.cookie-banner[hidden], .cookie-review:not([open]) { display: none; }
.cookie-banner {
  position: fixed; z-index: 1000; left: 50%; bottom: 18px;
  width: min(760px, calc(100% - 32px)); transform: translateX(-50%);
  padding: 20px; border: 1px solid rgba(255,255,255,.14); border-radius: 14px;
  background: rgba(20,20,19,.97); color: #fff;
  box-shadow: 0 24px 70px -24px rgba(0,0,0,.9);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
}
.cookie-banner__body { display: grid; grid-template-columns: 1fr auto; gap: 20px; align-items: end; }
.cookie-banner h2 { font-size: 1.05rem; margin-bottom: 6px; }
.cookie-banner p { color: rgba(255,255,255,.72); font-size: .88rem; line-height: 1.55; max-width: 62ch; }
.cookie-links { display: flex; flex-wrap: wrap; gap: 6px 14px; margin-top: 8px; font-size: .78rem; }
.cookie-links a { color: #fff; text-underline-offset: 3px; }
.cookie-actions { display: flex; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }
.cookie-actions .btn { padding: 11px 15px; font-size: .74rem; }
.cookie-actions .btn.cookie-secondary { background: transparent; box-shadow: inset 0 0 0 1px rgba(255,255,255,.38); }
.cookie-actions .btn.cookie-secondary:hover { background: rgba(255,255,255,.08); }

.cookie-review {
  width: min(640px, calc(100% - 28px)); max-height: min(760px, calc(100dvh - 28px));
  margin: auto; padding: 0; border: 0; border-radius: 16px; color: var(--fg);
  background: #fff; box-shadow: 0 30px 90px -20px #000; overflow: auto;
}
.cookie-review::backdrop { background: rgba(0,0,0,.66); backdrop-filter: blur(4px); }
.cookie-review__head { padding: 24px 24px 16px; border-bottom: 1px solid var(--border-subtle); }
.cookie-review__head h2 { font-size: 1.45rem; }
.cookie-review__head p { margin-top: 7px; color: var(--fg-muted); font-size: .9rem; }
.cookie-review__list { padding: 8px 24px; }
.cookie-option { display: grid; grid-template-columns: 1fr auto; gap: 18px; padding: 17px 0; border-bottom: 1px solid var(--border-subtle); }
.cookie-option:last-child { border-bottom: 0; }
.cookie-option strong { display: block; font-size: .95rem; }
.cookie-option p { margin-top: 3px; color: var(--fg-muted); font-size: .82rem; line-height: 1.5; }
.cookie-switch { position: relative; width: 46px; height: 26px; margin-top: 2px; }
.cookie-switch input { position: absolute; opacity: 0; pointer-events: none; }
.cookie-switch span { display: block; width: 100%; height: 100%; border-radius: 999px; background: #aaa; cursor: pointer; transition: background .18s; }
.cookie-switch span::after { content: ""; position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%; background: #fff; transition: transform .18s; box-shadow: 0 2px 6px rgba(0,0,0,.25); }
.cookie-switch input:checked + span { background: var(--red); }
.cookie-switch input:checked + span::after { transform: translateX(20px); }
.cookie-switch input:focus-visible + span { outline: 3px solid rgba(167,25,48,.28); outline-offset: 3px; }
.cookie-switch input:disabled + span { cursor: not-allowed; opacity: .72; }
.cookie-review__foot { position: sticky; bottom: 0; display: flex; justify-content: space-between; gap: 12px; padding: 16px 24px; background: #fff; border-top: 1px solid var(--border-subtle); }
.cookie-review__foot .btn { padding: 12px 16px; font-size: .76rem; }
.cookie-settings-link { border: 0; padding: 0; background: none; color: inherit; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; font: inherit; }

@media (max-width: 680px) {
  .cookie-banner { bottom: 10px; padding: 18px; }
  .cookie-banner__body { grid-template-columns: 1fr; gap: 16px; }
  .cookie-actions { justify-content: stretch; }
  .cookie-actions .btn { flex: 1 1 190px; }
  .cookie-review__head, .cookie-review__list { padding-left: 18px; padding-right: 18px; }
  .cookie-review__foot { padding: 14px 18px; flex-direction: column-reverse; }
  .cookie-review__foot .btn { width: 100%; }
}

@media (prefers-reduced-motion: reduce) {
  .cookie-switch span, .cookie-switch span::after { transition: none; }
}
