:root {
  --bg: #f6f4ef; --paper: #ffffff; --ink: #1d2230; --muted: #5d6475; --line: #e2ded4;
  --accent: #23407a; --accent-ink: #ffffff; --accent-soft: #e6ecf7; --gold: #b8892c;
  --ok: #1f7a4d; --ok-soft: #e3f3ea; --bad: #a33a32; --bad-soft: #f8e5e3; --warn: #8a6410; --warn-soft: #f8efd9;
  --indep: #9aa0ab; --radius: 10px;
  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, serif;
  --sans: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #12151c; --paper: #1a1e28; --ink: #e7e9ee; --muted: #9aa1b2; --line: #2b3140;
    --accent: #8fb0f0; --accent-ink: #0e1420; --accent-soft: #1f2a42; --gold: #d9ae55;
    --ok: #5fcf98; --ok-soft: #173326; --bad: #f08d84; --bad-soft: #3a1d1b; --warn: #e5bd62; --warn-soft: #362b12;
    --indep: #6c7383;
  }
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 16px/1.55 var(--sans); }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3 { font-family: var(--serif); line-height: 1.2; margin: 0 0 .5em; font-weight: 600; }
h1 { font-size: 2rem; } h2 { font-size: 1.4rem; } h3 { font-size: 1.1rem; }
.wrap { max-width: 1040px; margin: 0 auto; padding: 0 16px; }

header.top { background: var(--paper); border-bottom: 1px solid var(--line); }
header.top .wrap { display: flex; align-items: center; gap: 14px; min-height: 62px; flex-wrap: wrap; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--ink); font-family: var(--serif); font-weight: 600; font-size: 1.1rem; }
.brand img { width: 34px; height: 34px; border-radius: 8px; }
.brand:hover { text-decoration: none; }
nav.main { display: flex; gap: 2px; flex-wrap: nowrap; flex: 1; scrollbar-width: none; }
nav.main::-webkit-scrollbar { display: none; }
nav.main a { color: var(--muted); padding: 6px 9px; border-radius: 6px; font-size: .93rem; white-space: nowrap; }
nav.main a:hover, nav.main a.on { color: var(--ink); background: var(--accent-soft); text-decoration: none; }
.who { display: flex; align-items: center; gap: 8px; font-size: .92rem; }
.who form { margin: 0; }

main { padding: 28px 0 56px; }
footer { border-top: 1px solid var(--line); color: var(--muted); font-size: .88rem; padding: 18px 0 30px; }
footer .wrap { display: flex; gap: 16px; flex-wrap: wrap; justify-content: space-between; }

.card { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; }
.grid { display: grid; gap: 18px; }
.g2 { grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); }
.g3 { grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
.stack > * + * { margin-top: 18px; }
.muted { color: var(--muted); }
.small { font-size: .88rem; }
.eyebrow { text-transform: uppercase; letter-spacing: .08em; font-size: .75rem; color: var(--muted); font-weight: 600; }
.row { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.between { justify-content: space-between; }
hr { border: 0; border-top: 1px solid var(--line); margin: 20px 0; }

.btn { display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--line); background: var(--paper);
  color: var(--ink); padding: 8px 14px; border-radius: 8px; font: inherit; font-size: .95rem; cursor: pointer; }
.btn:hover { border-color: var(--accent); text-decoration: none; }
.btn.primary { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.btn.danger { color: var(--bad); }
.btn.small { padding: 4px 10px; font-size: .85rem; }
.btn.on { background: var(--accent-soft); border-color: var(--accent); }
.linkbtn { background: none; border: 0; color: var(--accent); cursor: pointer; font: inherit; padding: 0; }

input[type=text], input[type=url], textarea, select { width: 100%; font: inherit; color: var(--ink); background: var(--bg);
  border: 1px solid var(--line); border-radius: 8px; padding: 9px 11px; }
textarea { min-height: 140px; resize: vertical; }
label { display: block; font-weight: 600; margin: 14px 0 6px; font-size: .95rem; }
label.check { display: flex; gap: 8px; align-items: flex-start; font-weight: normal; }
.hint { font-size: .85rem; color: var(--muted); margin-top: 4px; }

.flash { padding: 10px 14px; border-radius: 8px; margin-bottom: 16px; }
.flash.ok { background: var(--ok-soft); color: var(--ok); }
.flash.error { background: var(--bad-soft); color: var(--bad); }

.av { width: 40px; height: 40px; border-radius: 50%; object-fit: cover; background: var(--line); flex: none; }
.av.lg { width: 84px; height: 84px; } .av.sm { width: 26px; height: 26px; }
.person { display: flex; align-items: center; gap: 10px; color: var(--ink); }
.person:hover { text-decoration: none; }
.person .n { font-weight: 600; line-height: 1.2; }
.person .h { font-size: .8rem; color: var(--muted); }

.badge { display: inline-block; font-size: .78rem; padding: 2px 8px; border-radius: 99px; background: var(--accent-soft); color: var(--accent); font-weight: 600; white-space: nowrap; }
.badge.ok { background: var(--ok-soft); color: var(--ok); }
.badge.bad { background: var(--bad-soft); color: var(--bad); }
.badge.warn { background: var(--warn-soft); color: var(--warn); }
.badge.gold { background: var(--warn-soft); color: var(--gold); }
.dot { display: inline-block; width: 10px; height: 10px; border-radius: 50%; vertical-align: middle; }

.office { display: flex; gap: 16px; align-items: center; }
.office .title { font-family: var(--serif); font-size: .95rem; color: var(--gold); font-weight: 600; letter-spacing: .02em; }
.office .nm { font-size: 1.35rem; font-family: var(--serif); font-weight: 600; color: var(--ink); }

.hemi { width: 100%; max-width: 520px; display: block; margin: 0 auto; }
.hemi a circle { transition: r .1s; }
.hemi a:hover circle { r: 10; }
.legend { display: flex; flex-wrap: wrap; gap: 6px 16px; justify-content: center; font-size: .9rem; margin-top: 8px; }

.banner { background: var(--accent); color: var(--accent-ink); border-radius: var(--radius); padding: 22px; }
.banner a { color: inherit; text-decoration: underline; }
.banner .big { font-family: var(--serif); font-size: 1.5rem; font-weight: 600; }
.banner .btn { background: var(--accent-ink); color: var(--accent); border-color: transparent; }

.list { list-style: none; margin: 0; padding: 0; }
.list > li { padding: 12px 0; border-top: 1px solid var(--line); }
.list > li:first-child { border-top: 0; }
.bar { height: 8px; background: var(--line); border-radius: 99px; overflow: hidden; display: flex; }
.bar .y { background: var(--ok); } .bar .n { background: var(--bad); } .bar .a { background: var(--indep); }

.prose p { margin: 0 0 .8em; } .prose pre { background: var(--bg); padding: 10px; border-radius: 8px; overflow-x: auto; }
.prose :last-child { margin-bottom: 0; }
.cand { border: 1px solid var(--line); border-radius: 8px; padding: 12px; }
.cand.pick { display: flex; gap: 10px; align-items: flex-start; cursor: pointer; }
.cand.pick:has(input:checked) { border-color: var(--accent); background: var(--accent-soft); }
.join { background: var(--warn-soft); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 20px; }
table { width: 100%; border-collapse: collapse; font-size: .95rem; }
td, th { text-align: left; padding: 8px 6px; border-top: 1px solid var(--line); }
th { color: var(--muted); font-weight: 600; font-size: .85rem; }
@media (max-width: 640px) {
  h1 { font-size: 1.6rem; }
  header.top .wrap { padding-top: 10px; padding-bottom: 8px; }
  nav.main { order: 3; flex-basis: 100%; overflow-x: auto; flex-wrap: nowrap; }
  .card { padding: 16px; }
}
