/**
 * SnoCountry Consent Banner styles (sno-consent-banner.js)
 *
 * Self-contained — no Tailwind or site-CSS dependencies, since the banner
 * appears on every layout. Accept all and Reject all are intentionally
 * styled identically (equal prominence, no dark patterns).
 */

.sno-consent-banner {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 9999;
  background: #ffffff;
  border-top: 3px solid #0d568b;
  box-shadow: 0 -4px 24px rgba(1, 22, 46, 0.18);
  font-family: "Mulish", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  color: #1f2937;
  line-height: 1.5;
}

.sno-consent-inner {
  max-width: 1020px;
  margin: 0 auto;
  padding: 18px 22px 20px;
}

.sno-consent-title {
  margin: 0 0 6px;
  font-size: 17px;
  font-weight: 700;
  color: #01203d;
}

.sno-consent-body {
  margin: 0 0 14px;
  font-size: 14px;
  color: #374151;
  max-width: 78ch;
}

.sno-consent-link {
  color: #0d568b;
  text-decoration: underline;
}

.sno-consent-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

.sno-consent-btn {
  font: inherit;
  font-size: 14px;
  font-weight: 600;
  border-radius: 8px;
  padding: 9px 18px;
  cursor: pointer;
  border: 1px solid transparent;
}

.sno-consent-btn:focus-visible {
  outline: 3px solid #529cc3;
  outline-offset: 2px;
}

.sno-consent-btn-primary {
  background: #0d568b;
  color: #ffffff;
}

.sno-consent-btn-primary:hover {
  background: #044b81;
}

.sno-consent-btn-text {
  background: transparent;
  color: #0d568b;
  border-color: #c8d4e0;
}

.sno-consent-btn-text:hover {
  background: #e8eef6;
}

.sno-consent-prefs {
  margin-top: 16px;
  border-top: 1px solid #e5e7eb;
  padding-top: 12px;
  max-height: 45vh;
  overflow-y: auto;
}

.sno-consent-pref-row {
  padding: 8px 0;
  border-bottom: 1px solid #f0f2f5;
}

.sno-consent-pref-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  cursor: pointer;
}

.sno-consent-pref-label {
  font-size: 14px;
  font-weight: 700;
  color: #01203d;
}

.sno-consent-pref-always {
  font-size: 12px;
  font-weight: 600;
  color: #3d7a4c;
  background: #eaf4ec;
  border: 1px solid #c2dcc8;
  border-radius: 999px;
  padding: 2px 10px;
}

.sno-consent-pref-desc {
  margin: 4px 0 0;
  font-size: 13px;
  color: #6b7280;
  max-width: 70ch;
}

/* Toggle switch */
.sno-consent-pref-toggle {
  appearance: none;
  -webkit-appearance: none;
  width: 42px;
  height: 24px;
  flex-shrink: 0;
  border-radius: 999px;
  background: #cbd5e1;
  position: relative;
  cursor: pointer;
  transition: background 0.15s ease;
  margin: 0;
}

.sno-consent-pref-toggle::after {
  content: "";
  position: absolute;
  top: 3px;
  left: 3px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #ffffff;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
  transition: left 0.15s ease;
}

.sno-consent-pref-toggle:checked {
  background: #0d568b;
}

.sno-consent-pref-toggle:checked::after {
  left: 21px;
}

.sno-consent-pref-toggle:focus-visible {
  outline: 3px solid #529cc3;
  outline-offset: 2px;
}

.sno-consent-prefs-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  margin-top: 12px;
}

.sno-consent-prefs-note {
  margin: 0;
  font-size: 12.5px;
  color: #6b7280;
}

/* Footer "Cookie Preferences" trigger — renders like the sibling footer links */
.sno-consent-open {
  background: none;
  border: none;
  padding: 0;
  font: inherit;
  color: inherit;
  text-decoration: underline;
  cursor: pointer;
}

.sno-consent-open:focus-visible {
  outline: 3px solid #529cc3;
  outline-offset: 2px;
}

@media (max-width: 640px) {
  .sno-consent-inner {
    padding: 14px 16px 16px;
  }

  .sno-consent-actions .sno-consent-btn {
    flex: 1 1 100%;
  }

  .sno-consent-prefs {
    max-height: 38vh;
  }
}
