/* css/events-public.css — public events listing: hero, toolbar, tabs, ticket-style cards, pager. Shared pieces live in events-shared.css. */

/* ---------- Hero (shares the site's .page-title-section) ---------- */
.ev-hero {
  position: relative;
  margin-bottom: 0;
  padding: 3.25rem 0 4.5rem;                /* bottom room for the toolbar that overlaps it */
  background:
    radial-gradient(52rem 20rem at 88% -20%, rgba(201, 164, 107, .24), transparent 62%),
    radial-gradient(38rem 18rem at 4% 120%, rgba(28, 74, 126, .6), transparent 62%),
    var(--primary-color, #0a2342);
}
.ev-hero::after {
  content: ""; position: absolute; inset: auto 0 0 0; height: 3px;
  background: linear-gradient(90deg, transparent, var(--ev-gold) 20%, var(--ev-gold) 80%, transparent);
}
.ev-eyebrow {
  margin: 0 0 .5rem;
  color: #e7cf9f;
  font: 700 .78rem/1 var(--body-font, Lato, sans-serif);
  letter-spacing: .28em; text-transform: uppercase;
}
.ev-hero h1 { margin: 0; font-size: clamp(2.4rem, 1.7rem + 3.4vw, 4rem); letter-spacing: -.015em; }
.ev-hero .subtitle { max-width: 38rem; margin: .8rem auto 0; color: rgba(255, 255, 255, .86); opacity: 1; font-size: clamp(1rem, .95rem + .3vw, 1.15rem); }
.ev-hero-stats {
  display: flex; flex-wrap: wrap; justify-content: center; gap: .35rem 1.4rem;
  margin: 1.1rem 0 0; color: rgba(255, 255, 255, .86); font-size: .95rem;
}
.ev-hero-stats strong { color: #fff; font-weight: 700; }
.ev-hero-stats span + span::before { content: "•"; margin-right: 1.4rem; color: var(--ev-gold); }
.ev-admin-add {
  display: inline-flex; align-items: center; gap: .5rem; margin-top: 1.25rem;
  min-height: 44px; padding: .55rem 1.2rem; border-radius: 999px;
  background: var(--ev-gold); color: var(--ev-ink) !important; font-weight: 700; text-decoration: none;
  transition: background-color .2s;
}
.ev-admin-add:hover { background: #dcc08f; }

/* ---------- Toolbar: search, switch, type chips ---------- */
.ev-wrap { max-width: 1100px; margin-inline: auto; padding-inline: 20px; }
.ev-toolbar {
  position: relative; z-index: 2;
  margin: -2.2rem auto 2rem;
  padding: 1rem 1.1rem 1.05rem;
  background: var(--ev-card);
  border: 1px solid var(--ev-line);
  border-radius: 20px;
  box-shadow: var(--ev-shade);
}
.ev-search { display: flex; flex-wrap: wrap; align-items: center; gap: .65rem .9rem; }
.ev-search__field { position: relative; flex: 1 1 15rem; min-width: 0; }
.ev-search__field i { position: absolute; left: 1rem; top: 50%; translate: 0 -50%; color: var(--ev-muted); pointer-events: none; }
.ev-search__input {
  width: 100%; min-height: 46px; padding: .6rem 1rem .6rem 2.7rem;
  border: 1.5px solid var(--ev-line); border-radius: 999px; background: #fff;
  font: 400 1rem/1.2 var(--body-font, Lato, sans-serif); color: var(--ev-text);
}
.ev-search__input::placeholder { color: #6b7280; }
.ev-search__input:hover { border-color: rgba(10, 35, 66, .3); }
.ev-switch { display: inline-flex; align-items: center; gap: .6rem; min-height: 44px; cursor: pointer; font-weight: 700; color: var(--ev-ink); user-select: none; }
.ev-switch input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.ev-switch__track { position: relative; width: 44px; height: 26px; flex: none; border-radius: 999px; background: #cbd5e1; transition: background-color .2s; }
.ev-switch__track::after { content: ""; position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0, 0, 0, .3); transition: transform .25s var(--ev-ease); }
.ev-switch input:checked + .ev-switch__track { background: var(--ev-ink); }
.ev-switch input:checked + .ev-switch__track::after { transform: translateX(18px); }
.ev-switch input:focus-visible + .ev-switch__track { outline: 3px solid var(--ev-ink); outline-offset: 2px; box-shadow: 0 0 0 5px rgba(201, 164, 107, .75); }

.ev-chips { display: flex; flex-wrap: wrap; gap: .5rem; margin: .9rem 0 0; padding: 0; list-style: none; }
.ev-chip {
  display: inline-flex; align-items: center; gap: .45rem; min-height: 38px; padding: .3rem .95rem;
  border: 1.5px solid var(--ev-line); border-radius: 999px; background: #fff;
  color: var(--ev-ink); font-size: .9rem; font-weight: 700; text-transform: capitalize; text-decoration: none;
  transition: background-color .2s, border-color .2s, color .2s;
}
.ev-chip small { color: var(--ev-muted); font-weight: 700; font-size: .78rem; }
.ev-chip:hover { border-color: var(--ev-ink); }
.ev-chip[aria-current="true"] { background: var(--ev-ink); border-color: var(--ev-ink); color: #fff; }
.ev-chip[aria-current="true"] small { color: #e7cf9f; }

/* ---------- Tabs ---------- */
.ev-tabbar { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: .5rem 1.5rem; border-bottom: 1px solid var(--ev-line); margin-bottom: 1.75rem; }
.ev-tabs { display: flex; gap: .25rem; }
.ev-tab {
  position: relative; display: inline-flex; align-items: center; gap: .55rem; min-height: 48px; padding: .6rem 1.1rem;
  color: var(--ev-muted); font: 700 1.02rem/1 var(--body-font, Lato, sans-serif); text-decoration: none;
  transition: color .2s;
}
.ev-tab::after {
  content: ""; position: absolute; left: .6rem; right: .6rem; bottom: -1px; height: 3px; border-radius: 3px 3px 0 0;
  background: var(--ev-gold); transform: scaleX(0); transform-origin: left; transition: transform .35s var(--ev-ease);
}
.ev-tab:hover { color: var(--ev-ink); }
.ev-tab[aria-selected="true"] { color: var(--ev-ink); }
.ev-tab[aria-selected="true"]::after { transform: scaleX(1); }
.ev-tab__n {
  min-width: 1.7rem; padding: .15rem .5rem; border-radius: 999px; background: #ece6d8; color: var(--ev-ink);
  font-size: .78rem; font-weight: 700; text-align: center; font-variant-numeric: tabular-nums;
}
.ev-tab[aria-selected="true"] .ev-tab__n { background: var(--ev-ink); color: #fff; }
.ev-results { margin: 0 0 .75rem; color: var(--ev-muted); font-size: .92rem; }

.ev-panel:focus { outline: none; }
.ev-panel.is-entering { animation: ev-rise .45s var(--ev-ease); }
/* ---------- Grid + year markers ---------- */
.ev-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 19.5rem), 1fr)); gap: 2rem 1.6rem; margin: 0; padding: 0; list-style: none; }
.ev-year {
  grid-column: 1 / -1; display: flex; align-items: center; gap: 1rem; margin: .6rem 0 -.4rem;
  font-family: var(--heading-font, Georgia, serif); font-size: clamp(1.8rem, 1.4rem + 1.6vw, 2.6rem); font-weight: 700; line-height: 1; color: var(--ev-gold-deep);
}
.ev-year:first-child { margin-top: 0; }
.ev-year::after { content: ""; flex: 1; height: 1px; background: linear-gradient(90deg, var(--ev-gold), transparent); }

/* ---------- Card (ticket stub) ---------- */
.ev-card {
  position: relative; display: flex; flex-direction: column;
  background: var(--ev-card); border: 1px solid var(--ev-line); border-radius: var(--ev-r);
  box-shadow: var(--ev-shade);
  transition: transform .35s var(--ev-ease), box-shadow .35s;
}
.ev-card__top { position: relative; }
.ev-card__media {
  position: relative; aspect-ratio: 16 / 10; overflow: hidden; background: var(--ev-ink);
  border-radius: calc(var(--ev-r) - 1px) calc(var(--ev-r) - 1px) 0 0;
}
.ev-card__media img {                         /* out of flow: a poster's own ratio must never size the card */
  position: absolute; inset: 0; display: block; width: 100%; height: 100%;
  object-fit: cover; object-position: 50% 18%; transition: transform .7s var(--ev-ease);
}
.ev-card__media--tall img { object-position: 50% 0; }
.ev-card__media::after {                      /* keeps the badge legible on any poster */
  content: ""; position: absolute; inset: 0 0 auto 0; height: 38%; pointer-events: none;
  background: linear-gradient(rgba(8, 19, 31, .45), transparent);
}



.ev-card__body { display: flex; flex-direction: column; flex: 1; padding: .55rem 1.25rem 1.1rem; }
.ev-card__kicker { display: flex; flex-wrap: wrap; align-items: center; gap: .15rem .7rem; min-height: 1.9rem; margin: 0 0 .65rem; padding-left: 4.15rem; font: 700 .72rem/1.2 var(--body-font, Lato, sans-serif); letter-spacing: .14em; text-transform: uppercase; }
.ev-card__type { color: var(--ev-gold-deep); }
.ev-card__soon { color: var(--ev-ok); }
.ev-card__title { margin: 0; font-size: clamp(1.25rem, 1.12rem + .5vw, 1.5rem); line-height: 1.22; text-wrap: balance; }
.ev-card__title a { color: var(--ev-ink); text-decoration: none; }
.ev-card__title a::after { content: ""; position: absolute; inset: 0; z-index: 1; border-radius: var(--ev-r); }   /* whole card is the link target */
.ev-card__title a:focus-visible { outline: none; box-shadow: none; }
.ev-card__title a:focus-visible::after { outline: 3px solid var(--ev-ink); outline-offset: 3px; box-shadow: 0 0 0 6px rgba(201, 164, 107, .75); }
.ev-card__meta { display: grid; gap: .3rem; margin: .8rem 0 0; padding: 0; list-style: none; color: var(--ev-muted); font-size: .92rem; }
.ev-card__meta li { display: flex; gap: .6rem; align-items: baseline; }
.ev-card__meta i { flex: none; width: 1rem; text-align: center; color: var(--ev-gold-deep); }
.ev-card__excerpt {
  margin: .85rem 0 0; color: var(--ev-text); font-size: .96rem; line-height: 1.6;
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}


/* perforated foot with ticket notches */
.ev-card__foot { position: relative; padding: 1rem 1.25rem 1.1rem; border-top: 2px dashed var(--ev-line); }
.ev-card__foot::before, .ev-card__foot::after {
  content: ""; position: absolute; top: -11px; width: 20px; height: 20px; border-radius: 50%;
  background: var(--ev-paper); box-shadow: inset 0 0 0 1px var(--ev-line);
}
.ev-card__foot::before { left: -11px; clip-path: inset(0 0 0 50%); }
.ev-card__foot::after { right: -11px; clip-path: inset(0 50% 0 0); }
.ev-card__actions { display: flex; flex-wrap: wrap; gap: .5rem; }
.ev-card__actions .ev-btn { flex: 1 1 auto; }
.ev-card__actions .ev-btn--heart { flex: 0 1 auto; }

.ev-share { display: flex; gap: .4rem; margin-top: .75rem; }
.ev-share__btn {
  position: relative; z-index: 2; display: inline-flex; align-items: center; justify-content: center;
  width: 44px; height: 44px; margin: -2px; border: 0; border-radius: 12px; background: transparent;
  color: var(--ev-ink); font-size: 1.05rem; cursor: pointer; text-decoration: none;
  transition: background-color .2s, color .2s;
}
.ev-share__btn:hover { background: rgba(10, 35, 66, .08); }
.ev-share__btn.is-done { color: var(--ev-ok); background: var(--ev-ok-bg); }

@media (hover: hover) {
  .ev-card:hover { transform: translateY(-5px); box-shadow: var(--ev-shade-hi); }
  .ev-card:hover .ev-card__media img { transform: scale(1.045); }
}

/* the next upcoming event gets the wide treatment */
@media (min-width: 900px) {
  .ev-card--feature { grid-column: 1 / -1; display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); grid-template-rows: 1fr auto; }
  .ev-card--feature .ev-card__top { grid-row: 1 / 3; }
  .ev-card--feature .ev-card__media { height: 100%; aspect-ratio: auto; min-height: 22rem; border-radius: calc(var(--ev-r) - 1px) 0 0 calc(var(--ev-r) - 1px); }
  .ev-card--feature .ev-plate { left: auto; right: -2.2rem; top: 1.75rem; bottom: auto; width: 4.4rem; }
  .ev-card--feature .ev-card__body { padding: 2rem 2rem .6rem 3.4rem; justify-content: center; }
  .ev-card--feature .ev-card__kicker { padding-left: 0; }
  .ev-card--feature .ev-card__title { font-size: clamp(1.8rem, 1.4rem + 1vw, 2.35rem); }
  .ev-card--feature .ev-card__excerpt { -webkit-line-clamp: 5; font-size: 1.02rem; }
  .ev-card--feature .ev-card__foot { padding-inline: 2rem 2rem; padding-left: 3.4rem; }
  .ev-card--feature .ev-card__foot::before { display: none; }
}

/* ---------- Empty state ---------- */
.ev-empty {
  display: grid; justify-items: center; gap: .5rem; padding: 3.5rem 1.25rem; text-align: center;
  border: 2px dashed rgba(10, 35, 66, .2); border-radius: 20px; background: rgba(255, 255, 255, .6);
}
.ev-empty__icon { display: grid; place-items: center; width: 4rem; height: 4rem; margin-bottom: .4rem; border-radius: 50%; background: var(--ev-gold-soft, #f3e9d6); color: var(--ev-gold-deep); font-size: 1.5rem; }
.ev-empty h3 { margin: 0; color: var(--ev-ink); font-size: clamp(1.4rem, 1.2rem + .8vw, 1.9rem); }
.ev-empty p { max-width: 32rem; margin: 0; color: var(--ev-muted); }
.ev-empty__actions { display: flex; flex-wrap: wrap; justify-content: center; gap: .6rem; margin-top: 1rem; }

/* ---------- Pagination ---------- */
.ev-pagination { margin: 2.5rem 0 0; }
.ev-pagination ul { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: .4rem; margin: 0; padding: 0; list-style: none; }
.ev-pagination__num, .ev-pagination__step {
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem; min-width: 44px; min-height: 44px; padding: .4rem .9rem;
  border: 1.5px solid var(--ev-line); border-radius: 999px; background: #fff; color: var(--ev-ink); font-weight: 700; text-decoration: none;
  font-variant-numeric: tabular-nums; transition: background-color .2s, color .2s, border-color .2s;
}
a.ev-pagination__num:hover, a.ev-pagination__step:hover { border-color: var(--ev-ink); }
.ev-pagination__num.is-current { background: var(--ev-ink); border-color: var(--ev-ink); color: #fff; }
.ev-pagination__step.is-disabled { color: #6b7280; background: transparent; border-style: dashed; }
.ev-pagination__gap { padding-inline: .2rem; color: var(--ev-muted); }

/* ---------- Small screens ---------- */
@media (max-width: 640px) {
  .ev-hero { padding: 2.4rem 0 4.2rem; }
  .ev-toolbar { margin-inline: -4px; padding: .9rem; border-radius: 18px; }
  .ev-search__field { flex-basis: 100%; }
  .ev-search .ev-btn { flex: 1 1 auto; }
  .ev-chip { min-height: 44px; padding-inline: 1rem; }
  .ev-tabbar { margin-bottom: 1.4rem; }
  .ev-tabs { width: 100%; }
  .ev-tab { flex: 1; justify-content: center; padding-inline: .5rem; }
  .ev-card__actions .ev-btn { flex: 1 1 100%; }
  .ev-card__actions .ev-btn--heart { flex-basis: 100%; }
  .ev-pagination__step span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  .ev-pagination__step { padding-inline: .6rem; }
}
@media (prefers-reduced-motion: reduce) {
  .ev-card:hover { transform: none; }
}

/* ---------- Mode chip, and the cancelled card (stamp on the poster: events-shared.css) ---------- */
.ev-card__mode { display: inline-flex; align-items: center; gap: .35rem; color: var(--ev-ink); font: 700 .74rem/1 var(--body-font, Lato, sans-serif); letter-spacing: .06em; }
.ev-card__mode i { color: var(--ev-gold-deep); font-size: .72rem; }
.ev-card--cancelled .ev-card__media img { filter: grayscale(.75) brightness(.72); }
.ev-card--cancelled .ev-plate { opacity: .88; }
.ev-card--cancelled .ev-card__title a { color: #4b5563; text-decoration: line-through; text-decoration-color: rgba(185, 28, 28, .55); text-decoration-thickness: 2px; }
.ev-card__sorry { display: flex; align-items: flex-start; gap: .55rem; margin: .2rem 0 .6rem; padding: .65rem .8rem; border-radius: 12px; background: #fef2f2; border: 1px solid #fecaca; color: #7f1d1d; font-size: .9rem; line-height: 1.45; }
.ev-card__sorry i { margin-top: .15rem; }
.ev-card--feature.ev-card--cancelled .ev-stamp__word { font-size: 2.1rem; }

