/* ============================================================
   GSR Technology — Bandeau de consentement cookies (CNIL/RGPD)
   Sans dépendance. Injecté par js/cookie-consent.js
   ============================================================ */

:root {
  --cc-navy:       #1a2a4a;
  --cc-navy-deep:  #0f1e38;
  --cc-teal:       #3ab5c6;
  --cc-teal-dark:  #2a9aab;
  --cc-white:      #ffffff;
  --cc-text:       rgba(255,255,255,0.82);
  --cc-muted:      rgba(255,255,255,0.55);
  --cc-border:     rgba(255,255,255,0.12);
}

/* ── Bandeau (1re visite) ─────────────────────────────────── */
.gsr-cc-banner {
  position: fixed;
  z-index: 9998;
  left: 1rem;
  right: 1rem;
  bottom: 1rem;
  max-width: 480px;
  margin: 0 auto 0 1rem;
  background: linear-gradient(160deg, #1e3560 0%, #14233f 100%);
  color: var(--cc-text);
  border: 1px solid var(--cc-border);
  border-radius: 16px;
  box-shadow: 0 20px 60px rgba(0,0,0,0.4);
  padding: 1.5rem;
  font-family: 'Roboto', system-ui, sans-serif;
  transform: translateY(140%);
  opacity: 0;
  transition: transform .5s cubic-bezier(.16,1,.3,1), opacity .4s;
}
.gsr-cc-banner.gsr-cc-visible { transform: translateY(0); opacity: 1; }

.gsr-cc-title {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--cc-white);
  margin: 0 0 .5rem;
}
.gsr-cc-text {
  font-size: .85rem;
  line-height: 1.6;
  color: var(--cc-text);
  margin: 0 0 1.1rem;
}
.gsr-cc-text a { color: var(--cc-teal); text-decoration: underline; }

.gsr-cc-actions {
  display: flex;
  flex-wrap: wrap;
  gap: .6rem;
}

.gsr-cc-btn {
  font-family: inherit;
  font-size: .85rem;
  font-weight: 600;
  border-radius: 50px;
  padding: .6rem 1.15rem;
  cursor: pointer;
  border: 1px solid transparent;
  transition: all .2s ease;
  flex: 1 1 auto;
  white-space: nowrap;
}
.gsr-cc-btn-primary {
  background: linear-gradient(135deg, #4dc8d8 0%, #2fa8b8 100%);
  color: #06222a;
  border-color: rgba(255,255,255,.15);
}
.gsr-cc-btn-primary:hover { filter: brightness(1.06); }
.gsr-cc-btn-secondary {
  background: rgba(255,255,255,.06);
  color: var(--cc-white);
  border-color: var(--cc-border);
}
.gsr-cc-btn-secondary:hover { background: rgba(255,255,255,.12); }
.gsr-cc-btn-link {
  background: transparent;
  color: var(--cc-muted);
  border: none;
  flex: 0 0 auto;
  text-decoration: underline;
  padding: .6rem .4rem;
}
.gsr-cc-btn-link:hover { color: var(--cc-white); }

/* ── Modale préférences ───────────────────────────────────── */
.gsr-cc-overlay {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: rgba(8,15,30,.6);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.25rem;
  opacity: 0;
  visibility: hidden;
  transition: opacity .3s, visibility .3s;
}
.gsr-cc-overlay.gsr-cc-visible { opacity: 1; visibility: visible; }

.gsr-cc-modal {
  width: 100%;
  max-width: 560px;
  max-height: 90vh;
  overflow-y: auto;
  background: linear-gradient(160deg, #1e3560 0%, #14233f 100%);
  color: var(--cc-text);
  border: 1px solid var(--cc-border);
  border-radius: 18px;
  box-shadow: 0 24px 64px rgba(0,0,0,.45);
  padding: 2rem;
  font-family: 'Roboto', system-ui, sans-serif;
  transform: translateY(16px) scale(.98);
  transition: transform .35s cubic-bezier(.16,1,.3,1);
}
.gsr-cc-overlay.gsr-cc-visible .gsr-cc-modal { transform: none; }

.gsr-cc-modal-title {
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--cc-white);
  margin: 0 0 .5rem;
}
.gsr-cc-modal-intro {
  font-size: .9rem;
  line-height: 1.6;
  color: var(--cc-text);
  margin: 0 0 1.5rem;
}
.gsr-cc-modal-intro a { color: var(--cc-teal); text-decoration: underline; }

/* Catégories */
.gsr-cc-cat {
  border: 1px solid var(--cc-border);
  border-radius: 12px;
  padding: 1.1rem 1.25rem;
  margin-bottom: .9rem;
  background: rgba(255,255,255,.03);
}
.gsr-cc-cat-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}
.gsr-cc-cat-name {
  font-size: .98rem;
  font-weight: 700;
  color: var(--cc-white);
}
.gsr-cc-cat-desc {
  font-size: .82rem;
  line-height: 1.55;
  color: var(--cc-muted);
  margin: .5rem 0 0;
}

/* Interrupteur */
.gsr-cc-switch { position: relative; width: 44px; height: 24px; flex: 0 0 auto; }
.gsr-cc-switch input { position: absolute; opacity: 0; width: 100%; height: 100%; margin: 0; cursor: pointer; }
.gsr-cc-slider {
  position: absolute; inset: 0;
  background: rgba(255,255,255,.18);
  border-radius: 50px;
  transition: background .25s;
}
.gsr-cc-slider::before {
  content: '';
  position: absolute;
  height: 18px; width: 18px;
  left: 3px; top: 3px;
  background: #fff;
  border-radius: 50%;
  transition: transform .25s;
}
.gsr-cc-switch input:checked + .gsr-cc-slider { background: var(--cc-teal); }
.gsr-cc-switch input:checked + .gsr-cc-slider::before { transform: translateX(20px); }
.gsr-cc-switch input:disabled + .gsr-cc-slider { background: var(--cc-teal); opacity: .5; cursor: not-allowed; }
.gsr-cc-switch input:focus-visible + .gsr-cc-slider { outline: 2px solid var(--cc-teal); outline-offset: 2px; }

.gsr-cc-cat-locked {
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: var(--cc-teal);
  flex: 0 0 auto;
}

.gsr-cc-modal-actions {
  display: flex;
  flex-wrap: wrap;
  gap: .6rem;
  margin-top: 1.5rem;
}
.gsr-cc-modal-actions .gsr-cc-btn { flex: 1 1 40%; }

@media (max-width: 520px) {
  .gsr-cc-banner { left: .75rem; right: .75rem; margin: 0; max-width: none; }
  .gsr-cc-actions .gsr-cc-btn { flex: 1 1 100%; }
  .gsr-cc-btn-link { order: 3; }
}
