:root {
  --bg: #0d0d10;
  --card: #17171c;
  --line: #2a2a33;
  --text: #ececf1;
  --muted: #9a9aa8;
  --accent: #5b6cff;
  --ok: #34d399;
  --warn: #fbbf24;
  --bad: #f87171;
  --trim: #fb923c;
}
* { box-sizing: border-box; }
html, 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; }
button { font: inherit; cursor: pointer; border: 0; border-radius: 10px; padding: 9px 14px; font-weight: 600; background: #26262e; color: var(--text); }
button:hover { background: #31313b; }
button:disabled { opacity: .5; cursor: default; }
button.main { background: var(--accent); color: #fff; }
button.main:hover { background: #6d7cff; }
input, textarea { font: inherit; width: 100%; background: #0b0b0e; color: var(--text); border: 1px solid var(--line); border-radius: 10px; padding: 9px 11px; outline: none; }
input:focus, textarea:focus { border-color: #555566; }
label { display: block; font-size: 13px; color: var(--muted); margin: 10px 0; }
label input { margin-top: 4px; }

.top { display: flex; align-items: center; justify-content: space-between; padding: 14px 16px; border-bottom: 1px solid var(--line); }
.brand { font-weight: 800; letter-spacing: -.01em; }
.who { display: flex; gap: 10px; align-items: center; color: var(--muted); font-size: 13px; }
.who button { padding: 6px 10px; font-size: 13px; }

main { max-width: 1000px; margin: 0 auto; padding: 16px; }
.login { display: flex; justify-content: center; padding-top: 10vh; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 16px; margin-bottom: 16px; }
.card.practice { border-style: dashed; }
.narrow { width: 100%; max-width: 360px; }
h1 { font-size: 22px; margin: 0 0 6px; }
.err { color: var(--bad); font-size: 13px; min-height: 1em; }
.msg { font-size: 13px; min-height: 1em; margin: 6px 0; }
.msg.ok { color: var(--ok); }
.msg.bad { color: var(--bad); }

.tabs { display: flex; flex-wrap: wrap; gap: 8px; }
.tabs button { padding: 7px 12px; font-size: 13px; background: #1e1e25; color: var(--muted); }
.tabs button.on { background: #fff; color: #000; }

.head { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.code { font: 800 20px/1 ui-monospace, Consolas, monospace; letter-spacing: .06em; }
.pill { border-radius: 999px; padding: 3px 9px; font-size: 12px; font-weight: 600; background: #26262e; color: var(--muted); }
.pill.ok { background: rgba(52, 211, 153, .15); color: var(--ok); }
.pill.warn { background: rgba(251, 191, 36, .15); color: var(--warn); }
.pill.bad { background: rgba(248, 113, 113, .15); color: var(--bad); }
.pill.blue { background: rgba(91, 108, 255, .18); color: #aab3ff; }

.spec { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.res { border-radius: 12px; padding: 8px 16px; font-size: 26px; font-weight: 900; letter-spacing: -.02em; }
.res.r480 { background: rgba(148, 163, 184, .2); color: #e2e8f0; box-shadow: inset 0 0 0 2px #94a3b8; }
.res.r720 { background: rgba(56, 189, 248, .15); color: #7dd3fc; box-shadow: inset 0 0 0 2px #38bdf8; }
.res.r1080 { background: rgba(236, 72, 153, .18); color: #f9a8d4; box-shadow: inset 0 0 0 2px #ec4899; }
.box { display: flex; align-items: center; border-radius: 12px; padding: 8px 14px; font-weight: 700; background: #26262e; }
.box.secs { font-size: 18px; }
.box.trim { background: var(--trim); color: #000; font-weight: 900; text-transform: uppercase; letter-spacing: .02em; }
.box.whole { color: var(--muted); font-weight: 500; font-size: 14px; }

.grid { display: grid; gap: 14px; margin-top: 14px; grid-template-columns: minmax(0, 260px) 1fr; }
@media (max-width: 680px) { .grid { grid-template-columns: 1fr; } }
.label { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); margin-bottom: 6px; }
video { width: 100%; max-height: 320px; border-radius: 10px; background: #000; display: block; }
.photos { display: flex; flex-wrap: wrap; gap: 8px; }
.photo { position: relative; }
.photo img { width: 84px; height: 84px; object-fit: cover; border-radius: 10px; display: block; background: #222; }
.photo a.dl { position: absolute; right: 4px; bottom: 4px; background: rgba(0, 0, 0, .75); color: #fff; font-size: 11px; padding: 1px 6px; border-radius: 6px; text-decoration: none; }
.text { white-space: pre-wrap; }
.note { border-radius: 10px; padding: 10px 12px; font-size: 14px; margin-top: 10px; }
.note.warn { background: rgba(251, 191, 36, .1); border: 1px solid rgba(251, 191, 36, .35); }
.note.info { background: rgba(91, 108, 255, .1); border: 1px solid rgba(91, 108, 255, .35); }
.actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--line); align-items: center; }
.bar { height: 8px; background: #26262e; border-radius: 6px; overflow: hidden; margin-top: 10px; }
.bar div { height: 100%; background: var(--accent); width: 0; transition: width .2s; }
a.link { color: #aab3ff; font-size: 13px; }
.empty { text-align: center; color: var(--muted); padding: 48px 0; border: 1px solid var(--line); border-radius: 16px; }
table { width: 100%; border-collapse: collapse; font-size: 14px; }
td, th { text-align: left; padding: 8px; border-bottom: 1px solid var(--line); }
th { color: var(--muted); font-weight: 600; font-size: 12px; }
.clip { font-weight: 600; text-transform: none; margin-left: 6px; }
.muted { color: var(--muted); }
.mt6 { margin-top: 6px; }
.mt10 { margin-top: 10px; }
.mt12 { margin-top: 12px; }
.mt14 { margin-top: 14px; }
video.result { max-width: 420px; }
.card.taken { opacity: .45; }
