:root {
  --bg: #0b0d12;
  --surface: #141821;
  --surface-2: #1b2030;
  --line: #262c3d;
  --text: #eef0f6;
  --muted: #9aa2b8;
  --accent: #7c9cff;
  --accent-2: #b48cff;
  --ok: #5fd3a6;
  --radius: 16px;
  color-scheme: dark;
}
* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  background: radial-gradient(1200px 600px at 70% -10%, #1a2140 0%, transparent 60%), var(--bg);
  color: var(--text);
  font: 16px/1.55 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  min-height: 100vh;
}
.wrap { max-width: 1080px; margin: 0 auto; padding: 24px 16px 48px; }
.top { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }
.brand { font-weight: 700; letter-spacing: .02em; display: flex; align-items: center; gap: 10px; }
.dot { width: 12px; height: 12px; border-radius: 50%; background: linear-gradient(135deg, var(--accent), var(--accent-2)); box-shadow: 0 0 16px var(--accent); }
.lock { margin: 0; font-size: 13px; color: var(--ok); border: 1px solid #2a4a40; padding: 4px 12px; border-radius: 999px; }

.hero { padding: 48px 0 28px; }
h1 { font-size: clamp(30px, 5vw, 52px); line-height: 1.08; margin: 0 0 14px; letter-spacing: -.02em; }
.sub { color: var(--muted); max-width: 620px; margin: 0; font-size: 17px; }

.drop {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px;
  border: 1.5px dashed var(--line); border-radius: var(--radius); background: var(--surface);
  padding: 36px 16px; cursor: pointer; text-align: center; transition: border-color .2s, background .2s;
}
.drop:hover, .drop.over { border-color: var(--accent); background: var(--surface-2); }
.drop input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.drop-icon { color: var(--accent); }
.drop-title { font-weight: 600; font-size: 18px; word-break: break-all; }
.drop-hint { color: var(--muted); font-size: 14px; }
.drop.compact { padding: 16px; flex-direction: row; gap: 12px; }
.drop.compact .drop-hint { display: none; }

.work { display: grid; grid-template-columns: 1.6fr 1fr; gap: 20px; margin-top: 20px; }
@media (max-width: 820px) { .work { grid-template-columns: 1fr; } }
.preview { align-self: start; background: #000; border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); display: flex; flex-direction: column; }
#stage { width: 100%; aspect-ratio: 16 / 10; display: block; }
.preview-bar { display: flex; align-items: center; gap: 12px; padding: 10px 14px; background: var(--surface); }
.preview-bar input { flex: 1; }
.time { font-variant-numeric: tabular-nums; color: var(--muted); font-size: 13px; min-width: 84px; text-align: right; }
.icon-btn { background: var(--surface-2); color: var(--text); border: 1px solid var(--line); width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; cursor: pointer; }

.panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; display: flex; flex-direction: column; gap: 18px; }
.group { display: flex; flex-direction: column; gap: 8px; }
.label { font-size: 13px; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; display: flex; justify-content: space-between; }
.val { color: var(--text); text-transform: none; letter-spacing: 0; }
.seg { display: grid; grid-template-columns: repeat(3, 1fr); background: var(--bg); border: 1px solid var(--line); border-radius: 12px; padding: 4px; gap: 4px; }
.seg button { background: none; border: 0; color: var(--muted); padding: 9px 6px; border-radius: 9px; font: inherit; font-size: 13.5px; cursor: pointer; }
.seg button[aria-checked="true"] { background: var(--surface-2); color: var(--text); box-shadow: inset 0 0 0 1px var(--line); }
.note { margin: 0; font-size: 13px; color: var(--muted); }
input[type="range"] { accent-color: var(--accent); width: 100%; }

.actions { display: flex; flex-direction: column; gap: 10px; }
.btn { font: inherit; font-weight: 600; padding: 13px 16px; border-radius: 12px; border: 1px solid var(--line); background: var(--surface-2); color: var(--text); cursor: pointer; }
.btn.primary { background: linear-gradient(135deg, var(--accent), var(--accent-2)); border: 0; color: #0b0d12; }
.btn:disabled { opacity: .45; cursor: not-allowed; }

.progress { display: flex; flex-direction: column; gap: 8px; }
.progress-head { display: flex; justify-content: space-between; font-size: 14px; }
.bar { height: 8px; background: var(--bg); border-radius: 99px; overflow: hidden; border: 1px solid var(--line); }
.fill { height: 100%; width: 0; background: linear-gradient(90deg, var(--accent), var(--accent-2)); transition: width .3s; }
.link { align-self: flex-start; background: none; border: 0; color: var(--muted); text-decoration: underline; cursor: pointer; padding: 0; font: inherit; font-size: 13px; }

.facts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-top: 40px; }
@media (max-width: 820px) { .facts { grid-template-columns: 1fr; } }
.fact { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; }
.fact h3 { margin: 0 0 6px; font-size: 16px; }
.fact p { margin: 0; color: var(--muted); font-size: 14px; }
.foot { margin-top: 28px; color: var(--muted); font-size: 13px; }
code { background: var(--surface-2); padding: 1px 6px; border-radius: 6px; font-size: 12.5px; }

[hidden] { display: none !important; }
