/* Mobile first: one column, large touch targets. Wider screens only get a centred column. */
:root {
  --bg: #ffffff; --ink: #14171a; --muted: #5b6470; --line: #d9dee4; --card: #f6f7f9;
  --accent: #0b5fd9; --accent-ink: #ffffff; --err: #a3231b; --err-bg: #fdecea;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #15181c; --ink: #eceff2; --muted: #a2abb5; --line: #343b44; --card: #1e2329;
    --accent: #6ea8ff; --accent-ink: #0b1220; --err: #ffb4ab; --err-bg: #4a1f1b;
  }
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 16px/1.5 system-ui, sans-serif; }
a { color: var(--accent); }
main { max-width: 40rem; margin: 0 auto; padding: 1rem; }
h1 { font-size: 1.4rem; margin: 0.5rem 0; }
h2 { font-size: 1.1rem; margin: 1.5rem 0 0.5rem; }

.top { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.5rem;
  padding: 0.5rem 1rem; border-bottom: 1px solid var(--line); }
.brand { font-weight: 700; text-decoration: none; color: var(--ink); }
.top nav { display: flex; align-items: center; gap: 1rem; }
.top nav a, .plain { min-height: 44px; display: inline-flex; align-items: center; }
.plain { background: none; border: 0; padding: 0; color: var(--accent); font: inherit; cursor: pointer;
  text-decoration: underline; width: auto; }

.card { background: var(--card); border: 1px solid var(--line); border-radius: 8px; padding: 1rem; margin: 0.75rem 0; }
label { display: block; font-weight: 600; margin-top: 0.75rem; }
label:first-child { margin-top: 0; }
input, select, textarea { width: 100%; min-height: 44px; padding: 0.5rem; margin-top: 0.25rem; font: inherit;
  color: var(--ink); background: var(--bg); border: 1px solid var(--line); border-radius: 6px; }
button[type=submit]:not(.plain) { width: 100%; min-height: 44px; margin-top: 1rem; font: inherit; font-weight: 600;
  color: var(--accent-ink); background: var(--accent); border: 0; border-radius: 6px; cursor: pointer; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }

.hint { color: var(--muted); font-size: 0.9rem; }
.error { color: var(--err); background: var(--err-bg); padding: 0.75rem; border-radius: 6px; }
.stage { font-weight: 600; }

.list { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line); }
.list li { display: flex; flex-direction: column; gap: 0.15rem; padding: 0.75rem 0; border-bottom: 1px solid var(--line);
  overflow-wrap: anywhere; }
.list li > a { font-weight: 600; min-height: 28px; }

.filters { display: flex; gap: 0.5rem; overflow-x: auto; padding: 0.25rem 0 0.75rem; }
.filters a { flex: none; padding: 0.4rem 0.75rem; border: 1px solid var(--line); border-radius: 999px;
  text-decoration: none; min-height: 44px; display: inline-flex; align-items: center; }
.filters a[aria-current] { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }
