/* jamReel public site. One stylesheet for the home, about and show pages.
   Night-river palette: brass from the logo for anything you can act on,
   river teal for the quiet structure, one fixed color per instrument. */

:root {
  --bg: #0a0c0f;
  --bg-2: #0f1418;
  --panel: rgba(22, 27, 32, 0.82);
  --panel-solid: #151a1f;
  --raise: #1c232a;
  --line: #26303a;
  --line-2: #33404c;
  --text: #ecebe6;
  --muted: #8f99a3;
  --faint: #5d6872;
  --brass: #e2bd6a;
  --brass-2: #c9a24a;
  --brass-ink: #1a1306;
  --river: #6fa3a6;
  --trout: #e8836b;
  --ok: #8fd19e;

  --guitar: #f28c28;
  --keys: #b07cd8;
  --bass: #4aa3df;
  --drums: #e8574a;
  --vocals: #4cc38a;
  --crowd: #f1c40f;
  --horns: #1abc9c;
  --standout: #fdcb6e;
  --jams: #ff7675;
  --dynamics: #fd9644;
  --guests: #26de81;
  --transitions: #74b9ff;
  --talk: #8f99a3;
  --harmonica: #00cec9;
  --strings: #e84393;
  --flute: #a29bfe;
  --loud: #e2bd6a;
  --song: #2b3a48;

  --radius: 14px;
  --display: "Fraunces", Georgia, "Times New Roman", serif;
  --body: -apple-system, BlinkMacSystemFont, "Segoe UI", Inter, Roboto, sans-serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, monospace;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--text);
  background: var(--bg) url("art/water.svg") repeat;
  background-attachment: fixed;
  font: 16px/1.55 var(--body);
  -webkit-font-smoothing: antialiased;
}
body::before {
  content: "";
  position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background: radial-gradient(1200px 600px at 70% -10%, rgba(226, 189, 106, 0.08), transparent 60%),
              radial-gradient(900px 700px at 0% 110%, rgba(111, 163, 166, 0.08), transparent 60%);
}
a { color: var(--brass); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 3px; }
img, svg { display: block; max-width: 100%; }
code, kbd { font: 0.86em/1.4 var(--mono); color: var(--brass); background: var(--raise);
  padding: 1px 6px; border-radius: 6px; }
h1, h2, h3 { font-family: var(--display); font-weight: 600; letter-spacing: -0.01em; margin: 0; }
h1 { font-size: clamp(34px, 6vw, 60px); line-height: 1.02; }
h2 { font-size: clamp(24px, 3.2vw, 32px); line-height: 1.1; }
h3 { font-size: 19px; line-height: 1.25; }
p { margin: 0 0 12px; }
.muted { color: var(--muted); }
.eyebrow { font: 600 12px/1 var(--body); letter-spacing: 0.14em; text-transform: uppercase; color: var(--brass); }
.wrap { max-width: 1180px; margin: 0 auto; padding: 0 16px; }
@media (min-width: 720px) { .wrap { padding: 0 28px; } }
:focus-visible { outline: 2px solid var(--brass); outline-offset: 2px; border-radius: 6px; }

/* Top bar */
.topbar { position: sticky; top: 0; z-index: 20; backdrop-filter: blur(10px);
  background: rgba(10, 12, 15, 0.72); border-bottom: 1px solid rgba(38, 48, 58, 0.6); }
.topbar .wrap { display: flex; align-items: center; justify-content: space-between; height: 60px; gap: 16px; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--text); font: 600 20px/1 var(--display); }
.brand:hover { text-decoration: none; }
.brand img { width: 34px; height: 34px; border-radius: 9px; object-fit: cover; }
.nav { display: flex; gap: 4px; }
.nav a { color: var(--muted); padding: 8px 12px; border-radius: 999px; font-size: 15px; }
.nav a:hover, .nav a[aria-current="page"] { color: var(--text); background: var(--raise); text-decoration: none; }

/* Buttons and fields */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; cursor: pointer;
  font: 600 15px/1 var(--body); padding: 13px 20px; border-radius: 999px; border: 1px solid transparent;
  color: var(--brass-ink); background: linear-gradient(180deg, #f3d58a, var(--brass-2)); white-space: nowrap; }
.btn:hover { filter: brightness(1.06); text-decoration: none; }
.btn:disabled { opacity: 0.45; cursor: not-allowed; filter: none; }
.btn.ghost { color: var(--text); background: transparent; border-color: var(--line-2); }
.btn.ghost:hover { border-color: var(--brass); }
.btn.small { padding: 8px 14px; font-size: 14px; }
input[type="text"], input[type="url"], input[type="password"], textarea {
  width: 100%; color: var(--text); background: rgba(10, 12, 15, 0.7); border: 1px solid var(--line-2);
  border-radius: 12px; padding: 13px 14px; font: 15px/1.4 var(--body); }
input::placeholder, textarea::placeholder { color: var(--faint); }
input:focus, textarea:focus { outline: none; border-color: var(--brass); box-shadow: 0 0 0 3px rgba(226, 189, 106, 0.15); }
label.field { display: grid; gap: 6px; font-size: 13px; color: var(--muted); }

.panel { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.35); }
.chip { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; line-height: 1;
  padding: 6px 10px; border-radius: 999px; border: 1px solid var(--line-2); color: var(--muted); }
.dot { width: 8px; height: 8px; border-radius: 50%; background: currentColor; flex: none; }

/* ---------- Home ---------- */
.hero { position: relative; overflow: hidden; }
.hero-art { position: absolute; inset: 0; background: url("art/hero.svg") right center / cover no-repeat; }
.hero-art::after { content: ""; position: absolute; inset: 0;
  background: linear-gradient(90deg, var(--bg) 0%, rgba(10, 12, 15, 0.85) 34%, rgba(10, 12, 15, 0) 62%),
              linear-gradient(0deg, var(--bg) 0%, rgba(10, 12, 15, 0) 30%); }
.hero .wrap { position: relative; display: grid; gap: 28px; padding-top: 96px; padding-bottom: 150px; min-height: 560px; }
.hero-copy { max-width: 560px; }
.hero-copy h1 { margin: 14px 0 18px; }
.hero-copy h1 em { font-style: italic; color: var(--brass); }
.hero-copy .lede { font-size: 18px; color: #c9cdd1; max-width: 46ch; }
@media (max-width: 760px) {
  .hero-art { position: relative; height: 230px; inset: auto; background-position: 88% center; }
  .hero-art::after { background: linear-gradient(0deg, var(--bg) 0%, rgba(10, 12, 15, 0) 45%); }
  .hero .wrap { padding-top: 8px; padding-bottom: 96px; min-height: 0; }
}

.cast { position: relative; z-index: 2; margin-top: -84px; padding: 22px; display: grid; gap: 14px; }
.cast-body { display: grid; gap: 18px; align-items: start; }
@media (min-width: 900px) { .cast-body:has(.offline:not([hidden])) { grid-template-columns: 1.3fr 1fr; } }
.cast-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.cast-head h2 { font-size: 24px; }
.engine { color: var(--faint); }
.engine.on { color: var(--ok); border-color: rgba(143, 209, 158, 0.35); }
.engine.on .dot { box-shadow: 0 0 0 4px rgba(143, 209, 158, 0.15); }
.drop { position: relative; display: flex; flex-direction: column; gap: 10px;
  border: 1.5px dashed var(--line-2); border-radius: 14px; padding: 10px; transition: border-color 0.15s, background 0.15s; }
.drop.over { border-color: var(--brass); background: rgba(226, 189, 106, 0.06); }
.drop input { flex: 1 1 260px; border: none; background: transparent; padding: 10px 6px; font-size: 16px; }
.drop input:focus { box-shadow: none; }
.cast-more { display: grid; gap: 10px; }
.cast-more summary { cursor: pointer; color: var(--muted); font-size: 14px; }
.cast-more[open] summary { margin-bottom: 10px; }
.cast-msg { min-height: 1.4em; margin: 0; font-size: 14px; color: var(--muted); }
.cast-msg.err { color: var(--trout); }
.cast-msg.ok { color: var(--ok); }
.offline { display: grid; grid-template-columns: 84px 1fr; gap: 16px; align-items: center;
  padding: 14px; border-radius: 12px; background: rgba(10, 12, 15, 0.5); border: 1px solid var(--line); }
.offline img { width: 84px; }
.offline p { margin: 0 0 6px; font-size: 14px; color: var(--muted); }
.offline strong { color: var(--text); }
.offline .row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin-top: 6px; }
.offline input { width: 200px; padding: 7px 10px; font-size: 13px; }
.bob { animation: bob 3.2s ease-in-out infinite; transform-origin: center; }
@keyframes bob { 50% { transform: translateY(4px); } }

.section { padding: 56px 0 8px; }
.section-head { display: flex; align-items: end; justify-content: space-between; gap: 16px; margin-bottom: 20px; flex-wrap: wrap; }
.section-head p { margin: 6px 0 0; }
.title-mark { display: flex; align-items: center; gap: 12px; }
.title-mark img { width: 44px; }

.queue { display: grid; gap: 10px; }
.job { display: grid; grid-template-columns: 1fr auto; gap: 8px 16px; padding: 14px 16px; }
.job h3 { font: 600 16px/1.3 var(--body); }
.job .meta { font-size: 13px; color: var(--muted); }
.job .spark { grid-column: 1 / -1; height: 30px; width: 100%; }
.steps { display: flex; gap: 4px; flex-wrap: wrap; grid-column: 1 / -1; }
.step { font-size: 11px; padding: 4px 8px; border-radius: 999px; background: var(--raise); color: var(--faint); }
.step.done { color: var(--brass-ink); background: var(--brass-2); }
.step.running { color: var(--text); background: var(--line-2); animation: pulse 1.4s ease-in-out infinite; }
.step.error { color: #fff; background: #9b3b2f; }
@keyframes pulse { 50% { opacity: 0.55; } }

.sets { display: grid; gap: 18px; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); }
.set-card { display: grid; gap: 12px; padding: 20px; color: inherit; transition: transform 0.15s, border-color 0.15s; }
.set-card:hover { text-decoration: none; border-color: var(--brass-2); transform: translateY(-2px); }
.set-card h3 { font-size: 22px; }
.set-card .when { font-size: 13px; color: var(--muted); }
.set-card .stats { display: flex; gap: 14px; flex-wrap: wrap; font-size: 13px; color: var(--muted); }
.set-card .stats b { color: var(--text); font-weight: 600; }
.strip { position: relative; height: 46px; border-radius: 8px; background: rgba(10, 12, 15, 0.6); overflow: hidden; }
.strip .s { position: absolute; top: 6px; bottom: 6px; background: var(--song); border-radius: 4px; }
.strip .m { position: absolute; bottom: 6px; width: 3px; border-radius: 2px; }

.steps-band { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); }
.how { padding: 20px; }
.how .num { font: 600 13px/1 var(--mono); color: var(--brass); }
.how h3 { margin: 10px 0 8px; }
.how p { color: var(--muted); font-size: 15px; margin: 0; }

.footer { margin-top: 72px; padding: 28px 0 40px; border-top: 1px solid var(--line); color: var(--faint); font-size: 14px; }
.footer .wrap { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; }

/* ---------- Show page ---------- */
.show-head { padding: 36px 0 20px; display: grid; gap: 10px; }
.show-head h1 { font-size: clamp(30px, 5vw, 48px); }
.show-meta { display: flex; gap: 8px; flex-wrap: wrap; }
.show-grid { display: grid; gap: 24px; }
@media (min-width: 1060px) {
  .show-grid { grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); align-items: start; }
  .stage { position: sticky; top: 76px; }
}
.player { aspect-ratio: 16 / 9; background: #000; border-radius: var(--radius); overflow: hidden;
  border: 1px solid var(--line); }
.player iframe, .player video, .player > div { width: 100%; height: 100%; border: 0; display: block; }
.player .audio-only { display: grid; place-items: center; align-content: center; gap: 18px; padding: 24px;
  background: radial-gradient(closest-side, rgba(226, 189, 106, 0.14), transparent), #06090b; }
.player .audio-only img { width: 120px; }
.player .audio-only audio { width: min(520px, 100%); }

.timeline { margin-top: 14px; padding: 14px 14px 10px; }
.tl-row { display: grid; grid-template-columns: 64px 1fr; align-items: center; gap: 10px; height: 22px; }
.tl-row + .tl-row { margin-top: 4px; }
.tl-label { font-size: 11px; color: var(--muted); text-align: right; white-space: nowrap; }
.tl-track { position: relative; height: 100%; background: rgba(10, 12, 15, 0.55); border-radius: 5px; cursor: pointer; }
.tl-track .s { position: absolute; top: 2px; bottom: 2px; background: var(--song); border-radius: 4px;
  font-size: 10px; color: var(--muted); padding: 2px 5px; overflow: hidden; white-space: nowrap; border: 0; cursor: pointer; }
.tl-track .s:hover, .tl-track .s.on { background: #3a4c5e; color: var(--text); }
.tl-track .m { position: absolute; top: 3px; bottom: 3px; min-width: 5px; border-radius: 3px; border: 0; padding: 0;
  cursor: pointer; opacity: 0.85; }
.tl-track .m.maybe { opacity: 0.4; }
.tl-track .m:hover, .tl-track .m.on { opacity: 1; outline: 2px solid #fff; outline-offset: 1px; z-index: 2; }
.tl-axis { position: relative; height: 16px; margin-left: 74px; font-size: 10px; color: var(--faint); }
.tl-axis span { position: absolute; transform: translateX(-50%); }
.playhead { position: absolute; top: 14px; bottom: 26px; width: 2px; background: var(--brass);
  box-shadow: 0 0 8px var(--brass); pointer-events: none; display: none; }
.timeline { position: relative; }
.tl-tip { position: fixed; z-index: 50; pointer-events: none; background: var(--panel-solid); border: 1px solid var(--line-2);
  border-radius: 8px; padding: 6px 9px; font-size: 12px; max-width: 260px; display: none; }

.catch { display: grid; gap: 12px; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); }
.pick { position: relative; text-align: left; font: inherit; color: inherit; cursor: pointer; padding: 16px;
  border-radius: var(--radius); border: 1px solid var(--line); overflow: hidden;
  background: linear-gradient(160deg, rgba(226, 189, 106, 0.12), rgba(21, 26, 31, 0.9) 55%); }
.pick:hover, .pick.on { border-color: var(--brass); }
.pick .rank { font: 600 34px/1 var(--display); color: var(--brass); opacity: 0.9; }
.pick .what { font-weight: 600; margin: 8px 0 2px; }
.pick .t { font: 13px/1.3 var(--mono); color: var(--muted); }
.pick .why { font-size: 13px; color: var(--muted); margin-top: 8px; }
.pick .bar { position: absolute; left: 0; top: 0; bottom: 0; width: 4px; }

.filters { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin: 4px 0 14px; }
.filter { font: 14px/1 var(--body); color: var(--muted); background: transparent; cursor: pointer;
  border: 1px solid var(--line-2); border-radius: 999px; padding: 8px 12px; display: inline-flex; align-items: center; gap: 7px; }
.filter[aria-pressed="true"] { color: var(--text); background: var(--raise); border-color: var(--text); }
.filter .n { color: var(--faint); font-size: 12px; }
.toggle { margin-left: auto; display: inline-flex; gap: 8px; align-items: center; font-size: 14px; color: var(--muted); cursor: pointer; }
.toggle input { accent-color: var(--brass); width: 16px; height: 16px; }

.moments { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.moment { display: grid; grid-template-columns: 4px 1fr auto; gap: 0 14px; border-radius: 12px; overflow: hidden;
  background: var(--panel); border: 1px solid var(--line); }
.moment.on { border-color: var(--brass); }
.moment .rail { background: var(--c, var(--muted)); }
.moment .body { padding: 12px 0; min-width: 0; cursor: pointer; }
.moment .top { display: flex; gap: 10px; align-items: baseline; flex-wrap: wrap; }
.moment .t { font: 14px/1 var(--mono); color: var(--brass); }
.moment .what { font-weight: 600; }
.moment .song { font-size: 12px; color: var(--faint); }
.moment .why { font-size: 13px; color: var(--muted); margin-top: 4px; }
.moment .side { display: flex; flex-direction: column; align-items: end; justify-content: center; gap: 6px; padding: 10px 12px 10px 0; }
.tray { font-size: 11px; padding: 3px 8px; border-radius: 999px; border: 1px solid var(--line-2); color: var(--faint); }
.tray.confident { color: var(--ok); border-color: rgba(143, 209, 158, 0.4); }
.share { font-size: 12px; color: var(--faint); background: none; border: 0; cursor: pointer; padding: 2px; }
.share:hover { color: var(--brass); }
.notes { font-size: 13px; color: var(--faint); margin-top: 16px; }
.notes p { margin: 0 0 6px; }
.empty { color: var(--muted); padding: 18px; text-align: center; }

/* ---------- About ---------- */
.prose { max-width: 720px; }
.prose h2 { margin: 48px 0 14px; }
.prose p, .prose li { color: #c9cdd1; }
.prose ul, .prose ol { padding-left: 1.2em; }
.prose li { margin-bottom: 8px; }
.prose strong { color: var(--text); }
.pipeline { list-style: none; padding: 0 !important; display: grid; gap: 10px; counter-reset: p; }
.pipeline li { counter-increment: p; position: relative; padding: 12px 14px 12px 52px; margin: 0;
  background: var(--panel); border: 1px solid var(--line); border-radius: 12px; }
.pipeline li::before { content: counter(p); position: absolute; left: 14px; top: 12px; width: 26px; height: 26px;
  border-radius: 50%; display: grid; place-items: center; font: 600 13px/1 var(--mono);
  color: var(--brass-ink); background: var(--brass-2); }

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

/* ---------- Password screen ---------- */
html.locked body > *:not(#gate) { visibility: hidden; }
#gate { position: fixed; inset: 0; z-index: 100; display: grid; place-items: center; padding: 16px;
  background: rgba(10, 12, 15, 0.92) url("art/water.svg"); }
.gate-card { width: min(360px, 100%); padding: 28px 24px; display: grid; gap: 12px; justify-items: center; text-align: center; }
.gate-card img { width: 64px; }
.gate-card h1 { font-size: 30px; }
.gate-card p { margin: 0; color: var(--muted); }
.gate-card input, .gate-card .btn { width: 100%; }
.gate-card .gate-note { font-size: 14px; }
.gate-err { min-height: 1.3em; color: var(--trout) !important; font-size: 14px; }

input[type="file"] { color: var(--muted); font: 14px var(--body); }
input[type="file"]::file-selector-button { font: 600 13px var(--body); color: var(--text); background: var(--raise);
  border: 1px solid var(--line-2); border-radius: 999px; padding: 7px 12px; margin-right: 10px; cursor: pointer; }

/* Cast box: YouTube link | Upload a file */
.modes { display: flex; gap: 6px; flex-wrap: wrap; }
.mode { display: inline-flex; align-items: center; gap: 8px; cursor: pointer; font: 600 14px/1 var(--body);
  color: var(--muted); background: transparent; border: 1px solid var(--line-2); border-radius: 999px; padding: 9px 14px; }
.mode svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.mode .play { fill: currentColor; stroke: none; }
.mode[aria-selected="true"] { color: var(--text); background: var(--raise); border-color: var(--text); }
#tab-yt[aria-selected="true"] svg rect { stroke: #ff4e45; }
#tab-yt[aria-selected="true"] svg .play { fill: #ff4e45; }
.pane { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.pane input { flex: 1 1 240px; }
.pane-file { min-height: 64px; justify-content: center; border-radius: 10px; background: rgba(10, 12, 15, 0.4); padding: 10px; }
.yt-status { margin: 0; font-size: 13px; color: var(--muted); display: flex; gap: 8px; align-items: center; }
.yt-status .dot { color: var(--faint); }
.yt-status.on .dot { color: var(--ok); }
.drop .pane input { border: 1px solid var(--line-2); background: rgba(10, 12, 15, 0.7); padding: 12px 14px; }
.drop .pane input:focus { border-color: var(--brass); }

/* ---------- Stems mixer (logic ported from 2kfest.com/houseband) ---------- */
.mixer { margin-top: 12px; padding: 14px; display: grid; gap: 12px; }
.mix-head { display: flex; gap: 12px; align-items: flex-start; justify-content: space-between; flex-wrap: wrap; }
.mix-head h3 { margin: 0 0 2px; }
.mix-help { margin: 0; font-size: 13px; max-width: 46ch; }
.mix-mode { display: inline-flex; align-items: center; gap: 0; font-size: 13px; }
.mix-mode > span { margin-right: 8px; }
.mix-mode button { font: 600 13px var(--sans, inherit); color: var(--muted); background: var(--raise); border: 1px solid var(--line-2);
  padding: 6px 12px; cursor: pointer; }
.mix-mode button:first-of-type { border-radius: 999px 0 0 999px; }
.mix-mode button:last-of-type { border-radius: 0 999px 999px 0; border-left: 0; }
.mix-mode button.on { color: var(--brass-ink); background: var(--brass); border-color: var(--brass); }
.stems { display: grid; gap: 10px; }
.stem { display: grid; grid-template-columns: 70px 36px 36px 1fr; gap: 8px; align-items: center; position: relative; }
.stem.dimmed { opacity: 0.42; }
.stem-name { font-size: 13px; color: var(--text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ms { font: 700 12px var(--mono); color: var(--muted); background: var(--raise); border: 1px solid var(--line-2);
  border-radius: 8px; height: 30px; cursor: pointer; }
.ms[data-act="mute"].on { color: #1a0f0d; background: var(--trout); border-color: var(--trout); }
.ms[data-act="solo"].on { color: var(--brass-ink); background: var(--brass); border-color: var(--brass); }
.vol { width: 100%; accent-color: var(--brass); }
.stem-load { position: absolute; left: 0; right: 0; bottom: -3px; height: 2px; background: transparent; pointer-events: none; }
.stem-load > span { display: block; height: 100%; width: 0; background: var(--river); transition: width .2s; }
.mix-foot { display: flex; gap: 10px; align-items: center; justify-content: space-between; flex-wrap: wrap;
  border-top: 1px solid var(--line); padding-top: 10px; }
.mix-status { margin: 0; font-size: 13px; color: var(--river); }
.mix-note { font-size: 12px; margin: 0; }
.mixer .mix-dl { display: flex; flex-wrap: wrap; gap: 8px; margin-left: auto; }
.mixer .mix-dl button:disabled { opacity: .45; cursor: default; }
.mixer.orig .stems { opacity: .55; }
