/* Reset */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: Arial, Helvetica, sans-serif;
}

/* Hero */
.hero {
    background: url('hero-juve.jpg') center/cover no-repeat;
    padding: 120px 20px;
    text-align: center;
    color: white;
    background-color: black;
}

.hero-content h1 {
    font-size: 3rem;
    letter-spacing: 2px;
}

.hero-content p {
    font-size: 1.2rem;
    opacity: 0.9;
}

/* Storia */
.storia {
    max-width: 900px;
    margin: 60px auto;
    padding: 0 20px;
    text-align: center;
}

.storia h2 {
    font-size: 2.2rem;
    margin-bottom: 20px;
}

.storia p {
    margin-bottom: 20px;
    line-height: 1.7;
    color: #333;
}

/* Direttivo */
.direttivo {
    background: #f7f7f7;
    padding: 60px 20px;
    text-align: center;
}

.direttivo h2 {
    font-size: 2.2rem;
}

.intro-direttivo {
    margin-bottom: 40px;
    color: #555;
    font-size: 1.1rem;
}

/* Cards Container */
.cards-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 30px;
}

/* Card stile giocatore potenziata */
.card {
    background: white;
    width: 260px;
    border-radius: 12px;
    overflow: hidden;
    position: relative;
    box-shadow: 0 4px 12px rgba(0,0,0,0.12);
    transition: transform 0.35s ease, box-shadow 0.35s ease;
    cursor: pointer;
}

/* Effetto 3D + Glow */
.card:hover {
    transform: translateY(-12px) scale(1.03);
    box-shadow: 0 12px 28px rgba(0,0,0,0.25), 0 0 10px white;
}

/* Immagine con zoom */
.card-img {
    height: 260px;
    background-size: cover;
    background-position: center;
    transition: transform 0.4s ease;
}

.card:hover .card-img {
    transform: scale(1.1);
}

/* Overlay sfumato in hover */
.card-img::after {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 260px;
    background: linear-gradient(to bottom, rgba(0,0,0,0) 40%, rgba(0,0,0,0.6));
    opacity: 0;
    transition: opacity 0.4s ease;
}

.card:hover .card-img::after {
    opacity: 1;
}

/* Testi */
.card h3 {
    font-size: 1.4rem;
    margin: 15px 0 5px 0;
    transition: color 0.3s ease;
}

.card .role {
    display: block;
    font-size: 0.9rem;
    color: #777;
    margin-bottom: 10px;
    opacity: 0;
    transform: translateY(-8px);
    transition: opacity 0.4s ease, transform 0.4s ease;
}

/* Ruolo visibile in hover */
.card:hover .role {
    opacity: 1;
    transform: translateY(0);
}

.card p {
    padding: 0 15px 20px;
    color: #444;
    line-height: 1.4;
    transition: color 0.3s ease;
}

/* Cambia colore testo per dare più contrasto con hover */
.card:hover h3,
.card:hover p {
    color: #111;
}

/* Esempi immagini */
.president { background-image: url('../../img/GIAN.png'); }
.vice      { background-image: url('../../img/freschini.png'); }
.seg       { background-image: url('../../img/zucchelli.png'); }
.tes       { background-image: url('tesoriere.jpg'); }

/* ======= SEZIONE ELEGANTE ======= */
.section-elegante {
    max-width: 1100px;
    margin:110px auto;
    background: #fff;
    padding: 50px 60px;
    border-radius: 14px;
    border: 1px solid #e5e5e5; /* bordo sottilissimo */
    box-shadow: 0 4px 14px rgba(0,0,0,0.06); /* ombra molto soft */
}

/* Titolo */
.section-elegante h2 {
    font-family: 'Montserrat', sans-serif;
    font-size: 2.2rem;
    font-weight: 700;
    margin-bottom: 20px;
    color: #111;
    border-left: 6px solid #000;  
    padding-left: 12px;
}

/* Testo interno */
.section-elegante p {
    font-family: 'Poppins', sans-serif;
    font-size: 1.05rem;
    line-height: 1.75;
    color: #222;
    white-space: pre-line;
    text-align: justify;   /* <-- GIUSTIFICA IL TESTO */
    text-justify: inter-word;
}
/* VIDEO ALL'INTERNO DELLA CARD */
.video-inside-card {
    width: 100%;
    margin: 20px 0 35px 0;
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid #e5e5e5;
    box-shadow: 0 3px 12px rgba(0,0,0,0.05);
}

.video-inside-card video,
.video-inside-card iframe {
    width: 100%;
    height: 430px;
    display: block;
    object-fit: cover;
}

@media (max-width: 768px) {
    .video-inside-card video,
    .video-inside-card iframe {
        height: 230px;
    }
}
/* Gallery Sede */
/* Impedisce lo sforamento a destra su tutto il sito */
html, body {
    overflow-x: hidden;
    width: 100%;
    margin: 0;
    padding: 0;
}

/* Gallery Sede - Ottimizzata per non sforare */
.sede-gallery {
    display: grid;
    grid-template-columns: repeat(3, 1fr); /* 3 colonne su PC */
    gap: 15px;
    margin-top: 25px;
    width: 100%;
    box-sizing: border-box;
}

.sede-foto {
    position: relative;
    display: block;
    height: 180px;
    border-radius: 8px;
    overflow: hidden;
    border: 1px solid #eee;
}

.sede-foto img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.overlay-zoom {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0,0,0,0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    opacity: 0;
    transition: opacity 0.3s;
}

.sede-foto:hover .overlay-zoom { opacity: 1; }

/* FIX PER MOBILE - Niente sforamento e foto compatte */
@media (max-width: 768px) {
    .sede-gallery {
        grid-template-columns: repeat(2, 1fr); /* 2 colonne su tablet/mobile */
        gap: 10px;
        padding: 0 5px; /* Evita che tocchino il bordo del telefono */
    }

    .sede-foto {
        height: 130px; /* Altezza ridotta per non farle sembrare enormi */
    }

    .section-elegante {
        padding: 40px 15px; /* Margini interni sicuri */
        max-width: 100vw;
        box-sizing: border-box;
    }
}

@media (max-width: 480px) {
    .sede-gallery {
        gap: 8px;
    }
    .sede-foto {
        height: 110px; /* Foto ancora più compatte su smartphone piccoli */
    }
}