:root { --topbar-h: 54px; }
body { display: flex; flex-direction: column; min-height: 100vh; }

/* ===== 顶栏：两个标签页 · 后台 / 导播台 ===== */
.topbar {
  flex: none; height: var(--topbar-h); display: flex; align-items: center; gap: 20px;
  padding: 0 18px; background: #0d1117; color: #e5e7eb;
  border-bottom: 1px solid #1f2937; position: sticky; top: 0; z-index: 200;
}
.brand { display: flex; align-items: center; gap: 10px; }
.brand-logo {
  width: 32px; height: 32px; border-radius: 9px; display: grid; place-items: center;
  background: linear-gradient(135deg, #f59e0b, #ef4444); color: #fff; font-weight: 800; font-size: 17px;
}
.brand-name { font-weight: 800; font-size: 15px; letter-spacing: 1px; line-height: 1.15; }
.brand-sub { font-size: 9px; color: #6b7280; letter-spacing: 1.6px; }
.top-tabs { display: flex; gap: 4px; background: #161e2b; padding: 4px; border-radius: 11px; }
.top-tab {
  border: 0; background: transparent; color: #9ca3af; font-weight: 800; font-size: 13.5px;
  padding: 7px 20px; border-radius: 8px; cursor: pointer; transition: .15s; white-space: nowrap;
}
.top-tab:hover:not(:disabled) { color: #e5e7eb; }
.top-tab.active { background: #4f46e5; color: #fff; box-shadow: 0 4px 14px rgba(79, 70, 229, .45); }
.top-tab:disabled { opacity: .32; cursor: not-allowed; }
.top-right { margin-left: auto; display: flex; align-items: center; gap: 8px; }
.top-act { display: flex; flex-direction: column; line-height: 1.25; text-align: right; max-width: 280px; }
.top-act span { font-size: 9.5px; color: #6b7280; letter-spacing: 1.2px; }
.top-act b { font-size: 13px; color: #ffd166; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.top-btn {
  border: 1px solid #374151; background: #1f2937; color: #cbd5e1; font-size: 12.5px; font-weight: 700;
  padding: 7px 12px; border-radius: 8px; cursor: pointer; white-space: nowrap;
}
.top-btn:hover { border-color: #6b7280; color: #fff; }

/* 后台里的二级导航（活动列表 / 控制台 / 报表） */
.subnav { flex: none; display: flex; gap: 6px; padding: 12px 28px 0; flex-wrap: wrap; }
.nav-item {
  text-align: left; background: #eef2f7; border: 1px solid transparent; color: #475569;
  padding: 8px 14px; border-radius: 9px; font-weight: 700; font-size: 13px; transition: .15s; cursor: pointer;
}
.nav-item:hover:not(:disabled) { background: #e0e7ff; color: #3730a3; }
.nav-item.active { background: #4f46e5; color: #fff; }
.nav-item:disabled { opacity: .4; cursor: default; }

.main { flex: 1; min-width: 0; width: 100%; padding: 18px 28px 60px; max-width: 1500px; }
.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 20px; flex-wrap: wrap; }
.page-title { font-size: 24px; font-weight: 800; margin: 0; }
.page-sub { color: var(--muted); font-size: 13px; margin-top: 4px; }
.grid { display: grid; gap: 14px; }
.grid.cards { grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); }
.grid.games { grid-template-columns: repeat(auto-fill, minmax(215px, 1fr)); }
.grid.two { grid-template-columns: repeat(auto-fit, minmax(360px, 1fr)); }
.pad { padding: 18px; }
.act-card { padding: 18px; position: relative; transition: .15s; }
.act-card:hover { transform: translateY(-2px); box-shadow: 0 12px 30px rgba(31,41,55,.12); }
.act-name { font-size: 17px; font-weight: 800; margin-bottom: 6px; }
.act-meta { color: var(--muted); font-size: 12px; display: flex; gap: 12px; flex-wrap: wrap; }
.act-actions { display: flex; gap: 8px; margin-top: 16px; flex-wrap: wrap; }
.game-card { padding: 16px; position: relative; transition: .15s; }
.game-card.live { border-color: var(--primary); box-shadow: 0 0 0 2px var(--primary-soft); }
.game-icon { font-size: 26px; margin-bottom: 6px; }
.game-name { font-weight: 800; font-size: 15px; }
.game-desc { color: var(--muted); font-size: 12px; min-height: 34px; margin: 6px 0 12px; }
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); margin-bottom: 18px; flex-wrap: wrap; }
.tab {
  border: 0; background: transparent; padding: 10px 14px; font-weight: 700; color: var(--muted);
  border-bottom: 2px solid transparent;
}
.tab.active { color: var(--primary); border-color: var(--primary); }
.link-box {
  display: flex; gap: 8px; align-items: center; background: var(--panel-2); border: 1px solid var(--line);
  border-radius: 10px; padding: 8px 10px; margin-bottom: 8px;
}
.link-box input { border: 0; background: transparent; flex: 1; min-width: 0; font-size: 12px; color: var(--muted); }
table.tbl { width: 100%; border-collapse: collapse; font-size: 13px; }
table.tbl th, table.tbl td { text-align: left; padding: 9px 10px; border-bottom: 1px solid var(--line); }
table.tbl th { color: var(--muted); font-weight: 700; font-size: 12px; background: var(--panel-2); }
table.tbl tr:hover td { background: #fafbff; }
.setting-row { display: grid; grid-template-columns: 150px 1fr; gap: 10px; align-items: center; margin-bottom: 10px; }
.switch { width: 42px; height: 24px; border-radius: 20px; border: 0; background: #d1d5db; position: relative; transition: .2s; }
.switch::after { content: ''; position: absolute; width: 18px; height: 18px; border-radius: 50%; background: #fff; top: 3px; left: 3px; transition: .2s; }
.switch.on { background: var(--primary); }
.switch.on::after { left: 21px; }
.modal-mask {
  position: fixed; inset: 0; background: rgba(15,23,42,.45); z-index: 100;
  display: grid; place-items: center; padding: 20px;
}
.modal { background: #fff; border-radius: 16px; width: min(620px, 100%); max-height: 86vh; overflow: auto; box-shadow: 0 30px 80px rgba(0,0,0,.25); }
.modal-head { display: flex; justify-content: space-between; align-items: center; padding: 16px 20px; border-bottom: 1px solid var(--line); }
.modal-body { padding: 20px; }
.modal-foot { padding: 14px 20px; border-top: 1px solid var(--line); display: flex; justify-content: flex-end; gap: 8px; }
.qr { width: 168px; height: 168px; border: 1px solid var(--line); border-radius: 10px; }
@media (max-width: 900px) {
  .brand-txt { display: none; }
  .top-tab { padding: 7px 12px; font-size: 12.5px; }
  .top-act { max-width: 130px; }
  .main { padding: 14px 16px 50px; }
  .subnav { padding: 10px 16px 0; }
}

/* 登录 */
.login-wrap { min-height: 72vh; display: grid; place-items: center; }
.login-card { width: min(390px, 100%); text-align: center; }

/* KTV 控制台 */
.kv-now { display: flex; flex-wrap: wrap; gap: 14px; align-items: center; justify-content: space-between;
  padding: 14px 16px; border-radius: 12px; background: linear-gradient(135deg, #eef2ff, #f8fafc); border: 1px solid #e0e7ff; margin-top: 12px; }
.kv-now-main { min-width: 200px; }
.kv-now-name { font-size: 18px; font-weight: 800; margin-bottom: 3px; }
.kv-queue { display: flex; flex-direction: column; gap: 8px; }
.kv-q { display: flex; align-items: center; gap: 10px; padding: 9px 12px; border: 1px solid var(--line); border-radius: 11px; background: var(--panel-2); }
.kv-q-no { width: 22px; text-align: center; font-weight: 900; color: var(--muted); font-size: 13px; flex: none; }
.kv-q-info { flex: 1; min-width: 0; }
.kv-q-info > div:first-child { font-weight: 700; font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* ============================================================
   导播台（主控台）
   ============================================================ */
/* 铺在顶栏下方，不盖住标签页；切到后台只是 hidden，iframe 不销毁 */
.dir { position: fixed; top: var(--topbar-h); left: 0; right: 0; bottom: 0; display: flex; flex-direction: column; background: #0d1117; z-index: 90; }
body.is-dir .subnav, body.is-dir .main { display: none; }
.dir-main { flex: 1; min-height: 0; display: flex; }

.dir-stage { flex: 1; min-width: 0; position: relative; padding: 12px 14px 14px; display: flex; flex-direction: column; gap: 10px; }
.dir-fit { flex: 1; min-height: 0; min-width: 0; display: flex; align-items: center; justify-content: center; overflow: hidden; }
/* 预览固定按 1920×1080 渲染，再用 zoom 整体缩放，保证导播台看到的就是大屏真实画面 */
.dir-frame { flex: none; width: 1920px; height: 1080px; border-radius: 10px; overflow: hidden; background: #000;
  box-shadow: 0 10px 40px rgba(0,0,0,.55), 0 0 0 1px rgba(148,163,184,.18); }
/* 预览可以点、可以拖二维码；页面里只有二维码响应鼠标，别的都点不动 */
.dir-preview { width: 1920px; height: 1080px; border: 0; background: #000; display: block; }
.dir-stage-tip { flex: none; display: flex; gap: 10px; align-items: center; align-self: flex-start;
  max-width: 100%; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  padding: 6px 14px; border-radius: 9px; background: #161e2b; border: 1px solid #1f2937; color: #cbd5e1; font-size: 13px; }
.dir-stage-tip > span { flex: none; }
.dir-stage-tip b { flex: 0 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.dir-stage-tip b { color: #ffd166; }
.dir-stage-tip .dot { width: 7px; height: 7px; border-radius: 50%; background: #22c55e; box-shadow: 0 0 8px #22c55e; }
.dir-stage-tip.idle .dot { background: #64748b; box-shadow: none; }

.dir-panel { width: clamp(300px, 23vw, 380px); flex: none; background: #f8fafc; border-left: 1px solid #1f2937; display: flex; flex-direction: column; overflow: hidden; }

/* ===== KTV 点歌板：夹在投屏区和右侧菜单之间，只在 KTV 环节出现 ===== */
.dir-ktv { width: clamp(228px, 17vw, 300px); flex: none; display: flex; flex-direction: column;
  background: #0e1520; border-left: 1px solid #1e293b; overflow: hidden; }
.dir-ktv[hidden] { display: none; }
.dkb-head { flex: none; padding: 14px 14px 10px; border-bottom: 1px solid #1e293b; }
.dkb-title { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.dkb-title b { font-size: 14px; color: #e2e8f0; letter-spacing: .5px; }
.dkb-title span { font-size: 11.5px; color: #64748b; }
.dkb-clear { flex: none; padding: 4px 9px; border-radius: 6px; font-size: 11px; font-weight: 700; cursor: pointer;
  background: transparent; color: #f87171; border: 1px solid rgba(248, 113, 113, .35); }
.dkb-clear:hover { background: rgba(248, 113, 113, .14); }

.dkb-list { flex: 1; min-height: 0; overflow-y: auto; padding: 8px; }
.dkb-list::-webkit-scrollbar { width: 6px; }
.dkb-list::-webkit-scrollbar-thumb { background: #263449; border-radius: 6px; }

.dkb-row { display: flex; align-items: center; gap: 8px; padding: 8px 8px 8px 6px; border-radius: 9px;
  background: #151f2e; border: 1px solid #1e2b3d; margin-bottom: 6px; transition: .15s; }
.dkb-row:hover { background: #1a2637; border-color: #2b3d55; }
.dkb-row.n1 { background: linear-gradient(100deg, #1c2b45, #17233a); border-color: #2f4570; }
.dkb-no { flex: none; width: 20px; text-align: center; font-size: 11.5px; font-weight: 800; color: #64748b;
  font-variant-numeric: tabular-nums; }
.dkb-row.n1 .dkb-no { color: #7dd3fc; }
.dkb-info { flex: 1; min-width: 0; }
.dkb-name { font-size: 13px; font-weight: 700; color: #e6edf7; line-height: 1.35; }
.dkb-sub { font-size: 11px; color: #7c8ba1; margin-top: 2px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dkb-op { flex: none; width: 24px; height: 24px; border-radius: 6px; cursor: pointer; font-size: 12px; line-height: 1;
  background: #1f2c3f; color: #93a6c0; border: 1px solid #2a3b52; transition: .15s; }
.dkb-op:hover { background: #2a3b52; color: #e2e8f0; }
.dkb-op.del:hover { background: rgba(248, 113, 113, .2); color: #fca5a5; border-color: rgba(248, 113, 113, .45); }
.dkb-empty { padding: 40px 16px; text-align: center; font-size: 12px; color: #5b6b80; line-height: 1.8; }

/* 歌名太长：鼠标移上去来回滚动 */
.dk-marquee { overflow: hidden; white-space: nowrap; }
.dk-marquee > i { display: inline-block; font-style: normal; }
.dk-marquee:hover > i { animation: dkb-run var(--dur, 5s) linear infinite alternate; }
@keyframes dkb-run {
  0%, 14% { transform: translateX(0); }
  86%, 100% { transform: translateX(var(--shift, 0)); }
}

.dp-head { padding: 16px 18px 12px; background: #fff; border-bottom: 1px solid var(--line); }
.dp-no { font-size: 11px; color: var(--muted); letter-spacing: 1px; margin-bottom: 4px; }
.dp-title { font-size: 19px; font-weight: 800; line-height: 1.3; }
.dp-meta { font-size: 12px; color: var(--muted); margin-top: 4px; }
.dp-body { flex: 1; overflow-y: auto; padding: 14px 18px 20px; }
.dp-sec { margin-bottom: 18px; }
.dp-sec-t { font-size: 11px; font-weight: 800; color: var(--muted); letter-spacing: 1px; margin-bottom: 8px; }
.dp-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.dp-grid.one { grid-template-columns: 1fr; }
.dir-btn { border: 1px solid var(--line); background: #fff; color: var(--text); border-radius: 10px; padding: 11px 10px;
  font-size: 13px; font-weight: 700; cursor: pointer; transition: .15s; text-align: center; }
.dir-btn:hover { border-color: #4f46e5; color: #4f46e5; }
.dir-btn:active { transform: scale(.97); }
.dir-btn.primary { background: #4f46e5; border-color: #4f46e5; color: #fff; }
.dir-btn.primary:hover { filter: brightness(1.1); color: #fff; }
.dir-btn.danger { background: #fff; border-color: #fecaca; color: #dc2626; }
.dir-btn.danger:hover { background: #fef2f2; border-color: #dc2626; color: #dc2626; }
.dir-btn.ghost { background: #f1f5f9; border-color: transparent; }
.dir-btn:disabled { opacity: .45; cursor: not-allowed; }
.dir-btn.wide { grid-column: 1 / -1; }

.dp-sfx { display: grid; grid-template-columns: repeat(3, 1fr); gap: 7px; }
.dp-sfx .dir-btn { padding: 9px 4px; font-size: 12px; }

.dp-empty { text-align: center; color: var(--muted); font-size: 13px; padding: 40px 10px; line-height: 1.8; }

/* 导播台 · KTV 点歌清单 */
.dk-total { color: var(--muted); font-weight: 600; letter-spacing: 0; margin-left: 4px; }
.dk-clear { float: right; border: 0; background: transparent; color: #dc2626; font-size: 11px; font-weight: 700; cursor: pointer; padding: 0; }
.dk-cur { display: flex; align-items: center; gap: 9px; padding: 9px 11px; border-radius: 11px;
  background: linear-gradient(135deg, #4338ca, #6d28d9); color: #fff; margin-bottom: 8px; }
.dk-sound { font-size: 15px; animation: dkPulse 1.6s ease-in-out infinite; }
@keyframes dkPulse { 0%, 100% { opacity: .45; } 50% { opacity: 1; } }
.dk-cur-info { min-width: 0; }
.dk-cur-name { font-size: 13.5px; font-weight: 800; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dk-cur-sub { font-size: 11.5px; opacity: .82; margin-top: 2px; }
.dk-prog { display: flex; align-items: center; gap: 7px; margin: -2px 0 9px; }
.dk-prog input[type=range] { flex: 1; accent-color: #6366f1; height: 4px; }
.dk-prog input[type=range]:disabled { opacity: .4; }
.dk-t { font-size: 11px; color: var(--muted); font-variant-numeric: tabular-nums; width: 34px; text-align: center; }
.dk-list { display: flex; flex-direction: column; gap: 5px; max-height: 220px; overflow-y: auto; }
.dk-row { display: flex; align-items: center; gap: 7px; padding: 7px 9px; border: 1px solid var(--line);
  border-radius: 9px; background: #fff; }
.dk-no { width: 18px; text-align: center; font-weight: 900; font-size: 12px; color: var(--muted); flex: none; }
.dk-info { flex: 1; min-width: 0; }
.dk-name { font-size: 12.5px; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dk-sub { font-size: 11px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dk-op { flex: none; width: 24px; height: 24px; border-radius: 7px; border: 1px solid var(--line);
  background: #f8fafc; color: #475569; font-size: 12px; font-weight: 900; cursor: pointer; line-height: 1; }
.dk-op:hover { border-color: #4f46e5; color: #4f46e5; }
.dk-op.del:hover { border-color: #dc2626; color: #dc2626; background: #fef2f2; }
.dk-empty { padding: 14px 6px; text-align: center; color: var(--muted); font-size: 12px; }
.dk-vol { display: flex; align-items: center; gap: 8px; margin-bottom: 7px; }
.dk-vol-k { width: 42px; flex: none; font-size: 12px; color: #475569; font-weight: 700; }
.dk-vol input { flex: 1; accent-color: #4f46e5; }
.dk-vol b { width: 34px; text-align: right; font-size: 11.5px; color: var(--muted); font-variant-numeric: tabular-nums; }
/* 总音量：一条压两条，给个浅底色跟下面两条区分开 */
.dk-vol-master { background: #eef2ff; border: 1px solid #e0e7ff; border-radius: 9px; padding: 6px 8px; }
.dk-vol-master .dk-vol-k { color: #4338ca; }
.dk-vol-master b { color: #4338ca; font-weight: 800; }
.dk-mic-row { display: flex; gap: 8px; margin-top: 4px; }
.dk-tip { margin-top: 7px; font-size: 10.5px; color: var(--muted); line-height: 1.6; }

/* MV 字幕处理：四选一分段控件 */
.dk-seg { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.dk-seg button { padding: 7px 4px; border-radius: 8px; font-size: 12px; font-weight: 700; cursor: pointer;
  background: #f1f5f9; color: #64748b; border: 1px solid #e2e8f0; transition: .15s; }
.dk-seg button:hover { background: #e8edf5; color: #475569; }
.dk-seg button.on { background: #4f46e5; color: #fff; border-color: #4338ca;
  box-shadow: 0 3px 10px rgba(79, 70, 229, .3); }

/* 大屏歌词字号 A－ / A＋ */
.dk-font { display: flex; align-items: center; gap: 7px; }
.dk-font b { flex: 1; text-align: center; font-size: 13px; font-weight: 800; color: var(--text);
  font-variant-numeric: tabular-nums; }
.dk-font .dir-btn { flex: none; padding: 8px 0; min-width: 54px; font-size: 12px; }

/* 流程条 */
.dir-flow { height: 124px; flex: none; background: #111827; border-top: 1px solid #1f2937; display: flex; align-items: center; gap: 10px; padding: 0 14px; }
.dir-track { flex: 1; display: flex; align-items: center; gap: 8px; overflow-x: auto; overflow-y: hidden; padding: 8px 2px; scroll-behavior: smooth; }
.dir-track::-webkit-scrollbar { height: 6px; }
.dir-track::-webkit-scrollbar-thumb { background: #374151; border-radius: 3px; }

.dir-card { flex: none; width: 140px; height: 88px; border-radius: 10px; padding: 10px 11px 22px; cursor: pointer; position: relative;
  background: #1f2937; border: 1px solid #374151; transition: .15s; user-select: none; }
.dir-card:hover { border-color: #6b7280; transform: translateY(-1px); }
.dir-card.current { background: linear-gradient(135deg, #4f46e5, #7c3aed); border-color: #a78bfa; box-shadow: 0 0 0 2px rgba(167,139,250,.4), 0 8px 24px rgba(79,70,229,.4); }
.dir-card.done { opacity: .5; }
.dir-card.done .dc-title { text-decoration: line-through; }
.dir-card.dragging { opacity: .3; }
.dir-card.drop-left { box-shadow: -3px 0 0 #22d3ee; }
.dir-card.drop-right { box-shadow: 3px 0 0 #22d3ee; }
.dc-no { font-size: 10px; color: #9ca3af; font-weight: 800; }
.dir-card.current .dc-no { color: rgba(255,255,255,.75); }
.dc-title { font-size: 13px; font-weight: 800; color: #e5e7eb; line-height: 1.28; margin-top: 3px;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.dir-card.current .dc-title { color: #fff; }
.dc-type { position: absolute; right: 8px; bottom: 7px; font-size: 10px; color: #6b7280; }
.dir-card.current .dc-type { color: rgba(255,255,255,.7); }
.dir-card .dc-game { position: absolute; left: 8px; bottom: 6px; font-size: 10px; color: #22d3ee; font-weight: 700; }

.dir-add { flex: none; width: 56px; height: 88px; border-radius: 10px; border: 1px dashed #374151; background: transparent;
  color: #6b7280; font-size: 22px; cursor: pointer; }
.dir-add:hover { border-color: #4f46e5; color: #a78bfa; }

/* 底部开关栏 */
.dir-bottom { height: 58px; flex: none; background: #0d1117; border-top: 1px solid #1f2937; display: flex; align-items: center; gap: 8px; padding: 0 14px; overflow-x: auto; }
.dir-tog { flex: none; height: 36px; padding: 0 14px; border-radius: 9px; border: 1px solid #374151; background: #1f2937;
  color: #9ca3af; font-size: 13px; font-weight: 700; cursor: pointer; display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; transition: .15s; }
.dir-tog:hover { border-color: #6b7280; }
/* 开：实心绿 + 白字 + 亮灯；关：深灰沉下去。隔着两米也能一眼分清 */
.dir-tog.on { background: #16a34a; border-color: #22c55e; color: #fff; box-shadow: 0 0 0 1px rgba(34, 197, 94, .35), 0 6px 16px rgba(22, 163, 74, .38); }
.dir-tog.off { background: #151a23; border-color: #2a323e; color: #5c6674; }
.dir-tog.on:hover { background: #18b352; }
.dir-tog.off:hover { border-color: #475569; color: #94a3b8; }
.dir-tog.back { background: #4f46e5; border-color: #4f46e5; color: #fff; }
.dir-tog.back:hover { background: #5b52ea; }
.dir-tog.plain { background: #1f2937; border-color: #374151; color: #9ca3af; }
.dir-tog .led { width: 7px; height: 7px; border-radius: 50%; background: #333c4a; flex: none; }
.dir-tog.on .led { background: #d1fae5; box-shadow: 0 0 8px #86efac; }
.dir-tog .dir-song { font-style: normal; font-size: 11px; font-weight: 700; opacity: .82; margin-left: 3px;
  max-width: 104px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dir-tog.off .dir-song { opacity: .6; }
.dir-sep { width: 1px; height: 26px; background: #1f2937; flex: none; margin: 0 4px; }
.dir-vol { flex: none; display: flex; align-items: center; gap: 7px; color: #9ca3af; font-size: 12px; }
.dir-vol input { width: 92px; accent-color: #22c55e; }
.dir-vol b { width: 24px; text-align: right; color: #e5e7eb; font-size: 12px; font-variant-numeric: tabular-nums; }
.dir-spacer { flex: 1; }
.dir-clock { color: #d1d5db; font-variant-numeric: tabular-nums; font-size: 15px; font-weight: 800; letter-spacing: 1px; }

/* 音乐选择菜单 */
.bgm-menu { position: fixed; z-index: 220; width: 306px; max-height: 64vh; display: flex; flex-direction: column;
  background: #fff; border: 1px solid var(--line); border-radius: 14px; box-shadow: 0 18px 50px rgba(0, 0, 0, .38); overflow: hidden; }
.bm-head { padding: 12px 14px; font-weight: 800; font-size: 13px; border-bottom: 1px solid var(--line); background: #f8fafc; }
.bm-now { display: flex; align-items: center; gap: 8px; padding: 8px 10px; background: #ecfdf5;
  border-bottom: 1px solid #a7f3d0; font-size: 11.5px; color: #065f46; }
.bm-now span { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bm-now b { font-weight: 800; }
.bm-stop { flex: none; padding: 4px 9px; border-radius: 7px; border: 1px solid #10b981; background: #fff;
  color: #047857; font-size: 11.5px; font-weight: 700; cursor: pointer; }
.bm-stop:hover { background: #10b981; color: #fff; }
.bm-list { overflow: auto; padding: 6px; }
.bm-t { font-size: 11px; font-weight: 800; color: var(--muted); letter-spacing: .5px; padding: 9px 10px 4px; }
.bm-tip { margin: 6px 8px 0; padding: 7px 10px; border-radius: 8px; background: #fef3c7; color: #92400e; font-size: 11.5px; line-height: 1.5; }
.bm-row { width: 100%; display: flex; align-items: center; gap: 8px; padding: 9px 10px; border: 0;
  background: transparent; border-radius: 9px; text-align: left; cursor: pointer; }
.bm-row:hover { background: #eef2ff; }
.bm-row.cur { background: #e0e7ff; }
.bm-name { flex: 1; min-width: 0; font-weight: 700; font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bm-sub { font-size: 11px; color: var(--muted); white-space: nowrap; }
.bm-tick { color: #4f46e5; font-style: normal; font-weight: 900; }
.bm-empty { padding: 18px; text-align: center; color: var(--muted); font-size: 12px; }
.bm-foot { display: flex; gap: 6px; padding: 8px; border-top: 1px solid var(--line); background: #f8fafc; }
.bm-foot .dir-btn { flex: 1; font-size: 12px; padding: 8px 6px; }

/* 对局记录（导播台右侧） */
.dp-matches { display: flex; flex-direction: column; gap: 7px; }
.dm-row { background: #fff; border: 1px solid var(--line); border-radius: 9px; padding: 8px 10px; }
.dm-no { font-size: 11px; font-weight: 800; color: #4f46e5; letter-spacing: .5px; }
.dm-list { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 5px; }
.dm-r { font-size: 12px; color: var(--text); background: #f1f5f9; border-radius: 6px; padding: 2px 7px; }
.dm-r.top { background: #fef3c7; color: #92400e; font-weight: 800; }
.dm-r i { font-style: normal; color: var(--muted); margin-left: 4px; font-size: 11px; }

/* ============ 活动设置（2026-11-23 照喜乐动后台结构）============
 * 子页签 + 分组模块清单：每行一个模块，右端「设置 + 开关」。
 * 开关真生效：关掉的模块不出现在玩法控制和导播台里。 */
.set-subtabs { display: flex; gap: 6px; border-bottom: 1px solid var(--line); margin-bottom: 16px; }
.set-subtab { border: 0; background: transparent; padding: 10px 18px; font-size: 14px; font-weight: 700;
  color: var(--muted); border-radius: 8px 8px 0 0; border-bottom: 2px solid transparent; margin-bottom: -1px; }
.set-subtab:hover { color: var(--primary); background: #f7f8fc; }
.set-subtab.active { color: var(--primary); border-bottom-color: var(--primary); background: #fff; }
.set-body { max-width: 1080px; }
.set-sec { background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 16px 18px; margin-bottom: 14px; }
.set-sec-h { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 12px; }
.set-sec-h b { font-size: 15px; }
.set-info { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px 20px; }
.set-f { display: flex; align-items: center; gap: 10px; }
.set-f > label { flex: none; width: 78px; font-size: 13px; color: var(--muted); }
.set-f > .input, .set-f > .select { flex: 1; min-width: 0; }
.set-ro { flex: 1; font-size: 13px; color: #64748b; font-family: ui-monospace, Consolas, monospace;
  background: #f7f8fc; border-radius: 8px; padding: 8px 10px; }
.set-mods { display: flex; flex-direction: column; gap: 8px; }
.set-mod { display: flex; align-items: center; gap: 14px; padding: 12px 14px; border-radius: 12px;
  background: #fafbfe; border: 1px solid #eef0f6; transition: .15s; }
.set-mod.on { background: #f6f7ff; border-color: #dcd9fb; }
.set-mod.todo { opacity: .62; }
.set-mod-ico { width: 38px; height: 38px; flex: none; border-radius: 11px; display: grid; place-items: center;
  font-size: 19px; background: #fff; border: 1px solid #e8ebf3; }
.set-mod-main { flex: 1; min-width: 0; }
.set-mod-nm { font-size: 14px; font-weight: 800; display: flex; align-items: center; gap: 7px; }
.set-mod-desc { font-size: 12px; color: var(--muted); margin-top: 3px; line-height: 1.5; }
.set-mod-act { flex: none; display: flex; align-items: center; gap: 12px; }
.set-mod-main .row { align-items: center; }
.set-mod-main .input { max-width: 420px; }
.set-link { border: 0; background: transparent; color: var(--primary); font-size: 13px; font-weight: 700; padding: 4px 6px; border-radius: 6px; }
.set-link:hover { background: #eef2ff; }
.set-todo { font-size: 12px; color: #94a3b8; background: #f1f5f9; border-radius: 999px; padding: 3px 10px; }
.set-hot { font-size: 10px; font-weight: 900; color: #fff; background: linear-gradient(135deg, #f59e0b, #ef4444);
  border-radius: 6px; padding: 1px 6px; letter-spacing: .5px; }
.set-tip { font-size: 12px; color: var(--muted); padding: 2px 4px 20px; }
.set-tip b { color: var(--primary); }
