/**
 * File:        style.css
 * Path:        /setlist/style.css
 * Description: NEXUS LivePrompt styles — NX stacks theme (slate-950 base,
 *              green/blue radial corners, slate-900 cards, green action + sky info).
 *              Prompter view is tuned for STAGE readability: huge type,
 *              high contrast, green current line.
 * Version:     2.11.0 (2026-11-23) — FULL SCREEN on tablet/monitor (Blaine: "utilize the space you have"); NX layout + colours (Blaine: "does not match anything on the site"):
 *              workstation = Setlist and Library side by side in a wide container; words view = centred
 *              column; gold/amber accents replaced with NX green (action) + sky (info). Gold stays in the logo only.
 *              Prior: 2.9.0 (2026-11-11) — show bar / tonight bar / start-from panel + read-only (venue) view.
 *              Prior: 2.8.0 (2026-07-13) — standard NEXUS glass footer styles (verbatim from platform include) + view bottom padding.
 */

:root {
  --bg: #020617;            /* slate-950 */
  --card: #0f172a;          /* slate-900 */
  --card-edge: #1e293b;     /* slate-800 */
  --text: #e2e8f0;          /* slate-200 */
  --dim: #64748b;           /* slate-500 */
  --accent: #38bdf8;        /* sky-400 — NX info accent (gold is logo-only) */
  --accent-deep: #0369a1;   /* sky-700 */
  --green: #22c55e;
  --blue: #3b82f6;
  --red: #ef4444;
  --lyric-size: 44px;
}

* { box-sizing: border-box; margin: 0; padding: 0; -webkit-tap-highlight-color: transparent; }

html, body {
  height: 100%;
  background:
    radial-gradient(1000px 600px at 0% 0%, rgba(34, 197, 94, 0.10), transparent 60%),
    radial-gradient(1000px 600px at 100% 100%, rgba(59, 130, 246, 0.10), transparent 60%),
    var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  overflow: hidden;
}

.view { height: 100vh; height: 100dvh; display: flex; flex-direction: column; overflow-y: auto; }
[hidden] { display: none !important; }

/* ---------- top bar / brand ---------- */
.topbar { padding: 22px 20px 8px; text-align: center; }
.brand {
  font-size: 30px; font-weight: 800; letter-spacing: 1px;
  display: flex; align-items: center; justify-content: center; gap: 12px;
}
.brand-wide-logo {
  display: block;
  width: min(620px, calc(100vw - 96px));
  height: auto;
  margin: 0 auto;
  filter: drop-shadow(0 0 7px rgba(251, 191, 36, 0.28));
}

/* gold NEXUS stacked mark (nexus-mark.png) at 40px + sparkle.
   The art is gold-on-black; mix-blend-mode:screen drops the black glow
   into the near-black header (no hard alpha knockout, keeps the gold glow),
   and a soft glow pulse breathes on the metal. */
.brand-logo-wrap { position: relative; height: 58px; display: inline-block; }
.brand-logo {
  height: 58px; width: auto; display: block;
  mix-blend-mode: screen;
  filter: drop-shadow(0 0 3px rgba(251, 191, 36, 0.0));
  animation: nx-glow 4.5s ease-in-out infinite;
}
@keyframes nx-glow {
  0%, 100% { filter: drop-shadow(0 0 2px rgba(251, 191, 36, 0.15)); }
  50%      { filter: drop-shadow(0 0 7px rgba(251, 191, 36, 0.55)); }
}
/* star twinkle on the heartbeat X (center of the mark) */
.brand-spark {
  position: absolute; left: 50%; top: 26%;
  transform: translate(-50%, -50%) scale(0);
  font-size: 13px; line-height: 1; color: #fffbe8;
  text-shadow: 0 0 6px #fde68a, 0 0 14px var(--accent);
  pointer-events: none;
  animation: nx-spark 4.5s ease-in-out infinite;
}
@keyframes nx-spark {
  0%, 40%  { transform: translate(-50%,-50%) scale(0) rotate(0deg); opacity: 0; }
  48%      { transform: translate(-50%,-50%) scale(1.2) rotate(45deg); opacity: 1; }
  58%      { transform: translate(-50%,-50%) scale(0) rotate(90deg); opacity: 0; }
  100%     { transform: translate(-50%,-50%) scale(0); opacity: 0; }
}

.brand-app { color: #cbd5e1; font-weight: 300; }
.tagline { color: var(--dim); font-size: 14px; margin-top: 4px; }
.tagline em { color: var(--accent); font-style: normal; font-weight: 600; }

/* ---------- panels ---------- */
.panel {
  background: var(--card);
  border: 1px solid var(--card-edge);
  border-radius: 14px;
  margin: 14px auto; padding: 16px;
  width: min(680px, calc(100% - 24px));
}
.panel-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; }
.panel-head h2 { font-size: 15px; text-transform: uppercase; letter-spacing: 2px; color: var(--dim); }

/* ---------- song cards ---------- */
.song-list { list-style: none; }
.song-item {
  display: flex; align-items: center; gap: 10px;
  padding: 14px 12px; border-radius: 12px; cursor: pointer;
  background: #0b1222;
  border: 1px solid #1e293b;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.4);
  margin-bottom: 8px;
}
.song-item:hover { background: #131c30; border-color: #334155; }
.song-item.dragging {
  border-color: var(--accent);
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.6), 0 0 0 1px var(--accent);
  opacity: 0.95;
}
.song-item .drag {
  color: var(--dim); font-size: 22px; line-height: 1;
  padding: 8px 10px; margin: -8px -2px -8px -6px;
  cursor: grab; touch-action: none; user-select: none; -webkit-user-select: none;
}
.song-item.dragging .drag { cursor: grabbing; color: var(--accent); }
.song-item .num { color: var(--accent); font-weight: 700; width: 26px; text-align: right; }
.song-item .meta { flex: 1; min-width: 0; }
.song-item .t { display: block; font-size: 18px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.song-item .a { display: block; font-size: 13px; color: var(--dim); }
.song-item .edit { color: var(--dim); font-size: 13px; padding: 8px 10px; border-radius: 8px; }
.song-item .edit:hover { color: var(--text); background: #33415577; }
.song-empty { color: var(--dim); text-align: center; padding: 24px 0; }

/* ---------- setlist/library row controls ---------- */
.panel-sub { color: var(--dim); font-size: 13px; margin: -2px 0 10px; }
.set-count { color: var(--accent); font-size: 12px; letter-spacing: 1px; margin-left: 8px; }
.song-item .rowbtns { display: flex; align-items: center; gap: 4px; flex-shrink: 0; }
.song-item .rb {
  background: #1e293b; color: var(--dim);
  border: 1px solid #334155; border-radius: 8px;
  padding: 8px 9px; font-size: 13px; line-height: 1; cursor: pointer;
}
.song-item .rb:hover { color: var(--text); background: #33415577; }
.song-item .rb.toset { color: var(--accent); border-color: var(--accent-deep); font-weight: 700; white-space: nowrap; }
.song-item .rb.out:hover { color: #f87171; border-color: #7f1d1d; }
@media (max-width: 420px) {
  .song-item { gap: 8px; padding: 12px 8px; }
  .song-item .rb { padding: 7px 7px; font-size: 12px; }
  .song-item .edit { padding: 7px 6px; font-size: 12px; }
}

/* ---------- song length + break cards ---------- */
.song-item .dur {
  color: var(--dim); font-size: 13px; font-variant-numeric: tabular-nums;
  flex-shrink: 0; min-width: 38px; text-align: right;
}
.break-item {
  background: transparent;
  border: 1px dashed #334155;
  box-shadow: none;
}
.break-item:hover { background: #0f172a66; border-color: #475569; }
.break-item .t { color: var(--accent); font-size: 15px; letter-spacing: 2px; }
.break-item .a { font-size: 12px; }
.break-item .dur { color: var(--accent); }

/* ---------- show message ticker (main page only) ---------- */
.ticker {
  display: flex; align-items: center; gap: 10px;
  width: min(680px, calc(100% - 24px));
  margin: 10px auto 0; padding: 10px 14px;
  background: #082f49;
  border: 1px solid var(--accent-deep);
  border-radius: 12px;
  color: #bae6fd; font-size: 16px; font-weight: 600;
}
.ticker-label { flex-shrink: 0; }
.ticker-clip { flex: 1; overflow: hidden; }
.ticker-text { display: inline-block; white-space: nowrap; padding-left: 100%; will-change: transform; }
@keyframes ticker-scroll {
  from { transform: translateX(0); }
  to   { transform: translateX(-100%); }
}

/* ---------- 🚨 emergency takeover (any view) ---------- */
.emg {
  position: fixed; inset: 0; z-index: 1000;
  display: flex; align-items: center; justify-content: center;
  background: #450a0a;
  animation: emg-pulse 1.2s ease-in-out infinite;
  text-align: center; padding: 24px;
}
@keyframes emg-pulse {
  0%, 100% { background: #450a0a; }
  50%      { background: #7f1d1d; }
}
.emg-inner { max-width: 760px; }
.emg-icon { font-size: 64px; }
.emg-inner h1, .emg-inner h2 {
  color: #fff; font-size: 54px; letter-spacing: 8px; margin: 10px 0 14px;
  text-shadow: 0 0 24px rgba(0, 0, 0, 0.6);
}
.emg-sub {
  color: #fca5a5; font-size: 17px; text-transform: uppercase;
  letter-spacing: 3px; margin-bottom: 14px;
}
.emg-inner p {
  color: #fff; font-size: 32px; line-height: 1.45; font-weight: 700;
}
.emg-inner p::before { content: "“"; }
.emg-inner p::after  { content: "”"; }
.emg-btn {
  margin-top: 34px; padding: 16px 40px; font-size: 18px; letter-spacing: 2px;
  background: #fff; color: #7f1d1d; border-color: #fff; border-radius: 12px;
}
@media (max-width: 480px) {
  .emg-inner h1, .emg-inner h2 { font-size: 38px; letter-spacing: 6px; }
  .emg-inner p { font-size: 21px; }
}

/* ---------- STANDARD NEXUS glass footer ----------
   Copied verbatim from the platform's includes/nx-glass-footer.inc.php
   (static app can't PHP-include). Base .nx-bottom-nav positioning added
   here since the platform normally supplies it. */
.nx-bottom-nav {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 40;
  display: flex; flex-direction: column;
}
#setlistView { padding-bottom: calc(120px + env(safe-area-inset-bottom)); }
        .nx-bottom-nav.nx-glass-footer{
            height: calc(96px + env(safe-area-inset-bottom)) !important;
            padding: 3px 10px calc(3px + env(safe-area-inset-bottom)) !important;
            gap: 0 !important;
            background:
              linear-gradient(180deg, rgba(0,0,0,.78), rgba(0,0,0,.95)),
              radial-gradient(circle at 50% 18%, rgba(77,255,170,.12), transparent 50%),
              radial-gradient(circle at 50% 100%, rgba(36,255,146,.18), transparent 55%) !important;
            border-top: 1px solid rgba(255,255,255,.06) !important;
            box-shadow:
              inset 0 1px 0 rgba(255,255,255,.08),
              inset 0 0 0 1px rgba(255,255,255,.07),
              inset 0 0 0 2px rgba(34,197,94,.08),
              inset 0 -1px 0 rgba(34,197,94,.18),
              0 -16px 36px rgba(0,0,0,.72) !important;
            backdrop-filter: blur(18px) saturate(135%) !important;
            -webkit-backdrop-filter: blur(18px) saturate(135%) !important;
            overflow: hidden !important;
        }
        .nx-bottom-nav.nx-glass-footer::before{
            content:"";
            position:absolute;
            inset:1px;
            border:1px solid rgba(255,255,255,.06);
            pointer-events:none;
            opacity:.9;
        }
        .nx-bottom-nav.nx-glass-footer::after{
            content:"";
            position:absolute;
            left:0;
            right:0;
            bottom:0;
            height:12px;
            background: linear-gradient(180deg, transparent, rgba(34,197,94,.12));
            pointer-events:none;
        }
        .nx-bottom-nav.nx-glass-footer .nx-glass-track{
            position:relative;
            z-index:1;
            display:flex;
            align-items:stretch;
            justify-content:space-between;
            gap:0;
            width:100%;
            height:100%;
            border-radius:0;
            overflow:hidden;
        }
        .nx-bottom-nav.nx-glass-footer .nx-bottom-copy{
            display:flex;
            align-items:center;
            justify-content:center;
            width:100%;
            line-height:1.1;
            font-size: 9px;
            letter-spacing:.08em;
            color: rgba(170, 223, 189, .42);
            text-transform: uppercase;
            position:relative;
            z-index:1;
            margin-top: 3px;
        }
        .nx-bottom-nav.nx-glass-footer .nx-bottom-copy.nx-bottom-legal,
        .nx-bottom-nav.nx-glass-footer .nx-bottom-copy.nx-bottom-legal a{
            font-size: 8px !important;
            letter-spacing: .04em !important;
            text-transform: none !important;
            color: rgba(156, 216, 188, .36);
        }
        .nx-bottom-nav.nx-glass-footer .nx-bottom-copy a{
            color: inherit;
            text-decoration:none;
        }
        .nx-bottom-nav.nx-glass-footer .nx-bottom-copy a:hover,
        .nx-bottom-nav.nx-glass-footer .nx-bottom-copy a:focus-visible{
            text-decoration: underline;
        }
        .nx-bottom-nav.nx-glass-footer .nx-glass-item{
            flex:1 1 0;
            min-width:0;
            position:relative;
            display:flex;
            flex-direction:column;
            align-items:center;
            justify-content:center;
            gap:3px;
            padding: 1px 6px;
            color: rgba(220, 229, 232, .62);
            text-decoration:none;
            text-shadow:
              0 1px 0 rgba(0,0,0,.95),
              0 -1px 0 rgba(255,255,255,.12);
            transition: transform 140ms ease, color 140ms ease, filter 140ms ease;
            isolation:isolate;
        }
        .nx-bottom-nav.nx-glass-footer .nx-glass-item + .nx-glass-item{
            margin-left: 0;
        }
        .nx-bottom-nav.nx-glass-footer .nx-glass-item::before{
            content:"";
            position:absolute;
            inset:4px 3px 4px 3px;
            background: linear-gradient(180deg, rgba(255,255,255,.03), rgba(255,255,255,0));
            box-shadow:
              inset 0 1px 0 rgba(255,255,255,.08),
              inset 0 -1px 0 rgba(0,0,0,.65);
            opacity:.72;
            pointer-events:none;
            z-index:-1;
        }
        .nx-bottom-nav.nx-glass-footer .nx-glass-item:hover{
            transform: translateY(-1px);
            color: rgba(233, 255, 244, .86);
        }
        .nx-bottom-nav.nx-glass-footer .nx-glass-item:active{
            transform: translateY(1px);
        }
        .nx-bottom-nav.nx-glass-footer .nx-glass-item.active,
        .nx-bottom-nav.nx-glass-footer .nx-glass-item[aria-current="page"]{
            color: #d9ffe8;
        }
        .nx-bottom-nav.nx-glass-footer .nx-glass-item.active::after,
        .nx-bottom-nav.nx-glass-footer .nx-glass-item[aria-current="page"]::after{
            content:"";
            position:absolute;
            inset: 4px 2px 8px 2px;
            background: radial-gradient(circle at 50% 42%, rgba(45, 255, 154, .26), transparent 60%);
            filter: blur(10px);
            pointer-events:none;
            z-index:-2;
        }
        .nx-bottom-nav.nx-glass-footer .nx-glass-icon{
            width: 34px;
            height: 34px;
            display:inline-flex;
            align-items:center;
            justify-content:center;
            color: rgba(243, 247, 248, .58);
        }
        .nx-bottom-nav.nx-glass-footer .nx-glass-icon svg{
            display:none;
        }
        .nx-bottom-nav.nx-glass-footer .nx-glass-icon img{
            width: 100%;
            height: 100%;
            display:block;
            object-fit: contain;
            filter:
              drop-shadow(0 1px 0 rgba(0,0,0,.95))
              drop-shadow(0 -1px 0 rgba(255,255,255,.16))
              drop-shadow(0 0 6px rgba(34,197,94,.12));
        }
        .nx-bottom-nav.nx-glass-footer .nx-glass-item.active .nx-glass-icon,
        .nx-bottom-nav.nx-glass-footer .nx-glass-item[aria-current="page"] .nx-glass-icon{
            color: #bbffe2;
        }
        .nx-bottom-nav.nx-glass-footer .nx-glass-item.active .nx-glass-icon img,
        .nx-bottom-nav.nx-glass-footer .nx-glass-item[aria-current="page"] .nx-glass-icon img{
            filter:
              drop-shadow(0 1px 0 rgba(0,0,0,.98))
              drop-shadow(0 -1px 0 rgba(255,255,255,.22))
              drop-shadow(0 0 10px rgba(34,197,94,.3));
        }
        .nx-bottom-nav.nx-glass-footer .nx-glass-icon-home{
            width: 42px;
            height: 42px;
        }
        .nx-bottom-nav.nx-glass-footer .nx-glass-icon-home svg{
            display:none;
        }
        .nx-bottom-nav.nx-glass-footer .nx-glass-icon-home img{
            filter:
              drop-shadow(0 0 1px rgba(255,255,255,.48))
              drop-shadow(0 1px 0 rgba(0,0,0,.98))
              drop-shadow(0 0 14px rgba(35, 255, 151, .18));
        }
        .nx-bottom-nav.nx-glass-footer .nx-glass-label{
            font-size: 10px;
            font-weight: 700;
            letter-spacing: .03em;
            line-height: 1;
        }
        .nx-bottom-nav.nx-glass-footer .nx-glass-item.active .nx-glass-label,
        .nx-bottom-nav.nx-glass-footer .nx-glass-item[aria-current="page"] .nx-glass-label{
            color: #eafff4;
            text-shadow:
              0 1px 0 rgba(0,0,0,.94),
              0 0 9px rgba(37, 255, 151, .28);
        }

/* ---------- ⚙ settings ---------- */
.settings-btn {
  position: absolute; top: 16px; right: 14px;
  background: transparent; border: none; cursor: pointer;
  color: var(--dim); font-size: 24px; line-height: 1; padding: 8px;
}
.settings-btn:hover { color: var(--text); }
.settings-group { margin-bottom: 22px; }
.settings-group h3 {
  font-size: 13px; text-transform: uppercase; letter-spacing: 2px;
  color: var(--dim); margin-bottom: 10px;
}
.nx-account {
  color: #bae6fd; font-size: 14px; line-height: 1.5;
  background: #082f49; border: 1px solid var(--accent-deep);
  border-radius: 10px; padding: 10px 12px; margin-bottom: 10px;
}
#nxBandSel {
  width: 100%; background: #020617; color: var(--text);
  border: 1px solid #334155; border-radius: 10px; padding: 10px 12px;
  font-size: 15px; margin-bottom: 10px;
}

/* ---------- buttons ---------- */
.btn {
  background: #1e293b; color: var(--text);
  border: 1px solid #334155; border-radius: 10px;
  padding: 10px 16px; font-size: 15px; font-weight: 600; cursor: pointer;
}
.btn:active { transform: scale(0.97); }
/* primary action — NX green pill (class name kept: app.js/HTML reference it) */
.btn-gold { background: linear-gradient(to right, #22c55e, #4ade80); color: #022c22; border-color: #16a34a; }
.btn-danger { background: #7f1d1d; border-color: #b91c1c; color: #fecaca; }
.btn-ghost { background: transparent; border-color: transparent; color: #94a3b8; }
.btn-mode { min-width: 108px; }
.btn-mode.auto { background: #052e16; border-color: var(--green); color: var(--green); }
.btn-mode.manual { background: #172554; border-color: var(--blue); color: #93c5fd; }
.btn-mode.flow { background: #082f49; border-color: var(--accent); color: var(--accent); }

/* ---------- cloud ---------- */
.cloud-row { display: flex; gap: 8px; }
.cloud-row input {
  flex: 1; background: #020617; color: var(--text);
  border: 1px solid #334155; border-radius: 10px; padding: 10px 12px; font-size: 15px;
}
.cloud-msg { color: var(--green); font-size: 13px; margin-top: 8px; min-height: 16px; }
.cloud-msg.err { color: var(--red); }

/* ---------- microphone picker ---------- */
.mic-pick-row { display: flex; gap: 8px; }
.mic-pick-row select {
  flex: 1; min-width: 0; background: #020617; color: var(--text);
  border: 1px solid #334155; border-radius: 10px; padding: 10px 12px; font-size: 15px;
}
.mic-vu {
  height: 12px; margin-top: 10px; background: #1e293b;
  border-radius: 6px; overflow: hidden;
}
.mic-vu .vu-bar {
  height: 100%; width: 0%;
  background: linear-gradient(90deg, var(--green), var(--accent));
  transition: width 60ms linear;
}
.mic-hint { color: var(--dim); font-size: 12px; margin-top: 8px; line-height: 1.4; }
.support-warn {
  width: min(680px, calc(100% - 24px)); margin: 0 auto 20px;
  background: #082f49; border: 1px solid var(--accent-deep); border-radius: 12px;
  padding: 12px 14px; font-size: 14px; color: #bae6fd;
}

/* ---------- editor modal ---------- */
.modal {
  position: fixed; inset: 0; z-index: 50;
  background: rgba(2, 6, 23, 0.85); backdrop-filter: blur(4px);
  display: flex; align-items: flex-start; justify-content: center; padding: 10px;
}
.modal-card {
  /* flex column: header + scrollable body + PINNED action row, so the
     Save/Cancel buttons are always reachable on small screens even with
     the keyboard up */
  position: relative; width: min(640px, 100%);
  max-height: calc(100dvh - 20px);
  display: flex; flex-direction: column;
  background: var(--card); border: 1px solid #334155; border-radius: 16px;
  padding: 16px;
}
.modal-body { flex: 1; overflow-y: auto; min-height: 0; padding-bottom: 4px; }
.lbl-note { color: #475569; font-size: 11px; }
.search-row { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; }
.find-msg { font-size: 13px; color: var(--dim); }
.find-msg.ok { color: var(--green); }
.find-msg.err { color: var(--red); }
.modal-x {
  position: absolute; top: 10px; right: 10px;
  width: 40px; height: 40px; border-radius: 10px;
  background: #1e293b; color: #cbd5e1; border: 1px solid #334155;
  font-size: 18px; cursor: pointer;
}
.modal-card h2 { margin-bottom: 14px; font-size: 20px; }
.modal-card label { display: block; font-size: 13px; color: var(--dim); margin-bottom: 12px; }
.modal-card input, .modal-card textarea {
  display: block; width: 100%; margin-top: 5px;
  background: #020617; color: var(--text);
  border: 1px solid #334155; border-radius: 10px;
  padding: 10px 12px; font-size: 16px; font-family: inherit;
}
.modal-card textarea { resize: vertical; line-height: 1.5; }
.modal-actions {
  display: flex; gap: 8px; flex-shrink: 0;
  padding-top: 10px; border-top: 1px solid var(--card-edge);
}
.modal-actions .spacer { flex: 1; }

/* ---------- prompter ---------- */
#prompterView { background: #000; }
.prompter-bar {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 12px;
  background: linear-gradient(180deg, #0f172a, #020617);
  border-bottom: 1px solid var(--card-edge);
  flex-shrink: 0;
}
.prompter-song { flex: 1; min-width: 0; text-align: center; }
.p-title { font-weight: 700; font-size: 16px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.p-artist { font-size: 12px; color: var(--dim); }
.prompter-controls { display: flex; align-items: center; gap: 6px; }

.mic-wrap { display: flex; align-items: center; gap: 5px; margin-right: 4px; }
.mic-dot { width: 10px; height: 10px; border-radius: 50%; background: #334155; }
.mic-dot.live { background: var(--red); box-shadow: 0 0 8px var(--red); animation: pulse 1.2s infinite; }
@keyframes pulse { 50% { opacity: 0.5; } }
.vu { width: 44px; height: 8px; background: #1e293b; border-radius: 4px; overflow: hidden; }
.vu-bar { height: 100%; width: 0%; background: linear-gradient(90deg, var(--green), var(--accent)); transition: width 80ms linear; }

.lyrics-scroll {
  /* NOTE: no CSS scroll-behavior:smooth here — bursts of programmatic
     smooth scrolls (rapid speech interim results) wedge the native
     animation and pin scrollTop. app.js does its own rAF glide.
     position:relative so line offsetTop is relative to the scroller. */
  position: relative;
  flex: 1; overflow-y: auto;
  padding: 0 4vw;
}
.lyrics-pad-top { height: 30vh; }
.lyrics-pad-bottom { height: 60vh; }
.lyrics-scroll { --k: 1; --ls: calc(var(--lyric-size) * var(--k)); }
.lyrics-box { text-align: center; }   /* full width of the screen, centred lines */
.lyric-line {
  font-size: var(--ls);
  line-height: 1.35;
  font-weight: 700;
  color: #475569;                 /* upcoming: readable slate */
  padding: 0.12em 0;
  transition: color 200ms, transform 200ms;
  transform-origin: center center;
}
.lyric-line.past { color: #1e293b; }         /* sung: fade way down */
.lyric-line.current {
  color: #4ade80;                 /* NX green — the line being sung */
  text-shadow: 0 0 24px rgba(34, 197, 94, 0.35);
  transform: scale(1.03);
}
.lyric-line.next { color: #e2e8f0; }
.lyric-gap { height: 0.8em; }
.lyric-marker {
  /* stage direction ("[Instrumental Break]") — never sung, never current */
  font-size: calc(var(--ls) * 0.45);
  font-weight: 600; font-style: italic;
  color: #166534; letter-spacing: 1px;
  padding: 0.5em 0;
}
.lyric-end {
  color: var(--green); font-size: 24px; letter-spacing: 4px;
  text-transform: uppercase; padding: 1em 0;
}

.status-strip {
  display: flex; justify-content: space-between; align-items: center;
  padding: 8px 14px; font-size: 13px; color: var(--dim);
  background: #020617; border-top: 1px solid var(--card-edge);
  flex-shrink: 0;
}
.status-strip .listening { color: var(--green); }
.status-strip .err { color: var(--red); }

@media (max-width: 640px) {
  :root { --lyric-size: 34px; }
  .brand { font-size: 24px; }
  .btn { padding: 9px 12px; font-size: 14px; }
}

/* ---------- SHOW mode (2026-11-11): one booking = one show ---------- */
.show-bar {
  display: flex; flex-wrap: wrap; align-items: center; gap: 6px 12px;
  width: min(680px, calc(100% - 24px));
  margin: 10px auto 0; padding: 10px 14px;
  background: #0b1220; border: 1px solid #334155; border-left: 4px solid var(--accent);
  border-radius: 12px; color: var(--text); font-size: 15px; text-decoration: none;
}
.show-bar .sb-main { flex: 1; min-width: 200px; }
.show-bar .sb-main b { color: var(--accent); }
.show-bar .sb-sub { display: block; color: #94a3b8; font-size: 13px; margin-top: 2px; }
.show-bar .sb-link { color: var(--accent); font-weight: 700; text-decoration: none; white-space: nowrap; }
.show-bar.err { border-left-color: var(--red); color: #fecaca; }
.show-bar.tonight { cursor: pointer; }
.show-start-btns { display: flex; flex-wrap: wrap; gap: 8px; }
/* venue view: the show set is read-only (only the band edits) */
.ro #addBreakBtn, .ro #libPanel, .ro .song-item .drag,
.ro .song-item .rowbtns, .ro .edit-hint { display: none !important; }


/* ---------- tablet + monitor: USE THE WHOLE SCREEN (2026-11-23) ----------
   Blaine: the phone column is for phones only. From tablet width up the
   Setlist and Library sit side by side edge to edge, and everything —
   rows, buttons, and above all the words — gets bigger with the screen so
   it reads from a distance on stage. A−/A+ still fine-tunes the words. */
.set-cols { display: block; }
@media (min-width: 768px) {
  .ticker, .show-bar, .support-warn, .panel.show-start { width: calc(100% - 32px); }
  .set-cols {
    display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 16px; align-items: start;
    width: calc(100% - 32px); margin: 0 auto;
  }
  .set-cols .panel { width: auto; margin: 14px 0; }
  .ro .set-cols { grid-template-columns: minmax(0, 1fr); }  /* venue view: no Library */
  .lyrics-scroll { --k: 1.25; }
  .song-item .t { font-size: 20px; }
  .p-title { font-size: 20px; } .p-artist { font-size: 14px; }
}
@media (min-width: 1300px) {
  .lyrics-scroll { --k: 1.5; }
  .set-cols { gap: 20px; }
  .set-cols .panel { padding: 22px; }
  .panel-head h2 { font-size: 18px; }
  .panel-sub, .set-count { font-size: 15px; }
  .song-item { padding: 18px 16px; gap: 14px; margin-bottom: 10px; }
  .song-item .t { font-size: 26px; }
  .song-item .a { font-size: 16px; }
  .song-item .num { font-size: 22px; width: 34px; }
  .song-item .dur { font-size: 18px; }
  .song-item .rb, .song-item .edit { font-size: 16px; padding: 10px 12px; }
  .break-item .t { font-size: 20px; } .break-item .a { font-size: 15px; }
  .btn { font-size: 17px; padding: 12px 20px; }
  .ticker { font-size: 20px; } .show-bar { font-size: 18px; } .show-bar .sb-sub { font-size: 15px; }
  .p-title { font-size: 24px; } .p-artist { font-size: 16px; }
  .status-strip { font-size: 16px; }
  .modal-card { width: min(1000px, 100%); }
  .modal-card textarea { min-height: 42vh; }
}
@media (min-width: 1700px) {
  .lyrics-scroll { --k: 2; }
  .set-cols { gap: 24px; }
  .set-cols .panel { padding: 28px; }
  .panel-head h2 { font-size: 22px; }
  .panel-sub, .set-count { font-size: 18px; }
  .song-item { padding: 22px 20px; }
  .song-item .t { font-size: 34px; }
  .song-item .a { font-size: 20px; }
  .song-item .num { font-size: 28px; width: 44px; }
  .song-item .dur { font-size: 22px; }
  .song-item .rb, .song-item .edit { font-size: 19px; padding: 12px 14px; }
  .break-item .t { font-size: 24px; } .break-item .a { font-size: 18px; }
  .btn { font-size: 20px; padding: 14px 24px; }
  .ticker { font-size: 26px; } .show-bar { font-size: 22px; } .show-bar .sb-sub { font-size: 18px; }
  .p-title { font-size: 30px; } .p-artist { font-size: 19px; }
  .status-strip { font-size: 19px; }
  .modal-card { width: min(1300px, 100%); }
}

/* ---------- Add Song: bigger search box + search-as-you-type list (2026-11-23) ---------- */
.modal-card input.search-big { font-size: 22px; padding: 14px 16px; font-weight: 600; }
.suggest {
  margin: -4px 0 14px; border: 1px solid #334155; border-radius: 12px;
  background: #020617; overflow: hidden;
}
.suggest-item {
  display: flex; flex-direction: column; gap: 2px; width: 100%; text-align: left;
  background: transparent; border: 0; border-bottom: 1px solid var(--card-edge);
  padding: 12px 16px; cursor: pointer; color: var(--text); font-family: inherit;
}
.suggest-item:last-child { border-bottom: 0; }
.suggest-item:hover, .suggest-item:focus { background: #0b2a1a; outline: none; }
.suggest-item .st { font-size: 18px; font-weight: 700; }
.suggest-item .sa { font-size: 14px; color: #94a3b8; }
@media (min-width: 1300px) {
  .modal-card input.search-big { font-size: 26px; padding: 16px 18px; }
  .suggest-item .st { font-size: 22px; } .suggest-item .sa { font-size: 16px; }
}

/* ---------- FLOW key = play / pause (2026-11-23) ---------- */
.btn-mode.flow { min-width: 132px; padding: 12px 18px; font-size: 17px; font-weight: 800; }
.btn-mode.flow.paused { background: linear-gradient(to right, #22c55e, #4ade80); color: #022c22; border-color: #16a34a; }
@media (min-width: 1300px) { .btn-mode.flow { min-width: 170px; font-size: 21px; padding: 14px 24px; } }
/* phone: the words-view bar wraps so the song title gets its own row and
   the buttons are not crushed (was squeezed before this change too) */
@media (max-width: 640px) {
  .prompter-bar { flex-wrap: wrap; row-gap: 6px; }
  .prompter-song { order: -1; flex: 0 0 100%; }
  .prompter-controls { flex: 1; justify-content: flex-end; }
}

/* ---------- SONG CARD in Add / Edit Song (2026-11-23) ---------- */
.song-card {
  display: grid; grid-template-columns: 96px minmax(0, 1fr); gap: 12px 16px; align-items: start;
  background: rgba(2, 6, 23, 0.35); border: 1px solid rgba(148, 163, 184, 0.25);
  border-radius: 14px; padding: 14px; margin-bottom: 14px;
}
.sc-art { width: 96px; height: 96px; border-radius: 10px; overflow: hidden; background: #020617; border: 1px solid #334155; }
.sc-art img { width: 100%; height: 100%; object-fit: cover; display: block; }
.sc-art-empty { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; color: #334155; font-size: 40px; }
.sc-fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 12px; }
.modal-card .sc-fields label { margin-bottom: 10px; }
.sc-media { grid-column: 1 / -1; display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.sc-media:not(:has(> :not([hidden]))) { display: none; }
.sc-link { color: var(--accent); font-weight: 700; font-size: 15px; text-decoration: none; }
.sc-link:hover { text-decoration: underline; }
/* list rows: small album cover beside the text */
.suggest-item { flex-direction: row; align-items: center; gap: 12px; }
.suggest-item .stxt { display: flex; flex-direction: column; gap: 2px; min-width: 0; flex: 1; }
.suggest-item .st, .suggest-item .sa { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.suggest-item .sthumb { width: 46px; height: 46px; border-radius: 6px; flex-shrink: 0; background: #0f172a; }
.suggest-item.nothumb { padding-left: 74px; }
@media (max-width: 520px) {
  .song-card { grid-template-columns: 72px minmax(0, 1fr); gap: 10px 12px; padding: 12px; }
  .sc-art { width: 72px; height: 72px; }
  .sc-fields { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .sc-artist, .sc-album { grid-column: 1 / -1; }
}
@media (min-width: 1300px) {
  .song-card { grid-template-columns: 140px minmax(0, 1fr); padding: 18px; }
  .sc-art { width: 140px; height: 140px; }
  .sc-fields { grid-template-columns: 2fr 2fr 1fr 1fr; }
  .modal-card textarea { min-height: 30vh; }
}

/* ---------- ZOOM: full-screen set <-> edit mode (2026-11-23) ---------- */
.topbar { position: relative; }   /* buttons ride with the header instead of floating over the list */
.zoom-btn { position: absolute; top: 14px; left: 14px; z-index: 5; }
/* phone: under the tagline, so it never sits on the logo */
@media (max-width: 640px) { .zoom-btn { position: static; display: block; margin: 10px auto 0; } }
/* FULL SCREEN: only tonight's set, as big as the screen allows */
#setlistView.zoom .brand, #setlistView.zoom .tagline, #setlistView.zoom #libPanel,
#setlistView.zoom .nx-bottom-nav, #setlistView.zoom .edit-hint, #setlistView.zoom #addBreakBtn,
#setlistView.zoom .song-item .drag, #setlistView.zoom .song-item .rowbtns,
#setlistView.zoom .song-item .edit, #setlistView.zoom .support-warn, #setlistView.zoom .panel.show-start { display: none !important; }
#setlistView.zoom { padding-bottom: 16px; }
#setlistView.zoom .topbar { padding: 0; height: 72px; }
@media (max-width: 640px) { #setlistView.zoom .topbar { height: auto; padding: 4px 0 10px; } }
#setlistView.zoom .set-cols { display: block; width: calc(100% - 24px); margin: 0 auto; }
#setlistView.zoom .set-cols .panel { width: auto; margin: 0 0 12px; background: transparent; border: 0; padding: 0; }
#setlistView.zoom .panel-head { margin-bottom: 12px; }
#setlistView.zoom .panel-head h2 { font-size: clamp(16px, 1.6vw, 26px); }
#setlistView.zoom .set-count { font-size: clamp(13px, 1.3vw, 22px); }
#setlistView.zoom .song-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 460px), 1fr)); gap: 10px 14px; }
#setlistView.zoom .song-item { margin-bottom: 0; padding: clamp(14px, 1.4vw, 26px) clamp(14px, 1.4vw, 24px); }
#setlistView.zoom .song-item .t { font-size: clamp(22px, 2.6vw, 46px); }
#setlistView.zoom .song-item .a { font-size: clamp(14px, 1.3vw, 22px); }
#setlistView.zoom .song-item .num { font-size: clamp(20px, 2.2vw, 38px); width: auto; min-width: 1.4em; }
#setlistView.zoom .song-item .dur { font-size: clamp(15px, 1.5vw, 26px); }
#setlistView.zoom .break-item .t { font-size: clamp(18px, 1.8vw, 30px); }

/* ---------- Save / Open setlist file (2026-11-23) ---------- */
.set-tools { display: flex; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }
.ro #openSetBtn, .ro #saveSetBtn, #setlistView.zoom .set-tools { display: none !important; }

/* ---------- STACKED, full width (Blaine 2026-11-23, late) ----------
   "make the setlist take over the width and move the library to the bottom …
   back to the start, where library was on bottom and songlist on top."
   Setlist on top (one full-width column, run times showing), Library underneath
   so a short song can be grabbed when the show runs short. The full-screen
   button is taken off: it hid the times and the NEXUS menu and confused. */
#zoomBtn { display: none !important; }
@media (min-width: 768px) {
  .set-cols { display: block; width: calc(100% - 32px); margin: 0 auto; }
  .set-cols .panel { width: auto; margin: 14px 0; }
  /* Library underneath: songs side by side so more of them fit without scrolling */
  #libList { display: grid; grid-template-columns: repeat(auto-fill, minmax(380px, 1fr)); gap: 8px 14px; }
  #libList .song-item { margin-bottom: 0; }
  #libList .song-empty { grid-column: 1 / -1; }
}

/* ---------- layout choice: top/bottom or side by side (2026-11-23) ---------- */
.layout-btn { position: absolute; top: 14px; left: 14px; z-index: 5; }
@media (max-width: 767px) { .layout-btn { display: none; } }   /* a phone is always top/bottom */
@media (min-width: 768px) {
  #setlistView.sbs .set-cols { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 16px; align-items: start; }
  #setlistView.sbs #libList { display: block; }
  #setlistView.sbs #libList .song-item { margin-bottom: 8px; }
}

/* ---------- quick stage messages: drop-down from the ticker (2026-11-23) ---------- */
.ticker { cursor: pointer; }
.quick-panel {
  position: fixed; top: 10px; left: 50%; transform: translateX(-50%); z-index: 60;
  width: min(900px, calc(100% - 20px));
  background: rgba(15, 23, 42, 0.98); border: 1px solid rgba(148, 163, 184, 0.5);
  border-radius: 16px; padding: 14px; box-shadow: 0 28px 80px rgba(2, 6, 23, 0.9);
}
.quick-head { display: flex; align-items: center; justify-content: space-between; color: #bae6fd; font-weight: 700; font-size: 16px; margin-bottom: 10px; }
.quick-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.quick-btn { min-height: 76px; font-size: 18px; line-height: 1.2; white-space: normal; }
.quick-btn.help { background: #7f1d1d; border-color: #b91c1c; color: #fecaca; }
.quick-note { color: var(--green); font-size: 14px; margin-top: 10px; min-height: 18px; }
.quick-note.err { color: var(--red); }
.quick-in { display: block; width: 100%; margin-bottom: 8px; background: #020617; color: var(--text); border: 1px solid #334155; border-radius: 10px; padding: 10px 12px; font-size: 15px; }
@media (max-width: 640px) { .quick-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } .quick-btn { min-height: 64px; font-size: 15px; } }
@media (min-width: 1300px) { .quick-btn { min-height: 96px; font-size: 22px; } }
