/* =================================================================
   bench.gay
   The page has two states, driven by [data-state] on <body>:
     "off"   -> sign dark, page calm
     "live"  -> sign lit, page charged
   live.js flips data-state after polling Owncast's /api/status.
   ================================================================= */

:root {
  --bg:        #0d0b14;
  --bg-soft:   #161222;
  --ink:       #ece8f5;
  --ink-dim:   #8a82a8;
  --line:      #2a2440;
  --live:      #ff2d6f;   /* hot pink — only appears when live */
  --live-glow: #ff2d6f55;
  --off:       #4a4566;
  --radius:    14px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

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

body {
  font-family: "Bricolage Grotesque", system-ui, sans-serif;
  background: var(--bg);
  color: var(--ink);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  line-height: 1.5;
  transition: background 600ms ease;
}

body[data-state="live"] {
  background:
    radial-gradient(120% 80% at 50% -10%, var(--live-glow) 0%, transparent 55%),
    var(--bg);
}

.wrap {
  width: min(880px, 92vw);
  margin: 0 auto;
  flex: 1;
  display: flex;
  flex-direction: column;
  padding: clamp(1.4rem, 4vw, 3rem) 0;
}

/* ---------- masthead ---------- */
.masthead {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.wordmark {
  font-weight: 800;
  font-size: clamp(1.5rem, 4vw, 2.1rem);
  letter-spacing: -0.03em;
}
.tld { color: var(--live); }

.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.5ch;
  font-family: "Space Mono", monospace;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--ink-dim);
  border: 1px solid var(--line);
  border-radius: 100px;
  padding: 0.4rem 0.8rem;
}
.dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--off);
  transition: background 300ms ease, box-shadow 300ms ease;
}
body[data-state="live"] .dot {
  background: var(--live);
  box-shadow: 0 0 0 0 var(--live-glow);
  animation: pulse 1.6s infinite;
}
@keyframes pulse {
  0%   { box-shadow: 0 0 0 0 var(--live-glow); }
  70%  { box-shadow: 0 0 0 9px transparent; }
  100% { box-shadow: 0 0 0 0 transparent; }
}

/* ---------- the sign (signature element) ---------- */
.marquee {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: clamp(2rem, 8vw, 5rem) 0;
}

.sign {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  text-decoration: none;
  color: inherit;
  gap: 0.6rem;
  padding: clamp(1.6rem, 5vw, 3rem) clamp(1.8rem, 6vw, 4rem);
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: var(--bg-soft);
  transition: transform 300ms ease, border-color 600ms ease, box-shadow 600ms ease;
  pointer-events: none;            /* off state: not clickable */
}
body[data-state="live"] .sign {
  border-color: var(--live);
  box-shadow: 0 0 60px -12px var(--live-glow), inset 0 0 40px -20px var(--live-glow);
  pointer-events: auto;            /* live: clickable */
  cursor: pointer;
}
body[data-state="live"] .sign:hover { transform: translateY(-3px); }

.sign-eyebrow {
  font-family: "Space Mono", monospace;
  font-size: 0.78rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink-dim);
}

.sign-word {
  font-weight: 800;
  font-size: clamp(2.6rem, 12vw, 6rem);
  letter-spacing: -0.04em;
  line-height: 0.95;
  color: var(--off);
  transition: color 500ms ease, text-shadow 500ms ease;
}
body[data-state="live"] .sign-word {
  color: var(--live);
  text-shadow: 0 0 30px var(--live-glow);
}

.sign-sub {
  font-size: 0.95rem;
  color: var(--ink-dim);
  max-width: 32ch;
}

/* loading shimmer before first status comes back */
body[data-state="loading"] .sign-word { opacity: 0.5; }

/* ---------- recordings ---------- */
.recordings {
  border-top: 1px solid var(--line);
  padding-top: 2rem;
}
.rec-head {
  font-size: 0.95rem;
  font-weight: 600;
  text-transform: lowercase;
  letter-spacing: 0.02em;
  color: var(--ink);
  margin-bottom: 1rem;
  display: flex; align-items: baseline; gap: 0.6ch;
}
.rec-num { color: var(--live); font-family: "Space Mono", monospace; }
.rec-list { list-style: none; }
.rec-item { border-bottom: 1px solid var(--line); }
.rec-item a {
  display: flex; align-items: baseline; gap: 0.6ch;
  padding: 0.9rem 0.2rem;
  text-decoration: none;
  color: var(--ink);
  transition: padding-left 200ms ease, color 200ms ease;
}
.rec-item a:hover { padding-left: 0.8rem; color: var(--live); }
.rec-title { font-weight: 600; }
.rec-meta { font-size: 0.85rem; color: var(--ink-dim); }
.rec-empty {
  padding: 0.9rem 0.2rem;
  font-family: "Space Mono", monospace;
  font-size: 0.82rem;
  color: var(--ink-dim);
}
.rec-note {
  margin-top: 1rem; font-size: 0.8rem; color: var(--ink-dim);
  font-family: "Space Mono", monospace;
}
.rec-note code {
  background: var(--bg-soft); padding: 0.1em 0.4em; border-radius: 4px;
}

/* ---------- footer ---------- */
.foot {
  margin-top: 2.5rem;
  display: flex; align-items: center; gap: 0.7ch;
  font-family: "Space Mono", monospace;
  font-size: 0.78rem;
  color: var(--ink-dim);
}
.foot a { color: var(--ink-dim); text-decoration: none; }
.foot a:hover { color: var(--live); }
.foot-sep { opacity: 0.5; }

/* ---------- a11y ---------- */
:focus-visible { outline: 2px solid var(--live); outline-offset: 3px; border-radius: 4px; }

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