/* ── Banner e pannello del consenso ────────────────────────────────────────
   Usa i token del sito: se cambia il colore del marchio, cambia anche qui
   senza toccare questo file. */

.me-cc,
.me-cc-modale { font-family: inherit; color: var(--text-body, #333); }

/* ── La barra in basso ─────────────────────────────────────────────────── */
.me-cc {
  position: fixed;
  inset: auto 0 0 0;
  z-index: 9000;
  background: var(--white, #fff);
  border-top: 1px solid var(--border-subtle, #E2E2E2);
  box-shadow: 0 -8px 32px rgba(0, 0, 0, .10);
  padding: 20px 24px calc(20px + env(safe-area-inset-bottom));
  /* Niente fill-mode 'both': con il riempimento all'indietro la barra resta
     fuori schermo finche' l'animazione non parte, e se non parte — scheda in
     secondo piano, browser che sospende le animazioni — non compare affatto.
     Il posto giusto e' quello predefinito; l'animazione e' solo l'ingresso. */
  animation: me-cc-su .28s ease-out;
}
@keyframes me-cc-su { from { transform: translateY(100%); } to { transform: none; } }
@media (prefers-reduced-motion: reduce) { .me-cc { animation: none; } }

.me-cc__dentro {
  max-width: 1140px; margin: 0 auto;
  display: flex; flex-wrap: wrap; align-items: center; gap: 16px 32px;
}
.me-cc__testo { flex: 1 1 420px; min-width: 0; font-size: 14.5px; line-height: 1.6; }
.me-cc__testo strong { display: block; margin-bottom: 4px; color: var(--text-heading, #1A1A1A); font-size: 15.5px; }
.me-cc__testo a { color: var(--text-link, #E91E63); }
.me-cc__azioni { flex: 0 0 auto; display: flex; flex-wrap: wrap; gap: 10px; }

/* ── I pulsanti ────────────────────────────────────────────────────────────
   "Rifiuta" ha lo stesso peso visivo di "Accetta": una scelta che si nota
   meno e' una scelta che non e' libera. */
.me-cc__btn {
  font: inherit; font-size: 14.5px; font-weight: 600;
  padding: 11px 22px; border-radius: 999px; border: 1px solid transparent;
  cursor: pointer; white-space: nowrap; transition: filter .15s, background .15s;
}
.me-cc__btn--si { background: var(--color-accent, #E91E63); color: #fff; }
.me-cc__btn--si:hover { filter: brightness(1.08); }
.me-cc__btn--no { background: var(--white, #fff); color: var(--text-heading, #1A1A1A); border-color: var(--border-strong, #CFCFCF); }
.me-cc__btn--no:hover { background: var(--gray-50, #F7F7F7); }
.me-cc__btn--terzo { background: none; border: none; color: var(--gray-700, #4A4A4A); text-decoration: underline; padding: 11px 6px; }
.me-cc__btn:focus-visible,
.me-cc__x:focus-visible { outline: 2px solid var(--color-accent, #E91E63); outline-offset: 2px; }

.me-cc__x {
  position: absolute; top: 8px; right: 10px;
  width: 32px; height: 32px; line-height: 1;
  background: none; border: none; cursor: pointer;
  font-size: 22px; color: var(--gray-500, #767676); border-radius: 50%;
}
.me-cc__x:hover { background: var(--gray-100, #EFEFEF); }

@media (max-width: 720px) {
  .me-cc { padding: 18px 18px calc(18px + env(safe-area-inset-bottom)); max-height: 82vh; overflow-y: auto; }
  .me-cc__azioni { width: 100%; }
  .me-cc__azioni .me-cc__btn--si,
  .me-cc__azioni .me-cc__btn--no { flex: 1 1 0; text-align: center; }
}

/* ── Il pannello con le scelte una per una ─────────────────────────────── */
.me-cc-modale {
  position: fixed; inset: 0; z-index: 9100;
  display: flex; align-items: center; justify-content: center;
  padding: 20px; background: rgba(26, 26, 26, .55);
}
.me-cc-modale__foglio {
  background: var(--white, #fff); border-radius: 16px;
  width: min(620px, 100%); max-height: 86vh; overflow-y: auto;
  padding: 28px; position: relative;
  box-shadow: 0 24px 64px rgba(0, 0, 0, .3);
}
.me-cc-modale h2 { margin: 0 0 6px; font-size: 21px; color: var(--text-heading, #1A1A1A); }
.me-cc-modale__intro { margin: 0 0 20px; font-size: 14.5px; line-height: 1.6; color: var(--gray-700, #4A4A4A); }
.me-cc-modale__intro a { color: var(--text-link, #E91E63); }

.me-cc-voce {
  border: 1px solid var(--border-subtle, #E2E2E2); border-radius: 12px;
  padding: 16px 18px; margin-bottom: 12px;
}
.me-cc-voce__capo { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.me-cc-voce__nome { font-weight: 600; font-size: 15px; color: var(--text-heading, #1A1A1A); }
.me-cc-voce p { margin: 8px 0 0; font-size: 13.5px; line-height: 1.6; color: var(--gray-700, #4A4A4A); }
.me-cc-voce__sempre { font-size: 13px; color: var(--gray-500, #767676); white-space: nowrap; }

/* interruttore */
.me-cc-int { position: relative; flex: 0 0 auto; width: 46px; height: 26px; }
.me-cc-int input { position: absolute; opacity: 0; width: 100%; height: 100%; margin: 0; cursor: pointer; }
.me-cc-int span {
  position: absolute; inset: 0; border-radius: 999px;
  background: var(--gray-300, #CFCFCF); transition: background .18s; pointer-events: none;
}
.me-cc-int span::after {
  content: ""; position: absolute; top: 3px; left: 3px;
  width: 20px; height: 20px; border-radius: 50%; background: #fff;
  transition: transform .18s; box-shadow: 0 1px 3px rgba(0, 0, 0, .3);
}
.me-cc-int input:checked + span { background: var(--color-accent, #E91E63); }
.me-cc-int input:checked + span::after { transform: translateX(20px); }
.me-cc-int input:focus-visible + span { outline: 2px solid var(--color-accent, #E91E63); outline-offset: 2px; }

.me-cc-modale__piede { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 20px; }
.me-cc-modale__piede .me-cc__btn { flex: 1 1 auto; }

.me-cc-blocca { overflow: hidden; }
