/* ═══════════════════════════════════════════════════════════════════
 VAAVIYO HOTEL · cookie-consent.css
 GDPR-compliant consent banner + preferences modal.
 Uses brand tokens from main.css (--v-red, --v-maroon, etc).
═══════════════════════════════════════════════════════════════════ */

/* ─── Banner (initial bottom-fixed strip) ─────────────────────── */
.cc-banner {
  position: fixed; left: 0; right: 0; bottom: 0;
  z-index: 9000;
  background: var(--v-maroon, #5a1a1f);
  color: var(--v-cream, #f7f1e6);
  border-top: 3px solid var(--v-red, #b8333a);
  box-shadow: 0 -6px 24px rgba(0, 0, 0, .25);
  font-family: var(--font-body, "Inter", system-ui, sans-serif);
  transform: translateY(100%);
  transition: transform .35s cubic-bezier(.4, 0, .2, 1);
  visibility: hidden;
}
.cc-banner.is-open {
  transform: translateY(0);
  visibility: visible;
}
.cc-banner-inner {
  max-width: 1240px;
  margin: 0 auto;
  padding: 22px clamp(18px, 4vw, 36px);
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 24px;
  align-items: center;
}
.cc-banner-text {
  font-size: 13.5px;
  line-height: 1.6;
  color: rgba(247, 241, 230, .9);
}
.cc-banner-text strong {
  display: block;
  font-family: var(--font-display, "Playfair Display", serif);
  font-weight: 600;
  font-size: 17px;
  color: var(--v-cream, #f7f1e6);
  margin-bottom: 4px;
  letter-spacing: .2px;
}
.cc-banner-text a {
  color: var(--v-sand, #d9c4a3);
  text-decoration: underline;
  text-underline-offset: 2px;
}
.cc-banner-text a:hover { color: var(--v-cream, #f7f1e6); }
.cc-banner-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: flex-end;
}
.cc-btn {
  font-family: inherit;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 1.6px;
  text-transform: uppercase;
  padding: 12px 22px;
  border: 1px solid transparent;
  border-radius: 2px;
  cursor: pointer;
  transition: background .2s, color .2s, border-color .2s;
  white-space: nowrap;
}
.cc-btn-primary {
  background: var(--v-red, #b8333a);
  color: #fff;
  border-color: var(--v-red, #b8333a);
}
.cc-btn-primary:hover {
  background: var(--v-red-d, #8e252b);
  border-color: var(--v-red-d, #8e252b);
}
.cc-btn-secondary {
  background: transparent;
  color: var(--v-cream, #f7f1e6);
  border-color: rgba(247, 241, 230, .4);
}
.cc-btn-secondary:hover {
  background: rgba(247, 241, 230, .08);
  border-color: var(--v-cream, #f7f1e6);
}
.cc-btn-link {
  background: transparent;
  color: var(--v-sand, #d9c4a3);
  border-color: transparent;
  padding: 12px 8px;
  text-decoration: underline;
  text-underline-offset: 3px;
}
.cc-btn-link:hover { color: var(--v-cream, #f7f1e6); }

/* ─── Preferences modal (granular toggles) ────────────────────── */
.cc-modal-backdrop {
  position: fixed; inset: 0;
  z-index: 9100;
  background: rgba(15, 8, 9, .72);
  backdrop-filter: blur(3px);
  opacity: 0;
  visibility: hidden;
  transition: opacity .25s, visibility .25s;
}
.cc-modal-backdrop.is-open {
  opacity: 1;
  visibility: visible;
}
.cc-modal {
  position: relative;
  width: min(560px, calc(100vw - 32px));
  max-height: calc(100vh - 64px);
  margin: 32px auto;
  background: var(--v-cream, #f7f1e6);
  color: var(--v-ink, #1f1a1a);
  border-radius: 4px;
  box-shadow: 0 24px 56px rgba(0, 0, 0, .35);
  display: flex;
  flex-direction: column;
  font-family: var(--font-body, "Inter", system-ui, sans-serif);
  transform: translateY(12px);
  transition: transform .25s;
}
.cc-modal-backdrop.is-open .cc-modal { transform: translateY(0); }
.cc-modal-header {
  padding: 24px 28px 16px;
  border-bottom: 1px solid rgba(31, 26, 26, .08);
}
.cc-modal-eyebrow {
  font-size: 10.5px;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--v-red, #b8333a);
  font-weight: 600;
  margin-bottom: 6px;
}
.cc-modal-title {
  font-family: var(--font-display, "Playfair Display", serif);
  font-weight: 500;
  font-size: 24px;
  color: var(--v-maroon, #5a1a1f);
  margin: 0;
  line-height: 1.2;
}
.cc-modal-close {
  position: absolute;
  top: 18px; right: 20px;
  width: 32px; height: 32px;
  background: transparent;
  border: none;
  color: var(--v-mist, #8a7a78);
  font-size: 18px;
  cursor: pointer;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  transition: background .15s, color .15s;
}
.cc-modal-close:hover {
  background: rgba(31, 26, 26, .06);
  color: var(--v-ink, #1f1a1a);
}
.cc-modal-body {
  padding: 18px 28px 4px;
  overflow-y: auto;
  flex: 1;
}
.cc-modal-intro {
  font-size: 13.5px;
  line-height: 1.65;
  color: rgba(31, 26, 26, .8);
  margin: 0 0 18px;
}
.cc-category {
  border-top: 1px solid rgba(31, 26, 26, .08);
  padding: 16px 0;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px 18px;
  align-items: start;
}
.cc-category-name {
  font-weight: 600;
  font-size: 14px;
  color: var(--v-maroon, #5a1a1f);
  margin-bottom: 4px;
}
.cc-category-desc {
  font-size: 12.5px;
  line-height: 1.55;
  color: rgba(31, 26, 26, .72);
}
.cc-category-locked {
  font-size: 11px;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--v-red, #b8333a);
  font-weight: 600;
  align-self: center;
}

/* Toggle switch */
.cc-toggle {
  position: relative;
  width: 42px; height: 24px;
  flex-shrink: 0;
  align-self: center;
}
.cc-toggle input {
  opacity: 0;
  width: 0; height: 0;
  position: absolute;
}
.cc-toggle-slider {
  position: absolute; inset: 0;
  background: rgba(31, 26, 26, .25);
  border-radius: 24px;
  cursor: pointer;
  transition: background .2s;
}
.cc-toggle-slider::before {
  content: "";
  position: absolute;
  height: 18px; width: 18px;
  left: 3px; top: 3px;
  background: #fff;
  border-radius: 50%;
  transition: transform .2s;
  box-shadow: 0 1px 3px rgba(0, 0, 0, .2);
}
.cc-toggle input:checked + .cc-toggle-slider {
  background: var(--v-red, #b8333a);
}
.cc-toggle input:checked + .cc-toggle-slider::before {
  transform: translateX(18px);
}
.cc-toggle input:focus-visible + .cc-toggle-slider {
  outline: 2px solid var(--v-red, #b8333a);
  outline-offset: 2px;
}

.cc-modal-footer {
  padding: 16px 28px 22px;
  border-top: 1px solid rgba(31, 26, 26, .08);
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: flex-end;
}
.cc-modal .cc-btn-secondary {
  color: var(--v-maroon, #5a1a1f);
  border-color: rgba(90, 26, 31, .35);
}
.cc-modal .cc-btn-secondary:hover {
  background: rgba(90, 26, 31, .06);
  border-color: var(--v-maroon, #5a1a1f);
}

/* ─── Footer "Cookie Settings" link button ────────────────────── */
.cc-reopen {
  background: none;
  border: none;
  padding: 0;
  font: inherit;
  color: inherit;
  cursor: pointer;
  text-decoration: none;
}
.cc-reopen:hover { color: var(--v-red, #b8333a); }

/* ─── Responsive ──────────────────────────────────────────────── */
@media (max-width: 720px) {
  .cc-banner-inner {
    grid-template-columns: 1fr;
    gap: 16px;
    padding: 18px 18px 20px;
  }
  .cc-banner-actions {
    justify-content: stretch;
  }
  .cc-banner-actions .cc-btn {
    flex: 1;
    min-width: 0;
    padding: 12px 14px;
    font-size: 11px;
    letter-spacing: 1.2px;
  }
  .cc-banner-actions .cc-btn-link {
    flex-basis: 100%;
    order: 3;
  }
  .cc-modal-header { padding: 20px 20px 14px; }
  .cc-modal-body { padding: 16px 20px 4px; }
  .cc-modal-footer { padding: 14px 20px 18px; }
  .cc-modal-title { font-size: 21px; }
}

@media (prefers-reduced-motion: reduce) {
  .cc-banner, .cc-modal-backdrop, .cc-modal { transition: none; }
}
