/* ═══════════════════════════════════════════════════════════
   COOKIE CONSENT — allineato ai design token del tema
═══════════════════════════════════════════════════════════ */

.pocca-cc {
    position: fixed;
    inset: auto 0 0 0;
    z-index: 99999;
    display: flex;
    justify-content: center;
    padding: 1rem;
    pointer-events: none;
}
.pocca-cc[hidden] { display: none; }

.pocca-cc-panel {
    pointer-events: auto;
    width: min(720px, 100%);
    max-height: calc(100vh - 2rem);
    overflow-y: auto;
    padding: 1.75rem;
    border-radius: var(--radius-md, 20px);
    border: 1px solid var(--border-subtle, rgba(255, 255, 255, 0.07));
    background: rgba(10, 6, 20, 0.92);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.55), 0 0 40px rgba(255, 0, 252, 0.08);
    animation: pocca-cc-in 0.5s var(--ease-out-expo, cubic-bezier(0.16, 1, 0.3, 1)) both;
}

@keyframes pocca-cc-in {
    from { opacity: 0; transform: translateY(24px); }
    to   { opacity: 1; transform: translateY(0); }
}

@media (prefers-reduced-motion: reduce) {
    .pocca-cc-panel { animation: none; }
}

.pocca-cc-title {
    font-size: 1.15rem;
    font-weight: 700;
    margin-bottom: 0.6rem;
    color: var(--text-primary, #f5f5f7);
}

.pocca-cc-text {
    font-size: 0.9rem;
    line-height: 1.65;
    color: var(--text-secondary, #a1a1a6);
    margin-bottom: 1.1rem;
}
.pocca-cc-text a { color: var(--primary, #ff00fc); text-decoration: underline; }

/* ── preferenze ── */

.pocca-cc-prefs {
    display: grid;
    gap: 0.75rem;
    margin-bottom: 1.1rem;
}
.pocca-cc-prefs[hidden] { display: none; }

.pocca-cc-opt {
    display: block;
    padding: 0.9rem 1rem;
    border-radius: var(--radius-sm, 12px);
    border: 1px solid var(--border-subtle, rgba(255, 255, 255, 0.07));
    background: var(--bg-glass, rgba(255, 255, 255, 0.04));
}
label.pocca-cc-opt { cursor: pointer; }

.pocca-cc-opt-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 0.3rem;
}

.pocca-cc-opt-name {
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--text-primary, #f5f5f7);
}

.pocca-cc-opt p {
    margin: 0;
    font-size: 0.82rem;
    line-height: 1.55;
    color: var(--text-tertiary, #6e6e73);
}

.pocca-cc-badge {
    font-size: 0.72rem;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    padding: 0.2rem 0.6rem;
    border-radius: 999px;
    color: var(--text-secondary, #a1a1a6);
    border: 1px solid var(--border-subtle, rgba(255, 255, 255, 0.07));
}

.pocca-cc-opt input[type="checkbox"] {
    appearance: none;
    -webkit-appearance: none;
    width: 44px;
    height: 24px;
    flex: 0 0 44px;
    border-radius: 999px;
    border: 1px solid var(--border-subtle, rgba(255, 255, 255, 0.07));
    background: rgba(255, 255, 255, 0.08);
    position: relative;
    cursor: pointer;
    transition: background 0.25s var(--ease-out-quart, ease);
}
.pocca-cc-opt input[type="checkbox"]::after {
    content: "";
    position: absolute;
    top: 2px;
    left: 2px;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: var(--text-primary, #f5f5f7);
    transition: transform 0.25s var(--ease-out-quart, ease);
}
.pocca-cc-opt input[type="checkbox"]:checked {
    background: var(--primary, #ff00fc);
    border-color: var(--primary, #ff00fc);
}
.pocca-cc-opt input[type="checkbox"]:checked::after { transform: translateX(20px); }
.pocca-cc-opt input[type="checkbox"]:focus-visible {
    outline: 2px solid var(--accent-cyan, #0dcaf0);
    outline-offset: 2px;
}

/* ── azioni ── */

.pocca-cc-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
}

.pocca-cc-btn {
    flex: 1 1 auto;
    min-height: 44px;
    padding: 0.7rem 1.3rem;
    border-radius: 999px;
    font-size: 0.9rem;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    border: 1px solid var(--border-subtle, rgba(255, 255, 255, 0.12));
    background: transparent;
    color: var(--text-primary, #f5f5f7);
    transition: all 0.3s var(--ease-out-quart, ease);
}
.pocca-cc-btn:hover {
    border-color: var(--primary, #ff00fc);
    color: var(--primary, #ff00fc);
}
.pocca-cc-btn:focus-visible {
    outline: 2px solid var(--accent-cyan, #0dcaf0);
    outline-offset: 2px;
}
.pocca-cc-btn[hidden] { display: none; }

/* "Accetta" e "Continua senza" hanno lo stesso peso visivo:
   il Garante chiede che rifiutare non sia piu' difficile che accettare. */
.pocca-cc-btn-primary {
    background: var(--primary, #ff00fc);
    border-color: var(--primary, #ff00fc);
    color: #0a0614;
}
.pocca-cc-btn-primary:hover {
    background: var(--text-primary, #f5f5f7);
    border-color: var(--text-primary, #f5f5f7);
    color: #0a0614;
}

.pocca-cc-btn-ghost {
    flex: 0 1 auto;
    background: none;
    border-color: transparent;
    color: var(--text-secondary, #a1a1a6);
    text-decoration: underline;
}

@media (max-width: 575.98px) {
    .pocca-cc { padding: 0.75rem; }
    .pocca-cc-panel { padding: 1.35rem; }
    .pocca-cc-btn { flex: 1 1 100%; }
}

/* ═══════════════════════════════════════════════════════════
   SEGNAPOSTO EMBED BLOCCATI (click-to-load)
═══════════════════════════════════════════════════════════ */

.cc-embed-placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    min-height: 450px;
    padding: 2rem 1.5rem;
    text-align: center;
    border: 1px dashed var(--border-subtle, rgba(255, 255, 255, 0.12));
    background: var(--bg-glass, rgba(255, 255, 255, 0.04));
}
.cc-embed-placeholder i { font-size: 2.5rem; color: var(--primary, #ff00fc); }
.cc-embed-placeholder h3 {
    font-size: 1.05rem;
    font-weight: 600;
    margin: 0;
    color: var(--text-primary, #f5f5f7);
}
.cc-embed-placeholder p {
    max-width: 46ch;
    margin: 0;
    font-size: 0.85rem;
    line-height: 1.6;
    color: var(--text-secondary, #a1a1a6);
}
.cc-embed-placeholder p a { color: var(--primary, #ff00fc); text-decoration: underline; }
.cc-embed-placeholder .pocca-cc-btn { flex: 0 0 auto; }

[data-cc-embed] iframe { display: block; border: 0; }

/* ═══════════════════════════════════════════════════════════
   INFORMATIVA SOTTO I FORM
═══════════════════════════════════════════════════════════ */

.form-privacy-note {
    margin-top: 1rem;
    font-size: 0.8rem;
    line-height: 1.6;
    color: var(--text-tertiary, #6e6e73);
}
.form-privacy-note a {
    color: var(--text-secondary, #a1a1a6);
    text-decoration: underline;
}
.form-privacy-note a:hover { color: var(--primary, #ff00fc); }
