/* --- IMPOSTAZIONI GLOBALI E VARIABILI --- */
:root {
    --bg-white: #ffffff;
    --bg-gray: #f5f5f7;  /* Sfondo principale */
    --bg-dark: #1a1a1a;
    --bg-event: #e6e8f0; /* Nuovo: Blu-Grigio per "Connessi" */
    --bg-partnership: #e6f0e8; /* Nuovo: Verde-Grigio per "Partnership" */
    
    --text-black: #1a1a1a;
    --text-white: #f5f5f7;
    
    /* Colori del gradiente statico per lo studio */
    --static-yellow-light: #FFFBEB; 
    --static-yellow-dark: #FEF7DA;
    
    --primary-yellow: #FFD700;
    --font-main: 'League Spartan', sans-serif;
    --transition-fluid: all 0.5s cubic-bezier(0.25, 0.8, 0.25, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    /* font-size: 16px; */
    font-size: 80%; /* MODIFICA: Testo ridimensionato come richiesto */
}

body {
    font-family: var(--font-main);
    background-color: var(--bg-gray); /* SFONDO PRINCIPALE GRIGIO */
    color: var(--text-black);
    line-height: 1.6;
    overflow-x: hidden;
}

/* --- TIPOGRAFIA --- */
h1, h2, h3 {
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1.5rem;
    text-align: center; 
}

h1 { font-size: 4.5rem; }
h2 { font-size: 3rem; }
h3 { font-size: 1.75rem; }

p {
    font-size: 1.1rem;
    font-weight: 400;
    margin-bottom: 1rem;
    text-align: center; /* Paragrafi centrati di default */
    max-width: 65ch; 
    margin-left: auto; 
    margin-right: auto;
}

/* Regole per il testo su sfondi scuri */
.dark-section {
    background: radial-gradient(ellipse at 50% -20%, rgba(255, 255, 255, 0.2), transparent 80%), 
                var(--bg-dark);
    color: var(--text-white);
}
.dark-section h2, .dark-section h3, .dark-section p {
    color: var(--text-white);
}

a {
    color: var(--text-black);
    text-decoration: none;
    font-weight: 500;
}
strong a {
    font-weight: inherit;
}

/* --- HEADER E NAVIGAZIONE --- */
header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    padding: 0.5rem 5%;
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.nav-wrapper {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
}

header nav {
    display: flex;
    align-items: center;
    gap: 2.5rem;
}

header nav a {
    font-size: 1rem;
    font-weight: 500;
    transition: color 0.3s ease;
    padding: 0.5rem;
}
header nav a:hover { color: var(--primary-yellow); }

.header-logo {
    height: 40px;
    width: auto;
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
}

/* --- SEZIONE EROE --- */
#hero {
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    background-color: var(--bg-white); /* SFONDO BIANCO */
}

.hero-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

#hero-logo {
    width: 150px;
    animation: logoIntro 2s cubic-bezier(0.165, 0.84, 0.44, 1) forwards;
}

@keyframes logoIntro {
    0% { opacity: 0; transform: scale(0.5) translateY(50px); }
    100% { opacity: 1; transform: scale(1) translateY(0); }
}

#hero-title {
    opacity: 0;
    animation: titleFadeIn 1.5s ease 1s forwards;
}

@keyframes titleFadeIn {
    0% { opacity: 0; transform: translateY(20px); }
    100% { opacity: 1; transform: translateY(0); }
}

/* --- LAYOUT SEZIONI --- */
.content-section {
    padding: 6rem 5%;
    width: 100%;
    position: relative; 
    overflow: hidden; 
}
.partnership-section {
    padding-top: 4rem;
    padding-bottom: 4rem;
}
.event-gallery-section {
    padding-top: 0;
    padding-bottom: 6rem;
}

/* Contenitore di testo base */
.text-container {
    width: 100%;
    max-width: 900px;
    margin: 0 auto; 
    position: relative; 
    z-index: 2;
}


/* --- CONTENITORI "EFFETTO VETRO" E STATICI --- */
.glass-yellow-container,
.glass-white-container,
.static-yellow-container {
    width: 100%;
    max-width: 1000px;
    padding: 4rem;
    border-radius: 24px;
    margin: 0 auto;
    text-align: center;
    position: relative; 
    z-index: 2;
}
.glass-yellow-container p,
.glass-white-container p,
.static-yellow-container p {
    text-align: center;
}

/* Vetro Giallo TRASPARENTE (per Missione) */
.glass-yellow-container {
    background: linear-gradient(135deg, rgba(255, 215, 0, 0.2), rgba(255, 215, 0, 0.05));
    border: 1px solid rgba(255, 215, 0, 0.3);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.1);
}

/* Vetro Bianco TRASPARENTE (per Contatti) */
.glass-white-container {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.2), rgba(255, 255, 255, 0.05));
    border: 1px solid rgba(255, 255, 255, 0.3);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.1);
}

/* NUOVO: Box Giallo STATICO (per Studio) */
.static-yellow-container {
    /* Gradiente statico come da immagine */
    background: linear-gradient(135deg, var(--static-yellow-light), var(--static-yellow-dark));
    color: var(--text-black);
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.2);
}
.static-yellow-container .cta-button {
    background-color: var(--text-black);
    color: var(--bg-white);
}


/* --- LAYOUT SPECIFICI PER SEZIONE --- */

/* MISSIONE (Griglia dentro vetro) */
.values-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    margin-top: 3rem;
    text-align: left; 
}
.values-grid .value-item h3 { text-align: left; }
.values-grid .value-item p { 
    font-size: 1rem; 
    text-align: left; 
    margin: 0; 
}

/* SEZIONE STUDIO (Vinile) */
/* MODIFICA: Aggiunto sfondo bianco alla sezione */
.studio-section {
    background-color: var(--bg-white);
}

.studio-stack-wrapper {
    display: grid; 
    place-items: center; 
    position: relative;
    width: 100%;
}
.spinning-vinyl {
    position: absolute;
    width: 88%; /* MODIFICA: Rimpicciolito da 90% */
    max-width: 670px; /* MODIFICA: Rimpicciolito da 700px */
    height: auto;
    opacity: 0.8; 
    z-index: 1; /* Sta dietro */
    animation: spin 20s linear infinite;
    grid-area: 1 / 1;
}
@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}
.studio-stack-wrapper .static-yellow-container {
    grid-area: 1 / 1; /* Sovrapposto e centrato */
    z-index: 2; /* Sta sopra il vinile */
}

/* GALLERIA ORIZZONTALE (Desktop) */
.horizontal-gallery {
    display: grid;
    grid-template-columns: repeat(4, 1fr); /* 4 FOTO */
    gap: 0; /* SENZA SPAZI */
    width: 100%;
    max-width: 1200px;
    margin: 4rem auto 0 auto;
    z-index: 2;
    position: relative;
    overflow: hidden;
    border-radius: 12px;
}
.horizontal-gallery img {
    width: 100%;
    height: 300px;
    object-fit: cover;
}

/* Nasconde gli slider su desktop */
.studio-mobile-slider, .event-mobile-slider {
    display: none;
}


/* SEZIONE EVENTO (Nuovo colore) */
.event-bg {
    /* background-color: var(--bg-event); */
    background-color: var(--bg-gray); /* MODIFICA: Sfondo grigio come #about */
}

/* SEZIONE PARTNERSHIP (Nuovo colore) */
.partnership-bg {
    /* background-color: var(--bg-partnership); */
    background-color: var(--bg-white); /* MODIFICA: Sfondo bianco */
}

/* GALLERIA EVENTO (Slider - usata solo su mobile) */
.gallery-container {
    width: 100vw; 
    margin-left: calc(-50vw + 50%); 
    overflow: hidden;
    position: relative;
    z-index: 2;
    -webkit-mask-image: linear-gradient(to right, transparent, black 10%, black 90%, transparent);
    mask-image: linear-gradient(to right, transparent, black 10%, black 90%, transparent);
}
.gallery-slider {
    display: flex;
    gap: 1rem; /* Spazio uniforme tra le foto */
    width: max-content; /* FONDAMENTALE: impedisce alle foto di andare a capo */
    animation: scroll 25s linear infinite; /* Velocità fluida */
}
.gallery-slider img {
    height: 250px;
    width: auto;
    /* Rimuoviamo il margine laterale qui perché usiamo gap nel genitore per precisione */
    margin: 0; 
    border-radius: 12px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    flex-shrink: 0; /* Impedisce alle immagini di schiacciarsi */
}

@keyframes scroll {
    0% { 
        transform: translateX(0); 
    }
    100% { 
        /* Si sposta esattamente di metà larghezza (dove inizia la copia delle foto) */
        transform: translateX(-50%); 
    }
}

/* --- BOTTONI (Call to Action) --- */
.cta-button {
    display: block;
    width: fit-content;
    margin: 1.5rem auto 0 auto;
    padding: 1rem 2.5rem;
    font-size: 1.1rem;
    font-weight: 700;
    border-radius: 50px;
    background-color: var(--primary-yellow);
    color: var(--text-black);
    transition: var(--transition-fluid);
    transform-origin: center;
}
.cta-button:hover {
    transform: scale(1.05);
}
/* Stile per bottone su sfondo scuro */
.cta-button.dark { 
    background-color: var(--bg-white);
    color: var(--bg-dark);
}

/* ### CORREZIONE QUI ### */
/* --- SEZIONE CONTATTI (Nuovo layout) --- */
.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr; /* Due colonne uguali */
    gap: 2rem;
    margin-top: 3rem;
}

.contact-column {
    text-align: center;
}

/* Regole per .contact-title-wrapper RIMOSSE 
   perché l'elemento HTML non esiste più.
*/

/* Il titolo h3 è ora centrato da .contact-column */
.contact-column h3 {
    font-size: 1.75rem;
    margin-bottom: 1rem; /* Mantiene lo spazio sotto il titolo */
}

/* NUOVO: Wrapper per (icona + link) */
.contact-link-wrapper {
    display: flex;
    justify-content: center; /* Centra il gruppo icona+link */
    align-items: center;
    gap: 0.75rem; /* Spazio tra icona e link */
}

.contact-icon {
    height: 28px; 
    width: 28px;
}

.contact-column a {
    font-size: 1.5rem;
    font-weight: 700;
    word-wrap: break-word; /* Manda a capo l'email se è troppo lunga */
    /* display: block; NON più necessario grazie a flex */
}

.contact-column a:hover {
    text-decoration: underline;
}

/* --- FOOTER --- */
footer {
    text-align: center;
    padding: 3rem 5%;
    background-color: var(--bg-white);
    border-top: 1px solid rgba(0, 0, 0, 0.1);
}
footer p {
    font-size: 0.9rem;
    color: #555;
    text-align: center; 
}
/* Regole duplicate rimosse */

/* Stile per le info legali aggiunte */
.footer-legal-info {
    margin-top: 1.5rem;
    border-top: 1px solid rgba(0, 0, 0, 0.1);
    padding-top: 1.5rem;
    /* --- MODIFICHE PER LAYOUT ORIZZONTALE --- */
    display: flex;
    justify-content: center;
    gap: 2rem;
    flex-wrap: wrap;
}
.footer-legal-info p {
    font-size: 0.9rem;
    color: #555;
    margin-bottom: 0; /* Rimuovo margine inferiore */
}
/* --- ANIMAZIONI ON-SCROLL (Fade In) --- */
.fade-in {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 1.2s cubic-bezier(0.165, 0.84, 0.44, 1), 
                transform 1s cubic-bezier(0.165, 0.84, 0.44, 1);
}
.fade-in.is-visible {
    opacity: 1;
    transform: translateY(0);
}

/* --- RESPONSIVE DESIGN (per Mobile) --- */
@media (max-width: 768px) {
    h1 { font-size: 2.8rem; }
    h2 { font-size: 2rem; }
    h3 { font-size: 1.5rem; }
    p { font-size: 1rem; }

    .header-logo { display: none; }
    .nav-wrapper { justify-content: center; }
    header nav { gap: 1rem; padding: 0; justify-content: center; }
    header nav a { font-size: 0.9rem; }

    .content-section { padding: 4rem 5%; }

    .glass-yellow-container,
    .glass-white-container,
    .static-yellow-container {
        padding: 2rem;
    }
    /* 1. Manteniamo l'overflow visibile */
    .studio-section {
        overflow: visible !important; 
    }

    /* 2. Riduciamo lo spazio tra le sezioni */
    .studio-stack-wrapper {
        display: block !important;
        position: relative;
        
        
    }

    /* 3. Ingrandiamo il vinile e lo posizioniamo */
    .spinning-vinyl {
        display: block !important;
        
        /* AUMENTATO: Da 200px a 280px (più largo) */
        width: 300px !important;       
        height: auto !important;
        
        position: absolute !important;
        
        /* ALZATO: Da -100px a -135px 
           (Deve salire di più perché il disco è più grande, 
           così spunta bene da dietro) */
        top: -100px !important;        
        
        /* Centratura standard */
        left: 0 !important;
        right: 0 !important;
        margin-left: auto !important;
        margin-right: auto !important;
        
        z-index: 0 !important;
        opacity: 1 !important;
    }

    /* Assicurati che il box giallo copra la metà inferiore del disco */
    .static-yellow-container {
        position: relative;
        z-index: 2;
        /* Importante: assicurati che abbia uno sfondo, altrimenti il disco si vede in trasparenza */
        background: linear-gradient(135deg, var(--static-yellow-light), var(--static-yellow-dark));
    }
    .fade-in {
        opacity: 1 !important;
        transform: translateY(0) !important;
        transition: none !important;
    }
    .spinning-vinyl {
        display: none; /* Nasconde il vinile su mobile */
    }

    /* Stili responsive per la griglia della missione */
    .values-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    .values-grid .value-item p,
    .values-grid .value-item h3 {
        text-align: center; 
        margin: 0 auto 1rem auto;
    }

    /* GALLERIE: Nasconde la griglia e mostra lo slider */
    .horizontal-gallery {
        display: none;
    }


    /* 1. TRUCCO MAGICO: Nasconde tutti i <br> (spazi vuoti manuali) 
       dentro le sezioni Studio ed Evento solo su mobile. 
       Questo elimina i buchi enormi. */
       .studio-section br,
       .event-gallery-section br {
           display: none;
       }
   
       /* 2. Impostazioni Slider Mobile */
       .studio-mobile-slider,
       .event-mobile-slider {
           display: block !important;
           
           /* Ora che i <br> sono nascosti, possiamo gestire lo spazio con precisione.
              Metti 0 se la vuoi attaccata, o 1rem per un minimo di respiro. */
           margin-top: 0rem !important; 
           
           margin-bottom: 3rem !important; /* Spazio sotto per non attaccarla al testo successivo */
           width: 100vw; /* Larghezza totale schermo */
           position: relative;
           left: 50%;
           right: 50%;
           margin-left: -50vw;
           margin-right: -50vw;
       }
   
       /* Regola specifica per avvicinare ancora di più quella dello studio se serve */
       .studio-mobile-slider {
           margin-top: 5rem !important;
           margin-bottom: 1rem !important;
       }
   

    .gallery-slider img {
        height: 200px; /* Immagini slider mobile */
    }

    /* --- SPOSTATO DENTRO LA MEDIA QUERY --- */
    /* Stili responsive per la griglia contatti */
    .contact-grid {
        grid-template-columns: 1fr; /* Impila le colonne */
        gap: 3rem; /* Aumenta lo spazio tra le colonne impilate */
    }
    
    .contact-column a {
        font-size: 1.2rem; /* Riduci un po' la mail su mobile */
    }
    
    /* Stili responsive per il footer */
    .footer-legal-info {
        flex-direction: column;
        gap: 0.5rem; /* Gap ridotto per stacking verticale */
    }
}
/* --- PARENTESI EXTRA E STILI FUORI POSTO RIMOSSI --- */