/* ===============================================
   1. Generali & Reset CSS (Base Styles)
   =============================================== */
html, body {
    height: 100%;
    margin: 0;
    padding: 0;
    color: #333;
    box-sizing: border-box;
}

body {
    display: flex; /* Utilizza flex per la struttura principale */
    flex-direction: column;
    font-family: 'Roboto', sans-serif;
    font-size: 16px; /* Coerente con il valore più recente */
    line-height: 1.6;
    font-weight: 400;
    min-width: 320px;
}

/* Link "skip-link" per accessibilità */
.skip-link {
    color: white;
    position: absolute;
    left: -9999px;
    top: auto;
    width: 1px;
    height: 1px;
    overflow: hidden;
    z-index: -999;
}

.skip-link:focus {
    position: static;
    width: auto;
    height: auto;
    background-color: #4b7c4d; /* Colore di sfondo per il focus */
    color: white;
    padding: 8px;
    margin: 10px;
    z-index: 999;
    outline: 2px solid white;
    outline-offset: -2px;
}


/* ===============================================
   2. Tipografia (Typography)
   =============================================== */
@font-face {
    font-family: 'vcr_osd_monoregular';
    src: url('/dam/fonts/vcr_font.woff2') format('woff2'), /* Preferisci woff2 per browser moderni */
         url('/dam/fonts/vcr_font.woff') format('woff');  /* Fallback per browser meno recenti */
    font-weight: normal;
    font-style: normal;
}

h1, .title, #film-title {
    font-family: 'vcr_osd_monoregular', sans-serif;
    color: #4b7c4d;
    font-size: 32px; /* Coerente con la versione più recente */
    font-weight: normal;
    margin: 10px 0 40px 0;
    text-align: center;
}

h1 .homepage-subtitle {
    display: block;
    font-size: 24px; /* Sottotitolo più piccolo per h1 */
    font-weight: 400;
}

h2, #title-h2 {
    font-family: 'vcr_osd_monoregular', sans-serif;
    color: #4b7c4d;
    font-size: 24px;
    font-weight: normal;
    margin: 8px 0 6px 0;
    text-align: center;
}

/* Film title as h3 - styled to match original film-title-link */
.film-title-heading {
    font-family: 'vcr_osd_monoregular', sans-serif;
    color: #4b7c4d;
    font-size: 20px;
    font-weight: normal;
    margin: 0;
    display: inline;
    text-align: left;
    line-height: 1.3;
}

.film-title-heading a {
    color: inherit;
    text-decoration: none;
}

.film-title-heading a:hover {
    text-decoration: underline;
}

h3, #films-today h3 {
    font-family: 'vcr_osd_monoregular', sans-serif;
    color: #4b7c4d;
    font-size: 20px;
    font-weight: normal;
    margin: 6px 0 4px 0;
    text-align: center;
}


/* ===============================================
   3. Layout Globale & Contenitori Principali
   =============================================== */
main {
    flex: 1;
    padding-left: 3%;
    padding-right: 3%;
    box-sizing: border-box;
    background-color: #f9f9f9;
    display: block;
}

.main-outer {
    padding-top: 90px;
    padding-bottom: 20px;
    margin-right: auto;
    margin-left: auto;
}

#programmazione, #film-details, .cta-button-container {
    max-width: 90%;
    margin: auto;
}

.text-container {
    margin: 0 auto;
    text-align: left;
}


/* ===============================================
   4. Header (Intestazione)
   =============================================== */
header {
    background-color: #ffffff;
    box-shadow: 0 4px 6px rgba(40, 38, 38, 0.1);
    position: fixed;
    top: 0;
    width: -webkit-fill-available;
    z-index: 1000;
    transition: all 0.3s ease;
    padding: 10px 20px;
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    box-sizing: border-box;
    transition: all 0.3s ease;
}

.header-container h1 {
    margin: 0;
    display: flex;
    align-items: center;
    transition: all 0.3s ease;
}

.logo-header {
    display: block;
    max-height: 50px;
    max-width: 50%;
    height: auto;
}

/* Header States */
.header-shrink {
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    height: 5%; /* Questo valore potrebbe essere troppo piccolo, verifica la resa */
}

.header-shrink .logo-header {
    width: 250px;
    max-height: 50px;
    max-width: 70%;
    transition: all 0.3s ease;
}

.header-shrink nav ul li {
    margin-right: 15px;
}


/* ===============================================
   5. Navigazione (Navigation) - Mobile First
   =============================================== */
nav {
    display: none; /* Nascosto di default su mobile */
    flex-direction: column;
    position: absolute;
    top: 90px; /* Sotto l'header */
    right: 20px;
    max-width: 400px;
    background-color: #fff;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    border-radius: 8px;
}

nav.open {
    display: flex;
    transition: all 0.3s ease;
}

nav ul {
    list-style: none;
    padding: 10px 0;
    margin: 0;
    font-family: 'Roboto', sans-serif;
    font-size: 16px;
    font-weight: 500;
    color: #333;
    letter-spacing: 0.02em;
    transition: all 0.3s ease;
    flex-direction: column;
    width: 100%;
}

nav ul.open {
    display: flex;
    transition: all 0.3s ease;
}

nav ul li {
    position: relative;
}

nav ul li a {
    text-decoration: none;
    padding: 12px 15px;
    display: flex;
    color: #333;
    line-height: 1;
    align-items: center;
    border-radius: 4px;
    margin: 2px 8px;
    transition: background-color 0.2s ease;
    justify-content: flex-end;
    font-weight: bold;
    font-size: 18px; /* Dalla regola specifica per header nav ul li a */
}

nav ul li a:hover {
    background-color: #f5f5f5;
}

/* Dropdown Menu */
nav ul li.show .dropdown-content {
    display: block;
}

.dropdown-content {
    display: none;
    position: static; /* Cambiato da absolute per mobile */
    top: 100%;
    left: 0;
    background-color: #fff;
    min-width: 160px;
    box-shadow: none; /* Rimosso shadow per mobile, se static */
    z-index: 1;
}

.dropdown-content li {
    margin: 0;
}

.dropdown-content li a {
    padding: 12px 15px;
    color: #333;
    background-color: #fff;
    margin: 2px 8px;
    border-radius: 4px;
    transition: background-color 0.2s ease;
}

.dropdown-content li a:hover {
    background-color: #f1f1f1;
}

/* Hamburger Menu */
.hamburger-menu {
    display: flex;
    width: 60px;
    height: 50px;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.hamburger-menu svg, .hamburger-menu img {
    max-width: 60%;
    max-height: 50px;
    display: block;
}

.hamburger-icon.hidden {
    display: none;
}

.hamburger-icon.visible {
    display: block;
}

nav ul li img {
    vertical-align: middle;
}


/* ===============================================
   6. Breadcrumbs (Percorso di Navigazione)
   =============================================== */
.breadcrumb-nav {
    display: flex;
    position: static; /* Static per permettere il flusso normale */
    top: auto;
    right: auto;
    max-width: none;
    width: 100%;
    box-sizing: border-box;
    box-shadow: none;
    background-color: transparent; /* Nessun background specifico */
    font-size: 12px; /* Base size per mobile */
}

.breadcrumb-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
}

.breadcrumb-item {
    display: flex;
    align-items: center;
    white-space: nowrap;
}

.breadcrumb-item a {
    text-decoration: none;
    color: #17183B;
    font-weight: normal;
}

.breadcrumb-item a:hover {
    text-decoration: underline;
}

.breadcrumb-item span[aria-current="page"] {
    color: #333;
    font-weight: bold;
}

.breadcrumb-separator {
    margin: 0 5px;
    color: #888;
}


/* ===============================================
   7. Form & Ricerca (Forms & Search)
   =============================================== */
#search {
    display: flex;
    flex-direction: column;
    align-items: center;
}

#searchForm {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    width: 100%;
    max-width: 300px;
}

.search-container {
    display: flex;
    flex-direction: column;
    margin-top: 20px;
    margin-bottom: 20px;
}

#searchInput {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 20px; /* Coerente con i bottoni */
}


/* ===============================================
   8. Pulsanti & CTA (Buttons & Call-to-Actions)
   =============================================== */
button,
.cta-button {
    display: inline-block;
    padding: 10px 20px;
    border-radius: 20px; /* Coerente con la versione più recente */
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: center;
    margin: 10px 0;
    display: block; /* Per far sì che prendano la larghezza disponibile */
    margin-left: auto;
    margin-right: auto;
}

/* CTA primaria */
button.primary,
.cta-button.primary {
    background-color: #17183B;
    border: 1px solid #17183B;
    color: #fff;
}

button.primary:hover,
.cta-button.primary:hover {
    background-color: #0f1030;
}

/* CTA secondaria */
button.secondary,
.cta-button.secondary {
    background-color: transparent;
    border: 1px solid #17183B;
    color: #17183B;
}

button.secondary:hover,
.cta-button.secondary:hover {
    background-color: #f0f0f5;
}

/* Contenitore per i pulsanti CTA */
.cta-button-container {
    display: flex;
    flex-direction: column; /* Colonna su mobile */
    align-items: center;
}

/* Sezione generale per le CTA (se necessario un wrapper) */
.cta-section {
    display: flex;
    justify-content: center;
    padding: 20px;
}


/* ===============================================
   9. Liste Generiche (General Lists)
   =============================================== */
#film-list, #screenings-list, #today-film-list {
    list-style-type: none;
    padding: 0;
    margin: 0;
}

#film-list li, #screenings-list li, #today-film-list li {
    padding: 10px;
    margin: 10px 0;
    background-color: #e0f7fa;
    border-radius: 8px;
}

#film-list a, #screenings-list a, #today-film-list a {
    text-decoration: none;
    color: #1919ee;
}

#film-list a:hover, #screenings-list a:hover, #today-film-list a:hover {
    color: #0000cc;
}

/* Contenitore per proiezioni passate (toggleable) */
.past-dates-container {
    list-style-type: none;
    padding: 0;
    margin: 0;
}

.no-screenings-message {
    text-align: center;
    font-size: 18px;
    color: #555;
    padding: 25px 30px;
    font-weight: 500;
    background: #f8f9fa;
    border-left: 6px solid #dc3545;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    position: relative;
    margin-top: 40px;
    margin-bottom: 40px;
    margin-right: auto;
    margin-left: auto;
    max-width: 750px;
}

.no-screenings-message::before {
    content: "⚠️";
    font-size: 24px;
    display: block;
    margin-bottom: 10px;
}


/* ===============================================
   10. Dettagli Film (Film Details)
   =============================================== */
#film-details {
    display: none; /* Gestito da JavaScript */
    text-align: center;
    margin-top: 20px;
}

#film-poster {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    display: block;
    margin: auto;
}

#film-synopsis {
    margin: 10px 0;
}

.poster-container,
.synopsis-container {
    margin-bottom: 16px;
}

.poster-container {
    text-align: center;
}

.synopsis-container h3 {
    margin-bottom: 8px;
    color: #333;
    font-size: 1.1em;
}


/* ===============================================
   11. Arene (Arena Specifics)
   =============================================== */
.arena-cards-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); /* Responsive grid */
    gap: 20px;
    margin-top: 30px;
    justify-content: center;
}

.arena-card {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 200px;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    text-decoration: none;
    color: white;
    font-family: 'vcr_osd_monoregular', sans-serif;
    font-size: 24px;
    background-size: cover;
    background-position: center;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    position: relative;
}

.arena-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.4);
    transition: background 0.3s ease;
}

.arena-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
}

.arena-card:hover::before {
    background: rgba(0, 0, 0, 0.5);
}

.arena-card h2 {
    margin: 0;
    color: white;
    z-index: 1;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.6);
}

/* Immagini di background specifiche per ogni arena */
/* Arena background images removed - files don't exist */


/* ===============================================
   12. Loading Overlay (Sovrapposizione di Caricamento)
   =============================================== */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.85);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    color: white;
    font-size: 1.2em;
    z-index: 10000;
    display: none;
}

.loading-content p {
    margin-top: 20px;
    font-size: 18px;
}

.spinner {
    border: 4px solid rgba(255, 255, 255, 0.3);
    border-top: 4px solid #ffffff;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    animation: spin 1s linear infinite;
    margin: 0 auto;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}


/* ===============================================
   13. Stati delle Date (Date States)
   =============================================== */
.past-date {
    color: #a0a0a0;
}

.past-date a {
    color: #6c6c6c;
}

.past-date a:hover {
    color: #5a5a5a;
}

.today-date {
    font-weight: bold;
    background-color: #e6ffe6;
    border-left: 5px solid #4CAF50;
    padding-left: 15px;
    box-sizing: border-box;
}

.today-date a {
    color: #4CAF50;
}

.today-date a:hover {
    color: #388E3C;
}


/* ===============================================
   14. Calendario (Calendar Specifics)
   =============================================== */

/* Date formatting styles */
.date-main {
    display: block;
}

.date-weekday {
    display: block;
    margin-top: 0;
    margin-bottom: 24px;
    font-family: 'vcr_osd_monoregular', sans-serif;
    color: #4b7c4d;
    font-size: 20px;
    font-weight: normal;
    text-align: center;
    line-height: 0.5;
}

/* Stili generali per le sezioni giorno */
.calendar-day-section {
    margin-bottom: 25px;
    padding: 20px;
    border: 1px solid #e0e0e0;
    border-radius: 10px;
    background-color: #ffffff;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.08);
    width: 90%; /* Occupa il 90% della larghezza disponibile del suo contenitore */
    max-width: 500px; /* Limite massimo per evitare che diventi troppo largo su schermi più grandi */
    margin-left: auto; /* Centra la sezione orizzontalmente */
    margin-right: auto; /* Centra la sezione orizzontalmente */
}

/* Stile per il titolo del giorno (assumendo H2 come da JS) */
.calendar-day-section h2 { /* Modificato da h3 per coerenza con JS */
    font-family: 'vcr_osd_monoregular', sans-serif;
    color: #4b7c4d;
    font-size: 20px;
    margin-top: 0;
    text-align: center;
    line-height: 1.2;
    margin-bottom: 20px;
}

/* Make weekday smaller in calendar day titles */
.calendar-day-section h2 .weekday {
    font-size: 0.75em;
}

/* Stile per il contenitore delle proiezioni all'interno di un giorno */
.films-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
    border-top: 3px solid #4b7c4d;
    padding-top: 15px;
}

/* Stile per ogni singola proiezione del film */
.film-entry {
    padding: 10px 20px;
    border: 1px solid #e0e0e0;
    border-radius: 10px;
    background-color: #ffffff;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.08);
}

.film-entry.past-show {
    color: #a0a0a0;
    background-color: #f2f2f2;
    border-color: #e0e0e0;
    box-shadow: none;
}

.film-entry.past-show .show-time,
.film-entry.past-show .arena-info,
.film-entry.past-show .film-title-link {
    color: #6c6c6c; /* Colore testo per proiezioni passate */
    text-align: left;
}
.film-entry.past-show .film-title-link:hover {
    color: #5a5a5a;
}

/* Stile per le proiezioni di oggi all'interno di film-entry */
.film-entry.today-show { /* Usato da JS come today-show */
    background-color: #e6ffe6;
    border: 2px solid #4CAF50;
    box-shadow: 0 4px 12px rgba(76, 175, 80, 0.3);
}

.film-entry.today-show .show-time,
.film-entry.today-show .arena-info,
.film-entry.today-show .film-title-link {
    color: #4CAF50;
}
.film-entry.today-show .film-title-link:hover {
    color: #388E3C;
}

.film-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
}

.film-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
    flex: 1; /* Permette al blocco info di espandersi */
}

.show-time {
    font-weight: bold;
    font-size: 16px;
    color: #333;
}

.film-title-link {
    font-size: 18px;
    color: #17183B;
    text-decoration: none;
    font-weight: bold;
}

.film-title-link:hover {
    text-decoration: underline;
}

.arena-info {
    font-size: 18px;
    color: #666;
}

/* Stile per le sezioni dei giorni passati nel calendario a lista */
.calendar-day-section.past-date {
    color: #a0a0a0;
    background-color: #f2f2f2;
    border-color: #e0e0e0;
    box-shadow: none;
    margin-top: 40px;
}

.calendar-day-section.past-date h2 { /* Modificato da h3 per coerenza con JS */
    color: #a0a0a0;
}

.past-date .date-weekday {
    color: #a0a0a0;
}

.past-date .films-list {
    border-top-color: #a0a0a0;
}

/* Stile per la sezione del giorno corrente (nuovo) */
.calendar-day-section.today-date-section {
    background-color: #e6ffe6;
    border: 2px solid #4CAF50;
    box-shadow: 0 4px 12px rgba(76, 175, 80, 0.3);
}

.calendar-day-section.today-date-section h2 { /* Modificato da h3 per coerenza con JS */
    color: #4CAF50;
}

/* Pulsante & Menu Calendario (Aggiunto dalla sezione dedicata nel JS) */
.add-to-calendar-btn {
    border: none;
    background: transparent;
    cursor: pointer;
    padding: 8px;
    border-radius: 20px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    position: relative;
}

.add-to-calendar-btn:hover {
    background-color: rgba(0, 0, 0, 0.05);
}

.add-to-calendar-btn:active {
    transform: scale(0.95);
}

.calendar-icon {
    display: block;
    width: 35px; /* Coerente con la versione più recente */
    height: 35px;
    object-fit: contain;
}

.add-to-calendar-btn--compact .calendar-icon {
    width: 24px;
    height: 24px;
}

.calendar-icon--bg {
    display: inline-block;
    width: 35px;
    height: 35px;
    background-image: url('/dam/images/calendar.svg');
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
}

.calendar-menu {
    background: #ffffff;
    border: 1px solid #e1e5e9;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    padding: 8px 0;
    min-width: 180px;
    max-width: 250px;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    font-size: 14px;
    animation: menuFadeIn 0.15s ease-out;
    box-sizing: border-box;
}

@keyframes menuFadeIn {
    from {
        opacity: 0;
        transform: translateY(-8px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.calendar-menu-item {
    display: flex;
    align-items: center;
    padding: 10px 16px;
    cursor: pointer;
    transition: background-color 0.15s ease;
    gap: 12px;
}

.calendar-menu-item:hover {
    background-color: #f8f9fa;
}

.calendar-menu-item:active {
    background-color: #e9ecef;
}

.calendar-provider-icon {
    display: inline-block;
    width: 20px;
    height: 20px;
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
    flex-shrink: 0;
}

.google-icon { background-image: url('/dam/images/calendar-google.svg'); }
.apple-icon { background-image: url('/dam/images/calendar-apple.svg'); }
.outlook-icon { background-image: url('/dam/images/calendar-outlook.svg'); }

.add-to-calendar-btn--with-text .calendar-icon {
    margin-right: 8px;
}

.add-to-calendar-btn--with-text::after {
    content: "Aggiungi al calendario";
    font-size: 14px;
}

.add-to-calendar-btn--compact {
    padding: 4px;
}

.add-to-calendar-btn--compact .calendar-icon {
    width: 18px;
    height: 18px;
}


/* ===============================================
   15. Footer (Piè di Pagina)
   =============================================== */
footer {
    background-color: #f1f1f1;
    text-align: center;
    box-shadow: 0 -4px 6px rgba(40, 38, 38, 0.1);
}

.footer-text {
    font-size: 15px; /* Spostato qui da media query desktop */
}


/* ===============================================
   16. Media Queries (Responsive Design & Temi)
   =============================================== */

/* Desktop Breakpoint (1024px and up) */
@media (min-width: 1024px) {
    /* Typography scaling */
    h1, .title, #film-title {
        font-size: 40px;
    }
    h2, #title-h2 {
        font-size: 32px;
    }
    h3, #films-today h3 {
        font-size: 24px;
    }
    body, main, p, li, nav ul li a {
        font-size: 18px;
    }

    .breadcrumb-nav {
        font-size: 12px !important;
    }
    /* Header */
    header {
        flex-direction: column; /* I suoi figli (header-container e breadcrumb-nav) si impileranno */
    }
    .logo-header {
        max-width: 50%;
    }

    /* Navigation - Desktop */
    .hamburger-menu {
        display: none;
    }
    nav {
        display: flex;
        position: static;
        box-shadow: none;
        width: auto;
        background-color: transparent;
        max-height: none;
        overflow: visible;
        justify-content: flex-end;
    }
    nav ul {
        display: flex;
        flex-direction: row;
        justify-content: flex-end;
        margin: 0;
        padding: 0;
        list-style: none;
    }
    nav ul li {
        width: auto;
        text-align: left;
    }
    nav ul li a {
        padding: 12px 15px;
        border-bottom: none;
        border-radius: 4px;
        margin: 2px 8px;
        font-weight: bold;
    }
    .dropdown-content {
        position: absolute; /* Torna a absolute per desktop */
        box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2);
        padding: 10px 0;
        border-radius: 8px;
        font-weight: bold;
        width: max-content;
    }
    .dropdown-content li a {
        justify-content: left;
    }
    .dropdown:hover .dropdown-content {
        display: block;
    }

    .breadcrumb-nav,
    .breadcrumb-nav a,
    .breadcrumb-nav li  {
        font-size: 14px !important; /* Base size per mobile */
    }

    /* Main content adjustments */
    main {
    margin-left: 10%;
    margin-right: 10%;
    }
    .main-outer {
        max-width: 1024px;
    }
    #programmazione, #film-details {
        max-width: 700px;
    }

    /* Search layout */
    #search {
        flex-direction: column;
        justify-content: center;
        height: auto;
    }
    #searchForm {
        flex-direction: row;
    }
    .search-container {
        flex-direction: column;
        align-items: center;
    }
    #searchInput {
        max-width: 300px;
        margin-right: 10px;
    }

    /* CTA buttons */
    .cta-button-container {
        flex-direction: row;
        justify-content: space-between;
        max-width: 900px; /* Rimuovo questa, è già presente in .main-outer */
    }

    /* Calendar specific scaling */

    .calendar-day-section {
        max-width: 750px;
    }

    .calendar-day-section h2 {
        font-size: 24px;
    }
    .film-info .show-time,
    .film-info .arena-info {
        font-size: 18px;
    }
    .film-title-link {
        font-size: 20px;
    }

    /* Arena Cards Layout */
    .arena-cards-container {
        grid-template-columns: repeat(2, 1fr); /* Due colonne su desktop */
        max-width: 800px;
        margin-left: auto;
        margin-right: auto;
    }

    /* Film Details containers */
    .poster-container,
    .synopsis-container {
        margin-bottom: 24px;
    }
    .synopsis-container h3 {
        margin-bottom: 12px;
        font-size: 1.3em;
    }

    .no-screenings-message {
    max-width: 750px; 
    }
}
/* Mobile optimizations */
@media (max-width: 768px) {
    .calendar-menu {
        min-width: 160px;
        font-size: 16px; /* Better for mobile touch */
    }
    .calendar-menu-item {
        padding: 12px 16px; /* Larger touch targets */
    }
    .add-to-calendar-btn {
        padding: 10px; /* Larger touch target */
    }
    .calendar-icon {
        width: 35px; /* Mantiene le tue dimensioni anche su mobile */
        height: 35px;
    }
}

/* Dark mode support */
@media (prefers-color-scheme: dark) {
    .calendar-menu {
        background: #2d3748;
        border-color: #4a5568;
        color: #e2e8f0;
    }
    .calendar-menu-item:hover {
        background-color: #4a5568;
    }
    .calendar-menu-item:active {
        background-color: #2d3748;
    }
    .add-to-calendar-btn:hover {
        background-color: rgba(255, 255, 255, 0.1);
    }
}

/* High contrast mode */
@media (prefers-contrast: high) {
    .calendar-menu {
        border-width: 2px;
    }
    .add-to-calendar-btn {
        border: 2px solid transparent;
    }
    .add-to-calendar-btn:hover {
        border-color: currentColor;
    }
}

/* Focus styles per accessibilità */
.add-to-calendar-btn:focus {
    outline: 2px solid #4b7c4d;
    outline-offset: 2px;
    fill: rgba(75, 124, 77, 0.4);
}

 .add-to-calendar-btn:hover  {
    fill: rgba(75, 124, 77, 0.2);
}

.calendar-menu-item:focus {
    outline: 2px solid #4b7c4d;
    outline-offset: -2px;
}
/* Poster Wall Styles */
.poster-wall-section {
    margin: 40px 0;
    padding: 0 20px;
}

.poster-wall-section h2 {
    text-align: center;
    margin-bottom: 30px;
    font-family: 'vcr_osd_monoregular', sans-serif;
    color: #4b7c4d;
    font-size: 24px;
}

.poster-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.poster-item {
    position: relative;
    aspect-ratio: 2/3;
    border-radius: 8px;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    background: white;
    border: 2px solid #17183B;
}

.poster-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.poster-link {
    display: block;
    width: 100%;
    height: 100%;
    text-decoration: none;
    color: inherit;
}

.poster-placeholder {
    width: 100%;
    height: 100%;
    position: relative;
}

.film-poster {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.poster-fallback {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    width: 100%;
    height: 100%;
    background: white;
    text-align: center;
    padding: 15px;
    box-sizing: border-box;
}

.poster-fallback h3 {
    font-family: 'vcr_osd_monoregular', sans-serif;
    font-size: clamp(12px, 4vw, 18px);
    margin: 0 0 8px 0;
    line-height: 1.2;
    font-weight: bold;
    color: #17183B;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

.poster-fallback .film-year {
    font-size: 12px;
    opacity: 0.8;
}

@media (max-width: 768px) {
    .poster-grid {
        grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
        gap: 15px;
        padding: 0 10px;
    }
    
    .poster-fallback h3 {
        font-size: clamp(10px, 3.5vw, 16px);
    }
    
    .poster-fallback .film-year {
        font-size: 10px;
    }
}

@media (max-width: 480px) {
    .poster-grid {
        grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
        gap: 10px;
    }
}
