:root {
  --bg: #0d0b14;
  --panel: #17131f;
  --panel-2: #1e1930;
  --ink: #f4f1fa;
  --muted: #b3aac6;
  --accent: #ffd43b;
  --accent-ink: #1a1400;
  --live: #ff4b5c;
  --border: #2a2338;
  --radius: 14px;
}
* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  background: radial-gradient(1200px 600px at 50% -10%, #241b3a 0%, var(--bg) 55%);
  color: var(--ink);
  font: 16px/1.6 system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, sans-serif;
  min-height: 100vh;
}
a { color: inherit; }
.wrap { max-width: 1040px; margin: 0 auto; padding: 1.5rem 1.25rem 3rem; }
.wrap-guide { max-width: 1280px; }

/* Top bar */
.topbar {
  display: flex; align-items: center; justify-content: space-between;
  gap: 1rem; padding-bottom: 1.25rem; margin-bottom: 1rem;
  border-bottom: 1px solid var(--border);
}
.logo {
  display: inline-flex; align-items: center; gap: 0.4em;
  text-decoration: none; line-height: 1;
}
.logo-icon { height: 32px; width: auto; }
.logo-live {
  font-size: 1.4rem; font-weight: 800; letter-spacing: -0.01em;
  color: #fff;
}
.logo-rest {
  font-size: 1.4rem; font-weight: 800; letter-spacing: -0.01em;
  color: var(--muted);
}
@media (max-width: 600px) {
  .logo-live, .logo-rest { font-size: 1rem; }
  .logo-icon { height: 26px; }
}
@media (max-width: 420px) {
  .logo-rest { display: none; }
}
/* original image logo (kept for quick revert) */
.logo-img { display: block; width: auto; height: auto; max-height: 46px; max-width: min(480px, 66vw); }
@media (max-width: 520px) { .logo-img { max-height: 40px; } }
.topbar-tag { color: var(--muted); font-size: 0.9rem; }
.back { color: var(--muted); text-decoration: none; font-size: 0.95rem; }
.back:hover { color: var(--ink); }

/* Feed */
.feed-section { margin-top: 1.5rem; }
.section-title {
  display: flex; align-items: center; gap: 0.5rem;
  font-size: 1.15rem; margin: 0 0 1rem;
}
.live-dot {
  width: 10px; height: 10px; border-radius: 50%; background: var(--live);
  box-shadow: 0 0 0 0 rgba(255,75,92,0.6); animation: pulse 1.8s infinite;
}
@keyframes pulse {
  0% { box-shadow: 0 0 0 0 rgba(255,75,92,0.6); }
  70% { box-shadow: 0 0 0 8px rgba(255,75,92,0); }
  100% { box-shadow: 0 0 0 0 rgba(255,75,92,0); }
}

/* Featured live hero (single muted autoplay player).
   On-video chrome is minimal (LIVE badge). Title / source / CTA live under the player. */
.featured {
  position: relative; display: block; text-decoration: none; overflow: hidden;
  border-radius: 16px; border: 1px solid var(--border); background: #000;
  aspect-ratio: 16 / 9; margin-bottom: 0;
}
.featured-video { position: absolute; inset: 0; background-size: cover; background-position: center; }
.featured-video iframe { width: 100%; height: 100%; border: 0; display: block; pointer-events: none; }
.hero-iframe { position: absolute; inset: 0; opacity: 0; transition: opacity .45s ease; }
.hero-iframe.ready { opacity: 1; }
.hero-loader { position: absolute; inset: 0; z-index: 1; display: flex; flex-direction: column;
  align-items: center; justify-content: center; gap: 12px; color: #fff; background: rgba(0,0,0,0.35); }
.hero-loader span { font-weight: 700; font-size: 0.9rem; letter-spacing: 0.02em; text-shadow: 0 1px 3px rgba(0,0,0,.6); }
.spinner { width: 38px; height: 38px; border: 3px solid rgba(255,255,255,0.3); border-top-color: #fff;
  border-radius: 50%; animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.featured-video .poster { position: absolute; inset: 0; background-size: cover; background-position: center;
  background-color: var(--panel-2); }
.featured-video .playpip { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; }
.featured-video .playpip::after { content: "▶"; color: #fff; font-size: 2rem; background: rgba(0,0,0,0.45);
  width: 66px; height: 66px; border-radius: 50%; display: flex; align-items: center; justify-content: center; padding-left: 6px; }
.featured-topbar { position: absolute; top: 12px; left: 12px; z-index: 2; display: flex; gap: 8px; align-items: center; }
.featured-topbar .card-badge { position: static; top: auto; left: auto; }
.featured-viewers { background: rgba(0,0,0,0.55); color: #fff; font-size: 0.75rem; font-weight: 700; padding: 3px 8px; border-radius: 6px; }
.featured-shuffle {
  position: absolute; top: 0; right: 0; bottom: 0; z-index: 3; cursor: pointer;
  width: 56px; background: transparent; color: #fff; border: none; border-radius: 0;
  font-size: 0; display: flex; align-items: center; justify-content: flex-end;
  padding-right: 12px; transition: background 0.2s;
}
.featured-shuffle::before {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(to right, transparent 0%, rgba(0,0,0,0.45) 100%);
  clip-path: polygon(40% 0, 100% 0, 100% 100%, 0% 100%);
  opacity: 0; transition: opacity 0.25s;
}
.featured-shuffle:hover::before { opacity: 1; }
.featured-shuffle::after {
  content: '\203A'; font-size: 2.4rem; font-weight: 300; position: relative; z-index: 1;
  opacity: 0.55; transition: opacity 0.25s; text-shadow: 0 1px 4px rgba(0,0,0,.6);
}
.featured-shuffle:hover::after { opacity: 1; }
/* Live embeds: no title wall on the video. Up-next may show a short title on the poster. */
.featured-overlay {
  position: absolute; left: 0; right: 0; bottom: 0; z-index: 2;
  padding: 1.25rem 1.1rem 1rem; display: flex; flex-direction: column; align-items: flex-start; gap: 0.2rem;
  background: linear-gradient(to top, rgba(0,0,0,0.72), rgba(0,0,0,0) 85%);
  pointer-events: none;
}
.featured-overlay[hidden] { display: none !important; }
.featured.is-live-embed .featured-overlay { display: none !important; }
.featured-overlay .featured-title {
  margin: 0; font-size: clamp(1.05rem, 2.8vw, 1.35rem); color: #fff; line-height: 1.2;
  text-shadow: 0 1px 10px rgba(0,0,0,0.55);
  max-width: 90%;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.featured-below {
  display: flex; flex-wrap: wrap; align-items: flex-start; justify-content: space-between;
  gap: 0.65rem 1rem; margin: 0.7rem 0 0.35rem;
}
.featured-below-copy { min-width: 0; flex: 1 1 14rem; }
.featured-below .featured-title {
  margin: 0; font-size: clamp(1.05rem, 2.6vw, 1.35rem); color: var(--ink); line-height: 1.25;
}
.featured-below .featured-meta { color: var(--muted); font-size: 0.9rem; margin-top: 0.2rem; }
.featured-below .featured-countdown {
  margin-top: 0.45rem;
  text-shadow: none;
  color: var(--ink);
}
.featured-below .featured-countdown-label { color: var(--accent); }
.featured-below .featured-countdown-when { color: var(--muted); }
.featured-cta { background: var(--accent); color: var(--accent-ink); font-weight: 800;
  padding: 0.45rem 1rem; border-radius: 999px; font-size: 0.85rem; text-decoration: none; }

.grid {
  display: grid; gap: 1rem;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
}
.card {
  display: flex; flex-direction: column; text-decoration: none;
  background: var(--panel); border: 1px solid var(--border); border-radius: var(--radius);
  overflow: hidden; transition: transform .12s ease, border-color .12s ease;
}
.card:hover { transform: translateY(-2px); border-color: #3a3050; }
.card-poster {
  aspect-ratio: 16 / 9; background: linear-gradient(135deg, #2a2140, #191426);
  background-size: cover; background-position: center; position: relative;
}
.card-badge {
  position: absolute; top: 8px; left: 8px;
  font-size: 0.7rem; font-weight: 800; letter-spacing: 0.06em;
  padding: 3px 7px; border-radius: 6px; background: var(--accent); color: var(--accent-ink);
}
.card-badge.is-live { background: var(--live); color: #fff; }
.card-badge.is-usual { background: #3a3050; color: #f2ebff; letter-spacing: 0.04em; }
.card.is-usual { cursor: default; }
.card.is-usual:hover { transform: none; }
.card-source.is-usual { color: var(--muted); }
.card-body { padding: 0.85rem 0.95rem 1rem; }
.card-title { margin: 0 0 0.3rem; font-size: 1.02rem; line-height: 1.25; }
.card-meta { color: var(--ink); font-size: 0.9rem; }
.card-when { color: var(--muted); font-size: 0.85rem; margin-top: 0.25rem; }
.card-people { color: var(--muted); font-size: 0.82rem; margin-top: 0.4rem; }

.empty { color: var(--muted); padding: 1rem 0; }

/* Watch page */
.watch { margin-top: 1rem; }
.player {
  aspect-ratio: 16 / 9; background: #000; border-radius: var(--radius);
  overflow: hidden; border: 1px solid var(--border);
}
.player video { width: 100%; height: 100%; display: block; background: #000; }
.player-empty {
  display: flex; align-items: center; justify-content: center; text-align: center;
  color: var(--ink); background: var(--panel-2);
}
.player-empty .muted { color: var(--muted); font-size: 0.9rem; }
.muted { color: var(--muted); }

.watch-info { margin-top: 1.25rem; }
.watch-head { display: flex; align-items: center; gap: 0.75rem; }
.watch-head h1 { font-size: 1.5rem; margin: 0; }
.watch-meta { font-size: 1.05rem; margin-top: 0.35rem; }
.watch-when { color: var(--muted); margin-top: 0.15rem; }
.watch-line { margin: 0.6rem 0 0; }
.watch-line .label {
  display: inline-block; min-width: 92px; color: var(--muted);
  font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.05em;
}
.watch-desc { margin-top: 1rem; color: var(--muted); max-width: 60ch; }

/* For-theaters guide */
.guide-hero { margin-top: 1.5rem; max-width: 760px; }
.guide-hero h1 { font-size: clamp(1.9rem, 5vw, 2.8rem); line-height: 1.1; margin: 0 0 1rem; letter-spacing: -0.02em; }
.lead { font-size: 1.08rem; color: var(--ink); margin: 0 0 1rem; }
.lead .muted, .lead em { color: var(--muted); }

.guide-block { margin-top: 2.5rem; }
.guide-block > h2 { font-size: 1.35rem; margin: 0 0 0.75rem; }
.small { font-size: 0.88rem; }

.standards { background: var(--panel); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.5rem; }
.std-grid { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); margin-top: 1rem; }
.std { background: var(--panel-2); border: 1px solid var(--border); border-radius: 12px; padding: 1.1rem; }
.std-num {
  width: 30px; height: 30px; border-radius: 50%; background: var(--accent); color: var(--accent-ink);
  font-weight: 800; display: flex; align-items: center; justify-content: center; margin-bottom: 0.6rem;
}
.std h3 { margin: 0 0 0.4rem; font-size: 1.02rem; }
.std p { margin: 0; color: var(--muted); font-size: 0.92rem; }

.ticks { list-style: none; padding: 0; margin: 0; }
.ticks li { position: relative; padding-left: 1.6rem; margin: 0.5rem 0; color: var(--ink); }
.ticks li::before { content: "✓"; position: absolute; left: 0; color: var(--accent); font-weight: 800; }
.ticks li em { color: var(--muted); }
.two-col { display: grid; gap: 0 1.5rem; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }

.tier { background: var(--panel); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.35rem; margin-top: 1rem; }
.tier-head { margin-bottom: 0.4rem; }
.tier-tag { display: inline-block; font-size: 0.72rem; font-weight: 800; letter-spacing: 0.06em; text-transform: uppercase;
  color: var(--accent); background: rgba(255,212,59,0.12); border: 1px solid rgba(255,212,59,0.3); padding: 3px 8px; border-radius: 6px; }
.tier-head h3 { margin: 0.55rem 0 0; font-size: 1.15rem; display: flex; align-items: baseline; gap: 0.6rem; flex-wrap: wrap; }
.price { color: var(--muted); font-weight: 600; font-size: 0.9rem; }
.tier p { color: var(--muted); }
.tier a { color: var(--accent); }
.steps { margin: 0.6rem 0 0; padding-left: 1.2rem; }
.steps li { margin: 0.45rem 0; }
.steps li strong { color: var(--ink); }
.steps li em { color: var(--muted); }

.settings-table { display: grid; gap: 0.5rem; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
.settings-table > div {
  display: flex; justify-content: space-between; gap: 1rem;
  background: var(--panel); border: 1px solid var(--border); border-radius: 10px; padding: 0.7rem 0.95rem;
}
.settings-table span { color: var(--muted); }

.guide-cta { margin-top: 3rem; text-align: center; background: var(--panel-2); border: 1px solid var(--border); border-radius: var(--radius); padding: 2rem 1.5rem; }
.guide-cta h2 { margin: 0 0 0.4rem; }
.guide-cta p { color: var(--muted); margin: 0 0 1.2rem; }
/* Explicit panel background so <button class="btn"> is not browser-default white
   with light ink (invisible on watch Follow/Report/Share and Following Unfollow). */
.btn {
  display: inline-block; padding: 0.7rem 1.3rem; border-radius: 999px;
  border: 1px solid var(--border); background: var(--panel-2); color: var(--ink);
  text-decoration: none; font-weight: 700; cursor: pointer; font: inherit;
  -webkit-appearance: none; appearance: none;
}
.btn.small { padding: 0.4rem 0.8rem; font-size: 0.8rem; }
.btn.primary { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }
.btn:hover { border-color: #3a3050; }
.btn.primary:hover { border-color: var(--accent); }

.foot { margin-top: 3rem; text-align: center; color: var(--muted); font-size: 0.9rem; }
.foot a { color: inherit; text-decoration: underline; text-underline-offset: 2px; }

/* —— Twitch + TV-guide homepage (Phase 1) —— */
.guide-layout {
  display: grid;
  gap: 1.25rem;
  grid-template-columns: 1fr;
  align-items: start;
}
.guide-main { min-width: 0; }
.guide-panel { display: none; }

.source-chip {
  display: inline-block;
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 2px 7px;
  border-radius: 4px;
  background: rgba(255,255,255,0.12);
  color: #fff;
  border: 1px solid rgba(255,255,255,0.18);
}
.source-chip.is-yt {
  background: rgba(255,75,92,0.18);
  border-color: rgba(255,75,92,0.45);
  color: #ffc9cf;
}
.source-chip.is-native {
  background: rgba(255,212,59,0.16);
  border-color: rgba(255,212,59,0.4);
  color: var(--accent);
}
.card-poster .card-source {
  position: absolute; top: 8px; right: 8px;
  z-index: 1;
}
.card-poster > img.card-poster-img,
.hero-poster > img.card-poster-img,
.stage-tile-media > img.card-poster-img,
.featured-video .poster > img.card-poster-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  z-index: 0;
  pointer-events: none;
  border: 0;
}
.card-poster > .card-badge {
  z-index: 1;
}

.featured-actions { display: flex; flex-wrap: wrap; gap: 0.45rem; align-items: center; flex: 0 0 auto; }
.featured-venue, .featured-theater {
  color: var(--ink); font-size: 0.85rem; font-weight: 700; text-decoration: none;
  padding: 0.4rem 0.75rem; border-radius: 999px; border: 1px solid var(--border);
}
.featured-theater:hover { border-color: #3a3050; }
.featured-below .source-chip {
  background: var(--panel-2);
  border-color: var(--border);
  color: var(--muted);
}
.featured-below .source-chip.is-yt {
  background: rgba(255,75,92,0.12);
  border-color: rgba(255,75,92,0.35);
  color: #ff8a96;
}
.featured-below .source-chip.is-native {
  background: rgba(255,212,59,0.12);
  border-color: rgba(255,212,59,0.35);
  color: var(--accent);
}
.featured-video iframe.hero-iframe { pointer-events: auto; }

/* Up-next hero: cinematic venue thumb; copy/countdown sit mostly under the player. */
.featured.is-upnext {
  border-color: rgba(255,212,59,0.28);
  box-shadow: 0 18px 48px rgba(0,0,0,0.35);
}
.featured.is-upnext .featured-overlay {
  padding: 1.5rem 1.2rem 1.1rem;
  background: linear-gradient(to top, rgba(0,0,0,0.78) 0%, rgba(0,0,0,0.25) 55%, rgba(0,0,0,0) 100%);
}
.featured.is-upnext .featured-overlay .featured-title {
  font-size: clamp(1.2rem, 3.4vw, 1.7rem);
  letter-spacing: -0.02em;
}
.featured-countdown {
  display: inline-flex; align-items: baseline; gap: 0.45rem; flex-wrap: wrap;
  margin-top: 0.15rem;
  color: var(--ink);
  font-weight: 800;
  letter-spacing: 0.01em;
}
/* Author display must not override the hidden attribute on live / embed heroes. */
.featured-countdown[hidden] { display: none !important; }
.featured-countdown-label {
  font-size: 0.72rem; font-weight: 800; letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--accent);
}
.featured-countdown-value {
  font-size: clamp(1.05rem, 2.8vw, 1.35rem);
  font-variant-numeric: tabular-nums;
}
.featured-countdown-when {
  width: 100%;
  color: var(--muted);
  font-size: 0.88rem;
  font-weight: 600;
}
.hero-poster {
  position: absolute; inset: 0;
  background-size: cover; background-position: center;
  background-color: var(--panel-2);
  transform: scale(1.04);
  animation: heroKen 18s ease-in-out infinite alternate;
}
.hero-embed-note {
  position: absolute; left: 1rem; right: 1rem; bottom: 1rem; z-index: 2;
  margin: 0; padding: 0.55rem 0.75rem;
  color: #f2ecff; font-size: 0.85rem; font-weight: 600;
  background: rgba(13, 11, 20, 0.72); border-radius: 8px;
  pointer-events: none;
}
.hero-poster::after {
  content: "";
  position: absolute; inset: 0;
  background:
    radial-gradient(ellipse at 30% 20%, rgba(255,212,59,0.12), transparent 45%),
    linear-gradient(120deg, rgba(13,11,20,0.35), rgba(13,11,20,0.05) 55%);
}
@keyframes heroKen {
  from { transform: scale(1.04) translate3d(0, 0, 0); }
  to { transform: scale(1.1) translate3d(-1.5%, -1%, 0); }
}
@media (prefers-reduced-motion: reduce) {
  .hero-poster { animation: none; transform: none; }
}

/* Guide window jumps — text segments, not pill clusters. */
.guide-jumps {
  display: flex; flex-wrap: wrap; align-items: baseline; gap: 0.15rem 0.65rem;
}
.guide-jump {
  appearance: none; -webkit-appearance: none;
  background: none; border: none; padding: 0;
  color: var(--muted); font: inherit; font-size: 0.78rem; font-weight: 700;
  letter-spacing: 0.02em; cursor: pointer;
}
.guide-jump:hover { color: var(--ink); }
.guide-jump.is-active {
  color: var(--accent);
  box-shadow: inset 0 -2px 0 var(--accent);
}
.card-badge.is-upnext {
  background: rgba(255,212,59,0.92); color: var(--accent-ink);
}

/* Live Now — Twitch thumbnail cards (visual scan). */
.live-rail {
  display: flex; gap: 0.75rem; overflow-x: auto; padding-bottom: 0.35rem;
  scroll-snap-type: x mandatory; -webkit-overflow-scrolling: touch;
}
.live-rail .rail-card {
  flex: 0 0 min(220px, 72vw); scroll-snap-align: start;
  background: transparent; border: none; border-radius: 0; overflow: visible;
}
.live-rail .rail-card:hover { transform: none; border-color: transparent; }
.live-rail .rail-card .card-poster {
  border-radius: 8px; border: 1px solid var(--border); overflow: hidden;
  aspect-ratio: 16 / 9;
}
.live-rail .rail-card.is-featured .card-poster {
  border-color: rgba(255,212,59,0.55);
  box-shadow: 0 0 0 1px rgba(255,212,59,0.25);
}
.live-rail .rail-card .card-body {
  padding: 0.45rem 0.1rem 0.15rem; background: transparent;
}
.live-rail .rail-card .card-title {
  margin: 0; font-size: 0.92rem; line-height: 1.25;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.live-rail .rail-card .card-meta {
  margin-top: 0.15rem; font-size: 0.78rem; color: var(--muted);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.live-rail .card-badge.is-live {
  top: auto; bottom: 8px; left: 8px;
  font-size: 0.65rem; padding: 2px 6px; border-radius: 4px;
}

/* Guide — dense time-first schedule rows (YouTube TV / EPG scan grammar). */
.guide-rows { display: flex; flex-direction: column; gap: 0; }
.guide-section-label {
  margin: 0.85rem 0 0.2rem;
  padding: 0.15rem 0;
  font-size: 0.68rem; font-weight: 800; letter-spacing: 0.14em;
  text-transform: uppercase; color: var(--muted);
}
.guide-section-label:first-child { margin-top: 0.35rem; }
.guide-section-label.is-live {
  color: var(--live);
  display: flex; align-items: center; gap: 0.4rem;
}
.guide-section-label.is-live::before {
  content: "";
  width: 6px; height: 6px; border-radius: 50%; background: var(--live);
  box-shadow: 0 0 0 0 rgba(255,75,92,0.55);
  animation: pulse 1.8s infinite;
}
.guide-row {
  display: grid;
  grid-template-columns: 4.6rem minmax(0, 1fr) auto;
  gap: 0.35rem 0.55rem;
  align-items: baseline;
  padding: 0.42rem 0.2rem 0.42rem 0.35rem;
  margin: 0;
  background: transparent;
  border: none;
  border-bottom: 1px solid rgba(255,255,255,0.055);
  border-left: 2px solid transparent;
  border-radius: 0;
  cursor: pointer;
  transition: background .12s ease, border-color .12s ease;
}
.guide-row:hover, .guide-row.is-active {
  background: rgba(255,255,255,0.035);
}
.guide-row.is-active {
  border-left-color: var(--accent);
}
.guide-row.is-live {
  border-left-color: rgba(255,75,92,0.75);
  background: rgba(255,75,92,0.04);
}
.guide-row.is-live:hover, .guide-row.is-live.is-active {
  background: rgba(255,75,92,0.07);
}
.guide-row.is-usual {
  cursor: default;
  opacity: 0.92;
}
.guide-row.is-usual .guide-row-time {
  font-weight: 650;
  letter-spacing: 0;
}

.guide-row-time {
  font-size: 0.72rem; font-weight: 800; color: var(--muted);
  letter-spacing: 0.01em; font-variant-numeric: tabular-nums;
  text-transform: none; line-height: 1.35; padding-top: 0.08rem;
}
.guide-row.is-live .guide-row-time {
  color: var(--live);
  letter-spacing: 0.08em;
}
.guide-row-body { min-width: 0; }
.guide-row-title {
  margin: 0; font-size: 0.86rem; line-height: 1.28; font-weight: 650;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
  overflow: hidden; max-width: 100%;
}
.guide-row-meta {
  color: var(--muted); font-size: 0.72rem; margin-top: 0.08rem; line-height: 1.3;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.guide-row-actions {
  display: flex; flex-direction: row; gap: 0.55rem; align-items: center;
  justify-content: flex-end; align-self: center;
}
.guide-watch {
  color: var(--accent); font-size: 0.72rem; font-weight: 800;
  text-decoration: none; letter-spacing: 0.02em; white-space: nowrap;
}
.guide-watch:hover { text-decoration: underline; }
.guide-venue, .guide-theater {
  color: var(--muted); font-size: 0.7rem; font-weight: 650;
  text-decoration: none; white-space: nowrap;
}
.guide-theater:hover { color: var(--ink); }

.guide-stack { margin-top: 1.15rem; }
.guide-stack-head {
  display: flex; flex-wrap: wrap; align-items: baseline;
  justify-content: space-between; gap: 0.5rem 1rem;
  margin-bottom: 0.35rem;
  position: sticky; top: 0; z-index: 5;
  padding: 0.4rem 0 0.35rem;
  background: linear-gradient(to bottom, rgba(13,11,20,0.97), rgba(13,11,20,0.9) 75%, transparent);
}
.guide-stack-title { margin: 0; }
.guide-panel-head {
  display: flex; flex-wrap: wrap; align-items: baseline;
  justify-content: space-between; gap: 0.4rem 0.75rem;
  margin-bottom: 0.25rem;
  padding-bottom: 0.45rem;
  border-bottom: 1px solid rgba(255,255,255,0.08);
  position: sticky; top: 0; z-index: 2;
  background: linear-gradient(to bottom, rgba(13,11,20,0.98), rgba(13,11,20,0.92));
}
.guide-panel-title {
  font-size: 0.72rem; margin: 0; letter-spacing: 0.14em;
  text-transform: uppercase; color: var(--muted); font-weight: 800;
}

@media (min-width: 1280px) {
  .wrap-guide { max-width: 1440px; }
  .guide-layout {
    grid-template-columns: minmax(0, 1fr) 340px;
    gap: 1.25rem;
  }
  .guide-panel {
    display: block;
    position: sticky;
    top: 0.75rem;
    align-self: start;
    max-height: calc(100vh - 1.5rem);
  }
  .guide-panel-inner {
    background: transparent;
    border: none;
    border-left: 1px solid var(--border);
    border-radius: 0;
    padding: 0.1rem 0 0.5rem 0.95rem;
    max-height: calc(100vh - 1.5rem);
    overflow: auto;
  }
  /* Right column is the full guide; avoid duplicating the long list under the rail. */
  .guide-stack { display: none; }
  .hero-section .featured { margin-bottom: 0; }
}

@media (max-width: 1279px) {
  .guide-panel { display: none; }
}

@media (max-width: 520px) {
  .featured.is-upnext .featured-overlay { padding: 1.1rem 0.9rem 0.9rem; }
  .featured-below { gap: 0.5rem; }
  .guide-row {
    grid-template-columns: 4.1rem minmax(0, 1fr);
    grid-template-rows: auto auto;
    padding-left: 0.25rem;
  }
  .guide-row-actions {
    grid-column: 2;
    justify-content: flex-start;
    padding-bottom: 0.1rem;
  }
}

/* ---- Live stage wall (other live shows, muted) + Coming up row ---- */
.stage-wall .section-title { display: flex; align-items: center; gap: 0.45rem; }
.stage-wall-count { color: var(--muted); font-weight: 600; font-size: 0.85em; }
.stage-wall-count:empty { display: none; }
.stage-wall-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 0.75rem; }
.stage-tile { all: unset; cursor: pointer; display: flex; flex-direction: column; gap: 0.35rem; min-width: 0; }
.stage-tile-media { position: relative; aspect-ratio: 16 / 9; border-radius: 10px; overflow: hidden;
  background: #111 center / cover no-repeat; outline: 2px solid transparent; transition: outline-color .15s; }
.stage-tile:hover .stage-tile-media, .stage-tile:focus-visible .stage-tile-media { outline-color: var(--accent); }
.stage-tile-media iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; pointer-events: none; }
.stage-tile-media .card-badge { position: absolute; top: 8px; left: 8px; z-index: 1; }
.stage-tile-cap { display: flex; flex-direction: column; min-width: 0; font-size: 0.85rem; }
.stage-tile-cap strong { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.stage-tile-cap span { color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
@media (max-width: 899px) { .stage-wall-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.stage-cams .section-title { color: var(--muted); }
.stage-cams .card-badge { background: #3a3a3a; }

/* Recently live: full wall of real theater replays (grid, not a single scroll row). */
.live-rail.recent-rail {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
  gap: 1rem 0.85rem; overflow: visible; scroll-snap-type: none;
}
.live-rail.recent-rail .rail-card { flex: none; width: auto; }

/* —— Category channels sidebar (bigstage.tv/<slug>) —— */
.logo-wordmark {
  font-size: 1.4rem; font-weight: 800; letter-spacing: -0.01em; color: var(--accent);
  margin-right: 0.35em;
}
@media (max-width: 600px) { .logo-wordmark { font-size: 1rem; } }
.channel-nav-toggle {
  display: inline-flex; align-items: center; gap: 0.45rem; flex: none;
  background: var(--panel); color: var(--ink); border: 1px solid var(--border);
  border-radius: 10px; padding: 0.45rem 0.7rem; font: inherit; font-size: 0.85rem; font-weight: 700;
  cursor: pointer;
}
.channel-nav-toggle:hover { border-color: var(--accent); }
.channel-nav-toggle-bars, .channel-nav-toggle-bars::before, .channel-nav-toggle-bars::after {
  display: block; width: 16px; height: 2px; background: currentColor; border-radius: 2px; position: relative;
}
.channel-nav-toggle-bars::before, .channel-nav-toggle-bars::after { content: ""; position: absolute; left: 0; }
.channel-nav-toggle-bars::before { top: -5px; }
.channel-nav-toggle-bars::after { top: 5px; }
@media (max-width: 420px) { .channel-nav-toggle-label { display: none; } }

.site-shell { display: block; }
.site-content { min-width: 0; }

.channel-nav {
  position: fixed; top: 0; left: 0; bottom: 0; z-index: 60;
  width: min(300px, 84vw); background: var(--panel); border-right: 1px solid var(--border);
  padding: 1rem 0.75rem 2rem; overflow-y: auto;
  transform: translateX(-102%); transition: transform 0.2s ease;
}
.channel-nav.is-open { transform: none; box-shadow: 0 0 40px rgba(0, 0, 0, 0.5); }
.channel-nav-backdrop { position: fixed; inset: 0; z-index: 55; background: rgba(0, 0, 0, 0.55); }
.channel-nav-backdrop[hidden] { display: none; }
body.channel-nav-open { overflow: hidden; }
.channel-nav-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 0.4rem 0.6rem; margin-bottom: 0.35rem; border-bottom: 1px solid var(--border);
}
.channel-nav-title {
  font-size: 0.72rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--muted); font-weight: 800;
}
.channel-nav-close {
  background: none; border: none; color: var(--muted); font-size: 1.5rem; line-height: 1; cursor: pointer; padding: 0 0.2rem;
}
.channel-nav-close:hover { color: var(--ink); }
.channel-list, .channel-sublist { list-style: none; margin: 0; padding: 0; }
.channel-list > li { position: relative; }
.channel-link {
  display: flex; align-items: center; justify-content: space-between; gap: 0.5rem;
  padding: 0.42rem 0.55rem; border-radius: 8px; color: var(--ink); text-decoration: none;
  font-size: 0.9rem; font-weight: 600; line-height: 1.25;
}
.channel-list > li.has-subs > .channel-link { padding-right: 2rem; }
.channel-link:hover { background: var(--panel-2); }
.channel-link.is-active { background: var(--panel-2); box-shadow: inset 3px 0 0 var(--accent); }
.channel-link.is-empty { color: var(--muted); opacity: 0.6; font-weight: 500; }
.channel-link.is-empty:hover { opacity: 0.9; }
.channel-link.is-sub { padding-left: 1.4rem; font-size: 0.84rem; }
.channel-name { min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.channel-live {
  display: inline-flex; align-items: center; gap: 0.3rem; flex: none;
  font-size: 0.75rem; font-weight: 800; color: var(--ink);
}
.channel-live .live-dot { width: 8px; height: 8px; }
.channel-expand {
  position: absolute; top: 0.2rem; right: 0.2rem; width: 1.6rem; height: 1.6rem;
  background: none; border: none; color: var(--muted); cursor: pointer; font-size: 0.85rem; border-radius: 6px;
}
.channel-expand:hover { color: var(--ink); background: var(--panel-2); }
.channel-expand[aria-expanded="true"] { transform: rotate(180deg); }
.channel-sublist[hidden] { display: none; }

.channel-heading { margin: 0 0 0.25rem; }
.channel-heading[hidden] { display: none; }
.channel-heading-title { margin: 0; font-size: clamp(1.2rem, 2.8vw, 1.6rem); font-weight: 800; letter-spacing: -0.01em; }

@media (min-width: 1024px) {
  .channel-nav-toggle { display: none; }
  .site-shell { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 1.25rem; align-items: start; }
  .channel-nav {
    position: sticky; top: 0.75rem; z-index: auto; width: auto; transform: none; transition: none;
    max-height: calc(100vh - 1.5rem); padding: 0.1rem 0.5rem 0.5rem 0; background: transparent;
    border-right: 1px solid var(--border); box-shadow: none;
  }
  .channel-nav-close { display: none; }
  .channel-nav-backdrop { display: none !important; }
  body.channel-nav-open { overflow: auto; }
}
@media (min-width: 1280px) {
  .wrap-guide.has-channels { max-width: 1680px; }
}
.channel-empty {
  margin: 0.75rem 0 1rem; padding: 1.1rem 1.2rem; color: var(--muted);
  background: var(--panel); border: 1px solid var(--border); border-radius: var(--radius);
}
.channel-empty[hidden] { display: none; }
.channel-empty a { color: var(--accent); text-decoration: none; font-weight: 700; }

/* Server-rendered about / FAQ / channel links (SEO). Quiet, below the guide. */
.seo-about { margin: 3rem 0 0; padding: 1.5rem 0 0; border-top: 1px solid var(--border); color: var(--muted); font-size: 0.95rem; max-width: 860px; }
.seo-about .seo-about-title { color: var(--ink); font-size: 1.35rem; line-height: 1.25; margin: 0 0 0.75rem; }
.seo-about h3 { color: var(--ink); font-size: 1rem; margin: 1.5rem 0 0.5rem; }
.seo-about p { margin: 0 0 0.75rem; }
.seo-about a, .seo-page a { color: var(--ink); }
.seo-list { margin: 0; padding-left: 1.1rem; }
.seo-list li { margin: 0.2rem 0; }
.seo-venues, .seo-channels { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 0.25rem 1rem; }
.seo-venues span { color: var(--muted); font-size: 0.85em; }
.seo-faq details { border-bottom: 1px solid var(--border); padding: 0.5rem 0; }
.seo-faq summary { cursor: pointer; color: var(--ink); }
.seo-faq details p { margin: 0.5rem 0 0; }
.seo-links { font-size: 0.9rem; }
.seo-page h1 { font-size: 1.8rem; line-height: 1.2; margin: 0.5rem 0 0.75rem; }
.seo-page h2 { font-size: 1.2rem; margin: 1.75rem 0 0.5rem; }
.seo-page .seo-lede { color: var(--muted); font-size: 1.05rem; }
.seo-page .seo-note { color: var(--muted); font-size: 0.9rem; }
.seo-about .seo-lede { color: var(--ink); font-size: 1.02rem; }
.seo-fresh { font-size: 0.85rem; color: var(--muted); }
.seo-crumbs { color: var(--muted); font-size: 0.85rem; }
.seo-embed { position: relative; width: 100%; max-width: 720px; aspect-ratio: 16 / 9; background: #000; border-radius: var(--radius); overflow: hidden; }
.seo-embed iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }

/* onestage.tv (standalone churches site): no channel rail, so the content spans the whole page.
   Scoped to main[data-standalone] (server) / body.is-standalone (client); bigstage.tv + komedy.tv unaffected. */
main[data-standalone] .site-shell,
body.is-standalone .site-shell { display: block; }
main[data-standalone] .site-content,
body.is-standalone .site-content { min-width: 0; width: 100%; }
@media (min-width: 1280px) {
  main.wrap-guide[data-standalone] { max-width: 1440px; }
}
main[data-standalone] .topbar-tag,
body.is-standalone .topbar-tag { white-space: nowrap; }
main[data-standalone] .channel-heading,
body.is-standalone .channel-heading { display: none; }
main[data-standalone] .topbar,
body.is-standalone .topbar { padding-bottom: 0.65rem; margin-bottom: 0.25rem; }
main[data-standalone] .hero-section,
body.is-standalone .hero-section { margin-top: 0.25rem; }

.card-venue, .stage-tile-venue, .guide-venue, .featured-venue {
  color: inherit;
  text-decoration: underline;
  text-underline-offset: 2px;
}
.card-venue:hover, .stage-tile-venue:hover, .guide-venue:hover, .featured-venue:hover {
  color: var(--ink, #111);
}

/* Subtle follow control on venue and category pages. */
.follow-slot { margin: 0.6rem 0 0.8rem; }
.follow-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 0.6rem 0.9rem; }
.follow-btn.is-following { border-color: var(--accent); }
.follow-hint { color: var(--muted); font-size: 0.85rem; }
.follow-email { display: flex; flex-wrap: wrap; align-items: center; gap: 0.4rem; }
.follow-email-label { color: var(--muted); font-size: 0.85rem; display: flex; gap: 0.4rem; align-items: center; flex-wrap: wrap; }
.follow-email input[type="email"] {
  background: var(--panel-2); border: 1px solid var(--border); border-radius: 8px;
  color: var(--ink); padding: 0.3rem 0.55rem; font: inherit;
}
