/* ETHSG public site — redesign */
@import url('/css/fonts.css');

:root {
  --bg: #0e1011;
  --bg-raised: #16191b;
  --bg-sunken: #0a0b0c;
  --line: #262b2e;
  --line-strong: #353b3f;
  --text: #eef0ef;
  --text-muted: #9aa3a6;
  --text-faint: #8a9396;
  --brand: #55a5ad;
  --brand-strong: #6fc0c8;
  --brand-ink: #0b2a2d;
  --brand-soft: rgba(85, 165, 173, 0.12);
  --danger: #e5746b;
  --warn: #e7b85c;
  --ok: #6cc7a1;

  --font-body: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --font-display: 'Space Grotesk', 'Inter', system-ui, sans-serif;

  --radius: 14px;
  --radius-sm: 8px;
  --shadow: 0 1px 0 rgba(255, 255, 255, 0.03) inset, 0 20px 40px -24px rgba(0, 0, 0, 0.6);
  --maxw: 1160px;
  --gutter: clamp(16px, 4vw, 32px);
}

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

html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: var(--brand-strong);
  text-decoration: none;
}

a:hover {
  color: var(--text);
}

h1,
h2,
h3,
h4 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.1;
  letter-spacing: -0.02em;
  margin: 0 0 0.5em;
  color: var(--text);
}

h1 {
  font-size: clamp(2.4rem, 6vw, 4.5rem);
}

h2 {
  font-size: clamp(1.75rem, 3.5vw, 2.5rem);
}

h3 {
  font-size: 1.25rem;
}

p {
  margin: 0 0 1em;
}

:focus-visible {
  outline: 2px solid var(--brand-strong);
  outline-offset: 2px;
}

.container {
  width: 100%;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.container-narrow {
  max-width: 720px;
}

.section {
  padding: clamp(56px, 9vw, 112px) 0;
}

.section-tight {
  padding: clamp(32px, 5vw, 56px) 0;
}

.eyebrow {
  display: inline-block;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--brand);
  margin-bottom: 1rem;
}

.lead {
  font-size: clamp(1.05rem, 1.6vw, 1.25rem);
  color: var(--text-muted);
  max-width: 60ch;
}

.muted {
  color: var(--text-muted);
}

.section-head {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 1rem;
  flex-wrap: wrap;
  margin-bottom: 2rem;
}

.section-head h2 {
  margin: 0;
}

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(14, 16, 17, 0.8);
  backdrop-filter: saturate(140%) blur(12px);
  -webkit-backdrop-filter: saturate(140%) blur(12px);
  border-bottom: 1px solid var(--line);
}

.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 68px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.15rem;
  color: var(--text);
}

.brand img {
  height: 34px;
  width: auto;
}

.nav {
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.nav a {
  color: var(--text-muted);
  font-weight: 500;
  font-size: 0.95rem;
  padding: 0.5rem 0.85rem;
  border-radius: 999px;
  transition: color 0.15s, background 0.15s;
}

.nav a:hover,
.nav a[aria-current="page"] {
  color: var(--text);
  background: rgba(255, 255, 255, 0.05);
}

.nav a.nav-cta {
  color: var(--brand-ink);
  font-weight: 600;
  background: var(--brand);
  margin-left: 0.5rem;
}

.nav a.nav-cta:hover {
  background: var(--brand-strong);
}

.nav-toggle {
  display: none;
  background: none;
  border: 1px solid var(--line-strong);
  color: var(--text);
  border-radius: var(--radius-sm);
  width: 42px;
  height: 42px;
  font-size: 1.2rem;
  cursor: pointer;
}

@media (max-width: 760px) {
  .nav-toggle {
    display: block;
  }

  .nav {
    display: none;
    position: absolute;
    top: 68px;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 0.5rem var(--gutter) 1rem;
    background: var(--bg);
    border-bottom: 1px solid var(--line);
  }

  .nav.open {
    display: flex;
  }

  .nav a {
    padding: 0.85rem 0.5rem;
    border-radius: 0;
    border-bottom: 1px solid var(--line);
  }

  .nav a.nav-cta {
    margin: 0.75rem 0 0;
    text-align: center;
    border-radius: 999px;
    border: none;
  }
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font: inherit;
  font-weight: 600;
  font-size: 0.95rem;
  padding: 0.8rem 1.4rem;
  border-radius: 999px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, color 0.15s, transform 0.15s;
  white-space: nowrap;
}

.btn:active {
  transform: translateY(1px);
}

.btn:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.btn-primary {
  background: var(--brand);
  color: var(--brand-ink);
}

.btn-primary:hover {
  background: var(--brand-strong);
  color: var(--brand-ink);
}

.btn-ghost {
  background: transparent;
  color: var(--text);
  border-color: var(--line-strong);
}

.btn-ghost:hover {
  border-color: var(--text-muted);
  color: var(--text);
}

.btn-lg {
  padding: 1rem 1.75rem;
  font-size: 1rem;
}

.btn-block {
  width: 100%;
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  overflow: hidden;
  padding: clamp(72px, 12vw, 160px) 0 clamp(56px, 8vw, 104px);
  border-bottom: 1px solid var(--line);
}

.hero::before {
  content: '';
  position: absolute;
  inset: -40% -10% auto auto;
  width: 70vw;
  height: 70vw;
  max-width: 900px;
  max-height: 900px;
  background: radial-gradient(circle, rgba(85, 165, 173, 0.22), transparent 60%);
  pointer-events: none;
}

.hero .container {
  position: relative;
}

.hero h1 {
  max-width: 14ch;
}

.hero h1 em {
  font-style: normal;
  color: var(--brand);
}

.hero-actions {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin-top: 2rem;
}

.page-hero {
  padding: clamp(48px, 8vw, 96px) 0 clamp(32px, 5vw, 56px);
  border-bottom: 1px solid var(--line);
}

.page-hero h1 {
  font-size: clamp(2.2rem, 5vw, 3.5rem);
}

/* ---------- Stats ---------- */
.stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}

.stat {
  padding: 1.5rem;
  border-right: 1px solid var(--line);
}

.stat:last-child {
  border-right: none;
}

.stat-num {
  display: block;
  font-family: var(--font-display);
  font-size: 2.25rem;
  font-weight: 600;
  color: var(--text);
}

.stat-label {
  font-size: 0.85rem;
  color: var(--text-muted);
}

@media (max-width: 700px) {
  .stats {
    grid-template-columns: repeat(2, 1fr);
  }

  .stat:nth-child(2) {
    border-right: none;
  }

  .stat:nth-child(-n + 2) {
    border-bottom: 1px solid var(--line);
  }
}

/* ---------- Grids & cards ---------- */
.grid {
  display: grid;
  gap: 1.25rem;
}

.grid-2 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.grid-3 {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.grid-4 {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

@media (max-width: 960px) {
  .grid-3,
  .grid-4 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 620px) {
  .grid-2,
  .grid-3,
  .grid-4 {
    grid-template-columns: 1fr;
  }
}

.panel {
  background: var(--bg-raised);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: clamp(1.25rem, 3vw, 2rem);
}

.pillar h3 {
  margin-top: 1rem;
}

.pillar p {
  color: var(--text-muted);
  margin: 0;
}

.pillar-num {
  font-family: var(--font-display);
  color: var(--brand);
  font-size: 0.9rem;
  font-weight: 600;
}

/* ---------- Event cards ---------- */
.event-card {
  display: flex;
  flex-direction: column;
  background: var(--bg-raised);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  color: var(--text);
  transition: border-color 0.2s, transform 0.2s;
}

.event-card:hover {
  border-color: var(--line-strong);
  transform: translateY(-3px);
  color: var(--text);
}

.event-cover {
  position: relative;
  aspect-ratio: 16 / 9;
  background: linear-gradient(135deg, #1b3b3e 0%, #0f1f21 55%, #16191b 100%);
  overflow: hidden;
}

.event-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.event-cover-fallback {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: flex-end;
  padding: 1.25rem;
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.25);
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.date-chip {
  position: absolute;
  top: 0.9rem;
  left: 0.9rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 54px;
  padding: 0.4rem 0.5rem;
  border-radius: 10px;
  background: rgba(14, 16, 17, 0.85);
  backdrop-filter: blur(6px);
  line-height: 1.1;
}

.date-chip .m {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  color: var(--brand);
  text-transform: uppercase;
}

.date-chip .d {
  font-family: var(--font-display);
  font-size: 1.4rem;
  font-weight: 600;
  color: var(--text);
}

.event-card-body {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  padding: 1.25rem;
  flex: 1;
}

.event-card-body h3 {
  margin: 0;
}

.event-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 1rem;
  color: var(--text-muted);
  font-size: 0.9rem;
}

.event-card-foot {
  margin-top: auto;
  padding-top: 0.75rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.85rem;
  color: var(--text-muted);
}

.event-card.is-past {
  opacity: 0.7;
}

.tag {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.75rem;
  font-weight: 600;
  padding: 0.25rem 0.65rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  color: var(--text-muted);
  border: 1px solid var(--line);
}

.tag-brand {
  background: var(--brand-soft);
  color: var(--brand-strong);
  border-color: transparent;
}

.tag-warn {
  background: rgba(231, 184, 92, 0.12);
  color: var(--warn);
  border-color: transparent;
}

.tag-danger {
  background: rgba(229, 116, 107, 0.12);
  color: var(--danger);
  border-color: transparent;
}

.tags {
  display: flex;
  gap: 0.4rem;
  flex-wrap: wrap;
}

/* ---------- Filters ---------- */
.filters {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin-bottom: 2rem;
}

.chip {
  font: inherit;
  font-size: 0.9rem;
  font-weight: 500;
  padding: 0.5rem 1rem;
  border-radius: 999px;
  border: 1px solid var(--line-strong);
  background: transparent;
  color: var(--text-muted);
  cursor: pointer;
  transition: all 0.15s;
}

.chip:hover {
  color: var(--text);
  border-color: var(--text-faint);
}

.chip[aria-pressed="true"] {
  background: var(--text);
  color: var(--bg);
  border-color: var(--text);
}

/* ---------- Event detail ---------- */
.event-detail {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 380px;
  gap: clamp(1.5rem, 4vw, 3rem);
  align-items: start;
}

@media (max-width: 900px) {
  .event-detail {
    grid-template-columns: 1fr;
  }
}

.event-hero-cover {
  aspect-ratio: 16 / 9;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--line);
  background: linear-gradient(135deg, #1b3b3e 0%, #0f1f21 55%, #16191b 100%);
  margin-bottom: 2rem;
}

.event-hero-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Square posters are shown whole instead of cropped to the wide frame */
.event-hero-cover img.poster {
  object-fit: contain;
}

.event-description {
  white-space: pre-line;
  color: var(--text-muted);
  font-size: 1.05rem;
}

.fact-list {
  list-style: none;
  padding: 0;
  margin: 0 0 1.5rem;
  display: grid;
  gap: 0.9rem;
}

.fact-list li {
  display: grid;
  grid-template-columns: 24px 1fr;
  gap: 0.75rem;
}

.fact-list .k {
  display: block;
  font-size: 0.78rem;
  color: var(--text-faint);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.sticky {
  position: sticky;
  top: 88px;
}

.progress {
  height: 6px;
  border-radius: 999px;
  background: var(--line);
  overflow: hidden;
  margin: 0.5rem 0 1.5rem;
}

.progress > span {
  display: block;
  height: 100%;
  background: var(--brand);
}

/* ---------- Forms ---------- */
.field {
  margin-bottom: 1rem;
}

.field label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 0.4rem;
  color: var(--text);
}

.field small {
  display: block;
  color: var(--text-faint);
  font-size: 0.8rem;
  margin-top: 0.35rem;
}

.input,
.field input,
.field select,
.field textarea {
  width: 100%;
  font: inherit;
  color: var(--text);
  background: var(--bg-sunken);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  padding: 0.75rem 0.9rem;
  transition: border-color 0.15s, box-shadow 0.15s;
}

.input:focus,
.field input:focus,
.field select:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--brand);
  box-shadow: 0 0 0 3px var(--brand-soft);
}

.field-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

@media (max-width: 520px) {
  .field-row {
    grid-template-columns: 1fr;
  }
}

.alert {
  padding: 0.85rem 1rem;
  border-radius: var(--radius-sm);
  font-size: 0.92rem;
  margin-bottom: 1rem;
}

.alert-error {
  background: rgba(229, 116, 107, 0.1);
  color: var(--danger);
  border: 1px solid rgba(229, 116, 107, 0.3);
}

.alert-success {
  background: rgba(108, 199, 161, 0.1);
  color: var(--ok);
  border: 1px solid rgba(108, 199, 161, 0.3);
}

.inline-form {
  display: flex;
  gap: 0.5rem;
  max-width: 480px;
}

.inline-form .input {
  border-radius: 999px;
  padding-left: 1.2rem;
}

@media (max-width: 520px) {
  .inline-form {
    flex-direction: column;
  }
}

/* ---------- Partners ---------- */
.logo-row {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.logo-row .logo-tile {
  background: #f3f4f3;
  border-radius: var(--radius-sm);
  height: 88px;
  width: 180px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem 1.5rem;
}

.logo-row .logo-tile.dark {
  background: var(--bg-raised);
  border: 1px solid var(--line);
}

.logo-row img {
  max-height: 52px;
  max-width: 100%;
  width: auto;
}

.logo-group + .logo-group {
  margin-top: 2.5rem;
}

.logo-group-label {
  display: block;
  margin-bottom: 1rem;
  font-size: 0.8rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-faint);
}


/* ---------- CTA band ---------- */
.cta-band {
  border: 1px solid var(--line);
  border-radius: calc(var(--radius) + 6px);
  padding: clamp(2rem, 5vw, 3.5rem);
  background: radial-gradient(ellipse at top right, rgba(85, 165, 173, 0.18), transparent 60%), var(--bg-raised);
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 2rem;
  align-items: center;
}

@media (max-width: 820px) {
  .cta-band {
    grid-template-columns: 1fr;
  }
}

/* ---------- Board ---------- */
.person {
  background: var(--bg-raised);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}

.person-photo {
  aspect-ratio: 4 / 5;
  background: var(--bg-sunken);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-size: 2.5rem;
  color: var(--text-faint);
}

.person-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: grayscale(0.2);
  transition: filter 0.3s;
}

.person:hover .person-photo img {
  filter: none;
}

.person-body {
  padding: 1rem 1.1rem 1.2rem;
}

.person-body h3 {
  font-size: 1.05rem;
  margin: 0 0 0.2rem;
}

.person-role {
  color: var(--brand-strong);
  font-size: 0.88rem;
  font-weight: 500;
  margin: 0 0 0.6rem;
}

.person-body p.bio {
  font-size: 0.88rem;
  color: var(--text-muted);
  margin: 0 0 0.75rem;
}

/* ---------- Gallery ---------- */
.gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 1rem;
}

.gallery button,
.gallery a {
  display: block;
  width: 100%;
  padding: 0;
  margin: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  overflow: hidden;
  background: var(--bg-raised);
  cursor: zoom-in;
}

.gallery img {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  transition: transform 0.4s;
}

.gallery button:hover img,
.gallery a:hover img {
  transform: scale(1.03);
}

.lightbox {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 100;
  background: rgba(0, 0, 0, 0.92);
  align-items: center;
  justify-content: center;
  padding: var(--gutter);
}

.lightbox.open {
  display: flex;
}

.lightbox img {
  max-width: 100%;
  max-height: 88vh;
  border-radius: var(--radius-sm);
}

.lightbox-close {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 1px solid var(--line-strong);
  background: rgba(0, 0, 0, 0.5);
  color: var(--text);
  font-size: 1.5rem;
  cursor: pointer;
}

/* ---------- Footer ---------- */
.site-footer {
  border-top: 1px solid var(--line);
  padding: 3rem 0 2.5rem;
  color: var(--text-muted);
  font-size: 0.9rem;
}

.site-footer .container {
  display: flex;
  justify-content: space-between;
  gap: 2rem;
  flex-wrap: wrap;
}

.footer-links {
  display: flex;
  gap: 1.25rem;
  flex-wrap: wrap;
}

.footer-links a {
  color: var(--text-muted);
}

.footer-links a:hover {
  color: var(--text);
}

/* ---------- Misc ---------- */
.empty {
  border: 1px dashed var(--line-strong);
  border-radius: var(--radius);
  padding: 3rem 1.5rem;
  text-align: center;
  color: var(--text-muted);
  grid-column: 1 / -1;
}

.skeleton {
  border-radius: var(--radius);
  background: linear-gradient(90deg, var(--bg-raised) 25%, #1d2123 50%, var(--bg-raised) 75%);
  background-size: 200% 100%;
  animation: shimmer 1.4s infinite;
  min-height: 320px;
}

@keyframes shimmer {
  to {
    background-position: -200% 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }
}

.toast {
  position: fixed;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 200;
  padding: 0.8rem 1.2rem;
  border-radius: 999px;
  background: var(--text);
  color: var(--bg);
  font-weight: 500;
  font-size: 0.92rem;
  box-shadow: var(--shadow);
  transition: opacity 0.3s;
}

.toast-error {
  background: var(--danger);
  color: #1a0806;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

/* ---------- Event archive ---------- */
.archive-year + .archive-year {
  margin-top: 2.5rem;
}

.archive-year h3 {
  margin: 2rem 0 1rem;
  font-family: var(--font-display);
  color: var(--text-muted);
}

.archive-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
  gap: 1rem;
}

.archive-tile {
  margin: 0;
}

.archive-tile img {
  width: 100%;
  height: auto;
  aspect-ratio: 1;
  object-fit: cover;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--bg-raised);
}

.archive-tile figcaption {
  margin-top: 0.5rem;
  font-size: 0.85rem;
  line-height: 1.35;
  color: var(--text-muted);
}

/* ---------- Checkbox row (e.g. no-show policy) ---------- */
.check-row {
  display: flex;
  gap: 0.6rem;
  align-items: flex-start;
  margin: 0.25rem 0 1rem;
  font-size: 0.9rem;
  color: var(--text-muted);
  cursor: pointer;
}

.check-row input {
  width: 1.1rem;
  height: 1.1rem;
  margin-top: 0.15rem;
  flex-shrink: 0;
  accent-color: var(--brand);
}

.archive-date {
  display: block;
  margin-top: 0.15rem;
  font-size: 0.8rem;
  color: var(--text-faint);
}

/* Keyboard users can jump past the header */
.skip-link {
  position: absolute;
  left: 1rem;
  top: -3rem;
  z-index: 200;
  padding: 0.6rem 1rem;
  border-radius: var(--radius-sm);
  background: var(--brand);
  color: var(--brand-ink);
  font-weight: 600;
}

.skip-link:focus {
  top: 1rem;
}

/* Selects and text inputs line up in the same row */
.field select {
  min-height: calc(1.5em + 1.5rem + 2px);
}

/* ---------- Hero with event mosaic ---------- */
.hero-grid {
  display: grid;
  grid-template-columns: 1.15fr 1fr;
  gap: clamp(2rem, 5vw, 4rem);
  align-items: center;
}

.hero-mosaic {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
  transform: rotate(-2deg);
}

.hero-mosaic img {
  width: 100%;
  height: auto;
  aspect-ratio: 1;
  object-fit: cover;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
}

.hero-mosaic img:nth-child(2),
.hero-mosaic img:nth-child(4) {
  transform: translateY(1.5rem);
}

@media (max-width: 860px) {
  .hero-grid {
    grid-template-columns: 1fr;
  }

  .hero-mosaic {
    grid-template-columns: 1fr 1fr;
    transform: none;
  }

  .hero-mosaic img:nth-child(2),
  .hero-mosaic img:nth-child(4) {
    transform: none;
  }
}

a.archive-tile {
  display: block;
  color: inherit;
  text-decoration: none;
}

a.archive-tile:hover img,
a.archive-tile:focus-visible img {
  border-color: var(--brand);
}

.archive-caption {
  display: block;
  margin-top: 0.5rem;
  font-size: 0.85rem;
  line-height: 1.35;
  color: var(--text);
}

.archive-fallback {
  display: grid;
  place-items: center;
  aspect-ratio: 1;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: linear-gradient(135deg, var(--brand-soft), var(--bg-raised));
  color: var(--text-muted);
  font-size: 0.8rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

/* The hidden attribute always wins over component display rules */
[hidden] {
  display: none !important;
}

/* Square posters get a square frame instead of side bands */
.event-hero-cover:has(img.poster) {
  aspect-ratio: 1;
  max-width: 520px;
}

/* Home page: eight recent events in a tidy 4 × 2 grid */
.recent-grid {
  grid-template-columns: repeat(4, 1fr);
}

@media (max-width: 600px) {
  .recent-grid {
    grid-template-columns: 1fr 1fr;
  }
}

/* "Next up" card under the panel on past event pages */
.next-up {
  margin-top: 1.5rem;
}

.next-up .eyebrow {
  display: block;
  margin-bottom: 0.75rem;
}
