/* Consent-banner + voorkeurenmodal.
   Huisstijl: crème surface, teal/goud accent, donker brons als accent. Werkt op
   zowel de publieke als de ingelogde schermen. Kleuren als losse waarden omdat
   niet alle pagina's dezelfde :root-tokens laden. */

:root {
  --fqpc-ink: #13263C;
  --fqpc-surface: #FFFDF8;
  --fqpc-canvas: #F1EEE9;
  --fqpc-cream: #F5F2ED;
  --fqpc-line: #E2DCD0;
  --fqpc-line-2: #CFC6B4;
  --fqpc-muted: #6B6659;
  --fqpc-teal: #17535F;
  --fqpc-gold: #B78A38;
  --fqpc-gold-text: #8A6227;
  --fqpc-accent: #7E5620;
  --fqpc-accent-top: #946B26;
  --fqpc-accent-low: #5E3F13;
  --fqpc-focus: 0 0 0 3px rgba(183, 138, 56, .35);
  /* CP-UI-FONT-CONSOLIDATIE-001: lettertype uit de centrale bron (fonts.css).
     FQP-consent laadt altijd samen met fonts.css (_fqp_public_head / feequote_base). */
  --fqpc-ff: var(--font-body);
}

/* Verborgen totdat de JS beslist dat de banner getoond moet worden. Zo is er
   geen flikkering bij een bezoeker die de keuze al gemaakt heeft. */
.fqpc-banner[hidden],
.fqpc-modal[hidden],
.fqpc-prefs[hidden] { display: none !important; }

/* ---------- Banner (onderin, volledige breedte) ---------- */
.fqpc-banner {
  position: fixed;
  left: 0; right: 0; bottom: 0;
  z-index: 2147483000;
  background: var(--fqpc-surface);
  border-top: 3px solid var(--fqpc-gold);
  box-shadow: 0 -8px 30px -18px rgba(19, 38, 60, .55);
  font-family: var(--fqpc-ff);
  color: var(--fqpc-ink);
  padding: 18px 20px calc(18px + env(safe-area-inset-bottom, 0px));
}
.fqpc-inner {
  max-width: 1180px; margin: 0 auto;
  display: flex; align-items: center; gap: 22px;
  flex-wrap: wrap;
}
.fqpc-copy { flex: 1 1 420px; min-width: 260px; }
.fqpc-title {
  margin: 0 0 4px; font-size: 14px; font-weight: 700;
  letter-spacing: .02em; color: var(--fqpc-accent);
  line-height: 1.35; /* expliciet, niet erven */
}
.fqpc-body { margin: 0; font-size: 12.5px; line-height: 1.5; color: var(--fqpc-muted); }

/* ---------- Knoprij: Accepteren en Weigeren even prominent ---------- */
.fqpc-actions {
  display: flex; gap: 10px; flex-wrap: wrap;
  align-items: center; flex: 0 0 auto;
}
.fqpc-btn {
  appearance: none; cursor: pointer; font-family: var(--fqpc-ff);
  font-size: 12.5px; font-weight: 600; letter-spacing: .06em;
  padding: 12px 20px; min-width: 118px; border-radius: 10px;
  border: 1px solid var(--fqpc-line-2); background: var(--fqpc-surface);
  color: var(--fqpc-ink); transition: filter .15s, border-color .15s,
    background-color .15s, color .15s, box-shadow .15s; text-align: center;
  /* ruime regelhoogte zodat staarten (g/j/p) volledig passen */
  line-height: 1.35;
}
.fqpc-btn:hover { border-color: var(--fqpc-accent); color: var(--fqpc-accent); }
.fqpc-btn:focus-visible { outline: none; box-shadow: var(--fqpc-focus); }

/* Accepteren én Weigeren delen exact dezelfde primaire stijl (geen dark
   pattern) — beide zijn de bronzen fill-knop. Instellingen is de neutrale
   omkaderde knop. */
.fqpc-btn--primary {
  border: 1px solid rgba(227, 194, 120, .42);
  background: linear-gradient(180deg, var(--fqpc-accent-top) 0%,
    var(--fqpc-accent) 55%, var(--fqpc-accent-low) 100%);
  color: #FFFDF8;
  box-shadow: 0 1px 0 rgba(247, 226, 157, .22) inset,
    0 10px 22px -14px rgba(94, 63, 19, .9);
}
.fqpc-btn--primary:hover { filter: brightness(1.06); color: #FFFDF8;
  border-color: rgba(247, 226, 157, .65); }

/* ---------- Modal (voorkeuren per categorie) ---------- */
.fqpc-modal {
  position: fixed; inset: 0; z-index: 2147483600;
  display: flex; align-items: center; justify-content: center;
  padding: 24px; background: rgba(19, 38, 60, .45);
  font-family: var(--fqpc-ff); color: var(--fqpc-ink);
}
.fqpc-dialog {
  width: 100%; max-width: 540px; max-height: calc(100vh - 48px);
  overflow-y: auto; background: var(--fqpc-surface);
  border: 1px solid var(--fqpc-line);
  border-radius: 16px; padding: 28px 28px 22px;
  box-shadow: 0 30px 70px -40px rgba(19, 38, 60, .7);
}
.fqpc-dialog-head {
  display: flex; align-items: flex-start; justify-content: space-between;
  gap: 16px; margin-bottom: 6px;
}
.fqpc-modal-title {
  margin: 0; font-size: 17px; font-weight: 700; color: var(--fqpc-accent);
  line-height: 1.3; /* staarten volledig zichtbaar */
}
.fqpc-close {
  appearance: none; border: 0; background: none; cursor: pointer;
  font-size: 22px; line-height: 1; color: var(--fqpc-muted);
  padding: 2px 6px; border-radius: 8px;
}
.fqpc-close:hover { color: var(--fqpc-ink); }
.fqpc-close:focus-visible { outline: none; box-shadow: var(--fqpc-focus); }
.fqpc-modal-intro {
  margin: 0 0 18px; font-size: 12.5px; line-height: 1.5; color: var(--fqpc-muted);
}

/* Categorie-kaart */
.fqpc-cat {
  border: 1px solid var(--fqpc-line); border-radius: 12px;
  padding: 14px 16px; margin-bottom: 12px; background: var(--fqpc-cream);
}
.fqpc-cat-head {
  display: flex; align-items: center; justify-content: space-between;
  gap: 12px; margin-bottom: 6px;
}
.fqpc-cat-title { font-size: 13.5px; font-weight: 700; color: var(--fqpc-ink); line-height: 1.35; }
/* ruime regelhoogte zodat staarten (j/y) volledig passen */
.fqpc-cat-desc { font-size: 12px; line-height: 1.5; color: var(--fqpc-muted); margin: 0; }
.fqpc-locked {
  font-size: 11px; font-weight: 700; letter-spacing: .04em;
  color: var(--fqpc-teal); text-transform: uppercase;
}

/* Toggle (analytisch) */
.fqpc-switch { position: relative; display: inline-flex; align-items: center; }
.fqpc-switch input {
  position: absolute; opacity: 0; width: 46px; height: 26px; margin: 0;
  cursor: pointer;
}
.fqpc-track {
  width: 46px; height: 26px; border-radius: 999px;
  background: #CFC6B4; transition: background-color .18s; position: relative;
  flex: 0 0 auto;
}
.fqpc-track::after {
  content: ""; position: absolute; top: 3px; left: 3px;
  width: 20px; height: 20px; border-radius: 50%; background: #FFFDF8;
  box-shadow: 0 1px 2px rgba(19, 38, 60, .3); transition: transform .18s;
}
.fqpc-switch input:checked + .fqpc-track { background: var(--fqpc-accent); }
.fqpc-switch input:checked + .fqpc-track::after { transform: translateX(20px); }
.fqpc-switch input:focus-visible + .fqpc-track { box-shadow: var(--fqpc-focus); }

.fqpc-dialog-foot {
  display: flex; justify-content: flex-end; gap: 10px; margin-top: 18px;
}

/* ---------- Herroep-link ("Cookievoorkeuren") ---------- */
.fqpc-prefs {
  position: fixed; left: 14px; bottom: 14px; z-index: 2147482000;
  font-family: var(--fqpc-ff); font-size: 11.5px; letter-spacing: .02em;
  background: var(--fqpc-surface); color: var(--fqpc-gold-text);
  border: 1px solid var(--fqpc-line); border-radius: 999px;
  padding: 8px 14px; cursor: pointer;
  line-height: 1.35; /* staarten volledig zichtbaar */
  box-shadow: 0 6px 18px -12px rgba(19, 38, 60, .5);
  transition: color .15s, border-color .15s;
}
.fqpc-prefs:hover { color: var(--fqpc-ink); border-color: var(--fqpc-accent); }
.fqpc-prefs:focus-visible { outline: none; box-shadow: var(--fqpc-focus); }

/* ---------- Mobiel (≤ 640px) ---------- */
@media (max-width: 640px) {
  .fqpc-inner { flex-direction: column; align-items: stretch; gap: 14px; }
  .fqpc-actions { flex-direction: column; }
  .fqpc-btn { width: 100%; }
  .fqpc-prefs { left: 10px; bottom: 10px; }
}

@media (prefers-reduced-motion: reduce) {
  .fqpc-btn, .fqpc-track, .fqpc-track::after, .fqpc-prefs, .fqpc-close { transition: none; }
}
