/* REGISTRAZIONE DEL FONT PERSONALIZZATO */
@font-face {
    font-family: 'SansForgetica';
    src: url('SansForgetica-Regular.otf') format('opentype'); 
    font-weight: normal;
    font-style: normal;
}

/* RESET E BASI */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background-color: #0b0b0b;
    color: #e0e0e0;
    font-family: 'Montserrat', sans-serif;
    line-height: 1.8;
}

.container {
    max-width: 960px;
    margin: 0 auto;
    padding: 0 20px;
}

/* TITOLI STILE PROG */
h1, h2 {
    font-family: 'Cinzel', serif;
    letter-spacing: 3px;
    color: #d4af37;
    text-align: center;
}

h2 {
    font-size: 2.5rem;
    margin-bottom: 40px;
    position: relative;
}

h2::after {
    content: '';
    display: block;
    width: 60px;
    height: 2px;
    background: #d4af37;
    margin: 15px auto 0 auto;
}

/* STRUTTURA DELLA HERO */
.hero {
    height: 60vh;
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    background-color: #0b0b0b;
}

/* Patina scura sopra le foto */
.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(rgba(0,0,0,0.6), rgba(11,11,11,1));
    z-index: 1;
}

/* Lo strato delle immagini che ruotano - STRUTTURA FISSA E BLOCCATA AL CENTRO */
.hero::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    background-image: url('img/hero-bg1.jpg');
    background-position: center center;
    background-size: cover;
    background-repeat: no-repeat;
    animation: progSlideshow 18s infinite ease-in-out;
}

.hero-content {
    position: relative;
    z-index: 2;
}

.hero-content h1 {
    font-family: 'SansForgetica', sans-serif;
    font-size: 5rem;
    letter-spacing: 3px;
    text-shadow: 0 0 25px rgba(212, 175, 55, 0.6);
    margin-bottom: 10px;
}

.subtitle {
    font-size: 1.2rem;
    text-transform: uppercase;
    letter-spacing: 5px;
    color: #888;
    margin-top: 10px;
}

/* ANIMAZIONE CORRETTA: CAMBIA SOLO L'URL DELL'IMMAGINE, LA CENTRATURA RESTA QUELLA DI SOPRA */
@keyframes progSlideshow {
    /* FOTO 1 */
    0%, 100% {
        background-image: url('img/hero-bg1.jpg');
        opacity: 1;
    }
    28% {
        background-image: url('img/hero-bg1.jpg');
        opacity: 1;
    }
    /* Transizione */
    33% {
        opacity: 0;
    }
    /* FOTO 2 */
    38% {
        background-image: url('img/hero-bg2.jpg');
        opacity: 1;
    }
    61% {
        background-image: url('img/hero-bg2.jpg');
        opacity: 1;
    }
    /* Transizione */
    66% {
        opacity: 0;
    }
    /* FOTO 3 */
    71% {
        background-image: url('img/hero-bg3.jpg');
        opacity: 1;
    }
    94% {
        background-image: url('img/hero-bg3.jpg');
        opacity: 1;
    }
}

/* SEZIONI */
.section {
    padding: 80px 0;
}

.biography {
    background-color: #111;
    text-align: justify;
    font-size: 1.1rem;
}

.biography p {
    margin-bottom: 20px;
}

.section-desc {
    text-align: center;
    margin-bottom: 40px;
    color: #aaa;
}

/* YOUTUBE VIDEO GRID */
.video-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    margin-bottom: 40px;
}

@media (max-width: 768px) {
    .video-grid { grid-template-columns: 1fr; }
}

.video-wrapper {
    position: relative;
    padding-bottom: 56.25%;
    height: 0;
}

.video-wrapper iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: 1px solid #333;
}

/* BOTTONE */
.cta-container { text-align: center; }
.btn {
    display: inline-block;
    padding: 12px 30px;
    border: 2px solid #d4af37;
    color: #d4af37;
    text-decoration: none;
    text-transform: uppercase;
    font-weight: 600;
    letter-spacing: 2px;
    transition: all 0.3s ease;
}
.btn:hover {
    background-color: #d4af37;
    color: #0b0b0b;
}

/* GALLERIA */
.photo-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 20px;
}

.photo-item img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    filter: grayscale(40%);
    border: 1px solid #222;
    transition: all 0.4s ease;
}

.photo-item img:hover {
    filter: grayscale(0%);
    transform: scale(1.03);
    border-color: #d4af37;
}

/* FOOTER & CONTATTI */
.footer {
    background-color: #050505;
    padding: 60px 0 30px 0;
    text-align: center;
    border-top: 1px solid #111;
}

.email-link {
    display: block;
    font-size: 1.8rem;
    color: #d4af37;
    text-decoration: none;
    margin: 20px 0;
    font-weight: bold;
}

.copyright {
    margin-top: 40px;
    font-size: 0.8rem;
    color: #555;
}

/* OTTIMIZZAZIONE SMARTPHONE */
@media (max-width: 480px) {
    .hero {
        height: 45vh;
    }
 .hero::after {
        /* Forza iOS Safari a tenere l'immagine bloccata esattamente al centro orizzontale */
        background-position: center center !important;
        background-position-x: center !important;
    }
    .hero-content h1 {
        font-size: 3rem;
    }
}
