/* ============================================================
   SDOS Cookie Consent — banner + settings modal
   Palette follows assets/css/style.css (deep navy + powder blue)
   Fixed positioning: no layout shift (CLS-safe).
   ============================================================ */

.sc-banner {
  position: fixed;
  left: 20px;
  bottom: 20px;
  z-index: 9999;
  max-width: 440px;
  width: calc(100% - 40px);
  opacity: 0;
  transform: translateY(16px);
  transition: opacity .25s ease, transform .25s ease;
  pointer-events: none;
}
.sc-banner.sc-visible { opacity: 1; transform: translateY(0); pointer-events: auto; }

.sc-card {
  background: #ffffff;
  border: 1px solid #e3e9f2;
  border-radius: 18px;
  box-shadow: 0 2px 6px rgba(11, 30, 58, .08), 0 22px 55px rgba(11, 30, 58, .14);
  padding: 22px 24px;
  font-family: "Inter", -apple-system, "Segoe UI", sans-serif;
}

.sc-title {
  font-family: "Manrope", "Inter", -apple-system, "Segoe UI", sans-serif;
  font-weight: 700;
  font-size: 17px;
  color: #101828;
  margin: 0 0 8px;
}

.sc-text {
  font-size: 13.5px;
  line-height: 1.55;
  color: #3d4b61;
  margin: 0 0 16px;
}

.sc-link { color: #2f6fe0; text-decoration: underline; }

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

.sc-btn {
  font-family: "Manrope", "Inter", -apple-system, "Segoe UI", sans-serif;
  font-weight: 600;
  font-size: 13.5px;
  border-radius: 12px;
  padding: 10px 18px;
  cursor: pointer;
  border: 1.5px solid transparent;
  transition: background .15s ease, color .15s ease, border-color .15s ease;
}
.sc-btn--primary { background: #2f6fe0; color: #fff; }
.sc-btn--primary:hover { background: #4f8cf0; }
.sc-btn--ghost { background: #fff; color: #0b1e3a; border-color: #c7dbfb; }
.sc-btn--ghost:hover { background: #f4f7fb; }
.sc-btn--text { background: none; color: #2f6fe0; padding: 10px 6px; }
.sc-btn--text:hover { text-decoration: underline; }
.sc-btn--block { width: 100%; margin-top: 18px; }

/* ---------- settings modal ---------- */
.sc-modal {
  position: fixed;
  inset: 0;
  z-index: 10000;
  background: rgba(8, 20, 38, .55);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  transition: opacity .2s ease;
  pointer-events: none;
}
.sc-modal.sc-visible { opacity: 1; pointer-events: auto; }

.sc-modal__box {
  background: #ffffff;
  border-radius: 18px;
  box-shadow: 0 2px 6px rgba(11, 30, 58, .08), 0 22px 55px rgba(11, 30, 58, .14);
  max-width: 520px;
  width: 100%;
  max-height: calc(100vh - 40px);
  overflow-y: auto;
  padding: 26px 28px;
  font-family: "Inter", -apple-system, "Segoe UI", sans-serif;
}

.sc-modal__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 18px;
}
.sc-modal__head .sc-title { margin: 0; }

.sc-modal__close {
  background: none;
  border: none;
  font-size: 26px;
  line-height: 1;
  color: #66748c;
  cursor: pointer;
  padding: 2px 6px;
}
.sc-modal__close:hover { color: #101828; }

.sc-cat {
  border: 1px solid #e3e9f2;
  border-radius: 12px;
  padding: 14px 16px;
  margin-bottom: 12px;
}
.sc-cat__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.sc-cat__name { font-weight: 600; font-size: 14.5px; color: #101828; }
.sc-cat__desc { font-size: 13px; color: #66748c; margin: 6px 0 0; }
.sc-cat__badge {
  font-size: 12px;
  font-weight: 600;
  color: #1f9d66;
  background: #eef3fa;
  border-radius: 999px;
  padding: 4px 10px;
  white-space: nowrap;
}

/* toggle switch */
.sc-switch { position: relative; display: inline-block; width: 44px; height: 24px; flex: none; }
.sc-switch input { opacity: 0; width: 0; height: 0; }
.sc-switch__slider {
  position: absolute; inset: 0;
  background: #c7dbfb;
  border-radius: 999px;
  transition: background .2s ease;
  cursor: pointer;
}
.sc-switch__slider::before {
  content: "";
  position: absolute;
  width: 18px; height: 18px;
  left: 3px; top: 3px;
  background: #ffffff;
  border-radius: 50%;
  transition: transform .2s ease;
  box-shadow: 0 1px 3px rgba(11, 30, 58, .25);
}
.sc-switch input:checked + .sc-switch__slider { background: #2f6fe0; }
.sc-switch input:checked + .sc-switch__slider::before { transform: translateX(20px); }
.sc-switch input:focus-visible + .sc-switch__slider { outline: 2px solid #4f8cf0; outline-offset: 2px; }

/* footer link */
.sc-footer-link {
  background: none;
  border: none;
  padding: 0;
  font: inherit;
  color: inherit;
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 2px;
}
.sc-footer-link:hover { color: #8cb4e7; }
.sc-footer-sep { margin: 0 6px; }

/* ---------- mobile ---------- */
@media (max-width: 560px) {
  .sc-banner {
    left: 0;
    right: 0;
    bottom: 0;
    max-width: none;
    width: 100%;
    padding: 0 12px 12px;
  }
  .sc-card { border-radius: 14px; padding: 18px 18px; }
  .sc-actions { flex-direction: column; align-items: stretch; }
  .sc-btn { width: 100%; text-align: center; }
  .sc-btn--text { text-align: center; }
  .sc-modal { padding: 12px; align-items: flex-end; }
  .sc-modal__box { padding: 20px 18px; border-radius: 14px; }
}
