:root{color-scheme:dark;--bg: #0b0b0c;--panel: #18181b;--line: #2c2c31;--text: #f4f4f5;--muted: #a1a1aa;--accent: #4ade80;--warn: #fbbf24;--bad: #f87171}*{box-sizing:border-box}html,body{margin:0;background:var(--bg);color:var(--text);font:17px/1.45 system-ui,-apple-system,Segoe UI,Roboto,Helvetica Neue,Arial,sans-serif;-webkit-text-size-adjust:100%}[hidden]{display:none!important}main{max-width:560px;margin:0 auto;padding:max(16px,env(safe-area-inset-top)) 16px max(24px,env(safe-area-inset-bottom));min-height:100vh;min-height:100dvh;display:flex;flex-direction:column;gap:16px}h1{font-size:22px;margin:8px 0 0}p{margin:0}.muted{color:var(--muted)}.error{color:var(--bad);min-height:1.45em}input,select,button{font:inherit;color:inherit}.code-input{width:100%;font-size:40px;font-weight:700;letter-spacing:.3em;text-align:center;text-transform:uppercase;padding:12px;background:var(--panel);border:2px solid var(--line);border-radius:14px}.code-input:focus{outline:none;border-color:var(--accent)}.btn{min-height:56px;padding:0 20px;border-radius:14px;border:0;background:var(--panel);font-weight:600}.btn.primary{background:var(--accent);color:#062b12;font-size:20px;min-height:72px}.btn.danger{background:#3a1414;color:#fecaca}.btn:disabled{opacity:.45}.btn:focus-visible{outline:3px solid var(--warn);outline-offset:2px}.link{background:none;border:0;color:var(--muted);text-decoration:underline;min-height:48px;padding:0;text-align:left}.row{display:flex;gap:12px}.row>*{flex:1}.chips{display:flex;flex-wrap:wrap;gap:8px}.chip{display:inline-flex;align-items:center;white-space:pre;padding:6px 12px;border-radius:999px;background:var(--panel);font-size:15px}.chip:before{content:"";width:10px;height:10px;border-radius:50%;margin-right:8px;background:var(--muted)}.chip[data-s=ok]:before{background:var(--accent)}.chip[data-s=wait]:before{background:var(--warn)}.chip[data-s=bad]:before{background:var(--bad)}.preview{background:#000;border-radius:14px;padding:12px 14px;min-height:5.4em;font-size:18px;font-weight:600;overflow:hidden;display:flex;flex-direction:column;justify-content:flex-end}.cap{margin:0}.interim{color:#8b8b8b}.field{display:flex;flex-direction:column;gap:6px}.field input[type=text]{padding:14px;min-height:52px;background:var(--panel);border:1px solid var(--line);border-radius:12px}details{background:var(--panel);border-radius:14px;padding:4px 14px}summary{min-height:48px;display:flex;align-items:center;cursor:pointer;font-weight:600}.setting{display:flex;align-items:center;justify-content:space-between;gap:12px;min-height:52px;border-top:1px solid var(--line)}.setting input[type=range]{flex:1;max-width:55%;min-height:44px}.setting select{min-height:44px;background:var(--bg);border:1px solid var(--line);border-radius:10px;padding:0 10px}.spacer{flex:1}.transcript{font-size:22px;font-weight:600;line-height:1.45;overflow-y:auto;flex:1;padding-bottom:24px}.transcript .cap+.cap{margin-top:.8em}.state{position:sticky;bottom:0;text-align:center;padding:8px;background:var(--panel);border-radius:12px}@media(prefers-reduced-motion:no-preference){.chip:before{transition:background-color .2s}}.chip[data-s=off]:before{background:var(--muted)}.btn.fix{background:#fbbf24;color:#1c1300;text-align:left;padding:14px 16px;line-height:1.35;min-height:72px;font-size:19px}textarea{width:100%;font:15px/1.5 ui-monospace,SFMono-Regular,Menlo,monospace;color:var(--text);background:var(--bg);border:1px solid var(--line);border-radius:10px;padding:10px;margin:8px 0}.small{font-size:14px}.row.wrap{flex-wrap:wrap;margin-bottom:8px}label.btn.file{display:flex;align-items:center;justify-content:center;cursor:pointer}.tip{display:flex;gap:12px;align-items:center;background:#13233a;color:#cfe3ff;border-radius:14px;padding:10px 12px}.tip p{flex:1;font-size:15px}.small-btn{min-height:48px;padding:0 16px;flex:0 0 auto}.ended{background:var(--panel);border-radius:14px;padding:14px;display:flex;flex-direction:column;gap:12px}.ended h2{margin:0;font-size:20px}.seg .btn[aria-pressed=true]{background:var(--text);color:var(--bg)}input.switch{width:28px;height:28px;accent-color:var(--accent)}
