/* LEG Events: undo inherited fixed heights; event cards grow with their content. */
.leg-events-showcase .events-layout, .leg-events-showcase .secondary-events { height: auto !important; min-height: 0 !important; max-height: none !important; }
.leg-events-showcase .event-card, .leg-events-showcase .featured-media, .leg-events-showcase .featured-body, .leg-events-showcase .side-body, .leg-events-showcase .side-content, .leg-events-showcase .event-meta { height: auto !important; min-height: 0 !important; max-height: none !important; }

/* With a right sidebar the two-column events layout needs more horizontal room. */
@media (max-width: 1399.98px) {
    body:has(#sp-right) .leg-events-showcase .events-layout { display: flex !important; flex-direction: column !important; align-items: stretch !important; grid-template-columns: minmax(0, 1fr) !important; }
    body:has(#sp-right) .leg-events-showcase .events-layout > .featured-event, body:has(#sp-right) .leg-events-showcase .events-layout > .secondary-events { flex: none !important; width: 100% !important; min-width: 0 !important; max-width: none !important; }
}

/* Once the columns stack (with or without a sidebar), all media follow content height. */
@media (max-width: 991.98px) {
    .leg-events-showcase .events-layout { display: flex !important; flex-direction: column !important; align-items: stretch !important; grid-template-columns: minmax(0, 1fr) !important; }
    .leg-events-showcase .events-layout > .featured-event, .leg-events-showcase .events-layout > .secondary-events { flex: none !important; width: 100% !important; min-width: 0 !important; max-width: none !important; }
}

@media (max-width: 1399.98px) {
    body:has(#sp-right) .leg-events-showcase .featured-photo, body:has(#sp-right) .leg-events-showcase .side-photo, body:has(#sp-right) .leg-events-showcase .featured-logo { height: auto !important; min-height: 0 !important; max-height: none !important; }
    body:has(#sp-right) .leg-events-showcase .featured-photo img, body:has(#sp-right) .leg-events-showcase .side-photo img { height: auto !important; max-height: none !important; }
}
@media (max-width: 991.98px) {
    .leg-events-showcase .featured-photo, .leg-events-showcase .side-photo, .leg-events-showcase .featured-logo { height: auto !important; min-height: 0 !important; max-height: none !important; }
    .leg-events-showcase .featured-photo img, .leg-events-showcase .side-photo img { height: auto !important; max-height: none !important; }
}
