/*
 * Infinity Events — front end.
 *
 * Everything themeable is a custom property on .infs-events, which is also what
 * the Elementor style controls write to. A theme can restyle the whole widget by
 * setting a handful of variables instead of out-specificity-ing our rules.
 *
 * Colours are expressed as raw channel triples (--infs-ev-accent-rgb) alongside
 * the resolved colour so we can build translucent variants with rgb(… / .12)
 * without needing a colour-mix polyfill.
 */

.infs-events {
    /* Palette */
    --infs-ev-accent: #5b53d6;
    --infs-ev-accent-rgb: 91, 83, 214;
    --infs-ev-on-accent: #fff;
    --infs-ev-card-bg: #fff;
    --infs-ev-line: rgba(17, 20, 45, .1);
    --infs-ev-title: #10142d;
    --infs-ev-meta: #5c6178;
    --infs-ev-text: #454a61;
    --infs-ev-badge-bg: rgba(var(--infs-ev-accent-rgb), .12);
    --infs-ev-badge-fg: var(--infs-ev-accent);

    /* Date chip — themeable so it can be recoloured without custom CSS. */
    --infs-ev-chip-bg: rgba(255, 255, 255, .86);
    --infs-ev-chip-fg: #10142d;
    --infs-ev-chip-accent: var(--infs-ev-accent);

    /* Shape */
    --infs-ev-radius: 18px;
    --infs-ev-btn-radius: 999px;
    --infs-ev-pad: 22px;
    --infs-ev-gap: 24px;
    --infs-ev-lift: 0px;
    --infs-ev-shadow: 0 1px 3px rgba(0, 0, 0, .11);
    --infs-ev-shadow-hi: 0 2px 10px rgba(0, 0, 0, .18);

    /* Grid */
    --infs-ev-cols: 3;
    --infs-ev-cols-t: 2;
    --infs-ev-cols-m: 1;
    --infs-ev-ratio: 16 / 9;

    color: var(--infs-ev-text);
    container-type: inline-size;
}

.infs-events *,
.infs-events *::before,
.infs-events *::after { box-sizing: border-box; }

.infs-events--ratio-4-3 { --infs-ev-ratio: 4 / 3; }
.infs-events--ratio-1-1 { --infs-ev-ratio: 1 / 1; }
.infs-events--ratio-3-4 { --infs-ev-ratio: 3 / 4; }

/* ── Track: grid, list and carousel share one element ──────────────────── */

.infs-ev-track {
    display: grid;
    grid-template-columns: repeat(var(--infs-ev-cols), minmax(0, 1fr));
    gap: var(--infs-ev-gap);
    margin: 0;
    padding: 0;
    list-style: none;
}

.infs-events--list .infs-ev-track,
.infs-events--featured .infs-ev-track { grid-template-columns: minmax(0, 1fr); }

@media (max-width: 1024px) {
    .infs-events--grid .infs-ev-track { grid-template-columns: repeat(var(--infs-ev-cols-t), minmax(0, 1fr)); }
}
@media (max-width: 640px) {
    .infs-events--grid .infs-ev-track { grid-template-columns: repeat(var(--infs-ev-cols-m), minmax(0, 1fr)); }
}

/* ── Card ───────────────────────────────────────────────────────────────── */

.infs-ev-card {
    position: relative;
    display: flex;
    flex-direction: column;
    min-width: 0;
    background: var(--infs-ev-card-bg);
    border: 1px solid var(--infs-ev-line);
    border-radius: var(--infs-ev-radius);
    box-shadow: var(--infs-ev-shadow);
    overflow: hidden;
    transition: transform .28s cubic-bezier(.2, .7, .3, 1), box-shadow .28s ease, opacity .2s ease;
}

.infs-ev-card:hover,
.infs-ev-card:focus-within {
    transform: translateY(var(--infs-ev-lift));
    box-shadow: var(--infs-ev-shadow-hi);
}

.infs-events--style-bordered .infs-ev-card { box-shadow: none; border-width: 1.5px; }
.infs-events--style-bordered .infs-ev-card:hover { box-shadow: none; border-color: var(--infs-ev-accent); }

.infs-events--style-minimal .infs-ev-card {
    box-shadow: none;
    border: 0;
    background: transparent;
    border-radius: 0;
}
.infs-events--style-minimal .infs-ev-body { padding-left: 0; padding-right: 0; }
.infs-events--style-minimal .infs-ev-media { border-radius: var(--infs-ev-radius); overflow: hidden; }

.infs-events--style-glass .infs-ev-card {
    background: rgba(255, 255, 255, .58);
    -webkit-backdrop-filter: blur(14px) saturate(160%);
    backdrop-filter: blur(14px) saturate(160%);
    border-color: rgba(255, 255, 255, .55);
}

/* Past events, when the widget is set to show rather than hide them. */
.infs-ev-card.is-past { opacity: .58; filter: saturate(.35); }
.infs-ev-card.is-past:hover { opacity: .82; filter: saturate(.7); }
.infs-ev-card.is-cancelled .infs-ev-title { text-decoration: line-through; text-decoration-thickness: 1.5px; }

/* ── Media ──────────────────────────────────────────────────────────────── */

.infs-ev-media {
    position: relative;
    display: flex;
    aspect-ratio: var(--infs-ev-ratio);
    overflow: hidden;
    background: rgba(var(--infs-ev-accent-rgb), .06);
    flex: none;
}

.infs-ev-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    display: block;
    transition: transform .5s cubic-bezier(.2, .7, .3, 1);
}
.infs-ev-card:hover .infs-ev-img { transform: scale(1.045); }

/* ── Image fit: "contain" keeps the whole image, no crop ─────────────────── */
/* Cards stay a uniform size; the odd aspect ratio is filled by a blurred copy
   of the same image so it reads as intentional, never as empty bars. */
.infs-events--fit-contain .infs-ev-img {
    position: relative;
    z-index: 1;
    object-fit: contain;
}
.infs-events--fit-contain .infs-ev-card:hover .infs-ev-img { transform: none; }

.infs-ev-media-bg {
    position: absolute;
    inset: 0;
    z-index: 0;
    background-size: cover;
    background-position: center;
    transform: scale(1.18);
    filter: blur(20px) saturate(1.25);
    opacity: .55;
}
/* Only the contain layout paints the backdrop. */
.infs-events--fit-cover .infs-ev-media-bg { display: none; }
.infs-ev-media-bg::after {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(var(--infs-ev-accent-rgb), .04);
}

/* No image: a deterministic gradient so a mixed listing still looks composed. */
.infs-ev-fallback {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(120% 120% at 15% 0%, hsl(var(--infs-ev-hue, 250) 78% 66%) 0%, transparent 60%),
        linear-gradient(135deg, hsl(var(--infs-ev-hue, 250) 70% 58%), hsl(calc(var(--infs-ev-hue, 250) + 48) 72% 46%));
}
.infs-ev-fallback::after {
    content: "";
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(255, 255, 255, .14) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, .14) 1px, transparent 1px);
    background-size: 26px 26px;
    mask-image: radial-gradient(90% 90% at 70% 20%, #000, transparent 75%);
    -webkit-mask-image: radial-gradient(90% 90% at 70% 20%, #000, transparent 75%);
}

/* ── Badge ──────────────────────────────────────────────────────────────── */

.infs-ev-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    z-index: 2;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 5px 11px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 650;
    line-height: 1.4;
    letter-spacing: .01em;
    background: var(--infs-ev-badge-bg);
    color: var(--infs-ev-badge-fg);
    -webkit-backdrop-filter: blur(10px) saturate(180%);
    backdrop-filter: blur(10px) saturate(180%);
    box-shadow: 0 1px 2px rgba(16, 20, 45, .12);
}

.infs-ev-badge--inline {
    position: static;
    align-self: flex-start;
    margin-bottom: 10px;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    box-shadow: none;
}

.infs-ev-badge--now       { background: rgba(224, 36, 62, .14); color: #c01739; }
.infs-ev-badge--today     { background: rgba(214, 118, 12, .15); color: #a85405; }
.infs-ev-badge--tomorrow  { background: rgba(20, 130, 96, .14); color: #0d6b4c; }
.infs-ev-badge--past      { background: rgba(90, 96, 120, .14); color: #4c5268; }
.infs-ev-badge--cancelled { background: rgba(190, 30, 45, .14); color: #a5122a; }

.infs-ev-pulse {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: currentColor;
    box-shadow: 0 0 0 0 currentColor;
    animation: infs-ev-pulse 1.8s ease-out infinite;
}
@keyframes infs-ev-pulse {
    0%   { box-shadow: 0 0 0 0 rgba(224, 36, 62, .55); }
    70%  { box-shadow: 0 0 0 7px rgba(224, 36, 62, 0); }
    100% { box-shadow: 0 0 0 0 rgba(224, 36, 62, 0); }
}

/* ── Date chip ──────────────────────────────────────────────────────────── */

.infs-ev-chip {
    position: absolute;
    right: 12px;
    bottom: 12px;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-width: 54px;
    padding: 7px 9px 8px;
    border-radius: 14px;
    background: var(--infs-ev-chip-bg);
    -webkit-backdrop-filter: blur(12px) saturate(180%);
    backdrop-filter: blur(12px) saturate(180%);
    box-shadow: 0 4px 14px -4px rgba(16, 20, 45, .35);
    color: var(--infs-ev-chip-fg);
    line-height: 1;
}
.infs-ev-chip-m {
    font-size: 11px;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
    color: var(--infs-ev-chip-accent);
}
.infs-ev-chip-d { font-size: 21px; font-weight: 750; margin-top: 3px; }

/* ── Body ───────────────────────────────────────────────────────────────── */

.infs-ev-body {
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
    min-width: 0;
    padding: var(--infs-ev-pad);
    gap: 8px;
}

.infs-ev-title {
    margin: 0;
    font-size: 1.15rem;
    line-height: 1.3;
    font-weight: 680;
    color: var(--infs-ev-title);
    letter-spacing: -.01em;
}

.infs-ev-link {
    color: inherit;
    text-decoration: none;
    background-image: linear-gradient(var(--infs-ev-accent), var(--infs-ev-accent));
    background-size: 0 1.5px;
    background-position: 0 100%;
    background-repeat: no-repeat;
    transition: background-size .3s ease, color .2s ease;
}
.infs-ev-card:hover .infs-ev-link { background-size: 100% 1.5px; }

/* Stretched link: the whole card is clickable, but focus still lands on a real
   anchor and the action buttons stay independently clickable above it. */
.infs-ev-link::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 1;
}

.infs-ev-when,
.infs-ev-where {
    display: flex;
    align-items: center;
    gap: 7px;
    margin: 0;
    font-size: .875rem;
    line-height: 1.45;
    color: var(--infs-ev-meta);
    font-weight: 550;
}
.infs-ev-where { font-weight: 500; }

.infs-ev-i {
    width: 15px;
    height: 15px;
    flex: none;
    fill: currentColor;
    opacity: .72;
}

.infs-ev-repeats {
    font-size: 11px;
    font-weight: 650;
    text-transform: uppercase;
    letter-spacing: .05em;
    padding: 2px 7px;
    border-radius: 999px;
    background: rgba(var(--infs-ev-accent-rgb), .1);
    color: var(--infs-ev-accent);
}

.infs-ev-summary {
    margin: 2px 0 0;
    font-size: .9375rem;
    line-height: 1.6;
    color: var(--infs-ev-text);
}

.infs-ev-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin: 4px 0 0;
}
.infs-ev-tag {
    font-size: 11.5px;
    font-weight: 620;
    padding: 3px 9px;
    border-radius: 999px;
    border: 1px solid var(--infs-ev-line);
    color: var(--infs-ev-meta);
}
.infs-ev-tag--free { background: rgba(20, 130, 96, .1); border-color: transparent; color: #0d6b4c; }
.infs-ev-tag--paid { background: rgba(var(--infs-ev-accent-rgb), .1); border-color: transparent; color: var(--infs-ev-accent); }

/* ── Actions ────────────────────────────────────────────────────────────── */

.infs-ev-actions {
    position: relative;
    z-index: 2;           /* above the stretched link overlay */
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: auto;
    padding-top: 14px;
}

.infs-ev-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 9px 17px;
    border: 1px solid transparent;
    border-radius: var(--infs-ev-btn-radius);
    font-size: .875rem;
    font-weight: 640;
    line-height: 1.2;
    text-decoration: none;
    cursor: pointer;
    transition: background-color .2s ease, color .2s ease, border-color .2s ease, transform .15s ease;
}
.infs-ev-btn:active { transform: translateY(1px); }

.infs-ev-btn--solid {
    background: var(--infs-ev-accent);
    color: var(--infs-ev-on-accent);
}
.infs-ev-btn--solid:hover,
.infs-ev-btn--solid:focus-visible {
    background: color-mix(in srgb, var(--infs-ev-accent) 86%, #000);
    color: var(--infs-ev-on-accent);
}

.infs-ev-btn--ghost {
    background: transparent;
    border-color: var(--infs-ev-line);
    color: var(--infs-ev-title);
}
.infs-ev-btn--ghost:hover,
.infs-ev-btn--ghost:focus-visible {
    border-color: var(--infs-ev-accent);
    color: var(--infs-ev-accent);
    background: rgba(var(--infs-ev-accent-rgb), .06);
}

.infs-events :focus-visible {
    outline: 2px solid var(--infs-ev-accent);
    outline-offset: 2px;
    border-radius: 6px;
}

/* ── List layout ────────────────────────────────────────────────────────── */

@media (min-width: 641px) {
    .infs-events--list .infs-ev-card { flex-direction: row; align-items: stretch; }
    .infs-events--list .infs-ev-media { width: clamp(180px, 30%, 340px); aspect-ratio: auto; }
    .infs-events--list .infs-ev-body { justify-content: center; }
}

/* ── Featured layout ────────────────────────────────────────────────────── */

@media (min-width: 861px) {
    .infs-events--featured .infs-ev-card { flex-direction: row; align-items: stretch; }
    .infs-events--featured .infs-ev-media { width: 46%; aspect-ratio: auto; min-height: 320px; }
    .infs-events--featured .infs-ev-body { justify-content: center; padding: calc(var(--infs-ev-pad) * 1.6); gap: 12px; }
    .infs-events--featured .infs-ev-title { font-size: 1.9rem; }
    .infs-events--featured .infs-ev-summary { font-size: 1.0625rem; }
}

/* ── Carousel ───────────────────────────────────────────────────────────── */

.infs-ev-carousel { position: relative; }

.infs-events--carousel .infs-ev-track {
    display: flex;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
    scrollbar-width: none;
    /* Room for the hover lift and focus rings, cancelled with a matching
       negative margin so the track still aligns with the rest of the page. */
    padding: 6px 2px 14px;
    margin: -6px -2px -14px;
}
.infs-events--carousel .infs-ev-track::-webkit-scrollbar { display: none; }

.infs-events--carousel .infs-ev-card {
    scroll-snap-align: start;
    flex: 0 0 calc((100% - (var(--infs-ev-cols) - 1) * var(--infs-ev-gap)) / var(--infs-ev-cols));
}
@media (max-width: 1024px) {
    .infs-events--carousel .infs-ev-card { flex-basis: calc((100% - (var(--infs-ev-cols-t) - 1) * var(--infs-ev-gap)) / var(--infs-ev-cols-t)); }
}
@media (max-width: 640px) {
    .infs-events--carousel .infs-ev-card { flex-basis: calc((100% - (var(--infs-ev-cols-m) - 1) * var(--infs-ev-gap)) / var(--infs-ev-cols-m)); }
}

.infs-ev-nav {
    position: absolute;
    top: 50%;
    z-index: 3;
    display: grid;
    place-items: center;
    width: 42px;
    height: 42px;
    padding: 0;
    transform: translateY(-50%);
    border: 1px solid var(--infs-ev-line);
    border-radius: 50%;
    background: var(--infs-ev-card-bg);
    color: var(--infs-ev-title);
    box-shadow: 0 6px 18px -8px rgba(16, 20, 45, .45);
    cursor: pointer;
    transition: opacity .2s ease, transform .2s ease, background-color .2s ease;
}
.infs-ev-nav:hover { background: var(--infs-ev-accent); color: var(--infs-ev-on-accent); border-color: transparent; }
.infs-ev-nav--prev { left: -18px; }
.infs-ev-nav--next { right: -18px; }
.infs-ev-nav[hidden],
.infs-ev-nav[disabled] { opacity: 0; pointer-events: none; }
.infs-ev-nav svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }

@media (max-width: 900px) {
    .infs-ev-nav--prev { left: 2px; }
    .infs-ev-nav--next { right: 2px; }
}

.infs-ev-dots {
    display: flex;
    justify-content: center;
    gap: 7px;
    margin-top: 18px;
}
.infs-ev-dots:empty { display: none; }
.infs-ev-dot {
    width: 7px;
    height: 7px;
    padding: 0;
    border: 0;
    border-radius: 999px;
    background: var(--infs-ev-line);
    cursor: pointer;
    transition: width .25s ease, background-color .25s ease;
}
.infs-ev-dot.is-active { width: 22px; background: var(--infs-ev-accent); }

/* ── Toolbar, status, load more ─────────────────────────────────────────── */

.infs-ev-toolbar { margin-bottom: 20px; }

.infs-ev-searchwrap { position: relative; max-width: 420px; }

.infs-ev-search {
    width: 100%;
    height: 46px;
    padding: 0 40px 0 42px;
    border: 1px solid var(--infs-ev-line);
    border-radius: var(--infs-ev-btn-radius);
    background: var(--infs-ev-card-bg);
    color: var(--infs-ev-title);
    font-size: .9375rem;
    transition: border-color .2s ease, box-shadow .2s ease;
}
.infs-ev-search:focus {
    outline: none;
    border-color: var(--infs-ev-accent);
    box-shadow: 0 0 0 4px rgba(var(--infs-ev-accent-rgb), .14);
}
.infs-ev-search::-webkit-search-cancel-button { display: none; }

.infs-ev-searchicon {
    position: absolute;
    left: 15px;
    top: 50%;
    width: 18px;
    height: 18px;
    transform: translateY(-50%);
    fill: var(--infs-ev-meta);
    pointer-events: none;
}

.infs-ev-clear {
    position: absolute;
    right: 8px;
    top: 50%;
    transform: translateY(-50%);
    width: 30px;
    height: 30px;
    border: 0;
    border-radius: 50%;
    background: transparent;
    color: var(--infs-ev-meta);
    font-size: 20px;
    line-height: 1;
    cursor: pointer;
}
.infs-ev-clear:hover { background: rgba(var(--infs-ev-accent-rgb), .1); color: var(--infs-ev-accent); }

.infs-ev-status {
    margin: 0 0 14px;
    font-size: .875rem;
    color: var(--infs-ev-meta);
    min-height: 1.25em;
}
.infs-ev-status:empty { display: none; }

.infs-ev-empty {
    margin: 8px 0;
    padding: 40px 20px;
    text-align: center;
    color: var(--infs-ev-meta);
    border: 1px dashed var(--infs-ev-line);
    border-radius: var(--infs-ev-radius);
}

.infs-ev-morewrap { display: flex; justify-content: center; margin-top: 28px; }
.infs-ev-more[hidden] { display: none; }

/* Loading state for AJAX swaps. */
.infs-events.is-loading .infs-ev-track { opacity: .45; pointer-events: none; transition: opacity .2s ease; }
.infs-events.is-loading .infs-ev-more { opacity: .6; pointer-events: none; }

/* Freshly appended cards fade in rather than snapping into place. */
.infs-ev-card.is-entering { opacity: 0; transform: translateY(14px); }
.infs-ev-card.is-entered {
    opacity: 1;
    transform: none;
    transition: opacity .45s ease, transform .45s cubic-bezier(.2, .7, .3, 1);
}

/* ── Modal ──────────────────────────────────────────────────────────────── */

.infs-ev-modal {
    position: fixed;
    inset: 0;
    z-index: 999999;
    display: grid;
    place-items: center;
    padding: 20px;
}
.infs-ev-modal[hidden] { display: none; }

.infs-ev-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(10, 12, 28, .58);
    -webkit-backdrop-filter: blur(6px);
    backdrop-filter: blur(6px);
    animation: infs-ev-fade .22s ease both;
}

.infs-ev-modal-panel {
    position: relative;
    width: min(760px, 100%);
    max-height: min(88vh, 900px);
    overflow: auto;
    overscroll-behavior: contain;
    background: var(--infs-ev-card-bg, #fff);
    border-radius: 20px;
    box-shadow: 0 40px 90px -24px rgba(6, 8, 24, .6);
    animation: infs-ev-pop .28s cubic-bezier(.2, .8, .3, 1) both;
}

@keyframes infs-ev-fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes infs-ev-pop {
    from { opacity: 0; transform: translateY(18px) scale(.97); }
    to   { opacity: 1; transform: none; }
}

.infs-ev-modal-close {
    position: absolute;
    top: 14px;
    right: 14px;
    z-index: 2;
    display: grid;
    place-items: center;
    width: 38px;
    height: 38px;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, .9);
    color: #10142d;
    box-shadow: 0 3px 12px -4px rgba(16, 20, 45, .4);
    cursor: pointer;
}
.infs-ev-modal-close:hover { background: #10142d; color: #fff; }
.infs-ev-modal-close svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; }

.infs-ev-modal-media { aspect-ratio: 16 / 7; overflow: hidden; background: rgba(var(--infs-ev-accent-rgb), .08); }
.infs-ev-modal-media[hidden] { display: none; }
.infs-ev-modal-media img { width: 100%; height: 100%; object-fit: cover; display: block; }

.infs-ev-modal-body { padding: 30px clamp(22px, 5vw, 40px) 34px; }

.infs-ev-modal-title {
    margin: 0 0 12px;
    font-size: clamp(1.4rem, 3vw, 1.85rem);
    line-height: 1.15;
    font-weight: 700;
    color: var(--infs-ev-title);
    letter-spacing: -.015em;
    padding-right: 44px;
}

.infs-ev-modal-meta {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    margin: 0 0 6px;
    font-size: .9375rem;
    font-weight: 550;
    color: var(--infs-ev-meta);
}
.infs-ev-modal-meta:empty,
.infs-ev-modal-meta[hidden] { display: none; }

/* "Get directions" — sits beside the location, opens Google Maps in a new tab. */
.infs-ev-directions {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-weight: 620;
    text-decoration: none;
    color: var(--infs-ev-accent);
    white-space: nowrap;
}
.infs-ev-directions[hidden] { display: none; }
.infs-ev-directions:hover,
.infs-ev-directions:focus-visible { text-decoration: underline; }
.infs-ev-directions .infs-ev-i { opacity: 1; }

/* Embedded location map (Google Maps Embed API iframe). */
.infs-ev-modal-map {
    margin: 18px 0 0;
    border-radius: 14px;
    overflow: hidden;
    border: 1px solid var(--infs-ev-line);
    line-height: 0;
}
.infs-ev-modal-map[hidden] { display: none; }
.infs-ev-modal-map iframe {
    display: block;
    width: 100%;
    height: 280px;
    border: 0;
}

.infs-ev-modal-content {
    margin-top: 18px;
    font-size: 1rem;
    line-height: 1.7;
    color: var(--infs-ev-text);
}
.infs-ev-modal-content > *:first-child { margin-top: 0; }
.infs-ev-modal-content > *:last-child { margin-bottom: 0; }
.infs-ev-modal-content img { max-width: 100%; height: auto; border-radius: 10px; }

.infs-ev-modal-actions { padding-top: 24px; }

/* Body scroll lock while the dialog is open. */
body.infs-ev-modal-open { overflow: hidden; }

/* ── Dark mode ──────────────────────────────────────────────────────────── */

@media (prefers-color-scheme: dark) {
    .infs-events {
        --infs-ev-card-bg: #171a27;
        --infs-ev-line: rgba(255, 255, 255, .12);
        --infs-ev-title: #f2f4fb;
        --infs-ev-meta: #a3a9c2;
        --infs-ev-text: #c3c8dc;
        --infs-ev-shadow: 0 1px 2px rgba(0, 0, 0, .4), 0 10px 28px -14px rgba(0, 0, 0, .8);
        --infs-ev-shadow-hi: 0 2px 8px rgba(0, 0, 0, .5), 0 26px 52px -20px rgba(0, 0, 0, .95);
    }
    .infs-events--style-glass .infs-ev-card {
        background: rgba(28, 32, 48, .6);
        border-color: rgba(255, 255, 255, .1);
    }
    .infs-events {
        --infs-ev-chip-bg: rgba(23, 26, 39, .88);
        --infs-ev-chip-fg: #f2f4fb;
    }
    .infs-ev-modal-close { background: rgba(23, 26, 39, .92); color: #f2f4fb; }
    .infs-ev-modal-close:hover { background: #f2f4fb; color: #10142d; }
}

/* ── Reduced motion ─────────────────────────────────────────────────────── */

@media (prefers-reduced-motion: reduce) {
    .infs-events *,
    .infs-ev-modal * {
        animation-duration: .001ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: .001ms !important;
    }
    .infs-events--carousel .infs-ev-track { scroll-behavior: auto; }
    .infs-ev-card:hover { transform: none; }
    .infs-ev-card:hover .infs-ev-img { transform: none; }
}

/* Screen-reader-only text, in case the theme does not define it. */
.infs-events .screen-reader-text,
.infs-ev-modal .screen-reader-text {
    position: absolute !important;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}
