/* =========================================
   Reset & Base Variables
   ========================================= */
:root {
    --primary-color: #FFFFFF;
    --bg-dark: #000000;
    --overlay-alpha-nav: rgba(0, 0, 0, 0.95);
    --overlay-alpha-bg: rgba(0, 0, 0, 0.4);
    /* Darkened the background slightly to ensure white text pops */
    --font-main: 'Montserrat', sans-serif;
}

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

body {
    font-family: var(--font-main);
    color: var(--primary-color);
    background-color: var(--bg-dark);
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
    position: relative;
    /* Prevent select highlight for app-like feel */
    user-select: none;
}

/* Evitare scrolling quando il menu base body ha la classe no-scroll */
body.no-scroll {
    overflow: hidden;
}

/* Elementi nascosti solo visivamente per SEO e Accessibilità */
.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* =========================================
   INTRO OVERLAY HYBRID (SFONDO PIENO)
   ========================================= */
body.no-scroll {
    overflow: hidden;
}

/* Nascondiamo tutto il contenuto della hero fintanto che c'è l'intro,
   ma li posizioniamo anche scorressi in basso. */
body.intro-active .hero-content,
body.intro-active .cta-container,
body.intro-active .main-header,
body.intro-active .discover-section,
body.intro-active .gallery-section,
body.intro-active .main-footer {
    opacity: 0 !important;
    pointer-events: none;
    transform: translateY(100px);
    /* Slidati in basso */
    transition: none;
    /* Disabilitata fino alla rivelazione */
}

/* Transizione per quando ritornano visibili */
.hero-content,
.cta-container,
.main-header,
.discover-section,
.gallery-section,
.main-footer {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 1.2s cubic-bezier(0.2, 0.8, 0.2, 1) 0.2s, transform 1.2s cubic-bezier(0.2, 0.8, 0.2, 1) 0.2s;
}

/* L'intro usa uno sfondo scuro solido. Quando ha finito, scorre verso l'alto
   rivelando la Home normale sottostante. */
.intro-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: transparent;
    /* Solo scritte sul vero sfondo */
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 1s ease;
    /* Fade out morbido, basta slide-up */
}

.intro-overlay.slide-up {
    transform: translateY(-100%);
}

.intro-center {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
}

.intro-text-line {
    display: flex;
    gap: 12px;
}

.intro-word {
    font-family: 'Montserrat', sans-serif;
    font-weight: 900;
    font-size: 2rem;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: #ffffff;
    opacity: 0;
    transform: translateY(25px);
    transition: opacity 0.7s ease, transform 0.7s ease;
    text-shadow: 0 2px 20px rgba(0, 0, 0, 0.6);
}

.intro-word.show {
    opacity: 1;
    transform: translateY(0);
}

.intro-logo {
    width: 250px;
    height: auto;
    opacity: 0;
    transform: translateY(60px);
    transition: opacity 0.8s ease, transform 0.8s ease, margin-bottom 0.8s ease;
}

.intro-logo.show {
    opacity: 1;
    transform: translateY(0);
}

/* Rimosso intro-logo.slide-home - user wants basic home logo */

@media (min-width: 768px) {
    .intro-word {
        font-size: 3.5rem;
    }

    .intro-logo {
        width: 250px;
    }
}

/* =========================================
   GALLERY (foto una sotto l'altra)
   ========================================= */
.gallery-section {
    padding: 40px 0 80px;
    background: var(--bg-dark);
}

.gallery-grid {
    display: flex;
    flex-direction: column;
    gap: 16px;
    padding: 20px 0;
}

.gallery-slide {
    border-radius: 14px;
    overflow: hidden;
    max-width: 600px;
    margin: 0 auto;
    width: 100%;
}

.gallery-slide img {
    width: 100%;
    height: auto;
    display: block;
}

@media (min-width: 768px) {
    .gallery-grid {
        display: grid;
        grid-template-columns: repeat(3, 1fr);
        gap: 20px;
    }

    .gallery-slide {
        max-width: none;
    }
}

/* =========================================
   Background Images & Overlays
   ========================================= */
.bg-image {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background-image: url('ImmaginesfondoHOME.jpeg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    z-index: -2;
    /* Soft ken-burns animation for dynamic feel */
    animation: slowPan 30s infinite alternate linear;
}

@keyframes slowPan {
    0% {
        transform: scale(1);
    }

    100% {
        transform: scale(1.05);
    }
}

.bg-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: var(--overlay-alpha-bg);
    z-index: -1;
}

/* =========================================
   Header & Navigation
   ========================================= */
.main-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 2rem;
    /* Ridotto per app mobile */
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 10;
    transition: background-color 0.4s ease, padding 0.4s ease;
}

.main-header.scrolled {
    background-color: var(--bg-dark);
}

.header-logo-link {
    display: inline-block;
}

.header-img {
    height: 32px;
    /* Ingrandita leggermente per bilanciare l'hamburger come richiesto */
    width: auto;
}

.hamburger-btn {
    background: transparent;
    border: none;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 10px;
    z-index: 10;
}

.hamburger-btn .line {
    display: block;
    width: 28px;
    height: 3px;
    background-color: var(--primary-color);
    border-radius: 2px;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

/* =========================================
   Hero Section
   ========================================= */
.hero-section {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    /* Center content vertically before adjusting margins */
    align-items: center;
    padding: 0 20px 40px;
    /* Rimossi i padding massivi sopra per accentrare verticalmente a piacimento */
}

.hero-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    margin-top: -15vh;
    /* Sposta il logo e il testo sensibilmente più in alto (stile Peter Pan) */
    margin-bottom: 5vh;
    /* Spazio tra logo e bottone */
    width: 100%;
}

.hero-logo-img {
    width: 100%;
    max-width: 250px;
    /* Ingrandito su mobile come richiesto, senza spostare la posizione */
    margin-bottom: 20px;
    height: auto;
    filter: drop-shadow(0 4px 6px rgba(0, 0, 0, 0.3));
    opacity: 0;
    animation: heroEntrance 1.2s cubic-bezier(0.165, 0.84, 0.44, 1) 0.2s forwards;
}

.hero-text-img {
    width: 100%;
    max-width: 300px;
    margin-bottom: 15px;
    height: auto;
}

.tagline {
    font-size: 1.2rem;
    font-weight: 400;
    letter-spacing: 1px;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.6);
    opacity: 0;
    animation: heroEntrance 1s cubic-bezier(0.165, 0.84, 0.44, 1) 0.6s forwards;
}

.cta-container {
    width: 100%;
    display: flex;
    justify-content: center;
    margin-bottom: -15vh;
    /* Sposta il bottone sensibilmente più in basso rispetto al centro */
    opacity: 0;
    animation: heroEntrance 1s cubic-bezier(0.165, 0.84, 0.44, 1) 0.9s forwards;
}

.btn {
    display: inline-block;
    text-decoration: none;
    text-align: center;
    font-weight: 700;
    font-size: 0.9rem;
    /* Testo più piccolo su mobile */
    letter-spacing: 2px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

.btn-outline {
    color: var(--primary-color);
    background: rgba(0, 0, 0, 0.2);
    border: 2px solid var(--primary-color);
    border-radius: 50px;
    padding: 12px 30px;
    /* Bottone più piccolo su mobile */
    backdrop-filter: blur(5px);
    /* Esecuzione glassmorphism */
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.btn-outline:hover {
    background: var(--primary-color);
    color: var(--bg-dark);
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(255, 255, 255, 0.3);
}

/* =========================================
   Fullscreen Menu Overlay
   ========================================= */
.fullscreen-menu {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: var(--overlay-alpha-nav);
    backdrop-filter: blur(10px);
    z-index: 100;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 2rem;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.4s ease, visibility 0.4s ease;
}

.fullscreen-menu.active {
    opacity: 1;
    visibility: visible;
}

.menu-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.menu-logo {
    font-weight: 700;
    font-size: 1.25rem;
    letter-spacing: 2px;
}

.close-btn {
    background: transparent;
    border: none;
    color: var(--primary-color);
    font-size: 2.5rem;
    line-height: 1;
    cursor: pointer;
    padding: 0 10px;
    transition: transform 0.3s ease;
}

.close-btn:hover {
    transform: rotate(90deg) scale(1.1);
}

.menu-links {
    list-style: none;
    text-align: center;
    display: flex;
    flex-direction: column;
    gap: 30px;
    margin-top: 40px;
}

.menu-links li {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.4s ease, transform 0.4s ease;
}

/* Staggered animation per menu items */
.fullscreen-menu.active .menu-links li:nth-child(1) {
    transition-delay: 0.1s;
    opacity: 1;
    transform: translateY(0);
}

.fullscreen-menu.active .menu-links li:nth-child(2) {
    transition-delay: 0.2s;
    opacity: 1;
    transform: translateY(0);
}

.fullscreen-menu.active .menu-links li:nth-child(3) {
    transition-delay: 0.3s;
    opacity: 1;
    transform: translateY(0);
}

.fullscreen-menu.active .menu-links li:nth-child(4) {
    transition-delay: 0.4s;
    opacity: 1;
    transform: translateY(0);
}

.fullscreen-menu.active .menu-links li:nth-child(5) {
    transition-delay: 0.5s;
    opacity: 1;
    transform: translateY(0);
}

.menu-links a {
    text-decoration: none;
    color: var(--primary-color);
    font-size: 2rem;
    font-weight: 700;
    text-transform: capitalize;
    transition: color 0.3s ease, letter-spacing 0.3s ease;
    display: inline-block;
    position: relative;
}

.menu-links a:hover {
    color: #e0e0e0;
    letter-spacing: 2px;
}

.menu-footer {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    padding-bottom: 2rem;
}

.separator {
    width: 80%;
    max-width: 400px;
    border: none;
    height: 1px;
    background-color: rgba(255, 255, 255, 0.3);
    margin-bottom: 30px;
}

.social-icon {
    color: var(--primary-color);
    transition: transform 0.3s ease, color 0.3s ease;
}

.social-icon:hover {
    transform: scale(1.2);
    color: #cccccc;
}

/* =========================================
   Content Sections (Press, Contact)
   ========================================= */
html {
    scroll-behavior: smooth;
}

.content-section {
    min-height: 100vh;
    width: 100%;
    display: flex;
    flex-direction: column;
    padding: 100px 20px 40px;
    position: relative;
    z-index: 1;
    /* Sopra al background */
}

.section-container {
    max-width: 800px;
    margin: 0 auto;
    width: 100%;
}

.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 2rem;
    text-transform: capitalize;
}

/* Press Section */
.press-heading {
    text-align: center;
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: 2px;
    margin-bottom: 2rem;
}

.article-card {
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 12px;
    padding: 2rem;
    text-align: center;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    transition: transform 0.3s ease;
}

.article-card:hover {
    transform: translateY(-5px);
}

.article-date {
    color: #ff0000;
    font-weight: 700;
    font-size: 0.9rem;
    margin-bottom: 1rem;
    letter-spacing: 1px;
}

.article-source {
    text-transform: uppercase;
}

.article-title {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    line-height: 1.4;
}

.article-desc {
    font-size: 1rem;
    font-weight: 400;
    margin-bottom: 2rem;
    opacity: 0.9;
}

.btn-red {
    display: inline-block;
    text-decoration: none;
    background-color: #ff0000;
    color: #ffffff;
    border: none;
    padding: 12px 30px;
    border-radius: 5px;
    /* Pulsante solido e meno arrotondato rispetto a quello hero */
    font-weight: 700;
    letter-spacing: 1px;
    box-shadow: 0 4px 15px rgba(255, 0, 0, 0.3);
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

.btn-red:hover {
    background-color: #cc0000;
    color: #ffffff;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(255, 0, 0, 0.4);
}

/* Contact Section */
.contact-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    margin-top: 4rem;
    padding: 2rem;
}

.contact-icon {
    margin-bottom: 1.5rem;
    color: var(--primary-color);
}

.contact-heading {
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
}

.contact-link {
    color: var(--primary-color);
    text-decoration: none;
    font-size: 1.2rem;
    margin-bottom: 0.8rem;
    transition: color 0.3s ease;
}

.contact-link:hover {
    color: #cccccc;
    text-decoration: underline;
}

/* Membership Section (Sb Member Card) */
.membership-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 2rem 0;
}

.membership-hero-heading {
    font-size: 2rem;
    font-weight: 900;
    line-height: 1.2;
    margin-bottom: 1.5rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.membership-desc {
    font-size: 1.1rem;
    max-width: 600px;
    margin-bottom: 3rem;
    color: rgba(255, 255, 255, 0.9);
}

.membership-actions {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    width: 100%;
    margin-bottom: 4rem;
    max-width: 400px;
}

.btn-block {
    width: 100%;
    padding: 16px 20px;
    font-size: 1.1rem;
    border-radius: 8px;
    /* Appena stondato per le tessere */
}

/* Perks Container */
.perks-container {
    width: 100%;
    max-width: 800px;
    border-top: none;
    /* Rimuovo linea solida */
    padding-top: 80px;
    /* Aumento padding per lo sfondo sfumato */
    padding-bottom: 60px;
    position: relative;
    z-index: 1;
}

.perks-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100vw;
    height: 100%;
    background: linear-gradient(to bottom, transparent 0%, var(--bg-dark) 100px, var(--bg-dark) 100%);
    z-index: -1;
}

.perks-heading {
    font-size: 1.4rem;
    font-weight: 700;
    margin-bottom: 2rem;
    letter-spacing: 2px;
}

.perks-grid {
    display: grid;
    grid-template-columns: repeat(1, 1fr);
    gap: 1.5rem;
}

@media (min-width: 576px) {
    .perks-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

.perk-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(10px);
    border-radius: 12px;
    /* Ridotto */
    padding: 1.5rem 1rem;
    /* Ridotto sensibilmente per card più contenute */
    text-align: center;
    position: relative;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    display: flex;
    flex-direction: column;
    align-items: center;
    z-index: 1;
    /* relative to ::before */
}

.perk-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(255, 0, 0, 0.1) 0%, rgba(0, 0, 0, 0) 100%);
    opacity: 0;
    transition: opacity 0.4s ease;
    z-index: -1;
}

.perk-card:hover {
    transform: translateY(-8px);
    border-color: rgba(255, 0, 0, 0.4);
    box-shadow: 0 15px 40px rgba(255, 0, 0, 0.15);
}

.perk-card:hover::before {
    opacity: 1;
}

.perk-icon-wrapper {
    width: 60px;
    height: 60px;
    margin: 0 auto 1.5rem;
    background: rgba(255, 0, 0, 0.1);
    color: #ff0000;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: transform 0.4s ease, background 0.4s ease, color 0.4s ease;
}

.perk-card:hover .perk-icon-wrapper {
    transform: scale(1.1) rotate(5deg);
    background: #ff0000;
    color: #ffffff;
    box-shadow: 0 0 15px rgba(255, 0, 0, 0.5);
}

.perk-title {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 0.75rem;
    letter-spacing: 1px;
}

.perk-desc {
    font-size: 0.95rem;
    color: rgba(255, 255, 255, 0.7);
    line-height: 1.5;
}

/* Specific background watermark simulating 'Schoolbreak' logo behind sections */
.press-section::before,
.contact-section::before,
.membership-section::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 80%;
    height: 80%;
    background-image: url('Schoolbreak logo.PNG');
    background-size: contain;
    background-position: center;
    background-repeat: no-repeat;
    opacity: 0.05;
    z-index: -1;
    pointer-events: none;
}

/* =========================================
   Animations
   ========================================= */
@keyframes fadeInUp {
    0% {
        opacity: 0;
        transform: translateY(30px);
    }

    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes heroEntrance {
    0% {
        opacity: 0;
        transform: translateY(40px) scale(0.95);
    }

    100% {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@keyframes fadeIn {
    0% {
        opacity: 0;
    }

    100% {
        opacity: 1;
    }
}

/* =========================================
   Media Queries for PC/Desktop Optimization
   ========================================= */
@media (min-width: 768px) {
    .main-header {
        padding: 2rem 2rem;
        /* Ripristino padding nativo per desktop */
    }

    .header-img {
        height: 20px;
        /* Ridotto anche su PC */
    }

    .hero-section {
        padding: 0 20px 40px;
        /* Ripristino top padding hero per desktop */
    }

    .hero-logo-img {
        max-width: 350px;
    }

    .hero-text-img {
        max-width: 450px;
    }

    .tagline {
        font-size: 1.5rem;
    }

    .btn-outline {
        padding: 16px 50px;
        font-size: 1.1rem;
    }


    .menu-links a {
        font-size: 3rem;
    }

    .membership-hero-heading {
        font-size: 3rem;
    }

    .membership-desc {
        font-size: 1.3rem;
    }

    .membership-actions {
        flex-direction: row;
        max-width: 800px;
    }

    .btn-block {
        width: 50%;
    }

    .perks-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

/* =========================================
   EVENTI SECTION & ADMIN
   ========================================= */
.eventi-section {
    min-height: 100vh;
    padding-bottom: 80px;
}

.eventi-main-heading {
    font-size: 3rem;
    font-weight: 900;
    margin-bottom: 2rem;
    text-align: left;
}

.events-carousel {
    display: flex;
    flex-wrap: nowrap;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    gap: 20px;
    padding: 20px 0 40px 0;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
}

.events-carousel::-webkit-scrollbar {
    display: none;
}

.event-card {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 16px;
    overflow: hidden;
    position: relative;
    border: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    flex-direction: column;
    flex: 0 0 85%;
    /* Lascia intravedere la card successiva su mobile */
    max-width: 400px;
    scroll-snap-align: center;
}

@media (min-width: 768px) {
    .event-card {
        flex: 0 0 350px;
        scroll-snap-align: start;
    }
}

.event-poster {
    width: 100%;
    height: auto;
    display: block;
    aspect-ratio: 4/5;
    object-fit: cover;
}

.event-actions {
    display: flex;
    justify-content: space-between;
    gap: 0;
    background: #000;
}

.btn-white {
    background: #fff;
    color: #000;
    flex: 1;
    border: none;
    padding: 20px 10px;
    font-weight: 900;
    font-size: 0.9rem;
    border-radius: 0;
    text-align: center;
    text-decoration: none;
    cursor: pointer;
    transition: background 0.3s;
}

.btn-white:hover {
    background: #ddd;
}

.btn-gray {
    background: #555;
    color: #fff;
    flex: 1;
    border: none;
    padding: 20px 10px;
    font-weight: 900;
    font-size: 0.9rem;
    border-radius: 0;
    text-align: center;
    text-decoration: none;
    cursor: pointer;
    transition: background 0.3s;
}

.btn-gray:hover {
    background: #333;
}

.admin-form {
    background: rgba(255, 255, 255, 0.05);
    padding: 30px;
    border-radius: 12px;
    border: 1px solid rgba(255, 0, 0, 0.3);
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: bold;
}

.form-group input {
    width: 100%;
    padding: 12px;
    border-radius: 6px;
    border: 1px solid #555;
    background: #222;
    color: #fff;
    font-family: 'Montserrat', sans-serif;
}

.form-group input[type="file"] {
    padding: 9px;
    background: #111;
}

.btn-red,
.btn.btn-red {
    background: #ff0000;
    color: #ffffff;
    border: 2px solid #ff0000;
    margin-top: 10px;
    padding: 15px;
    border-radius: 6px;
    font-weight: bold;
    cursor: pointer;
}

.btn-red:hover,
.btn.btn-red:hover {
    background: #cc0000;
    border-color: #cc0000;
    color: #ffffff;
}

/* =========================================
   3D & ANIMATION UTILITIES
   ========================================= */
.reveal {
    opacity: 0;
    transform: translateY(50px);
    transition: all 0.8s cubic-bezier(0.5, 0, 0, 1);
}

.reveal.active {
    opacity: 1;
    transform: translateY(0);
}

.tilt-element {
    transition: transform 0.4s ease-out;
    transform-style: preserve-3d;
    backface-visibility: hidden;
}

/* =========================================
   DISCOVER SECTION (QUESTO E' SCHOOLBREAK)
   ========================================= */
.discover-section {
    padding: 180px 0 80px 0;
    /* Aumentato vistosamente il padding top per far iniziare il testo più in basso (sul nero pieno) */
    background: linear-gradient(to bottom, transparent 0%, var(--bg-dark) 200px, var(--bg-dark) 100%);
}

.discover-heading {
    text-align: center;
    font-size: 1.8rem;
    /* Titolo più piccolo su mobile */
    font-weight: 900;
    margin-bottom: 50px;
    letter-spacing: 2px;
}

.discover-grid {
    display: grid;
    grid-template-columns: repeat(1, 1fr);
    gap: 30px;
}

@media (min-width: 768px) {
    .discover-heading {
        font-size: 2.5rem;
        /* Ripristino dimensione su desktop */
    }
}

@media (min-width: 900px) {
    .discover-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

.discover-card {
    position: relative;
    aspect-ratio: 1 / 1;
    border-radius: 12px;
    overflow: hidden;
    display: block;
    text-decoration: none;
    color: var(--primary-color);
    perspective: 1000px;
}

.discover-card-bg {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-size: contain;
    /* Foto intera senza tagliare nulla */
    background-position: center;
    /* Foto centrata nel riquadro */
    background-repeat: no-repeat;
    background-color: #111;
    /* Sfondo scuro per coprire i vuoti ai lati */
    transition: transform 0.8s ease;
    z-index: 1;
}

.discover-card:hover .discover-card-bg {
    transform: scale(1.1);
}

.discover-card::after {
    /* Gradient overlay to make text readable */
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 70%;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.9), transparent);
    z-index: 2;
}

/* Rimosse classi sostitutive .card-1, .card-2, .card-3 che sovrascrivevano le foto vere */

.discover-card-content {
    position: absolute;
    bottom: 30px;
    left: 30px;
    right: 30px;
    z-index: 3;
    transform: translateZ(30px);
}

.discover-card-content h3 {
    font-size: 2.2rem;
    font-weight: 900;
    margin-bottom: 10px;
    text-transform: uppercase;
    text-shadow: 2px 2px 10px rgba(0, 0, 0, 0.8);
}

.discover-card-content p {
    font-size: 1rem;
    color: #ccc;
    font-weight: 400;
}

/* =========================================
   FOOTER SECTION
   ========================================= */
.main-footer {
    background-color: #050505;
    border-top: 1px solid #1a1a1a;
    padding: 60px 0 20px;
    color: #aaa;
    font-size: 0.9rem;
    position: relative;
    z-index: 5;
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 40px;
}

.footer-col {
    flex: 1;
    min-width: 200px;
}

.footer-col-logo {
    display: flex;
    align-items: center;
}

.footer-logo {
    max-width: 150px;
    filter: brightness(0) invert(1);
    opacity: 0.8;
}

.footer-icon {
    margin-right: 15px;
    color: #ff0000;
    margin-top: 2px;
}

.footer-col-contact,
.footer-col-location {
    display: flex;
    align-items: flex-start;
}

.footer-text-block h4,
.footer-col-social h4 {
    color: var(--primary-color);
    font-weight: 700;
    margin-bottom: 5px;
    text-transform: uppercase;
    font-size: 1rem;
}

.footer-text-block a {
    color: #aaa;
    text-decoration: none;
    transition: color 0.3s;
}

.footer-text-block a:hover {
    color: var(--primary-color);
}

.footer-social-icons {
    display: flex;
    gap: 15px;
    margin-top: 15px;
}

.footer-social-icons a {
    color: #aaa;
    background: #111;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.3s ease;
}

.footer-social-icons a:hover {
    color: var(--primary-color);
    background: #ff0000;
    transform: translateY(-3px);
}

.footer-divider {
    max-width: 1200px;
    margin: 40px auto 20px;
    height: 1px;
    background-color: #1a1a1a;
}

.footer-bottom {
    text-align: center;
    font-size: 0.75rem;
    color: #666;
    padding: 0 20px;
}