:root {
  --bg: #f6f5f2; --card: #fff; --ink: #1b1b1a; --muted: #6b6a66; --line: #e4e2dc;
  --accent: #1f5eff; --ok: #137a3f; --warn: #a35a00; --err: #b3261e;
  color-scheme: light dark;
}
@media (prefers-color-scheme: dark) {
  :root { --bg: #141413; --card: #1e1e1c; --ink: #eceae4; --muted: #9a988f; --line: #33322e;
          --accent: #6f95ff; --ok: #4cc47d; --warn: #e0a043; --err: #f07167; }
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--bg); color: var(--ink);
  font: 16px/1.5 system-ui, -apple-system, "Segoe UI", sans-serif; }
main { max-width: 640px; margin: 0 auto; padding: 32px 20px 48px; }
header { margin-bottom: 24px; }
.brand { font-weight: 700; font-size: 22px; color: var(--ink); text-decoration: none; letter-spacing: -0.01em; }
.tag { margin: 4px 0 0; color: var(--muted); }
.card { background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 22px; }
.card h2 { margin: 0 0 12px; font-size: 18px; }
.hint { color: var(--muted); margin: 0 0 16px; font-size: 15px; }
.drop { display: block; border: 2px dashed var(--line); border-radius: 12px; padding: 40px 16px;
  text-align: center; cursor: pointer; transition: border-color .15s, background .15s; }
.drop.over, .drop:hover { border-color: var(--accent); background: color-mix(in srgb, var(--accent) 6%, transparent); }
.drop strong { color: var(--accent); }
#file-input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.share { display: flex; gap: 8px; margin: 0 0 16px; }
.link { flex: 1; min-width: 0; padding: 10px 12px; border: 1px solid var(--line); border-radius: 8px;
  background: var(--bg); color: var(--ink); font: 14px ui-monospace, monospace; }
.files { list-style: none; margin: 0 0 16px; padding: 0; border-top: 1px solid var(--line); }
.files li { display: flex; justify-content: space-between; gap: 12px; padding: 8px 0; border-bottom: 1px solid var(--line); font-size: 15px; }
.files .name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.files .size { color: var(--muted); flex-shrink: 0; font-variant-numeric: tabular-nums; }
.bar { height: 10px; background: var(--line); border-radius: 99px; overflow: hidden; }
.bar-fill { height: 100%; width: 0; background: var(--accent); transition: width .3s; }
.meta { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 4px 12px; margin-top: 8px;
  font-size: 14px; color: var(--muted); font-variant-numeric: tabular-nums; }
.status.ok { color: var(--ok); } .status.warn { color: var(--warn); } .status.err { color: var(--err); }
.path.relay { color: var(--warn); }
.actions { display: flex; flex-direction: column; gap: 8px; margin-top: 16px; }
.actions:empty { display: none; }
.actions p { margin: 4px 0 0; font-size: 14px; }
.actions p.warn { color: var(--warn); }
button, .button { font: inherit; padding: 10px 16px; border-radius: 8px; border: 1px solid var(--line);
  background: var(--card); color: var(--ink); cursor: pointer; text-decoration: none; display: inline-block; text-align: center; }
button.primary { background: var(--accent); border-color: var(--accent); color: #fff; font-weight: 600; }
button.subtle { color: var(--muted); }
footer { margin-top: 20px; color: var(--muted); font-size: 13px; text-align: center; }
.problem { border: 1px solid color-mix(in srgb, var(--err) 40%, transparent); background: color-mix(in srgb, var(--err) 7%, transparent);
  border-radius: 10px; padding: 10px 14px; margin: 0 0 14px; }
.problem p { margin: 4px 0; color: var(--err); font-size: 15px; }
.problem button { margin-top: 6px; }
