

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'polymath', -apple-system, BlinkMacSystemFont, sans-serif;
    line-height: 1.6;
    color: #2c3e3a;
    background: var(--color-bg-light);
}

/* Hero */
.hero {
    min-height: 100dvh;
    background-image: url(hero.png);
    background-position: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: space-evenly;
    padding: 2rem;
    position: relative;
}
.hero-title {
    display: none;
}

.desktop {
    display: block;
   
}
.mobile {
    display: none;
}

.hero-logo-img {
    height: 70px;
}

.hero-title-img {
    width: 100%;
    height: auto;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 8px;
    background: linear-gradient(90deg, var(--color-sage) 0%, var(--color-teal) 50%, var(--color-orange) 100%);
}

.hero-nav {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem 3rem;
    z-index: 10;
}



.sponsor-img {
    height: 70px;
}
.sponsor-img-anci {
    height: 550px;
    margin-top: -100px;
    margin-right: -50px;
    margin-bottom: -100px;
}

.sponsor-img-comune {
    height: 120px;
}
.sponsor-img-cdp {
    height: 120px;
}

.hero-ticket-btn {
    padding: 0.9rem 2.5rem;
    background: white;
    color: var(--color-teal);
    border: 3px solid var(--color-teal);
    border-radius: 50px;
    font-weight: 800;
    text-transform: uppercase;
    cursor: pointer;
    transition: all 0.3s;
    text-decoration: none;
    font-size: 1rem;
    
}

.hero-ticket-btn:hover {
    background: var(--color-teal);
    color: white;
}

.hero-content {
    text-align: center;
    z-index: 2;
}

.hero-location {
    display: inline-flex;
    align-items: center;
    gap: 0.7rem;
    background: white;
    color: var(--color-teal);
    padding: 0.85rem 2.2rem;
    border-radius: 50px;
    font-weight: 700;
    margin-bottom: 2rem;
    font-size: 1.05rem;
}

.hero h1 {
    font-size: 7.5rem;
    margin-bottom: 2rem;
    text-transform: uppercase;
    font-family: "arsenica-variable",sans-serif;
    font-variation-settings: 'wght' 600, 'opsz' 980;
    line-height: 0.9;
    color: var(--color-red);
}

.hero-subtitle {
    font-size: 1.7rem;
    font-family: 'polymath', -apple-system, BlinkMacSystemFont, sans-serif;
    color: var(--color-teal-dark);
    font-weight: 400;
    margin: 1%;
}
.hero-subtitle-date {
    font-weight: 600;
}

/* Navbar */
.navbar {
    position: fixed;
    top: -100px;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: 0 4px 30px rgba(0,0,0,0.1);
    padding: 1rem 3rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 1000;
    transition: top 0.4s;
}

.navbar.visible {
    top: 0;
}

.navbar-logo-img {
    height: 45px;
    display: block;
}

.nav-links {
    display: flex;
    gap: 2.5rem;
    list-style: none;
}

.nav-links a {
    text-decoration: none;
    color: var(--color-teal-dark);
    font-weight: 700;
    font-size: 0.95rem;
    transition: color 0.3s;
}

.nav-links a:hover {
    color: var(--color-teal);
}

/* Stats */
.stats-section {
    background: var(--color-orange);
    padding: 2rem
}

.stats-container {
    max-width: 1200px;
    color: white;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 5rem;
}

.stat-item {
    text-align: center;
    padding: 3.5rem 2rem;
    border: 5px solid var(--color-yellow);
    transition: transform 0.3s;
}

.box1 {
    border-radius: 58% 42% 57% 43% / 58% 45% 55% 42% ;
}

.box2 {
    border-radius: 60% 40% 48% 52% / 40% 45% 55% 60% 
}

.box3 {
    border-radius: 41% 59% 57% 43% / 27% 45% 55% 73% ;
}

.stat-number {
    font-size: 8.5rem;
    font-family: "arsenica-variable",sans-serif;
    font-variation-settings: 'wght' 600, 'opsz' 980;
    line-height: 1;
}

.stat-label {
    font-size: 1.3rem;
    font-weight: 500;
    text-transform: uppercase;
}

/* Info Banner */
.info-banner {
    background: var(--color-orange);
    padding: 4rem 3rem;
    display: grid;
    grid-template-columns: 1fr 1fr;
    color: white;
}

.info-banner-item {
    text-align: center;
}

.info-banner-label {
    font-size: 1.15rem;
    margin-bottom: 2rem;
    font-weight: 600;
}

.info-banner-text {
    font-size: 3.5rem;
    font-weight: 900;
    text-transform: uppercase;
    line-height: 1.2;
}

/* Agenda - EXACT Groovory Structure */
.agenda-section {
    background: var(--color-bg-light);
    padding: 3rem 0 8rem 0 ;
}

.agenda-header {
    text-align: center;
    margin-bottom: 0; /* Rimosso margin, la sidebar è subito sotto */
}

.agenda-header h2 {
    font-size: 5.5rem;
    margin-bottom: 2rem;
    font-weight: 900;
    text-transform: uppercase;
    color: var(--color-teal);
}

/* Rimuove il grid, ora è layout verticale */
.agenda-container {
    display: block;
    max-width: 1600px;
    margin: 0 auto;
    padding: 0;
}
/* Sidebar orizzontale sticky */
.days-sidebar {
    position: sticky;
    top: 77px; /* Altezza della navbar */
    z-index: 100;
    background: var(--color-bg-light);
    display: flex;
    flex-direction: row;
    overflow-x: auto;
    gap: 0.5rem;
    padding: 1rem 2rem;
    border-bottom: 2px solid rgba(82, 166, 130, 0.15);
    margin-bottom: 3rem;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none; /* Nasconde scrollbar Firefox */
    justify-content: space-evenly;
}

.days-sidebar::-webkit-scrollbar {
    display: none; /* Nasconde scrollbar Chrome/Safari */
}

.day-link {
    display: block;
    font-size: 1.4rem;
    font-weight: 900;
    color: #ddd;
    text-transform: uppercase;
    text-align: center;
    padding: 0.5rem 0.8rem;
    cursor: pointer;
    transition: all 0.3s;
    border-radius: 10px;
    line-height: 1.1;
    flex-shrink: 0;
    white-space: nowrap;
    margin-bottom: 0;
}

.day-link.active {
    color: var(--color-sage);
    background: rgba(82, 166, 130, 0.1);
}


/* Content occupa tutta la larghezza */
.days-content {
    display: flex;
    flex-direction: column;
    gap: 5rem;
    padding: 0 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

/* Day Section */
.day-section {
    scroll-margin-top: 180px;
}

/* Day Header - Title + Time Range */
.day-header {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    margin-bottom: 3rem;
}

.day-title {
    font-size: 3.5rem;
    font-weight: 900;
    color: var(--color-sage);
    text-transform: uppercase;
}

.day-hours {
    font-size: 2.5rem;
    font-weight: 900;
    color: var(--color-sage);
    opacity: 0.3;
}

/* Events with timeline */
.events-list {
    position: relative;
    padding-left: 100px;
}

/* Vertical line */
.events-list::before {
    content: '';
    position: absolute;
    left: 0;
    top: 30px;
    bottom: 0;
    width: 2px;
    background: var(--color-sage);
}

/* Single Event */
.event {
    position: relative;
    margin-bottom: 2rem;
}

/* Time marker on left */
.event-time {
    position: absolute;
    left: -80px;
    top: 20px;
    font-size: 1.3rem;
    font-weight: 900;
    color: var(--color-sage);
}

/* Dot on line */
.event-dot {
    position: absolute;
    left: -7px;
    top: 28px;
    width: 16px;
    height: 16px;
    background: white;
    border: 3px solid var(--color-sage);
    border-radius: 50%;
}

/* Event Card */
.event-card {
    background: white;
    border-radius: 18px;
    overflow: hidden;
    margin-left: 20px;
    transition: all 0.3s;
    cursor: pointer;
}

.event-teatro {
    border: 3px solid var(--color-teatro);
}

.event-laboratorio {
    border: 3px solid var(--color-laboratori);
}

.event-cinema {
    border: 3px solid var(--color-cinema);
}

.event-musica {
    border: 3px solid var(--color-musica);
}


.event-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(82, 166, 130, 0.15);
}

/* Event Header */
.event-header {
    padding: 1.8rem 2.2rem 1.5rem;
    position: relative;
}

.event-time-range {
    font-size: 0.85rem;
    color: var(--color-sage);
    display: none;
    font-weight: 700;
    margin-bottom: 0.7rem;
}

.event-title {
    font-size: 1.8rem;
    font-weight: 900;
    text-transform: uppercase;
    margin-bottom: 0.5rem;
    line-height: 1.1;
}

.event-title-teatro {
    color: var(--color-teatro);
}

.event-title-cinema {
    color: var(--color-cinema);
}

.event-title-laboratorio {
    color: var(--color-laboratori);
}
.event-title-musica {
    color: var(--color-musica);
}



.event-description {
    font-size: 0.95rem;
    color: #666;
    line-height: 1.4;
}

/* Don't Miss Badge */
.event-badge {
    position: absolute;
    top: 1.8rem;
    right: 2.2rem;
    background: var(--color-red);
    color: white;
    padding: 0.4rem 1rem;
    border-radius: 20px;
    font-size: 0.65rem;
    font-weight: 900;
    text-transform: uppercase;
}

/* Event Footer - 3 columns like Groovory but with duration removed, keeping only 2 */
.event-footer {
    background: var(--color-sage);
    padding: 1.2rem 2.2rem;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    color: white;
}

.event-footer-laboratorio {
    background: var(--color-laboratori);
}
.event-footer-teatro {
    background: var(--color-teatro);
}
.event-footer-cinema {
    background: var(--color-cinema);
}
.event-footer-musica {
    background: var(--color-musica);
}

.emoji {
        max-height: 0.9rem;
}

.event-info {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
}

.event-icon {
    width: 13px;
    height: 13px;
}

/* Contacts Section */
.contacts-section {
    background: white;
    padding: 7rem 2rem;
}

.contacts-container {
    max-width: 1200px;
    margin: 0 auto;
    text-align: center;
}

.contacts-container h2 {
    font-size: 4.5rem;
    font-weight: 900;
    color: var(--color-teal);
    text-transform: uppercase;
    margin-bottom: 1rem;
}

.contacts-subtitle {
    font-size: 1.2rem;
    color: #666;
    margin-bottom: 4rem;
}

.contacts-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 3rem;
}

.contact-item {
    background: var(--color-bg-light);
    padding: 3rem 2rem;
    border-radius: 25px;
    transition: transform 0.3s;
}

.contact-icon {
    width: 50px;
    height: 50px;
    background: var(--color-teal);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    color: white;
    font-size: 1.5rem;
}

.contact-label {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--color-teal);
    margin-bottom: 0.5rem;
    text-transform: uppercase;
}

.contact-value {
    font-size: 1.3rem;
    font-weight: 600;
    color: #555;
}

.contact-value a {
    color: #555;
    text-decoration: none;
    transition: color 0.3s;
}

.contact-value a:hover {
    color: var(--color-teal);
}

    /* Map Section */
.map-section {
    background: white;
    padding: 4rem 2rem;
}

.map-container {
    max-width: 1200px;
    margin: 0 auto;
    text-align: center;
}

.map-container h2 {
    font-size: 4.5rem;
    font-weight: 700;
    line-height: 0.9;
    color: var(--color-teal);
    margin-bottom: 1rem;
}

.map-subtitle {
    font-size: 1.2rem;
    color: #666;
    margin-bottom: 4rem;
}

.map-grid {
    display: flex;
    background-color: white;
    align-items: center;
    justify-content: center;
    gap: 3rem;
}

.map-frame {
    border:0;
    width: 50vw;
    height: 70dvh;
}

/* Sponsors Section */
.sponsors-section {
    background: var(--color-sage-light);
    padding: 7rem 2rem;
}

.sponsors-container {
    max-width: 1200px;
    margin: 0 auto;
    text-align: center;
}

.sponsors-container h2 {
    font-size: 4.5rem;
    font-weight: 900;
    color: white;
    text-transform: uppercase;
    margin-bottom: 1rem;
}

.sponsors-subtitle {
    font-size: 1.3rem;
    color: white;
    margin-top: 2rem;
    margin-bottom: 1rem;
}

.sponsors-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2vw;
}
.sponsors-istituzionali {
    display: flex;
    background-color: white;
    border-radius: 30px;
    align-items: center;
    justify-content: center;
    gap: 3rem;
}

.sponsor-item {
    background: white;
    padding: 2%;
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.3s;
}


.sponsor-logo {
    justify-content: center;
    display: flex;
}

/* Footer */
footer {
    background: var(--color-teal-dark);
    color: white;
    text-align: center;
    padding: 4.5rem 2rem;
    position: relative;
}

footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 8px;
    background: linear-gradient(90deg, var(--color-sage) 0%, var(--color-teal) 50%, var(--color-orange) 100%);
}

footer p {
    font-weight: 400;
    opacity: 0.9;
    font-size: 1.05rem;
    margin: 0;
}

footer p + p {
    margin-top: 1.2rem;
}

/* Back to Top Button */
.back-to-top {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 50px;
    height: 50px;
    background: var(--color-teal);
    color: white;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    box-shadow: 0 4px 15px rgba(1, 120, 98, 0.3);
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    transition: all 0.3s ease;
    z-index: 999;
}

.back-to-top.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.back-to-top:hover {
    background: var(--color-sage);
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(82, 166, 130, 0.4);
}

.back-to-top:active {
    transform: translateY(-1px);
}


/* Responsive */
@media (max-width: 1700px) {

    .hero-date {
            padding: 1rem 1.5rem;
            font-size: 3rem;
    }
    .hero h1 {
        font-size: 6.5rem;
        margin-bottom: 0.5rem;
    }
}

/* Responsive */
@media (max-width: 1024px) {

    /* Rimuovi eventuali override dell'agenda-container e days-sidebar
       perché ora sono già impostati per funzionare su tutti i dispositivi */
    .agenda-container {
        display: block; /* Già block, nessun cambio */
    }

    .stats-container, .contacts-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .sponsors-grid {
        display: grid ;
        grid-template-columns: repeat(1, 1fr);
        gap: 1rem;
    }


}

@media (max-width: 768px) {
    /* Hero fixes */
    .hero {
        padding: 1rem;
        min-height: 100sdvh;
    }

    .desktop {
        display: none;
    }
    .mobile {
        display: block;
    }


    .hero-nav {
        padding: 1rem 1.5rem;
        align-items: center;
        justify-content: center;
        flex-wrap: wrap;
        gap: 1rem;
    }

    .hero-logo-img {
        height: 50px;
    }


    .hero-ticket-btn {
        font-size: 0.85rem;
        padding: 0.7rem 1.5rem;
    }


    .hero-location {
        font-size: 0.9rem;
        padding: 0.7rem 1.5rem;
        margin-bottom: 2rem;
    }

    .hero h1 {
        font-size: 5rem;
        margin-bottom: 1.5rem;
    }

    .hero-subtitle {
        font-size: 1.2rem;
    }

    /* Navbar fixes */
    .navbar {
        padding: 0.8rem 1.5rem;
    }


    .nav-links {
        gap: 1.5rem;
    }

    .nav-links a {
        font-size: 0.85rem;
    }

    /* Stats fixes */
    .stats-section {
        padding: 4rem 1.5rem;
    }

    .stat-item {
        padding: 2.5rem 1.5rem;
    }

    .stat-number {
        font-size: 3rem;
    }

    .stat-label {
        font-size: 1.1rem;
    }

    /* Info banner fixes */
    .info-banner {
        grid-template-columns: 1fr;
        padding: 0;
    }

    .info-banner-item {
        padding: 3rem 2rem;
    }

    .info-banner-label {
        font-size: 1rem;
        margin-bottom: 1.5rem;
    }

    .info-banner-text {
        font-size: 2rem;
    }


    /* Agenda header fixes */
    .agenda-section {
        padding: 4rem 0 5rem;
    }

    .agenda-header {
        margin-bottom: 3rem;
    }

    .agenda-header h2 {
        font-size: 3.5rem;
    }

    .days-sidebar {
        top: 70px; /* Navbar ancora più piccola su mobile */
        padding: 0.8rem 1.5rem;
        gap: 0.3rem;
    }

    .day-link {
        font-size: 1.1rem;
        padding: 0.4rem 0.6rem;
    }

    .days-content {
        padding: 0 1.5rem;
        gap: 3rem;
    }

    .day-section {
        scroll-margin-top: 180px; /* Spazio per navbar + sidebar sticky */
    }

    .day-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
        margin-bottom: 2rem;
    }

    .day-title {
        font-size: 2.5rem;
    }

    .day-hours {
        font-size: 1.5rem;
    }

    /* REMOVE timeline and time markers on mobile */
    .events-list {
        padding-left: 0;
    }

    .events-list::before {
        display: none;
    }

    .event {
        margin-bottom: 1.5rem;
    }

    .event-time {
        display: none;
    }

    .event-dot {
        display: none;
    }

    .event-card {
        margin-left: 0;
    }

    /* Event content fixes */
    .event-header {
        padding: 1rem 1.2rem 1rem;
    }

    .event-time-range {
        display: contents;
        font-size: 0.8rem;
    }

    .event-title {
        font-size: 1.4rem;
        margin-bottom: 0.5rem;
    }

    .event-description {
        font-size: 0.9rem;
    }

    .event-badge {
        position: static;
        display: inline-block;
        margin-bottom: 0.8rem;
        font-size: 0.6rem;
        padding: 0.35rem 0.9rem;
    }

    .event-footer {
        grid-template-columns: 1fr;
        padding: 1rem 1.5rem;
        gap: 0.8rem;
    }

    .event-info {
        justify-content: center;
        font-size: 0.7rem;
    }

    /* Contacts fixes */
    .contacts-section {
        padding: 4rem 1.5rem;
    }

    .contacts-container h2 {
        font-size: 3rem;
    }

    .contacts-subtitle {
        font-size: 1.1rem;
        margin-bottom: 2.5rem;
    }

    .contact-item {
        padding: 2rem 1.5rem;
    }

    .contact-icon {
        width: 45px;
        height: 45px;
        font-size: 1.3rem;
    }

    .contact-label {
        font-size: 1rem;
    }

    .contact-value {
        font-size: 1.1rem;
    }

    /* Sponsors fixes */
    .sponsors-section {
        padding: 4rem 1.5rem;
    }

    .sponsors-container h2 {
        font-size: 3rem;
    }

    .sponsors-subtitle {
        font-size: 1.1rem;
    }

    .sponsors-grid {
        gap: 2rem;
    }

    .sponsor-img-anci {
        height: auto;
        margin-right: 0px;
        max-width: 100%;
    }

    .sponsor-img-comune {
        height: 6rem;
        margin-top: 1.5rem;
    }

    .sponsor-img-cdp {
        height: 5rem;
        margin-top: 0.5rem;
    }

    .sponsors-istituzionali {
        display: flex;
        flex-direction: column;  /* Fa andare a capo */
        align-items: center;      /* Centra le immagini */
        gap: 2rem;               /* Spazio tra le immagini */
    }

    .map-grid {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 2rem;
    }

    .map-container h2 {
        font-size: 2rem;
        font-weight: 900;
        color: var(--color-teal);
        text-transform: uppercase;
        margin-bottom: 1rem;
    }

    .map-frame {
        border:0;
        width: 80vw;
        height: 30dvh;
    }
    /* Footer fixes */
    footer {
        padding: 3rem 1.5rem;
    }

    footer p {
        font-size: 0.95rem;
    }

    /* Back to top button mobile */
    .back-to-top {
        width: 45px;
        height: 45px;
        bottom: 1.5rem;
        right: 1.5rem;
        font-size: 1.3rem;
    }
}

/* Extra small devices */
@media (max-width: 480px) {
    .hero h1 {
        font-size: 4rem;
    }


    .day-title {
        font-size: 2rem;
    }


    .event-title {
        font-size: 1.2rem;
    }

    .hero-date {
        font-size: 2rem;
        padding: 0.8rem 1.5rem;
    }
}



/* NAV BAR */
.navbar-logo {
    z-index: 1500;
}
/* Hamburger Menu */
.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
    gap: 5px;
    z-index: 1001;
}


.hamburger span {
    width: 25px;
    height: 3px;
    background: var(--color-teal);
    border-radius: 3px;
    transition: all 0.3s ease;
}

.hamburger.active span:nth-child(1) {
    transform: rotate(45deg) translateY(8px);
}

.hamburger.active span:nth-child(2) {
    opacity: 0;
}

.hamburger.active span:nth-child(3) {
    transform: rotate(-45deg) translateY(-8px);
}

/* Mobile Navigation */
@media (max-width: 768px) {
    .hamburger {
        display: flex;
    }

    .nav-links {
        position: fixed;
        top: 0;
        right: -100%;
        width: 100%;
        height: auto;
        background: white;
        flex-direction: column;
        padding: 5rem 2rem 2rem;
        gap: 2rem;
        box-shadow: -5px 0 15px rgba(0,0,0,0.1);
        transition: height 4s ease;
        z-index: 1000;
    }

    .nav-links.active {
        right: 0;
    }

    .nav-links li {
        width: 100%;
    }

    .nav-links a {
        font-size: 1.1rem;
        display: block;
        padding: 0.5rem 0;
    }

    /* Overlay scuro quando menu aperto */
    .nav-overlay {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100dvh;
        background: rgba(0, 0, 0, 0.5);
        opacity: 0;
        visibility: hidden;
        transition: all 0.3s ease;
        z-index: 999;
    }

    .nav-overlay.active {
        opacity: 1;
        visibility: visible;
    }
}