:root {
  color-scheme: dark;
  --bg: #07080d;
  --bg-2: #101118;
  --card: #14151c;
  --line: #2c2e38;
  --text: #f4f5f8;
  --muted: #a4a8b8;
  --pink: #ff2f86;
  --lime: #d6f25c;
  --lime-ink: #141806;
  --cyan: #5ce1ff;
  --gold: #e6b325;
  --gold-ink: #1c1404;
  --plum: #12080e;
  --cardinal: #9d2235;
  --shadow: 0 18px 40px rgba(0, 0, 0, 0.28);
  --max: 1120px;
  --sans: "Avenir Next", "Segoe UI", system-ui, sans-serif;
  --display: "Avenir Next Condensed", "Arial Narrow", "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 15px;
  line-height: 1.3;
}
body.theme-theatre { background: radial-gradient(1200px 500px at 80% -10%, rgba(230, 179, 37, 0.16), transparent 50%), var(--plum); }
body.theme-legends { background: #e4e4e8; color: #161616; color-scheme: light; }
img { max-width: 100%; display: block; }
a { color: inherit; }
button, input, select { font: inherit; color: inherit; }
.sr, .skip {
  position: absolute;
  width: 1px; height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
}
.skip:focus { position: fixed; left: 12px; top: 12px; width: auto; height: auto; clip: auto; background: var(--lime); color: var(--lime-ink); padding: 8px 12px; z-index: 9; }

.top {
  position: sticky;
  top: 0;
  z-index: 5;
  background: rgba(7, 8, 13, 0.92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid #24262f;
  color: #f4f5f8;
}
.top-row {
  max-width: var(--max);
  margin: 0 auto;
  padding: 12px 16px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 18px;
}
.logo {
  font-family: var(--display);
  font-weight: 800;
  font-size: 1.55rem;
  letter-spacing: -0.04em;
  text-decoration: none;
}
.dot {
  display: inline-block;
  width: 8px; height: 8px;
  margin-left: 4px;
  border-radius: 50%;
  background: var(--pink);
  box-shadow: 0 0 10px var(--pink);
  vertical-align: super;
}
.wave { width: 92px; height: 22px; }
.nav {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 12px;
}
.nav a { text-decoration: none; color: #d5d7e0; font-weight: 650; font-size: 0.92rem; }
.nav a[aria-current="page"] { color: white; }
.search { flex: 1 1 180px; min-width: 0; }
.search input, .filters select, .submit-show input {
  width: 100%;
  background: #0c0d12;
  border: 1px solid #343744;
  border-radius: 999px;
  padding: 10px 14px;
}
.region { margin: 0; color: #c5c8d4; font-size: 0.92rem; white-space: nowrap; }
.wrap { max-width: var(--max); margin: 0 auto; padding: 10px 12px 28px; }
.lede { color: var(--muted); max-width: 62ch; font-size: 0.95rem; margin: 0.2rem 0 0.4rem; }
.theme-legends .lede, .theme-legends .crumb, .theme-legends .where { color: #4d4f57; }
.eyebrow, .kicker, .crumb { color: var(--gold); letter-spacing: 0.04em; text-transform: uppercase; font-size: 0.78rem; font-weight: 700; }
.theme-night .kicker { color: var(--pink); }
h1, h2, h3 { font-family: var(--display); letter-spacing: -0.03em; line-height: 1.05; margin: 0.15rem 0; }
h1 { font-size: clamp(1.7rem, 4.5vw, 2.6rem); }
h2 { font-size: 1.2rem; }
.theatre h1, .legends h1 { color: var(--gold); }
.theme-legends h1, .theme-legends h2 { color: #161616; }
.theme-legends .profile-grid h2,
.theme-legends .profile-hero h1,
.theme-legends .featured h2,
.theme-legends .legend-card h3,
.theme-legends .catch,
.theme-legends .signature h2 { color: #fff; }
.theme-legends .profile-hero .lede,
.theme-legends .profile-hero .jerseys { color: #f6d5dc; }
.pills, .tabs {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  overflow: visible;
  margin: 14px 0;
}
.pills a, .tabs a, .btn {
  text-decoration: none;
  border-radius: 999px;
  padding: 8px 12px;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  border: 1px solid #4a4d5c;
  font-weight: 700;
  font-size: 0.84rem;
  line-height: 1.2;
}
.pills a[aria-current="page"] { background: var(--pink); border-color: var(--pink); color: white; }
.tabs a[aria-current="page"] { border-bottom: 3px solid var(--lime); border-radius: 0; }
.pills.gold a[aria-current="page"], .theatre .pills a:first-child { background: var(--gold); color: var(--gold-ink); border-color: var(--gold); }
.pills.cardinal a[aria-current="page"] { background: var(--cardinal); color: white; border-color: var(--cardinal); }
.theme-legends .pills a { color: #161616; border-color: #b9b9c2; background: white; }
.btn-lime { background: var(--lime); color: var(--lime-ink); border-color: var(--lime); display: inline-block; }
.btn-gold { background: var(--gold); color: var(--gold-ink); border-color: var(--gold); display: inline-block; }
.btn-cardinal { background: var(--cardinal); color: white; border-color: var(--cardinal); display: inline-block; }
.filters { display: flex; flex-wrap: wrap; gap: 12px; margin: 8px 0 18px; }
.filters label { display: grid; gap: 4px; font-size: 0.8rem; color: var(--muted); min-width: min(100%, 220px); flex: 1; }
.filters select { border-radius: 12px; }

.hero {
  display: grid;
  gap: 0;
  background: #12131a;
  border: 1px solid var(--line);
  border-radius: 14px;
  overflow: hidden;
  box-shadow: var(--shadow);
  margin-bottom: 10px;
}
.hero-copy { padding: 12px 14px; }
.hero-glow {
  min-height: 64px;
  display: grid;
  place-items: end start;
  padding: 16px;
  background:
    radial-gradient(circle at 80% 20%, rgba(255, 47, 134, 0.55), transparent 42%),
    radial-gradient(circle at 20% 80%, rgba(92, 225, 255, 0.35), transparent 40%),
    linear-gradient(120deg, #1a1030, #101820 60%, #142018);
}
.hero-glow span { font-family: var(--display); font-size: 1.4rem; letter-spacing: 0.08em; text-transform: uppercase; }
.cat-sports .hero-glow { background: radial-gradient(circle at 70% 30%, rgba(157, 34, 53, 0.7), transparent 46%), #1a1014; }
.cat-theatre .hero-glow { background: radial-gradient(circle at 70% 30%, rgba(230, 179, 37, 0.45), transparent 42%), #1a1016; }
.cat-family .hero-glow { background: radial-gradient(circle at 70% 30%, rgba(92, 225, 255, 0.4), transparent 42%), #101820; }
.section-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.section-head p, .where, .fine, .more { color: var(--muted); }
.cards { display: grid; gap: 8px; }
.card {
  display: flex;
  flex-direction: column;
  text-decoration: none;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 12px;
  overflow: hidden;
  min-height: 44px;
}
.card-banner { height: 26px; display: flex; align-items: flex-end; padding: 4px 10px; background: linear-gradient(100deg, #241433, #123044); }
.cat-sports .card-banner { background: linear-gradient(100deg, #3a1020, #1a1a1a); }
.cat-theatre .card-banner, .card-run .card-banner { background: linear-gradient(100deg, #3a2410, #241428); }
.cat-family .card-banner { background: linear-gradient(100deg, #10343a, #1a2040); }
.cat-community .card-banner { background: linear-gradient(100deg, #242838, #1a1c24); }
.card-banner span { font-size: 0.78rem; letter-spacing: 0.08em; text-transform: uppercase; font-weight: 800; }
.card-body { padding: 8px 10px 10px; display: flex; flex-direction: column; gap: 2px; flex: 1; }
.card .btn { margin-top: auto; align-self: flex-start; }
.card h3 { font-size: 1.02rem; }
.card p, .where { margin: 0; }
.card .btn { justify-self: start; margin-top: 8px; }
.theme-theatre .card { background: #1a1016; border-color: #3a2a22; }
.empty, .empty-inline { color: var(--muted); }

.split { display: grid; gap: 22px; margin-top: 10px; }
.plain { list-style: none; padding: 0; margin: 0; display: grid; gap: 14px; }
.plain a { font-size: 1.15rem; }
.table-wrap { overflow-x: auto; }
.auditions { width: 100%; border-collapse: collapse; }
.auditions th, .auditions td { text-align: left; padding: 10px 8px; border-bottom: 1px solid #3a2c22; vertical-align: top; }
.auditions span { display: block; color: var(--muted); font-size: 0.88rem; }
.submit-show, .context, .catch, .profile-hero, .profile-grid section, .legend-card, .featured {
  border: 1px solid #3a2c22;
  border-radius: 18px;
  padding: 16px;
  margin-top: 18px;
}
.theme-theatre .submit-show { background: #1a1016; }
.form-grid { display: grid; gap: 10px; }
.submit-show input { border-radius: 10px; background: #10080c; }
.site-foot {
  max-width: var(--max);
  margin: 0 auto;
  padding: 8px 16px 32px;
  color: var(--muted);
  font-size: 0.92rem;
}
.theme-legends .site-foot { color: #3e4048; }
.prose { max-width: 760px; }
.prose li, .status-list li { margin: 0.45em 0; }
.status-list { padding-left: 1.1em; }

.theme-legends .featured, .theme-legends .legend-card, .theme-legends .profile-hero, .theme-legends .profile-grid section {
  background: #17171a;
  color: #f4f5f8;
  border-color: #2a2a30;
}
.theme-legends .featured h2, .theme-legends .legend-card h3, .theme-legends .profile-hero h1 { color: white; }
.featured { display: grid; gap: 12px; background:
  radial-gradient(circle at 85% 40%, rgba(157, 34, 53, 0.65), transparent 36%),
  linear-gradient(100deg, #141414, #2a1218);
  text-decoration: none;
}
.legend-grid { display: grid; gap: 8px; }
.legend-card { display: grid; grid-template-columns: 64px 1fr; gap: 8px; align-items: center; text-decoration: none; margin-top: 0; padding: 8px; min-height: 44px; }
.thumb, .initials.thumb { width: 64px; height: 64px; object-fit: cover; border-radius: 10px; }
.initials { display: grid; place-items: center; background: #2a1218; color: white; font-family: var(--display); font-size: 1.4rem; }
.badges { display: flex; flex-wrap: wrap; gap: 6px; }
.badges span { border: 1px solid rgba(255,255,255,0.25); border-radius: 999px; padding: 2px 8px; font-size: 0.72rem; letter-spacing: 0.04em; }
.theme-legends .legend-card .badges span { color: #f4d6dc; border-color: #9d2235; }
.catch { display: flex; justify-content: space-between; gap: 12px; align-items: center; background: #17171a; color: white; }
.profile-hero { display: grid; gap: 16px; }
.profile-hero figure { margin: 0; }
.profile-photo, .initials.profile-photo { width: 220px; height: 260px; border-radius: 16px; object-fit: cover; }
.featured-photo, .initials.featured-photo { width: 180px; height: 220px; object-fit: cover; border-radius: 14px; justify-self: end; }
.stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin: 12px 0 0; }
.stats div { background: #241016; border-radius: 12px; padding: 8px; }
.stats dt { font-family: var(--display); font-size: 1.8rem; color: #ff5a78; }
.stats dd { margin: 0; color: #ddd; }
.facts div, .profile-grid li { margin: 0.35em 0; }
.facts { display: grid; gap: 6px; }
.facts dt { color: #aaa; font-size: 0.8rem; }
.facts dd { margin: 0; }
.signature { background: #3a1020 !important; }
.jerseys { color: #ffd0d8; }
.venue-list { list-style: none; padding: 0; display: grid; gap: 0; }
.venue-list li { display: flex; justify-content: space-between; gap: 12px; border-bottom: 1px solid var(--line); padding: 8px 0; min-height: 44px; align-items: center; }
.day { margin-top: 10px; }
.venue-block { margin: 0 0 8px; }
.venue-block h3 { font-size: 1rem; }
.venue-block h3 span { color: var(--muted); font-weight: 500; font-size: 0.85rem; }
.productions { list-style: none; margin: 0; padding: 0; }
.productions li {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 2px 12px;
  min-height: 44px;
  padding: 6px 0;
  border-bottom: 1px solid rgba(230, 179, 37, 0.28);
}
.prod-title { font-weight: 700; }
.prod-dates { color: var(--muted); text-align: right; }
.productions .btn { min-height: 44px; display: inline-flex; align-items: center; justify-content: center; }
code { font-size: 0.92em; }

@media (max-width: 720px) {
  .auditions thead { display: none; }
  .auditions tr { display: grid; padding: 8px 0; }
  .region { display: none; }
  .top-row { padding: 8px 12px; }
  .catch { flex-direction: column; align-items: flex-start; }
  .productions li { grid-template-columns: minmax(0, 1fr) auto; }
  .prod-title { grid-column: 1; grid-row: 1; }
  .prod-dates { grid-column: 1; grid-row: 2; text-align: left; }
  .productions .btn { grid-column: 2; grid-row: 1 / span 2; }
}
@media (min-width: 760px) {
  .cards { grid-template-columns: repeat(2, 1fr); }
  .hero { grid-template-columns: 1.3fr 0.7fr; align-items: stretch; }
  .hero-glow { min-height: 100%; }
  .form-grid, .split, .profile-hero { grid-template-columns: 1fr 1fr; }
  .legend-grid { grid-template-columns: repeat(2, 1fr); }
  .featured { grid-template-columns: 1fr auto; align-items: center; }
}
@media (min-width: 980px) {
  .cards { grid-template-columns: repeat(3, 1fr); }
  .legend-grid { grid-template-columns: repeat(3, 1fr); }
  .profile-grid { display: grid; grid-template-columns: 1.2fr 0.8fr; gap: 12px; }
  .profile-grid .signature, .profile-grid section:last-child { grid-column: 1 / -1; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .wave { display: none; }
}
.filtering #event-grid, .filtering #hero-slot { visibility: hidden; }
