:root { --bg:#14161c; --card:#1e222b; --line:#2e3441; --text:#e8eaf0; --muted:#8b93a7; --accent:#6c8cff; --ok:#4cc38a; --warn:#f0b34a; --bad:#ef6a6a; }
* { box-sizing: border-box; }
body { margin:0; background:var(--bg); color:var(--text); font:15px/1.45 system-ui,-apple-system,Segoe UI,Roboto,sans-serif; }
.hidden { display:none !important; }
.page { max-width:980px; margin:0 auto; padding:20px 16px 60px; }
h1 { margin:30px 0 6px; font-size:32px; }
h2 { margin:0 0 10px; font-size:18px; }
.lead { color:var(--muted); max-width:640px; }
.card { background:var(--card); border:1px solid var(--line); border-radius:12px; padding:16px; margin:14px 0; }
label { display:block; color:var(--muted); font-size:13px; margin-bottom:10px; }
input, select, button { font:inherit; color:var(--text); background:#272c38; border:1px solid var(--line); border-radius:8px; padding:8px 10px; }
input, select { width:100%; }
label input { margin-top:4px; }
button { cursor:pointer; width:auto; }
button:hover:not(:disabled) { border-color:var(--accent); }
button:disabled { opacity:.45; cursor:default; }
button.primary { background:var(--accent); border-color:var(--accent); color:#fff; font-weight:600; }
button.rec { background:var(--bad); border-color:var(--bad); color:#fff; font-weight:600; }
button.small { padding:3px 8px; font-size:12px; }
button.big { padding:12px 20px; font-size:16px; }
.row { display:flex; gap:8px; align-items:center; flex-wrap:wrap; }
.row > input { flex:1; min-width:120px; }
.or { text-align:center; color:var(--muted); margin:12px 0; }
.topbar { display:flex; justify-content:space-between; gap:12px; align-items:center; flex-wrap:wrap; padding:8px 0 14px; border-bottom:1px solid var(--line); margin-bottom:14px; }
.code { font-size:20px; letter-spacing:3px; margin:0 8px; }
.players { display:flex; gap:6px; flex-wrap:wrap; }
.chip { display:inline-flex; align-items:center; gap:6px; background:#272c38; border:1px solid var(--line); border-radius:999px; padding:2px 10px; font-size:13px; }
.dot { width:9px; height:9px; border-radius:50%; background:var(--muted); display:inline-block; }
.dot.on { background:var(--ok); }
video { width:100%; max-height:420px; background:#000; border-radius:10px; }
canvas { width:100%; height:110px; background:#10131a; border-radius:8px; cursor:pointer; display:block; }
.muted { color:var(--muted); }
.ok { color:var(--ok); } .warn { color:var(--warn); } .bad { color:var(--bad); }
table { width:100%; border-collapse:collapse; }
th { text-align:left; color:var(--muted); font-weight:500; font-size:12px; padding:4px; }
td { padding:4px; vertical-align:middle; }
td input[type=number] { width:80px; }
td select { min-width:110px; }
.seglist td { border-top:1px solid var(--line); }
.bar { height:8px; background:#272c38; border-radius:4px; overflow:hidden; }
.bar > i { display:block; height:100%; background:var(--accent); width:0; transition:width .2s; }
#toast { position:fixed; top:12px; left:50%; transform:translateX(-50%); z-index:10; display:flex; flex-direction:column; gap:6px; }
#toast div { background:#3a2430; border:1px solid var(--bad); padding:8px 14px; border-radius:8px; }
#toast div.info { background:#1f2f3d; border-color:var(--accent); }
.cdown { position:absolute; inset:0; display:flex; align-items:center; justify-content:center; font-size:96px; font-weight:700; background:rgba(0,0,0,.55); border-radius:10px; }
.vwrap { position:relative; }
.line { font-size:20px; margin:8px 0; }
.cur { background:#232a3d; }
.swatch { display:inline-block; width:10px; height:10px; border-radius:3px; margin-right:6px; }
.grid2 { display:grid; grid-template-columns:1fr 1fr; gap:14px; }
@media (max-width:760px) { .grid2 { grid-template-columns:1fr; } td input[type=number] { width:64px; } }

.subs { position:absolute; left:8%; right:8%; bottom:14px; text-align:center; font-size:22px; font-weight:600; color:#fff; text-shadow:0 0 4px #000,0 0 8px #000; pointer-events:none; }

a.btn { display:inline-block; text-decoration:none; color:var(--text); background:#272c38; border:1px solid var(--line); border-radius:8px; padding:8px 14px; }
a.btn.primary { background:var(--accent); border-color:var(--accent); color:#fff; font-weight:600; }
a.btn.big { padding:12px 20px; font-size:16px; }
