:root { --bg:#0b0d10; --panel:#161a20; --fg:#f2f4f7; --muted:#b4bcc8; --accent:#ffb020; --ok:#4ade80; --err:#ff6b6b; }
* { box-sizing: border-box; }
body { margin:0; background:var(--bg); color:var(--fg); font:18px/1.45 system-ui, sans-serif; min-height:100vh; display:flex; flex-direction:column; }
header { padding:12px 16px; background:var(--panel); border-bottom:2px solid var(--accent); }
h1 { margin:0 0 8px; font-size:1.25rem; }
nav { display:flex; flex-wrap:wrap; gap:6px; }
nav button, button { font:inherit; color:var(--fg); background:#242a33; border:2px solid #3a4350; border-radius:10px; padding:10px 14px; min-height:48px; cursor:pointer; }
nav button.active { border-color:var(--accent); color:var(--accent); }
button.primary { background:var(--accent); color:#000; border-color:var(--accent); font-weight:700; width:100%; min-height:60px; margin-top:12px; }
button:disabled { opacity:.45; cursor:not-allowed; }
button.link { background:none; border:none; text-decoration:underline; min-height:40px; padding:4px 8px; }
button:focus-visible, input:focus-visible, pre:focus-visible { outline:3px solid #fff; outline-offset:2px; }
main { flex:1; padding:16px; max-width:960px; width:100%; margin:0 auto; }
h2 { margin-top:0; }
.help, .info { color:var(--muted); }
.drop { display:flex; flex-direction:column; align-items:center; justify-content:center; gap:4px; min-height:140px; border:3px dashed var(--accent); border-radius:14px; background:var(--panel); cursor:pointer; text-align:center; padding:12px; }
.drop .big { font-size:1.3rem; font-weight:700; }
.drop .small { color:var(--muted); font-size:.9rem; }
input[type=file] { position:absolute; opacity:0; width:1px; height:1px; }
.fmt { display:flex; gap:10px; align-items:center; padding:14px; margin:8px 0; background:var(--panel); border:2px solid #3a4350; border-radius:12px; cursor:pointer; }
.fmt:has(input:checked) { border-color:var(--accent); }
.fmt input { width:24px; height:24px; accent-color:var(--accent); }
#message { padding:12px 14px; border-radius:10px; margin-bottom:12px; font-weight:600; }
#message.error { background:#3a1517; border:2px solid var(--err); }
#message.ok { background:#12301c; border:2px solid var(--ok); }
.item { background:var(--panel); border:1px solid #3a4350; border-radius:12px; padding:12px; margin:8px 0; display:flex; flex-wrap:wrap; gap:8px; justify-content:space-between; align-items:center; }
.item small { color:var(--muted); display:block; }
.cols { display:grid; grid-template-columns:1fr; gap:12px; }
@media (min-width:800px) { .cols { grid-template-columns:1fr 1fr; } }
pre { background:var(--panel); border:1px solid #3a4350; border-radius:10px; padding:10px; overflow:auto; max-height:60vh; font-size:.8rem; white-space:pre-wrap; word-break:break-word; }
footer { display:flex; gap:12px; align-items:center; flex-wrap:wrap; padding:10px 16px; color:var(--muted); border-top:1px solid #3a4350; }
dialog { background:var(--panel); color:var(--fg); border:2px solid var(--accent); border-radius:14px; max-width:90vw; }
dialog::backdrop { background:#000a; }
.warn { color:var(--accent); font-size:.9rem; }
