/* =====================================================================
   Mock Draft — Premium Redesign (Broadcast Booth)
   ===================================================================== */

:root {
  --bg: #06070b;
  --surface: #0e0f12;
  --surface-2: #17191f;
  --surface-3: #20232b;
  --line: rgba(255, 255, 255, 0.1);
  --text: #f5f7ff;
  --muted: #969cab;
  --accent: #00f5ff;
  --accent-2: #ff4f68;
  --violet: #7c4dff;
  --lime: #8cff4f;
  --danger: #ff4f68;
  --qb: #ff3b4f;
  --rb: #00f5a0;
  --wr: #00b8ff;
  --te: #ff8a2a;
  --k: #a855ff;
  --def: #ff4fb8;
  --warn: #ffda2a;
  --gold: #ffb300;
  --panel-bg: rgba(13, 15, 20, 0.82);
  --rail-bg: rgba(4, 6, 11, 0.55);
  --hairline: rgba(255, 255, 255, 0.04);
  --shadow: 0 18px 50px rgba(0, 0, 0, 0.45);
  --font-heading: "Monument Extended", Impact, sans-serif;
}

/* ---- fonts ---- */
@font-face {
  font-family: "Monument Extended";
  src: url("fonts/PPMonumentExtended-Light.otf") format("opentype");
  font-weight: 300;
  font-display: swap;
}
@font-face {
  font-family: "Monument Extended";
  src: url("fonts/PPMonumentExtended-Regular.otf") format("opentype");
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: "Monument Extended";
  src: url("fonts/PPMonumentExtended-Black.otf") format("opentype");
  font-weight: 700 900;
  font-display: swap;
}

/* ---- keyframes ---- */
@keyframes mdsPulse { 0%,100% { opacity: 1 } 50% { opacity: .3 } }
@keyframes mdsRing {
  0%,100% { box-shadow: inset 0 0 0 2px var(--accent), 0 0 12px rgba(0,245,255,.15) }
  50%     { box-shadow: inset 0 0 0 2px var(--accent), 0 0 20px rgba(0,245,255,.45) }
}

/* ---- foundations ---- */
* { box-sizing: border-box; }

body {
  margin: 0;
  min-width: 320px;
  min-height: 100vh;
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background:
    radial-gradient(circle at 6% -6%, rgba(124,77,255,.20), transparent 30%),
    radial-gradient(circle at 99% 4%, rgba(0,245,255,.14), transparent 34%),
    linear-gradient(160deg, rgba(255,79,104,.05), transparent 42%),
    var(--bg);
}

::-webkit-scrollbar { width: 7px; height: 7px }
::-webkit-scrollbar-thumb { background: rgba(255,255,255,.14); border-radius: 4px }
::-webkit-scrollbar-track { background: transparent }

button, input { font: inherit; }

h1, h2, h3, .eyebrow, .panel-heading h2 {
  font-family: "Monument Extended", Impact, sans-serif;
  font-weight: 900;
  text-transform: uppercase;
}

h1, h2, p { margin-top: 0; }
h1 { margin-bottom: 0; }
h2 { margin-bottom: 0; font-size: 1rem; }

/* ===================== BUTTONS (FLAT) ===================== */
button {
  height: 38px;
  border-radius: 7px;
  cursor: pointer;
  transition: all .14s;
  font: 600 12px/1 Inter, sans-serif;
  letter-spacing: .03em;
  color: rgba(255,255,255,.82);
  background: rgba(255,255,255,.03);
  border: 1px solid rgba(255,255,255,.14);
  padding: 0 15px;
}
button:hover {
  color: #fff;
  border-color: rgba(0,245,255,.55);
  background: rgba(0,245,255,.06);
}
button:disabled { opacity: .35; cursor: not-allowed; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
:focus:not(:focus-visible) { outline: none; }
button.active {
  color: var(--accent);
  border-color: rgba(0,245,255,.45);
  background: rgba(0,245,255,.12);
}
button.btn-danger {
  color: #ff7184 !important;
  background: transparent !important;
  border: 1px solid rgba(255,79,104,.3) !important;
}
button.btn-danger:hover {
  color: #ff8e9d !important;
  border-color: #ff5f76 !important;
  background: rgba(255,79,104,.08) !important;
}

/* ===================== APP SHELL ===================== */
.app-shell {
  width: min(1680px, 100%);
  min-height: 100vh;
  margin: 0 auto;
  padding: 16px;
}

.draft-room {
  position: relative;
  /* Fixed shell height: panels scroll internally so the topbar never scrolls away */
  height: calc(100vh - 32px);
  height: calc(100dvh - 32px);
  min-height: 620px;
  display: grid;
  /* Sleeper-style vertical split: board ~43%, pool area ~57% of the space below
     the topbar (see REDESIGN/reference/SLEEPER_MEASUREMENTS.md). The board
     scrolls internally so it gives up height first on short screens. */
  grid-template-rows: auto minmax(180px, 0.75fr) minmax(300px, 1fr);
  gap: 14px;
  transition: grid-template-rows 180ms ease;
}

/* ===================== TOP BAR ===================== */
.topbar, .panel {
  background: var(--panel-bg);
  border: 1px solid rgba(255,255,255,.10);
  backdrop-filter: blur(16px);
  box-shadow: var(--shadow);
}

.topbar {
  display: grid;
  grid-template-columns: auto auto 1fr auto;
  align-items: center;
  gap: 30px;
  padding: 14px 20px;
  border-radius: 12px;
  /* Above the board so the overflow menu isn't painted over, below modals (z 20+) */
  position: relative;
  z-index: 15;
}

/* Sound-effects toggle */
.sfx-toggle-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  padding: 0;
  border-radius: 9px;
  border: 1px solid rgba(255,255,255,.14);
  background: rgba(255,255,255,.03);
  color: rgba(255,255,255,.6);
  cursor: pointer;
  transition: all .14s;
  flex: 0 0 auto;
}
.sfx-toggle-btn:hover { color: #fff; border-color: rgba(0,245,255,.5); background: rgba(0,245,255,.06); }
.sfx-toggle-btn.muted { color: rgba(255,255,255,.35); }
.sfx-toggle-btn svg { width: 18px; height: 18px; }

.logo-wrap { display: flex; flex-direction: column; gap: 0; }
.site-logo { height: 80px; width: auto; display: block; margin: -24px 0 -20px -10px; }

.eyebrow {
  margin: 0;
  font: 300 9.5px/1 "Monument Extended", Impact, sans-serif;
  letter-spacing: .24em;
  text-transform: uppercase;
  color: var(--accent);
}

/* ---- controls overflow menu ---- */
.controls-more { position: relative; display: flex; }
.more-btn {
  width: 38px;
  height: 38px;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(255,255,255,.7);
}
.more-btn:hover { color: #fff; }
.more-menu {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  z-index: 30;
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 6px;
  min-width: 168px;
  background: #17191f;
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 12px;
  box-shadow: 0 14px 44px rgba(0,0,0,.6), 0 0 0 1px rgba(255,255,255,.04);
}
.more-menu[hidden] { display: none; }
.more-menu button {
  width: 100%;
  height: 38px;
  justify-content: flex-start;
  text-align: left;
  border: none;
  background: transparent;
  padding: 0 12px;
}
.more-menu button:hover { background: rgba(255,255,255,.07); border: none; color: #fff; }
.more-menu button:disabled { opacity: .4; }
.more-menu button.btn-danger { border: none !important; }
.more-menu button.btn-danger:hover { background: rgba(255,79,104,.12) !important; }

/* ---- status cluster ---- */
.draft-status {
  display: flex;
  align-items: center;
  gap: 15px;
  text-align: left;
}

.pick-clock {
  position: relative;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background: conic-gradient(var(--accent) 100%, rgba(255,255,255,.09) 0);
  box-shadow: 0 0 18px rgba(0,245,255,.32);
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  transition: box-shadow .3s;
}
.pick-clock-inner {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: #0a0c12;
  display: flex;
  align-items: center;
  justify-content: center;
  font: 900 13px "Monument Extended", Impact, sans-serif;
  color: #fff;
}

/* ===================== TIME-CRITICAL (≤10s on your clock) ===================== */
/* Pulsing red screen-edge vignette — the unmissable "hurry up" cue. */
.draft-room.time-critical::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 60;
  animation: mdsCriticalEdge 1s ease-in-out infinite;
}
@keyframes mdsCriticalEdge {
  0%, 100% { box-shadow: inset 0 0 0 0 rgba(255,59,79,0), inset 0 0 0 0 rgba(255,59,79,0); }
  50% { box-shadow: inset 0 0 0 3px rgba(255,59,79,.7), inset 0 0 80px rgba(255,59,79,.32); }
}
/* Topbar pick clock flushes red and pulses. */
.draft-room.time-critical .pick-clock {
  animation: mdsCriticalClock 1s ease-in-out infinite;
}
.draft-room.time-critical .pick-clock-inner { color: #ff4f68; }
@keyframes mdsCriticalClock {
  0%, 100% { box-shadow: 0 0 10px rgba(255,59,79,.4); }
  50% { box-shadow: 0 0 0 5px rgba(255,59,79,.35), 0 0 26px rgba(255,59,79,.6); }
}
/* On the human's mobile "Your Turn" CTA, swap the cyan pulse for red. */
.draft-room.time-critical .controls #startBtn.your-turn {
  background: #ff4f68;
  animation: mdsCriticalCta 1s ease-in-out infinite;
}
@keyframes mdsCriticalCta {
  0%, 100% { box-shadow: 0 0 0 0 rgba(255,59,79,.5); }
  50% { box-shadow: 0 0 0 8px rgba(255,59,79,0); }
}

.status-text { display: flex; flex-direction: column; gap: 5px; }
.pick-label {
  font: 700 10px "Monument Extended", Impact, sans-serif;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: rgba(255,255,255,.5);
}
.on-clock-row { display: flex; align-items: center; gap: 9px; }
.on-clock-name {
  font: 900 14px "Monument Extended", Impact, sans-serif;
  text-transform: uppercase;
  color: #fff;
}
.on-clock-pill {
  font: 700 7.5px "Monument Extended", Impact, sans-serif;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: #04141a;
  background: var(--accent);
  border-radius: 4px;
  padding: 3px 6px;
}
.progress-row { display: flex; align-items: center; gap: 9px; }
.progress-track {
  width: 148px;
  height: 4px;
  border-radius: 2px;
  background: rgba(255,255,255,.1);
  overflow: hidden;
}
.progress-fill {
  height: 100%;
  border-radius: 2px;
  background: linear-gradient(90deg, var(--lime), var(--accent));
}
.progress-label {
  font: 700 9px "Monument Extended", Impact, sans-serif;
  letter-spacing: .05em;
  color: rgba(255,255,255,.45);
}

/* hide old status elements */
.draft-status > span,
.draft-status > strong,
.draft-status > small { display: none; }

/* ---- controls ---- */
.controls {
  display: flex;
  align-items: center;
  gap: 12px;
  justify-self: end;
  flex-wrap: wrap;
  justify-content: flex-end;
}
.btn-group {
  display: flex;
  align-items: center;
  gap: 6px;
  background: none;
  padding: 0;
}
.controls button {
  height: 34px;
  font-size: 11px;
  padding: 0 12px;
}
.btn-group button {
  border-radius: 7px;
}
.btn-divider {
  width: 1px;
  height: 22px;
  background: rgba(255,255,255,.12);
  flex: 0 0 auto;
}

/* primary button (Start) */
.btn-group-primary button:first-child,
#startBtn {
  font-weight: 700;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: #03100f;
  background: var(--accent);
  border: none;
  padding: 0 18px;
}
.btn-group-primary button:first-child:hover,
#startBtn:hover { background: #fff; box-shadow: none; }
.btn-group-primary button:disabled {
  background: rgba(255,255,255,.08);
  color: rgba(255,255,255,.25);
  cursor: not-allowed;
  pointer-events: none;
}

/* ===================== BOARD ===================== */
.board-wrap {
  position: relative;
  min-height: 0;
  overflow: auto;
  border-radius: 12px;
  background: var(--rail-bg);
  border: 1px solid rgba(255,255,255,.10);
  box-shadow: inset 0 0 60px rgba(0,0,0,.4);
}
.draft-board {
  width: 100%;
  min-width: 0;
  display: grid;
  align-items: stretch;
}
.team-col {
  display: grid;
  min-width: 0;
  border-right: 1px solid rgba(255,255,255,.035);
}
.team-col.my-col { background: rgba(0,245,255,.03); }

.team-head {
  position: sticky;
  top: 0;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  padding: 4px 3px;
  text-align: center;
  background: rgba(6,8,12,.96);
  border-bottom: 1px solid rgba(255,255,255,.08);
}
.team-head strong {
  display: block;
  max-width: 100%;
  overflow: hidden;
  font: 700 11px/1 Inter, sans-serif;
  color: #fff;
  text-transform: none;
  letter-spacing: normal;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.team-head.my-seat {
  box-shadow: inset 0 -3px 0 var(--accent), 0 0 18px rgba(0,245,255,.28);
}
.team-head.my-seat strong { color: var(--accent); }
.team-head.claimed-seat {
  box-shadow: inset 0 -3px 0 rgba(255,79,184,.86), 0 0 16px rgba(255,79,184,.34);
}
/* personality sub-label removed per spec */
.team-head span { display: none; }

/* ---- pick tiles ---- */
.pick-tile {
  display: grid;
  align-content: center;
  gap: 3px;
  padding: 8px;
  border-bottom: 1px solid rgba(255,255,255,.04);
  background: transparent;
  overflow: hidden;
  min-height: 0;
  max-height: 100%;
}
.pick-tile.on-clock {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  background: rgba(0,245,255,.1);
  outline: none;
  animation: mdsRing 1.8s ease-out infinite;
}
.pick-tile.on-clock .oc-label {
  font: 700 6.5px "Monument Extended", Impact, sans-serif;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--accent);
}
.pick-tile.on-clock .oc-pick {
  font: 900 12px "Monument Extended", Impact, sans-serif;
  color: #fff;
}

/* Tile-as-timer: the countdown lives on the on-clock tile. A color fill drains
   right->left with the clock; the time reads black over the fill (clipped copy)
   and white over the emptied dark part. */
.pick-tile.on-clock.oc-timer { position: relative; padding: 0; overflow: hidden; }
.oc-clock-fill {
  position: absolute;
  top: 0; bottom: 0; left: 0;
  z-index: 1;
  background: var(--accent);
  transition: width 1s linear, background .4s ease;
}
.pick-tile.oc-timer .oc-layer {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
}
.oc-layer-under { z-index: 0; }
.oc-layer-over  { z-index: 2; pointer-events: none; transition: clip-path 1s linear; }
.pick-tile.oc-timer .oc-time {
  font: 900 19px/1 "Monument Extended", Impact, sans-serif;
  letter-spacing: .01em;
}
.oc-layer-under .oc-time { color: #fff; }
.oc-layer-over  .oc-time { color: #04070c; }
.pick-tile.oc-timer .oc-label { font-size: 6px; }
/* Same treatment as the digits: black over the fill, white over the emptied side.
   (Extra specificity needed to beat .pick-tile.on-clock .oc-label's cyan.) */
.pick-tile.oc-timer .oc-layer-under .oc-label { color: #fff; }
.pick-tile.oc-timer .oc-layer-over  .oc-label { color: #04070c; }
.pick-tile.oc-timer .oc-pick-mini {
  font: 700 8px "Monument Extended", Impact, sans-serif;
  opacity: .8;
}
.oc-layer-under .oc-pick-mini { color: rgba(255,255,255,.75); }
.oc-layer-over  .oc-pick-mini { color: rgba(4,7,12,.8); }

/* While the tile carries the countdown, the little topbar ring is redundant —
   hide it on desktop and mobile alike. */
.draft-room.tile-clock-active .pick-clock { display: none; }
.pick-tile.filled { color: #071016; }

.pick-name {
  overflow: hidden;
  font-size: clamp(0.56rem, 0.72vw, 0.82rem);
  font-weight: 900;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.pick-meta {
  display: flex;
  justify-content: space-between;
  color: rgba(7,16,22,.72);
  font-size: clamp(0.48rem, 0.58vw, 0.68rem);
  font-weight: 800;
}
.empty-pick {
  font: 700 9px "Monument Extended", Impact, sans-serif;
  color: rgba(255,255,255,.16);
}

/* ===================== THE LOCKED PLAYER CARD (sexy mode) ===================== */
.pick-tile.sexy-tile {
  display: grid;
  grid-template-rows: 1fr auto;
  position: relative;
  overflow: hidden;
  background: #111218;
  border: 1px solid transparent;
  border-bottom: none;
  gap: 0;
  padding: 0;
  height: 100%;
}
.sexy-border-QB  { border-color: var(--qb); border-bottom-color: transparent; }
.sexy-border-RB  { border-color: var(--rb); border-bottom-color: transparent; }
.sexy-border-WR  { border-color: var(--wr); border-bottom-color: transparent; }
.sexy-border-TE  { border-color: var(--te); border-bottom-color: transparent; }
.sexy-border-K   { border-color: var(--k); border-bottom-color: transparent; }
.sexy-border-DEF { border-color: var(--def); border-bottom-color: transparent; }

.sexy-card-upper {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  gap: 1px;
  padding: 4px 5px 2px;
  flex: 1;
  min-height: 0;
  overflow: hidden;
}
.sexy-last-name {
  font: 900 13px "Monument Extended", Impact, sans-serif;
  line-height: 14px;
  min-height: 14px;
  letter-spacing: -.02em;
  color: #fff;
  white-space: nowrap;
  align-self: flex-start;
  transform-origin: left center;
  text-shadow: 1px 1px 4px rgba(0,0,0,.7);
  max-width: 100%;
}
.sexy-first-name {
  font: 700 7px/1.1 "Monument Extended", Impact, sans-serif;
  text-transform: uppercase;
  letter-spacing: .02em;
  color: rgba(255,255,255,.55);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  text-shadow: 1px 1px 3px rgba(0,0,0,.6);
}
.sexy-pos-badge {
  align-self: flex-start;
  margin-top: 2px;
  font: 900 8px/1.3 "Monument Extended", Impact, sans-serif;
  letter-spacing: .02em;
  border: 1.5px solid currentColor;
  border-radius: 5px;
  padding: 2px 7px;
  background: transparent;
}
.sexy-pos-badge.pos-QB  { color: var(--qb); }
.sexy-pos-badge.pos-RB  { color: var(--rb); }
.sexy-pos-badge.pos-WR  { color: var(--wr); }
.sexy-pos-badge.pos-TE  { color: var(--te); }
.sexy-pos-badge.pos-K   { color: var(--k); }
.sexy-pos-badge.pos-DEF { color: var(--def); }

.sexy-card-footer {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  align-items: center;
  gap: 3px;
  padding: 2px 5px;
  color: #071016;
  font: 800 7px "Monument Extended", Impact, sans-serif;
  letter-spacing: .01em;
}
.sexy-card-footer span { white-space: nowrap; overflow: hidden; }
.sexy-card-footer span:last-child { text-align: right; font-weight: 900; }
.sexy-card-footer.pos-QB-bg  { background: var(--qb); }
.sexy-card-footer.pos-RB-bg  { background: var(--rb); }
.sexy-card-footer.pos-WR-bg  { background: var(--wr); }
.sexy-card-footer.pos-TE-bg  { background: var(--te); }
.sexy-card-footer.pos-K-bg   { background: var(--k); }
.sexy-card-footer.pos-DEF-bg { background: var(--def); }

.sexy-headshot {
  position: absolute;
  right: 0;
  bottom: 0;
  width: 52%;
  height: 108%;
  z-index: 0;
  opacity: .6;
  object-fit: cover;
  object-position: top center;
  -webkit-mask-image: linear-gradient(to right, transparent, #000 32%);
  mask-image: linear-gradient(to right, transparent, #000 32%);
}

/* tile-* position colors (non-sexy fallback) */
.pick-tile.filled.tile-QB:not(.sexy-tile) { background: var(--qb); }
.pick-tile.filled.tile-RB:not(.sexy-tile) { background: var(--rb); }
.pick-tile.filled.tile-WR:not(.sexy-tile) { background: var(--wr); }
.pick-tile.filled.tile-TE:not(.sexy-tile) { background: var(--te); }
.pick-tile.filled.tile-K:not(.sexy-tile)  { background: var(--k); }
.pick-tile.filled.tile-DEF:not(.sexy-tile){ background: var(--def); }

/* ===================== LOWER GRID + PANELS ===================== */
.lower-grid {
  display: grid;
  grid-template-columns: 300px minmax(0, 1fr) 330px;
  gap: 14px;
  min-height: 0;
}

/* ===================== DESKTOP TABBED SIDE DOCK =====================
   Player pool is one big section; the other section is a tabbed panel
   (Team / Queue / Bot Brain|Chat). Hidden on tablet/mobile, which keep
   their own layouts. */
.side-tabs { display: none; gap: 6px; }
.side-tab {
  flex: 1;
  height: 40px;
  padding: 0 10px;
  border-radius: 10px;
  border: 1px solid rgba(255,255,255,.08);
  background: var(--panel-bg);
  color: rgba(255,255,255,.55);
  font: 800 10.5px Inter, sans-serif;
  letter-spacing: .06em;
  text-transform: uppercase;
  cursor: pointer;
  transition: all .14s;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
}
.side-tab:hover { color: #fff; border-color: rgba(255,255,255,.2); }
.side-tab.active {
  color: var(--accent);
  border-color: rgba(0,245,255,.45);
  background: rgba(0,245,255,.07);
}
.side-tab-count { font-weight: 900; opacity: .85; }
.side-tab-count:empty { display: none; }

/* Queue rows in the dock (desktop) — a compact horizontal row. The mobile
   media query restyles these larger for touch. */
.queue-panel .queue-list { flex: 1; min-height: 0; overflow-y: auto; padding: 6px 0; }
.queue-row {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 7px 12px;
  border-bottom: 1px solid rgba(255,255,255,.04);
}
.queue-row .draft-button {
  flex: 0 0 auto;
  height: 28px;
  padding: 0 10px;
  border-radius: 6px;
  border: none;
  color: #03100f;
  background: var(--accent);
  font: 700 9.5px Inter, sans-serif;
  letter-spacing: .04em;
  text-transform: uppercase;
}
.queue-row .draft-button:hover { background: #fff; }
.queue-row .draft-button:disabled { background: rgba(255,255,255,.08); color: rgba(255,255,255,.28); cursor: default; }
.queue-row .queue-rank { flex: 0 0 auto; font: 700 11px Inter, sans-serif; color: rgba(255,255,255,.28); min-width: 12px; text-align: center; }
.queue-row .player-main { flex: 1; min-width: 0; }
.queue-row .row-title { font: 600 13px Inter, sans-serif; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.queue-row .player-tags { margin-top: 2px; font-size: 10px; }
.queue-row .adp { flex: 0 0 auto; font: 700 12px "Monument Extended", Impact, sans-serif; color: rgba(255,255,255,.6); }
.queue-row .queue-remove {
  flex: 0 0 auto;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  border: 1px solid rgba(255,79,104,.25);
  background: transparent;
  color: var(--danger);
  font-size: 14px;
  cursor: pointer;
  display: grid;
  place-items: center;
  padding: 0;
}
.queue-row .queue-remove:hover { background: rgba(255,79,104,.12); }
.team-panel-heading { cursor: pointer; }
.roster-expand-hint { font: 600 9px Inter, sans-serif; color: rgba(255,255,255,.3); letter-spacing: .03em; }

@media (min-width: 981px) {
  /* [ tabbed dock | player pool (middle) | Bot Brain/Chat ] */
  .lower-grid {
    grid-template-columns: 300px minmax(0, 1fr) 330px;
    grid-template-rows: auto minmax(0, 1fr);
    align-items: stretch;
  }
  .side-tabs { display: flex; grid-column: 1; grid-row: 1; }
  .lower-grid .team-panel,
  .lower-grid .queue-panel {
    grid-column: 1;
    grid-row: 2;
    display: none;
    min-height: 0;
  }
  .draft-room.side-roster .team-panel { display: flex; }
  .draft-room.side-queue .queue-panel { display: flex; }
  .player-panel { grid-column: 2; grid-row: 1 / span 2; }
  .insight-panel { grid-column: 3; grid-row: 1 / span 2; display: flex; min-height: 0; }
}

.panel {
  min-height: 200px;
  overflow: hidden;
  border-radius: 12px;
  display: flex;
  flex-direction: column;
}
.panel-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  border-bottom: 1px solid rgba(255,255,255,.07);
  min-height: 48px;
}
.panel-heading h2 {
  font: 900 13px "Monument Extended", Impact, sans-serif;
  letter-spacing: .01em;
  text-transform: uppercase;
  color: #fff;
  margin: 0;
}
.panel-heading span {
  font: 600 11px Inter, sans-serif;
  color: rgba(255,255,255,.45);
}

.player-heading-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

/* ---- My Roster panel ---- */
.needs-row {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 10px 13px;
  border-bottom: 1px solid rgba(255,255,255,.06);
}
.needs-row .needs-label {
  font: 800 9px Inter, sans-serif;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: rgba(255,255,255,.4);
  margin-right: 2px;
}
/* Need chips — single canonical definition (was previously defined 3× with conflicts) */
.need-chip {
  font: 900 8.5px "Monument Extended", Impact, sans-serif;
  letter-spacing: .04em;
  border-radius: 5px;
  padding: 3px 7px;
  cursor: pointer;
  transition: transform .15s;
}
.need-chip:hover { transform: scale(1.05); }
.need-chip.pos-QB  { color: var(--qb); background: rgba(255,59,79,.12); border: 1px solid rgba(255,59,79,.25); }
.need-chip.pos-RB  { color: var(--rb); background: rgba(0,245,160,.12); border: 1px solid rgba(0,245,160,.25); }
.need-chip.pos-WR  { color: var(--wr); background: rgba(0,184,255,.12); border: 1px solid rgba(0,184,255,.25); }
.need-chip.pos-TE  { color: var(--te); background: rgba(255,138,42,.12); border: 1px solid rgba(255,138,42,.25); }
.need-chip.pos-K   { color: var(--k); background: rgba(168,85,255,.12); border: 1px solid rgba(168,85,255,.25); }
.need-chip.pos-DEF { color: var(--def); background: rgba(255,79,184,.12); border: 1px solid rgba(255,79,184,.25); }
.need-chip.pos-FLEX { color: var(--accent); background: rgba(0,245,255,.12); border: 1px solid rgba(0,245,255,.25); }
.need-chip.pos-SUPERFLEX { color: var(--violet); background: rgba(124,77,255,.12); border: 1px solid rgba(124,77,255,.3); }
.bench-divider {
  font: 800 9px Inter, sans-serif;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: rgba(255,255,255,.35);
  padding: 9px 13px 5px;
}

/* Self-serve auto-pick toggle (roster panel) */
.autopick-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin: 8px 13px 4px;
  padding: 9px 12px;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 10px;
  background: rgba(255,255,255,.02);
  transition: border-color .15s, background .15s;
}
.autopick-row.on { border-color: rgba(0,245,255,.35); background: rgba(0,245,255,.05); }
.autopick-info { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.autopick-label {
  font: 800 10px Inter, sans-serif;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: #fff;
}
.autopick-row.on .autopick-label { color: var(--accent); }
.autopick-sub { font: 400 10px Inter, sans-serif; color: rgba(255,255,255,.4); line-height: 1.3; }
.autopick-switch {
  flex: 0 0 auto;
  width: 44px;
  height: 26px;
  border-radius: 13px;
  border: 1px solid rgba(255,255,255,.14);
  background: rgba(255,255,255,.06);
  padding: 0;
  cursor: pointer;
  position: relative;
  transition: background .15s, border-color .15s;
}
.autopick-switch.on { background: var(--accent); border-color: var(--accent); }
.autopick-knob {
  position: absolute;
  top: 2px;
  left: 2px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 1px 3px rgba(0,0,0,.4);
  transition: transform .16s ease;
}
.autopick-switch.on .autopick-knob { transform: translateX(18px); background: #04070c; }

.settings-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  padding: 12px 14px;
  border-bottom: 1px solid var(--line);
  background: rgba(255,255,255,.018);
}
.team-panel .settings-grid { display: none; }
.settings-grid label {
  display: grid;
  gap: 5px;
  color: var(--muted);
  font-size: 0.68rem;
  font-weight: 900;
  text-transform: uppercase;
}
.settings-grid label:first-child { grid-column: span 2; }
.settings-grid input,
.settings-grid select {
  width: 100%;
  min-height: 34px;
  border: 1px solid var(--line);
  border-radius: 9px;
  color: var(--text);
  background: var(--surface-2);
  padding: 0 8px;
}
.settings-grid button {
  grid-column: span 2;
  align-self: end;
  color: #030305;
  background: var(--lime);
  border: 0;
  font-weight: 900;
}

.team-list, .player-list {
  flex: 1 1 0;
  min-height: 0;
  overflow: auto;
}

.team-row, .player-row {
  display: grid;
  align-items: center;
  gap: 10px;
  padding: 8px 14px;
  border-bottom: 1px solid rgba(255,255,255,.04);
}
.team-row { grid-template-columns: 34px minmax(0, 1fr); min-height: 48px; }
.team-row.on-clock { background: rgba(0,245,255,.1); }
.team-row.human-team { background: rgba(255,79,104,.08); }
.team-row.human-team.on-clock { background: linear-gradient(90deg, rgba(255,79,104,.2), rgba(0,245,255,.13)); }

.team-row.mini-roster-row {
  display: grid;
  grid-template-columns: 44px 1fr auto;
  gap: 9px;
  padding: 7px 13px;
}
.team-row.mini-roster-row.filled { background: transparent; }
.team-row.mini-roster-row .avatar {
  width: auto;
  height: 30px;
  border-radius: 7px;
  font: 900 8.5px "Monument Extended", Impact, sans-serif;
  letter-spacing: .02em;
}
/* Slot badges colored by position (matches the design-system position palette) */
.mini-roster-row .avatar.pos-av-QB   { background: rgba(255,59,79,.14); color: var(--qb); border: 1px solid rgba(255,59,79,.3); }
.mini-roster-row .avatar.pos-av-RB   { background: rgba(0,245,160,.14); color: var(--rb); border: 1px solid rgba(0,245,160,.3); }
.mini-roster-row .avatar.pos-av-WR   { background: rgba(0,184,255,.14); color: var(--wr); border: 1px solid rgba(0,184,255,.3); }
.mini-roster-row .avatar.pos-av-TE   { background: rgba(255,138,42,.14); color: var(--te); border: 1px solid rgba(255,138,42,.3); }
.mini-roster-row .avatar.pos-av-K    { background: rgba(168,85,255,.14); color: var(--k); border: 1px solid rgba(168,85,255,.3); }
.mini-roster-row .avatar.pos-av-DEF  { background: rgba(255,79,184,.14); color: var(--def); border: 1px solid rgba(255,79,184,.3); }
.mini-roster-row .avatar.pos-av-FLEX { background: rgba(0,245,255,.12); color: var(--accent); border: 1px solid rgba(0,245,255,.3); }
.mini-roster-row .avatar.pos-av-SUPERFLEX { background: rgba(124,77,255,.14); color: var(--violet); border: 1px solid rgba(124,77,255,.35); }
.mini-roster-row .avatar.pos-av-BENCH { background: rgba(255,255,255,.06); color: rgba(255,255,255,.55); border: 1px solid rgba(255,255,255,.14); }

.avatar {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  color: #030305;
  background: var(--accent);
  font-size: 0.78rem;
  font-weight: 900;
}

.row-title {
  overflow: hidden;
  font: 800 13px/1.1 Inter, sans-serif;
  color: #fff;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.team-row.mini-roster-row:not(.filled) .row-title { color: rgba(255,255,255,.3); }
.row-subtitle {
  overflow: hidden;
  font: 500 10px/1.1 Inter, sans-serif;
  color: rgba(255,255,255,.42);
  margin-top: 2px;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.team-row .pick-tag {
  font: 900 10px "Monument Extended", Impact, sans-serif;
  color: var(--accent);
}

/* ---- Player Pool ---- */
.filter-pills {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  justify-content: flex-end;
}
.filter-pills button {
  font: 700 10px Inter, sans-serif;
  letter-spacing: .03em;
  height: 27px;
  padding: 0 10px;
  border-radius: 8px;
  color: rgba(255,255,255,.5);
  background: transparent;
  border: 1px solid rgba(255,255,255,.1);
}
.filter-pills button .filter-count {
  font-size: 8px;
  font-weight: 400;
  opacity: .5;
  margin-left: 3px;
}
.filter-pills button.active {
  color: var(--accent);
  background: rgba(0,245,255,.12);
  border: 1px solid rgba(0,245,255,.45);
}

.pool-search {
  display: flex;
  align-items: center;
  gap: 9px;
  margin: 10px 14px 0;
  height: 36px;
  border-radius: 9px;
  border: 1px solid rgba(255,255,255,.1);
  background: rgba(255,255,255,.03);
  padding: 0 12px;
}
.pool-search input {
  flex: 1;
  border: none;
  background: transparent;
  font: 500 13px Inter, sans-serif;
  color: var(--text);
  outline: none;
  height: 100%;
}
.pool-search input::placeholder { color: rgba(255,255,255,.38); }
.pool-search .icon { font-size: 16px; color: rgba(255,255,255,.4); }
.pool-search .kbd {
  font: 700 9px "Monument Extended", Impact, sans-serif;
  color: rgba(255,255,255,.4);
  background: rgba(255,255,255,.06);
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 5px;
  padding: 3px 6px;
}

.table-head {
  display: none;
}
.player-row {
  display: flex;
  align-items: center;
  gap: 8px;
}
.player-row .player-rank { flex: 0 0 22px; }
.player-row .pos-badge { flex: 0 0 30px; }
.player-row .player-main { flex: 1; min-width: 0; }
.player-row .adp { flex: 0 0 40px; }
.player-row .value-chip { flex: 0 0 auto; }
.player-row .queue-button { flex: 0 0 28px; }
.player-row .draft-button { flex: 0 0 auto; }
.player-row { transition: background .14s; }
.player-row:hover { background: rgba(0,245,255,.05); }
.player-row .draft-button {
  font: 700 10px Inter, sans-serif;
  letter-spacing: .05em;
  text-transform: uppercase;
  color: #03100f;
  background: var(--accent);
  border: none;
  height: 30px;
  border-radius: 6px;
  display: inline-grid;
  place-items: center;
  box-shadow: none;
  padding: 0 8px;
}
.player-row .draft-button:hover { background: #fff; }
.player-row .draft-button-disabled {
  background: rgba(255,255,255,.08);
  color: rgba(255,255,255,.25);
  cursor: default;
  pointer-events: none;
}
.player-row .queue-button {
  font: 700 16px Inter, sans-serif;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: 1px solid rgba(255,255,255,.15);
  background: transparent;
  color: rgba(255,255,255,.4);
  display: inline-grid;
  place-items: center;
  cursor: pointer;
  padding: 0;
  flex: 0 0 30px;
}
.player-row .queue-button:hover { border-color: var(--accent); color: var(--accent); }
.player-row .queue-button.queued {
  background: rgba(0,245,255,.15);
  border-color: var(--accent);
  color: var(--accent);
}
.player-row.human-pick { background: rgba(0,245,255,.035); }
.player-row.human-pick:hover { background: rgba(0,245,255,.1); }

/* Team panel tabs — Roster / Queue */
.team-panel-tabs {
  display: flex;
  gap: 0;
}
.tp-tab {
  font: 700 10px Inter, sans-serif;
  letter-spacing: .05em;
  text-transform: uppercase;
  height: 34px;
  padding: 0 12px;
  border: none;
  border-radius: 0;
  background: transparent;
  color: rgba(255,255,255,.4);
  cursor: pointer;
  border-bottom: 2px solid transparent;
}
.tp-tab:hover { color: rgba(255,255,255,.7); }
.tp-tab.active {
  color: var(--accent);
  border-bottom-color: var(--accent);
}
.desktop-queue-container {
  overflow-y: auto;
  flex: 1 1 0;
  min-height: 0;
}
.desktop-queue-container .queue-row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  border-bottom: 1px solid rgba(255,255,255,.04);
}
.desktop-queue-container .queue-rank {
  font: 700 11px Inter, sans-serif;
  color: rgba(255,255,255,.3);
  min-width: 16px;
  text-align: center;
}
.desktop-queue-container .player-main { min-width: 0; flex: 1; }
.desktop-queue-container .row-title { font-size: 12px; font-weight: 600; }
.desktop-queue-container .player-tags { font-size: 9px; color: rgba(255,255,255,.5); }
.desktop-queue-container .adp { font-size: 10px; color: rgba(255,255,255,.4); }
.desktop-queue-container .queue-remove {
  width: 28px; height: 28px; border-radius: 50%;
  border: 1px solid rgba(255,79,104,.25); background: transparent;
  color: #ff4f68; font-size: 13px; cursor: pointer;
  display: grid; place-items: center; padding: 0;
}
.desktop-queue-container .queue-remove:hover { background: rgba(255,79,104,.1); }
.desktop-queue-container .queue-empty {
  padding: 16px 14px;
  color: rgba(255,255,255,.3);
  font-size: 11px;
  text-align: center;
}

/* Player rank number */
.player-rank {
  font: 700 11px Inter, sans-serif;
  color: rgba(255,255,255,.25);
  min-width: 22px;
  text-align: right;
}

/* Position badge (pill) */
.pos-badge {
  font: 700 9px Inter, sans-serif;
  letter-spacing: .03em;
  padding: 2px 6px;
  border-radius: 4px;
  text-align: center;
  min-width: 28px;
  display: inline-block;
}
.pos-badge.pos-QB { background: rgba(255,59,79,.2); color: #ff3b4f; }
.pos-badge.pos-RB { background: rgba(0,245,160,.2); color: #00f5a0; }
.pos-badge.pos-WR { background: rgba(0,184,255,.2); color: #00b8ff; }
.pos-badge.pos-TE { background: rgba(255,138,42,.2); color: #ff8a2a; }
.pos-badge.pos-K  { background: rgba(168,85,255,.2); color: #a855ff; }
.pos-badge.pos-DEF { background: rgba(255,79,184,.2); color: #ff4fb8; }
.pos-badge.pos-FLEX, .pos-badge.pos-FLX { background: rgba(255,255,255,.1); color: rgba(255,255,255,.6); }
.pos-badge.pos-SUPERFLEX, .pos-badge.pos-SF { background: rgba(255,255,255,.1); color: rgba(255,255,255,.6); }
.pos-badge.pos-BENCH, .pos-badge.pos-BN { background: rgba(140,255,79,.1); color: #8cff4f; }

/* Roster panel */
.roster-switcher {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 14px;
  border-bottom: 1px solid rgba(255,255,255,.06);
}
.roster-switcher-select {
  font: 600 12px Inter, sans-serif;
  color: #fff;
  background: rgba(255,255,255,.06);
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 8px;
  padding: 6px 10px;
  cursor: pointer;
  max-width: 200px;
}
.roster-progress {
  font: 400 11px Inter, sans-serif;
  color: rgba(255,255,255,.4);
}
.roster-section-label {
  font: 700 9px Inter, sans-serif;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: rgba(255,255,255,.3);
  padding: 10px 14px 4px;
  border-top: 1px solid rgba(255,255,255,.05);
}
.mini-roster-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 7px 14px;
  border-bottom: 1px solid rgba(255,255,255,.03);
}
.mini-roster-row .pos-badge { flex: 0 0 32px; text-align: center; }
.roster-player-info { flex: 1; min-width: 0; }
.roster-player-info .row-title { font-size: 13px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.roster-player-info .row-subtitle { font-size: 10px; color: rgba(255,255,255,.4); margin-top: 1px; }
.roster-empty .row-title { color: rgba(255,255,255,.2); font-style: italic; font-weight: 400; }
.roster-empty .pos-badge { opacity: .4; }
.roster-needs {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  padding: 10px 14px;
  border-top: 1px solid rgba(255,255,255,.06);
}
.roster-needs-label {
  font: 600 10px Inter, sans-serif;
  color: rgba(255,255,255,.4);
  letter-spacing: .03em;
}
.roster-next-picks {
  font: 400 10px Inter, sans-serif;
  color: rgba(255,255,255,.35);
  padding: 6px 14px 10px;
}

/* Pool toolbar (count + sort) */
.pool-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 2px 14px 6px;
}
.pool-count {
  font: 400 10px Inter, sans-serif;
  color: rgba(255,255,255,.35);
  letter-spacing: .02em;
}
/* Pool empty state */
.pool-empty {
  padding: 32px 20px;
  text-align: center;
  color: rgba(255,255,255,.3);
  font-size: 13px;
}

/* Draft button inline confirm (desktop) */
.draft-button-confirm {
  background: #fff !important;
  color: #03100f !important;
  font-weight: 800 !important;
}

.player-main { min-width: 0; }
.player-tags {
  display: flex;
  gap: 6px;
  margin-top: 3px;
  font: 500 10px/1.2 Inter, sans-serif;
  color: rgba(255,255,255,.42);
}

.pos-dot, .legend i {
  width: 9px;
  height: 9px;
  border-radius: 50%;
}
.player-tags .pos-dot { margin-top: 4px; }
.player-row .pos-dot { box-shadow: 0 0 8px currentColor; }
.player-row .adp {
  font: 700 12px "Monument Extended", Impact, sans-serif;
  color: rgba(255,255,255,.7);
  text-align: center;
}

/* value chip */
.value-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 24px;
  padding: 0 9px;
  border-radius: 6px;
  font: 800 9px "Monument Extended", Impact, sans-serif;
  letter-spacing: .02em;
}

/* ---- Bot Brain ---- */
#botBrainBody {
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 13px;
  overflow: auto;
  flex: 1;
  min-height: 0;
}
/* Children keep natural height; the body scrolls instead of squashing them */
#botBrainBody > * { flex-shrink: 0; }
.insight-live {
  display: flex;
  align-items: center;
  gap: 6px;
  font: 700 9px Inter, sans-serif;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--lime);
}
.insight-live i {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--lime);
  box-shadow: 0 0 8px var(--lime);
  animation: mdsPulse 1.2s ease-in-out infinite;
}

.bot-row { display: flex; align-items: center; gap: 11px; }
.bot-avatar {
  width: 40px;
  height: 40px;
  border-radius: 11px;
  display: flex;
  align-items: center;
  justify-content: center;
  font: 900 15px "Monument Extended", Impact, sans-serif;
  color: #fff;
  background: linear-gradient(145deg, var(--violet), #4a2fb0);
  box-shadow: 0 4px 14px rgba(124,77,255,.4);
  flex: 0 0 auto;
}
.bot-name { font: 800 14px Inter, sans-serif; color: #fff; }
.bot-sub { font: 500 10px Inter, sans-serif; color: rgba(255,255,255,.45); margin-top: 4px; }

.pick-card {
  border-radius: 11px;
  padding: 11px 13px;
  border: 1px solid rgba(255,255,255,.08);
  background: linear-gradient(150deg, rgba(0,245,255,.09), transparent 60%), rgba(255,255,255,.03);
}
.pick-card .label {
  font: 700 8px "Monument Extended", Impact, sans-serif;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: rgba(255,255,255,.45);
}
.pick-card .name { font: 800 14px Inter, sans-serif; color: #fff; }
.pick-card .pos { font: 600 10px Inter, sans-serif; color: rgba(255,255,255,.5); }

.conf-row { display: flex; align-items: center; justify-content: space-between; margin-bottom: 7px; }
.conf-row .l { font: 700 10px Inter, sans-serif; letter-spacing: .05em; text-transform: uppercase; color: rgba(255,255,255,.5); }
.conf-row .v { font: 900 13px "Monument Extended", Impact, sans-serif; color: var(--accent); }
.conf-track { height: 6px; border-radius: 3px; background: rgba(255,255,255,.1); overflow: hidden; }
.conf-fill { height: 100%; border-radius: 3px; background: linear-gradient(90deg, var(--lime), var(--accent)); }

.insight-card {
  min-height: 0;
  margin: 14px;
  padding: 14px;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 11px;
  background: linear-gradient(150deg, rgba(0,245,255,.09), transparent 60%), rgba(255,255,255,.03);
}
.insight-card p, .insight-text {
  font: 500 12.5px/1.55 Inter, sans-serif;
  color: rgba(232,238,245,.9);
  margin-bottom: 0;
}

.up-next {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid rgba(255,255,255,.08);
  background: rgba(255,255,255,.025);
}
.up-next .l { font: 700 8.5px Inter, sans-serif; letter-spacing: .1em; text-transform: uppercase; color: rgba(255,255,255,.4); }
.up-next .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); margin-left: auto; }
.up-next .name { font: 800 12px Inter, sans-serif; color: #fff; }

.slider-row { display: grid; gap: 10px; padding: 0 14px 14px; }
.slider-row label { color: var(--muted); font-size: 0.78rem; font-weight: 800; }
input[type="range"] { width: 100%; accent-color: var(--accent); }

.legend {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  padding: 2px 14px 16px;
}
.legend span {
  display: flex;
  align-items: center;
  gap: 6px;
  font: 600 10px Inter, sans-serif;
  color: rgba(255,255,255,.52);
}

/* position dot/legend colors */
.qb { background: var(--qb); }
.rb { background: var(--rb); }
.wr { background: var(--wr); }
.te { background: var(--te); }
.k  { background: var(--k); }
.def { background: var(--def); }

/* ===================== SETUP MODAL (WAR ROOM) ===================== */
.setup-modal {
  position: fixed;
  inset: 0;
  z-index: 20;
  display: none;
  align-items: flex-start;
  justify-content: center;
  padding: 22px;
  overflow-y: auto;
  background: radial-gradient(circle at 50% 0%, rgba(0,245,255,.08), transparent 60%), rgba(2,3,6,.94);
  backdrop-filter: blur(12px);
}
.setup-modal.open { display: flex; }

/* Draft countdown overlay */
.countdown-overlay {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(2,3,6,.92);
  backdrop-filter: blur(16px);
  animation: countdownFadeIn .3s ease;
}
@keyframes countdownFadeIn { from { opacity: 0; } to { opacity: 1; } }
.countdown-card {
  text-align: center;
  padding: 48px 64px;
  border-radius: 24px;
  border: 1px solid rgba(0,245,255,.2);
  background: rgba(11,12,16,.95);
  box-shadow: 0 0 80px rgba(0,245,255,.15);
}
.countdown-title {
  font-family: var(--font-heading);
  font-size: 20px;
  text-transform: uppercase;
  letter-spacing: 3px;
  color: rgba(255,255,255,.7);
  margin-bottom: 16px;
}
.countdown-number {
  font-family: var(--font-heading);
  font-size: 96px;
  font-weight: 900;
  color: #00f5ff;
  line-height: 1;
  transition: color .3s;
}
.countdown-sub {
  font-size: 14px;
  color: rgba(255,255,255,.4);
  margin-top: 12px;
  letter-spacing: 1px;
}

.setup-card {
  display: grid;
  grid-template-columns: 38% 1fr;
  width: min(1040px, 96vw);
  margin: auto 0;
  border-radius: 20px;
  border: 1px solid rgba(255,255,255,.12);
  background: #0b0c10;
  overflow: hidden;
  box-shadow: 0 0 0 1px rgba(0,245,255,.1), 0 40px 120px rgba(0,0,0,.75);
}

/* left hero */
.setup-hero {
  position: relative;
  overflow: hidden;
  padding: 40px 34px;
  display: flex;
  flex-direction: column;
  background: linear-gradient(165deg, #08191f 0%, #0a0b0f 62%);
  border-right: 1px solid rgba(255,255,255,.08);
  min-height: 0;
}
.setup-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: radial-gradient(120% 75% at 0% 0%, rgba(0,245,255,.22), transparent 55%);
}
.setup-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: repeating-linear-gradient(90deg, rgba(255,255,255,.04) 0 1px, transparent 1px 48px);
}
.setup-hero .inner { position: relative; z-index: 1; display: flex; flex-direction: column; height: 100%; }
.setup-hero .eyebrow { font: 300 10px "Monument Extended", Impact, sans-serif; letter-spacing: .26em; }
.setup-hero .title {
  font: 900 46px/.86 "Monument Extended", Impact, sans-serif;
  letter-spacing: -.01em;
  text-transform: uppercase;
  color: #fff;
  margin: 18px 0 0;
  text-shadow: 0 0 30px rgba(0,245,255,.3);
}
.setup-hero .subtitle { font: 400 14px/1.55 Inter, sans-serif; color: rgba(255,255,255,.6); margin: 18px 0 0; max-width: 280px; }
.setup-hero .stats { display: flex; gap: 28px; margin-top: auto; }
.setup-hero .stat-num { font: 900 30px "Monument Extended", Impact, sans-serif; color: #fff; line-height: 1; }
.setup-hero .stat-num.accent { color: var(--accent); }
.setup-hero .stat-lbl { font: 700 9px Inter, sans-serif; letter-spacing: .1em; text-transform: uppercase; color: rgba(255,255,255,.45); margin-top: 6px; }
.comp-bar { display: flex; height: 10px; border-radius: 5px; overflow: hidden; gap: 2px; margin-top: 24px; }
.comp-bar i { display: block; }
.comp-cap { font: 400 10px Inter, sans-serif; color: rgba(255,255,255,.45); margin-top: 8px; letter-spacing: .02em; }
.setup-identity { display: flex; align-items: center; gap: 11px; margin-top: 24px; padding-top: 20px; border-top: 1px solid rgba(255,255,255,.09); }
.setup-identity .av {
  width: 38px; height: 38px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font: 900 14px "Monument Extended", Impact, sans-serif;
  color: #03100f; background: var(--accent); box-shadow: 0 0 16px rgba(0,245,255,.45);
}
.setup-identity .nm { font: 700 13px Inter, sans-serif; color: #fff; }
.setup-identity .sb { font: 400 10px Inter, sans-serif; color: rgba(255,255,255,.5); margin-top: 2px; }

/* right form */
.setup-form { padding: 34px 36px; display: flex; flex-direction: column; gap: 22px; background: #0b0c10; overflow-y: auto; min-height: 0; }
.setup-form .form-header { display: flex; align-items: flex-start; justify-content: space-between; }
.setup-form .form-title { font: 900 19px "Monument Extended", Impact, sans-serif; text-transform: uppercase; color: #fff; letter-spacing: .01em; }
.setup-form .form-sub { font: 400 12px Inter, sans-serif; color: rgba(255,255,255,.5); margin-top: 5px; }
.setup-form .close {
  width: 34px; height: 34px; border-radius: 9px;
  border: 1px solid rgba(255,255,255,.14);
  background: rgba(255,255,255,.03);
  display: flex; align-items: center; justify-content: center;
  font-size: 16px; color: rgba(255,255,255,.6); cursor: pointer;
  padding: 0; min-height: 0;
}
.section-label {
  font: 800 10px Inter, sans-serif;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: rgba(255,255,255,.45);
  margin-bottom: 9px;
}

/* segmented control */
.seg-row { display: grid; gap: 7px; }
.seg-row.scoring { grid-template-columns: repeat(5, 1fr); }
.seg-row.league-size { grid-template-columns: repeat(3, 1fr); }

.seg {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 42px;
  border-radius: 9px;
  cursor: pointer;
  transition: all .14s;
  font: 700 13px Inter, sans-serif;
  letter-spacing: .01em;
  white-space: nowrap;
  color: rgba(255,255,255,.6);
  background: rgba(255,255,255,.03);
  border: 1px solid rgba(255,255,255,.12);
  padding: 0;
}
.seg:hover:not(.active) {
  color: #fff;
  border-color: rgba(255,255,255,.3);
  background: rgba(255,255,255,.06);
}
.seg.active {
  color: #03100f;
  background: var(--accent);
  border: 1px solid var(--accent);
  box-shadow: 0 0 14px rgba(0,245,255,.32);
}

.name-field {
  display: flex;
  align-items: center;
  height: 42px;
  border-radius: 9px;
  border: 1px solid rgba(0,245,255,.35);
  background: rgba(0,245,255,.05);
  padding: 0 14px;
}
.name-field input {
  border: none;
  background: transparent;
  font: 600 14px Inter, sans-serif;
  color: #fff;
  outline: none;
  width: 100%;
  height: 100%;
}

/* draft-slot chips */
.slot-grid { display: grid; grid-template-columns: repeat(12, 1fr); gap: 6px; }
.slot-chip {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 48px;
  border-radius: 9px;
  cursor: pointer;
  transition: all .14s;
  font: 900 15px "Monument Extended", Impact, sans-serif;
  color: rgba(255,255,255,.7);
  background: rgba(255,255,255,.04);
  border: 1px solid rgba(255,255,255,.1);
  padding: 0;
}
.slot-chip:hover:not(.mine):not(.claimed) {
  color: #fff;
  border-color: rgba(0,245,255,.45);
  background: rgba(0,245,255,.06);
}
.slot-chip .sub { font: 800 7px Inter, sans-serif; letter-spacing: .12em; margin-top: 2px; color: rgba(255,255,255,.25); }
.slot-chip.mine { color: #03100f; background: var(--accent); border: none; box-shadow: 0 0 18px rgba(0,245,255,.5); }
.slot-chip.mine .sub { color: #03100f; }
.slot-chip.claimed { opacity: .35; cursor: default; pointer-events: none; border-style: dashed; }
.slot-chip.claimed .sub { color: rgba(255,255,255,.5); }

/* roster steppers */
.stepper-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.stepper {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  padding: 9px 11px;
  border-radius: 11px;
  background: rgba(255,255,255,.03);
  border: 1px solid rgba(255,255,255,.09);
}
.stepper .dot { width: 9px; height: 9px; border-radius: 50%; box-shadow: 0 0 7px currentColor; }
.stepper .pos-label { font: 700 11px Inter, sans-serif; color: #fff; letter-spacing: .02em; white-space: nowrap; }
.stepper .val { font: 900 14px "Monument Extended", Impact, sans-serif; color: #fff; min-width: 14px; text-align: center; }
.stepper .ctrl { display: flex; align-items: center; gap: 4px; }
.stepper .minus {
  width: 26px; height: 26px; border-radius: 6px;
  border: 1px solid rgba(255,255,255,.14);
  background: rgba(255,255,255,.04);
  color: rgba(255,255,255,.7);
  display: flex; align-items: center; justify-content: center;
  font-size: 13px; cursor: pointer; padding: 0; min-height: 0;
}
.stepper .minus:hover { color: #fff; border-color: rgba(255,255,255,.35); background: rgba(255,255,255,.09); }
.stepper .plus {
  width: 26px; height: 26px; border-radius: 6px;
  border: 1px solid rgba(0,245,255,.35);
  background: rgba(0,245,255,.08);
  color: var(--accent);
  display: flex; align-items: center; justify-content: center;
  font-size: 13px; cursor: pointer; padding: 0; min-height: 0;
}
.stepper .plus:hover { background: rgba(0,245,255,.18); border-color: var(--accent); }

/* footer CTA */
.setup-footer { display: flex; gap: 10px; margin-top: auto; }
.setup-cta {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  height: 54px;
  border-radius: 12px;
  cursor: pointer;
  background: linear-gradient(180deg, #2ef6ff, #00d4e3);
  color: #03141a;
  font: 900 15px "Monument Extended", Impact, sans-serif;
  letter-spacing: .02em;
  text-transform: uppercase;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.5), 0 0 28px rgba(0,245,255,.45);
  border: none;
  padding: 0;
}
.setup-cancel {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 54px;
  padding: 0 22px;
  border-radius: 12px;
  cursor: pointer;
  border: 1px solid rgba(255,255,255,.14);
  background: transparent;
  color: rgba(255,255,255,.7);
  font: 600 13px Inter, sans-serif;
}

/* hide old setup-head */
.setup-head { display: none; }
#setupSettingsMount { display: contents; }

/* ===================== ROSTER VIEW ===================== */
.roster-view[hidden] { display: none; }
.roster-view {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(255px, 1fr));
  /* Rows keep natural card height; the view scrolls inside the fixed shell */
  grid-auto-rows: max-content;
  flex: 1 1 0;
  min-height: 0;
  gap: 14px;
  overflow: auto;
  padding: 14px;
}
.draft-room.roster-mode .roster-view {
  grid-template-columns: repeat(var(--roster-columns, 4), minmax(0, 1fr));
  gap: 14px;
  max-height: none;
  padding: 18px;
}

.roster-card {
  overflow: hidden;
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 14px;
  background: rgba(13,15,20,.85);
  display: flex;
  flex-direction: column;
}
.roster-card.human-roster {
  border-color: rgba(0,245,255,.9);
  box-shadow: 0 0 0 1px rgba(0,245,255,.4), 0 0 28px rgba(0,245,255,.18);
}
.roster-card.claimed-roster {
  border-color: rgba(255,79,184,.8);
  box-shadow: 0 0 0 1px rgba(255,79,184,.36), 0 0 30px rgba(255,79,184,.16);
}

.roster-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  padding: 13px 14px 10px;
}
.roster-card-head h3 {
  margin: 0;
  font: 800 14px Inter, sans-serif;
  color: #fff;
  text-transform: none;
  letter-spacing: normal;
}
.roster-card.human-roster .roster-card-head h3 { color: var(--accent); }
.roster-card-head p { margin: 4px 0 0; color: var(--muted); font-size: 0.72rem; }
.roster-card-head span {
  font: 900 12px "Monument Extended", Impact, sans-serif;
  color: var(--accent);
}

.roster-slots { display: grid; gap: 4px; padding: 8px 10px 12px; }
.roster-slot {
  display: grid;
  grid-template-columns: 36px minmax(0, 1fr) auto auto;
  gap: 0 8px;
  align-items: center;
  min-height: 32px;
  padding: 5px 10px;
  border: 1px solid rgba(255,255,255,.06);
  border-radius: 8px;
  background: transparent;
}
.roster-slot .rv-pos {
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
  font: 900 9px "Monument Extended", Impact, sans-serif !important;
  padding: 4px 0;
  background: transparent !important;
}
.roster-slot strong {
  overflow: hidden;
  font: 900 12px "Monument Extended", Impact, sans-serif;
  color: rgba(247,248,255,.4);
  line-height: 1;
  text-overflow: ellipsis;
  white-space: nowrap;
  text-transform: uppercase;
}
.roster-slot .rv-first {
  font-weight: 400;
}
.roster-slot .rv-last {
  font-weight: 900;
}
.roster-slot.filled .rv-first { color: #fff; }
.roster-slot.filled .rv-last { color: #fff; }
.roster-slot em {
  overflow: hidden;
  color: rgba(255,255,255,.3);
  font: 600 9px Inter, sans-serif;
  line-height: 1;
  text-overflow: ellipsis;
  white-space: nowrap;
  text-align: right;
}
.roster-slot b {
  color: var(--accent);
  font: 900 9px "Monument Extended", Impact, sans-serif;
  white-space: nowrap;
  text-align: right;
}
.roster-slot.filled {
  background: transparent;
}
.roster-slot.filled strong { color: var(--text); }

/* roster slot position colors — text color on the pos label */
.pos-chip-QB  { color: var(--qb) !important; }
.pos-chip-RB  { color: var(--rb) !important; }
.pos-chip-WR  { color: var(--wr) !important; }
.pos-chip-TE  { color: var(--te) !important; }
.pos-chip-K   { color: var(--k) !important; }
.pos-chip-DEF { color: var(--def) !important; }
.pos-chip-FLEX { color: var(--accent) !important; }
.pos-chip-BENCH { color: rgba(255,255,255,.45) !important; }

.roster-slot:has(.pos-chip-BENCH) { border-color: rgba(255,255,255,.1); }

/* roster slot border by position */
.roster-slot:has(.pos-chip-QB)  { border-color: rgba(255,59,79,.25); }
.roster-slot:has(.pos-chip-RB)  { border-color: rgba(0,245,160,.25); }
.roster-slot:has(.pos-chip-WR)  { border-color: rgba(0,184,255,.25); }
.roster-slot:has(.pos-chip-TE)  { border-color: rgba(255,138,42,.25); }
.roster-slot:has(.pos-chip-K)   { border-color: rgba(168,85,255,.25); }
.roster-slot:has(.pos-chip-DEF) { border-color: rgba(255,79,184,.25); }
.roster-slot:has(.pos-chip-FLEX){ border-color: rgba(0,245,255,.2); }

/* ===================== ROSTER MODAL ===================== */
.roster-modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 30;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 22px;
  background: radial-gradient(circle at 50% 0%, rgba(0,245,255,.06), transparent 50%), rgba(2,3,6,.92);
  backdrop-filter: blur(12px);
}
.roster-modal {
  width: min(900px, 96vw);
  max-height: 90vh;
  overflow-y: auto;
  border-radius: 20px;
  border: 1px solid rgba(255,255,255,.12);
  background: #0b0c10;
  box-shadow: 0 0 0 1px rgba(255,255,255,.05), 0 40px 120px rgba(0,0,0,.75);
  padding: 30px;
}
.roster-modal.human-roster {
  border-color: rgba(0,245,255,.6);
  box-shadow: 0 0 0 1px rgba(0,245,255,.3), 0 0 40px rgba(0,245,255,.12), 0 40px 120px rgba(0,0,0,.75);
}
.rm-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 24px;
}
.rm-eyebrow {
  font: 300 10px "Monument Extended", Impact, sans-serif;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: rgba(255,255,255,.45);
  margin-bottom: 6px;
}
.rm-title {
  font: 900 28px/.9 "Monument Extended", Impact, sans-serif;
  text-transform: uppercase;
  color: #fff;
  text-shadow: 0 0 20px rgba(0,245,255,.15);
  margin: 0;
}
.roster-modal.human-roster .rm-title { color: var(--accent); }
.rm-close {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  border: 1px solid rgba(255,255,255,.14);
  background: rgba(255,255,255,.03);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  color: rgba(255,255,255,.6);
  cursor: pointer;
  min-height: 0;
  padding: 0;
}
.rm-split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}
.rm-section-label {
  font: 800 10px Inter, sans-serif;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: rgba(255,255,255,.35);
  padding: 0 0 10px;
}
.rm-card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
  gap: 8px;
}
.rm-card-wrap {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.rm-slot-chip {
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 5px;
  font: 900 8px "Monument Extended", Impact, sans-serif;
  padding: 2px 0;
  letter-spacing: .04em;
}
.rm-card {
  height: 90px;
  border-radius: 6px;
  position: relative;
  overflow: hidden;
  display: grid;
  grid-template-rows: 1fr auto;
}
.rm-card.sexy-tile .sexy-headshot {
  position: absolute;
  right: 0;
  top: 0;
  bottom: auto;
  width: 48%;
  height: 108%;
  opacity: .7;
  clip-path: none;
  object-fit: cover;
  object-position: top center;
  -webkit-mask-image: none;
  mask-image: none;
}
.rm-card .sexy-last-name { font-size: 16px; line-height: 16px; min-height: 16px; }
.rm-card .sexy-first-name { font-size: 8px; }
.rm-card .sexy-card-upper { padding: 4px 5px 2px; }
.rm-card .sexy-pos-badge { font-size: 9px; padding: 2px 7px; }
.rm-card .sexy-card-footer { font-size: 7px; padding: 3px 5px; }
.rm-empty-card {
  height: 80px;
  border-radius: 6px;
  border: 1px dashed rgba(255,255,255,.08);
  background: rgba(255,255,255,.02);
  display: flex;
  align-items: center;
  justify-content: center;
}
.rm-open {
  font: 500 10px Inter, sans-serif;
  color: rgba(255,255,255,.2);
}

/* ===================== DRAWER + LAYOUT STATES ===================== */
.draft-room[data-drawer="compact"] { grid-template-rows: auto minmax(430px, 1fr) 76px; }
.draft-room[data-drawer="expanded"] { grid-template-rows: auto minmax(180px, 30vh) 1fr; }
.draft-room.roster-mode { grid-template-rows: auto 1fr; }
.draft-room.roster-mode .board-wrap { display: none; }
.draft-room.roster-mode .lower-grid { grid-template-columns: 1fr; min-height: calc(100vh - 136px); }
.draft-room.roster-mode .team-panel,
.draft-room.roster-mode .insight-panel { display: none; }
.draft-room.roster-mode .player-panel { min-height: calc(100vh - 136px); }
.draft-room.roster-mode .filter-pills { display: none; }
.draft-room.roster-mode .drawer-controls { display: none; }

.draft-room[data-drawer="compact"] .lower-grid { overflow: hidden; }
.draft-room[data-drawer="compact"] .panel { min-height: 74px; }
.draft-room[data-drawer="compact"] .settings-grid,
.draft-room[data-drawer="compact"] .team-list,
.draft-room[data-drawer="compact"] .table-head,
.draft-room[data-drawer="compact"] .player-list,
.draft-room[data-drawer="compact"] .insight-card,
.draft-room[data-drawer="compact"] .slider-row,
.draft-room[data-drawer="compact"] .legend { display: none; }

.draft-room[data-drawer="expanded"] .team-list,
.draft-room[data-drawer="expanded"] .player-list { max-height: calc(100vh - 390px); }

.drawer-controls {
  position: fixed;
  right: 20px;
  bottom: 26px;
  z-index: 20;
  display: grid;
  grid-template-columns: repeat(2, 44px);
  gap: 8px;
  /* keep the floating buttons subtle so they don't fight Bot Brain content behind them */
  opacity: .5;
  transition: opacity .15s;
}
.drawer-controls:hover, .drawer-controls:focus-within { opacity: 1; }
.drawer-btn {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 1px solid rgba(255,255,255,.14);
  border-radius: 50%;
  background: rgba(119,136,170,.72);
  box-shadow: 0 10px 28px rgba(0,0,0,.34);
  min-height: 0;
}
.drawer-btn span { width: 12px; height: 12px; border-top: 3px solid #eef3fb; border-left: 3px solid #eef3fb; }
.drawer-up span { transform: translateY(3px) rotate(45deg); }
.drawer-down span { transform: translateY(-3px) rotate(225deg); }
.drawer-btn:disabled { cursor: default; opacity: .36; }

/* ===================== RECORDING MODE ===================== */
.draft-room.recording-mode .topbar,
.draft-room.recording-mode .panel { backdrop-filter: none; box-shadow: none; }
.draft-room.recording-mode .board-wrap { background: #050608; }
.draft-room.recording-mode .team-head { background: #080a0f; box-shadow: none; }
.draft-room.recording-mode .team-head.my-seat { border-color: #00dff0; box-shadow: inset 0 -4px 0 #00dff0; }
.draft-room.recording-mode .team-head.claimed-seat { border-color: #f24cab; box-shadow: inset 0 -4px 0 #f24cab; }
.draft-room.recording-mode .pick-tile { border-color: rgba(255,255,255,.13); }
.draft-room.recording-mode .pick-tile.filled { color: #f7f8ff; }
.draft-room.recording-mode .pick-name { text-shadow: 0 1px 2px rgba(0,0,0,.72); }
.draft-room.recording-mode .pick-meta { color: rgba(247,248,255,.84); text-shadow: 0 1px 2px rgba(0,0,0,.7); }
.draft-room.recording-mode .tile-QB { background: #9f2432; }
.draft-room.recording-mode .tile-RB { background: #137a58; }
.draft-room.recording-mode .tile-WR { background: #166d9f; }
.draft-room.recording-mode .tile-TE { background: #ad5a1f; }
.draft-room.recording-mode .tile-K  { background: #6d37b5; }
.draft-room.recording-mode .tile-DEF { background: #a72c78; }

/* Reconnection banner */
.reconnect-banner {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 200;
  padding: 8px 16px;
  font: 700 11px Inter, sans-serif;
  text-align: center;
  letter-spacing: .06em;
  text-transform: uppercase;
  transition: transform .3s ease, opacity .3s ease;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}
.reconnect-banner.warning { background: rgba(255,218,42,.85); color: #1a1400; }
.reconnect-banner.error { background: rgba(255,79,104,.9); color: #fff; }
.reconnect-banner.success { background: rgba(0,245,160,.85); color: #03100f; }

/* Pick animation */
@keyframes pickFillIn {
  0% { transform: scale(.85); opacity: .45; }
  100% { transform: scale(1); opacity: 1; }
}
.pick-tile.pick-animate { animation: pickFillIn .35s ease-out; }

/* Autopicked tag */
.autopick-tag {
  position: absolute;
  top: 2px;
  right: 2px;
  font: 600 7px Inter, sans-serif;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: rgba(255,255,255,.5);
  background: rgba(0,0,0,.4);
  padding: 1px 3px;
  border-radius: 2px;
}

/* Draft confirmation sheet (mobile) */
.draft-confirm-sheet {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 150;
  background: #0b0c10;
  border-top: 1px solid rgba(0,245,255,.2);
  border-radius: 20px 20px 0 0;
  padding: 24px 20px;
  box-shadow: 0 -8px 40px rgba(0,0,0,.6);
  animation: sheetSlideUp .25s ease-out;
}
@keyframes sheetSlideUp { from { transform: translateY(100%); } to { transform: translateY(0); } }
.draft-confirm-sheet .confirm-player { font: 700 18px Inter, sans-serif; color: #fff; margin-bottom: 4px; }
.draft-confirm-sheet .confirm-meta { font-size: 13px; color: rgba(255,255,255,.5); margin-bottom: 20px; }
.draft-confirm-sheet .confirm-actions { display: flex; gap: 10px; }
.draft-confirm-sheet .confirm-draft {
  flex: 1; height: 48px; border-radius: 12px; border: none;
  background: var(--accent); color: #03100f;
  font: 800 14px Inter, sans-serif; letter-spacing: .04em; text-transform: uppercase;
  cursor: pointer;
}
.draft-confirm-sheet .confirm-cancel {
  flex: 0 0 auto; height: 48px; padding: 0 20px; border-radius: 12px;
  border: 1px solid rgba(255,255,255,.15); background: transparent;
  color: rgba(255,255,255,.6); font: 600 13px Inter, sans-serif; cursor: pointer;
}
.draft-confirm-overlay {
  position: fixed; inset: 0; z-index: 149; background: rgba(0,0,0,.4);
}

/* Tile menu (commish) */
.tile-menu {
  background: #14161e;
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 12px;
  min-width: 200px;
  box-shadow: 0 8px 32px rgba(0,0,0,.6);
  overflow: hidden;
}
.tile-menu-header {
  padding: 10px 14px 8px;
  font: 700 10px Inter, sans-serif;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: rgba(255,255,255,.4);
  border-bottom: 1px solid rgba(255,255,255,.06);
}
.tile-menu-item {
  display: block;
  width: 100%;
  padding: 10px 14px;
  font: 500 13px Inter, sans-serif;
  color: #fff;
  background: transparent;
  border: none;
  text-align: left;
  cursor: pointer;
}
.tile-menu-item:hover { background: rgba(255,255,255,.06); }
.tile-menu-danger { color: #ff4f68; }
.tile-menu-danger:hover { background: rgba(255,79,104,.1); }
.tile-menu-disabled { color: rgba(255,255,255,.25); cursor: default; pointer-events: none; }
.commish-crown { font-size: 8px; margin-left: 3px; }

/* Commish player picker */
.commish-picker-overlay {
  position: fixed; inset: 0; z-index: 10002;
  display: flex; align-items: center; justify-content: center;
  background: rgba(0,0,0,.5); backdrop-filter: blur(4px);
}
.commish-picker-card {
  background: #0b0c10; border: 1px solid rgba(255,255,255,.12);
  border-radius: 16px; width: min(480px, 94vw); max-height: 70vh;
  display: flex; flex-direction: column; overflow: hidden;
  box-shadow: 0 20px 60px rgba(0,0,0,.6);
}
.commish-picker-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 16px; font: 700 14px Inter, sans-serif; color: #fff;
  border-bottom: 1px solid rgba(255,255,255,.08);
}
.commish-picker-close {
  background: none; border: none; color: rgba(255,255,255,.5);
  font-size: 20px; cursor: pointer; padding: 0 4px;
}
.commish-picker-search { padding: 10px 16px; }
.commish-picker-input {
  width: 100%; height: 36px; padding: 0 12px;
  border-radius: 8px; border: 1px solid rgba(255,255,255,.12);
  background: rgba(255,255,255,.05); color: #fff;
  font: 400 13px Inter, sans-serif;
}
.commish-picker-list { flex: 1; overflow-y: auto; }
.commish-picker-row {
  display: flex; align-items: center; gap: 10px;
  padding: 8px 16px; cursor: pointer;
  border-bottom: 1px solid rgba(255,255,255,.03);
}
.commish-picker-row:hover { background: rgba(255,255,255,.04); }
.commish-picker-confirming { background: rgba(0,245,255,.08) !important; }
.commish-picker-current { opacity: .5; }
.commish-picker-name { flex: 1; font: 600 13px Inter, sans-serif; color: #fff; }
.commish-picker-team { font: 400 11px Inter, sans-serif; color: rgba(255,255,255,.4); }
.commish-picker-adp { font: 500 11px Inter, sans-serif; color: rgba(255,255,255,.5); min-width: 36px; text-align: right; }
.commish-picker-tag { font: 700 8px Inter, sans-serif; color: var(--accent); text-transform: uppercase; letter-spacing: .04em; }

/* Rewind confirm */
.rewind-confirm-btn {
  flex: 1; height: 42px; border-radius: 10px; border: none;
  background: #ff4f68; color: #fff; font: 700 13px Inter, sans-serif;
  cursor: pointer;
}
.rewind-confirm-btn:disabled { opacity: .4; cursor: not-allowed; }
.rewind-cancel-btn {
  height: 42px; padding: 0 20px; border-radius: 10px;
  border: 1px solid rgba(255,255,255,.15); background: transparent;
  color: rgba(255,255,255,.6); font: 600 13px Inter, sans-serif; cursor: pointer;
}

/* mobile gear button — hidden on desktop */
.mobile-gear-btn { display: none; }
.queue-panel { display: none; }

/* ===================== MOBILE DRAWER + TABS ===================== */
.mobile-drawer-top { display: none; }

.mobile-tabs {
  display: none; /* shown via media query */
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
  background: var(--surface);
  border-top: 1px solid rgba(255,255,255,.08);
  border-bottom: 1px solid rgba(255,255,255,.08);
  padding: 0;
  position: sticky;
  bottom: 0;
  z-index: 11;
}
.mobile-tab {
  height: 42px;
  border: none;
  border-radius: 0;
  background: transparent;
  font: 700 10px Inter, sans-serif;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: rgba(255,255,255,.4);
  padding: 0;
  min-height: 0;
}
.mobile-tab.active {
  color: var(--accent);
  box-shadow: inset 0 -2px 0 var(--accent);
  background: rgba(0,245,255,.04);
}

/* ===================== RESPONSIVE ===================== */

/* ---- tablet ---- */
@media (max-width: 980px) {
  .app-shell { padding: 10px; }
  /* Stacked layout — let the page grow and scroll again */
  .draft-room { height: auto; min-height: calc(100vh - 20px); grid-template-rows: auto 390px auto; }
  .draft-room[data-drawer="expanded"] { grid-template-rows: auto 160px auto; }
  .topbar, .lower-grid { grid-template-columns: 1fr; }
  .player-panel { order: -1; }
  .draft-status { text-align: left; }
  .controls { justify-content: flex-start; }
  .team-list, .player-list { max-height: 320px; }
  .draft-room[data-drawer="expanded"] .team-list,
  .draft-room[data-drawer="expanded"] .player-list { max-height: 560px; }
  .settings-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .draft-room.roster-mode .roster-view { grid-template-columns: 1fr; max-height: calc(100vh - 230px); }
  .setup-card { grid-template-columns: 1fr; }
  .setup-hero { display: none; }
}

/* ---- mobile ---- */
@media (max-width: 600px) {
  /* ============ FOUNDATIONS ============ */
  .app-shell { padding: 0; }
  .draft-room {
    display: flex;
    flex-direction: column;
    height: 100vh;
    height: 100dvh;
    min-height: 0;
    gap: 0;
    border-radius: 0;
    overflow: hidden;
  }
  .draft-room[data-drawer="compact"],
  .draft-room[data-drawer="expanded"] {
    display: flex;
    flex-direction: column;
  }

  /* ============ TOPBAR — Sleeper-style: clock | CTA | gear ============ */
  .topbar {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 12px;
    border-radius: 0;
    flex: 0 0 auto;
    border-bottom: 1px solid rgba(255,255,255,.08);
  }
  .topbar > div:first-child { display: none; } /* hide logo */
  .draft-status {
    display: flex;
    align-items: center;
    gap: 0;
    flex: 0 0 auto;
    min-width: 0;
    order: 1;
  }
  .pick-clock { width: 36px; height: 36px; flex: 0 0 36px; }
  .pick-clock-inner { width: 28px; height: 28px; font-size: 10px; letter-spacing: -.02em; }
  .status-text { display: none; }
  .progress-row { display: none; }

  /* Main CTA — big center button like Sleeper */
  .controls {
    flex: 1;
    gap: 0;
    justify-content: center;
    order: 2;
  }
  .controls .btn-divider { display: none; }
  .controls .btn-group { display: none; }
  .controls-more { display: none; } /* mobile uses the gear for settings */
  .controls .btn-group-primary {
    display: flex;
    flex: 1;
    justify-content: center;
  }
  .controls .btn-group-primary button { display: none; }
  .controls #startBtn {
    display: flex !important;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 40px;
    font-size: 13px;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
    border-radius: 22px;
    padding: 0 20px;
  }

  /* Your Turn state */
  .controls #startBtn.your-turn {
    background: var(--accent);
    animation: yourTurnPulse 2s ease-in-out infinite;
  }
  @keyframes yourTurnPulse {
    0%, 100% { box-shadow: 0 0 0 0 rgba(0,245,255,.4); }
    50% { box-shadow: 0 0 0 8px rgba(0,245,255,0); }
  }

  /* Sound + settings icons on the right */
  .sfx-toggle-btn {
    order: 3;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    flex: 0 0 36px;
  }
  .mobile-gear-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    order: 4;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: transparent;
    border: 1px solid rgba(255,255,255,.15);
    color: rgba(255,255,255,.5);
    cursor: pointer;
    flex: 0 0 36px;
  }
  .mobile-gear-btn:active { background: rgba(255,255,255,.1); }

  /* ============ BOARD — takes bulk of screen ============ */
  .board-wrap {
    flex: 1 1 0;
    min-height: 120px;
    max-height: none;
    border-radius: 0;
    border-left: none;
    border-right: none;
    overflow: auto;
  }
  .draft-board { font-size: 0; }
  /* No overflow:hidden here — it breaks position:sticky on .team-head */
  .team-col { min-width: 0; }

  /* Paused banner: a fixed bar right below the topbar so it reads as a clear
     status, instead of overlapping the board's sticky column headers.
     (.draft-room prefix beats the later base .paused-ribbon rule on specificity.) */
  .draft-room .paused-ribbon {
    position: fixed;
    top: 58px;
    left: 0;
    right: 0;
    width: auto;
    z-index: 45;
    box-shadow: 0 6px 18px rgba(0,0,0,.55);
  }
  .team-head {
    padding: 5px 4px;
    min-height: 28px;
    overflow: hidden;
  }
  .team-head strong { font-size: 10px; max-width: 100%; }
  .pick-tile { padding: 3px 3px; }
  .empty-pick { font-size: 8px; }
  .pick-tile.on-clock .oc-label { font-size: 6px; }
  .pick-tile.on-clock .oc-pick { font-size: 10px; }

  /* sexy tiles on mobile — hide headshot, tighter layout */
  .pick-tile.sexy-tile { min-height: 48px; }
  .sexy-headshot { display: none; }
  /* No !important — name-fit.js shrinks long names via inline font-size and must win */
  .sexy-last-name { font-size: 10px; line-height: 11px; min-height: 11px; }
  .sexy-first-name { font-size: 6px; }
  .sexy-pos-badge { font-size: 6px; padding: 1px 4px; border-radius: 3px; border-width: 1px; margin-top: 1px; }
  .sexy-card-upper { padding: 3px 4px 1px; gap: 0; }
  .sexy-card-footer { font-size: 6px; padding: 2px 4px; gap: 2px; }

  /* non-sexy tiles */
  .pick-name { font-size: 0.58rem !important; }
  .pick-meta { font-size: 0.48rem !important; }

  /* ============ LOWER SECTION — bottom sheet drawer ============ */
  .mobile-drawer-top {
    display: flex;
    flex-direction: column;
    flex: 0 0 auto;
    background: var(--surface);
    border-radius: 16px 16px 0 0;
    position: relative;
    z-index: 5;
    margin-top: -12px;
    box-shadow: 0 -4px 24px rgba(0,0,0,.5);
  }
  .drawer-handle {
    display: flex;
    justify-content: center;
    padding: 8px 0 2px;
    cursor: grab;
  }
  .drawer-handle span {
    width: 36px;
    height: 4px;
    border-radius: 2px;
    background: rgba(255,255,255,.2);
  }
  .mobile-tabs {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    border-bottom: 1px solid rgba(255,255,255,.08);
    border-top: none;
    background: transparent;
  }

  .lower-grid {
    flex: 1 1 0;
    display: flex;
    flex-direction: column;
    min-height: 0;
    grid-template-columns: 1fr;
    gap: 0;
    background: var(--surface);
    overflow: hidden;
  }

  .panel {
    border-radius: 0;
    border: none;
    min-height: 0;
    flex: 1;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    backdrop-filter: none;
    box-shadow: none;
    background: transparent;
  }

  /* hide side panels by default, show player panel */
  .team-panel { display: none; }
  .insight-panel { display: none; }
  .queue-panel { display: none !important; }
  .player-panel { display: flex; flex: 1; overflow: hidden; }
  .draft-room.mobile-roster .team-panel { display: flex; flex: 1; }
  .draft-room.mobile-roster .player-panel { display: none; }
  .draft-room.mobile-brain .insight-panel { display: flex; flex: 1; }
  .draft-room.mobile-brain .player-panel { display: none; }
  .draft-room.mobile-queue .queue-panel { display: flex !important; flex: 1; flex-direction: column; overflow: hidden; }
  .draft-room.mobile-queue .player-panel { display: none; }

  /* panel heading — hide title, keep filter pills */
  .panel-heading { padding: 0; min-height: 0; }
  .panel-heading h2 { display: none; }
  .team-panel .panel-heading { display: none; }
  .desktop-queue-container { display: none !important; }
  .insight-panel .panel-heading { display: none; }

  /* ============ PLAYER POOL — Sleeper-style ============ */
  .player-heading-actions { flex: 1; }
  .filter-pills {
    display: flex;
    gap: 6px;
    justify-content: flex-start;
    overflow-x: auto;
    flex-wrap: nowrap;
    padding: 10px 12px 8px;
  }
  .filter-pills button {
    height: 36px;
    min-width: 48px;
    padding: 0 12px;
    font-size: 11px;
    font-weight: 700;
    flex: 0 0 auto;
    border-radius: 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1px;
    line-height: 1.1;
  }
  .filter-pills button .filter-count {
    font-size: 8px;
    font-weight: 400;
    opacity: .6;
  }
  .filter-pills button.active .filter-count { opacity: .8; }
  .pool-search {
    margin: 0 12px 6px;
    height: 36px;
    border-radius: 20px;
  }
  .pool-search input { font-size: 13px; }
  .pool-search .icon { font-size: 16px; }
  .table-head { display: none; }
  .player-row {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    border-bottom: 1px solid rgba(255,255,255,.04);
  }
  /* Draft button on left — Sleeper-style */
  .player-row .draft-button {
    flex: 0 0 auto;
    height: 32px;
    font-size: 10px;
    font-weight: 700;
    padding: 0 10px;
    border-radius: 8px;
    text-transform: uppercase;
    letter-spacing: .04em;
    order: 0;
  }
  .player-row .draft-button-disabled {
    background: rgba(255,255,255,.06);
    color: rgba(255,255,255,.2);
    border: 1px solid rgba(255,255,255,.06);
  }
  .player-row .player-rank { display: none; } /* hide rank on mobile */
  .player-row .pos-badge { order: 1; font-size: 8px; padding: 2px 5px; flex: 0 0 auto; }
  .player-row .player-main { flex: 1; min-width: 0; order: 2; }
  .player-row .row-title { font-size: 14px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .player-tags { font-size: 10px; gap: 3px; margin-top: 2px; }
  .player-row .queue-button { order: 5; width: 34px; height: 34px; flex: 0 0 34px; font-size: 16px; }
  .player-row .adp {
    flex: 0 0 auto;
    font-size: 11px;
    text-align: center;
    order: 3;
  }
  .player-row .adp::before { content: "ADP"; display: block; font-size: 7px; opacity: .5; font-weight: 600; letter-spacing: .05em; }
  .value-chip { height: 20px; padding: 0 5px; font-size: 8px; border-radius: 5px; order: 4; flex: 0 0 auto; }
  .pool-toolbar { padding: 2px 12px 4px; }
  .player-list { flex: 1; overflow-y: auto; max-height: none; }

  /* ============ MY ROSTER PANEL — Sleeper slot-based ============ */
  .settings-grid { display: none; }
  .team-list { flex: 1; overflow-y: auto; max-height: none; padding: 4px 0; }
  .team-row {
    padding: 10px 14px;
    border-bottom: 1px solid rgba(255,255,255,.06);
  }
  .team-row .avatar {
    width: 42px;
    height: 32px;
    border-radius: 8px;
    font-size: 11px;
    font-weight: 700;
  }
  .team-row .row-title { font-size: 14px; font-weight: 600; }
  .team-row .row-subtitle { font-size: 11px; opacity: .5; }

  /* ============ QUEUE PANEL ============ */
  .queue-list { flex: 1; overflow-y: auto; padding: 8px 0; }
  .queue-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    flex: 1;
    color: rgba(255,255,255,.3);
    font-size: 13px;
    gap: 8px;
    padding: 40px 20px;
    text-align: center;
  }
  .queue-empty-icon { font-size: 32px; opacity: .4; }
  .queue-row {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    border-bottom: 1px solid rgba(255,255,255,.05);
  }
  .queue-row .draft-button {
    flex: 0 0 auto;
    height: 32px;
    font: 700 10px Inter, sans-serif;
    padding: 0 10px;
    border-radius: 8px;
    text-transform: uppercase;
    letter-spacing: .04em;
    color: #03100f;
    background: var(--accent);
    border: none;
    cursor: pointer;
  }
  .queue-row .draft-button:disabled {
    background: rgba(255,255,255,.06);
    color: rgba(255,255,255,.2);
    cursor: default;
  }
  .queue-row .queue-rank {
    font: 700 13px Inter, sans-serif;
    color: rgba(255,255,255,.3);
    min-width: 20px;
    text-align: center;
  }
  .queue-row .player-main { flex: 1; min-width: 0; }
  .queue-row .row-title { font-size: 14px; font-weight: 600; }
  .queue-row .player-tags { font-size: 10px; color: rgba(255,255,255,.5); margin-top: 2px; }
  .queue-row .adp { font-size: 11px; text-align: center; color: rgba(255,255,255,.5); }
  .queue-row .adp::before { content: "ADP"; display: block; font-size: 7px; opacity: .5; font-weight: 600; }
  .queue-row .queue-remove {
    width: 34px; height: 34px; border-radius: 50%;
    border: 1px solid rgba(255,79,104,.3); background: transparent;
    color: #ff4f68; font-size: 16px; cursor: pointer;
    display: grid; place-items: center; padding: 0;
  }
  .queue-row .queue-remove:hover { background: rgba(255,79,104,.1); }

  /* ============ BOT BRAIN ============ */
  #botBrainBody { padding: 10px; flex: 1; overflow-y: auto; }
  .bot-avatar { width: 32px; height: 32px; font-size: 12px; border-radius: 8px; }
  .insight-card { font-size: 12px; }
  .slider-row { padding: 6px 10px; }
  .legend { padding: 6px 10px; font-size: 9px; gap: 6px; }

  /* mobile tabs already handled in drawer section */

  /* drawer drag handle area — prevent scroll on touch */
  .mobile-drawer-top { touch-action: none; }

  /* ============ DRAWER ============ */
  .drawer-controls { display: none; }
  .draft-room[data-drawer="compact"] .table-head,
  .draft-room[data-drawer="compact"] .player-list,
  .draft-room[data-drawer="compact"] .team-list,
  .draft-room[data-drawer="compact"] .insight-card,
  .draft-room[data-drawer="compact"] .slider-row,
  .draft-room[data-drawer="compact"] .legend { display: revert; }
  .draft-room[data-drawer="compact"] .settings-grid { display: none; }
  .draft-room[data-drawer="compact"] .panel { min-height: 0; }

  /* ============ ROSTER VIEW ============ */
  .draft-room.roster-mode .board-wrap { display: none; }
  .draft-room.roster-mode .lower-grid {
    flex: 1;
    max-height: none;
    min-height: 0;
  }
  .draft-room.roster-mode .roster-view {
    grid-template-columns: 1fr;
    max-height: none;
    padding: 10px;
    gap: 10px;
  }
  .roster-card-head { padding: 10px 12px 8px; }
  .roster-card-head h3 { font-size: 13px; }
  .roster-slots { padding: 6px 8px 10px; }

  /* ============ WAR ROOM MODAL ============ */
  .setup-modal { padding: 0; align-items: stretch; }
  .setup-card {
    width: 100%;
    height: 100vh;
    height: 100dvh;
    max-height: none;
    border-radius: 0;
    border: none;
    grid-template-columns: 1fr;
    grid-template-rows: 1fr;
    overflow: hidden;
  }
  .setup-hero { display: none; }
  .setup-form { padding: 20px 16px; gap: 18px; overflow-y: auto; -webkit-overflow-scrolling: touch; }
  .setup-form .form-title { font-size: 16px; }
  .seg { height: 38px; font-size: 12px; }
  .seg-row.scoring { grid-template-columns: repeat(3, 1fr); }
  .seg-row { gap: 5px; }
  .slot-grid { gap: 5px; grid-template-columns: repeat(6, 1fr) !important; }
  .slot-chip { height: 40px; font-size: 13px; border-radius: 7px; }
  .slot-chip .sub { font-size: 6px; }
  .stepper-grid { grid-template-columns: repeat(2, 1fr); gap: 6px; }
  #pickClockOptions { grid-template-columns: repeat(3, 1fr) !important; }
  .stepper { padding: 7px 9px; border-radius: 9px; }
  .stepper .pos-label { font-size: 10px; }
  .stepper .val { font-size: 12px; }
  .stepper .minus, .stepper .plus { width: 34px; height: 34px; font-size: 15px; }
  .name-field { height: 38px; }
  .name-field input { font-size: 13px; }
  .setup-footer { position: sticky; bottom: 0; padding: 12px 0 0; background: #0b0c10; }
  .setup-cta { height: 48px; font-size: 13px; border-radius: 10px; }
  .setup-cancel { height: 48px; font-size: 12px; border-radius: 10px; }

  /* ============ ROSTER MODAL ============ */
  .roster-modal-overlay { padding: 0; }
  .roster-modal, .roster-modal-card {
    width: 100%;
    max-height: 100vh;
    max-height: 100dvh;
    border-radius: 0;
  }
  .roster-modal { padding: 20px 14px; }
}

/* ===================== FULL ROOM POPUP ===================== */
.fullroom-overlay {
  position: fixed;
  inset: 0;
  background: rgba(5, 6, 8, 0.88);
  backdrop-filter: blur(12px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
}
.fullroom-popup {
  background: var(--panel-bg);
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 20px;
  padding: 36px 32px 32px;
  max-width: 360px;
  width: 90%;
  text-align: center;
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.fullroom-icon { font-size: 40px; line-height: 1; }
.fullroom-title {
  font: 900 22px "Monument Extended", Impact, sans-serif;
  letter-spacing: .02em;
  color: #fff;
  margin: 0;
}
.fullroom-body {
  font: 400 13px Inter, sans-serif;
  color: rgba(255,255,255,.55);
  margin: 0;
  line-height: 1.5;
}
.fullroom-actions {
  display: flex;
  gap: 10px;
  margin-top: 6px;
}
.fullroom-actions button {
  flex: 1;
  height: 44px;
  border-radius: 10px;
  font: 800 13px Inter, sans-serif;
  cursor: pointer;
  border: none;
  transition: opacity .15s;
}
.fullroom-actions button:hover { opacity: .85; }
.fullroom-exit {
  background: rgba(255,255,255,.08);
  color: rgba(255,255,255,.7);
}
.fullroom-spectate {
  background: var(--accent);
  color: #071016;
}

/* ===================== SPECTATOR MODE ===================== */
.draft-room.spectator-mode .topbar .btn-group-primary button,
.draft-room.spectator-mode #resetBtn,
.draft-room.spectator-mode #exportBtn {
  opacity: .35;
  cursor: not-allowed;
  pointer-events: none;
}
.draft-room.spectator-mode #inviteBtn {
  opacity: .6;
  cursor: default;
  pointer-events: none;
}
.setup-cta-spectate {
  background: var(--accent) !important;
  color: #071016 !important;
}

/* ===================== DRAFT CHAT — Glassmorphism ===================== */
.chat-messages-wrap {
  position: relative;
  flex: 1 1 0;
  min-height: 0;
  display: flex;
  flex-direction: column;
}
.chat-messages {
  flex: 1;
  overflow-y: auto;
  padding: 10px 14px 6px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-height: 0;
}
/* Jump-to-latest pill — appears when the reader scrolls up off the newest message */
.chat-jump-latest {
  position: absolute;
  left: 50%;
  bottom: 10px;
  transform: translateX(-50%);
  height: 28px;
  padding: 0 14px;
  border-radius: 14px;
  border: 1px solid rgba(0,245,255,.35);
  background: rgba(10,16,24,.92);
  color: var(--accent);
  font: 700 10px Inter, sans-serif;
  letter-spacing: .04em;
  text-transform: uppercase;
  cursor: pointer;
  backdrop-filter: blur(8px);
  box-shadow: 0 6px 20px rgba(0,0,0,.5);
  transition: background .15s, box-shadow .15s, transform .15s;
  z-index: 4;
}
.chat-jump-latest:hover { background: rgba(0,245,255,.14); transform: translateX(-50%) translateY(-1px); }
.chat-jump-latest[hidden] { display: none; }
/* New message arrived while scrolled up — pull focus */
.chat-jump-latest.has-new {
  background: var(--accent);
  color: #04070c;
  border-color: var(--accent);
  box-shadow: 0 0 18px rgba(0,245,255,.4);
  animation: chatJumpPulse 1.6s ease-in-out infinite;
}
@keyframes chatJumpPulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(0,245,255,.4); }
  50% { box-shadow: 0 0 0 6px rgba(0,245,255,0); }
}
.chat-empty {
  font: 400 11px Inter, sans-serif;
  color: rgba(255,255,255,.25);
  text-align: center;
  margin: auto;
  padding: 20px 0;
}
.chat-msg {
  display: flex;
  flex-direction: column;
  gap: 3px;
  align-items: flex-start;
  margin-top: 4px;
}
.chat-msg.chat-msg-me { align-items: flex-end; }
.chat-meta {
  display: flex;
  align-items: center;
  gap: 5px;
}
.chat-name {
  font: 700 8.5px Inter, sans-serif;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: rgba(255,255,255,.35);
}
.chat-msg-me .chat-name { color: rgba(0,245,255,.5); }
.chat-time {
  font: 400 8.5px Inter, sans-serif;
  color: rgba(255,255,255,.18);
}
.chat-bubble {
  position: relative;
  max-width: 85%;
  padding: 8px 12px;
  border-radius: 14px 14px 14px 4px;
  font: 400 12.5px Inter, sans-serif;
  color: rgba(255,255,255,.9);
  line-height: 1.45;
  word-break: break-word;
  background: rgba(255,255,255,.06);
  border: 1px solid rgba(255,255,255,.08);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  overflow: visible;
  cursor: pointer;
  box-shadow: 0 2px 8px rgba(0,0,0,.2);
}
.chat-msg-me .chat-bubble {
  border-radius: 14px 14px 4px 14px;
  background: linear-gradient(135deg, rgba(0,245,255,.22), rgba(124,77,255,.22));
  border: 1px solid rgba(0,245,255,.18);
  color: #fff;
  box-shadow: 0 2px 12px rgba(0,245,255,.1);
}
.chat-input-row {
  display: flex;
  gap: 6px;
  padding: 10px 14px 14px;
  border-top: 1px solid rgba(255,255,255,.05);
  flex-shrink: 0;
  background: rgba(0,0,0,.15);
}
.chat-input {
  flex: 1;
  height: 36px;
  background: rgba(255,255,255,.05);
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 18px;
  padding: 0 14px;
  color: #fff;
  font: 400 12px Inter, sans-serif;
  outline: none;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  transition: border-color .2s, box-shadow .2s;
}
.chat-input::placeholder { color: rgba(255,255,255,.25); }
.chat-input:focus {
  border-color: rgba(0,245,255,.4);
  box-shadow: 0 0 0 2px rgba(0,245,255,.08);
}
.chat-send {
  height: 36px;
  padding: 0 14px;
  background: linear-gradient(135deg, var(--accent), var(--violet));
  color: #071016;
  font: 800 11px Inter, sans-serif;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  flex-shrink: 0;
  transition: opacity .15s;
}
.chat-send:hover { opacity: .85; }

/* Chat pop-out button */
.chat-popout-btn {
  width: 24px;
  height: 24px;
  background: rgba(255,255,255,.06);
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 5px;
  color: rgba(255,255,255,.5);
  font-size: 14px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  margin-right: 6px;
  transition: background .15s, color .15s;
  vertical-align: middle;
  line-height: 1;
}
.chat-popout-btn:hover { background: rgba(255,255,255,.15); color: #fff; }

/* GIF button */
.chat-gif-btn {
  height: 34px;
  padding: 0 8px;
  background: rgba(255,255,255,.08);
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 6px;
  color: rgba(255,255,255,.6);
  font: 800 9px Inter, sans-serif;
  letter-spacing: .04em;
  cursor: pointer;
  flex-shrink: 0;
  transition: background .15s;
}
.chat-gif-btn:hover { background: rgba(255,255,255,.15); color: #fff; }

/* Chat GIF image */
.chat-gif {
  max-width: 100%;
  max-height: 150px;
  border-radius: 6px;
  display: block;
}

/* GIF picker panel */
.gif-picker-panel {
  width: 280px;
  height: 310px;
  background: #1a1d24;
  border: 1px solid rgba(255,255,255,.15);
  border-radius: 12px;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  box-shadow: 0 8px 32px rgba(0,0,0,.6);
}
.gif-search-input {
  margin: 8px;
  height: 32px;
  background: rgba(255,255,255,.08);
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 8px;
  padding: 0 10px;
  color: #fff;
  font: 400 12px Inter, sans-serif;
  outline: none;
  flex-shrink: 0;
}
.gif-search-input::placeholder { color: rgba(255,255,255,.3); }
.gif-search-input:focus { border-color: var(--accent); }
.gif-results {
  flex: 1;
  overflow-y: auto;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 4px;
  padding: 0 8px 8px;
  align-content: start;
}
.gif-result-item {
  width: 100%;
  height: auto;
  border-radius: 6px;
  cursor: pointer;
  transition: transform .1s;
  display: block;
}
.gif-result-item:hover { transform: scale(1.04); }
.gif-loading {
  grid-column: 1 / -1;
  text-align: center;
  color: rgba(255,255,255,.3);
  font: 400 11px Inter, sans-serif;
  padding: 20px;
}
.gif-powered {
  text-align: center;
  font: 400 8px Inter, sans-serif;
  color: rgba(255,255,255,.2);
  padding: 4px;
  flex-shrink: 0;
}

/* Chat emoji button */
.chat-emoji-btn {
  height: 34px;
  width: 34px;
  background: rgba(255,255,255,.06);
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 6px;
  font-size: 16px;
  cursor: pointer;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background .15s;
  padding: 0;
}
.chat-emoji-btn:hover { background: rgba(255,255,255,.12); }

/* Swap bot brain body to chat flex layout */
#botBrainBody[data-mode="chat"] {
  padding: 0;
  gap: 0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
/* Hide speed slider and legend when in chat mode */
.insight-panel.chat-mode .slider-row,
.insight-panel.chat-mode .legend { display: none; }

/* ===================== EMOJI REACTIONS ===================== */
.react-float {
  position: absolute;
  bottom: 2px;
  right: 2px;
  font-size: 10px;
  line-height: 1;
  padding: 2px 5px;
  border-radius: 8px;
  background: rgba(0,0,0,.6);
  backdrop-filter: blur(4px);
  border: 1px solid rgba(255,255,255,.12);
  z-index: 3;
  cursor: pointer;
  pointer-events: auto;
  white-space: nowrap;
  color: #fff;
  transition: transform .1s;
}
.react-float:hover { transform: scale(1.1); }

/* Reaction details tooltip */
.react-tooltip {
  background: #1a1d24;
  border: 1px solid rgba(255,255,255,.15);
  border-radius: 10px;
  padding: 6px 4px;
  display: flex;
  flex-direction: column;
  gap: 2px;
  box-shadow: 0 8px 32px rgba(0,0,0,.6);
  min-width: 100px;
  max-width: 200px;
}
.react-tooltip-row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 4px 8px;
  border-radius: 6px;
}
.react-tooltip-row:hover { background: rgba(255,255,255,.06); }
.react-tooltip-emoji { font-size: 16px; flex: 0 0 20px; text-align: center; }
.react-tooltip-name {
  font: 500 12px Inter, sans-serif;
  color: rgba(255,255,255,.8);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ===================== ROSTER MODAL (compact seat popup card) =====================
   The shared .roster-modal-overlay backdrop is defined once, alongside .roster-modal. */
.roster-modal-card {
  background: var(--surface);
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 18px;
  width: min(440px, 96vw);
  max-height: 85vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  box-shadow: 0 24px 80px rgba(0,0,0,.6);
}
.roster-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 20px 14px;
  border-bottom: 1px solid rgba(255,255,255,.08);
}
.roster-modal-title {
  font: 900 18px "Monument Extended", Impact, sans-serif;
  text-transform: uppercase;
  color: var(--accent);
  letter-spacing: .01em;
}
.roster-modal-sub {
  font: 500 11px Inter, sans-serif;
  color: rgba(255,255,255,.45);
  margin-top: 3px;
}
.roster-modal-close {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: rgba(255,255,255,.06);
  border: 1px solid rgba(255,255,255,.1);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  color: rgba(255,255,255,.5);
  cursor: pointer;
}
.roster-modal-close:hover { background: rgba(255,255,255,.12); color: #fff; }
.roster-modal-export {
  height: 32px;
  padding: 0 14px;
  background: var(--accent);
  color: #071016;
  font: 700 11px Inter, sans-serif;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  letter-spacing: .03em;
  transition: opacity .15s;
}
.roster-modal-export:hover { opacity: .85; }
.roster-modal-body {
  padding: 14px 20px 20px;
  overflow-y: auto;
  flex: 1;
}

/* Emoji picker floating */
.emoji-picker {
  background: #1a1d24;
  border: 1px solid rgba(255,255,255,.15);
  border-radius: 12px;
  padding: 6px;
  display: flex;
  gap: 4px;
  box-shadow: 0 8px 32px rgba(0,0,0,.6);
}
.emoji-option {
  font-size: 20px;
  width: 36px;
  height: 36px;
  background: none;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background .1s;
}
.emoji-option:hover { background: rgba(255,255,255,.1); }

/* ===================== CHAT EMOJI BUTTON ===================== */
.chat-emoji-btn {
  flex-shrink: 0;
  width: 34px;
  height: 34px;
  background: rgba(255,255,255,.06);
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 8px;
  font-size: 16px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background .15s, border-color .15s;
  line-height: 1;
  padding: 0;
}
.chat-emoji-btn:hover {
  background: rgba(255,255,255,.12);
  border-color: rgba(255,255,255,.2);
}

/* Chat emoji picker (floats above input row) */
.chat-emoji-picker {
  background: #1a1d24;
  border: 1px solid rgba(255,255,255,.15);
  border-radius: 12px;
  padding: 8px;
  display: grid;
  grid-template-columns: repeat(6, 36px);
  gap: 4px;
  box-shadow: 0 8px 32px rgba(0,0,0,.65);
}
.chat-emoji-option {
  font-size: 20px;
  width: 36px;
  height: 36px;
  background: none;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background .1s;
  padding: 0;
  line-height: 1;
}
.chat-emoji-option:hover { background: rgba(255,255,255,.1); }

/* ===================== FULL EMOJI PICKER (TABBED) ===================== */
.chat-emoji-picker.chat-emoji-picker-full {
  width: 280px;
  max-height: 300px;
  display: flex;
  flex-direction: column;
  padding: 0;
  overflow: hidden;
}
.chat-emoji-tabs {
  display: flex;
  gap: 2px;
  padding: 6px 6px 0;
  border-bottom: 1px solid rgba(255,255,255,.08);
  flex-shrink: 0;
}
.chat-emoji-tab {
  flex: 1;
  background: none;
  border: none;
  color: rgba(255,255,255,.4);
  font-size: 16px;
  padding: 6px 0 8px;
  cursor: pointer;
  border-bottom: 2px solid transparent;
  transition: color .15s, border-color .15s;
}
.chat-emoji-tab:hover { color: rgba(255,255,255,.7); }
.chat-emoji-tab.chat-emoji-tab-active {
  color: #fff;
  border-bottom-color: var(--accent, #00f5ff);
}
.chat-emoji-grids {
  flex: 1;
  overflow-y: auto;
  padding: 8px;
}
.chat-emoji-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 3px;
}
.chat-emoji-grid-hidden { display: none; }

/* ===================== FLOATING CHAT PANEL ===================== */
.floating-chat-panel {
  position: fixed;
  bottom: 20px;
  right: 20px;
  width: 380px;
  height: 500px;
  z-index: 999;
  background: rgba(10, 12, 18, .72);
  backdrop-filter: blur(24px) saturate(1.4);
  -webkit-backdrop-filter: blur(24px) saturate(1.4);
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 18px;
  display: flex;
  flex-direction: column;
  box-shadow:
    0 24px 64px rgba(0,0,0,.55),
    0 0 0 1px rgba(0,245,255,.06),
    inset 0 1px 0 rgba(255,255,255,.06);
  overflow: hidden;
}
.floating-chat-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  background: linear-gradient(180deg, rgba(255,255,255,.05), rgba(255,255,255,.01));
  border-bottom: 1px solid rgba(255,255,255,.06);
  cursor: grab;
  flex-shrink: 0;
  user-select: none;
}
.floating-chat-title {
  font: 900 13px "Monument Extended", Impact, sans-serif;
  text-transform: uppercase;
  letter-spacing: .01em;
  color: #fff;
}
.floating-chat-actions {
  display: flex;
  align-items: center;
  gap: 5px;
}
.floating-chat-newwin {
  height: 26px;
  padding: 0 8px;
  background: rgba(255,255,255,.05);
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 8px;
  color: rgba(255,255,255,.45);
  font: 600 10px Inter, sans-serif;
  cursor: pointer;
  transition: all .15s;
}
.floating-chat-newwin:hover { background: rgba(255,255,255,.1); color: #fff; border-color: rgba(255,255,255,.15); }
.floating-chat-close {
  width: 26px;
  height: 26px;
  background: rgba(255,255,255,.05);
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 8px;
  color: rgba(255,255,255,.4);
  font-size: 15px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all .15s;
  padding: 0;
  line-height: 1;
}
.floating-chat-close:hover { background: rgba(255,70,70,.15); color: #ff4646; border-color: rgba(255,70,70,.25); }
.floating-chat-messages {
  flex: 1;
  overflow-y: auto;
  padding: 10px 14px 6px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-height: 0;
}
.floating-chat-input-row {
  display: flex;
  gap: 6px;
  padding: 10px 14px 14px;
  border-top: 1px solid rgba(255,255,255,.05);
  flex-shrink: 0;
  background: rgba(0,0,0,.15);
}

/* ===================== CHAT FLOATING NOTICE ===================== */
.chat-floating-notice {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 40px 20px;
  text-align: center;
}
.chat-floating-notice-icon {
  font-size: 28px;
  opacity: .4;
}
.chat-floating-notice-text {
  font: 700 13px Inter, sans-serif;
  color: rgba(255,255,255,.5);
  text-transform: uppercase;
  letter-spacing: .04em;
}
.chat-floating-notice-sub {
  font: 400 11px Inter, sans-serif;
  color: rgba(255,255,255,.25);
}

/* ===================== MESSAGE REACTIONS (iMessage tapback) ===================== */
/* iMessage-style floating reaction badges — inside .chat-bubble */
.msg-reactions-row {
  position: absolute;
  top: -9px;
  right: -2px;
  display: flex;
  gap: 1px;
  z-index: 2;
  pointer-events: auto;
}
.chat-msg-me .msg-reactions-row { right: auto; left: -2px; }
.msg-reaction-pill {
  display: inline-flex;
  align-items: center;
  gap: 1px;
  padding: 0;
  background: none;
  border: none;
  font-size: 13px;
  cursor: pointer;
  transition: transform .1s;
  line-height: 1;
  height: 18px;
  min-height: 0;
}
.msg-reaction-pill:hover { transform: scale(1.2); }

/* Message reaction bar (appears above bubble on click) */
.msg-reaction-bar {
  display: flex;
  gap: 2px;
  padding: 6px 8px;
  background: #1a1d24;
  border: 1px solid rgba(255,255,255,.15);
  border-radius: 24px;
  box-shadow: 0 8px 32px rgba(0,0,0,.65);
}
.msg-reaction-bar-btn {
  width: 36px;
  height: 36px;
  background: none;
  border: none;
  border-radius: 50%;
  font-size: 20px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background .1s, transform .1s;
  padding: 0;
  line-height: 1;
}
.msg-reaction-bar-btn:hover { background: rgba(255,255,255,.1); transform: scale(1.2); }

/* Make chat bubble clickable for reactions */
.chat-bubble { cursor: pointer; }

/* ===================== REACTION TOAST ===================== */
.reaction-toast {
  position: fixed;
  top: 72px;
  right: 16px;
  z-index: 10000;
  background: #1a1d24;
  border: 1px solid rgba(0,245,255,.25);
  border-radius: 12px;
  padding: 11px 16px 12px;
  min-width: 220px;
  max-width: 300px;
  box-shadow: 0 8px 32px rgba(0,0,0,.55), 0 0 0 1px rgba(0,245,255,.08);
  pointer-events: none;
  opacity: 0;
  transform: translateY(-6px);
  transition: opacity .22s ease, transform .22s ease;
}
.reaction-toast.reaction-toast-visible {
  opacity: 1;
  transform: translateY(0);
}
.reaction-toast-headline {
  font: 700 12px Inter, sans-serif;
  color: var(--accent, #00f5ff);
  letter-spacing: .02em;
  margin-bottom: 4px;
}
.reaction-toast-sub {
  font: 400 11px Inter, sans-serif;
  color: rgba(255,255,255,.55);
}

/* ===================== ERROR / INFO TOASTS (§17) ===================== */
.toast-container { position: fixed; bottom: 20px; left: 50%; transform: translateX(-50%); z-index: 200; display: flex; flex-direction: column; gap: 8px; pointer-events: none; }
.toast { padding: 10px 20px; border-radius: 10px; font: 600 13px Inter, sans-serif; color: #fff; animation: toastIn .3s ease; pointer-events: auto; }
.toast.error { background: #ff4f68; }
.toast.success { background: #00f5a0; color: #03100f; }
.toast.info { background: rgba(0,245,255,.9); color: #03100f; }
@keyframes toastIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }

/* ===================== PAUSED RIBBON (§15) ===================== */
.paused-ribbon {
  position: sticky;
  top: 0;
  z-index: 10;
  width: 100%;
  padding: 8px 16px;
  text-align: center;
  font: 800 12px Inter, sans-serif;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: #1a1400;
  background: linear-gradient(90deg, var(--gold), #ffd54f);
  box-shadow: 0 2px 12px rgba(255,179,0,.3);
  flex-shrink: 0;
}

/* ===================== COMMISH MENU (§15) ===================== */
.commish-menu-btn {
  width: 34px;
  height: 34px;
  border-radius: 7px;
  border: 1px solid rgba(255,255,255,.14);
  background: rgba(255,255,255,.03);
  color: rgba(255,255,255,.6);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  padding: 0;
  transition: all .14s;
}
.commish-menu-btn:hover {
  background: rgba(0,245,255,.08);
  border-color: rgba(0,245,255,.4);
  color: var(--accent);
}

.commish-menu {
  width: 220px;
  background: #17191f;
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 12px;
  padding: 6px;
  box-shadow: 0 12px 40px rgba(0,0,0,.65), 0 0 0 1px rgba(255,255,255,.04);
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.commish-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  width: 100%;
  height: 40px;
  padding: 0 14px;
  border: none;
  border-radius: 8px;
  background: transparent;
  color: rgba(255,255,255,.8);
  font: 600 12px Inter, sans-serif;
  cursor: pointer;
  transition: background .12s;
  text-align: left;
}
.commish-item:hover {
  background: rgba(255,255,255,.06);
  color: #fff;
}
.commish-item-danger {
  color: #ff4f68 !important;
}
.commish-item-danger:hover {
  background: rgba(255,79,104,.1) !important;
}

.commish-clock-edit {
  cursor: default;
}
.commish-clock-edit:hover {
  background: rgba(255,255,255,.04);
}
.commish-clock-select {
  height: 28px;
  padding: 0 8px;
  background: rgba(255,255,255,.06);
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 6px;
  color: #fff;
  font: 600 11px Inter, sans-serif;
  outline: none;
  cursor: pointer;
}

/* Force Pick button in OTC area */
.commish-force-btn {
  height: 30px;
  padding: 0 12px;
  margin-left: 8px;
  border: 1px solid rgba(255,179,0,.35);
  border-radius: 6px;
  background: rgba(255,179,0,.1);
  color: var(--gold);
  font: 700 10px Inter, sans-serif;
  letter-spacing: .04em;
  text-transform: uppercase;
  cursor: pointer;
  transition: all .14s;
  flex-shrink: 0;
}
.commish-force-btn:hover {
  background: rgba(255,179,0,.2);
  border-color: var(--gold);
}

/* Abort confirmation input */
.abort-confirm-input {
  width: 100%;
  height: 42px;
  background: rgba(255,255,255,.06);
  border: 1px solid rgba(255,79,104,.3);
  border-radius: 9px;
  padding: 0 14px;
  color: #fff;
  font: 600 14px Inter, sans-serif;
  outline: none;
  text-align: center;
  letter-spacing: .1em;
  text-transform: uppercase;
}
.abort-confirm-input::placeholder { color: rgba(255,255,255,.25); text-transform: none; letter-spacing: normal; }
.abort-confirm-input:focus { border-color: #ff4f68; }

/* ===================== CONFETTI (§16) ===================== */
@keyframes confettiFall {
  0% { transform: translateY(-100vh) rotate(0deg); opacity: 1; }
  100% { transform: translateY(100vh) rotate(720deg); opacity: 0; }
}

.confetti-container {
  position: fixed;
  inset: 0;
  z-index: 10000;
  pointer-events: none;
  overflow: hidden;
}
.confetti-piece {
  position: absolute;
  top: -10px;
  width: 10px;
  height: 10px;
  border-radius: 2px;
  opacity: 0.85;
  animation: confettiFall 2s ease-out forwards;
}

/* ===================== RESULTS VIEW (§16) ===================== */
.results-overlay {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 22px;
  background: radial-gradient(circle at 50% 0%, rgba(0,245,255,.08), transparent 60%), rgba(2,3,6,.94);
  backdrop-filter: blur(12px);
}
.results-card {
  width: min(700px, 96vw);
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  border-radius: 20px;
  border: 1px solid rgba(255,255,255,.12);
  background: #0b0c10;
  box-shadow: 0 0 0 1px rgba(0,245,255,.1), 0 40px 120px rgba(0,0,0,.75);
  overflow: hidden;
}
.results-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  padding: 24px 28px 16px;
  border-bottom: 1px solid rgba(255,255,255,.08);
}
.results-eyebrow {
  font: 300 10px "Monument Extended", Impact, sans-serif;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: rgba(255,255,255,.45);
  margin-bottom: 6px;
}
.results-title {
  font: 900 24px/.9 "Monument Extended", Impact, sans-serif;
  text-transform: uppercase;
  color: var(--accent);
  margin: 0;
  text-shadow: 0 0 20px rgba(0,245,255,.2);
}
.results-close {
  width: 34px;
  height: 34px;
  border-radius: 9px;
  border: 1px solid rgba(255,255,255,.14);
  background: rgba(255,255,255,.03);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  color: rgba(255,255,255,.6);
  cursor: pointer;
  padding: 0;
  min-height: 0;
}
.results-tabs {
  display: flex;
  gap: 2px;
  padding: 10px 20px 0;
  overflow-x: auto;
  flex-shrink: 0;
  border-bottom: 1px solid rgba(255,255,255,.06);
}
.results-tab {
  flex: 0 0 auto;
  height: 34px;
  padding: 0 14px;
  border: none;
  border-radius: 8px 8px 0 0;
  background: transparent;
  color: rgba(255,255,255,.45);
  font: 600 11px Inter, sans-serif;
  cursor: pointer;
  white-space: nowrap;
  border-bottom: 2px solid transparent;
  transition: all .12s;
}
.results-tab:hover { color: rgba(255,255,255,.7); }
.results-tab.active {
  color: var(--accent);
  border-bottom-color: var(--accent);
  background: rgba(0,245,255,.04);
}
.results-tab-mine { font-weight: 800; }

.results-body {
  flex: 1;
  overflow-y: auto;
  padding: 16px 20px;
}
.results-roster-hidden { display: none !important; }

.results-roster {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.results-roster-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
}
.results-roster-head h3 {
  font: 800 16px Inter, sans-serif;
  color: #fff;
  margin: 0;
  text-transform: none;
  letter-spacing: normal;
}
.results-roster-mine .results-roster-head h3 { color: var(--accent); }
.results-roster-head span {
  font: 900 12px "Monument Extended", Impact, sans-serif;
  color: var(--accent);
}
.results-bench-divider {
  font: 800 9px Inter, sans-serif;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: rgba(255,255,255,.3);
  padding: 10px 0 4px;
}
.results-slot {
  display: grid;
  grid-template-columns: 42px 1fr auto auto;
  gap: 0 10px;
  align-items: center;
  padding: 8px 12px;
  border: 1px solid rgba(255,255,255,.06);
  border-radius: 8px;
  min-height: 36px;
}
.results-slot.filled { border-color: rgba(255,255,255,.1); }
.results-pos {
  font: 900 9px "Monument Extended", Impact, sans-serif;
  text-align: center;
}
.results-name {
  font: 700 13px Inter, sans-serif;
  color: #fff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.results-slot:not(.filled) .results-name { color: rgba(255,255,255,.25); }
.results-meta {
  font: 500 10px Inter, sans-serif;
  color: rgba(255,255,255,.35);
  white-space: nowrap;
}
.results-pick {
  font: 900 10px "Monument Extended", Impact, sans-serif;
  color: var(--accent);
}

.results-footer {
  display: flex;
  gap: 10px;
  padding: 16px 20px;
  border-top: 1px solid rgba(255,255,255,.08);
  flex-shrink: 0;
}
.results-again {
  flex: 1;
  height: 44px;
  border: none;
  border-radius: 10px;
  background: var(--accent);
  color: #071016;
  font: 800 13px Inter, sans-serif;
  letter-spacing: .04em;
  text-transform: uppercase;
  cursor: pointer;
}
.results-again:hover { opacity: .85; }
.results-share {
  flex: 1;
  height: 44px;
  border: 1px solid rgba(255,255,255,.14);
  border-radius: 10px;
  background: transparent;
  color: rgba(255,255,255,.7);
  font: 600 13px Inter, sans-serif;
  cursor: pointer;
}
.results-share:hover { background: rgba(255,255,255,.04); }

/* Mobile results */
@media (max-width: 600px) {
  .results-overlay { padding: 0; }
  .results-card { width: 100%; max-height: 100vh; max-height: 100dvh; border-radius: 0; border: none; }
  .results-header { padding: 16px; }
  .results-title { font-size: 18px; }
  .results-tabs { padding: 8px 12px 0; }
  .results-body { padding: 12px; }
  .results-footer { padding: 12px; }
  .commish-force-btn { display: none; }
}
