/* wevotehere.org. Plain CSS, system fonts, no external resources. */

/* Colors (Hugh, 2026-11-11, final): red, white and blue, one shade of each, exactly balanced
   between white and black: each has the same contrast, 4.6 : 1, with white and with black (the one
   brightness where the two are equal, just above the 4.5 : 1 that accessibility guidelines ask for
   text). They are the hues of Apple's iPhone system colors, System Red #ff3b30 and System Blue
   #007aff, with only the brightness changed. The banner (WeVoteHere.svg) uses the same two.
   Text is only black or white; red and blue are fills, lines and the ✔︎/✖︎ marks. */
:root {
  color-scheme: light;
  --red: #eb0c00; --blue: #0071ed; --white: #ffffff;
  --mid: #e6e6e6; --yes-mark: var(--blue); --no-mark: var(--red); --link-line: var(--blue);
  --bg: #ffffff; --surface: #ffffff; --surface-2: #f2f2f2;
  --ink: #000000; --ink-2: #000000; --muted: #4d4d4d; --line: #d9d9d9;
  --shadow: 0 1px 2px rgb(0 0 0 / 6%), 0 4px 16px rgb(0 0 0 / 6%);
  --radius: 14px;
  --serif: Charter, "Bitstream Charter", "Sitka Text", Cambria, Georgia, serif;
  --sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, "SF Mono", "Cascadia Mono", Consolas, Menlo, monospace;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
    --bg: #000000; --surface: #121212; --surface-2: #1f1f1f;
    --ink: #ffffff; --ink-2: #ffffff; --muted: #b3b3b3; --line: #383838;
    --mid: #333333;
    --shadow: none;
  }
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #000000; --surface: #121212; --surface-2: #1f1f1f;
  --ink: #ffffff; --ink-2: #ffffff; --muted: #b3b3b3; --line: #383838;
  --mid: #333333;
  --shadow: none;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
/* ✔ and ✖ have emoji forms that phones draw in grey, ignoring the color. Every mark is written
   with U+FE0E (text form, please); this asks again for browsers that support it. */
body { font-variant-emoji: text; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font: 17px/1.6 var(--sans);
}
img { max-width: 100%; height: auto; }
a { color: var(--ink); text-decoration-color: var(--link-line); text-underline-offset: 2px; }
a:hover { text-decoration-thickness: 2px; }
h1, h2, h3 { font-family: var(--serif); color: var(--ink); line-height: 1.2; font-weight: 700; }
h1 { font-size: clamp(30px, 5vw, 46px); margin: 0 0 16px; letter-spacing: -0.01em; }
h2 { font-size: clamp(24px, 3.4vw, 32px); margin: 0 0 12px; }
h3 { font-size: 20px; margin: 0 0 8px; }
p { margin: 0 0 14px; }
.wrap { max-width: 1100px; margin: 0 auto; padding: 0 16px; }
.narrow { max-width: 720px; }
.muted { color: var(--muted); }
.small { font-size: 14.5px; }

/* ---- header ---- */
.site-head { background: var(--surface); border-bottom: 1px solid var(--line); }
.banner-link { display: block; padding: 14px 0 10px; }
.banner { display: block; width: 100%; }
.site-nav { display: flex; flex-wrap: wrap; gap: 4px 6px; align-items: center; padding: 0 0 10px; }
.site-nav a {
  text-decoration: none; color: var(--ink-2); font-weight: 600; font-size: 15.5px;
  padding: 7px 12px; border-radius: 999px;
}
.site-nav a:hover { background: var(--surface-2); color: var(--ink); }
.site-nav a[aria-current="page"] { background: var(--blue); color: var(--white); }
.site-nav .by { margin-left: auto; font-weight: 400; font-size: 14px; color: var(--muted); }
.site-nav .by a { padding: 0; font-weight: 600; font-size: 14px; color: var(--muted); }
.site-nav .by a:hover { background: none; text-decoration: underline; }
.stripe { display: flex; height: 4px; }
.stripe i { flex: 1; }
/* Three lines under the menu, red, blue, red (Hugh, 2026-11-11). */
.stripe i:nth-child(odd) { background: var(--red); } .stripe i:nth-child(2) { background: var(--blue); }

main.wrap { padding-top: 44px; padding-bottom: 72px; }
section { margin: 0 0 56px; }

/* ---- footer ---- */
.site-foot { border-top: 1px solid var(--line); background: var(--surface); padding: 28px 0 40px; font-size: 14.5px; color: var(--muted); }
.site-foot .wrap { display: flex; flex-wrap: wrap; gap: 8px 32px; justify-content: space-between; }
.site-foot a { color: var(--muted); }

/* ---- building blocks ---- */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; box-shadow: var(--shadow); }
.grid { display: grid; gap: 16px; }
.grid-3 { grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
.grid-2 { grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); }
.btn {
  display: inline-flex; align-items: center; gap: 8px; text-decoration: none; cursor: pointer;
  font: 600 16px/1 var(--sans); padding: 13px 20px; border-radius: 10px;
  border: 1px solid var(--blue); background: var(--blue); color: var(--white);
}
.btn:hover { filter: brightness(1.08); }
.btn.secondary { background: transparent; color: var(--ink); }
.btn.secondary:hover { background: var(--surface-2); filter: none; }
.btn:disabled { opacity: .5; cursor: default; }
.btn-row { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 22px; }
.eyebrow { font: 700 13px/1 var(--sans); letter-spacing: .08em; text-transform: uppercase; color: var(--ink); margin: 0 0 12px; }
.lead { font-size: 19px; color: var(--ink-2); max-width: 40em; }
.kicker { display: flex; gap: 14px; align-items: flex-start; }
.kicker .num {
  flex: none; width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center;
  font: 700 16px/1 var(--sans); background: var(--blue); color: var(--white);
}
.icon { width: 28px; height: 28px; color: var(--blue); margin-bottom: 8px; }

/* ---- home ---- */
.hero { display: grid; grid-template-columns: 1.25fr 1fr; gap: 40px; align-items: center; }
@media (max-width: 820px) { .hero { grid-template-columns: 1fr; } }
.ballot { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 20px 22px; max-width: 380px; justify-self: center; width: 100%; }
.ballot h3 { font-size: 17px; margin: 0 0 2px; }
.ballot .muted { font-size: 13.5px; margin-bottom: 12px; }
.ballot ol { list-style: none; margin: 0; padding: 0; }
.ballot li { display: flex; align-items: center; gap: 12px; padding: 9px 0; border-top: 1px dashed var(--line); }
.ballot .rank { flex: none; width: 30px; height: 30px; border-radius: 8px; display: grid; place-items: center; font: 700 15px/1 var(--sans); color: #fff; }
.ballot li:nth-child(odd) .rank { background: var(--blue); } .ballot li:nth-child(even) .rank { background: var(--red); }
.ballot .ord { margin-left: auto; font-size: 13px; color: var(--muted); }
.statline { display: grid; grid-template-columns: auto 1fr; gap: 6px 24px; align-items: baseline; }
.bignum { font: 700 clamp(48px, 8vw, 76px)/1 var(--serif); color: var(--ink); letter-spacing: -0.02em; }
.quote { font-family: var(--serif); font-size: 21px; line-height: 1.45; color: var(--ink-2); border-left: 4px solid var(--blue); padding: 2px 0 2px 18px; margin: 0; }
.quote.principle { color: var(--ink); border: 2px solid var(--blue); border-radius: 12px; background: var(--surface); padding: 16px 22px; margin: 16px 0 20px; }

/* ---- count page ---- */
.steps { display: grid; gap: 14px; counter-reset: s; }
.drop {
  border: 2px dashed var(--line); border-radius: var(--radius); background: var(--surface);
  padding: 28px 20px; text-align: center; transition: border-color .15s, background .15s;
}
.drop.over { border-color: var(--blue); background: var(--surface-2); }
.drop .file-name { font-weight: 600; margin: 8px 0 0; min-height: 1.6em; overflow-wrap: anywhere; }
.drop input[type=file] { position: absolute; width: 1px; height: 1px; opacity: 0; }
.drop label.btn { margin-top: 4px; }
.privacy { display: flex; gap: 10px; align-items: flex-start; font-size: 15px; color: var(--ink-2); margin-top: 14px; }
.privacy svg { flex: none; width: 20px; height: 20px; color: var(--blue); margin-top: 3px; }
#results:empty { display: none; }
#results { margin-top: 28px; }
#results > * { margin-bottom: 14px; }
.result-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; box-shadow: var(--shadow); }
.winner-box { text-align: center; padding: 26px 18px; background: var(--blue); color: var(--white); border-radius: var(--radius); border-bottom: 6px solid var(--red); }
.winner-box .btn { background: var(--white); border-color: var(--white); color: #000; }
.winner-box .label { font: 700 13px/1 var(--sans); letter-spacing: .08em; text-transform: uppercase; color: var(--white); }
.winner { display: block; font: 700 clamp(26px, 4.4vw, 38px)/1.2 var(--serif); margin-top: 10px; overflow-wrap: anywhere; }
.download { margin-top: 4px; }
.error { color: var(--ink); font-weight: 600; border-left: 4px solid var(--red); padding-left: 12px; }
.detail { font-size: 14px; color: var(--muted); }
.detected { font-size: 15.5px; background: var(--surface-2); border-radius: 10px; padding: 12px 16px; }
.detected ul { margin: 4px 0 0; padding-left: 1.3em; }
.warnhead { margin-top: 8px; font-weight: 700; color: var(--ink); }
.notice { color: var(--ink); background: var(--surface-2); border-left: 4px solid var(--red); border-radius: 10px; padding: 12px 16px; font-size: 15.5px; }
.spin { display: inline-block; width: 16px; height: 16px; border: 2px solid var(--line); border-top-color: var(--blue); border-radius: 50%; animation: spin .8s linear infinite; vertical-align: -3px; margin-right: 8px; }
@keyframes spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .spin { animation: none; } }

/* ---- prose ---- */
.prose { max-width: 44em; }
.prose p, .prose li { color: var(--ink-2); }
.prose h2 { margin-top: 40px; }
.prose dl { margin: 0 0 16px; }
.prose dt { font-weight: 700; color: var(--ink); margin-top: 12px; }
.prose dd { margin: 2px 0 0; color: var(--ink-2); }
.aside { font-size: 15.5px; background: var(--surface-2); border-radius: 10px; padding: 14px 18px; }

/* ---- data page ---- */
.tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 14px; }
.tile { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 20px; }
.tile .v { font: 700 40px/1.05 var(--serif); color: var(--ink); }
.tile .k { font-size: 14.5px; color: var(--ink-2); margin-top: 6px; }
.chart { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; }
.chart h3 { font-family: var(--sans); font-size: 17px; margin-bottom: 2px; }
.chart .sub { font-size: 14.5px; color: var(--muted); margin-bottom: 14px; }
.chart svg { display: block; width: 100%; height: auto; overflow: visible; }
.chart svg text { fill: var(--muted); font: 13px var(--sans); }
.chart svg .lbl { fill: var(--ink-2); }
.chart svg .val { fill: var(--ink); font-weight: 600; }
.chart svg .grid { stroke: var(--line); stroke-width: 1; }
.chart svg .axis { stroke: var(--muted); stroke-width: 1; }
.legend { display: flex; flex-wrap: wrap; gap: 6px 18px; font-size: 14px; color: var(--ink-2); margin: 0 0 10px; }
.legend span { display: inline-flex; align-items: center; gap: 7px; }
.legend i { width: 12px; height: 12px; border-radius: 3px; display: inline-block; }
.legend .s1 { background: var(--blue); } .legend .s2 { background: var(--red); }
.legend .pos { background: var(--blue); } .legend .neg { background: var(--red); } .legend .mid { background: var(--mid); border: 1px solid var(--line); }
.tip {
  position: fixed; z-index: 10; pointer-events: none; background: var(--ink); color: var(--bg);
  font-size: 13.5px; line-height: 1.4; padding: 7px 10px; border-radius: 8px; max-width: 260px; display: none;
}
.table-toggle { margin-top: 12px; font-size: 14px; }
.table-toggle summary { cursor: pointer; color: var(--ink); font-weight: 600; }
table.data { border-collapse: collapse; font-size: 14px; margin-top: 8px; }
table.data th, table.data td { border-bottom: 1px solid var(--line); padding: 5px 12px 5px 0; text-align: right; }
table.data th:first-child, table.data td:first-child { text-align: left; }

.explorer-bar { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-bottom: 14px; }
.seg { display: inline-flex; border: 1px solid var(--line); border-radius: 10px; overflow: hidden; background: var(--surface); }
.seg button { font: 600 14px var(--sans); border: 0; background: none; color: var(--ink-2); padding: 8px 13px; cursor: pointer; }
.seg button + button { border-left: 1px solid var(--line); }
.seg button[aria-pressed="true"] { background: var(--blue); color: var(--white); }
.icon-btn { font: 600 14px var(--sans); border: 1px solid var(--line); background: var(--surface); color: var(--ink-2); padding: 8px 12px; border-radius: 10px; cursor: pointer; }
.icon-btn:hover { color: var(--ink); border-color: var(--muted); }
.ex-title { font-weight: 700; font-size: 17px; margin: 0; }
.ex-meta { font-size: 14.5px; color: var(--muted); margin: 2px 0 14px; }
.matrix-wrap { overflow-x: auto; padding-bottom: 4px; }
table.matrix { border-collapse: separate; border-spacing: 2px; font: 600 12.5px var(--sans); }
table.matrix th { color: var(--muted); font-weight: 700; padding: 0 4px; text-align: center; }
table.matrix th.row { text-align: right; padding-right: 8px; }
table.matrix td { width: 30px; height: 30px; min-width: 30px; text-align: center; border-radius: 5px; color: var(--ink); }
table.matrix td.self { background: transparent; }
table.matrix td.on { color: #fff; }
table.matrix tr.smith th.row { box-shadow: inset 4px 0 var(--blue); }
.badge { display: inline-block; font: 700 12.5px/1 var(--sans); padding: 5px 9px; border-radius: 999px; background: var(--surface-2); color: var(--ink-2); vertical-align: 2px; margin-left: 6px; }
.badge.cw { background: var(--blue); color: var(--white); } .badge.cycle { background: var(--red); color: var(--white); } .badge.tie { background: var(--surface-2); }
.explain { font-size: 15px; color: var(--ink-2); margin-top: 12px; }

/* ---- 404 ---- */
.center { text-align: center; }
.m0 { margin: 0; }

/* ---- v2: views of an election ---- */
.views { display: grid; grid-template-columns: minmax(0, auto) minmax(0, 1fr); gap: 28px; align-items: start; margin-top: 8px; }
@media (max-width: 860px) { .views { grid-template-columns: 1fr; } }
.view-h { font: 700 13px/1 var(--sans); letter-spacing: .06em; text-transform: uppercase; color: var(--muted); margin: 0 0 10px; }
.ladder-wrap, .grid-wrap { overflow-x: auto; padding-bottom: 4px; }
.ladder { font-family: var(--mono); font-size: 15px; line-height: 1.15; white-space: nowrap; }
.ladder span { display: inline-block; width: 1.45em; text-align: center; cursor: default; }
.ladder .yes, .yes { color: var(--yes-mark); } .ladder .no, .no { color: var(--no-mark); } .ladder .tie, .tie { color: var(--muted); font-weight: 700; }
.ladder .name { font-family: var(--sans); font-size: 15px; font-weight: 700; color: var(--ink); }
table.mov { border-collapse: separate; border-spacing: 2px; font: 600 12.5px var(--sans); }
table.mov th { color: var(--muted); font-weight: 700; padding: 0 3px; text-align: center; }
table.mov th.row { text-align: left; padding-right: 8px; color: var(--ink); font-weight: 600; white-space: nowrap; max-width: 15em; overflow: hidden; text-overflow: ellipsis; }
table.mov th.row .k { color: var(--muted); font-weight: 700; }
table.mov td { min-width: 30px; height: 28px; text-align: center; border-radius: 5px; cursor: default; }
table.mov td.self { background: transparent; }
table.mov td.win { background: var(--blue); color: var(--white); }
table.mov td.loss { background: var(--red); color: var(--white); }
table.mov td.even { background: var(--mid); color: var(--ink); }
.swatch { display: inline-block; width: 11px; height: 11px; border-radius: 3px; vertical-align: -1px; }
.swatch.win { background: var(--blue); } .swatch.loss { background: var(--red); }
.how-to-read { font-size: 15.5px; color: var(--ink-2); }
.example { margin: 0 0 22px; }
.example h2 { margin: 0 0 4px; }
.example .eyebrow { margin-bottom: 8px; }
.result-line { font-weight: 600; color: var(--ink); }
table.ballots td, table.ballots th { text-align: center; padding: 4px 8px; }
table.ballots th { font-size: 12.5px; max-width: 7em; white-space: normal; vertical-align: bottom; }
table.ballots td.first { font-weight: 800; color: var(--ink); }
.grid-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 12px; margin-bottom: 14px; }
.ex-card { display: flex; flex-direction: column; gap: 6px; text-decoration: none; color: var(--ink); background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; box-shadow: var(--shadow); }
.ex-card:hover { border-color: var(--blue); }
.ex-card .q { font: 700 17px/1.3 var(--serif); }
.ex-card .meta { font-size: 13.5px; color: var(--muted); }
.ex-card .w { font-weight: 700; }
.ex-card .badge { margin: 4px 0 0; align-self: flex-start; }
.badge.nocw { background: var(--surface-2); color: var(--ink-2); }
.group { margin: 0 0 22px; }
#viewer { margin: 0 0 24px; scroll-margin-top: 16px; }
.ex-card .badge { border-radius: 8px; line-height: 1.3; padding: 5px 8px; }
.part-h { margin: 6px 0 6px; font-size: 13.5px; color: var(--muted); }

/* ---- v3 ---- */
.mov-view { min-width: 0; }
.mov-box { display: inline-block; max-width: 100%; }
.mov-box .view-h { text-align: center; }
.methods-block { margin-top: 22px; }
table.methods td, table.methods th { text-align: left; padding: 5px 16px 5px 0; }
table.methods td:first-child { color: var(--muted); font-variant-numeric: tabular-nums; }
table.methods td.differs { font-weight: 700; color: var(--ink); }
table.methods tr.rp td { border-top: 2px solid var(--line); font-weight: 700; }
table.methods sup { color: var(--muted); margin-left: 2px; }
.methods-wrap .muted { margin-top: 6px; }
.downloads { display: flex; flex-wrap: wrap; gap: 10px; margin: 20px 0 6px; }
.example .about { font-style: italic; color: var(--ink-2); }

/* ---- v4: the combined figure (ladder + matrix + methods) ---- */
.figure-wrap { overflow-x: auto; padding-bottom: 4px; }
.figure { --cell: 34px; display: grid; align-items: center; font: 600 12.5px var(--sans); }
/* the head-to-head results: chevron tiles (views.js, docs/chevron-tiles.md); --u is set by views.js */
.figure .field { display: block; align-self: start; justify-self: end; }
.figure .field polygon { cursor: default; }
.figure .mk { cursor: default; }
/* the same results as text at the start of each row (✔︎/✖︎), hidden from view only while the tiles show */
.tiles-on .h2h-text { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; border: 0; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; }
.figure .mk.yes { color: var(--yes-mark); } .figure .mk.no { color: var(--no-mark); } .figure .mk.tie { color: var(--muted); }
.figure .nm { position: relative; font: 700 15px/calc(2 * var(--u)) var(--sans); color: var(--ink); white-space: nowrap; padding: 0 12px 0 0; max-width: 18em; overflow-x: clip; overflow-y: visible; text-overflow: ellipsis; }
.figure .nm .k { color: var(--muted); }
.figure .ch { align-self: end; text-align: center; color: var(--muted); font-weight: 700; padding-bottom: 3px; }
.figure .cell { align-self: stretch; margin: 1px; padding: 0 4px; border-radius: 5px; display: flex; align-items: center; justify-content: center; cursor: default; }
.figure .cell.win { background: var(--blue); color: var(--white); }
.figure .cell.loss { background: var(--red); color: var(--white); }
.figure .cell.even { background: var(--mid); color: var(--ink); }
.figure .ph { align-self: end; padding: 0 0 3px 14px; font: 700 12px var(--sans); letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.figure .picks { align-self: center; padding-left: 14px; font: 500 calc(1.55 * var(--u))/calc(2 * var(--u)) var(--sans); color: var(--ink-2); }
.figure .picks.differs { color: var(--ink); font-weight: 700; }
.figure .meth { cursor: default; white-space: nowrap; } .figure .meth.rp { font-weight: 700; }
.figure .picks sup { color: var(--muted); margin-left: 1px; line-height: 0; font-size: 0.75em; vertical-align: 0.45em; } /* never makes its line taller */
.fig-note { margin-top: 8px; }
details.more-methods { margin-top: 14px; }
details.more-methods summary { cursor: pointer; color: var(--ink); font-weight: 600; }
.example.review { border: 2px solid var(--red); }
.example.review .eyebrow { color: var(--ink); }
.review-note { background: var(--surface-2); border-left: 4px solid var(--red); color: var(--ink); border-radius: 10px; padding: 10px 14px; margin: 0 0 12px; }
.figure.big { --cell: 27px; font-size: 11px; }
.figure.big .picks { padding-left: 10px; }
.figure.big .nm { font-size: 14px; }
.figure.big .cell { padding: 0 2px; }

/* ---- v5: Real Elections list and the All Elections page ---- */
details.how-to-read summary { cursor: pointer; }
details.how-to-read[open] summary { margin-bottom: 8px; }
.filters { display: flex; flex-wrap: wrap; gap: 10px 16px; align-items: end; margin: 0 0 8px; }
.filters label { display: flex; flex-direction: column; gap: 4px; font-size: 13px; font-weight: 600; color: var(--muted); }
.filters .f-q { flex: 1 1 220px; }
.filters input, .filters select { font: 15px var(--sans); padding: 8px 10px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); color: var(--ink); }
.elist { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line); }
.erow { border-bottom: 1px solid var(--line); scroll-margin-top: 12px; }
.row-head { all: unset; box-sizing: border-box; width: 100%; cursor: pointer; display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 2px 16px; padding: 12px 6px; }
.row-head:hover .row-title, .row-head:focus-visible .row-title { color: var(--ink); text-decoration: underline; text-decoration-color: var(--link-line); }
.row-head:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; }
.row-title { font: 700 17px/1.3 var(--serif); color: var(--ink); }
.row-meta { grid-column: 1; font-size: 14px; color: var(--muted); }
.row-head .badge { grid-column: 2; grid-row: 1 / span 2; align-self: center; border-radius: 8px; padding: 5px 8px; font-size: 13px; }
.erow.open .row-head { background: var(--surface-2); border-radius: 8px; }
.row-body { padding: 8px 6px 22px; }
@media (max-width: 600px) { .row-head { grid-template-columns: 1fr; } .row-head .badge { grid-column: 1; grid-row: auto; justify-self: start; } }
.row-k { color: var(--muted); font-family: var(--sans); font-weight: 600; font-size: 15px; }
.el-top { margin-bottom: 18px; }
.el-top h1 { margin-bottom: 6px; }
.filters { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 18px; margin: 0 0 22px; display: grid; gap: 14px; }
.filters label > span, .f-label { display: block; font: 600 14px var(--sans); color: var(--ink-2); margin-bottom: 6px; }
.filters input[type=search] { width: 100%; box-sizing: border-box; font: 16px var(--sans); color: var(--ink); background: var(--bg); border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; }
.filters input[type=search]:focus { outline: 2px solid var(--blue); outline-offset: 1px; }
.f-range output { color: var(--ink); }
/* One track, two knobs: two range inputs laid over each other; only their knobs take the pointer. */
.dual { position: relative; height: 28px; }
.dual-track { position: absolute; left: 11px; right: 11px; top: 12px; height: 4px; border-radius: 2px; background: var(--line); }
.dual-fill { position: absolute; top: 0; bottom: 0; border-radius: 2px; background: var(--blue); }
.dual input[type=range] { position: absolute; inset: 0; width: 100%; height: 28px; margin: 0; padding: 0; border: 0; background: none; pointer-events: none; -webkit-appearance: none; appearance: none; }
.dual input[type=range]::-webkit-slider-runnable-track { background: none; border: 0; }
.dual input[type=range]::-moz-range-track { background: none; border: 0; }
.dual input[type=range]::-webkit-slider-thumb { pointer-events: auto; -webkit-appearance: none; appearance: none; width: 22px; height: 22px; border-radius: 50%; background: var(--surface); border: 2px solid var(--blue); box-sizing: border-box; cursor: grab; }
.dual input[type=range]::-moz-range-thumb { pointer-events: auto; width: 22px; height: 22px; border-radius: 50%; background: var(--surface); border: 2px solid var(--blue); box-sizing: border-box; cursor: grab; }
.dual input[type=range]:focus-visible { outline: none; }
.dual input[type=range]:focus-visible::-webkit-slider-thumb { box-shadow: 0 0 0 3px var(--surface-2); background: var(--surface-2); }
.dual input[type=range]:focus-visible::-moz-range-thumb { box-shadow: 0 0 0 3px var(--surface-2); background: var(--surface-2); }
.f-row { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.f-row select { font: 15px var(--sans); color: var(--ink); background: var(--bg); border: 1px solid var(--line); border-radius: 10px; padding: 8px 10px; max-width: 100%; }
.f-row select:disabled { opacity: .55; }
.f-row select:focus-visible { outline: 2px solid var(--blue); outline-offset: 1px; }
.f-count { margin: 0; }
.f-foot { display: flex; flex-wrap: wrap; gap: 8px 16px; align-items: center; justify-content: space-between; }
.f-dl { margin-left: auto; display: flex; flex-wrap: wrap; gap: 8px; align-items: center; justify-content: flex-end; }
.f-dl .f-label { margin: 0; }
.f-dl .btn { margin: 0; padding: 7px 12px; font-size: 14.5px; }
.f-dl .btn small { font-weight: 400; opacity: .8; }
.f-dl-note { margin: -6px 0 0; text-align: right; }
.el-top p.small { margin: 0 0 6px; }
details.how-to-read summary { color: var(--ink); font-weight: 600; font-size: 15px; }
details.how-to-read p { font-size: 15px; color: var(--ink-2); }
.footnotes { margin-top: 28px; }
.footnotes .aside + .aside { margin-top: 10px; }

/* The note shown when a mark, square or method is tapped on a touch screen (tips.js). */
.tap-tip { position: absolute; z-index: 50; max-width: min(300px, calc(100vw - 16px)); box-sizing: border-box; padding: 8px 10px; border-radius: 8px; background: var(--ink); color: var(--bg); font: 14px/1.4 var(--sans); box-shadow: 0 4px 14px rgba(0,0,0,.25); pointer-events: none; }
.f-compare #cmp-rows { display: grid; gap: 8px; }
/* Search, the number of choices and the Condorcet menu on one line (on a phone held sideways
   too; Hugh, 2026-11-08). The search box and the menu are the same width, at most 290px; the
   slider takes the rest, at least 180px. Stacked on narrow screens. */
.f-top { display: grid; grid-template-columns: minmax(0, 290px) minmax(180px, 1fr) minmax(0, 290px); gap: 14px 20px; align-items: end; }
.f-top .f-search, .f-top .f-cw { min-width: 0; }
.f-top .f-cw select { width: 100%; padding: 10px; text-overflow: ellipsis; }
.f-top .f-range { padding-bottom: 6px; }
@media (max-width: 600px) { .f-top { grid-template-columns: minmax(0, 1fr); } .f-top .f-range { padding-bottom: 0; } }
.f-add { font: 600 14.5px var(--sans); color: var(--ink); background: none; border: 1px dashed var(--line); border-radius: 10px; padding: 6px 12px; cursor: pointer; }
.f-add:hover { background: var(--surface-2); }
/* A comparison line stays on one line from 600px up (a phone held sideways; Hugh, 2026-11-08):
   the three menus share the room, each narrowed (its text cut short) rather than wrapped, and
   the + and x buttons keep their size. Below 600px the line wraps as before. */
@media (min-width: 600px) {
  .f-compare .f-row { flex-wrap: nowrap; }
  .f-compare .f-row select { flex: 0 1 auto; min-width: 0; text-overflow: ellipsis; }
  .f-compare .f-row .f-add, .f-compare .f-row .f-del { flex: none; white-space: nowrap; }
}
.f-del { font: 600 18px/1 var(--sans); color: var(--ink-2); background: none; border: 1px solid var(--line); border-radius: 10px; width: 36px; height: 36px; cursor: pointer; }
.f-del:hover { color: var(--ink); background: var(--surface-2); }
