/* Live theatre (live.html, assets/js/live.js). Tokens and dark mode come from main.css. */
.mute { color: var(--muted); }
.live-page-gap { height: 96px; }

/* Header */
.l-head { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 24px 48px; align-items: end; padding: clamp(28px, 4vw, 48px) 0 28px; }
.l-head > * { min-width: 0; }
.l-head h1 { font-size: clamp(32px, 4.6vw, 64px); margin-top: 14px; max-width: 20ch; overflow-wrap: anywhere; }
.l-head .lede { margin: 16px 0 0; }
.l-state { margin: 18px 0 0; }
.l-state .label { flex-wrap: wrap; }
.l-state.on .label { color: var(--iodine); }
.l-state.on .dot { animation: livedot 1.6s infinite; }
.crumbs { color: var(--muted); }
.who { display: flex; align-items: center; gap: 14px; min-width: 0; }
.who[hidden] { display: none; }
.avatar { width: 48px; height: 48px; border-radius: 50%; background: var(--drape); color: var(--paper); display: grid; place-items: center; font-family: var(--f-display); font-size: 19px; flex: none; border: 1px solid var(--drape-2); overflow: hidden; }
.avatar img { width: 100%; height: 100%; object-fit: cover; display: block; }
.who strong { display: block; font-weight: 500; color: var(--ink); overflow-wrap: anywhere; }
.who span { font-size: 14px; }
.viewers { font-family: var(--f-mono); font-size: 12px; color: var(--muted); margin-top: 4px; }
.viewers[hidden] { display: none; }
@media (max-width: 760px) { .l-head { grid-template-columns: minmax(0, 1fr); } }

/* Layout: main column and a side column; one column on small screens */
.state { margin-top: 4px; }
.l-grid { display: grid; grid-template-columns: minmax(0, 1fr) 380px; gap: 28px; align-items: start; }
.l-grid > * { min-width: 0; }
@media (max-width: 1060px) { .l-grid { grid-template-columns: minmax(0, 1fr); } }
.l-about { margin-top: 18px; color: var(--ink-2); }
.l-about p { margin: 0 0 8px; max-width: 70ch; }

/* Stage */
.stage { position: relative; aspect-ratio: 16 / 9; border-radius: var(--r-m); overflow: hidden; background: #09050A; border: 1px solid var(--theatre-line); }
.stage-art { position: absolute; inset: 0; }
.stage.real iframe, .stage.real video { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; display: block; background: #000; }
.stage-msg { position: absolute; inset: 0; display: grid; place-items: center; padding: 24px; text-align: center; color: #E9DEE6; }
.stage-msg p { margin: 0; max-width: 46ch; line-height: 1.5; }
.feed { position: absolute; inset: 0; transition: all .6s var(--ease-out); }
#dScope .shot { position: absolute; inset: 0; opacity: 0; transition: opacity 1.1s var(--ease-out); }
#dScope .shot.on { opacity: 1; }
#dScope .shot img { width: 100%; height: 100%; object-fit: cover; display: block; transform: scale(1.06); }
#dScope .shot.on img { animation: drift 18s ease-in-out infinite alternate; }
@keyframes drift { from { transform: scale(1.04) translate(-1%, .5%); } to { transform: scale(1.1) translate(1%, -1%); } }
#dScope::after { content: ""; position: absolute; inset: 0; pointer-events: none; background: radial-gradient(ellipse at center, transparent 55%, rgba(9, 5, 10, .55) 100%); }
#dRoom > img { width: 100%; height: 100%; object-fit: cover; display: block; }
.stage[data-feed="scope"] #dRoom { opacity: 0; pointer-events: none; }
.stage[data-feed="room"] #dScope { opacity: 0; }
.stage[data-feed="split"] #dRoom { inset: auto 16px 64px auto; width: 30%; aspect-ratio: 16 / 9; height: auto; border-radius: 10px; overflow: hidden; border: 1px solid rgba(248, 242, 247, .35); box-shadow: 0 18px 40px -10px rgba(0, 0, 0, .7); z-index: 2; }
.ov { position: absolute; z-index: 3; font-family: var(--f-mono); font-size: 11px; letter-spacing: .06em; text-transform: uppercase; color: #E9DEE6; }
.ov-tl { top: 14px; left: 14px; right: 14px; display: flex; gap: 8px; }
.pill { background: rgba(9, 5, 10, .66); padding: 6px 10px; border-radius: 999px; display: inline-flex; align-items: center; gap: 8px; backdrop-filter: blur(6px); max-width: 100%; }
.lower { position: absolute; left: 0; right: 0; bottom: 0; z-index: 1; padding: 64px 20px 16px; background: linear-gradient(transparent, rgba(9, 5, 10, .88)); pointer-events: none; }
.lower .mono { color: var(--monitor); display: block; }
.lower-t { font-family: var(--f-display); font-size: clamp(20px, 2.6vw, 32px); line-height: 1.1; color: #fff; margin: 4px 0 0; }
.cp-flag { position: absolute; z-index: 4; top: 14px; left: 50%; transform: translateX(-50%); background: var(--monitor); color: var(--theatre); padding: 9px 14px; border-radius: 999px; font-family: var(--f-mono); font-size: 11px; letter-spacing: .06em; text-transform: uppercase; text-decoration: none; min-height: 36px; display: inline-flex; align-items: center; animation: flagin .5s var(--ease-out); }
.cp-flag[hidden] { display: none; }
.cp-flag:hover { background: #fff; }
.cp-flag:focus-visible { outline: 2px solid #fff; outline-offset: 3px; }
@keyframes flagin { from { opacity: 0; transform: translate(-50%, -8px); } }
@media (max-width: 640px) {
  .stage[data-feed="split"] #dRoom { width: 36%; bottom: 58px; right: 10px; }
  .lower { padding: 40px 14px 10px; }
  .lower .mono { display: none; }
  .lower-t { font-size: 19px; max-width: 62%; }
  .cp-flag { top: auto; bottom: 12px; left: auto; right: 10px; transform: none; animation: none; }
}

.controls { display: flex; justify-content: space-between; align-items: center; gap: 12px 20px; flex-wrap: wrap; margin: 16px 0 18px; }
.controls-r { display: flex; gap: 10px 16px; align-items: center; flex-wrap: wrap; }
.seg { display: inline-flex; border: 1px solid var(--line); border-radius: 999px; padding: 3px; }
.seg button { min-height: 40px; padding: 0 16px; border-radius: 999px; background: none; border: 0; color: var(--muted); font: inherit; font-size: 14px; cursor: pointer; }
.seg button:hover { color: var(--ink); }
.seg button[aria-pressed="true"] { background: var(--drape); color: var(--paper); }
.chip { min-height: 40px; padding: 0 16px; border-radius: 999px; border: 1px solid var(--line); background: none; color: var(--ink-2); font: inherit; font-size: 14px; cursor: pointer; }
.chip:hover { border-color: var(--ink); }
.chip[aria-disabled="true"] { opacity: .5; cursor: default; }
.chip[hidden] { display: none; }
.shots { display: grid; grid-template-columns: repeat(8, minmax(0, 1fr)); gap: 8px; margin-top: 4px; }
.shots button { all: unset; box-sizing: border-box; cursor: pointer; display: grid; gap: 6px; min-width: 0; align-content: start; }
.shots img { width: 100%; height: auto; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 8px; display: block; opacity: .62; filter: saturate(.7); outline: 2px solid transparent; outline-offset: 2px; transition: opacity .3s, filter .3s, outline-color .3s, transform .4s var(--ease-out); }
.shots span { font-size: 11px; line-height: 1.25; color: var(--muted); overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.shots b { font-family: var(--f-mono); font-weight: 400; margin-right: 5px; color: var(--drape); }
.shots button:hover img { opacity: .9; transform: translateY(-2px); }
.shots button[aria-pressed="true"] img { opacity: 1; filter: none; outline-color: var(--iodine); }
.shots button[aria-pressed="true"] span { color: var(--ink); }
.shots button:focus-visible img { outline-color: var(--drape); }
@media (max-width: 760px) { .shots { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 6px; } .shots button { flex: 0 0 92px; scroll-snap-align: start; } }
.feed-credit { margin: 10px 0 0; font-size: 12px; color: var(--muted); overflow-wrap: anywhere; }
.feed-credit .show-credit, .credits .show-credit { position: static; max-width: none; font: inherit; letter-spacing: normal; text-align: start; text-shadow: none; color: inherit; text-decoration: underline; text-underline-offset: 2px; }
.feed-credit .show-credit:hover, .credits .show-credit:hover { color: var(--ink); }
.credits { margin: 8px 0 24px; font-size: 12px; color: var(--muted); }
.credits summary { cursor: pointer; min-height: 32px; display: flex; align-items: center; }
.credits ul { margin: 6px 0 0; padding-inline-start: 18px; display: grid; gap: 4px; overflow-wrap: anywhere; }

/* Phase rail */
.rail-h { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; margin-bottom: 12px; flex-wrap: wrap; }
.rail-h h3 { font-size: 22px; }
.rail { display: flex; gap: 3px; height: 10px; }
.rail span { position: relative; border-radius: 3px; background: var(--line); overflow: hidden; min-width: 0; }
.rail span b { position: absolute; inset: 0; width: 0; background: var(--drape-2); }
.rail span.done b { width: 100%; }
.rail span.now b { background: var(--drape); }
.phases { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); border-top: 1px solid var(--line); margin-top: 16px; }
.phases > div { padding: 14px 18px 0 0; min-width: 0; }
.phases > div + div { padding-left: 18px; border-left: 1px solid var(--line); }
.phases .mono { color: var(--muted); font-size: 11px; text-transform: uppercase; letter-spacing: .06em; }
.phases .now .mono { color: var(--drape); }
.phases p { margin: 6px 0 0; color: var(--ink); font-family: var(--f-display); font-size: 20px; line-height: 1.15; overflow-wrap: anywhere; }
.phases small { display: block; margin-top: 6px; color: var(--muted); font-size: 14px; }
@media (max-width: 640px) { .phases { grid-template-columns: minmax(0, 1fr); } .phases > div + div { border-left: 0; padding-left: 0; border-top: 1px dashed var(--line); margin-top: 12px; } .phases > div { padding-bottom: 2px; } }

/* Side column */
.panel { background: var(--card); border: 1px solid var(--line); border-radius: var(--r-m); padding: 22px; min-width: 0; }
.panel + .panel, .l-side > * + * { margin-top: 20px; }
.panel-h { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; margin-bottom: 14px; flex-wrap: wrap; }
.panel-h .mono { color: var(--muted); font-size: 11px; text-transform: uppercase; letter-spacing: .06em; }
.panel h3 { font-size: 22px; }
.panel h3:focus { outline: none; }
.panel h3:focus-visible { outline: var(--focus-ring); outline-offset: 4px; }
.pager { display: flex; align-items: center; gap: 12px; margin: 0 0 14px; }
.pager[hidden] { display: none; }
.pg { width: 40px; height: 40px; border-radius: 50%; border: 1px solid var(--line); background: none; color: var(--ink-2); cursor: pointer; display: grid; place-items: center; flex: none; }
.pg svg { width: 14px; height: 14px; }
.pg:hover { border-color: var(--ink); }
.pg[aria-disabled="true"] { opacity: .35; cursor: default; }
.pager .mono { color: var(--muted); }
.cp-q { font-family: var(--f-display); font-size: 21px; line-height: 1.25; color: var(--ink); margin: 0 0 16px; overflow-wrap: anywhere; }
.opts { display: grid; gap: 8px; }
.opt { position: relative; text-align: start; display: grid; grid-template-columns: 26px minmax(0, 1fr); gap: 10px; padding: 12px 14px; border-radius: 12px; border: 1px solid var(--line); background: transparent; color: var(--ink-2); font: inherit; font-size: 15px; line-height: 1.4; cursor: pointer; overflow: hidden; transition: border-color .25s, background-color .25s; min-width: 0; }
.opt:hover:not([aria-disabled="true"]) { border-color: var(--hover-line); background: color-mix(in srgb, var(--drape) 5%, transparent); }
.opt[aria-disabled="true"] { cursor: default; }
.opt .k { font-family: var(--f-mono); font-size: 12px; color: var(--muted); padding-top: 2px; position: relative; }
.opt .bar { position: absolute; inset: 0 auto 0 0; width: 0; background: color-mix(in srgb, var(--drape) 22%, transparent); transition: width 1s var(--ease-out); }
[dir="rtl"] .opt .bar { inset: 0 0 0 auto; }
.opt.right .bar { background: color-mix(in srgb, var(--drape) 22%, transparent); }
.opt .t { position: relative; overflow-wrap: anywhere; }
.opt .pct { display: block; margin-top: 4px; font-family: var(--f-mono); font-size: 11px; color: var(--muted); }
.opt .pct[hidden] { display: none; }
.opt.right { border-color: var(--drape); }
.opt.right .k { color: var(--drape); }
.opt.picked:not(.right) { border-color: var(--iodine); }
.verdict { margin: 14px 0 0; font-size: 15px; color: var(--muted); animation: rise .5s var(--ease-out) backwards; }
.verdict b { color: var(--ink); font-weight: 500; }
.v-note { display: block; margin-top: 8px; font-size: 14px; }
.wait { margin: 0; color: var(--muted); font-size: 15px; }
.tally { font-family: var(--f-mono); font-size: 11px; color: var(--muted); margin-top: 14px; }
@keyframes rise { from { opacity: 0; transform: translateY(8px); } }

.qs { list-style: none; margin: 0; padding: 0; }
.qs li { display: grid; grid-template-columns: 52px minmax(0, 1fr); gap: 12px; padding: 12px 0; border-top: 1px solid var(--line); }
.qs li.nov { grid-template-columns: minmax(0, 1fr); }
.vote { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; min-height: 48px; border-radius: 10px; border: 1px solid var(--line); background: none; color: var(--muted); font-family: var(--f-mono); font-size: 12px; cursor: pointer; transition: border-color .25s, color .25s; }
.vote svg { width: 12px; }
.vote:hover { border-color: var(--hover-line); color: var(--ink); }
.vote[aria-pressed="true"] { border-color: var(--drape); color: var(--drape); }
.vote.static { cursor: default; border-style: dashed; }
.qs p { margin: 0; color: var(--ink); font-size: 15px; line-height: 1.4; overflow-wrap: anywhere; }
.qs small { display: block; margin-top: 4px; color: var(--muted); font-size: 13px; }
.qs small em { font-style: normal; color: var(--drape); }
.qs .ans { margin-top: 8px; padding: 8px 12px; border-inline-start: 3px solid var(--drape); background: var(--paper-2); border-radius: 0 var(--r-s) var(--r-s) 0; font-size: 14px; color: var(--ink-2); }
.qs .ans b { color: var(--ink); font-weight: 500; }
.q-empty { margin: 0 0 8px; font-size: 15px; }
.q-empty[hidden], .q-err[hidden] { display: none; }
.q-err { color: var(--iodine); font-size: 14px; margin: 0 0 8px; }
.ask { display: grid; gap: 8px; margin-top: 14px; }
.ask label { font-size: 14px; font-weight: 500; color: var(--ink); margin-top: 6px; }
.ask label:first-child { margin-top: 0; }
.ask .opt-note { color: var(--muted); font-weight: 400; }
.ask textarea, .ask input[type="text"], .ask input[type="email"] { width: 100%; background: var(--paper); border: 1px solid var(--line); border-radius: 12px; color: var(--ink); font: inherit; font-size: 16px; padding: 12px 14px; min-height: 46px; }
.ask textarea { min-height: 84px; resize: vertical; line-height: 1.45; }
.ask textarea:focus, .ask input:focus { outline: 0; border-color: var(--drape); box-shadow: 0 0 0 3px color-mix(in srgb, var(--drape) 18%, transparent); }
.ask [aria-invalid="true"] { border-color: var(--iodine); }
.ask .row { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }
.ask .row small { color: var(--muted); font-size: 13px; font-family: var(--f-mono); }
.ask .row small.near { color: var(--warn); }
.ask .hint { font-size: 13px; color: var(--muted); margin: 0; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.btn.sm { min-height: 44px; padding: 0 18px; font-size: 14px; }
.btn.mon { --bg: var(--drape); --fg: var(--paper); }
.btn.mon:hover { --bg: var(--ink); }
.btn[aria-disabled="true"], .btn:disabled { opacity: .6; cursor: progress; }

/* Upcoming, ended, none */
.up { border: 1px solid var(--line); border-radius: var(--r-l); background: var(--card); padding: clamp(22px, 3vw, 36px); }
.up h2 { font-size: clamp(24px, 2.6vw, 34px); margin-bottom: 14px; }
.count { display: flex; gap: 10px; flex-wrap: wrap; margin: 0 0 14px; }
.cd { display: grid; justify-items: center; min-width: 76px; padding: 12px 10px; border: 1px solid var(--line); border-radius: var(--r-m); background: var(--paper); }
.cd b { font-family: var(--f-mono); font-weight: 500; font-size: clamp(24px, 3vw, 34px); color: var(--drape); font-variant-numeric: tabular-nums; }
.cd i { font-style: normal; font-family: var(--f-mono); font-size: 10px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.up-when { font-size: 17px; color: var(--ink); margin: 0 0 6px; }
.up-pres { color: var(--muted); margin: 0 0 18px; }
.up-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.up-late { margin: 0 0 14px; color: var(--ink-2); max-width: 56ch; }
.up .btn { min-height: 46px; }
.remind-form { display: grid; gap: 8px; margin-top: 4px; }
.remind-form label { font-size: 14px; font-weight: 500; }
.remind-form .check { display: flex; gap: 10px; align-items: flex-start; font-weight: 400; margin-top: 6px; }
.remind-form .check input { width: 20px; height: 20px; margin: 2px 0 0; accent-color: var(--drape); flex: none; }
.remind-form input[type="email"] { width: 100%; background: var(--paper); border: 1px solid var(--line); border-radius: 12px; color: var(--ink); font: inherit; font-size: 16px; padding: 10px 14px; min-height: 46px; }
.remind-form input:focus { outline: 0; border-color: var(--drape); box-shadow: 0 0 0 3px color-mix(in srgb, var(--drape) 18%, transparent); }
.remind-form [aria-invalid="true"] { border-color: var(--iodine); }
.remind-form .hint { font-size: 13px; color: var(--muted); margin: 0; }
.remind-form .btn { justify-self: start; margin-top: 8px; }
.form-msg { margin-top: 8px; }
.none { max-width: 640px; }
.none h2 { font-size: clamp(26px, 3vw, 38px); margin-bottom: 12px; }
.ended-card { border: 1px solid var(--line); border-radius: var(--r-l); background: var(--card); padding: clamp(22px, 3vw, 36px); }
.ended-card h2 { font-size: clamp(24px, 2.6vw, 34px); margin-bottom: 12px; }
.ended-card p { color: var(--ink-2); max-width: 60ch; }
.ended-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 8px; }
.l-after { margin-top: 28px; }

/* Demo */
.demo { margin-top: clamp(56px, 7vw, 96px); padding-top: clamp(32px, 4vw, 48px); border-top: 1px solid var(--line); }
.demo[hidden] { display: none; }
.demo-h { display: flex; align-items: baseline; gap: 14px; flex-wrap: wrap; margin-bottom: 16px; }
.demo-h h2 { font-size: clamp(28px, 3.2vw, 42px); }
.demo .notice { margin-bottom: 22px; }
.demo .notice strong { color: var(--ink); font-weight: 500; }
.demo .notice p { margin: 6px 0 0; font-size: 14px; color: var(--ink-2); }
.demo-end { margin-top: 24px; }
.demo-link { margin-top: 40px; }
.demo-link[hidden] { display: none; }

/* Schedule */
.sched { margin-top: clamp(56px, 7vw, 96px); }
.sched-h { display: flex; justify-content: space-between; align-items: end; gap: 12px 24px; flex-wrap: wrap; margin-bottom: 24px; }
.sched-h h2 { font-size: clamp(28px, 3.2vw, 42px); }
.slots { list-style: none; margin: 0; padding: 0; }
.slot a { display: grid; grid-template-columns: 210px minmax(0, 1fr) auto; gap: 8px 24px; align-items: center; padding: 18px 0; border-top: 1px solid var(--line); text-decoration: none; color: inherit; }
.slot:last-child a { border-bottom: 1px solid var(--line); }
.slot .when { font-family: var(--f-mono); font-size: 12px; color: var(--drape); }
.slot-t { display: grid; gap: 4px; min-width: 0; }
.slot-t strong { font-family: var(--f-display); font-weight: 400; font-size: 24px; line-height: 1.15; transition: color .25s; overflow-wrap: anywhere; }
.slot-t span { color: var(--muted); font-size: 14px; }
.slot-s { font-size: 13px; color: var(--muted); white-space: nowrap; }
.slot-s .on { color: var(--iodine); font-family: var(--f-mono); font-weight: 500; text-transform: uppercase; letter-spacing: .06em; font-size: 11px; }
.slot a:hover strong { color: var(--drape); }
.slot a[aria-current="page"] strong { color: var(--drape); }
@media (max-width: 760px) { .slot a { grid-template-columns: minmax(0, 1fr); } .slot-s { white-space: normal; } }

@media (prefers-reduced-motion: reduce) {
  #dScope .shot.on img, .l-state.on .dot, .cp-flag, .verdict { animation: none !important; }
  .feed, #dScope .shot, .opt .bar { transition: none; }
}
