.eventi-filters {
    background: #fff;
    padding: 30px;
    margin-bottom: 50px;
    box-shadow: 0 4px 18px rgba(0,0,0,.06);
}
.eventi-filters label { display:block; font-weight:600; margin-bottom:8px; }
.eventi-filters .form__field { width:100%; }
.eventi-filters__actions { display:flex; flex-wrap:wrap; gap:12px; margin-top:24px; }
.evento-card { height:100%; }
.evento-card__organizer { font-size:14px; font-weight:600; margin-bottom:12px; }
.evento-card__date { margin-bottom:8px; }
.evento-single__image img { width:100%; height:auto; display:block; }
.evento-single__content { margin-top:35px; }
.evento-info-box { background:#f8f4f1; padding:30px; position:sticky; top:30px; }
.evento-info-box h5 { margin-bottom:25px; }
.evento-info-row { display:flex; flex-direction:column; gap:4px; padding:14px 0; border-bottom:1px solid rgba(0,0,0,.12); }
.evento-info-row:last-child { border-bottom:0; }
.evento-gallery { display:grid; grid-template-columns:repeat(3,1fr); gap:15px; margin-top:40px; }
.evento-gallery__item img { width:100%; aspect-ratio:1/1; object-fit:cover; display:block; }
.eventi-empty { text-align:center; padding:50px 20px; background:#fff; }
@media (max-width: 767px) {
    .eventi-filters { padding:20px; }
    .eventi-filters .col-md-4 + .col-md-4 { margin-top:18px; }
    .evento-gallery { grid-template-columns:repeat(2,1fr); }
    .evento-info-box { margin-top:35px; position:static; }
}


.evento-hero-subtitle { font-size: 1.15rem; max-width: 850px; margin-top: .75rem; }
.evento-single__subtitle { margin-bottom: 1.5rem; }
.evento-card__subtitle { margin: .35rem 0 .75rem; font-weight: 600; line-height: 1.4; }
.evento-calendar { margin-top: 3rem; }
.evento-calendar__list { display: grid; gap: 1rem; margin-top: 1.25rem; }
.evento-calendar__item { display: flex; align-items: stretch; background: #fff; border: 1px solid rgba(0,0,0,.08); }
.evento-calendar__date { min-width: 110px; padding: 1rem; display: flex; flex-direction: column; align-items: center; justify-content: center; background: #f5f2ef; text-align: center; }
.evento-calendar__day { font-size: 2rem; font-weight: 700; line-height: 1; }
.evento-calendar__month { margin-top: .35rem; text-transform: capitalize; font-size: .85rem; }
.evento-calendar__details { padding: 1rem 1.25rem; display: flex; flex-direction: column; justify-content: center; gap: .25rem; }
.evento-calendar__details strong { text-transform: capitalize; }
.evento-calendar__details small { margin-top: .25rem; }
.evento-materiali { margin-top: 3rem; }
.evento-materiali__item { display: flex; justify-content: space-between; gap: 1rem; padding: 1rem 1.25rem; margin-top: .75rem; border: 1px solid rgba(0,0,0,.1); background: #fff; }
@media (max-width: 575px) {
  .evento-calendar__date { min-width: 88px; }
  .evento-calendar__day { font-size: 1.65rem; }
  .evento-materiali__item { flex-direction: column; }
}


/* Correzione allegati e galleria nella pagina del singolo evento */

.evento-materiali {
    margin-top: 35px;
}

.evento-materiali__item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    width: 100%;
    margin-bottom: 12px;
    padding: 16px 20px;
    border: 1px solid rgba(29, 85, 120, 0.18);
    background: #eef9f8;
    color: #1d5578;
    text-decoration: none;
    border-radius:30px;
}

.evento-materiali__item:hover {
    background: #dff2f2;
    color: #1d5578;
}

.evento-gallery {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px;
    margin-top: 35px;
}

.evento-gallery:empty {
    display: none;
}

.evento-gallery__item {
    display: block;
    overflow: hidden;
    background: #f4f4f4;
    border: 1px solid rgba(29, 85, 120, 0.12);
}

.evento-gallery__item img {
    display: block;
    width: 100%;
    height: 320px;
    aspect-ratio: auto;
    object-fit: contain;
    object-position: center;
    background: #fff;
}

.evento-gallery__item:only-child {
    max-width: 520px;
}

/* Maggiore respiro sopra e sotto ai pulsanti dei filtri */
.eventi-filters__actions {
    margin-top: 35px;
    margin-bottom: 35px;
}

.eventi-filters__actions .button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.evento-single__image img {
    width: 100%;
}

@media (max-width: 767px) {
    .evento-gallery {
        grid-template-columns: 1fr;
    }

    .evento-gallery__item img {
        height: auto;
        max-height: 420px;
    }

    .evento-gallery__item:only-child {
        max-width: 100%;
    }
}


/* Materiali evento con pulsante coerente con gli altri pulsanti del sito */
.evento-materiali__item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    width: 100%;
    margin-top: 12px;
    margin-bottom: 12px;
    padding: 18px 20px;
    border: 1px solid rgba(29, 85, 120, 0.18);
    background: #eef9f8;
    border-radius: 30px;
}

.evento-materiali__titolo {
    color: #1d5578;
    font-weight: 600;
}

.evento-materiali__button {
    flex: 0 0 auto;
    margin: 0;
}

.eventi-filters select.form__field {
    padding-right: 55px;
    background-position: calc(100% - 24px) center;
}

@media (max-width: 767px) {
    .eventi-filters select.form__field {
        padding-right: 50px;
        background-position: calc(100% - 20px) center;
    }
}

@media (max-width: 575px) {
    .evento-materiali__item {
        align-items: flex-start;
        flex-direction: column;
    }
}


@media (max-width: 767px) {

    .promo-primary {
        position: relative;
        overflow: hidden;
    }

    .promo-primary picture,
    .promo-primary picture img {
        position: absolute;
        inset: 0;
        width: 100%;
        height: 100%;
    }

    .promo-primary picture img {
        object-fit: cover;
    }

    .promo-primary::before {
        content: "";
        position: absolute;
        inset: 0;
        display: block;
        background: rgba(23, 63, 91, 0.62);
        z-index: 1;
        pointer-events: none;
    }

    .promo-primary .container {
        position: relative;
        z-index: 2;
    }

    .text-white {
        margin-top: 45px;
    }
}


.eventi-select-wrap {
    position: relative;
}

.eventi-select-wrap select.form__field {
    width: 100%;
    padding-right: 65px;

    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;

    background-image: none;
}

.eventi-select-wrap::after {
    content: "";
    position: absolute;
    top: 50%;
    right: 28px;
    width: 9px;
    height: 9px;

    border-right: 2px solid #172126;
    border-bottom: 2px solid #172126;

    transform: translateY(-70%) rotate(45deg);
    pointer-events: none;
}

.evento-info-appointments {
    display: flex;
    flex-direction: column;
    gap: 18px;
    margin-top: 12px;
}

.evento-info-appointment {
    padding: 16px;
    background: #fff;
    border-left: 3px solid #40baa4;
}

.evento-info-appointment__date {
    margin-bottom: 5px;
}

.evento-info-appointment__time {
    margin-bottom: 5px;
}

.evento-info-appointment__note {
    font-size: 14px;
    font-weight: 600;
    color: #255f83;
}

.evento-detail-calendar {
    margin-top: 50px;
}

.evento-detail-calendar__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 25px;
}

.evento-detail-calendar__header h3 {
    margin: 0;
}

.evento-detail-calendar__navigation {
    display: flex;
    align-items: center;
    gap: 8px;
}

.evento-detail-calendar__nav,
.evento-detail-calendar__today {
    min-height: 42px;
    border: 1px solid rgba(29, 85, 120, 0.25);
    background: #fff;
    color: #1d5578;
    font-weight: 700;
    cursor: pointer;
}

.evento-detail-calendar__nav {
    width: 42px;
    font-size: 25px;
}

.evento-detail-calendar__today {
    padding: 0 16px;
}

.evento-detail-calendar__title {
    margin-bottom: 15px;
    color: #255f83;
    text-transform: capitalize;
}

.evento-detail-calendar__weekdays,
.evento-detail-calendar__grid {
    display: grid;
    grid-template-columns: repeat(7, minmax(0, 1fr));
}

.evento-detail-calendar__weekdays {
    background: #255f83;
    color: #fff;
    font-weight: 700;
    text-align: center;
}

.evento-detail-calendar__weekdays span {
    padding: 12px 6px;
}

.evento-detail-calendar__grid {
    border-top: 1px solid rgba(29, 85, 120, 0.15);
    border-left: 1px solid rgba(29, 85, 120, 0.15);
}

.evento-detail-calendar__day {
    min-height: 145px;
    padding: 8px;
    background: #fff;
    border-right: 1px solid rgba(29, 85, 120, 0.15);
    border-bottom: 1px solid rgba(29, 85, 120, 0.15);
}

.evento-detail-calendar__day.is-outside-month {
    background: #f5f3f1;
}

.evento-detail-calendar__day.is-outside-month
.evento-detail-calendar__day-number {
    opacity: 0.35;
}

.evento-detail-calendar__day.is-today {
    box-shadow: inset 0 0 0 2px #40baa4;
}

.evento-detail-calendar__day-number {
    margin-bottom: 8px;
    font-weight: 700;
}

.evento-detail-calendar__events {
    display: flex;
    flex-direction: column;
    gap: 7px;
}

.evento-detail-calendar__event {
    padding: 8px;
    background: #eef9f8;
    border-left: 3px solid #40baa4;
}

.evento-detail-calendar__event-time,
.evento-detail-calendar__event-note {
    display: block;
}

.evento-detail-calendar__event-time {
    font-size: 13px;
}

.evento-detail-calendar__event-note {
    margin-top: 4px;
    color: #255f83;
    font-size: 12px;
    font-weight: 600;
    line-height: 1.3;
}

.evento-detail-calendar__empty {
    padding: 30px;
    background: #f5f3f1;
    text-align: center;
}

@media (max-width: 767px) {
    .evento-detail-calendar__header {
        align-items: flex-start;
        flex-direction: column;
    }

    .evento-detail-calendar__weekdays {
        display: none;
    }

    .evento-detail-calendar__grid {
        display: block;
        border: 0;
    }

    .evento-detail-calendar__day {
        display: none;
        min-height: 0;
        margin-bottom: 12px;
        border: 1px solid rgba(29, 85, 120, 0.15);
    }

    .evento-detail-calendar__day:has(
        .evento-detail-calendar__event
    ) {
        display: block;
    }

    .evento-detail-calendar__day.is-outside-month {
        display: none;
    }
}