@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@400;500;600;700;800&display=swap');

:root {
    --bg-dark: #050505;
    --text-white: #ffffff;
    --text-gray: #d1d1d1;
    --primary-glow: #00c455; 
    --secondary-glow: #00ffd5; 
}

/* 1. RESET & STRUTTURA */
html, body {
    margin: 0 !important; padding: 0 !important; width: 100% !important; height: 100% !important;
    background-color: var(--bg-dark) !important; overflow: hidden !important; 
    font-family: 'Plus Jakarta Sans', sans-serif; 
}

.aff-page-container { 
    position: fixed !important; top: 0; left: 0; 
    width: 100vw; height: 100vh; background: var(--bg-dark);
    z-index: 999999; overflow-y: auto; display: block;
    scroll-behavior: smooth;
}

.aff-scroll-content { position: relative; width: 100%; display: flex; flex-direction: column; align-items: center; z-index: 10; }
.aff-page-container * { box-sizing: border-box; }

/* =========================================
   2. LUCI E BACKGROUND (Ora più visibili!)
   ========================================= */
.aff-aurora-bg-fixed {
    position: fixed; top: 0; left: 0; width: 100%; height: 100%;
    z-index: 0; overflow: hidden; pointer-events: none;
    opacity: 0.35; /* Alzato per maggiore colore */
    mix-blend-mode: screen;
}

.aff-blob {
    position: absolute; border-radius: 50%; filter: blur(120px);
    transition: background 1s ease-in-out;
}

.blob-1 { top: -10%; left: -10%; width: 50vw; height: 50vw; background: var(--primary-glow); animation: float 12s infinite alternate; }
.blob-2 { bottom: 10%; right: -10%; width: 40vw; height: 40vw; background: var(--secondary-glow); animation: float 15s infinite alternate-reverse; }
.blob-3 { top: 40%; left: 30%; width: 30vw; height: 30vw; background: var(--primary-glow); opacity: 0.5; animation: float 10s infinite alternate; }

@keyframes float {
    0% { transform: translate(0, 0) scale(1); }
    100% { transform: translate(50px, 50px) scale(1.1); }
}

/* =========================================
   3. NAVBAR "FLOATING PILL" & HERO
   ========================================= */
.aff-navbar {
    width: 92% !important; max-width: 1100px !important; 
    padding: 12px 25px !important;
    margin: 25px auto 0 auto !important; /* La stacca dal tetto dello schermo */
    display: flex; justify-content: space-between; align-items: center;
    background: rgba(20, 20, 20, 0.6) !important; /* Vetro scuro leggero */
    backdrop-filter: blur(25px); -webkit-backdrop-filter: blur(25px);
    position: sticky; top: 20px; z-index: 1000;
    border: 1px solid rgba(255,255,255,0.08) !important; /* Bordino luce */
    border-radius: 50px !important; /* Arrotonda i lati (Pillola) */
    box-shadow: 0 15px 35px rgba(0,0,0,0.4) !important;
    transition: all 0.4s ease;
}
/* Stile del Logo Immagine */
.aff-logo-link { display: flex; align-items: center; }
.aff-logo-img { 
    height: 32px; /* Altezza perfetta ed elegante */
    width: auto; 
    display: block;
    transition: transform 0.3s;
}
.aff-logo-img:hover { transform: scale(1.05); }

.aff-nav-links { display: flex; gap: 20px; align-items: center; }

/* Adattamento per i Telefoni (Piccola pillola compatta) */
@media (max-width: 768px) {
    .aff-navbar { 
        width: 95% !important; padding: 10px 18px !important; 
        margin: 15px auto 0 auto !important; top: 15px; 
    }
    .aff-logo-img { height: 24px; } /* Rimpicciolisce il logo su mobile */
}

.aff-btn-outline { padding: 10px 20px; border: 2px solid rgba(255,255,255,0.2); border-radius: 50px; }
.aff-btn-outline:hover { border-color: var(--primary-glow); }
.aff-btn-fill { padding: 12px 25px; background: var(--text-white); color: #000 !important; border-radius: 50px; font-weight: 700; box-shadow: 0 4px 15px rgba(255,255,255,0.2); }
.aff-btn-fill:hover { transform: translateY(-2px); box-shadow: 0 6px 20px rgba(255,255,255,0.4); }

.aff-hero { width: 100%; padding: 80px 20px 40px 20px; display: flex; flex-direction: column; align-items: center; text-align: center; }
.aff-content { max-width: 800px; position: relative; z-index: 2; }

/* Testo Gradient */
.text-gradient {
    background: linear-gradient(90deg, var(--primary-glow), var(--secondary-glow));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    display: inline-block;
}

.aff-hero h1 { font-size: 4rem; font-weight: 800; line-height: 1.1; margin: 30px 0 20px 0; color: var(--text-white); letter-spacing: -2px; }
.aff-hero p { font-size: 1.3rem; color: var(--text-gray); line-height: 1.6; margin-bottom: 40px; font-weight: 500; }

/* =========================================
   4. SWITCHER (Cerco / Offro) - FIXATO
   ========================================= */
.aff-switch {
    display: inline-flex; background: rgba(255,255,255,0.05); padding: 5px; border-radius: 50px;
    position: relative; border: 1px solid rgba(255,255,255,0.1); margin-bottom: 20px;
}
.aff-switch-btn {
    width: 170px; /* Larghezza fissa per entrambi! */
    padding: 15px 0; font-size: 1.1rem; font-weight: 700; color: #888; background: transparent;
    border: none; border-radius: 50px; cursor: pointer; position: relative; z-index: 2; transition: 0.4s;
}
.aff-switch-btn.active { color: #000; }
.aff-switch-bg {
    position: absolute; top: 5px; left: 5px; width: 170px; height: calc(100% - 10px);
    background: var(--text-white); border-radius: 50px; transition: transform 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55); z-index: 1;
}

.aff-main-cta {
    display: inline-block; padding: 20px 50px; font-size: 1.2rem; font-weight: 800;
    color: #fff; background: var(--primary-glow); text-decoration: none; border-radius: 50px;
    transition: 0.4s; box-shadow: 0 10px 30px rgba(0,0,0,0.5); border: 2px solid transparent;
}
.aff-main-cta:hover { transform: translateY(-5px); filter: brightness(1.2); box-shadow: 0 15px 40px var(--primary-glow); }

/* =========================================
   5. SEZIONE: COME FUNZIONA (Nuova!)
   ========================================= */
.aff-how-section {
    width: 100%; max-width: 1200px; padding: 80px 20px;
    display: flex; flex-direction: column; align-items: center;
}

.aff-how-title { font-size: 2.5rem; font-weight: 800; margin-bottom: 50px; text-align: center; }

.aff-grid {
    display: grid; grid-template-columns: repeat(3, 1fr); gap: 30px; width: 100%;
}

/* Glassmorphism Cards */
.aff-glass-card {
    background: rgba(20, 20, 20, 0.6);
    backdrop-filter: blur(15px); -webkit-backdrop-filter: blur(15px);
    border: 1px solid rgba(255,255,255,0.05);
    border-top: 1px solid var(--primary-glow); /* Linea colorata sopra */
    border-radius: 20px;
    padding: 40px 30px;
    text-align: left;
    transition: 0.3s;
    box-shadow: 0 15px 35px rgba(0,0,0,0.2);
}

.aff-glass-card:hover { transform: translateY(-10px); box-shadow: 0 20px 50px rgba(0,0,0,0.5); border-color: rgba(255,255,255,0.1); border-top-color: var(--secondary-glow); }

.card-icon {
    width: 60px; height: 60px; border-radius: 16px;
    background: rgba(255,255,255,0.05); color: var(--primary-glow);
    display: flex; align-items: center; justify-content: center;
    font-size: 1.8rem; margin-bottom: 25px;
    border: 1px solid rgba(255,255,255,0.1);
    transition: color 0.4s;
}

.aff-glass-card h3 { font-size: 1.4rem; margin-bottom: 15px; color: #fff; }
.aff-glass-card p { font-size: 1rem; color: #aaa; line-height: 1.6; }

/* =========================================
   6. MODALITA' MOBILE
   ========================================= */
@media (max-width: 768px) {
    .aff-hero h1 { font-size: 2.8rem; }
    .aff-hero p { font-size: 1.1rem; }
    .aff-navbar { padding: 15px 20px; }
    .aff-nav-links a.aff-btn-outline { display: none; } /* Nasconde bottone secondario per spazio */
    .aff-switch { transform: scale(0.9); }
    .aff-grid { grid-template-columns: 1fr; gap: 20px; }
    .aff-glass-card { padding: 30px 20px; }
    .blob-1 { width: 80vw; height: 80vw; }
    .blob-2 { width: 70vw; height: 70vw; }
}

/* Popup Auth Restano Nascosti all'inizio */
.aff-modal-overlay { display: none; }

/* FIX MODALE SOPRA A TUTTO */
.aff-modal-overlay { z-index: 9999999 !important; }

/* =========================================
   7. NUOVE SEZIONI LUNGHE E ANIMAZIONI
   ========================================= */
/* Animazione allo scroll */
.aff-reveal {
    opacity: 0;
    transform: translateY(60px);
    transition: all 0.8s cubic-bezier(0.5, 0, 0, 1);
}
.aff-reveal.active {
    opacity: 1;
    transform: translateY(0);
}

.aff-features-section { width: 100%; max-width: 1200px; padding: 100px 20px; margin: 0 auto; }
.aff-features-container { display: flex; align-items: center; gap: 60px; }
.aff-feature-text { flex: 1; }
.aff-feature-image { flex: 1; display: flex; justify-content: center; }

.aff-feature-list { list-style: none; padding: 0; margin: 0; }
.aff-feature-list li { display: flex; align-items: flex-start; gap: 15px; margin-bottom: 25px; font-size: 1.05rem; color: #ddd; line-height: 1.5; }
.feat-icon { font-size: 1.5rem; background: rgba(255,255,255,0.05); padding: 10px; border-radius: 12px; border: 1px solid rgba(255,255,255,0.1); }

.aff-mockup-card {
    background: rgba(20,20,20,0.8); border: 1px solid rgba(255,255,255,0.1); border-radius: 24px;
    padding: 30px; width: 100%; max-width: 400px; box-shadow: 0 30px 60px rgba(0,0,0,0.6);
    transform: perspective(1000px) rotateY(-10deg) rotateX(5deg);
    transition: transform 0.5s;
}
.aff-mockup-card:hover { transform: perspective(1000px) rotateY(0deg) rotateX(0deg); }

.aff-bottom-cta {
    width: 100%; max-width: 1000px; margin: 50px auto 100px auto; padding: 60px 40px;
    background: linear-gradient(135deg, rgba(20,20,20,0.9), rgba(5,5,5,0.9));
    border-radius: 30px; text-align: center; border: 1px solid rgba(255,255,255,0.05);
    box-shadow: 0 20px 50px rgba(0,0,0,0.5); position: relative; overflow: hidden;
}
.aff-bottom-cta::before {
    content: ''; position: absolute; top: 0; left: 0; width: 100%; height: 4px;
    background: linear-gradient(90deg, var(--primary-glow), var(--secondary-glow));
}
.aff-bottom-cta h2 { font-size: 2.5rem; margin-bottom: 20px; color: #fff; }
.aff-bottom-cta p { font-size: 1.2rem; color: #aaa; margin-bottom: 30px; }

@media (max-width: 768px) {
    .aff-features-container { flex-direction: column; gap: 40px; }
    .aff-mockup-card { transform: none; }
    .aff-bottom-cta h2 { font-size: 2rem; }
}

/* =========================================
   8. FIX CONFLITTI TEMA & HOVER BOTTONI
   ========================================= */
/* Forza la visibilità di tutti i titoli e sottotitoli contro il tema WP */
.aff-page-container h1, 
.aff-page-container h2, 
.aff-page-container h3, 
.aff-page-container h4 {
    color: #ffffff !important;
    position: relative;
    z-index: 2;
}
.aff-page-container p {
    color: #d1d1d1 !important;
}

/* Fix Bottone CTA: Hover Premium senza sbavature */
.aff-main-cta {
    display: inline-flex !important; 
    align-items: center; 
    justify-content: center; 
    gap: 10px;
    color: #ffffff !important;
}
.aff-main-cta:hover {
    transform: translateY(-5px);
    background: var(--secondary-glow) !important; /* Cambia colore, niente filtri strani */
    color: #000000 !important; /* Testo nero su hover per massimo contrasto */
    box-shadow: 0 15px 40px var(--secondary-glow) !important;
    border-color: transparent !important;
}

/* Allineamento perfetto per le nuove icone SVG nello switcher */
.aff-switch-btn {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    gap: 8px;
}
.aff-switch-btn svg {
    margin-bottom: 2px;
}

/* =========================================
   9. ESPANSIONE LARGHEZZA SCHERMO
   ========================================= */
/* Allarghiamo la navbar e le sezioni per sfruttare i monitor grandi */
.aff-navbar, 
.aff-how-section {
    max-width: 1500px !important; /* Da 1200px a 1500px */
    width: 96% !important; /* Prende quasi tutto lo schermo */
}

/* =========================================
   10. STILE MODALE LOGIN (Vetro e Neon)
   ========================================= */
.aff-modal-overlay {
    position: fixed; top: 0; left: 0; width: 100vw; height: 100vh;
    background: rgba(0, 0, 0, 0.85); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
    display: none; align-items: center; justify-content: center;
    z-index: 9999999 !important; padding: 20px;
}

.aff-modal-box {
    background: rgba(15, 15, 15, 0.85);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-top: 2px solid var(--primary-glow); /* Righina neon in cima */
    border-radius: 24px; padding: 40px; 
    width: 100%; max-width: 420px;
    position: relative; 
    box-shadow: 0 30px 60px rgba(0,0,0,0.7);
    color: #fff;
    animation: modalPopUp 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

@keyframes modalPopUp {
    0% { transform: scale(0.9) translateY(20px); opacity: 0; }
    100% { transform: scale(1) translateY(0); opacity: 1; }
}

/* Bottone X di chiusura: Area di click ingrandita e centrata */
.aff-modal-close {
    position: absolute; top: 15px; right: 15px; 
    background: transparent; border: none; color: #888;
    cursor: pointer; transition: 0.3s;
    width: 45px; height: 45px; /* Area bella grande per i polpastrelli */
    display: flex; align-items: center; justify-content: center;
    border-radius: 50%;
}
.aff-modal-close:hover { 
    color: #ff4d4d; 
    background: rgba(255,77,77,0.1); 
    transform: rotate(90deg); 
}

/* Input del Login */
.aff-modal-box .aff-input-group { margin-bottom: 20px; }

.aff-modal-box input {
    width: 100%; 
    padding: 15px 20px; 
    border-radius: 12px;
    background: rgba(0,0,0,0.5); 
    border: 1px solid rgba(255,255,255,0.1);
    color: #ffffff !important; /* FORZA IL BIANCO E BLOCCA IL TEMA */
    font-size: 1rem; 
    outline: none; 
    transition: 0.3s;
}

/* Colore del testo finto di suggerimento (es. tu@email.com) */
.aff-modal-box input::placeholder {
    color: #888888 !important; 
    opacity: 1;
}

.aff-modal-box input:focus { 
    border-color: var(--primary-glow); 
    background: rgba(0,0,0,0.8); 
}

/* Bottone Accedi: Hover corretto senza sfondi invisibili */
.aff-btn-submit {
    width: 100%; padding: 16px; margin-top: 10px;
    background: var(--primary-glow) !important; color: #fff !important;
    border: 2px solid transparent !important; border-radius: 50px; 
    font-weight: 800; font-size: 1.1rem;
    cursor: pointer; transition: all 0.3s ease; 
    box-shadow: 0 10px 25px rgba(0,0,0,0.3);
    display: flex; align-items: center; justify-content: center; gap: 8px; /* Per l'SVG */
}
.aff-btn-submit:hover { 
    background: var(--secondary-glow) !important; /* Si accende del colore secondario */
    color: #000 !important; /* Testo nero a contrasto */
    transform: translateY(-3px); 
    box-shadow: 0 15px 35px var(--secondary-glow) !important;
}

/* =========================================
   11. SEZIONE TELEGRAM E ANIMAZIONE RADAR (OTTIMIZZATA)
   ========================================= */
.aff-telegram-section {
    width: 100%; max-width: 1200px; padding: 40px 20px; margin: 0 auto;
}

.aff-telegram-glass {
    display: flex; align-items: center; justify-content: space-between; gap: 50px;
    background: linear-gradient(135deg, rgba(0, 136, 204, 0.15) 0%, rgba(20,20,20,0.8) 100%);
    backdrop-filter: blur(15px); -webkit-backdrop-filter: blur(15px);
    border: 1px solid rgba(0, 136, 204, 0.3); border-radius: 24px;
    padding: 50px; box-shadow: 0 20px 50px rgba(0,0,0,0.5);
    position: relative; overflow: hidden;
}

.aff-telegram-glass::before {
    content: ''; position: absolute; top: -50px; left: -50px; width: 200px; height: 200px;
    background: #0088cc; filter: blur(100px); opacity: 0.3; z-index: 0; pointer-events: none;
}

.aff-tg-text { flex: 1.5; position: relative; z-index: 2; }
.aff-tg-visual { flex: 1; display: flex; justify-content: center; align-items: center; position: relative; z-index: 2; }

.aff-tg-list { list-style: none; padding: 0; margin: 0; }
.aff-tg-list li { display: flex; align-items: center; gap: 12px; margin-bottom: 15px; font-size: 1.05rem; color: #ddd; font-weight: 500; }

/* --- FIX CENTRATURA ICONA TELEGRAM --- */
.tg-icon-wrapper {
    background: #0088cc; width: 90px; height: 90px; border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    box-shadow: 0 0 30px rgba(0, 136, 204, 0.8); z-index: 5;
    position: relative;
}
/* Spingiamo l'aeroplanino per compensare il suo peso visivo sbilanciato */
.tg-icon-wrapper svg {
    margin-right: 4px; 
    margin-top: 2px;
}

/* --- FIX RADAR: ANIMAZIONE FLUIDA (GPU ACCELERATED) --- */
.tg-radar-box { position: relative; width: 160px; height: 160px; display: flex; align-items: center; justify-content: center; }

.tg-radar-circle {
    position: absolute; top: 50%; left: 50%; 
    transform: translate(-50%, -50%) scale(1); /* Usa la Scala, non la Width! */
    width: 90px; height: 90px; border-radius: 50%;
    border: 2px solid #0088cc; opacity: 0;
    will-change: transform, opacity; /* Dice al telefono di usare la scheda video */
}

/* Animazione perfetta, fluida fino allo zero assoluto */
.wave-1 { animation: radarScan 3s infinite ease-out; }
.wave-2 { animation: radarScan 3s infinite ease-out 1.5s; }

@keyframes radarScan {
    0% { transform: translate(-50%, -50%) scale(1); opacity: 0.8; }
    100% { transform: translate(-50%, -50%) scale(3.5); opacity: 0; }
}

/* =========================================
   12. ANIMAZIONI DI ENTRATA ALLO SCROLL (MOBILE & DESKTOP)
   ========================================= */
/* Prepariamo le card ad essere invisibili e abbassate */
.aff-glass-card, .aff-mockup-card, .aff-telegram-glass {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.8s ease-out, transform 0.8s cubic-bezier(0.2, 0.8, 0.2, 1);
}

/* Quando lo JS aggiunge la classe 'active' scivolano su morbidamente */
.aff-glass-card.active, .aff-mockup-card.active, .aff-telegram-glass.active {
    opacity: 1;
    transform: translateY(0);
}

/* Solo su Computer: permettiamo alla card di fare l'animazione di Hover, 
   sovrascrivendo l'animazione di entrata quando il mouse passa sopra */
@media (min-width: 769px) {
    .aff-glass-card.active:hover {
        transform: translateY(-10px);
        box-shadow: 0 20px 50px rgba(0,0,0,0.5); 
        border-color: rgba(255,255,255,0.1); 
        border-top-color: var(--secondary-glow);
    }
    .aff-mockup-card.active:hover {
        transform: perspective(1000px) rotateY(0deg) rotateX(0deg);
    }
}

@media (max-width: 768px) {
    .aff-telegram-glass { flex-direction: column; padding: 30px 25px; text-align: center; gap: 30px; }
    .aff-tg-list li { justify-content: center; }
    .aff-telegram-glass::before { display: none; }
}

/* =========================================
   13. SEZIONE CONTATORI (FOMO ANIMATO)
   ========================================= */
.aff-counters-section {
    width: 100%; max-width: 1100px; padding: 20px; margin: 20px auto 60px auto;
}

.aff-counters-grid {
    display: grid; grid-template-columns: repeat(3, 1fr); gap: 30px;
    background: rgba(20,20,20,0.5); border: 1px solid rgba(255,255,255,0.05);
    border-radius: 24px; padding: 40px; box-shadow: 0 15px 35px rgba(0,0,0,0.3);
    text-align: center; backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
}

.aff-counter-item { 
    display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; 
}

.aff-counter-num {
    font-size: 3.5rem; /* Leggermente più piccolo */
    font-weight: 600; /* Più sottile ed elegante, meno massiccio */
    color: var(--primary-glow);
    line-height: 1; 
    text-shadow: 0 0 10px rgba(0,0,0,0.5); /* Ombra scura per staccare dal fondo, niente bagliori esagerati */
    display: flex; align-items: center; justify-content: center;
    transition: color 0.4s;
    letter-spacing: -1px; /* Stringe i numeri per un look tech */
}

.aff-counter-text { 
    font-size: 1.1rem; color: #aaa; font-weight: 600; 
}

/* Modalità Mobile */
@media (max-width: 768px) {
    .aff-counters-section { margin: 10px auto 40px auto; }
    .aff-counters-grid { grid-template-columns: 1fr; padding: 40px 20px; gap: 40px; }
    .aff-counter-num { font-size: 3rem; }
}

/* =========================================
   14. SEZIONE RECENSIONI (STILE CHAT)
   ========================================= */
.aff-reviews-section {
    width: 100%; max-width: 800px; padding: 20px; margin: 40px auto 80px auto;
}

.aff-reviews-title {
    text-align: center; font-size: 2.2rem; font-weight: 800; margin-bottom: 40px; color: #fff;
}

.aff-chat-container {
    display: flex; flex-direction: column; gap: 20px;
}

/* Stile Base Fumetto */
.aff-chat-bubble {
    background: rgba(30, 30, 30, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.05);
    padding: 20px; max-width: 85%; color: #e0e0e0;
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
    backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
    transition: transform 0.3s;
}
.aff-chat-bubble:hover { transform: translateY(-5px); }

/* Fumetto a Sinistra (Utente 1) */
.aff-chat-bubble.left {
    align-self: flex-start;
    border-radius: 20px 20px 20px 4px;
    border-left: 3px solid var(--primary-glow);
}

/* Fumetto a Destra (Utente 2) */
.aff-chat-bubble.right {
    align-self: flex-end;
    border-radius: 20px 20px 4px 20px;
    background: rgba(255, 255, 255, 0.05);
    border-right: 3px solid var(--secondary-glow);
}

/* Testi interni */
.chat-header {
    display: flex; justify-content: space-between; align-items: center;
    margin-bottom: 10px; border-bottom: 1px solid rgba(255,255,255,0.05); padding-bottom: 8px;
}
.chat-header strong {
    color: #fff; font-weight: 700; display: flex; align-items: center; gap: 6px; font-size: 0.95rem;
}
.chat-header strong svg { fill: var(--primary-glow); transition: fill 0.4s; }
.chat-time {
    font-size: 0.75rem; color: #888; font-weight: 500;
}
.chat-body { font-size: 1.05rem; line-height: 1.5; color: #ccc; }

@media (max-width: 768px) {
    .aff-chat-bubble { max-width: 95%; padding: 15px; }
    .chat-body { font-size: 0.95rem; }
}

/* =========================================
   15. SEZIONE FAQ (ACCORDION)
   ========================================= */
.aff-faq-section {
    width: 100%; max-width: 800px; padding: 20px; margin: 40px auto 80px auto;
}

.aff-faq-title {
    text-align: center; font-size: 2.2rem; font-weight: 800; margin-bottom: 40px; color: #fff;
}

.aff-faq-container {
    display: flex; flex-direction: column; gap: 15px;
}

.aff-faq-item {
    background: rgba(30, 30, 30, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 16px;
    overflow: hidden;
    transition: background 0.3s, border-color 0.3s;
    backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
}
.aff-faq-item:hover {
    background: rgba(30, 30, 30, 0.7);
    border-color: rgba(255, 255, 255, 0.15);
}

.aff-faq-question {
    width: 100%; text-align: left; padding: 25px;
    background: transparent; border: none; color: #fff;
    font-size: 1.15rem; font-weight: 700; cursor: pointer;
    display: flex; justify-content: space-between; align-items: center;
    font-family: inherit; transition: color 0.3s;
}

.aff-faq-question:hover { color: var(--primary-glow); }

.faq-icon {
    transition: transform 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    min-width: 24px; color: var(--primary-glow);
}

.aff-faq-answer {
    max-height: 0; 
    overflow: hidden;
    transition: max-height 0.4s cubic-bezier(0.2, 0.8, 0.2, 1);
}

/* Lo spazio lo diamo al div interno, non al testo! */
.aff-faq-inner {
    padding: 0 25px 25px 25px;
}

.aff-faq-answer p {
    padding: 0; margin: 0;
    color: #bbb !important; font-size: 1.05rem; line-height: 1.6;
}

/* Stato Attivo (Aperto) */
.aff-faq-item.active {
    background: rgba(20, 20, 20, 0.8);
    border-color: var(--primary-glow);
}
.aff-faq-item.active .faq-icon {
    transform: rotate(180deg);
}

@media (max-width: 768px) {
    .aff-faq-question { font-size: 1.05rem; padding: 20px; }
    .aff-faq-inner { padding: 0 20px 20px 20px; }
    .aff-faq-answer p { font-size: 0.95rem; }
}

/* =========================================
   16. FOOTER PREMIUM CORPORATE
   ========================================= */
.aff-footer {
    width: 100%;
    background: linear-gradient(180deg, rgba(10,10,10,0.6) 0%, rgba(5,5,5,1) 100%);
    border-top: 1px solid rgba(255,255,255,0.05);
    padding: 80px 20px 30px 20px;
    margin-top: 60px;
    backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px);
}

.aff-footer-container {
    max-width: 1200px; margin: 0 auto;
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1.5fr; /* Proporzioni delle 4 colonne */
    gap: 40px;
}

/* Colonna Brand */
.aff-footer-logo {
    height: 35px; margin-bottom: 20px;
    filter: grayscale(100%) brightness(150%);
    transition: filter 0.4s ease, transform 0.4s ease;
}
.aff-footer-logo:hover {
    filter: grayscale(0%) brightness(100%);
    transform: scale(1.05);
}
.brand-col p { color: #888 !important; font-size: 0.95rem; line-height: 1.6; margin-bottom: 15px; }

.aff-contact-item {
    display: flex; align-items: flex-start; gap: 10px;
    color: #aaa; font-size: 0.9rem; line-height: 1.5;
}
.aff-contact-item svg { flex-shrink: 0; margin-top: 3px; }

/* Titoli Colonne */
.aff-footer-col h4 {
    color: #fff !important; font-size: 1.1rem; margin-bottom: 25px; font-weight: 800;
}

/* Liste Link (Incolonnate perfettamente) */
.aff-footer-link-group {
    display: flex; flex-direction: column; gap: 12px;
}

.aff-footer-link-group a {
    color: #888; text-decoration: none; font-size: 0.95rem; font-weight: 500;
    transition: color 0.3s, transform 0.3s;
    display: inline-flex; align-items: center; gap: 8px;
    width: fit-content; /* L'effetto hover non prende tutta la riga */
}
.aff-footer-link-group a:hover {
    color: var(--primary-glow);
    transform: translateX(6px);
}

/* Link Highlight (La Mail) */
.aff-highlight-link { color: #ddd !important; }
.aff-highlight-link svg { color: var(--primary-glow); }

/* Icone Social */
.aff-social-icons { display: flex; gap: 12px; margin-bottom: 30px; }
.aff-social-icons a {
    display: flex; align-items: center; justify-content: center;
    width: 42px; height: 42px; border-radius: 50%;
    background: rgba(255,255,255,0.05); border: 1px solid rgba(255,255,255,0.05);
    color: #fff; transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}
.aff-social-icons a:hover {
    background: var(--primary-glow); color: #000;
    transform: translateY(-5px); border-color: var(--primary-glow);
    box-shadow: 0 10px 20px rgba(0, 196, 85, 0.4);
}

/* Badge di Sicurezza */
.aff-trust-badge {
    background: rgba(255,255,255,0.03); border: 1px solid rgba(255,255,255,0.08);
    border-radius: 12px; padding: 15px;
}
.trust-title {
    display: flex; align-items: center; gap: 6px;
    color: #fff; font-size: 0.8rem; font-weight: 700; text-transform: uppercase; margin-bottom: 10px;
}
.trust-icons {
    display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
}

/* Base Footer */
.aff-footer-bottom {
    max-width: 1200px; margin: 60px auto 0 auto; padding-top: 25px;
    border-top: 1px solid rgba(255,255,255,0.05); text-align: center;
}
.aff-footer-bottom p {
    color: #555 !important; font-size: 0.85rem; margin: 0; font-weight: 500;
}

/* Adattamento per i Telefoni */
@media (max-width: 900px) {
    .aff-footer-container { grid-template-columns: 1fr 1fr; } /* A metà schermo fa 2 colonne */
}
@media (max-width: 600px) {
    .aff-footer { padding: 60px 20px 20px 20px; }
    .aff-footer-container { grid-template-columns: 1fr; gap: 40px; } /* Su cell tutto in fila */
}

/* =========================================
   17. MODALE TESTI LEGALI E SCROLLBAR
   ========================================= */
.aff-legal-overlay {
    z-index: 9999999 !important;
}

.aff-legal-box {
    max-width: 850px; /* Più largo del Login per leggere bene i testi lunghi */
    width: 95%;
    padding: 40px 30px;
}

/* Area che scorre internamente */
.aff-legal-content-scroll {
    max-height: 70vh; /* Occupa massimo il 70% dello schermo in altezza */
    overflow-y: auto;
    padding-right: 15px; /* Spazio per non far accavallare il testo alla barra */
}

/* Personalizzazione Barra di scorrimento (Scrollbar) */
.aff-legal-content-scroll::-webkit-scrollbar { 
    width: 6px; 
}
.aff-legal-content-scroll::-webkit-scrollbar-track { 
    background: rgba(255,255,255,0.05); 
    border-radius: 10px; 
}
.aff-legal-content-scroll::-webkit-scrollbar-thumb { 
    background: var(--primary-glow); /* La barra si illumina di verde o viola! */
    border-radius: 10px; 
}

/* Stile dei testi legali */
.legal-text-content h2 {
    font-size: 2rem; color: #fff; margin-top: 0; margin-bottom: 25px; text-align: left;
}
.legal-body {
    color: #ccc; font-size: 1rem; line-height: 1.7; text-align: left;
}
.legal-body h3, .legal-body strong {
    color: #fff; margin-top: 25px; margin-bottom: 10px; display: block;
}
.legal-body p { margin-bottom: 15px; }

/* Adattamento Mobile */
@media (max-width: 768px) {
    .aff-legal-box { padding: 30px 20px; }
    .legal-text-content h2 { font-size: 1.6rem; }
    .legal-body { font-size: 0.95rem; }
    .aff-legal-content-scroll { max-height: 75vh; }
}

/* =========================================
   COOKIE BANNER GDPR
   ========================================= */
.aff-cookie-banner {
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    width: 90%;
    max-width: 900px;
    background: rgba(17, 17, 17, 0.95);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 16px;
    box-shadow: 0 20px 50px rgba(0,0,0,0.8);
    z-index: 9999999; /* Sopra a tutto */
    padding: 20px;
    display: flex;
    align-items: center;
}

.aff-cookie-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    gap: 20px;
}

.aff-cookie-text {
    flex: 1;
}

.aff-cookie-buttons {
    display: flex;
    align-items: center; /* Centra i bottoni verticalmente */
    gap: 12px;
    flex-shrink: 0;
}

/* Regola universale per i bottoni del banner per non farli schiacciare */
.aff-cookie-buttons button {
    white-space: nowrap; /* Impedisce al testo di andare a capo! */
    height: 42px; /* Altezza uguale per entrambi */
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0; /* Rimuove margini indesiderati */
}

.aff-btn-outline {
    background: transparent;
    color: #ccc;
    border: 1px solid rgba(255,255,255,0.2);
    padding: 0 20px;
    border-radius: 50px;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: 0.3s;
}

.aff-btn-outline:hover {
    border-color: #fff;
    color: #fff;
}

/* Versione Mobile */
@media (max-width: 768px) {
    .aff-cookie-banner {
        bottom: 10px;
        width: 95%;
        padding: 15px;
    }
    .aff-cookie-content {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
    }
    .aff-cookie-buttons {
        width: 100%;
        flex-direction: column;
    }
    .aff-cookie-buttons button {
        width: 100%;
    }
}