.upcoming-events-section {
    padding: 1rem 0 4rem 0;
}
.upcoming-events-container {
    max-width: 1200px;
    margin: 0 auto;
}
.upcoming-events-title {
    padding: 2rem 0 2rem 0;
    color: var(--e-global-color-7a55303, #FD8549);
}
.upcoming-events-grid {
    width: 100%;        /* don't let a flex parent shrink this */
    flex-shrink: 0;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}
@media (max-width: 900px) {
    .upcoming-events-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}
@media (max-width: 600px) {
    .upcoming-events-grid {
        grid-template-columns: 1fr;
    }
}
.event-card {
    flex-shrink: 0;      /* belt-and-braces, in case a card is itself a flex item somewhere */
    min-height: 0;        /* flex/grid children can silently get min-height/width:auto, which blocks aspect-ratio */
    position: relative;
    width: 100%;
    display: block;
    border-radius: 10px;
    overflow: hidden;
    aspect-ratio: 1 / 1.414;
    background-color: #f2f2f2;      /* letterbox fill behind the contained image */
    background-size: contain;        /* show the FULL image, never cropped */
    background-repeat: no-repeat;
    background-position: center;
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
    text-decoration: none;
    color: inherit;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.event-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.25);
}
.event-card-date-badge {
    position: absolute;
    top: 14px;
    right: 14px;
    background: var(--e-global-color-836c7fb, #E53365);
    color: #fff;
    padding: 6px 12px;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    line-height: 1.3;
    text-align: center;
    z-index: 3;
    box-shadow: 0 2px 6px rgba(0,0,0,0.25);
}
.event-card-date-badge .day {
    display: block;
    font-size: 18px;
    font-weight: 700;
}
/* title overlay - hidden until hover */
.event-card-title-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 20px;
    background: rgba(0,0,0,0.55);
    opacity: 0;
    transition: opacity 0.2s ease;
    z-index: 2;
}
.event-card:hover .event-card-title-overlay {
    opacity: 1;
}
.event-card-title {
    margin: 0;
    font-size: 18px;
    font-weight: 600;
    color: #fff;
}
.event-card-button {
    position: absolute;
    bottom: 14px;
    left: 14px;
    padding: 10px 18px;
    background: var(--e-global-color-7a55303, #FD8549);
    color: #fff;
    text-decoration: none;
    border-radius: 5px;
    font-size: 14px;
    font-weight: 600;
    z-index: 3;
    transition: background 0.2s ease;
}
.event-card-button:hover {
    background: black;
    color: var(--e-global-color-7a55303, #FD8549);
}
