  /* HOST CONSOLE SHELL (simple neutral boxes for platform.hostconsole.js to populate) */
  #host-console-shell {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.75rem;
    margin-bottom: 1rem;
  }

  .host-console-box {
    background: #050b14;
    border: 1px solid #262c3a;
    border-radius: 8px;
    padding: 0.5rem 0.75rem;
    min-height: 40px;
  }

  @media (min-width: 1200px) {
    #host-console-shell {
      grid-template-columns: repeat(2, minmax(0, 1fr));
    }
  }
  /* === PER-SEAT MUTE BUTTON (safe, isolated) === */
#video-grid .seat-mute-btn {
  position: absolute;
  right: 6px;
  bottom: 4px;
  z-index: 20;
  background: rgba(0, 0, 0, 0.85);
  border: 1px solid #ef4444;
  color: #fef2f2;
  font-size: 10px;
  padding: 2px 6px;
  border-radius: 4px;
  font-weight: 700;
  cursor: pointer;
}
/* Visual muted state */
.seat.seat-muted {
  outline: 2px solid #ef4444;
  box-shadow: 0 0 10px rgba(239, 68, 68, 0.7);
}

/* Host-only VOTING CONSOLE above media console */
.vote-console{
  display: none;                 /* HIDDEN BY DEFAULT – JS will show for host only */
  margin-top: 8px;
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid #111827;
  background: #020617;

  /* layout tweaks (merged from the duplicate block) */
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;

  /* existing layout */
  flex-direction: column;
  font-size: 12px;
}
/* Host-only: never show hot stats to players/viewers */
/* KISS: allow hot stats overlay to render for non-host when triggered */
/* body:not(.host-mode) #hot-stats-overlay { display: none !important; } */



/* NEW — when JS marks host, show it */
.vote-console.vote-visible{
  display: flex;
}


    .vote-console-header {
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 8px;
    }

    .vote-console-label {
      text-transform: uppercase;
      letter-spacing: .12em;
      font-size: 11px;
      opacity: .8;
    }

    .vote-console-pill {
      padding: 3px 9px;
      border-radius: 999px;
      border: 1px solid #374151;
      font-size: 11px;
      text-transform: uppercase;
      letter-spacing: .10em;
      opacity: .85;
    }

    .vote-console-pill.live {
      border-color: #22c55e;
      color: #bbf7d0;
      background: #052e16;
    }

    .vote-console-body {
      display: flex;
      gap: 12px;
      margin-top: 4px;
    }

    .vote-controls-row {
      display: flex;
      flex-direction: column;
      align-items: flex-start;
      gap: 6px;
    }

    .vote-controls-row button {
      border-radius: 999px;
      border: 1px solid #4b5563;
      background: #111827;
      color: #f9fafb;
      padding: 4px 10px;
      font-size: 11px;
      cursor: pointer;
      width: 110px;
    }

    .vote-controls-row button:hover {
      background: #1f2937;
    }

    .vote-console-right {
      flex: 1;
    }

    .vote-timer {
      font-size: 11px;
      opacity: .8;
    }

    /* Host-only media console under the arena */
    .media-console {
      margin-top: 8px;
      padding: 8px 10px;
      border-radius: 10px;
      border: 1px solid #111827;
      background: #020617;

      display: none;            /* only enabled for host-mode below */
      flex-direction: column;
      gap: 6px;
      font-size: 12px;
      padding: 12px;
      max-height: 76px;
      overflow: hidden;
      transition: max-height 0.2s ease;
      position: relative;
      z-index: 5;
    }

    .media-console.media-expanded {
      max-height: 160px;
      overflow: auto;
      box-shadow: 0 12px 30px rgba(0, 0, 0, 0.7);
    }

    .media-console-header,
    .media-console-footer {
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 8px;
    }

    .media-console-label {
      text-transform: uppercase;
      letter-spacing: 0.12em;
      font-size: 11px;
      opacity: 0.7;
      white-space: nowrap;
    }

    .media-console-status {
      font-size: 11px;
      opacity: 0.8;
    }

    .media-core-controls {
      display: flex;
      align-items: center;
      gap: 8px;
      flex-wrap: wrap;
      font-size: 11px;
      opacity: 0.9;
    }

    .media-rows {
      display: none;
      flex-direction: column;
      gap: 4px;
      max-height: 150px;
      overflow-y: auto;
      padding-top: 4px;
    }
    .media-btn,
.media-file-trigger {
  padding: 0 6px !important;
  font-size: 10px !important;
}

.media-seat-tag {
  padding: 0 4px !important;
  font-size: 10px !important;
}

.media-title-input {
  width: 100% !important;
  min-width: 0 !important;
}

.media-row-status {
  font-size: 10px;
  text-align: left;
}


    .media-console.media-expanded .media-rows {
      display: flex;
    }

    .media-row {
  display: grid;

  /* V | P2 | Add | Title | U | status */
  grid-template-columns:
    24px   /* V */
    36px   /* P2–P8 */
    88px   /* Add Files */
    180px  /* Title */
    24px   /* U */
    48px;  /* status */

  align-items: center;
  gap: 6px;
  font-size: 11px;
}


    .media-seat-tag {
      font-weight: 600;
      padding: 2px 6px;
      border-radius: 999px;
      border: 1px solid #374151;
      background: #020617;
    }

    .media-btn,
    .media-file-trigger {
      border-radius: 999px;
      border: 1px solid #4b5563;
      background: #111827;
      color: #f9fafb;
      padding: 3px 8px;
      cursor: pointer;
      white-space: nowrap;
      font-size: 11px;
    }

    .media-btn:hover,
    .media-file-trigger:hover {
      background: #1f2937;
    }

    .media-title-input {
      border-radius: 999px;
      border: 1px solid #374151;
      background: #020617;
      color: #f9fafb;
      padding: 3px 8px;
      font-size: 11px;
      min-width: 80px;
    }

    .media-row-status {
      font-size: 10px;
      opacity: 0.75;
      text-align: right;
    }

    .media-console select,
    .media-console button,
    #media-url-input {
      font-size: 12px;
    }

    .media-console select {
      padding: 4px 8px;
      border-radius: 999px;
      border: 1px solid #374151;
      background: #020617;
      color: #f9fafb;
      outline: none;
      max-width: 220px;
    }

    #media-url-input {
      min-width: 220px;
      max-width: 320px;
      padding: 4px 10px;
      border-radius: 999px;
      border: 1px solid #374151;
      background: #020617;
      color: #f9fafb;
      outline: none;
    }

    .media-console-footer button {
      border-radius: 999px;
      border: 1px solid #4b5563;
      background: #111827;
      color: #f9fafb;
      padding: 4px 10px;
      cursor: pointer;
      white-space: nowrap;
    }

    .media-console-footer button:hover {
      background: #1f2937;
    }

    #media-toggle {
      border-radius: 999px;
      border: 1px solid #4b5563;
      background: #111827;
      color: #e5e7eb;
      padding: 3px 8px;
      font-size: 10px;
      cursor: pointer;
      white-space: nowrap;
    }

    #media-toggle:hover {
      background: #1f2937;
    }

    .media-session-list {
      display: none;
      flex-wrap: wrap;
      gap: 4px;
      margin-top: 4px;
    }

    .media-console.media-expanded .media-session-list {
      display: flex;
    }

    .media-session-item {
      border-radius: 999px;
      border: 1px solid #374151;
      background: #020617;
      color: #e5e7eb;
      padding: 3px 8px;
      font-size: 10px;
      cursor: pointer;
      white-space: nowrap;
    }

    .media-session-item:hover {
      background: #111827;
    }

    .media-session-empty {
      font-size: 11px;
      opacity: 0.7;
      padding-top: 4px;
    }

    body.host-mode .media-console {
      display: flex;
    }

    .sr-only {
      position: absolute;
      width: 1px;
      height: 1px;
      padding: 0;
      margin: -1px;
      overflow: hidden;
      clip: rect(0, 0, 0, 0);
      border: 0;
    }
  
.vote-console-round {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 180px;
}

.vc-round-label {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: #9ca3af;
}

.vc-round-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  font-size: 12px;
}

#round-length {
  background: #020617;
  color: #e5e7eb;
  border-radius: 999px;
  border: 1px solid #374151;
  font-size: 11px;
  padding: 2px 8px;
}

.vc-round-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.vc-round-buttons-group {
  display: flex;
  gap: 6px;
}


.vote-console-winners {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 140px;
}

.vc-winner-label {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: #9ca3af;
}

.vc-winner-name {
  font-size: 12px;
  font-weight: 600;
  color: #e5e7eb;
}
/* HOST CONTROL ROW: Player console + voting side by side */
/*.host-control-row {
/*  display: none;           /* host-only; shown when host-mode is active */
 /* margin-top: 8px;
 /* gap: 8px;
/*} */

/* Only show host controls when host-mode is active */
body.host-mode .host-control-row {
  display: flex;
}
/* Host: put Round/Vote buttons LEFT and Podium mini-panel RIGHT */
body.host-mode #vote-console .vc-round-buttons{
  display: flex;
  flex-direction: row;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

body.host-mode #vote-console .vc-round-buttons-group{
  flex: 1 1 auto;
  min-width: 240px;
}

body.host-mode #vote-console #podium-mini-panel{
  margin-top: 0;
  margin-left: auto;
  flex: 0 0 460px;
  max-width: 520px;
}


/* Make both consoles share the row nicely */
.host-control-row > .player-console,
.host-control-row > .vote-console {
  flex: 1;
  min-width: 0;
}

/* PLAYER CONSOLE STYLING */
.player-console {
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid #111827;
  background: #020617;
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 12px;
}

.pc-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.pc-label {
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 11px;
  opacity: 0.8;
}

.pc-body {
  display: flex;
  flex-direction: column;
  gap: 4px;
  max-height: 120px;
  overflow-y: auto;
}

.pc-row {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
}

.pc-seat-tag {
  font-weight: 600;
  padding: 2px 6px;
  border-radius: 999px;
  border: 1px solid #374151;
  background: #020617;
}

.pc-name-input {
  flex: 1;
  min-width: 0;
  border-radius: 999px;
  border: 1px solid #374151;
  background: #020617;
  color: #f9fafb;
  padding: 3px 8px;
  font-size: 11px;
}

.pc-link-btn,
.pc-clear-btn {
  border-radius: 999px;
  border: 1px solid #4b5563;
  background: #111827;
  color: #f9fafb;
  padding: 3px 8px;
  cursor: pointer;
  font-size: 11px;
  white-space: nowrap;
}

.pc-clear-btn {
  padding-inline: 6px;
}

.pc-link-btn:hover,
.pc-clear-btn:hover {
  background: #1f2937;
}

.pc-code-label {
  font-size: 10px;
  opacity: 0.8;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 160px;
}

.pc-hint {
  font-size: 10px;
  opacity: 0.7;
}


.vote-console-winners {
  min-width: 140px;
}
/* =========================================================
   DEMO LOCK — ABSOLUTE ADMIN HIDE FOR NON-HOST
   (P2–P8 + viewers can NEVER see admin UI)
========================================================= */

/* Seat-level admin buttons */
body:not(.host-mode) .seat-controls,
body:not(.host-mode) .seat-mute-btn {
  display: none !important;
}

/* Host consoles (player, voting, media) */
body:not(.host-mode) .host-control-row,
body:not(.host-mode) .player-console,
body:not(.host-mode) .vote-console,
body:not(.host-mode) .media-console {
  display: none !important;
}
/* FORCE media console expansion (override any inline styles) */
.media-console.media-expanded {
  max-height: 260px !important;
  overflow: visible !important;
}

/* =========================================================
   HOST DOCK COMPACT OVERRIDES (LOCKED 2026-01-07)
   Goal: eliminate wasted vertical space under arena WITHOUT
   changing markup or JS behavior. Host CSS is source of truth.
========================================================= */

/* Kill the legacy floating VP1 panel overlay (not part of dock) */
#vp1MediaPanel{
  display:none !important;
  visibility:hidden !important;
  pointer-events:none !important;
}

/* Host row (Player + Voting) */
/*body.host-mode .host-control-row{
  display:flex;
  gap:8px;
  margin-top:6px;
  align-items:stretch;
}

/* Consoles: tighter padding + fixed, scrollable height */
/*body.host-mode .player-console,
body.host-mode .vote-console{
  padding:6px 8px !important;
  border-radius:10px;
  font-size:11px !important;
  line-height:1.2;
  max-height:190px;
  overflow:auto;
}

/* Media console: compact wrapper */
/*body.host-mode .media-console{
  margin-top:6px !important;
  padding:8px !important;
  font-size:11px !important;
  line-height:1.2;
}

/* When collapsed, keep it short (header only). When expanded, cap height + scroll list */
/*body.host-mode .media-console:not(.media-expanded){
  max-height:54px;
  overflow:hidden;
}
body.host-mode .media-console.media-expanded{
  max-height:230px;
  overflow:hidden;
}
body.host-mode .media-console.media-expanded .media-rows{
  max-height:150px;
  overflow:auto;
  padding-right:4px;
}

/* Tighten row layout */
body.host-mode .media-console .media-row{
  gap:4px !important;
  grid-template-columns: auto auto auto minmax(90px, 1fr) auto auto !important;
}

/* Normalize control sizes */
body.host-mode .media-console button,
body.host-mode .media-console input,
body.host-mode .media-console select,
body.host-mode .player-console button,
body.host-mode .player-console input,
body.host-mode .vote-console button,
body.host-mode .vote-console input,
body.host-mode .vote-console select{
  height:26px !important;
  padding:0 8px !important;
  font-size:11px !important;
}

/* Reduce big header/spacing */
body.host-mode .pc-header,
body.host-mode .vote-header,
body.host-mode .media-header{
  margin-bottom:6px !important;
  gap:6px !important;
}

/* Buttons: tighter */
body.host-mode .media-btn,
body.host-mode .media-file-trigger{
  height:26px !important;
  padding:0 10px !important;
}

/* Seat tag: tighter */
body.host-mode .media-seat-tag{
  padding:1px 6px !important;
  font-size:11px !important;
}
/* =========================================================
   SAFE MEDIA ROW COMPRESSION (NO GRID REWRITE)
   Goal: stop the title inputs from consuming the full width.
   This does NOT touch the first columns (V / seat / Add Files),
   so it won’t cause the stacked-card button overlap.
========================================================= */

/* Make the title column a fixed compact width instead of 1fr */
body.host-mode .media-console .media-row{
  grid-template-columns: auto auto auto 240px auto auto !important;
}

/* Hard-cap the title input so it cannot stretch */
body.host-mode .media-console .media-title-input{
  width: 240px !important;
  max-width: 240px !important;
  min-width: 140px !important;
  justify-self: start !important;
}

/* Prevent any child from forcing row-wide expansion */
body.host-mode .media-console .media-row > *{
  min-width: 0 !important;
}
/* =========================================================
   FINAL OVERRIDE — MEDIA ROWS NARROW + CONSOLE NOT FULL-WIDTH
   (Put at very bottom so it beats earlier !important rules)
========================================================= */

body.host-mode .media-console{
  align-self: flex-start !important;     /* stop stretch */
  width: fit-content !important;         /* shrink-wrap */
  max-width: 520px !important;           /* ~1/4 screen */
}

/* Force the micro-columns you want */
body.host-mode .media-console .media-row{
  grid-template-columns: 24px 36px 88px 180px 24px 48px !important;
}

/* Title should fill its 180px column, not grow the row */
body.host-mode .media-console .media-title-input{
  width: 100% !important;
  min-width: 0 !important;
}

/* =========================================================
   HOST DOCK v1 — Layout-only decoupling
   Goal: Voting ALWAYS beside Media. Player Seats = drawer.
   IDs stay the same => JS keeps working.
========================================================= */

body.host-mode .host-dock{
  display:block;
  margin-top: 6px;
}

/* Main dock: 2 columns (Media | Voting) */
body.host-mode .dock-main{
  display:grid;
  grid-template-columns: minmax(380px, 1fr) minmax(380px, 1fr);
  gap: 8px;
  align-items:start;
}

/* Keep consoles compact and scroll internally if needed */
body.host-mode #media-console,
body.host-mode #vote-console{
  display:flex !important;
  margin-top: 0 !important;
  max-height: 210px;
  overflow: auto;
}

/* Media collapsed stays tiny; expanded scrolls */
body.host-mode #media-console:not(.media-expanded){
  max-height: 56px;
  overflow: hidden;
}
body.host-mode #media-console.media-expanded{
  max-height: 240px;
  overflow: hidden;
}
body.host-mode #media-console.media-expanded .media-rows{
  max-height: 150px;
  overflow: auto;
}

/* Utility drawer toggle button */
body.host-mode .dock-util-toggle{
  margin-top: 8px;
  height: 30px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,.18);
  background: rgba(255,255,255,.06);
  color: #fff;
  padding: 0 12px;
  cursor: pointer;
  width: fit-content;
}

/* Drawer hidden by default */
body.host-mode .dock-util-drawer{
  display:none;
  margin-top: 8px;
}

/* Drawer open state */
body.host-mode .dock-util-drawer.open{
  display:block;
}

/* Player console gets a tighter height when shown */
body.host-mode #player-console{
  max-height: 200px;
  overflow: auto;
}

/* Mobile safety: stack columns if narrow */
@media (max-width: 980px){
  body.host-mode .dock-main{
    grid-template-columns: 1fr;
  }
}
/* =========================================================
   HOST UTILITY POPUP — Player Seats / Invite Links
========================================================= */
body.host-mode .host-utility-overlay{
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.45);
  display: none;
  z-index: 999999;
}
body.host-mode .host-utility-overlay.open{
  display: flex;
  align-items: center;
  justify-content: center;
}
body.host-mode .host-utility-panel{
  width: 440px;
  max-width: calc(100vw - 24px);
  max-height: 80vh;
  background: rgba(10,10,12,.96);
  border: 1px solid rgba(255,255,255,.15);
  border-radius: 14px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
body.host-mode .utility-header{
  display:flex;
  align-items:center;
  justify-content:space-between;
  padding:10px 12px;
  border-bottom:1px solid rgba(255,255,255,.12);
  font-weight:700;
  letter-spacing:.2px;
}
body.host-mode .utility-close{
  cursor:pointer;
  background:transparent;
  color:#fff;
  border:1px solid rgba(255,255,255,.25);
  border-radius:10px;
  padding:6px 10px;
}
body.host-mode .utility-body{
  padding: 12px;
  overflow: auto;
}
/* =========================================================
   PODIUM RESULTS OVERLAY — DO NOT BLOCK HOST DOCK CLICKS
   Fix: the podium graphic (round-results) was sitting over the
   host dock, blocking Podium Controls buttons.
   Single-file override: raise it into the arena area and make
   it click-through.
   ========================================================= */
body.host-mode #round-results{
  position: fixed !important;
  left: 50% !important;
  transform: translateX(-50%) !important;

  /* ✅ Host dock clearance ONLY */
  bottom: 280px !important;

  z-index: 9998 !important;
  pointer-events: none !important;
}

/* Host-only safety */
body.host-mode #round-results *{
  pointer-events: none !important;
}


/* Safety: if any child had pointer-events restored elsewhere, kill it */
#round-results *{
  pointer-events: none !important;
}
/* STAGE8 LOCK: chat names must always display */
.chat-user{
  display:inline !important;
  visibility:visible !important;
  opacity:1 !important;
}
/* =========================================================
   HOST CONSOLES MUST ALWAYS SIT ABOVE ARENA OVERLAYS
   ========================================================= */

/* Ensure host dock/consoles create a top stacking layer */
body.host-mode .host-dock,
body.host-mode #host-dock {
  position: relative !important;
  z-index: 5000 !important;
  isolation: isolate;
}

/* Arena overlays should never block clicks below */
body.host-mode #winner-overlay,
body.host-mode #round-results,
body.host-mode .podium-overlay,
body.host-mode .hot-stats-overlay {
  pointer-events: none !important;
}

/* Keep arena seats clickable */
.video-main .seat,
.video-main video {
  pointer-events: auto;
}


/* =========================================================
   FINAL LOCK — Host Dock visibility + Vote gating
   (added 2026-01-17 to stop CSS wars)
========================================================= */

/* Host should NOT see the voter popup panel (player vote UI) */
body.host-mode #vote-panel,
body.host-mode #votePanel,
body.host-mode .vote-panel,
body.host-mode .vote-modal,
body.host-mode .vote-popup,
body.host-mode .vote-overlay-panel{
  display:none !important;
}

/* Hide vote sliders/controls until vote console is marked visible */
#vote-console .vote-console-controls,
#vote-console .vote-console-winner-inputs{
  display:none !important;
}

/* platform.vote.js typically toggles vote-visible on the console */
#vote-console.vote-visible .vote-console-controls{
  display:grid !important;
}
#vote-console.vote-visible .vote-console-winner-inputs{
  display:flex !important;
}
/* =========================================================
   FINAL DOCK AUTHORITY (B) — 2026-01-17
   Only Dock v1 controls host console layout.
   - Main dock: Media | Voting
   - Utility drawer: Player Seats
   - Vote controls gated by .vote-visible
========================================================= */

/* 1) Kill legacy host-control-row system completely */
body.host-mode .host-control-row { display: none !important; }

/* 2) Dock layout: 2 columns */
body.host-mode .host-dock { display: block !important; margin-top: 6px !important; }
body.host-mode .dock-main{
  display: grid !important;
  grid-template-columns: minmax(360px, 1fr) minmax(360px, 1fr) !important;
  gap: 8px !important;
  align-items: start !important;
}

/* 3) Consoles live inside dock-main and scroll internally */
body.host-mode #media-console,
body.host-mode #vote-console{
  display: flex !important;
  margin-top: 0 !important;
  max-height: 220px !important;
  overflow: auto !important;
}

/* Media collapsed/expanded behavior */
body.host-mode #media-console:not(.media-expanded){
  max-height: 56px !important;
  overflow: hidden !important;
}
body.host-mode #media-console.media-expanded{
  max-height: 260px !important;
  overflow: hidden !important;
}
body.host-mode #media-console.media-expanded .media-rows{
  max-height: 160px !important;
  overflow: auto !important;
}

/* 4) Voting console gating (no “always-visible” controls) */
#vote-console .vote-console-controls,
#vote-console .vote-console-winner-inputs{
  display: none !important;
}
#vote-console.vote-visible .vote-console-controls{
  display: grid !important;
}
#vote-console.vote-visible .vote-console-winner-inputs{
  display: flex !important;
}

/* 5) Utility drawer (Player Seats) lives below dock-main */
body.host-mode .dock-util-drawer{ display: none; margin-top: 8px; }
body.host-mode .dock-util-drawer.open{ display: block; }

/* 6) Overlays must never block host dock */
body.host-mode .host-dock { position: relative !important; z-index: 5000 !important; isolation: isolate; }
body.host-mode #winner-overlay,
body.host-mode #round-results,
body.host-mode .podium-overlay,
body.host-mode .hot-stats-overlay{
  pointer-events: none !important;
}
body.host-mode .host-control-row { display: none !important; }
/* =========================================================
   DOCK VISIBILITY + ORGANIZATION FIX (2026-01-17)
   - Prevent Media column from going off-screen
   - Add clear console borders
   - Add internal separators so controls don’t mush together
========================================================= */

/* Console “cards” */
body.host-mode #media-console,
body.host-mode #vote-console{
  border: 1px solid rgba(255,255,255,0.14) !important;
  border-radius: 14px !important;
  background: rgba(0,0,0,0.28) !important;
}

/* Give dock columns breathing room */
body.host-mode .dock-main{
  gap: 10px !important;
}

/* Make sure each column can shrink without pushing the other off-screen */
body.host-mode .dock-col{
  min-width: 0 !important;
}

/* INTERNAL ORGANIZATION: voting console separators */
body.host-mode #vote-console .vote-controls-row{
  padding-bottom: 8px !important;
  border-bottom: 1px solid rgba(255,255,255,0.10) !important;
}

body.host-mode #vote-console .vote-console-controls{
  padding-top: 10px !important;
}

/* Right side groups (round / podium / overlays / inputs) */
body.host-mode #vote-console .vote-right > .vote-console-round,
body.host-mode #vote-console .vote-right > .round-row,
body.host-mode #vote-console .vote-right > .overlay-row,
body.host-mode #vote-console .vote-right > .vote-console-winner-inputs{
  padding-top: 10px !important;
  margin-top: 10px !important;
  border-top: 1px solid rgba(255,255,255,0.10) !important;
}

/* Make overlay rows look like a grouped control bar */
body.host-mode #vote-console .overlay-row{
  gap: 8px !important;
  flex-wrap: wrap !important;
}

/* RESPONSIVE: stack Media over Voting so Media never “disappears” */
@media (max-width: 980px){
  body.host-mode .dock-main{
    grid-template-columns: 1fr !important;
  }
}
.host-dockbar{ display:flex; gap:8px; margin:8px 0; flex-wrap:wrap; }
.dock-tab{ padding:6px 10px; border-radius:999px; }

.dock-panels{
  display:grid;
  grid-template-columns: 1fr 1fr;   /* two columns on wide screens */
  gap:10px;
}
@media (max-width: 980px){
  .dock-panels{ grid-template-columns: 1fr; }
}

.dock-panel{
  border:1px solid rgba(255,255,255,0.15);
  border-radius:16px;
  background: rgba(0,0,0,0.28);
  padding:10px;
  overflow:hidden;
}

.dock-panel:not(.open){ display:none; }
/* =========================================================
   DOCK v2 PANELS — HARD OVERRIDE (2026-01-17)
   You are using dock panels: #dock-media/#dock-vote/#dock-round/#dock-podium/#dock-overlays
   This disables Dock v1 "2-column media|vote" assumptions and
   removes the tiny/collapsed media constraints.
========================================================= */

/* 1) Dock main is a single panel stack */
body.host-mode #dock-main{
  display: block !important;
  gap: 0 !important;
}

/* 2) Panels are real "cards" */
body.host-mode .dock-panel{
  display: none; /* hidden unless open */
  border: 1px solid rgba(255,255,255,0.14) !important;
  border-radius: 16px !important;
  background: rgba(0,0,0,0.28) !important;
  padding: 12px !important;
  margin-top: 8px !important;
  overflow: visible !important;
}

/* Show the active panel */
body.host-mode .dock-panel.open{
  display: block !important;
}

/* 3) Dock tabs bar stays compact */
body.host-mode #host-dockbar{
  display: flex !important;
  gap: 8px !important;
  flex-wrap: wrap !important;
  align-items: center !important;
  margin-bottom: 6px !important;
}

/* Optional: make tabs look consistent */
body.host-mode .dock-tab,
body.host-mode .dock-util-toggle{
  height: 30px !important;
  border-radius: 999px !important;
  border: 1px solid rgba(255,255,255,.18) !important;
  background: rgba(255,255,255,.06) !important;
  color: #fff !important;
  padding: 0 12px !important;
  cursor: pointer !important;
}

/* =========================================================
   MEDIA PANEL — STOP THE TINY COLLAPSED BOX PROBLEM
========================================================= */

/* Media console should be visible/full inside dock panel */
body.host-mode #dock-media #media-console{
  display: flex !important;
  max-height: none !important;
  overflow: visible !important;
  width: 100% !important;
}

/* Kill the collapsed/expanded height clamps when in dock-media */
body.host-mode #dock-media #media-console:not(.media-expanded),
body.host-mode #dock-media #media-console.media-expanded{
  max-height: none !important;
  overflow: visible !important;
}

/* Always show the media rows list area inside media panel */
body.host-mode #dock-media #media-console .media-rows{
  display: flex !important;
  max-height: 220px !important;
  overflow: auto !important;
  padding-top: 6px !important;
}

/* Make Add Files label look like a button */
body.host-mode #dock-media .media-file-trigger{
  display: inline-flex !important;
  align-items: center !important;
  border-radius: 999px !important;
  border: 1px solid rgba(255,255,255,.18) !important;
  background: rgba(255,255,255,.06) !important;
  color: #fff !important;
  padding: 4px 10px !important;
  cursor: pointer !important;
}

/* =========================================================
   VOTE PANEL — KEEP GATING, BUT DON'T BREAK LAYOUT
========================================================= */

/* Vote console should be visible when its panel is open */
body.host-mode #dock-vote #vote-console{
  display: flex !important;
  max-height: none !important;
  overflow: visible !important;
  margin-top: 0 !important;
}

/* Keep your existing "vote-visible" gating */
body.host-mode #dock-vote #vote-console .vote-console-controls,
body.host-mode #dock-vote #vote-console .vote-console-winner-inputs{
  display: none !important;
}
body.host-mode #dock-vote #vote-console.vote-visible .vote-console-controls{
  display: grid !important;
}
body.host-mode #dock-vote #vote-console.vote-visible .vote-console-winner-inputs{
  display: flex !important;
}
/* Host controls must NEVER show unless role-host is set */
.host-only { display: none !important; }
body.role-host .host-only { display: block !important; }
/* =========================================================
   HOST DOCK: RIGHT-SIDE DRAWER BESIDE CHAT
   Paste at VERY END of stage8-host.css
========================================================= */

:root{
  --host-dockbar-h: 44px;
  --host-dockpanel-max: 62vh;
  --host-dockpanel-w: min(520px, 36vw);
  --host-chat-w: 320px; /* adjust if your chat column is wider */
}

/* Bottom tab bar stays full width */
body.host-mode #host-dock{
  position: fixed !important;
  left: 0 !important;
  right: 0 !important;
  bottom: 0 !important;
  z-index: 2500 !important;
  pointer-events: none;
}

body.host-mode #host-dockbar{
  height: var(--host-dockbar-h) !important;
  display: flex !important;
  align-items: center !important;
  gap: 8px !important;
  padding: 6px 10px !important;
  background: rgba(2,6,23,0.92) !important;
  border-top: 1px solid rgba(255,255,255,0.08) !important;
  pointer-events: auto;
}

/* OPENED PANEL becomes a RIGHT drawer BESIDE the chat column */
body.host-mode #dock-main{
  position: fixed !important;

  /* sit just LEFT of chat */
  right: calc(var(--host-chat-w) + 10px) !important;
  left: auto !important;

  width: var(--host-dockpanel-w) !important;
  bottom: calc(var(--host-dockbar-h) + 10px) !important;
  max-height: var(--host-dockpanel-max) !important;

  overflow: hidden !important;
  border: 1px solid rgba(255,255,255,0.10) !important;
  border-radius: 14px !important;
  background: rgba(2,6,23,0.90) !important;
  backdrop-filter: blur(8px) !important;
  -webkit-backdrop-filter: blur(8px) !important;

  pointer-events: auto;
}

/* Panels scroll internally */
body.host-mode #dock-main .dock-panel{
  height: 100% !important;
  overflow: auto !important;
  padding: 10px !important;
}

/* Players drawer follows the same position */
body.host-mode #player-drawer{
  position: fixed !important;

  right: calc(var(--host-chat-w) + 10px) !important;
  left: auto !important;

  width: var(--host-dockpanel-w) !important;
  bottom: calc(var(--host-dockbar-h) + 10px) !important;
  max-height: min(72vh, 720px) !important;

  overflow: auto !important;
  border: 1px solid rgba(255,255,255,0.10) !important;
  border-radius: 14px !important;
  background: rgba(2,6,23,0.92) !important;
  backdrop-filter: blur(8px) !important;
  -webkit-backdrop-filter: blur(8px) !important;

  pointer-events: auto;
}
/* =========================================================
   HOST CHAT FIX — restore clickability & visibility
========================================================= */

/* 1️⃣ Force chat rail ABOVE all dock overlays */
body.host-mode .right-rail{
  position: relative !important;
  z-index: 9000 !important;
  pointer-events: auto !important;
}

/* Ensure chat internals can receive clicks */
body.host-mode .right-rail *{
  pointer-events: auto !important;
}

/* 2️⃣ Dock wrapper itself should NOT intercept clicks */
body.host-mode #host-dock{
  pointer-events: none !important;
}

/* 3️⃣ Only the visible dock pieces may receive input */
body.host-mode #host-dockbar,
body.host-mode #dock-main,
body.host-mode #player-drawer{
  pointer-events: auto !important;
}

/* 4️⃣ Defensive: prevent invisible panels from blocking chat */
body.host-mode #dock-main:not(:has(.dock-panel.open)){
  pointer-events: none !important;
}
/* =========================================================
   FIX: dv-overlay (vote sliders) must be above chat + clickable
   - No layout changes to chat
   - No dock surgery
   - Only affects #dv-overlay when it is active
========================================================= */

/* Keep the overlay itself non-blocking except for the card */
body.host-mode #dv-overlay.dv-overlay{
  position: fixed !important;
  right: 16px !important;
  bottom: 80px !important;

  /* IMPORTANT: beat chat rail (your chat is 9000) */
  z-index: 15000 !important;

  /* Overlay container should NOT eat clicks */
  pointer-events: none !important;
}

/* The actual voting card must be clickable */
body.host-mode #dv-overlay.dv-overlay .dv-card,
body.host-mode #dv-overlay.dv-overlay .dv-card *{
  pointer-events: auto !important;
}

/* If any old rule is making it look like a “sliver”, stop clipping */
body.host-mode #dv-overlay.dv-overlay{
  overflow: visible !important;
}
