/* HDE theme overrides for Silktide Consent Manager (dark site, primary #663399 family) */
#stcm-wrapper {
  --fontFamily: Poppins, ui-sans-serif, system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --primaryColor: hsl(270 50% 60%);
  --backgroundColor: hsl(220 20% 12%);
  --textColor: hsl(0 0% 98%);
  --backdropBackgroundColor: #00000088;
  --iconColor: hsl(0 0% 98%);
  --iconBackgroundColor: hsl(270 50% 50%);
  --boxShadow: 0 10px 40px -10px #00000099;
}
#stcm-banner,
#stcm-modal {
  border: 1px solid hsl(220 15% 22%) !important;
  border-radius: 0.75rem !important;
}
#stcm-banner {
  padding: 20px 24px !important;
  font-size: 14px;
}
#stcm-banner p { font-size: 14px !important; line-height: 1.55 !important; }
#stcm-wrapper #stcm-banner button,
#stcm-wrapper #stcm-modal button.stcm-button {
  border-radius: 0.5rem !important;
  font-family: var(--fontFamily) !important;
  font-size: 14px !important;
}
@media (max-width: 640px) {
  #stcm-banner { left: 8px !important; right: 8px !important; bottom: 8px !important; width: auto !important; transform: none !important; padding: 16px !important; }
}

/* Hide visitor-facing Silktide branding (license kept in vendored source) */
#stcm-wrapper #stcm-icon,
#stcm-wrapper .stcm-logo,
#stcm-wrapper .stcm-credit-link { display: none !important; }

/* Integrate banner/modal with HDE theme */
#stcm-wrapper .stcm-button {
  border-radius: 9999px !important;
  font-weight: 600 !important;
  padding: 9px 20px !important;
  transition: background-color .2s, color .2s, border-color .2s;
}
#stcm-wrapper .stcm-button-secondary {
  background: transparent !important;
  color: var(--textColor) !important;
  border-color: hsl(220 15% 30%) !important;
}
#stcm-wrapper .stcm-button-secondary:hover { border-color: var(--primaryColor) !important; background: hsl(270 50% 60% / .12) !important; }
#stcm-wrapper .stcm-button-primary:hover { background: hsl(270 50% 52%) !important; color: var(--textColor) !important; border-color: hsl(270 50% 52%) !important; }
#stcm-wrapper .stcm-button-primary { color: var(--textColor) !important; }
#stcm-banner a, #stcm-modal a { background: transparent !important; text-underline-offset: 3px; }
#stcm-banner .stcm-preferences-button { font-family: var(--fontFamily); font-size: 14px !important; font-weight: 600; }
#stcm-modal { padding: 24px !important; max-width: calc(100% - 16px) !important; max-height: calc(100vh - 16px) !important; }
#stcm-modal h1 { font-size: 20px !important; font-weight: 600 !important; }
#stcm-modal p { font-size: 14px !important; line-height: 1.55 !important; }
#stcm-modal legend { font-size: 15px !important; font-weight: 600 !important; }
#stcm-modal section { margin-top: 16px !important; }
#stcm-modal fieldset { margin-bottom: 20px !important; padding-bottom: 20px !important; border-bottom: 1px solid hsl(220 15% 20%) !important; }
#stcm-modal fieldset:last-of-type { border-bottom: 0 !important; padding-bottom: 0 !important; }
#stcm-modal .stcm-modal-close { background: transparent !important; border-radius: 9999px !important; padding: 8px !important; }
#stcm-modal .stcm-toggle, #stcm-modal .stcm-toggle-track { width: 52px !important; height: 28px !important; }
#stcm-modal .stcm-toggle-track { background: hsl(220 15% 28%) !important; }
#stcm-modal .stcm-toggle input:checked + .stcm-toggle-track { background: var(--primaryColor) !important; }
#stcm-modal .stcm-toggle-thumb { width: 22px !important; height: 22px !important; top: 3px !important; left: 3px !important; background: var(--textColor) !important; }
#stcm-modal .stcm-toggle input:checked ~ .stcm-toggle-thumb { left: calc(100% - 25px) !important; }
#stcm-modal .stcm-toggle-on, #stcm-modal .stcm-toggle-off { display: none !important; }
#stcm-modal footer { justify-content: flex-end; }
