/* ── Cookie Consent Banner & Modal ──────────────────────────────────────── */

/* Banner — fixed bottom bar */
.cc-banner {
  position: fixed;
  bottom: 0; left: 0; right: 0;
  background: var(--navy);
  border-top: 1px solid rgba(196,150,58,0.25);
  padding: 1.25rem 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  z-index: 9000;
  transform: translateY(0);
  transition: transform 0.4s var(--ease-out, cubic-bezier(0.22,1,0.36,1));
  flex-wrap: wrap;
}
.cc-banner--hidden {
  transform: translateY(110%);
  pointer-events: none;
}
.cc-banner__text {
  font-size: 0.8rem;
  color: rgba(255,255,255,0.68);
  max-width: 60ch;
  line-height: 1.65;
}
.cc-banner__text a {
  color: var(--gold);
  text-decoration: underline;
}
.cc-banner__actions {
  display: flex;
  gap: 0.55rem;
  flex-shrink: 0;
  flex-wrap: wrap;
  align-items: center;
}

/* Modal overlay */
.cc-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.55);
  z-index: 9001;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}
.cc-overlay--visible {
  opacity: 1;
  pointer-events: all;
}

/* Modal panel — slides up from bottom */
.cc-modal {
  position: fixed;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%) translateY(100%);
  width: min(640px, 100vw);
  background: var(--navy);
  border-top: 2px solid var(--gold);
  border-left: 1px solid rgba(196,150,58,0.2);
  border-right: 1px solid rgba(196,150,58,0.2);
  padding: 2rem;
  z-index: 9002;
  transition: transform 0.35s var(--ease-out, cubic-bezier(0.22,1,0.36,1));
  max-height: 85vh;
  overflow-y: auto;
}
.cc-modal--visible {
  transform: translateX(-50%) translateY(0);
}

.cc-modal__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.5rem;
}
.cc-modal__title {
  font-family: var(--font-display, serif);
  font-size: 1.1rem;
  color: var(--white);
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.cc-modal__close {
  background: none;
  border: none;
  color: rgba(255,255,255,0.45);
  cursor: pointer;
  font-size: 1.4rem;
  line-height: 1;
  padding: 0.2rem 0.4rem;
  transition: color 0.2s;
}
.cc-modal__close:hover { color: var(--white); }

/* Category rows */
.cc-category {
  border-top: 1px solid rgba(196,150,58,0.12);
  padding: 1.1rem 0;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1.25rem;
}
.cc-category:last-of-type {
  border-bottom: 1px solid rgba(196,150,58,0.12);
}
.cc-category__info { flex: 1; }
.cc-category__name {
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--white);
  margin-bottom: 0.35rem;
}
.cc-category__desc {
  font-size: 0.78rem;
  color: rgba(255,255,255,0.48);
  line-height: 1.58;
}

/* "Always on" label for necessary cookies */
.cc-always-on {
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--gold);
  flex-shrink: 0;
  padding-top: 3px;
}

/* Toggle switch */
.cc-toggle {
  position: relative;
  display: inline-block;
  width: 44px;
  height: 24px;
  flex-shrink: 0;
  margin-top: 2px;
  cursor: pointer;
}
.cc-toggle input {
  opacity: 0;
  width: 0; height: 0;
  position: absolute;
}
.cc-toggle__track {
  position: absolute;
  inset: 0;
  background: rgba(255,255,255,0.15);
  border-radius: 12px;
  transition: background 0.25s;
}
.cc-toggle input:checked + .cc-toggle__track {
  background: var(--gold);
}
.cc-toggle__track::after {
  content: '';
  position: absolute;
  top: 3px; left: 3px;
  width: 18px; height: 18px;
  background: #fff;
  border-radius: 50%;
  transition: transform 0.25s;
  box-shadow: 0 1px 3px rgba(0,0,0,0.3);
}
.cc-toggle input:checked + .cc-toggle__track::after {
  transform: translateX(20px);
}

/* Modal action buttons */
.cc-modal__actions {
  display: flex;
  gap: 0.55rem;
  margin-top: 1.75rem;
  flex-wrap: wrap;
  justify-content: flex-end;
}

/* Shared button base */
.cc-btn {
  font-family: var(--font-body, sans-serif);
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 0.65rem 1.35rem;
  cursor: pointer;
  border: 1px solid transparent;
  transition: background 0.22s, color 0.22s, border-color 0.22s;
  white-space: nowrap;
  line-height: 1;
}
.cc-btn--gold {
  background: var(--gold);
  color: #fff;
  border-color: var(--gold);
}
.cc-btn--gold:hover {
  background: rgba(196,150,58,0.8);
  border-color: rgba(196,150,58,0.8);
}
.cc-btn--outline {
  background: transparent;
  color: rgba(255,255,255,0.65);
  border-color: rgba(255,255,255,0.28);
}
.cc-btn--outline:hover {
  color: #fff;
  border-color: rgba(255,255,255,0.55);
}

/* Mobile */
@media (max-width: 768px) {
  .cc-banner {
    padding: 1rem 1.25rem;
    flex-direction: column;
    align-items: flex-start;
  }
  .cc-banner__actions {
    width: 100%;
  }
  .cc-banner__actions .cc-btn {
    flex: 1;
    text-align: center;
  }
  .cc-modal {
    width: 100vw;
    padding: 1.5rem 1.25rem;
    border-left: none;
    border-right: none;
  }
  .cc-modal__actions {
    flex-direction: column-reverse;
  }
  .cc-modal__actions .cc-btn {
    width: 100%;
    text-align: center;
  }
}
