.cookie-consent {
  position: fixed;
  z-index: 10000;
  right: 18px;
  bottom: 18px;
  left: auto;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 18px;
  align-items: end;
  width: min(620px, calc(100% - 36px));
  margin: 0 auto;
  padding: 16px 18px;
  color: #173638;
  background: #f8f5ef;
  border: 1px solid rgba(20, 78, 79, 0.24);
  border-top: 3px solid #155455;
  border-radius: 12px;
  box-shadow: 0 22px 70px rgba(16, 48, 49, 0.24);
  font-family: inherit;
}

.cookie-consent__copy {
  min-width: 0;
  max-width: 440px;
}

.cookie-consent__eyebrow {
  margin: 0 0 4px;
  color: #155455;
  font-size: 0.62rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.cookie-consent h2 {
  margin: 0 0 5px;
  color: #123f40;
  font-size: clamp(1.05rem, 2vw, 1.25rem);
  line-height: 1.2;
}

.cookie-consent p {
  margin: 0;
  font-size: 0.82rem;
  line-height: 1.4;
}

.cookie-consent__current {
  margin-top: 6px !important;
  font-weight: 700;
}

.cookie-consent__note {
  margin-top: 5px !important;
  color: #526869;
  font-size: 0.72rem !important;
}

.cookie-consent__actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(96px, 1fr));
  gap: 8px;
  min-width: 200px;
}

.cookie-consent__actions button {
  min-height: 40px;
  padding: 8px 12px;
  color: #fff;
  background: #155455;
  border: 2px solid #155455;
  border-radius: 999px;
  font: inherit;
  font-size: 0.78rem;
  font-weight: 800;
  cursor: pointer;
  transition: background-color 160ms ease, border-color 160ms ease, box-shadow 160ms ease;
}

.cookie-consent__actions button:hover {
  background: #0f4445;
  border-color: #0f4445;
}

.cookie-consent__actions button:focus-visible,
.cookie-settings:focus-visible {
  outline: 3px solid #dba43b;
  outline-offset: 3px;
}

.cookie-settings {
  padding: 0;
  color: inherit;
  background: transparent;
  border: 0;
  font: inherit;
  text-decoration: underline;
  text-underline-offset: 3px;
  cursor: pointer;
}

@media (max-width: 760px) {
  .cookie-consent {
    right: 14px;
    bottom: 14px;
    left: 14px;
    grid-template-columns: 1fr;
    gap: 12px;
    width: auto;
    padding: 14px 15px;
    border-radius: 11px;
  }

  .cookie-consent__actions {
    display: flex;
    min-width: 0;
  }

  .cookie-consent__actions button { flex: 1 1 0; }
}

@media (max-width: 430px) {
  .cookie-consent__actions {
    grid-template-columns: 1fr 1fr;
  }
}

@media (prefers-reduced-motion: reduce) {
  .cookie-consent__actions button {
    transition: none;
  }
}

/* Bandeau discret pleine largeur : les préférences restent accessibles sans
   masquer le contenu, y compris sur les petits écrans. */
.cookie-consent {
  right: 0;
  bottom: 0;
  left: 0;
  width: 100%;
  max-width: none;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  padding: 14px clamp(16px, 4vw, 48px);
  border-right: 0;
  border-bottom: 0;
  border-left: 0;
  border-radius: 0;
  box-shadow: 0 -12px 36px rgba(16, 48, 49, .16);
}

.cookie-consent__copy { max-width: 760px; }
.cookie-consent h2 { font-size: 1.05rem; }
.cookie-consent__note { display: none; }

@media (max-width: 760px) {
  .cookie-consent {
    right: 0;
    bottom: 0;
    left: 0;
    grid-template-columns: 1fr;
    gap: 10px;
    padding: 12px 16px calc(12px + env(safe-area-inset-bottom));
  }
  .cookie-consent__copy { max-width: none; }
  .cookie-consent__eyebrow { font-size: .58rem; }
  .cookie-consent p { font-size: .76rem; }
  .cookie-consent h2 { margin-bottom: 3px; font-size: .98rem; }
}

/* Version compacte : une bande informative, pas une fenêtre qui prend la
   moitié de l’écran. L’état de gestion conserve les boutons détaillés. */
.cookie-consent {
  gap: 12px;
  padding-top: 9px;
  padding-bottom: 9px;
}
.cookie-consent__eyebrow { display: none; }
.cookie-consent h2 { margin-bottom: 2px; font-size: .94rem; }
.cookie-consent p { font-size: .76rem; line-height: 1.3; }
.cookie-consent__actions button { min-height: 34px; padding: 6px 11px; font-size: .73rem; }
.cookie-consent--manage h2 { color: #123f40; }
@media (max-width: 760px) {
  .cookie-consent { gap: 7px; padding-top: 8px; padding-bottom: 8px; }
  .cookie-consent h2 { font-size: .88rem; }
  .cookie-consent p { font-size: .7rem; }
  .cookie-consent__actions button { min-height: 32px; padding: 5px 9px; }
}
