/* =====================================================================
 *  vaauban — cookie-banner.css
 *  Bandeau RGPD à la charte Night/Stone, conforme CNIL :
 *    - bouton "Tout accepter" et "Tout refuser" au même niveau visuel
 *    - lien "Personnaliser" pour le centre de préférences
 *    - aucun cookie déposé tant que le choix n'est pas fait
 * ===================================================================== */
.vb-cc {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 9999;
  background: #0F1A2E; color: #F2EDE4;
  border-top: 1px solid rgba(242,237,228,0.18);
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 14px; line-height: 1.5;
  transform: translateY(100%); transition: transform 280ms ease;
  box-shadow: 0 -12px 40px rgba(0,0,0,0.35);
}
.vb-cc.is-open { transform: translateY(0); }
.vb-cc-inner {
  max-width: 1200px; margin: 0 auto;
  padding: 22px clamp(20px, 4vw, 48px);
  display: grid; grid-template-columns: 1fr auto; gap: 24px; align-items: center;
}
.vb-cc-text { max-width: 70ch; }
.vb-cc-text strong {
  font-family: 'Fraunces', serif; font-weight: 380; font-size: 18px;
  display: block; margin-bottom: 6px; color: #F2EDE4;
}
.vb-cc-text p { margin: 0; color: rgba(242,237,228,0.78); font-size: 13.5px; }
.vb-cc-text a { color: #F2EDE4; text-decoration: underline; text-underline-offset: 3px; }
.vb-cc-actions { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.vb-cc-btn {
  font-family: inherit; font-weight: 500; font-size: 13.5px;
  padding: 11px 18px; border: 1px solid; cursor: pointer;
  background: transparent; color: inherit;
  letter-spacing: 0.005em; transition: background 160ms ease, color 160ms ease;
  border-radius: 0;
}
.vb-cc-btn--ghost { border-color: rgba(242,237,228,0.45); color: #F2EDE4; }
.vb-cc-btn--ghost:hover { background: rgba(242,237,228,0.08); }
.vb-cc-btn--primary { background: #4A6B3E; border-color: #4A6B3E; color: #FAFAF7; }
.vb-cc-btn--primary:hover { background: #F2EDE4; color: #0F1A2E; border-color: #F2EDE4; }
.vb-cc-btn--link {
  background: transparent; border: 0; padding: 11px 6px;
  color: rgba(242,237,228,0.78); text-decoration: underline; text-underline-offset: 4px;
}
.vb-cc-btn--link:hover { color: #F2EDE4; }

/* Modale préférences */
.vb-cc-modal {
  position: fixed; inset: 0; z-index: 10000;
  background: rgba(15,26,46,0.72);
  display: none; align-items: center; justify-content: center;
  padding: 24px; backdrop-filter: blur(4px);
}
.vb-cc-modal.is-open { display: flex; }
.vb-cc-modal-box {
  max-width: 560px; width: 100%;
  background: #FAFAF7; color: #0F1A2E;
  border: 1px solid rgba(15,26,46,0.12);
  padding: clamp(28px, 4vw, 40px);
  font-family: 'Inter', system-ui, sans-serif;
  max-height: 86vh; overflow: auto;
}
.vb-cc-modal-box h2 {
  font-family: 'Fraunces', serif; font-weight: 380; font-size: 28px;
  margin: 0 0 12px; letter-spacing: -0.01em; line-height: 1.1;
}
.vb-cc-modal-box p { font-size: 13.5px; color: #2a2a2a; line-height: 1.55; margin: 0 0 20px; }
.vb-cc-cat {
  border-top: 1px solid rgba(15,26,46,0.1); padding: 18px 0;
  display: grid; grid-template-columns: 1fr auto; gap: 16px; align-items: start;
}
.vb-cc-cat:last-of-type { border-bottom: 1px solid rgba(15,26,46,0.1); }
.vb-cc-cat h3 { font-size: 14px; margin: 0 0 4px; font-weight: 600; letter-spacing: -0.005em; }
.vb-cc-cat p { font-size: 12.5px; margin: 0; color: #555; }
.vb-cc-switch {
  position: relative; width: 40px; height: 22px; flex-shrink: 0;
  background: #d4d0c7; cursor: pointer; transition: background 160ms ease;
  border-radius: 999px;
}
.vb-cc-switch.is-on { background: #4A6B3E; }
.vb-cc-switch.is-locked { background: #4A6B3E; opacity: 0.55; cursor: not-allowed; }
.vb-cc-switch::after {
  content: ""; position: absolute; top: 2px; left: 2px;
  width: 18px; height: 18px; background: #FAFAF7;
  border-radius: 50%; transition: transform 160ms ease;
}
.vb-cc-switch.is-on::after { transform: translateX(18px); }
.vb-cc-modal-actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 24px; }
.vb-cc-modal-actions .vb-cc-btn { color: #0F1A2E; border-color: #0F1A2E; }
.vb-cc-modal-actions .vb-cc-btn--primary { color: #FAFAF7; }
.vb-cc-modal-actions .vb-cc-btn--ghost:hover { background: #0F1A2E; color: #FAFAF7; }

/* Bouton flottant pour rouvrir le centre de préférences */
.vb-cc-fab {
  position: fixed; left: 16px; bottom: 16px; z-index: 9998;
  width: 36px; height: 36px; border-radius: 50%;
  background: #0F1A2E; color: #F2EDE4; border: 1px solid rgba(242,237,228,0.2);
  cursor: pointer; display: none; align-items: center; justify-content: center;
  font-size: 16px; box-shadow: 0 6px 24px rgba(0,0,0,0.25);
}
.vb-cc-fab.is-visible { display: flex; }
.vb-cc-fab:hover { background: #4A6B3E; }

@media (max-width: 720px) {
  .vb-cc-inner { grid-template-columns: 1fr; gap: 18px; }
  .vb-cc-actions { justify-content: stretch; }
  .vb-cc-actions .vb-cc-btn { flex: 1; text-align: center; }
}
