/* mycongress.vote - sticker zine. Cream paper, ink outlines, hard shadows, marigold,
   one chunky card per bill. Bricolage Grotesque (display), Atkinson Hyperlegible (reading,
   built for legibility), IBM Plex Mono (small labels). Icons: Phosphor (MIT).
   Reaction emoji: Twemoji (CC-BY 4.0). */
:root {
  --paper: #fbf6ec;
  --card: #fffefa;
  --ink: #1a1916;
  --ink-2: #48443c;
  --ink-3: #6f6a61;  /* 5:1 on --paper: small gray text stays readable (WCAG AA) */
  --line: #1a1916;
  --soft: #efe7d6;
  --soft-2: #f6f0e3;
  --accent: #ffc93c;
  --accent-ink: #1a1916;
  --pink: #ff8fb1;
  --dem: #2f6be6;
  --rep: #e0402f;
  --ind: #8b5cf6;
  --good: #16794c;
  --good-bg: #d9f2e3;
  --bad: #b3261e;
  --bad-bg: #fde2de;
  --wait-bg: #fff1c7;
  --move-bg: #dcebff;
  --idle-bg: #ece8df;
  --shadow: 5px 5px 0 var(--line);
  --display: "Bricolage Grotesque", "Segoe UI", system-ui, sans-serif;
  --body: "Atkinson Hyperlegible", "Segoe UI", system-ui, sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, Consolas, monospace;
  --wrap: 1140px;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --paper: #15130f; --card: #211e18; --ink: #f3ecdf; --ink-2: #cfc6b5; --ink-3: #9a9282; --line: #000;
    --soft: #2c2820; --soft-2: #26221c; --good: #58d197; --good-bg: #173427; --bad: #ff8a7a; --bad-bg: #3b1d19;
    --wait-bg: #3a3016; --move-bg: #1c2b45; --idle-bg: #2c2820; --dem: #6b93ff; --rep: #ff6a57; --ind: #b08cff;
    color-scheme: dark;
  }
  :root:not([data-theme="light"]) .card, :root:not([data-theme="light"]) .tile,
  :root:not([data-theme="light"]) .box { border-color: #4a4336; }
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
/* One bill at a time: the page settles on the nearest card (under the sticky tab bar and
   the day label). Phones stop at every card, so a fling can't skip a bill. */
html { scroll-snap-type: y mandatory; scroll-padding-top: 108px; }
.mast { scroll-snap-align: start; }
.card, .also, .caught, .cloud.open { scroll-snap-align: start; } /* an opened cloud can be taller than the screen */
.more, .site-foot { scroll-snap-align: end; }
@media (pointer: coarse) { .card, .also { scroll-snap-stop: always; } }
body { margin: 0; background: var(--paper); color: var(--ink); font: 400 17px/1.5 var(--body); -webkit-tap-highlight-color: transparent; }
a { color: inherit; }
button, select, input { font: inherit; color: inherit; }
button { cursor: pointer; background: none; border: 0; padding: 0; }
:focus-visible { outline: 3px solid var(--ink); outline-offset: 2px; border-radius: 6px; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--ink); color: var(--paper); padding: 6px 10px; z-index: 99; }
.skip:focus { left: 8px; }
.i, .ti { width: 1.1em; height: 1.1em; fill: currentColor; flex: none; vertical-align: -0.18em; }
.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 20px; }
.mono { font-family: var(--mono); }

/* ------------------------------------------------------------ masthead */
.mast-row { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding-top: 16px; }
.logo { display: inline-flex; align-items: center; text-decoration: none; }
.mark { display: none; }
/* mycongress.vote: a scribbled "my", the big word, and ".vote" as the marigold sticker */
.my {
  align-self: flex-start; display: inline-block; margin: 0 2px 0 0; font: 800 17px/1 var(--display); color: var(--ink-2);
  transform: rotate(-10deg); text-decoration: underline 3px var(--accent); text-underline-offset: 3px;
  transition: transform .25s cubic-bezier(.3,1.6,.5,1);
}
.word { font: 800 30px/1 var(--display); letter-spacing: -0.02em; white-space: nowrap; }
.tld {
  display: inline-block; margin-left: 5px; padding: 4px 9px 5px; background: var(--accent); color: var(--accent-ink);
  border: 2px solid var(--line); border-radius: 9px; box-shadow: 3px 3px 0 var(--line); transform: rotate(-4deg);
  font: 800 22px/1 var(--display); letter-spacing: -0.01em; transition: transform .25s cubic-bezier(.3,1.6,.5,1);
}
.logo:hover .tld { transform: rotate(3deg) scale(1.05); }
.logo:hover .my { transform: rotate(-3deg) translateY(-2px); }
.mast-tools { display: flex; align-items: center; gap: 8px; }
.tool {
  display: inline-flex; align-items: center; gap: 7px; height: 38px; padding: 0 13px; border: 2px solid var(--line);
  border-radius: 999px; background: var(--card); box-shadow: 2px 2px 0 var(--line); font-weight: 700; font-size: 14.5px;
  transition: transform .12s, box-shadow .12s;
}
.tool:hover { transform: translate(-1px, -1px); box-shadow: 3px 3px 0 var(--line); }
.tool:active { transform: translate(2px, 2px); box-shadow: none; }
.tool.tipjar { background: var(--accent); color: var(--accent-ink); text-decoration: none; }
.tool.tipjar .i { transition: transform .3s cubic-bezier(.3,1.6,.5,1); }
.tool.tipjar:hover .i { transform: rotate(-14deg) scale(1.2); }
.tool .lbl-short { display: none; }
#surprise { background: var(--pink); color: #1a1916; }
#surprise .i { transition: transform .4s; }
#surprise:hover .i { transform: rotate(180deg); }
.dateline {
  display: flex; flex-wrap: wrap; align-items: center; gap: 6px 12px; padding-top: 10px; padding-bottom: 14px;
  font: 500 12px/1.4 var(--mono); text-transform: uppercase; letter-spacing: 0.06em; color: var(--ink-3);
}
.dateline .sep { width: 4px; height: 4px; border-radius: 50%; background: var(--ink-3); opacity: .5; }
.live-line { display: inline-flex; align-items: center; gap: 6px; color: var(--ink-2); }
.pulse { width: 8px; height: 8px; border-radius: 50%; background: #22c55e; box-shadow: 0 0 0 0 rgba(34,197,94,.6); animation: pulse 1.8s infinite; }
.about-link { margin-left: auto; font: inherit; color: var(--ink-2); text-decoration: underline; text-underline-offset: 3px; }

/* ------------------------------------------------------------ tabs */
.tabbar {
  position: sticky; top: 0; z-index: 30; background: color-mix(in srgb, var(--paper) 92%, transparent);
  backdrop-filter: blur(10px); border-bottom: 2px solid var(--line);
}
.tabbar-row { display: flex; align-items: center; }
.tabs { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; padding: 10px 0; }
.tabs::-webkit-scrollbar { display: none; }
.tabs button {
  flex: none; display: inline-flex; align-items: baseline; gap: 6px; padding: 7px 15px; border: 2px solid var(--line);
  border-radius: 999px; background: var(--card); box-shadow: 2px 2px 0 var(--line); font-weight: 700; font-size: 15px;
  transition: transform .12s, box-shadow .12s, background .15s;
}
.tabs button:hover { transform: translate(-1px, -1px); box-shadow: 3px 3px 0 var(--line); }
.tabs button.on { background: var(--accent); color: var(--accent-ink); }
.tabs .n { font: 600 11.5px var(--mono); opacity: .65; }

/* ------------------------------------------------------------ layout */
.layout { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 40px; align-items: start; }
.feed { min-width: 0; padding-bottom: 60px; max-width: 700px; }
/* sticky, but never taller than the window: on short screens it scrolls on its own */
.rail { position: sticky; top: 78px; max-height: calc(100vh - 78px); overflow-y: auto; scrollbar-width: none;
  padding: 22px 8px 12px 2px; font-size: 15px; }
.rail::-webkit-scrollbar { display: none; }
.rail-how { margin: 10px 0 0; }
.rail-how .about-link { margin: 0; font-size: 14px; text-align: left; }
@media (max-width: 980px) {
  .layout { grid-template-columns: minmax(0, 1fr); }
  .feed { max-width: none; }
  .rail { display: none; }
}
.search {
  display: flex; align-items: center; gap: 9px; height: 46px; margin-top: 20px; padding: 0 14px; border: 2px solid var(--line);
  border-radius: 14px; background: var(--card); box-shadow: 3px 3px 0 var(--line); color: var(--ink-3);
}
.search:focus-within { box-shadow: 3px 3px 0 var(--accent); }
.search input { flex: 1; min-width: 0; border: 0; background: transparent; outline: none; color: var(--ink); font-size: 16.5px; }
/* tag cloud: a pile of stickers, biggest in the middle */
.cloud { margin-top: 16px; padding: 12px 14px 14px; border: 2px dashed var(--ink-3); border-radius: 18px; background: var(--soft-2); }
.cloud:empty { display: none; }
.cloud.filtering { border-style: solid; border-color: var(--line); background: var(--card); box-shadow: 3px 3px 0 var(--line); }
.cloud-h { display: flex; align-items: center; flex-wrap: wrap; gap: 4px 8px; margin-bottom: 10px; font-size: 14px; color: var(--ink-3); }
.cloud-h .i { width: 18px; height: 18px; color: var(--ink); }
.cloud-h b { font: 800 15px var(--display); color: var(--ink); }
.cloud-h .clear { margin-left: auto; padding: 3px 11px; border: 2px solid var(--line); border-radius: 999px; background: var(--card); font-weight: 700; font-size: 13.5px; }
.words { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 7px 6px; }
.w {
  flex: none; white-space: nowrap;
  display: inline-flex; align-items: center; gap: 5px; min-height: 32px; padding: 3px 11px; border: 1.5px solid var(--line);
  border-radius: 999px; background: var(--fill, var(--card)); color: var(--ink); font: 700 14px/1.15 var(--body);
  transform: rotate(var(--rot, 0deg)); transition: transform .15s cubic-bezier(.3,1.6,.5,1), box-shadow .12s;
}
.w:hover { transform: rotate(0deg) scale(1.07); box-shadow: 2px 2px 0 var(--line); }
.w:active { transform: scale(.96); box-shadow: none; }
.w.t1 { border-color: var(--ink-3); color: var(--ink-2); font-size: 13.5px; }
.w.t2 { font-size: 15.5px; padding: 4px 12px; }
.w.t3 { font: 800 18px/1.1 var(--display); padding: 5px 14px; border-width: 2px; box-shadow: 2px 2px 0 var(--line); color: #1a1916; }
.w.t4 { font: 800 23px/1.05 var(--display); padding: 6px 16px; border-width: 2px; box-shadow: 3px 3px 0 var(--line); color: #1a1916; letter-spacing: -0.01em; }
.w.on { background: var(--ink); color: var(--paper); border-color: var(--ink); box-shadow: 2px 2px 0 var(--accent); }
.w .x { width: 14px; height: 14px; }
.w.w-more { border-style: dashed; color: var(--ink-3); background: transparent; font-weight: 700; }
/* tags on a card: one line only; a chip that doesn't fit is clipped whole, never wrapped */
.kick .topic { display: flex; flex-wrap: wrap; column-gap: 10px; max-height: 1.3em; overflow: hidden; }
.chip { font: 800 15px/1.2 var(--display); color: var(--ink); border-radius: 6px; white-space: nowrap; }
.chip span { color: var(--ink-3); margin-right: 1px; }
.chip:hover { text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 3px; }
.chip.on { background: var(--accent); color: var(--accent-ink); padding: 0 5px; }
.chips { display: flex; flex-wrap: wrap; gap: 6px 4px; margin: 0 0 10px; }
.chips .chip { padding: 3px 10px; border: 1.5px solid var(--line); border-radius: 999px; background: var(--card); margin: 0; font-size: 14px; }
.chips .chip.on { background: var(--accent); }
/* while filtering, the tag rides along at the bottom */
.pill {
  position: fixed; left: 50%; bottom: calc(16px + env(safe-area-inset-bottom)); z-index: 40; display: flex; transform: translateX(-50%);
  border: 2px solid var(--line); border-radius: 999px; background: var(--ink); color: var(--paper); box-shadow: 3px 3px 0 var(--accent);
  animation: toast-in .2s ease-out; max-width: calc(100vw - 32px);
}
.pill[hidden] { display: none; }
.pill button { display: inline-flex; align-items: center; gap: 4px; min-height: 42px; padding: 0 14px; font: 800 15px var(--display); }
.pill .pill-tag { padding-right: 8px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pill .pill-x { padding: 0 14px 0 10px; border-left: 1.5px solid color-mix(in srgb, var(--paper) 30%, transparent); }
body.pill-on .toast { bottom: calc(76px + env(safe-area-inset-bottom)); }
/* loading placeholders */
.skel { pointer-events: none; }
.skel i, .skel .sk-vote { display: block; height: 14px; margin: 10px 0; border-radius: 7px; background: var(--soft); animation: shimmer 1.2s ease-in-out infinite; }
.skel .sk-top { display: flex; gap: 11px; align-items: center; }
.skel .sk-top i:first-child { width: 44px; height: 44px; border-radius: 13px; margin: 0; }
.skel .sk-top i:last-child { width: 120px; margin: 0; }
.skel .sk-h { height: 24px; width: 92%; margin-top: 16px; }
.skel .short { width: 55%; }
.skel .sk-vote { height: 120px; border-radius: 16px; margin-top: 16px; }
.sheet-skel { padding-top: 4px; }
.hello {
  display: flex; align-items: center; gap: 10px; margin-top: 12px; padding: 11px 14px; border: 2px solid var(--line);
  border-radius: 14px; background: var(--accent); color: var(--accent-ink); box-shadow: 3px 3px 0 var(--line); font-weight: 700; font-size: 15px;
}
.hello button:first-of-type { text-decoration: underline; text-underline-offset: 3px; }
.hello .x { margin-left: auto; }

.day {
  position: sticky; top: 58px; z-index: 6; display: flex; align-items: center; gap: 10px; margin: 26px -8px 12px;
  padding: 9px 8px; background: var(--paper); font: 800 14px/1 var(--display); text-transform: uppercase;
  letter-spacing: 0.08em; color: var(--ink);
}
.day span { padding: 5px 10px; border: 2px solid var(--line); border-radius: 8px; background: var(--card); transform: rotate(-2deg); }
.day::after { content: ""; flex: 1; border-top: 2px dashed var(--soft); }
.caught {
  display: flex; flex-wrap: wrap; align-items: center; gap: 12px 14px; margin: 34px 0 10px; padding: 16px 18px; border: 2px dashed var(--line);
  border-radius: 18px; background: var(--soft-2);
}
.caught > div { flex: 1; min-width: 200px; }
.caught .ti { width: 34px; height: 34px; color: var(--ink); }
.caught b { display: block; font: 800 19px/1.2 var(--display); }
.caught span { color: var(--ink-3); font-size: 15px; }
.btn-plain.tipbtn { background: var(--accent); color: var(--accent-ink); }
.tipbtn .i { width: 17px; height: 17px; }
.tipbox p { margin-bottom: 12px; }
.more { padding: 22px 0; color: var(--ink-3); text-align: center; }
.empty { padding: 50px 0; color: var(--ink-3); text-align: center; }
.empty p { margin: 0 0 14px; }
.empty b { color: var(--ink); }
.btn-plain {
  display: inline-flex; align-items: center; gap: 7px; padding: 8px 15px; border: 2px solid var(--line); border-radius: 999px;
  background: var(--card); box-shadow: 2px 2px 0 var(--line); font-weight: 700; font-size: 14.5px; text-decoration: none;
}
.btn-plain:active { transform: translate(2px, 2px); box-shadow: none; }

/* ------------------------------------------------------------ card */
.card {
  position: relative; margin-bottom: 34px; padding: 16px 18px 14px; background: var(--card); border: 2px solid var(--line);
  border-radius: 20px; box-shadow: var(--shadow); transition: opacity .3s, transform .3s, box-shadow .15s;
}
/* The bill you're on stays bright; the ones around it step back. */
#items.focusing .card:not(.focus), #items.focusing .also:not(.focus) { opacity: .42; transform: scale(.985); }
#items.focusing .card.focus { box-shadow: 6px 6px 0 var(--line), 0 0 0 3px var(--accent); }
.vline { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; margin: 10px 0 0; font-size: 14.5px; color: var(--ink-2); }
.vline b { color: var(--ink); }
.vline .i { width: 17px; height: 17px; }
.vline .pass { color: var(--good); } .vline .fail { color: var(--bad); }
.vline .mono { font-size: 13px; color: var(--ink-3); }
.card-top { display: flex; align-items: center; gap: 11px; }
.tile {
  flex: none; display: grid; place-items: center; width: 44px; height: 44px; border: 2px solid var(--line); border-radius: 13px;
  background: var(--tc, var(--soft)); color: #1a1916; box-shadow: 2px 2px 0 var(--line); transform: rotate(-4deg);
  transition: transform .3s cubic-bezier(.3,1.6,.5,1);
}
.card:hover .tile { transform: rotate(4deg) scale(1.06); }
.tile .ti { width: 26px; height: 26px; }
.kick { display: flex; flex-direction: column; min-width: 0; line-height: 1.25; }
.kick .topic { font: 800 15px var(--display); }
.kick .meta { font: 500 12px var(--mono); color: var(--ink-3); letter-spacing: 0.03em; }
.card-top .when { margin-left: auto; align-self: flex-start; font: 500 12px var(--mono); color: var(--ink-3); }
.hed { margin: 12px 0 6px; font: 800 25px/1.13 var(--display); letter-spacing: -0.015em; text-wrap: balance; }
.hed a { text-decoration: none; }
.hed a:hover { text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 3px; }
.dek { margin: 0 0 10px; color: var(--ink-2); font-size: 16.5px; text-wrap: pretty; }
.card .dek { display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.official { margin: 0 0 8px; font-size: 14px; color: var(--ink-3); }
.official i { font-style: normal; color: var(--ink-2); }

/* status stamp + flags */
.stamps { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 10px; margin: 6px 0 2px; }
.stamp {
  display: inline-flex; align-items: center; gap: 7px; padding: 5px 11px; border: 2px solid var(--line); border-radius: 10px;
  font: 800 13.5px/1.1 var(--display); text-transform: uppercase; letter-spacing: 0.04em; transform: rotate(-1.5deg);
  box-shadow: 2px 2px 0 var(--line); background: var(--idle-bg);
}
.stamp .i { width: 17px; height: 17px; }
.tone-law, .tone-done { background: var(--good-bg); }
.tone-desk { background: var(--wait-bg); }
.tone-moving { background: var(--move-bg); }
.tone-failed, .tone-vetoed { background: var(--bad-bg); }
.stamp-sub { font-size: 14px; font-weight: 700; color: var(--ink-2); }
.flag {
  display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border-radius: 999px; font-weight: 700; font-size: 13px;
  background: #dcfce7; color: #14532d; border: 1.5px solid #14532d;
}
.flag.cal { background: var(--wait-bg); color: #7a5500; border-color: #7a5500; }
.flag .i { width: 15px; height: 15px; }

/* mini tracker */
.track { display: flex; list-style: none; margin: 12px 0 4px; padding: 0; max-width: 460px; }
.track li { flex: 1; position: relative; padding-top: 22px; font: 800 12.5px/1.25 var(--display); text-transform: uppercase; letter-spacing: 0.04em; color: var(--ink-3); }
.track li::before { content: ""; position: absolute; top: 7px; left: 0; right: 0; height: 3px; border-radius: 3px; background: var(--soft); }
.track li:last-child::before { right: auto; width: 0; }
.track li.done::before { background: var(--ink); transform-origin: left; animation: draw .6s ease-out both; }
.track .node { position: absolute; top: 0; left: 0; width: 17px; height: 17px; border-radius: 50%; border: 2.5px solid var(--line); background: var(--card); display: grid; place-items: center; }
.track .done .node { background: var(--ink); }
.track .done .node::after { content: ""; width: 5px; height: 8px; border: solid var(--card); border-width: 0 2px 2px 0; transform: translate(0, -1px) rotate(45deg); }
.track .now .node { background: var(--accent); animation: bob 1.8s ease-in-out infinite; }
.track .fail .node { background: var(--bad); }
.track .next .node { border-style: dashed; border-color: var(--ink-3); }
.track .done, .track .now { color: var(--ink); }
.track .sub { display: block; text-transform: none; letter-spacing: 0; font: 500 12px var(--body); color: var(--ink-3); }

/* vote panel */
.vote { margin: 14px 0 6px; padding: 12px 14px; border: 2px solid var(--line); border-radius: 16px; background: var(--soft-2); }
.vote + .vote { margin-top: 10px; }
.vote-h { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; font: 500 12px/1.4 var(--mono); color: var(--ink-3); text-transform: uppercase; letter-spacing: 0.04em; }
.vote-h b { color: var(--ink); font-weight: 600; }
.result { margin-left: auto; padding: 2px 9px; border: 2px solid var(--line); border-radius: 8px; font: 800 13px/1.2 var(--display); letter-spacing: .05em; transform: rotate(2deg); }
.result.pass { background: var(--good-bg); color: var(--good); }
.result.fail { background: var(--bad-bg); color: var(--bad); }
.vote-body { display: grid; grid-template-columns: minmax(0, 270px) auto; gap: 6px 22px; align-items: end; margin-top: 8px; }
.hemi { width: 100%; height: auto; display: block; overflow: visible; }
.vote .hemi { clip-path: inset(0 100% 0 0); }
.vote.in .hemi, .sheet .vote .hemi { animation: sweep .9s cubic-bezier(.3,.7,.2,1) forwards; }
.seat.D { fill: var(--dem); } .seat.R { fill: var(--rep); } .seat.I { fill: var(--ind); } .seat.X { fill: var(--ink-2); }
.seat.no { fill: var(--card); stroke-width: 1.4; }
.seat.no.D { stroke: var(--dem); } .seat.no.R { stroke: var(--rep); } .seat.no.I { stroke: var(--ind); }
.seat.nv { fill: var(--soft); }
.named .seat { cursor: pointer; }
.named .seat:hover, .named .seat.hot { stroke: var(--ink); stroke-width: 2.4; }
.tally { display: grid; gap: 0; margin: 0; padding-bottom: 6px; }
.tally div { display: flex; align-items: baseline; gap: 8px; }
.tally dd { margin: 0; min-width: 2.2ch; text-align: right; font: 800 34px/1.02 var(--display); letter-spacing: -0.03em; }
.tally dt { font: 800 13px var(--display); text-transform: uppercase; letter-spacing: .05em; color: var(--ink-3); }
.tally .nv dd { font-size: 18px; color: var(--ink-3); }
.parties { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 14px; margin: 8px 0 0; font: 600 13px var(--mono); }
.parties div { display: flex; align-items: center; gap: 6px; }
.parties dt { display: inline-flex; align-items: center; gap: 5px; color: var(--ink-2); }
.parties dt::before { content: ""; width: 10px; height: 10px; border-radius: 50%; background: var(--pc); border: 1.5px solid var(--line); }
.parties dd { margin: 0; }
.parties dd span { color: var(--ink-3); padding: 0 2px; }
.key { margin-left: auto; font: 500 11.5px var(--mono); color: var(--ink-3); }
.note { display: flex; align-items: flex-start; gap: 7px; margin: 8px 0 0; font-size: 15px; font-weight: 700; color: var(--ink-2); }
.note .i { margin-top: 2px; }
.v-yes { color: var(--good); font-weight: 700; } .v-no { color: var(--bad); font-weight: 700; } .v-nv { color: var(--ink-3); }
.novote { display: flex; align-items: flex-start; gap: 8px; margin: 12px 0 4px; padding: 9px 12px; border: 2px dashed var(--ink-3); border-radius: 14px; font-size: 14.5px; color: var(--ink-2); }
.novote .i { margin-top: 3px; }

/* byline + what's in it */
.byline { display: flex; align-items: center; gap: 10px; margin: 12px 0 0; font-size: 14.5px; color: var(--ink-2); }
.face {
  width: 34px; height: 34px; border-radius: 50%; object-fit: cover; object-position: top; flex: none; border: 2px solid var(--line);
  background: var(--soft); display: grid; place-items: center; font: 700 12px var(--mono); color: var(--ink-3);
}
.byline b { color: var(--ink); }
.pty { font: 600 12.5px var(--mono); }
.pty.D { color: var(--dem); } .pty.R { color: var(--rep); } .pty.I { color: var(--ind); }
.byline small { display: block; font-size: 13px; color: var(--ink-3); }
.inside { margin-top: 12px; }
.inside > summary {
  display: inline-flex; align-items: center; gap: 7px; padding: 6px 12px; border: 2px solid var(--line); border-radius: 999px;
  background: var(--card); font-weight: 700; font-size: 14.5px; cursor: pointer; list-style: none; box-shadow: 2px 2px 0 var(--line);
}
.inside > summary::-webkit-details-marker { display: none; }
.inside > summary .caret { transition: transform .2s; }
.inside[open] > summary .caret { transform: rotate(180deg); }
.inside[open] > summary { background: var(--accent); color: var(--accent-ink); }
.points { margin: 12px 0 4px; padding: 0; list-style: none; }
.points li { position: relative; padding-left: 26px; margin: 7px 0; font-size: 16px; line-height: 1.42; }
.points li::before {
  content: counter(pt); counter-increment: pt; position: absolute; left: 0; top: 1px; width: 19px; height: 19px; border-radius: 6px;
  background: var(--ink); color: var(--paper); font: 800 11.5px/19px var(--display); text-align: center;
}
.points { counter-reset: pt; }
.affects { margin: 8px 0 0; font-size: 14.5px; color: var(--ink-3); }
.affects b { color: var(--ink); font-weight: 700; }
.ai { display: inline-flex; align-items: center; gap: 6px; margin: 10px 0 0; font-size: 12.5px; color: var(--ink-3); }

.actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
.act {
  display: inline-flex; align-items: center; gap: 7px; padding: 7px 13px; border: 2px solid var(--line); border-radius: 999px;
  background: var(--card); box-shadow: 2px 2px 0 var(--line); font-weight: 700; font-size: 14.5px; text-decoration: none;
  transition: transform .12s, box-shadow .12s;
}
.act:hover { transform: translate(-1px, -1px); box-shadow: 3px 3px 0 var(--line); }
.act:active { transform: translate(2px, 2px); box-shadow: none; }
.act.primary { background: var(--ink); color: var(--paper); }
.act.on { background: var(--accent); color: var(--accent-ink); }
.act .i { width: 17px; height: 17px; }
.act .mono { font-size: 12px; opacity: .7; }
.act .short { display: none; }
.act.icon-only { padding: 7px 10px; }
.inside-body { margin-top: 10px; padding: 4px 14px 10px; border: 2px solid var(--line); border-radius: 14px; background: var(--soft-2); animation: rise .2s ease-out; }
.inside-body[hidden] { display: none; }

/* ------------------------------------------------------------ reactions */
.reacts { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 14px; padding-top: 12px; border-top: 2px dashed var(--soft); }
.rx {
  display: inline-flex; align-items: center; gap: 6px; height: 34px; padding: 0 10px; border: 2px solid var(--line); border-radius: 999px;
  background: var(--card); font: 800 14px var(--display); transition: transform .12s, background .15s;
}
.rx:hover { transform: translateY(-2px); }
.rx.mine { background: var(--accent); color: var(--accent-ink); }
.rx.ghost { border-style: dashed; border-color: var(--ink-3); opacity: .8; }
.rx.ghost:hover { opacity: 1; border-style: solid; border-color: var(--line); }
.rx b { font-weight: 800; min-width: 1ch; }
.rx.pop .emo { animation: pop .45s cubic-bezier(.3,1.8,.4,1); }
.rx.add { gap: 0; padding: 0 9px; color: var(--ink-2); }
.rx.add .plus { width: 11px; height: 11px; margin-left: -3px; margin-top: -12px; }
.emo { width: 20px; height: 20px; flex: none; display: inline-block; }
.emo.word {
  width: auto; height: auto; padding: 2px 6px; border-radius: 6px; background: var(--wc); color: #fff; font: 800 12px/1.2 var(--display);
  letter-spacing: .03em; white-space: nowrap; transform: rotate(-3deg); text-shadow: 0 1px 0 rgba(0,0,0,.25);
}
.picker {
  position: fixed; z-index: 70; width: 340px; max-height: min(460px, 70vh); overflow-y: auto; padding: 12px 14px 14px;
  background: var(--card); border: 2px solid var(--line); border-radius: 18px; box-shadow: 6px 6px 0 var(--line); animation: rise .18s ease-out;
}
.picker-h { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; margin-bottom: 4px; }
.picker-h b { font: 800 18px var(--display); }
.picker-h span { font-size: 12.5px; color: var(--ink-3); }
.picker h4 { margin: 10px 0 6px; font: 800 12px var(--display); text-transform: uppercase; letter-spacing: .08em; color: var(--ink-3); }
.picker .grid { display: flex; flex-wrap: wrap; gap: 5px; }
.pick { display: grid; place-items: center; min-width: 42px; height: 42px; padding: 0 6px; border: 2px solid transparent; border-radius: 12px; transition: transform .1s, background .1s; }
.pick:hover { background: var(--soft-2); border-color: var(--line); transform: scale(1.12); }
.pick.mine { background: var(--accent); border-color: var(--line); }
.pick .emo { width: 28px; height: 28px; }
.pick .emo.word { width: auto; height: auto; font-size: 13px; }
@media (max-width: 640px) {
  .picker { left: 0 !important; right: 0; bottom: 0; top: auto !important; width: 100%; max-height: 62vh; border-radius: 20px 20px 0 0; box-shadow: none; border-bottom: 0; }
}

/* also on the record */
.also { margin-bottom: 22px; border: 2px dashed var(--ink-3); border-radius: 18px; background: var(--soft-2); }
.also > summary { display: flex; align-items: center; gap: 10px; padding: 12px 16px; cursor: pointer; list-style: none; font-size: 15px; }
.also > summary::-webkit-details-marker { display: none; }
.also > summary .ti { width: 22px; height: 22px; }
.also > summary b { font-weight: 800; }
.also > summary .caret { margin-left: auto; transition: transform .2s; }
.also[open] > summary .caret { transform: rotate(180deg); }
.also ul { list-style: none; margin: 0; padding: 0 16px 10px; }
.also li { display: flex; align-items: baseline; gap: 12px; padding: 8px 0; border-top: 1.5px dashed var(--soft); font-size: 15px; }
.also li a { text-decoration: none; font-weight: 700; }
.also li a:hover { text-decoration: underline; }
.also li .num { margin-left: auto; font: 500 12px var(--mono); color: var(--ink-3); white-space: nowrap; }

/* ------------------------------------------------------------ rail */
.box { margin-bottom: 18px; padding: 14px 16px; background: var(--card); border: 2px solid var(--line); border-radius: 18px; box-shadow: 4px 4px 0 var(--line); }
.box:nth-child(2) { transform: rotate(.6deg); }
.box:nth-child(3) { transform: rotate(-.5deg); }
.rail h3, .sheet h3 { margin: 0 0 10px; font: 800 13px/1.2 var(--display); letter-spacing: .08em; text-transform: uppercase; color: var(--ink-3); }
.rail p { margin: 6px 0; color: var(--ink-2); }
.stats { display: grid; grid-template-columns: 1fr 1fr; gap: 12px 10px; margin: 0; }
.stats div { display: flex; flex-direction: column-reverse; }
.stats dd { margin: 0; font: 800 28px/1.05 var(--display); letter-spacing: -.02em; }
.stats dt { font-size: 12.5px; color: var(--ink-3); }
.how { list-style: none; margin: 0; padding: 0; counter-reset: s; }
.how li { position: relative; padding-left: 32px; margin: 0 0 10px; color: var(--ink-2); counter-increment: s; }
.how li::before {
  content: counter(s); position: absolute; left: 0; top: 0; width: 22px; height: 22px; border-radius: 7px; background: var(--accent);
  border: 2px solid var(--line); display: grid; place-items: center; font: 800 12px var(--display); color: #1a1916;
}
.how b { color: var(--ink); }
.keys { list-style: none; margin: 0; padding: 0; color: var(--ink-2); }
.keys li { margin: 5px 0; }
kbd {
  display: inline-block; min-width: 24px; padding: 1px 6px; margin-right: 3px; border: 2px solid var(--line); border-radius: 6px;
  background: var(--card); box-shadow: 1px 2px 0 var(--line); font: 700 12px/1.5 var(--mono); text-align: center; color: var(--ink);
}

/* ------------------------------------------------------------ detail sheet */
.sheet { position: fixed; inset: 0; z-index: 60; }
.sheet[hidden] { display: none; }
.sheet-bg { position: absolute; inset: 0; background: rgba(20, 18, 14, 0.5); animation: fade .2s ease-out; }
.sheet-body {
  position: absolute; top: 0; right: 0; bottom: 0; width: min(700px, 100%); overflow-y: auto; background: var(--paper);
  border-left: 2px solid var(--line); padding: 22px 28px 60px; animation: slide .28s cubic-bezier(.2,.8,.2,1); overscroll-behavior: contain;
}
@media (max-width: 720px) {
  .sheet-body { top: auto; left: 0; width: 100%; max-height: 94vh; border-left: 0; border-top: 2px solid var(--line); border-radius: 22px 22px 0 0; padding: 22px 18px calc(48px + env(safe-area-inset-bottom)); animation: rise .28s cubic-bezier(.2,.8,.2,1); }
  /* grab handle: drag down from the top to close */
  .sheet-body::before { content: ""; position: absolute; top: 8px; left: 50%; width: 44px; height: 5px; margin-left: -22px; border-radius: 3px; background: var(--ink-3); opacity: .45; }
}
.sheet-close {
  position: sticky; top: 0; float: right; z-index: 2; display: grid; place-items: center; width: 40px; height: 40px; margin: -4px -8px 0 0;
  border: 2px solid var(--line); border-radius: 50%; background: var(--card); box-shadow: 2px 2px 0 var(--line);
}
.sheet .card-top { margin-right: 44px; }
.sheet .hed { font-size: 30px; }
.sheet section.part { margin-top: 24px; }
.sheet .vote { background: var(--card); }
.sheet .vote-body { grid-template-columns: minmax(0, 360px) auto; }
.vote-more { display: flex; gap: 10px; margin-top: 10px; }
.members-tabs { display: flex; gap: 6px; flex-wrap: wrap; margin: 12px 0 8px; }
.members-tabs button { padding: 4px 11px; border: 2px solid var(--line); border-radius: 999px; font-size: 13.5px; font-weight: 700; background: var(--card); }
.members-tabs button.on { background: var(--ink); color: var(--paper); }
.mlist { columns: 2 200px; column-gap: 20px; font-size: 14px; }
.mlist .pg { break-inside: avoid; margin-bottom: 12px; }
.mlist h4 { margin: 0 0 4px; font: 800 12.5px var(--display); letter-spacing: .05em; text-transform: uppercase; }
.mlist .m { padding: 1px 0; }
.mlist .st { font: 500 11.5px var(--mono); color: var(--ink-3); margin-left: 4px; }
.timeline { list-style: none; margin: 0; padding: 0; border-left: 3px solid var(--ink); }
.timeline li { position: relative; padding: 2px 0 12px 18px; }
.timeline li::before { content: ""; position: absolute; left: -9px; top: 6px; width: 12px; height: 12px; border-radius: 50%; background: var(--accent); border: 2px solid var(--line); }
.timeline time { display: block; font: 500 12.5px var(--mono); color: var(--ink-3); }
.crs { white-space: pre-line; font-size: 15px; color: var(--ink-2); margin-top: 10px; padding: 12px; border: 2px solid var(--line); border-radius: 14px; background: var(--card); }
details.fold > summary { cursor: pointer; font-weight: 700; font-size: 15px; list-style: none; display: flex; align-items: center; gap: 8px; }
details.fold > summary::-webkit-details-marker { display: none; }
details.fold > summary .i { transition: transform .2s; }
details.fold[open] > summary .i { transform: rotate(180deg); }
.links { display: flex; flex-wrap: wrap; gap: 10px; }
.report { display: flex; align-items: flex-start; gap: 7px; margin: 16px 0 0; font-size: 14px; color: var(--ink-3); }
.report .i { margin-top: 2px; }
.report a { color: var(--ink-2); font-weight: 700; }
.how-vote { max-width: 300px; margin: 4px 0 10px; }
.tip {
  position: fixed; z-index: 80; pointer-events: none; padding: 7px 11px; border-radius: 10px; background: var(--ink); color: var(--paper);
  font-size: 13.5px; line-height: 1.35; border: 2px solid var(--line); max-width: 240px;
}
.tip span { font: 500 11.5px var(--mono); opacity: .8; }
.site-foot { padding-top: 10px; padding-bottom: 80px; font-size: 13.5px; color: var(--ink-3); max-width: 720px; }
.site-foot p { margin: 0 0 8px; }
.site-foot b { color: var(--ink-2); }
.site-foot .about-link { margin: 0; font: inherit; }
.toast {
  position: fixed; left: 50%; bottom: 26px; z-index: 90; padding: 10px 18px; border-radius: 999px; background: var(--ink); color: var(--paper);
  border: 2px solid var(--line); font-weight: 700; font-size: 14.5px; transform: translateX(-50%); animation: toast-in .2s ease-out;
}

@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(34,197,94,.6); } 70% { box-shadow: 0 0 0 8px rgba(34,197,94,0); } 100% { box-shadow: 0 0 0 0 rgba(34,197,94,0); } }
@keyframes bob { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-3px); } }
@keyframes draw { from { transform: scaleX(0); } to { transform: scaleX(1); } }
@keyframes sweep { from { clip-path: inset(0 100% 0 0); } to { clip-path: inset(0 0 0 0); } }
@keyframes pop { 0% { transform: scale(1); } 40% { transform: scale(1.55) rotate(-8deg); } 100% { transform: scale(1); } }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes slide { from { transform: translateX(30px); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes rise { from { transform: translateY(24px); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes toast-in { from { transform: translate(-50%, 12px); opacity: 0; } to { transform: translate(-50%, 0); opacity: 1; } }
@keyframes shimmer { 0%, 100% { opacity: 1; } 50% { opacity: .45; } }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .vote .hemi { clip-path: none; }
}

@media (max-width: 640px) {
  body { font-size: 16px; }
  .wrap { padding: 0 14px; }
  .word { font-size: 24px; }
  .my { font-size: 14px; text-decoration-thickness: 2px; }
  .tld { font-size: 17px; padding: 3px 7px 4px; margin-left: 4px; }
  .tool .lbl { display: none; }
  .tool .lbl-short { display: inline; }
  /* the tab row scrolls sideways: fade the right edge so it looks like it does */
  .tabs { mask-image: linear-gradient(to right, #000 82%, transparent); -webkit-mask-image: linear-gradient(to right, #000 82%, transparent); padding-right: 30px; }
  .tool { padding: 0 10px; height: 36px; font-size: 13.5px; }
  .cloud { margin-top: 12px; padding: 9px 9px 11px; }
  .cloud-h { margin-bottom: 8px; }
  .words { gap: 6px 5px; }
  .w { min-height: 30px; padding: 2px 10px; }
  .w.t4 { font-size: 18px; padding: 4px 13px; }
  .w.t3 { font-size: 15.5px; padding: 3px 11px; }
  .w.t2 { font-size: 14.5px; }
  .hello { margin-top: 10px; padding: 8px 12px; font-size: 14.5px; }
  .wide { display: none; }
  html { scroll-padding-top: 100px; }
  .day { top: 52px; }
  /* phones: one bill should fit one screen */
  .card { padding: 12px 13px 10px; border-radius: 18px; box-shadow: 4px 4px 0 var(--line); margin-bottom: 26px; }
  .tile { width: 38px; height: 38px; border-radius: 11px; }
  .tile .ti { width: 22px; height: 22px; }
  .hed { font-size: 21px; margin: 9px 0 5px; }
  .card .dek { font-size: 15.5px; margin-bottom: 8px; }
  .stamp { font-size: 12.5px; padding: 4px 9px; }
  .track { margin: 8px 0 2px; }
  .track li { padding-top: 20px; }
  .track .sub { display: none; }
  .track .now .sub { display: block; }
  .vote { margin: 10px 0 4px; padding: 9px 11px; }
  .note { font-size: 14px; margin-top: 6px; }
  .byline { margin-top: 9px; }
  .byline small { display: none; }
  .face { width: 30px; height: 30px; }
  .actions { gap: 6px; margin-top: 10px; }
  .act { padding: 6px 10px; font-size: 13.5px; gap: 5px; }
  .act .long { display: none; }
  .act .short { display: inline; }
  .reacts { margin-top: 10px; padding-top: 9px; gap: 6px; }
  .rx { height: 32px; padding: 0 9px; }
  .novote { margin: 8px 0 2px; padding: 7px 10px; font-size: 13.5px; }
  .vote-body { grid-template-columns: minmax(0, 1fr) auto; gap: 4px 12px; }
  .vote .hemi-wrap { max-width: 215px; }
  .tally dd { font-size: 27px; }
  .sheet .vote-body { grid-template-columns: minmax(0, 1fr); }
  .sheet .tally { grid-auto-flow: column; justify-content: start; gap: 16px; }
  .sheet .hed { font-size: 25px; }
}
