/* ============================================================================
   JNVKAA Events: public, member, batch-admin and admin event screens.
   MOBILE-FIRST (360 px base; min-width steps 560 / 768 / 960 / 1024 / 1280 / 1600).
   - Event cards are the shared tile (.pg-card.pg-tile from console.css): same radius, padding,
     16:9 media and meta row as the album and story cards. This file adds the event extras only.
   - Card grid: 1 > 2 > 3 > 4 > 5 columns as the screen grows (never stretched cards).
   - Status is text + icon + colour, never colour alone. Text colours meet 4.5:1.
   - No style="" anywhere: every visual lives here (CSP). Motion is gated below.
   ========================================================================== */
.ev { --ev-ok: #10794f; --ev-ok-bg: #e8f6ef; --ev-warn: #8a4b00; --ev-warn-bg: #fff4e5;
      --ev-bad: #a4231b; --ev-bad-bg: #fdecec; --ev-info: #0b6569; --ev-info-bg: #e6f5f5;
      --ev-mut: #4a585b; --ev-mut-bg: #eef1f1; --ev-live: #b3261e; }

/* site.css turns every hovered .btn's text white; ghost/cream buttons hover to a cream background, so keep them readable */
.ev .btn-ghost:hover, .ev .btn-ghost:focus-visible, .ev .btn-cream:hover, .ev details[open] > summary.btn-ghost { color: var(--teal-700); }
.ev a:focus-visible, .ev button:focus-visible, .ev summary:focus-visible, .ev input:focus-visible,
.ev select:focus-visible, .ev textarea:focus-visible { outline: 3px solid var(--teal-700); outline-offset: 2px; }
.ev .ev-sr { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.ev-muted { color: var(--muted); }
.ev-small { font-size: var(--fs-sm); }
.ev-row { display: flex; flex-wrap: wrap; align-items: center; gap: var(--sp-2); }
.ev-stack { display: grid; gap: var(--sp-4); }
.ev-mt { margin-top: var(--sp-4); } .ev-mt-sm { margin-top: var(--sp-2); } .ev-mb { margin-bottom: var(--sp-4); } .ev-m0 { margin: 0; }
.ev-center { text-align: center; }
.ev-inline { display: inline; }

/* ---- page rhythm: list and detail pages sit close under the band (public matches the member page body) ---- */
.section.section-fluid.ev-page, .section.section-fluid.ev-detail, .section.section-fluid.ev-ticket-page { padding-block: var(--sp-6) var(--sp-8); }
@media (min-width: 1024px) { .section.section-fluid.ev-page, .section.section-fluid.ev-detail { padding-block: var(--sp-8) 3rem; } }

/* ---- toolbar: segmented Upcoming / Past + type chips (+ year) -------------------------------- */
.ev-toolbar { display: flex; flex-wrap: wrap; align-items: center; gap: var(--sp-3); margin: 0 0 var(--sp-4); }
.ev-seg { display: inline-flex; gap: 2px; padding: 3px; background: #fff; border: 1px solid var(--line); border-radius: 999px; max-width: 100%; overflow-x: auto; scrollbar-width: none; }
.ev-seg::-webkit-scrollbar { display: none; }
.ev-seg a { flex: 0 0 auto; display: inline-flex; align-items: center; gap: 6px; min-height: var(--ctl-h-sm); padding: 0 14px; border-radius: 999px;
  font-size: var(--fs-sm); font-weight: 600; color: var(--ink); white-space: nowrap; transition: background .15s, color .15s; }
.ev-seg a i { font-size: .9em; color: var(--teal-700); }
.ev-seg a:hover { background: var(--cream); color: var(--teal-700); }
.ev-seg a[aria-current="page"] { background: var(--teal); color: #fff; }
.ev-seg a[aria-current="page"] i { color: #fff; }

.ev-filters { display: flex; gap: 6px; align-items: center; flex: 1 1 100%; min-width: 0; overflow-x: auto; scrollbar-width: none;
  padding: 2px; margin: -2px; scroll-snap-type: x proximity; }
.ev-filters::-webkit-scrollbar { display: none; }
.ev-filters a { flex: 0 0 auto; scroll-snap-align: start; display: inline-flex; align-items: center; min-height: var(--ctl-h-sm); padding: 0 12px;
  border-radius: 999px; border: 1px solid var(--line); background: #fff; color: var(--ink); font-size: var(--fs-sm); font-weight: 500; white-space: nowrap;
  transition: border-color .15s, color .15s, background .15s; }
.ev-filters a:hover { border-color: var(--teal-300); color: var(--teal-700); }
.ev-filters a[aria-current="true"] { background: var(--cream); border-color: var(--teal-300); color: var(--teal-700); font-weight: 600; }
.ev-year select { min-height: var(--ctl-h-sm); padding: 0 2rem 0 .75rem; border-radius: 999px; font-size: var(--fs-sm); }
@media (min-width: 768px) {
  .ev-filters { flex: 0 1 auto; flex-wrap: wrap; overflow: visible; }
  .ev-year { margin-left: auto; }
}
.ev-count { margin: 0 0 var(--sp-3); font-size: var(--fs-sm); color: var(--muted); font-variant-numeric: tabular-nums; }
.ev-group { margin-bottom: var(--sp-6); }

/* ---- card grid: 1 > 2 > 3 > 4 > 5 columns -------------------------------------------------------- */
.ev-cards { display: grid; grid-template-columns: minmax(0, 1fr); gap: var(--sp-4); }
@media (min-width: 560px) { .ev-cards { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 960px) { .ev-cards { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 1280px) { .ev-cards { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--sp-5); } }
@media (min-width: 1600px) { .ev-cards { grid-template-columns: repeat(5, minmax(0, 1fr)); } }
/* legacy grid name (kept for any old markup) */
.ev-grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: var(--sp-4); }
@media (min-width: 560px) { .ev-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* ---- event card (extras on top of .pg-card.pg-tile) ------------------------------------------- */
.ev-card { position: relative; }
.ev-card .pg-card-media { background: var(--cream); }
.ev-card .pg-card-media img { position: absolute; inset: 0; }
.ev-card__body { gap: 6px; padding: var(--sp-3) var(--sp-4) var(--sp-4); }
.ev-card__kicker { display: flex; align-items: center; justify-content: space-between; gap: var(--sp-2); margin: 0; min-height: 22px;
  font-size: var(--fs-2xs); font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--teal-700); }
.ev-card__kicker .ev-chip { text-transform: none; letter-spacing: 0; }
.ev-card__title a { color: var(--ink); }
/* whole card clickable through the heading link (one interactive element per card) */
.ev-card__title a::after { content: ""; position: absolute; inset: 0; z-index: 1; }
.ev-card__title a:focus-visible { outline: none; }
.ev-card:focus-within { border-color: var(--teal-700); box-shadow: 0 0 0 3px rgba(18, 146, 152, .25); }
.ev-card__meta { flex-direction: column; gap: 3px; font-size: var(--fs-xs); }
.ev-card__meta > span { align-items: flex-start; }
.ev-card__meta i { width: 14px; margin-top: 2px; text-align: center; color: var(--teal-700); flex: 0 0 14px; }
.ev-card__venue > span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.ev-card__summary { font-size: var(--fs-sm); }
.ev-card .ev-seats { margin-top: auto; padding-top: 2px; }
.ev-card.is-cancelled .pg-card-media img { filter: grayscale(.8); opacity: .75; }
.ev-card.is-cancelled .ev-card__title a { text-decoration: line-through; text-decoration-color: rgba(164, 35, 27, .45); }
.ev-card.is-past .pg-card-media img { filter: saturate(.65); }

/* date badge on the photo: reads like a tear-off calendar when scanning */
.ev-date { position: absolute; z-index: 1; left: var(--sp-3); top: var(--sp-3); display: grid; justify-items: center; min-width: 50px;
  padding: 4px 6px 5px; border-radius: 8px; background: #fff; color: var(--ink); line-height: 1; font-family: var(--font-head);
  box-shadow: 0 6px 16px -6px rgba(0, 29, 35, .45); text-align: center; }
.ev-date__m { font-size: var(--fs-2xs); font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: #fff; background: var(--teal);
  border-radius: 4px; padding: 3px 6px; width: 100%; }
.ev-date__d { font-size: 1.45rem; font-weight: 800; margin-top: 3px; font-variant-numeric: tabular-nums; }
.ev-date__y { font-size: var(--fs-2xs); color: var(--muted); margin-top: 2px; font-variant-numeric: tabular-nums; }
.ev-date--tba .ev-date__d { font-size: var(--fs-sm); margin-top: 5px; }
.ev-card.is-past .ev-date__m { background: var(--ev-mut); }
.ev-card__flags { position: absolute; z-index: 1; left: var(--sp-3); right: var(--sp-3); bottom: var(--sp-3); display: flex; flex-wrap: wrap; gap: 6px; }
.ev-card__flags .ev-chip { box-shadow: 0 2px 8px -2px rgba(0, 29, 35, .35); }
.ev-card__flags .ev-chip:not(.ev-chip--live) { background: rgba(255, 255, 255, .95); }

/* ---- chips ------------------------------------------------------------------------------------ */
.ev-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.ev-chip { display: inline-flex; align-items: center; gap: 5px; padding: 3px 9px; border-radius: 999px; font-family: var(--font-body); font-weight: 600;
  font-size: var(--fs-2xs); background: var(--ev-mut-bg); color: var(--ev-mut); line-height: 1.35; white-space: nowrap; }
.ev-chip--ok { background: var(--ev-ok-bg); color: var(--ev-ok); }
.ev-chip--warn { background: var(--ev-warn-bg); color: var(--ev-warn); }
.ev-chip--bad { background: var(--ev-bad-bg); color: var(--ev-bad); }
.ev-chip--info { background: var(--ev-info-bg); color: var(--ev-info); }
.ev-chip--live { background: var(--ev-live); color: #fff; }
.ev-chip--live::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: #fff; animation: ev-pulse 1.6s ease-in-out infinite; }
@keyframes ev-pulse { 50% { opacity: .35; } }

/* ---- empty states, callouts, banners -------------------------------------------------------------- */
.ev-empty .btn { margin-top: var(--sp-1); }
.ev-callout { display: flex; flex-wrap: wrap; align-items: center; gap: var(--sp-3) var(--sp-4); margin-top: var(--sp-8); padding: var(--sp-4) var(--sp-5);
  border-radius: var(--card-radius); background: var(--cream); border: 1px solid #f6dcc8; }
.ev-callout__ico { width: 40px; height: 40px; border-radius: 10px; display: grid; place-items: center; background: #fff; color: var(--teal-700); flex: 0 0 40px; }
.ev-callout > div { flex: 1 1 260px; min-width: 0; }
.ev-callout h2 { font-size: var(--fs-md); margin: 0 0 2px; }
.ev-callout p { margin: 0; font-size: var(--fs-sm); color: var(--ink-2); }

.ev-banner { display: flex; gap: var(--sp-3); align-items: flex-start; padding: var(--sp-3) var(--sp-4); border-radius: var(--card-radius); border: 1px solid transparent;
  margin-bottom: var(--sp-4); background: var(--ev-info-bg); color: var(--ev-info); font-size: var(--fs-base); }
.ev-banner > i { margin-top: 3px; }
.ev-banner strong { display: block; font-family: var(--font-head); }
.ev-banner p { margin: 2px 0 0; color: var(--ink-2); font-size: var(--fs-sm); }
.ev-banner--bad { background: var(--ev-bad-bg); color: var(--ev-bad); border-color: #f3c3c0; }
.ev-banner--warn { background: var(--ev-warn-bg); color: var(--ev-warn); border-color: #f5d7a9; }
.ev-banner--ok { background: var(--ev-ok-bg); color: var(--ev-ok); border-color: #b7e2cd; }
.ev-banner--mut { background: var(--ev-mut-bg); color: var(--ev-mut); }

/* ---- detail: key facts in the page band ------------------------------------------------------------ */
.ev-headmeta { display: grid; gap: var(--sp-3); margin-top: var(--sp-3); }
.ev-headmeta .ev-chip { background: rgba(255, 255, 255, .12); color: #e6fbfc; border: 1px solid rgba(255, 255, 255, .2); }
.ev-headmeta .ev-chip--ok { background: rgba(16, 121, 79, .35); border-color: rgba(120, 220, 170, .45); color: #d9fbe9; }
.ev-headmeta .ev-chip--warn { background: rgba(255, 181, 71, .2); border-color: rgba(255, 196, 110, .5); color: #ffe7c2; }
.ev-headmeta .ev-chip--bad { background: rgba(179, 38, 30, .35); border-color: rgba(255, 150, 140, .5); color: #ffe1de; }
.ev-headmeta .ev-chip--live { background: var(--ev-live); border-color: transparent; color: #fff; }
.ev-facts { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px var(--sp-5); }
.ev-facts li { display: inline-flex; align-items: baseline; gap: var(--sp-2); color: rgba(255, 255, 255, .9); font-size: var(--fs-sm); min-width: 0; }
.ev-facts i { color: #9af4f8; width: 14px; text-align: center; flex: 0 0 14px; }
@media (min-width: 768px) { .ev-facts li { font-size: var(--fs-base); } }
.pagehead.ev-pagehead h1 { max-width: 28ch; text-wrap: balance; }
.member-layout .pg-head.is-banner.ev-pagehead .pg-title { max-width: 28ch; text-wrap: balance; }
.member-layout .pg-head.is-banner .ev-headmeta .ev-chips { margin-top: 0; }

/* ---- detail layout: main column + sticky aside ------------------------------------------------------ */
.ev-layout { display: grid; grid-template-columns: minmax(0, 1fr); gap: var(--sp-4); }
.ev-layout > * { min-width: 0; }
.ev-main { display: grid; gap: var(--sp-4); align-content: start; min-width: 0; }
.ev-aside { display: grid; gap: var(--sp-4); align-content: start; }
.ev-box + .ev-box { margin-top: 0; }
/* Phones and tablets: photo + when/where first, then the RSVP aside, then the rest (CSS order). */
@media (max-width: 1023px) {
  .ev-layout { display: flex; flex-direction: column; }
  .ev-layout > .ev-main { display: contents; }
  .ev-layout > .ev-main > * { order: 2; }
  .ev-layout > .ev-main > .ev-first { order: 0; }
  .ev-layout > .ev-aside { order: 1; }
}
@media (min-width: 1024px) {
  .ev-layout { grid-template-columns: minmax(0, 1fr) 340px; gap: var(--sp-6); align-items: start; }
  .ev-aside { position: sticky; top: calc(var(--mnav-h, 64px) + var(--sp-4)); }
}
@media (min-width: 1440px) { .ev-layout { grid-template-columns: minmax(0, 1fr) 380px; } }

.ev-hero { position: relative; border-radius: var(--card-radius); overflow: hidden; aspect-ratio: 16 / 9; background: var(--cream); }
.ev-hero img { width: 100%; height: 100%; object-fit: cover; }
@media (min-width: 768px) { .ev-hero { aspect-ratio: 2 / 1; } }
@media (min-width: 1280px) { .ev-hero { aspect-ratio: 21 / 9; } }

.ev-box { background: #fff; border: 1px solid var(--line); border-radius: var(--card-radius); padding: var(--sp-4); box-shadow: 0 1px 2px rgba(0, 29, 35, .04); min-width: 0; }
@media (min-width: 768px) { .ev-box { padding: var(--sp-5); } }
.ev-box h2 { font-family: var(--font-head); font-size: var(--fs-lg); line-height: 1.3; margin: 0 0 var(--sp-3); display: flex; align-items: center; gap: var(--sp-2); }
.ev-box h2 > i { color: var(--teal); font-size: .9em; }
.ev-lede { margin: 0 0 var(--sp-3); font-size: var(--fs-md); line-height: 1.6; color: var(--ink-2); max-width: var(--measure); }
.ev-body { overflow-wrap: anywhere; max-width: var(--measure); font-size: var(--fs-md); line-height: 1.7; color: var(--ink-2); }
.ev-body > :first-child { margin-top: 0; }
.ev-body > :last-child { margin-bottom: 0; }
.ev-body :lang(te), .ev-body:lang(te), .ev-lede:lang(te) { line-height: 1.95; }
.ev-body img { border-radius: 10px; height: auto; }
.ev-back { margin: var(--sp-6) 0 0; }

/* when & where: icon facts that sit side by side on wide screens */
.ev-ww { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr)); gap: var(--sp-4); margin: 0; }
.ev-ww > div { display: flex; gap: var(--sp-3); align-items: flex-start; min-width: 0; }
.ev-ww dt { font-size: var(--fs-xs); font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.ev-ww dd { margin: 2px 0 0; color: var(--ink); font-size: var(--fs-base); line-height: 1.5; overflow-wrap: anywhere; }
.ev-ww .ev-ico { flex: 0 0 36px; height: 36px; border-radius: 10px; background: var(--cream); color: var(--teal-700); display: grid; place-items: center; }
.ev-localtime { display: block; font-size: var(--fs-sm); color: var(--ev-info); margin-top: 2px; }
.ev-directions { margin-top: var(--sp-4); }

.ev-cal { display: grid; grid-template-columns: minmax(0, 1fr); gap: var(--sp-2); }
.ev-cal .btn { width: 100%; justify-content: center; white-space: normal; }
.ev-going { display: flex; align-items: center; gap: var(--sp-2); margin: 0 0 var(--sp-3); font-size: var(--fs-base); color: var(--ink-2); }
.ev-going i { color: var(--teal); }
.ev-going strong { font-variant-numeric: tabular-nums; }
.ev-join .btn-block { justify-content: center; }
.ev-thanks { margin: 0; padding: var(--sp-3) var(--sp-4); border-radius: var(--card-radius); background: var(--cream); font-size: var(--fs-sm); color: var(--ink-2); }
.ev-thanks i { color: #d6455d; }

/* ---- RSVP panel ------------------------------------------------------------------------------------- */
.ev-rsvp { scroll-margin-top: calc(var(--mnav-h, 64px) + var(--sp-4)); border-top: 3px solid var(--teal); }
.ev-rsvp__state { display: flex; align-items: center; gap: var(--sp-2); padding: var(--sp-3); border-radius: 10px; background: var(--ev-ok-bg); color: var(--ev-ok);
  font-family: var(--font-head); font-weight: 700; font-size: var(--fs-base); margin: 0 0 var(--sp-3); }
.ev-rsvp__state--warn { background: var(--ev-warn-bg); color: var(--ev-warn); }
.ev-rsvp__state--mut { background: var(--ev-mut-bg); color: var(--ev-mut); }
.ev-rsvp__state i { font-size: 1.1rem; }
.ev-rsvp .field { margin-bottom: var(--sp-3); }
.ev-rsvp textarea { min-height: 72px; }
.ev-actions { display: grid; gap: var(--sp-2); }
@media (min-width: 420px) { .ev-actions--two { grid-template-columns: 1fr 1fr; } }
.ev-aside .ev-actions--two { grid-template-columns: minmax(0, 1fr); }
@media (min-width: 1440px) { .ev-aside .ev-actions--two { grid-template-columns: 1fr 1fr; } }
.ev-actions .btn { width: 100%; justify-content: center; }
.ev-actions--two > :only-child { grid-column: 1 / -1; }
.ev-seats { font-size: var(--fs-sm); color: var(--ev-warn); font-weight: 600; margin: 0 0 var(--sp-3); }
.ev-check { display: flex; gap: var(--sp-2); align-items: flex-start; min-height: 36px; font-size: var(--fs-base); }
.ev-check input { width: 18px; height: 18px; margin-top: 2px; flex: 0 0 18px; accent-color: var(--teal-700); }
.ev-radio-row { display: grid; grid-template-columns: 1fr 1fr; gap: var(--sp-2); }
.ev-radio-row label { min-height: var(--ctl-h); display: flex; align-items: center; gap: var(--sp-2); border: 1px solid var(--line-strong); border-radius: var(--ctl-radius); padding: 0 var(--sp-3); cursor: pointer; font-size: var(--fs-base); }
.ev-radio-row input { accent-color: var(--teal-700); width: 16px; height: 16px; }
.ev-radio-row label:has(input:checked) { border-color: var(--teal-700); background: var(--ev-info-bg); }

/* guest stepper: - n + */
.ev-stepper { display: inline-flex; align-items: center; border: 1px solid var(--line-strong); border-radius: var(--ctl-radius); overflow: hidden; background: #fff; }
.ev-stepper button { width: 40px; height: 40px; border: 0; background: var(--cream); color: var(--teal-700); font-size: 1rem; cursor: pointer; }
.ev-stepper button:disabled { opacity: .4; cursor: not-allowed; }
.ev-stepper input { width: 52px; height: 40px; border: 0; border-radius: 0; text-align: center; font-size: 1rem; font-family: var(--font-head); font-weight: 700; -moz-appearance: textfield; appearance: textfield; }
.ev-stepper input::-webkit-outer-spin-button, .ev-stepper input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
@media (pointer: coarse) { .ev-stepper button, .ev-stepper input { height: 44px; } .ev-stepper button { width: 44px; } }

.ev-ok-pop { animation: ev-pop .2s ease-out; }
@keyframes ev-pop { from { transform: scale(.85); } to { transform: scale(1); } }

/* ---- sticky bottom action bar (member detail, phones and tablets) --------------------------------------- */
.ev-sticky { position: fixed; left: 0; right: 0; bottom: 0; z-index: 45; display: flex; gap: var(--sp-3); align-items: center;
  padding: var(--sp-2) var(--gutter) calc(var(--sp-2) + env(safe-area-inset-bottom)); background: rgba(255, 255, 255, .97); border-top: 1px solid var(--line);
  box-shadow: 0 -8px 24px -12px rgba(0, 29, 35, .25); transition: transform .2s ease; }
.ev-sticky .btn { flex: 0 0 auto; min-height: 44px; }
.ev-sticky__info { flex: 1 1 auto; min-width: 0; font-size: var(--fs-xs); line-height: 1.3; }
.ev-sticky__info strong { display: block; font-family: var(--font-head); font-size: var(--fs-sm); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ev-sticky.is-hidden { transform: translateY(110%); }
@media (max-width: 1023px) {
  body.has-ev-sticky .page-body, body.has-ev-sticky .portal-content { padding-bottom: calc(84px + env(safe-area-inset-bottom)); }
  body.has-ev-sticky .back-top { bottom: calc(84px + env(safe-area-inset-bottom)); }
}
@media (min-width: 1024px) { .ev-sticky { display: none; } }

/* ---- attendee list (members) -------------------------------------------------------------------- */
.ev-people { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 220px), 1fr)); gap: 0 var(--sp-5); }
.ev-people li { display: flex; justify-content: space-between; gap: var(--sp-2); padding: 7px 0; border-bottom: 1px solid var(--line); font-size: var(--fs-base); }
.ev-batch-h { font-family: var(--font-body); font-size: var(--fs-2xs); font-weight: 700; color: var(--teal-700); margin: var(--sp-4) 0 var(--sp-1); text-transform: uppercase; letter-spacing: .08em; }

/* ---- agenda (timeline) / speakers ------------------------------------------------------------------ */
.ev-agenda { list-style: none; padding: 0; margin: 0; display: grid; }
.ev-agenda li { position: relative; display: grid; grid-template-columns: 76px minmax(0, 1fr); gap: var(--sp-3); padding: 0 0 var(--sp-4); }
.ev-agenda li:last-child { padding-bottom: 0; }
.ev-agenda li::before { content: ""; position: absolute; left: 84px; top: 6px; width: 9px; height: 9px; border-radius: 50%; background: var(--teal); box-shadow: 0 0 0 3px var(--ev-info-bg); }
.ev-agenda li:not(:last-child)::after { content: ""; position: absolute; left: 88px; top: 18px; bottom: 2px; width: 1px; background: var(--line-strong); }
.ev-agenda time { font-family: var(--font-head); font-weight: 700; font-size: var(--fs-sm); color: var(--teal-700); font-variant-numeric: tabular-nums; white-space: nowrap; }
.ev-agenda__item { padding-left: var(--sp-5); font-size: var(--fs-base); }
.ev-agenda__item strong { display: block; color: var(--ink); }
.ev-agenda__who { display: inline-flex; align-items: center; gap: 6px; margin-top: 2px; font-size: var(--fs-sm); color: var(--muted); }
.ev-agenda__who i { color: var(--teal); font-size: .9em; }
.ev-agenda p { margin: 4px 0 0; color: var(--muted); font-size: var(--fs-sm); max-width: var(--measure); }
.ev-speakers { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: var(--sp-3); }
.ev-speaker { display: grid; justify-items: center; gap: 2px; text-align: center; padding: var(--sp-4) var(--sp-3); border: 1px solid var(--line); border-radius: var(--card-radius); font-size: var(--fs-sm); }
.ev-speaker img { width: 64px; height: 64px; border-radius: 50%; object-fit: cover; margin: 0 auto var(--sp-2); background: var(--cream); }
.ev-speaker strong { font-family: var(--font-head); font-size: var(--fs-base); }

/* ---- support (donation campaign) ------------------------------------------------------------------- */
.ev-support .bar { height: 8px; border-radius: 99px; background: #eef1f1; overflow: hidden; }
.ev-support .bar > i { display: block; height: 100%; width: 0; background: linear-gradient(90deg, var(--teal), var(--teal-300)); border-radius: inherit; transition: width .9s ease; }
.ev-support h2 > i { color: #d6455d; }

/* ---- rating (feedback) ---------------------------------------------------------------------------- */
.ev-rating { display: flex; gap: 6px; flex-wrap: wrap; border: 0; padding: 0; margin: 0 0 var(--sp-3); }
.ev-rating legend { font-family: var(--font-head); font-weight: 600; font-size: var(--fs-base); margin-bottom: var(--sp-2); }
.ev-rating label { min-width: 40px; min-height: 40px; display: grid; place-items: center; border: 1px solid var(--line-strong); border-radius: var(--ctl-radius); cursor: pointer; font-family: var(--font-head); font-weight: 700; }
.ev-rating input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.ev-rating label:has(input:checked) { background: var(--teal-700); color: #fff; border-color: var(--teal-700); }
.ev-rating label:has(input:focus-visible) { outline: 3px solid var(--teal-700); outline-offset: 2px; }
@media (pointer: coarse) { .ev-rating label { min-width: 44px; min-height: 44px; } }

/* ---- ticket: a printable stub with a perforated cut ---------------------------------------------------- */
.ev-ticket { position: relative; max-width: 440px; margin: 0 auto; text-align: center; background: #fff; border: 1px solid var(--line); border-radius: 18px;
  box-shadow: 0 24px 50px -28px rgba(0, 29, 35, .45); overflow: hidden; }
.ev-ticket__top { padding: var(--sp-5) var(--sp-5) var(--sp-4); background: linear-gradient(160deg, #f2fbfb, #fff 70%); display: grid; justify-items: center; gap: var(--sp-2); }
.ev-ticket__title, .ev-ticket h1 { font-family: var(--font-head); font-size: 1.25rem; line-height: 1.25; margin: var(--sp-1) 0 0; text-wrap: balance; }
.ev-ticket__when { margin: 0; font-size: var(--fs-sm); color: var(--muted); display: flex; gap: 6px; align-items: baseline; justify-content: center; }
.ev-ticket__when i { color: var(--teal); }
.ev-ticket__cut { position: relative; height: 0; border-top: 2px dashed var(--line-strong); margin: 0 var(--sp-4); }
.ev-ticket__cut::before, .ev-ticket__cut::after { content: ""; position: absolute; top: -12px; width: 22px; height: 22px; border-radius: 50%; background: var(--paper); border: 1px solid var(--line); }
.ev-ticket__cut::before { left: calc(-1 * var(--sp-4) - 12px); }
.ev-ticket__cut::after { right: calc(-1 * var(--sp-4) - 12px); }
.ev-ticket__bottom { padding: var(--sp-4) var(--sp-5) var(--sp-5); }
.ev-ticket__actions { display: flex; flex-wrap: wrap; justify-content: center; gap: var(--sp-2); margin: var(--sp-5) auto 0; max-width: 440px; }
.ev-ticket__actions .btn { flex: 1 1 160px; justify-content: center; }
.ev-qr { background: #fff; padding: 12px; display: inline-block; border-radius: 12px; border: 1px solid var(--line); margin: var(--sp-2) 0; }
.ev-qr img { width: 240px; height: 240px; max-width: 64vw; max-height: 64vw; image-rendering: pixelated; }
.ev-code { font-family: ui-monospace, "Cascadia Mono", Consolas, monospace; font-size: 1.75rem; letter-spacing: .18em; font-weight: 700; color: var(--ink); font-variant-numeric: tabular-nums; }
.ev-ticket__who { font-family: var(--font-head); font-size: var(--fs-lg); font-weight: 700; margin-top: var(--sp-2); }
.ev-tip { font-size: var(--fs-sm); color: var(--muted); margin: var(--sp-3) 0 0; }
.ev-tip i { color: #e7a200; }
.ev-ticket .btn-block, .ev-ticket form .btn { justify-content: center; }
.member-layout .ev-ticket-page .ev-ticket { margin-top: var(--sp-2); }
@media print {
  .side, .topbar, .ev-noprint, .mnav, .mdrawer, .site-header, .site-footer, .footer, footer, nav, .back-top, .whatsapp-float { display: none !important; }
  .portal-main { margin: 0 !important; }
  .page-body { padding: 0 !important; }
  .ev-ticket { box-shadow: none; border: 2px solid #000; page-break-inside: avoid; margin-top: 0; }
  .ev-ticket__top { background: none; }
  body { background: #fff !important; }
}

/* ---- check-in (venue desk, one-handed) ------------------------------------------------------------ */
.ev-checkin { list-style: none; padding: 0; margin: 0; display: grid; gap: .5rem; }
.ev-checkin li { background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: .7rem .8rem; display: grid; grid-template-columns: 1fr; gap: .6rem; min-height: 56px; }
@media (min-width: 640px) { .ev-checkin li { grid-template-columns: 1fr auto; align-items: center; } }
.ev-checkin li.is-in { border-color: #b7e2cd; background: #f6fcf9; }
.ev-checkin li[hidden] { display: none; }
.ev-checkin .ev-who strong { font-family: var(--font-head); font-size: 1.05rem; display: block; }
.ev-checkin form { margin: 0; }
.ev-checkin .btn { width: 100%; min-height: 52px; }
@media (min-width: 640px) { .ev-checkin .btn { width: auto; min-width: 150px; } }
.ev-flash { padding: .9rem 1rem; border-radius: 12px; font-family: var(--font-head); font-weight: 700; margin-bottom: .8rem; }
.ev-flash--ok { background: var(--ev-ok-bg); color: var(--ev-ok); }
.ev-flash--bad { background: var(--ev-bad-bg); color: var(--ev-bad); }
.ev-flash.is-new { animation: ev-flash 1s ease-out; }
@keyframes ev-flash { 0% { box-shadow: 0 0 0 0 rgba(16,121,79,.5); } 100% { box-shadow: 0 0 0 14px rgba(16,121,79,0); } }

/* ---- editor (admin + batch-admin consoles) ------------------------------------------------------------ */
.ev-editor details { background: #fff; border: 1px solid var(--line); border-radius: var(--card-radius); margin-bottom: var(--sp-3); box-shadow: 0 1px 2px rgba(0, 29, 35, .04); }
.ev-editor summary { min-height: 48px; display: flex; align-items: center; gap: var(--sp-2); padding: var(--sp-3) var(--sp-4); cursor: pointer; font-family: var(--font-head); font-weight: 700; font-size: var(--fs-md); list-style: none; }
.ev-editor summary::-webkit-details-marker { display: none; }
.ev-editor summary::after { content: "\f078"; font-family: "Font Awesome 6 Free"; font-weight: 900; margin-left: auto; font-size: .75rem; color: var(--muted); transition: transform .2s; }
.ev-editor details[open] > summary::after { transform: rotate(180deg); }
.ev-editor details[open] > summary { border-bottom: 1px solid var(--line); margin-bottom: var(--sp-3); }
.ev-editor summary i { color: var(--teal-700); width: 20px; text-align: center; }
.ev-editor .ev-sec { padding: 0 var(--sp-4) var(--sp-4); }
.ev-editor textarea { min-height: 110px; }
.ev-grid2 { display: grid; grid-template-columns: 1fr; gap: 0 var(--sp-4); }
@media (min-width: 620px) { .ev-grid2 { grid-template-columns: 1fr 1fr; } .ev-grid3 { grid-template-columns: 1fr 1fr 1fr; } }
@media (min-width: 1280px) { .ev-editor .ev-grid2.ev-grid3 { grid-template-columns: repeat(3, 1fr); } }
.ev-hint { color: var(--muted); font-size: var(--fs-xs); margin: 4px 0 0; }
.ev-error-summary { background: var(--ev-bad-bg); color: var(--ev-bad); border-radius: var(--card-radius); padding: var(--sp-3) var(--sp-4); margin-bottom: var(--sp-4); }
.ev-error-summary:focus { outline: 3px solid var(--ev-bad); }
.ev-savebar { position: sticky; bottom: 0; z-index: 10; background: rgba(248,248,249,.96); padding: var(--sp-3) 0 calc(var(--sp-3) + env(safe-area-inset-bottom)); display: flex; gap: var(--sp-2); flex-wrap: wrap; border-top: 1px solid var(--line); }
.ev-savebar .btn { flex: 1 1 160px; justify-content: center; }
@media (min-width: 760px) { .ev-savebar { justify-content: flex-end; } .ev-savebar .btn { flex: 0 0 auto; min-width: 140px; } }
.ev-repeat { border: 1px dashed var(--line-strong); border-radius: var(--card-radius); padding: var(--sp-3); margin-bottom: var(--sp-3); }
.ev-danger { border-color: #f3c3c0 !important; }
.ev-danger summary { color: var(--ev-bad); }
.ev-danger summary i { color: var(--ev-bad); }

/* ---- admin / batch-admin consoles (layout comes from console.css; only event-specific bits here) ------ */
.ev-total { font-size: var(--fs-sm); color: var(--muted); font-variant-numeric: tabular-nums; }
.ev-dtile { flex-direction: column; gap: 0; line-height: 1; font-family: var(--font-head); text-align: center; border: 1px solid rgba(18, 146, 152, .18); }
.ev-dtile b { font-size: 1.05rem; font-weight: 800; color: var(--teal-700); }
.ev-dtile small { font-size: .62rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-2); margin-top: 2px; }
tr.ev-row-past .ev-dtile, .pg-tile.is-past .ev-dtile { background: #eef1f1; border-color: var(--line); }
tr.ev-row-past .ev-dtile b, .pg-tile.is-past .ev-dtile b { color: var(--muted); }
.pg-tile .ev-tilehead { display: flex; gap: var(--sp-3); align-items: flex-start; }
.pg-tile .ev-tilehead > div { min-width: 0; display: grid; gap: 4px; }
.ev-meter { height: 6px; border-radius: 99px; background: #eef1f1; overflow: hidden; }
.ev-meter > span { display: block; height: 100%; background: linear-gradient(90deg, var(--teal), var(--teal-300)); border-radius: inherit; }
.ev-desk-search { position: sticky; top: calc(var(--top-h, 60px) + 6px); z-index: 5; background: var(--paper); padding: var(--sp-1) 0 var(--sp-3); }
.ev-desk-search .input { min-height: 48px; font-size: 16px; border-width: 2px; border-color: var(--teal-300); border-radius: 12px; }
.ev-acts { display: flex; flex-wrap: wrap; gap: .5rem; }
.ev-contact { display: flex; flex-wrap: wrap; align-items: center; gap: 2px 10px; max-width: 360px; white-space: normal; }
.ev-contact form { margin: 0; }
.ev-contact .btn-reveal { white-space: nowrap; }
@media (min-width: 1200px) { .ev-contact { flex-wrap: nowrap; max-width: none; } .ev-contact .pii { white-space: nowrap; overflow-wrap: normal; } }
@media (max-width: 759px) { .ev-contact { justify-content: flex-end; text-align: right; } }
.ev-acts form { margin: 0; }
.ev-pop { position: relative; }
.ev-pop > summary { list-style: none; }
.ev-pop > summary::-webkit-details-marker { display: none; }
.ev-pop-body { margin-top: .5rem; background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: .8rem; box-shadow: var(--shadow); display: grid; gap: .5rem; min-width: 240px; }
@media (min-width: 760px) { .ev-pop-body { position: absolute; right: 0; z-index: 20; } }
.ev-pop-body label { font-size: .85rem; font-family: var(--font-head); }
.ev-pop-body input, .ev-pop-body select, .ev-pop-body textarea { width: 100%; min-height: 44px; font-size: 16px; padding: .5rem .7rem; border: 1px solid var(--line); border-radius: 10px; }
/* RSVP "change guests or note": the panel opens in place (no floating popover inside the aside) */
.ev-rsvp .ev-pop > summary.btn { justify-content: center; }

/* ---- member pages: member.css carries older per-feature sizes; the shared tile values win here ---- */
.member-layout .ev-card, .member-layout .ev-box, .member-layout .ev-hero { border-radius: var(--card-radius); }
.member-layout .ev-card__meta { font-size: var(--fs-xs); }
.member-layout .ev-card__summary { font-size: var(--fs-sm); }
.member-layout .ev-hero { aspect-ratio: 16 / 9; }
@media (min-width: 768px) { .member-layout .ev-hero { aspect-ratio: 2 / 1; } }
@media (min-width: 1280px) { .member-layout .ev-hero { aspect-ratio: 21 / 9; } }

/* ---- motion: everything off under prefers-reduced-motion ------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  .ev-sticky, .ev-editor summary::after, .ev-seg a, .ev-filters a, .ev-support .bar > i { transition: none !important; }
  .ev-ok-pop, .ev-flash.is-new, .ev-chip--live::before { animation: none !important; }
}

/* ---- single-event management tabs + editor spans (events-operations.md §6) ---- */
.ev-manage-tabs { margin: 0 0 var(--sp-3, 12px); }
.ev-grid2 > .ev-span2 { grid-column: 1 / -1; }

/* ---- programme on the event pages (events-programme.md §1): day tabs, hourly timeline, meals, practical info ---- */
.ev-prog .pk-session { --pk: #0b6569; --pk-bg: #e6f5f5; }
.ev-prog .pk-meal { --pk: #9a4a00; --pk-bg: #fff1e3; }
.ev-prog .pk-break { --pk: #6b5a2e; --pk-bg: #f6f1e4; }
.ev-prog .pk-activity { --pk: #1e6b3a; --pk-bg: #e7f5ec; }
.ev-prog .pk-ceremony { --pk: #6a3d8f; --pk-bg: #f3ecf9; }
.ev-prog .pk-travel { --pk: #1f5694; --pk-bg: #e8f0fa; }
.ev-prog .pk-registration { --pk: #3d4f5c; --pk-bg: #edf1f4; }
.ev-prog .pk-other { --pk: #4a585b; --pk-bg: #eef1f1; }
.ev-prog { scroll-margin-top: calc(var(--mnav-h, 0px) + 1rem); }
.ev-prog-live { display: grid; gap: 6px; margin: 0 0 var(--sp-3); padding: var(--sp-2) var(--sp-3); border-radius: 12px; background: #fff7f6; border: 1px solid #f3c3c0; font-size: var(--fs-sm); }
.ev-prog-live p { margin: 0; display: flex; flex-wrap: wrap; gap: 4px 8px; align-items: center; }
.ev-prog-live a { font-weight: 700; color: var(--ink); }
.ev-prog-tabs { display: flex; gap: var(--sp-2); overflow-x: auto; margin: 0 0 var(--sp-3); padding: 2px 2px var(--sp-1); scrollbar-width: none; }
.ev-prog-tabs[hidden] { display: none; }
.ev-prog-tabs::-webkit-scrollbar { display: none; }
.ev-prog-tab { flex: 0 0 auto; display: grid; justify-items: start; min-height: 44px; padding: 6px 14px; border: 1px solid var(--line); border-radius: 12px;
  background: #fff; color: var(--ink); font: inherit; text-align: left; cursor: pointer; transition: background .15s, border-color .15s; }
.ev-prog-tab:hover { border-color: var(--teal); }
.ev-prog-tab.is-active { background: var(--teal); border-color: var(--teal); color: #fff; }
.ev-prog-tab-n { font-family: var(--font-head); font-weight: 700; font-size: var(--fs-sm); }
.ev-prog-tab-d { font-size: var(--fs-xs); opacity: .85; }
.ev-prog-day + .ev-prog-day { margin-top: var(--sp-4); }
.ev-prog-day[hidden] { display: none; }
.ev-prog-day:focus-visible { outline: 3px solid var(--teal-700); outline-offset: 2px; border-radius: 8px; }
.ev-prog-dayhead { position: sticky; top: var(--mnav-h, 0px); z-index: 2; margin: 0 0 4px; padding: 6px 0; background: #fff; font-family: var(--font-head); font-size: var(--fs-base, 1rem); line-height: 1.3; }
.ev-prog-dayhead small { display: block; font-family: var(--font-body); font-weight: 600; font-size: var(--fs-sm); color: var(--muted); }
.ev-prog-dayn { display: inline-block; margin-right: 4px; padding: 0 8px; border-radius: 999px; background: var(--teal); color: #fff; font-size: var(--fs-xs); vertical-align: 2px; }
.ev-prog-dayvenue { display: flex; flex-wrap: wrap; gap: 4px 8px; align-items: baseline; margin: 0 0 var(--sp-2); font-size: var(--fs-sm); color: var(--ink-2, var(--ink)); }
.ev-prog-dayvenue i { color: var(--teal); }
.ev-prog-dayvenue a { font-weight: 600; color: var(--teal-700); }
.ev-prog-daynotes { margin: 0 0 var(--sp-2); font-size: var(--fs-sm); white-space: pre-line; color: var(--muted); }
.ev-prog-tl { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--sp-2); }
.ev-prog-hour { display: flex; align-items: center; gap: var(--sp-2); margin-top: 2px; font-size: var(--fs-xs); font-weight: 700; color: var(--muted); }
.ev-prog-hour::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.ev-prog-item { display: grid; grid-template-columns: 4.4rem minmax(0, 1fr); gap: var(--sp-2); align-items: start; scroll-margin-top: 5rem; }
@media (min-width: 768px) { .ev-prog-item { grid-template-columns: 5rem minmax(0, 1fr); } }
.ev-prog-time { display: grid; padding-top: 8px; font-size: var(--fs-sm); font-weight: 700; font-variant-numeric: tabular-nums; line-height: 1.25; }
.ev-prog-to { font-weight: 400; font-size: var(--fs-xs); color: var(--muted); }
.ev-prog-body { min-width: 0; padding: var(--sp-2) var(--sp-3); border: 1px solid var(--line); border-left: 4px solid var(--pk, var(--teal)); border-radius: 12px; background: #fff; }
.ev-prog-kind { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin: 0; font-size: var(--fs-xs); font-weight: 700; color: var(--pk, var(--muted)); }
.ev-prog-kind .ev-chip { font-size: var(--fs-2xs, .7rem); padding: 1px 8px; }
.ev-prog-title { margin: 2px 0 0; font-family: var(--font-head); font-size: var(--fs-base, 1rem); line-height: 1.3; overflow-wrap: anywhere; }
.ev-prog-meta { display: flex; flex-wrap: wrap; gap: 2px var(--sp-3); margin: 4px 0 0; font-size: var(--fs-sm); color: var(--muted); }
.ev-prog-meta i { margin-right: 3px; color: var(--pk, var(--teal)); }
.ev-prog-desc { margin: 6px 0 0; font-size: var(--fs-sm); white-space: pre-line; overflow-wrap: anywhere; }
.ev-prog-menu { margin: 6px 0 0; padding: 6px 10px; border-radius: 8px; background: var(--pk-bg, #fff7ee); }
.ev-prog-menu-h { margin: 0; font-size: var(--fs-2xs, .7rem); font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--pk, var(--muted)); }
.ev-prog-menu ul { margin: 2px 0 0; padding-left: 1.1rem; font-size: var(--fs-sm); columns: 2 9rem; column-gap: var(--sp-4); }
.ev-prog-item.is-now .ev-prog-body { border-color: var(--ev-live, #b3261e); border-left-color: var(--ev-live, #b3261e); box-shadow: 0 0 0 3px rgba(179, 38, 30, .12); }
.ev-prog-item.is-next .ev-prog-body { border-color: var(--teal); box-shadow: 0 0 0 3px rgba(18, 146, 152, .12); }
.ev-prog-item.is-over { opacity: .62; }
.ev-prog-item:target .ev-prog-body { box-shadow: 0 0 0 3px rgba(18, 146, 152, .35); }
.ev-prog-info { margin-top: var(--sp-4); }
.ev-prog-infoh { margin: 0 0 var(--sp-2); font-family: var(--font-head); font-size: var(--fs-base, 1rem); }
.ev-prog-acc { border: 1px solid var(--line); border-radius: 12px; background: #fff; }
.ev-prog-acc + .ev-prog-acc { margin-top: var(--sp-2); }
.ev-prog-acc > summary { display: flex; align-items: center; gap: var(--sp-2); min-height: 44px; padding: 6px var(--sp-3); cursor: pointer; font-weight: 700; list-style: none; }
.ev-prog-acc > summary::-webkit-details-marker { display: none; }
.ev-prog-acc > summary::after { content: "+"; margin-left: auto; font-size: 1.1rem; color: var(--teal-700); }
.ev-prog-acc[open] > summary::after { content: "–"; }
.ev-prog-acc > summary > i { color: var(--teal); width: 1.1rem; text-align: center; }
.ev-prog-acc-n { font-size: var(--fs-xs); font-weight: 600; color: var(--muted); }
.ev-prog-acc-body { padding: 0 var(--sp-3) var(--sp-3); }
.ev-prog-acc-body h4 { margin: var(--sp-2) 0 2px; font-size: var(--fs-sm); }
.ev-prog-acc-body p { margin: 0; font-size: var(--fs-sm); white-space: pre-line; overflow-wrap: anywhere; }
@media (prefers-reduced-motion: reduce) { .ev-prog-tab { transition: none; } }
@media print { .ev-prog-tabs { display: none !important; } .ev-prog-day[hidden] { display: block !important; } .ev-prog-dayhead { position: static; } }
