/* Draft Day — dark scoreboard theme, built to read from a couch across the room. */

:root {
  color-scheme: dark;
  --bg: #0a0f1c;
  --panel: #131a2e;
  --panel-2: #1a2340;
  --line: #263156;
  --text: #e8edf8;
  --muted: #8b96b3;
  --gold: #f5b800;
  --green: #2edc7c;
  --red: #ff5d6c;
  --blue: #4da3ff;
  --radius: 12px;
  --bg-glow: #16224a;
  --topbar-bg: rgba(10, 15, 28, 0.9);
  --on-gold: #221a00;
  --gold-tint: #2a2410;
  --green-tint: #10301f;
  --cell-empty: rgba(255, 255, 255, 0.02);
  --overlay: rgba(4, 7, 16, 0.94);
  --overlay-soft: rgba(5, 8, 16, 0.82);
}

/* follow the device's light/dark setting; accents re-picked for contrast on
   a light ground, not naively inverted */
@media (prefers-color-scheme: light) {
  :root {
    color-scheme: light;
    --bg: #edf1f8;
    --panel: #ffffff;
    --panel-2: #e9eef7;
    --line: #c8d3e6;
    --text: #182238;
    --muted: #5c6b8a;
    --gold: #a87d00;
    --green: #158549;
    --red: #c92f40;
    --blue: #1e66c7;
    --bg-glow: #dce6f6;
    --topbar-bg: rgba(247, 249, 253, 0.92);
    --on-gold: #ffffff;
    --gold-tint: #f5eed6;
    --green-tint: #def1e5;
    --cell-empty: rgba(20, 40, 80, 0.03);
    --overlay: rgba(240, 244, 250, 0.95);
    --overlay-soft: rgba(24, 34, 56, 0.45);
  }
}

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

body {
  background: radial-gradient(1200px 600px at 70% -10%, var(--bg-glow) 0%, var(--bg) 55%);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  min-height: 100vh;
}

code { background: var(--panel-2); padding: 1px 5px; border-radius: 4px; font-size: 0.9em; }

/* ---------- top bar ---------- */

.topbar {
  display: flex; align-items: center; gap: 18px; flex-wrap: wrap;
  padding: 12px 20px;
  border-bottom: 1px solid var(--line);
  background: var(--topbar-bg);
  position: sticky; top: 0; z-index: 10;
  backdrop-filter: blur(6px);
}
.brand { display: flex; align-items: center; gap: 10px; }
.brand-ball { font-size: 28px; }
.brand-title { font-size: 20px; font-weight: 800; letter-spacing: 0.3px; }
.brand-sub { font-size: 11px; color: var(--muted); text-transform: uppercase; letter-spacing: 1.2px; }
.toolbar { margin-left: auto; display: flex; gap: 8px; align-items: center; }

.tabs { display: flex; gap: 4px; background: var(--panel); border: 1px solid var(--line); border-radius: 999px; padding: 4px; max-width: 100%; overflow-x: auto; scrollbar-width: none; }
.tabs::-webkit-scrollbar { display: none; }
#tabs-slot { min-width: 0; max-width: 100%; } /* phones: let the pill shrink and scroll instead of widening the page */
.tab {
  border: none; background: transparent; color: var(--muted);
  font-weight: 700; font-size: 14px; padding: 8px 16px; border-radius: 999px; cursor: pointer;
}
.tab:hover:not(:disabled) { color: var(--text); }
.tab.active { background: var(--gold); color: var(--on-gold); }
.tab:disabled { opacity: 0.35; cursor: not-allowed; }

/* ---------- buttons ---------- */

.btn {
  border: 1px solid var(--line); background: var(--panel-2); color: var(--text);
  font-weight: 700; font-size: 14px; padding: 9px 16px; border-radius: 9px; cursor: pointer;
}
.btn:hover:not(:disabled) { border-color: var(--gold); }
.btn:disabled { opacity: 0.4; cursor: not-allowed; }
.btn.primary { background: var(--gold); border-color: var(--gold); color: var(--on-gold); }
.btn.primary:hover:not(:disabled) { filter: brightness(1.08); }
.btn.ghost { background: transparent; }
.btn.small { padding: 5px 10px; font-size: 12px; }
.btn.big { padding: 14px 26px; font-size: 17px; }
.btn.danger { color: var(--red); }
.file-btn { position: relative; overflow: hidden; display: inline-block; }
.file-btn input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.btn-row { display: flex; gap: 10px; margin: 12px 0; flex-wrap: wrap; align-items: center; }

/* ---------- layout ---------- */

main { padding: 20px; max-width: 1500px; margin: 0 auto; }
.panel {
  background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 18px;
}
.panel h2 { font-size: 15px; text-transform: uppercase; letter-spacing: 1px; color: var(--gold); margin: 14px 0 10px; }
.panel h2:first-child { margin-top: 0; }
.panel.narrow { max-width: 720px; margin: 0 auto; }
.panel.center { text-align: center; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.auction-grid { display: grid; grid-template-columns: 340px 1fr 380px; gap: 18px; align-items: start; }
.hint { color: var(--muted); font-size: 13px; line-height: 1.5; margin: 6px 0 12px; }
.muted { color: var(--muted); }
.small-txt { font-size: 11px; }

/* ---------- forms ---------- */

input[type="text"], input[type="number"], textarea, select {
  background: var(--bg); border: 1px solid var(--line); color: var(--text);
  border-radius: 8px; padding: 9px 11px; font-size: 14px; font-family: inherit; width: 100%;
}
input:focus, textarea:focus, select:focus { outline: none; border-color: var(--gold); }
input:disabled { opacity: 0.5; }
.field { display: block; font-size: 12px; color: var(--muted); font-weight: 700; margin-bottom: 12px; }
.field input { margin-top: 5px; }
.field-row { display: flex; gap: 12px; }
textarea { resize: vertical; font-family: ui-monospace, Menlo, monospace; font-size: 12.5px; }

.min-grid { display: flex; gap: 8px; flex-wrap: wrap; }
.min-grid .field.mini { flex: 0 0 auto; margin-bottom: 4px; text-align: center; }
.min-grid .field.mini input { width: 58px; text-align: center; }

.team-list { margin-bottom: 10px; }
.team-row { display: flex; gap: 8px; margin-bottom: 6px; }
.team-row .seen { align-self: center; font-size: 12px; color: var(--muted); white-space: nowrap; font-variant-numeric: tabular-nums; }
.team-row .seen.ok { color: var(--green); font-weight: 600; }
.start-row { margin-top: 20px; display: flex; align-items: center; gap: 10px; font-weight: 700; }

/* ---------- chips & lists ---------- */

.chip {
  display: inline-block; min-width: 34px; text-align: center;
  font-size: 10.5px; font-weight: 800; letter-spacing: 0.5px;
  padding: 3px 5px; border-radius: 5px; color: #fff;
}
.pos-QB { background: #d64550; }
.pos-RB { background: #2f9e5f; }
.pos-WR { background: #3878c7; }
.pos-TE { background: #d98324; }
.pos-K  { background: #7d5bc6; }
.pos-DST { background: #5a6478; }

.searchbar { margin-bottom: 10px; }
.search-wrap { position: relative; }
.search-wrap input { padding-right: 34px; }
.search-clear {
  position: absolute; right: 6px; top: 50%; transform: translateY(-50%);
  width: 24px; height: 24px; border: none; border-radius: 50%; cursor: pointer;
  background: var(--line); color: var(--muted); font-size: 12px; line-height: 1;
}
.search-clear:hover { color: var(--text); }
.posfilter { display: flex; gap: 4px; margin-top: 8px; flex-wrap: wrap; }
.pf {
  border: 1px solid var(--line); background: transparent; color: var(--muted);
  font-size: 11px; font-weight: 800; padding: 4px 9px; border-radius: 999px; cursor: pointer;
}
.pf.on { background: var(--blue); border-color: var(--blue); color: #fff; }

.pool-list { max-height: 520px; overflow-y: auto; display: flex; flex-direction: column; gap: 4px; scrollbar-gutter: stable; padding-right: 10px; }
.pool-row, .mini-row {
  display: flex; align-items: center; gap: 8px; width: 100%;
  background: var(--panel-2); border: 1px solid transparent; border-radius: 8px;
  color: var(--text); padding: 8px 10px; font-size: 13.5px; text-align: left; cursor: pointer;
}
.mini-row { cursor: default; margin-bottom: 4px; }
.pool-row:hover:not(:disabled) { border-color: var(--gold); }
.pool-row.on-block { border-color: var(--gold); background: var(--gold-tint); }
.pool-row.cant { opacity: 0.35; cursor: not-allowed; }
.pname { font-weight: 700; flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mini-row .pname { flex: 1; }
.val { color: var(--green); font-weight: 800; font-variant-numeric: tabular-nums; }

.custom-player { margin-top: 12px; font-size: 13px; color: var(--muted); }
.custom-player summary { cursor: pointer; font-weight: 700; }
.cp-row { display: flex; gap: 6px; margin-top: 10px; }
.cp-row input, .cp-row select { width: auto; flex: 1; min-width: 0; padding: 7px 8px; }
.cp-row input#cp-nfl { flex: 0 0 58px; }
.cp-row input#cp-value { flex: 0 0 64px; }

/* ---------- auction center ---------- */

.phase-strip {
  font-size: 13px; font-weight: 700; letter-spacing: 1px; color: var(--muted);
  display: flex; align-items: center; flex-wrap: wrap; gap: 4px 0; margin-bottom: 16px;
}
/* each fact is one unbreakable segment — on a phone whole segments wrap, never "1 / of 8" */
.phase-strip .seg { display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; }
.phase-strip .seg + .seg::before { content: "•"; margin: 0 8px; }
.live-dot {
  width: 10px; height: 10px; border-radius: 50%; background: var(--red);
  display: inline-block; animation: pulse 1.4s infinite;
}
.live-dot.snake { background: var(--green); }
@keyframes pulse { 0%,100% { opacity: 1; } 50% { opacity: 0.35; } }

.on-the-block, .empty-block, .on-the-clock { text-align: center; padding: 18px 10px 6px; }
.otb-label { font-size: 12px; letter-spacing: 3px; color: var(--gold); font-weight: 800; margin-bottom: 8px; }
.otb-name { font-size: 44px; font-weight: 900; line-height: 1.1; }
.otb-meta { color: var(--muted); font-size: 15px; margin: 10px 0 4px; display: flex; gap: 8px; justify-content: center; align-items: center; }
.empty-block { padding: 60px 30px; }

/* Nomination rotation: big "on the clock" card fills the empty block between sales. */
.empty-block.nominating { padding: 44px 20px 30px; }
.empty-block.nominating .otb-label { color: var(--green); }
.empty-block.nominating .otb-name { color: var(--green); }
.nom-next { color: var(--muted); font-size: 15px; margin-top: 14px; }
.nom-next b { color: var(--text); }
.nom-by { font-size: 13px; font-weight: 700; color: var(--muted); letter-spacing: 0.5px; margin-top: 2px; }
.nom-list { max-width: 420px; }
.nom-list li::before { color: var(--green); }

.bid-row { display: flex; justify-content: center; align-items: center; gap: 8px; margin: 18px 0 6px; }
.bid-box {
  display: flex; align-items: center; font-size: 34px; font-weight: 900; color: var(--green);
  background: var(--bg); border: 2px solid var(--green); border-radius: 10px; padding: 2px 10px;
}
.bid-box input {
  width: 90px; border: none; background: transparent; color: var(--green);
  font-size: 34px; font-weight: 900; text-align: center; padding: 4px 0;
}
.bid-box input:focus { outline: none; }
.bid-box input::-webkit-outer-spin-button, .bid-box input::-webkit-inner-spin-button { -webkit-appearance: none; }
.sold-hint { color: var(--muted); font-size: 13px; margin-bottom: 14px; }

.high-bid { text-align: center; font-size: 15px; color: var(--muted); margin: 2px 0 8px; letter-spacing: 0.5px; }
.high-bid.live { color: var(--text); font-weight: 700; }
.high-bid.live b { color: var(--gold); font-size: 18px; }

.team-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 8px; margin-bottom: 16px; }
/* Whole tile = two big click zones: left half +1, right half +5.
   Team name + max float on top and pass clicks through. */
.team-bid-tile {
  position: relative; height: 78px; overflow: hidden;
  background: var(--panel-2); border: 1px solid var(--line); border-radius: 10px;
  text-align: center;
}
.team-bid-tile.high { border-color: var(--gold); background: var(--gold-tint); box-shadow: 0 0 0 1px var(--gold); }
.team-bid-tile.cant { opacity: 0.35; }
.team-bid-tile.high .tb-max { color: var(--gold); font-weight: 800; }
.tb-half {
  position: absolute; top: 0; bottom: 0; left: 0; width: 50%;
  border: none; background: transparent; color: var(--green);
  font-weight: 900; font-size: 16px; cursor: pointer;
  display: flex; align-items: flex-end; justify-content: center; padding-bottom: 7px;
}
.tb-half.five { left: 50%; border-left: 1px dashed var(--line); }
.tb-half:hover:not(:disabled) { background: rgba(46, 220, 124, 0.12); }
.tb-half:disabled { opacity: 0.25; cursor: not-allowed; }
.tb-info { position: absolute; top: 8px; left: 0; right: 0; pointer-events: none; z-index: 2; padding: 0 6px; }
/* The hammer is an ACTION, not a status — outline until you commit (hover fills it). */
.hammer-btn {
  display: block; margin: 2px auto 14px;
  background: transparent; border: 1.5px solid var(--gold); color: var(--gold);
}
.hammer-btn:hover:not(:disabled) { background: var(--gold); color: var(--on-gold); }
.hammer-btn:disabled { opacity: 0.35; }
.team-bid {
  background: var(--panel-2); border: 1px solid var(--line); border-radius: 10px;
  color: var(--text); padding: 10px 8px; cursor: pointer; text-align: center;
}
.team-bid:hover:not(:disabled) { border-color: var(--green); background: var(--green-tint); }
.team-bid.cant { opacity: 0.35; cursor: not-allowed; }
.tb-name { display: block; font-weight: 800; font-size: 14px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tb-max { display: block; font-size: 11px; color: var(--green); margin-top: 3px; font-variant-numeric: tabular-nums; }
.tb-needs { color: var(--gold); white-space: normal; }
.otb-needs { font-size: 13px; font-weight: 700; color: var(--gold); margin-top: 6px; }
.otb-needs.ok { color: var(--green); }
.needs-line { font-size: 10.5px; font-weight: 600; color: var(--gold); margin-top: 2px; white-space: normal; }
.needs-line.ok { color: var(--muted); }
.end-early { margin: 6px auto 0; display: block; }

/* ---------- standings ---------- */

.standings { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.standings th {
  text-align: left; color: var(--muted); font-size: 11px; text-transform: uppercase;
  letter-spacing: 0.8px; padding: 6px 8px; border-bottom: 1px solid var(--line);
}
.standings td { padding: 7px 8px; border-bottom: 1px solid var(--line); font-variant-numeric: tabular-nums; }
.standings .tname { font-weight: 700; }
.score.pos { color: var(--green); font-weight: 800; }
.score.neg { color: var(--red); font-weight: 800; }
.pos { color: var(--green); }
.neg { color: var(--red); }

/* ---------- snake order ---------- */

.order-list { list-style: none; counter-reset: pick; margin: 10px 0; }
.order-list li {
  counter-increment: pick;
  display: flex; align-items: center; gap: 12px;
  background: var(--panel-2); border: 1px solid var(--line); border-radius: 10px;
  padding: 10px 14px; margin-bottom: 6px; font-size: 15px;
}
.order-list li::before {
  content: counter(pick);
  font-weight: 900; font-size: 18px; color: var(--gold); min-width: 26px;
}
.order-list .tname { font-weight: 800; flex: 1; }
.order-list.compact li { padding: 6px 12px; font-size: 13.5px; font-weight: 700; }
.order-list.compact li.done { opacity: 0.45; }
.order-list li.otc { border-color: var(--green); background: var(--green-tint); }
.order-btns { display: flex; gap: 4px; }

.next-up { text-align: center; color: var(--muted); font-size: 14px; margin: 4px 0 10px; }
.recent { max-height: 260px; overflow-y: auto; }
/* Your-team list on the snake tab: the whole roster, no scroll clamp. */
.recent.full-roster { max-height: none; overflow-y: visible; }

/* ---------- board ---------- */

.board-panel { overflow: hidden; }
.board-scroll { overflow-x: auto; }
/* Fixed layout: every team column gets an equal share of the full width, so ALL teams
   are always on screen at once (built for the TV / screen share). Names ellipsize;
   hover a cell for the full name + price. */
.board { border-collapse: collapse; font-size: 12.5px; width: 100%; table-layout: fixed; }
.board col.rcol { width: 60px; }
.board th, .board td {
  border: 1px solid var(--line); padding: 5px 6px; text-align: left;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.board thead th {
  background: var(--panel-2); font-size: 12px; position: sticky; top: 0;
  white-space: normal; word-break: break-word; vertical-align: top;
}
.board tbody th { background: var(--panel-2); color: var(--gold); font-weight: 800; }
.board td.empty { background: var(--cell-empty); }
.board td.acell { background: rgba(245, 184, 0, 0.07); }
.board .chip { min-width: 26px; padding: 2px 3px; font-size: 9px; }
.cell-price { color: var(--gold); font-weight: 800; margin-left: 2px; }

/* Board on phones: one team at a time (see renderBoard). Hidden on wide screens. */
.board-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; flex-wrap: wrap; }
.board-head h2 { margin: 0 0 10px; }
.board-toggle, .board-phone { display: none; }
.team-chips { display: flex; gap: 6px; overflow-x: auto; padding: 2px 0 8px; margin-bottom: 6px; -webkit-overflow-scrolling: touch; }
.team-chips .pf { white-space: nowrap; flex: 0 0 auto; font-size: 12px; padding: 6px 11px; }
.team-chips .pf.mine:not(.on) { border-color: var(--gold); color: var(--gold); }
.team-card-head { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; flex-wrap: wrap; margin: 2px 0 8px; font-size: 16px; }
.team-card-head .muted { font-size: 12.5px; }
.team-slots { display: flex; flex-direction: column; gap: 4px; }
.team-slot { display: flex; align-items: center; gap: 8px; background: var(--panel-2); border: 1px solid transparent; border-radius: 8px; padding: 8px 10px; font-size: 14px; }
.team-slot.acell { background: rgba(245, 184, 0, 0.10); border-color: rgba(245, 184, 0, 0.25); }
.team-slot.empty { opacity: 0.45; }
.team-slot .slot-num { color: var(--gold); font-weight: 800; min-width: 1.6em; text-align: right; font-variant-numeric: tabular-nums; }
.team-slot .slot-name { flex: 1; min-width: 0; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.team-slot .cell-price { font-size: 15px; }

@media (max-width: 900px) {
  .board-toggle { display: inline-block; }
  .board-panel:not(.show-grid) .board-phone { display: block; }
  .board-panel:not(.show-grid) .board-scroll { display: none; }
  /* "Full grid" on a small screen: real column widths, swipe sideways, slot column pinned */
  .board { width: calc(36px + var(--cols, 10) * 120px); min-width: 100%; }
  .board col.rcol { width: 36px; }
  .board thead th:first-child, .board tbody th { position: sticky; left: 0; z-index: 2; }
}

/* ---------- live/spectator ---------- */

.conn { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; color: var(--muted); margin-right: 6px; white-space: nowrap; }
.conn-dot { width: 9px; height: 9px; border-radius: 50%; background: var(--muted); display: inline-block; }
.conn-dot.ok { background: var(--green); }
.conn-dot.bad { background: var(--red); animation: pulse 1.4s infinite; }

.pool-row.inert { cursor: default; }
.pool-row.inert:hover { border-color: transparent; }
.spectator-bid { font-size: 30px; font-weight: 900; color: var(--green); margin: 16px 0 4px; }
.waiting { margin-top: 8vh; padding: 60px 30px; }

/* ---------- toast ---------- */

.toast {
  position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%) translateY(80px);
  background: var(--panel-2); border: 1px solid var(--gold); color: var(--text);
  padding: 12px 22px; border-radius: 999px; font-weight: 700; font-size: 14px;
  opacity: 0; transition: all 0.25s ease; z-index: 100; pointer-events: none;
  max-width: 90vw; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }
.toast.error { border-color: var(--red); }

/* ---------- responsive ---------- */

@media (max-width: 1100px) {
  .auction-grid { grid-template-columns: 1fr 1fr; }
  .standings-panel { grid-column: 1 / -1; }
}
@media (max-width: 760px) {
  .grid-2, .auction-grid { grid-template-columns: 1fr; }
  .otb-name { font-size: 32px; }
  .topbar { gap: 10px; }
  .tab { padding: 7px 11px; font-size: 13px; white-space: nowrap; }
  /* phones: lead with the action, then scores; the big pool list goes last */
  .block-panel { order: -2; }
  .pool-panel { order: -1; } /* Available players above Auction value (Mike/Steve 08/23) */
}

/* ---------- live device bidding ---------- */

/* going-once countdown (auction block, live mode) */
.countdown { display: flex; align-items: center; gap: 14px; margin: 14px auto 4px; max-width: 420px; }
.count-track { flex: 1; height: 10px; background: var(--panel-2); border: 1px solid var(--line); border-radius: 999px; overflow: hidden; }
.count-bar { height: 100%; width: 0%; background: var(--green); border-radius: 999px; transition: width 0.2s linear; }
.count-num { min-width: 74px; text-align: right; font-size: 26px; font-weight: 900; color: var(--green); font-variant-numeric: tabular-nums; }
.count-num.going { color: var(--red); animation: going-pulse 0.5s ease infinite alternate; }
@keyframes going-pulse { from { opacity: 1; } to { opacity: 0.45; } }

/* team-device raise pad: two huge thumb targets */
.bid-pad { display: flex; gap: 12px; margin: 14px auto 6px; max-width: 420px; }
.bid-big {
  flex: 1; padding: 22px 10px 18px; font-size: 34px; font-weight: 900; cursor: pointer;
  background: var(--panel-2); color: var(--green); border: 2px solid var(--green);
  border-radius: var(--radius); line-height: 1.05; touch-action: manipulation;
}
.bid-big span { display: block; font-size: 14px; font-weight: 700; color: var(--muted); margin-top: 6px; }
.bid-big.five { color: var(--gold); border-color: var(--gold); }
.bid-big:not(:disabled):active { transform: scale(0.96); }
.bid-big:disabled { opacity: 0.35; cursor: default; }
.bid-note { font-size: 14px; font-weight: 700; color: var(--muted); margin-bottom: 6px; }
.bid-note.mine { color: var(--green); }

/* it's-your-turn glow (nomination card / snake on-the-clock) */
.empty-block.nominating.mine, .on-the-clock.mine {
  outline: 2px solid var(--green); outline-offset: -2px; border-radius: var(--radius);
  animation: my-turn 1.2s ease infinite alternate;
}
@keyframes my-turn { from { box-shadow: 0 0 0 rgba(46, 220, 124, 0); } to { box-shadow: 0 0 26px rgba(46, 220, 124, 0.35); } }

/* commissioner overrides + setup controls */
.live-overrides { justify-content: center; margin-top: 12px; }
.check { display: flex; align-items: center; gap: 10px; font-weight: 700; margin: 10px 0; cursor: pointer; }
.check input { width: 20px; height: 20px; accent-color: var(--green); }
.going-field { max-width: 220px; }

/* invite links (commissioner-only, secrets!) */
.invite-list { margin-top: 10px; border: 1px solid var(--line); border-radius: var(--radius); padding: 10px 14px; }
.invite-row { display: flex; flex-wrap: wrap; gap: 4px 12px; align-items: baseline; padding: 5px 0; border-bottom: 1px solid var(--line); }
.invite-row:last-of-type { border-bottom: 0; }
.invite-row .tname { font-weight: 700; min-width: 140px; }
.invite-row code { font-size: 12px; color: var(--blue); word-break: break-all; user-select: all; }

/* ---------- auto-pilot ---------- */
#auto-panel[hidden] { display: none; }
.auto-panel { display: flex; flex-direction: column; gap: 12px; }
.auto-panel textarea {
  width: 100%; resize: vertical; min-height: 140px;
  background: var(--bg); border: 1px solid var(--line); border-radius: 10px;
  color: var(--text); padding: 10px 12px; font: inherit; font-size: 14px; line-height: 1.45;
}
.auto-panel textarea:focus { outline: none; border-color: var(--blue); }
.auto-status { font-size: 13px; color: var(--muted); min-height: 18px; }
.auto-status.on { color: var(--green); }
.auto-status.err { color: var(--red); }
.auto-chip-row { margin-top: 10px; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.auto-badge {
  display: inline-block; font-size: 10px; font-weight: 800; letter-spacing: 0.6px;
  padding: 1px 6px; border-radius: 999px; vertical-align: 1px;
  background: rgba(46, 220, 124, 0.14); color: var(--green); border: 1px solid rgba(46, 220, 124, 0.4);
}
.auto-badge.starting { background: rgba(245, 184, 0, 0.12); color: var(--gold); border-color: rgba(245, 184, 0, 0.4); }

/* ---------- bought list (💰 filter) ---------- */
.sold-row .paid-over { color: var(--red); }
.sold-row .paid-under { color: var(--green); }

/* ---------- commissioner pause ---------- */
.btn.pause-on { border-color: var(--gold); color: var(--gold); }
#pause-banner[hidden] { display: none; }
#pause-banner {
  flex-basis: 100%; /* its own row at the bottom of the sticky top bar */
  background: var(--gold); color: var(--on-gold);
  font-weight: 800; font-size: 15px; letter-spacing: 0.3px; text-align: center;
  padding: 10px 14px; border-radius: 8px;
  animation: pause-pulse 1.8s ease-in-out infinite;
}
@keyframes pause-pulse { 0%, 100% { filter: brightness(1); } 50% { filter: brightness(0.82); } }
@media (prefers-reduced-motion: reduce) { #pause-banner { animation: none; } }
body.paused .bid-big { opacity: 0.4; }

/* ---------- roast break ---------- */
#roast-screen[hidden] { display: none; }
#roast-screen {
  position: fixed; inset: 0; z-index: 70;
  background: var(--overlay);
  display: flex; align-items: center; justify-content: center; padding: 20px;
}
.roast-box {
  max-width: 720px; width: 100%; text-align: center;
  display: flex; flex-direction: column; gap: 18px; align-items: center;
}
.roast-box h1 { font-size: 34px; letter-spacing: 1px; }
#roast-lines {
  width: 100%; text-align: left; margin: 0; padding-left: 1.3em;
  list-style: disc; display: flex; flex-direction: column; gap: 12px;
}
.roast-line { font-size: 19px; line-height: 1.5; color: var(--text); }
.roast-line::marker { color: var(--gold); }
.roast-count { font-size: 15px; color: var(--muted); }
.roast-count span { font-weight: 800; color: var(--gold); font-variant-numeric: tabular-nums; }

/* 🏆 RANKS pool filter */
.rank-row .rank-num{color:var(--gold);font-weight:700;min-width:1.4em;text-align:right}
.rank-row.mine{border-left:3px solid var(--gold)}

/* two-line board cells: player name / NFL team + price */
.board td .cell-top { white-space: nowrap; }
.board td .cell-sub { font-size: 11px; color: var(--muted); margin-top: 2px; padding-left: 2px; }

/* ---------- live mini-bar: follow the auction from any tab ---------- */
/* flex-basis 100% + min-width 0: its own full-width row of the wrapping topbar,
   allowed to shrink so the nowrap text ellipsizes instead of pushing off-screen */
#live-bar { flex-basis: 100%; min-width: 0; display: flex; gap: 8px; align-items: stretch; padding: 6px 0 2px; }
#live-bar[hidden] { display: none; }
.lb-main { flex: 1; min-width: 0; display: flex; gap: 10px; align-items: center; text-align: left;
  background: var(--panel-2); border: 1px solid var(--line); border-radius: 10px; padding: 8px 12px;
  color: var(--text); font: inherit; cursor: pointer; }
.lb-main.mine { border-color: var(--green); background: rgba(46, 220, 124, 0.12); animation: lb-pulse 1.6s ease-in-out infinite; }
.lb-main.mine-high { border-color: var(--gold); }
.lb-tag { font-size: 10px; letter-spacing: 1px; color: var(--muted); text-transform: uppercase; white-space: nowrap; }
.lb-text { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 14px; }
.lb-sub { font-size: 12px; color: var(--muted); white-space: nowrap; font-variant-numeric: tabular-nums; }
/* price sits outside .lb-text so a long player/bidder name can never truncate it */
.lb-price { font-weight: 800; white-space: nowrap; font-variant-numeric: tabular-nums; }
.lb-main.mine-high .lb-price { color: var(--gold); }
.lb-clock { font-weight: 800; font-variant-numeric: tabular-nums; min-width: 34px; text-align: right; }
.lb-clock.going { color: var(--red); }
.lb-btns { display: flex; gap: 6px; }
.lb-bid { min-width: 56px; border-radius: 10px; border: 1px solid var(--green); background: rgba(46, 220, 124, 0.15);
  color: var(--green); font-weight: 800; font-size: 15px; cursor: pointer; }
.lb-bid.five { border-color: var(--gold); background: rgba(245, 184, 0, 0.15); color: var(--gold); }
.lb-bid:disabled { opacity: 0.35; cursor: default; }
@keyframes lb-pulse { 0%, 100% { box-shadow: 0 0 0 0 rgba(46, 220, 124, 0); } 50% { box-shadow: 0 0 0 4px rgba(46, 220, 124, 0.25); } }
/* Wide screens: don't stretch the pill across the whole row — that parked the
   +$1/+$5 buttons at the far right edge where they went unnoticed (Steve).
   FIXED pill width (not content-width): the +$1/+$5 buttons must never shift
   as player/bidder names change length — the text ellipsizes inside instead. */
@media (min-width: 900px) { .lb-main { flex: 0 1 620px; } }

/* ---------- short team names (narrow screens) ---------- */
/* teamNameHTML() renders both spans; CSS picks one. 900px matches the Board's
   phone breakpoint — the tightest team-name real estate. */
.tn-short { display: none; }
@media (max-width: 900px) {
  .tn-full { display: none; }
  .tn-short { display: inline; }
}
/* The full grid packs 10 columns, so its headers need short names well before
   the global 900px cutoff — full names there wrap to 3 lines around ~1100px. */
@media (max-width: 1400px) {
  table.board th .tn-full { display: none; }
  table.board th .tn-short { display: inline; }
}
.team-row .short-input { flex: 0 0 100px; }
