/* Cookie consent banner + settings panel — matches site tokens: bg #050505/#030303/#0a0a0a, accent #bfeeff, Inter + Playfair italic, glass-card language. Mirrors .qc-* modal pattern from configurator.css. */

body.cc-lock-scroll { overflow: hidden; }

/* ---------- Bottom banner ---------- */

#cookieBanner {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 9998;
  display: flex;
  justify-content: center;
  padding: 16px;
  transform: translateY(120%);
  opacity: 0;
  transition: transform .6s cubic-bezier(.16,1,.3,1), opacity .6s cubic-bezier(.16,1,.3,1);
  pointer-events: none;
}

#cookieBanner.cc-visible {
  transform: translateY(0);
  opacity: 1;
  pointer-events: auto;
}

#cookieBanner[hidden] { display: none; }

.cc-bar {
  width: min(980px, 100%);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 20px;
  border-radius: 26px;
  border: 1px solid rgba(255,255,255,.12);
  padding: 22px 26px;
  background: linear-gradient(160deg, rgba(255,255,255,.07), rgba(255,255,255,.018)), #0a0a0a;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.1), 0 30px 90px rgba(0,0,0,.5);
  backdrop-filter: blur(18px);
}

.cc-copy {
  flex: 1 1 320px;
  min-width: 240px;
  color: rgba(255,255,255,.72);
  font-size: 13px;
  line-height: 1.6;
}

.cc-copy strong {
  color: #fff;
  font-weight: 600;
}

.cc-copy a {
  color: #bfeeff;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.cc-copy a:hover { color: #fff; }

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

.cc-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  padding: 11px 20px;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: -.01em;
  white-space: nowrap;
  cursor: pointer;
  border: none;
  transition: transform .2s ease, background .3s ease, box-shadow .3s ease, border-color .3s ease, color .3s ease;
}

.cc-btn:active { transform: scale(.95); }

.cc-btn-primary {
  background: #fff;
  color: #000;
}

.cc-btn-primary:hover {
  background: #effbff;
  box-shadow: 0 10px 30px rgba(191,238,255,.25);
}

.cc-btn-ghost {
  background: transparent;
  color: rgba(255,255,255,.78);
  border: 1px solid rgba(255,255,255,.2);
}

.cc-btn-ghost:hover {
  border-color: rgba(255,255,255,.4);
  color: #fff;
  background: rgba(255,255,255,.06);
}

.cc-btn-text {
  background: transparent;
  color: rgba(255,255,255,.6);
  padding: 11px 6px;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.cc-btn-text:hover { color: #bfeeff; }

/* ---------- Settings overlay (mirrors .qc-* pattern) ---------- */

#cookieSettingsOverlay {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

#cookieSettingsOverlay[hidden] { display: none; }

.cc-backdrop {
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 50% 0%, rgba(191,238,255,.06), transparent 55%), rgba(3,3,3,.86);
  backdrop-filter: blur(6px);
  opacity: 0;
  transition: opacity .45s cubic-bezier(.16,1,.3,1);
}

#cookieSettingsOverlay.cc-open .cc-backdrop { opacity: 1; }

.cc-panel {
  position: relative;
  width: min(560px, 100%);
  max-height: min(720px, 92vh);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border-radius: 2rem;
  border: 1px solid rgba(255,255,255,.12);
  background: linear-gradient(160deg, rgba(255,255,255,.08), rgba(255,255,255,.02)), #0a0a0a;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.1), 0 40px 140px rgba(0,0,0,.6);
  opacity: 0;
  transform: translateY(24px) scale(.98);
  transition: opacity .5s cubic-bezier(.16,1,.3,1), transform .5s cubic-bezier(.16,1,.3,1);
}

#cookieSettingsOverlay.cc-open .cc-panel { opacity: 1; transform: translateY(0) scale(1); }

.cc-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 22px 24px 16px;
  border-bottom: 1px solid rgba(255,255,255,.08);
  flex-shrink: 0;
}

.cc-title {
  font-size: clamp(20px, 3vw, 26px);
  font-weight: 500;
  letter-spacing: -.02em;
  color: #fff;
  margin: 0;
}

.cc-title em {
  font-family: "Playfair Display", serif;
  font-style: italic;
  font-weight: 500;
}

.cc-close {
  flex-shrink: 0;
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,.18);
  background: transparent;
  color: rgba(255,255,255,.7);
  cursor: pointer;
  transition: border-color .3s ease, color .3s ease, background .3s ease;
}

.cc-close:hover { border-color: rgba(255,255,255,.4); color: #fff; background: rgba(255,255,255,.06); }

.cc-body {
  position: relative;
  flex: 1;
  overflow-y: auto;
  padding: 22px 24px 6px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.cc-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  padding: 16px 18px;
  border-radius: 18px;
  border: 1px solid rgba(255,255,255,.1);
  background: rgba(255,255,255,.03);
}

.cc-row-copy { flex: 1; }

.cc-row-title {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 14px;
  font-weight: 600;
  color: #fff;
  margin: 0 0 6px;
}

.cc-row-badge {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: rgba(191,238,255,.86);
  border: 1px solid rgba(191,238,255,.3);
  background: rgba(191,238,255,.08);
  border-radius: 999px;
  padding: 3px 9px;
}

.cc-row-desc {
  margin: 0;
  font-size: 13px;
  line-height: 1.6;
  color: rgba(255,255,255,.58);
}

.cc-toggle {
  flex-shrink: 0;
  position: relative;
  width: 46px;
  height: 26px;
}

.cc-toggle input {
  position: absolute;
  inset: 0;
  opacity: 0;
  margin: 0;
  cursor: pointer;
}

.cc-toggle input:disabled { cursor: not-allowed; }

.cc-toggle-track {
  position: absolute;
  inset: 0;
  border-radius: 999px;
  background: rgba(255,255,255,.14);
  border: 1px solid rgba(255,255,255,.16);
  transition: background .3s ease, border-color .3s ease;
  pointer-events: none;
}

.cc-toggle-track::after {
  content: "";
  position: absolute;
  top: 2px;
  left: 2px;
  width: 20px;
  height: 20px;
  border-radius: 999px;
  background: #fff;
  transition: transform .3s cubic-bezier(.16,1,.3,1);
}

.cc-toggle input:checked ~ .cc-toggle-track {
  background: rgba(191,238,255,.4);
  border-color: rgba(191,238,255,.6);
}

.cc-toggle input:checked ~ .cc-toggle-track::after {
  transform: translateX(20px);
  background: #bfeeff;
}

.cc-toggle input:disabled ~ .cc-toggle-track {
  opacity: .5;
}

.cc-toggle input:focus-visible ~ .cc-toggle-track {
  outline: 2px solid #bfeeff;
  outline-offset: 2px;
}

.cc-link {
  margin: 4px 0 0;
  font-size: 12px;
  color: rgba(255,255,255,.5);
}

.cc-link a { color: #bfeeff; text-decoration: underline; text-underline-offset: 2px; }
.cc-link a:hover { color: #fff; }

.cc-footer {
  flex-shrink: 0;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  padding: 18px 24px 24px;
  border-top: 1px solid rgba(255,255,255,.08);
}

@media (max-width: 640px) {
  #cookieBanner {
    padding: 10px 12px;
  }

  .cc-bar {
    flex-direction: column;
    align-items: stretch;
    text-align: left;
    gap: 12px;
    padding: 14px 16px;
    border-radius: 20px;
  }

  .cc-copy {
    flex: 1 1 auto;
    font-size: 12px;
    line-height: 1.5;
  }

  .cc-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    width: 100%;
  }

  .cc-btn {
    padding: 10px 12px;
    font-size: 12px;
  }

  .cc-btn-primary {
    grid-column: 1 / -1;
  }
}

@media (prefers-reduced-motion: reduce) {
  #cookieBanner,
  .cc-backdrop,
  .cc-panel,
  .cc-toggle-track,
  .cc-toggle-track::after,
  .cc-btn {
    transition: none !important;
  }
}
