/* ================================================================
   VELARIO — cookie-consent.css v3
   Design allineato al sistema visivo V3 (stone, gold, Cormorant).
   Da caricare in OGNI pagina del sito, IT e EN.
   ================================================================ */

/* ── BANNER PRINCIPALE ── */
#vlr-cookie-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 9999;
    background: #0F0F0F;
    border-top: 1px solid rgba(201, 164, 76, 0.25);
    padding: 28px 80px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 40px;
    transform: translateY(100%);
    transition: transform 0.4s ease;
    box-shadow: 0 -8px 40px rgba(0,0,0,0.6);
}
#vlr-cookie-banner.visible {
    transform: translateY(0);
}

/* ── TESTO BANNER ── */
.vlr-cookie-text {
    flex: 1;
    min-width: 0;
}
.vlr-cookie-text p {
    font-family: 'Inter', system-ui, sans-serif;
    font-size: 12px;
    font-weight: 300;
    line-height: 1.75;
    color: rgba(245, 240, 232, 0.65);
    margin: 0;
}
.vlr-cookie-text a {
    color: rgba(201, 164, 76, 0.80);
    text-decoration: none;
    transition: color 0.3s ease;
}
.vlr-cookie-text a:hover {
    color: #C9A84C;
}

/* ── AZIONI BANNER ── */
.vlr-cookie-actions {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-shrink: 0;
}

/* Bottone Accetta tutti */
.vlr-btn-accept {
    display: inline-block;
    padding: 10px 24px;
    background: #C9A84C;
    color: #0A0A0A;
    border: 1px solid #C9A84C;
    font-family: 'Inter', system-ui, sans-serif;
    font-size: 10px;
    font-weight: 500;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    cursor: pointer;
    transition: background 0.3s ease, color 0.3s ease;
    white-space: nowrap;
}
.vlr-btn-accept:hover {
    background: #B8960C;
    border-color: #B8960C;
}

/* Bottone Solo necessari */
.vlr-btn-reject {
    display: inline-block;
    padding: 10px 24px;
    background: transparent;
    color: rgba(245, 240, 232, 0.50);
    border: 1px solid rgba(245, 240, 232, 0.20);
    font-family: 'Inter', system-ui, sans-serif;
    font-size: 10px;
    font-weight: 500;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    cursor: pointer;
    transition: all 0.3s ease;
    white-space: nowrap;
}
.vlr-btn-reject:hover {
    color: rgba(245, 240, 232, 0.90);
    border-color: rgba(245, 240, 232, 0.45);
}

/* Bottone Gestisci preferenze */
.vlr-btn-manage {
    background: none;
    border: none;
    font-family: 'Inter', system-ui, sans-serif;
    font-size: 10px;
    font-weight: 400;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: rgba(245, 240, 232, 0.35);
    cursor: pointer;
    padding: 4px 0;
    text-decoration: underline;
    text-decoration-color: transparent;
    transition: color 0.3s ease, text-decoration-color 0.3s ease;
    white-space: nowrap;
}
.vlr-btn-manage:hover {
    color: rgba(245, 240, 232, 0.65);
    text-decoration-color: rgba(245, 240, 232, 0.30);
}

/* ── MODAL PREFERENZE ── */
#vlr-cookie-modal {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 10000;
    background: rgba(0, 0, 0, 0.75);
    backdrop-filter: blur(4px);
    align-items: center;
    justify-content: center;
    padding: 24px;
}
#vlr-cookie-modal.open {
    display: flex;
}

.vlr-modal-inner {
    background: #111111;
    border: 1px solid rgba(201, 164, 76, 0.20);
    max-width: 560px;
    width: 100%;
    padding: 48px;
    position: relative;
    max-height: 90vh;
    overflow-y: auto;
}
.vlr-modal-inner::-webkit-scrollbar { width: 2px; }
.vlr-modal-inner::-webkit-scrollbar-thumb { background: rgba(201,164,76,0.3); }

.vlr-modal-title {
    font-family: 'Cormorant Garamond', Georgia, serif;
    font-size: 28px;
    font-weight: 300;
    color: #F5F0E8;
    margin-bottom: 8px;
}
.vlr-modal-subtitle {
    font-family: 'Inter', system-ui, sans-serif;
    font-size: 12px;
    font-weight: 300;
    color: rgba(245, 240, 232, 0.50);
    line-height: 1.7;
    margin-bottom: 36px;
}
.vlr-modal-subtitle a {
    color: rgba(201, 164, 76, 0.75);
    text-decoration: none;
}

/* Categoria cookie */
.vlr-cookie-cat {
    padding: 20px 0;
    border-top: 1px solid rgba(201, 164, 76, 0.10);
}
.vlr-cookie-cat:last-of-type {
    border-bottom: 1px solid rgba(201, 164, 76, 0.10);
    margin-bottom: 32px;
}
.vlr-cat-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 8px;
}
.vlr-cat-name {
    font-family: 'Inter', system-ui, sans-serif;
    font-size: 11px;
    font-weight: 500;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: #F5F0E8;
}
.vlr-cat-desc {
    font-family: 'Inter', system-ui, sans-serif;
    font-size: 11px;
    font-weight: 300;
    color: rgba(245, 240, 232, 0.45);
    line-height: 1.7;
}

/* Toggle switch */
.vlr-toggle {
    position: relative;
    flex-shrink: 0;
    width: 40px;
    height: 22px;
    margin-left: 16px;
}
.vlr-toggle input {
    opacity: 0;
    width: 0;
    height: 0;
    position: absolute;
}
.vlr-toggle-slider {
    position: absolute;
    inset: 0;
    background: rgba(245, 240, 232, 0.12);
    border: 1px solid rgba(245, 240, 232, 0.20);
    cursor: pointer;
    transition: background 0.3s ease;
}
.vlr-toggle-slider::before {
    content: '';
    position: absolute;
    width: 14px;
    height: 14px;
    background: rgba(245, 240, 232, 0.40);
    top: 3px;
    left: 3px;
    transition: transform 0.3s ease, background 0.3s ease;
}
.vlr-toggle input:checked + .vlr-toggle-slider {
    background: rgba(201, 164, 76, 0.25);
    border-color: rgba(201, 164, 76, 0.50);
}
.vlr-toggle input:checked + .vlr-toggle-slider::before {
    transform: translateX(18px);
    background: #C9A84C;
}
/* Necessari: sempre attivi, non modificabili */
.vlr-toggle input:disabled + .vlr-toggle-slider {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Azioni modal */
.vlr-modal-actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}
.vlr-modal-actions .vlr-btn-accept { flex: 1; text-align: center; }
.vlr-modal-actions .vlr-btn-reject { flex: 1; text-align: center; }

/* Chiudi modal */
.vlr-modal-close {
    position: absolute;
    top: 20px;
    right: 24px;
    background: none;
    border: none;
    font-size: 18px;
    color: rgba(245, 240, 232, 0.30);
    cursor: pointer;
    transition: color 0.3s ease;
    line-height: 1;
}
.vlr-modal-close:hover { color: rgba(245, 240, 232, 0.75); }

/* ── LINK "GESTISCI COOKIE" IN FOOTER ── */
.vlr-reopen-consent {
    background: none;
    border: none;
    font-family: 'Inter', system-ui, sans-serif;
    font-size: 10px;
    font-weight: 400;
    color: rgba(245, 240, 232, 0.28);
    letter-spacing: 0.1em;
    cursor: pointer;
    padding: 0;
    transition: color 0.3s ease;
    text-transform: uppercase;
}
.vlr-reopen-consent:hover { color: rgba(245, 240, 232, 0.65); }

/* ── RESPONSIVE ── */
@media (max-width: 768px) {
    #vlr-cookie-banner {
        flex-direction: column;
        align-items: flex-start;
        padding: 24px;
        gap: 20px;
    }
    .vlr-cookie-actions {
        flex-wrap: wrap;
        width: 100%;
    }
    .vlr-btn-accept,
    .vlr-btn-reject {
        flex: 1;
        text-align: center;
        min-width: 120px;
    }
    .vlr-modal-inner {
        padding: 32px 24px;
    }
    .vlr-modal-actions {
        flex-direction: column;
    }
}
