/* Bill page. Reuses record.css (panels, buttons); this file only adds what a bill needs.
 * Pictures first: the path, the cosponsors, each vote and when members spoke are drawn by bill.js
 * with viz.js. Marks hold 3:1 against their panel; no text here is under 12 px. */
.bill-shell {
  padding-bottom: 28px;
  --dem-fill: var(--dem); --rep-fill: var(--rep); --ind-fill: #98a1ae; --oth-fill: #d9c9a3;
  --anon-fill: #8b93a1; --off-line: #6b7482;
}
.bill-status { margin: 18px 0; color: var(--paper-dim); }
/* When the status line is all the page has (a give-up, a missing bill), it starts where the site
   header does, as on the member page, not 90 px in at the bill's reading column. The loading
   line keeps the reading column so it does not jump when the bill draws. */
.bill-shell:has(> #bill-header[hidden]):has(> #bill-content[hidden]):not(:has(> #bill-status .bill-skel)) { max-width: 1180px; }
.bill-status a { color: var(--gold); text-decoration: underline; text-underline-offset: 3px; }
/* Words for screen readers only. */
.bill-sr { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; border: 0; }
/* Loading: a still-or-sweeping block at the size of what will replace it, never the word alone. */
.bill-skel { display: block; border-radius: 6px;
  background: linear-gradient(90deg, var(--ink-2) 0%, var(--line) 50%, var(--ink-2) 100%) 0 0 / 300% 100%;
  animation: bill-skel 1.4s ease-in-out infinite; }
@keyframes bill-skel { from { background-position: 100% 0; } to { background-position: 0 0; } }
/* While the bill loads, the status line is a slot for one line over a skeleton in the shape of what
   comes: the sentence, the four counts, the stage strip and the first vote card, in the order the
   page draws them (on a phone: the sentence, the path, the counts, the votes). The quiet line
   (bill.js) and the waking line (startup-retry.js, .cc-wake) share the slot, one at a time
   (data-wake-hide), and the slot has its height from the first paint, so neither moves the
   skeleton. The skeleton reaches past the fold, so the footer is never on screen to be pushed down
   when the bill draws. Every exit (the bill, a missing bill, a failure, a give-up) sets the status
   text, which takes all of this out. */
.bill-status:has(> .bill-skel-page) { display: grid; grid-template-columns: minmax(0, 1fr); margin: 6px 0 0; }
.bill-quiet, .bill-status > .cc-wake { grid-area: 1 / 1; min-height: 22px; font-size: 15px; line-height: 22px; }
.bill-status:has(> .bill-skel-page) > .cc-wake { margin: 0; }
.bill-skel-page { grid-area: 2 / 1; display: flex; flex-direction: column; min-height: 100vh; }
.bill-skel--line { flex: none; width: 100%; height: 20px; margin: 10px 0 0; max-width: 46em; }
.bill-skel--end { width: 62%; }
.bill-skel-tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; margin: 18px 0 0; }
.bill-skel-tiles > .bill-skel { height: 94px; }
.bill-skel-card { display: block; margin-top: 18px; background: var(--panel); border: 1px solid var(--line); border-radius: 5px; overflow: hidden; }
.bill-skel-card__head { display: block; padding: 18px 18px; border-bottom: 1px solid var(--line); }
.bill-skel-card__body { display: block; padding: 20px 18px 18px; }
.bill-skel--title { width: 9em; height: 14px; border-radius: 3px; }
.bill-skel--label { width: 11em; max-width: 70%; height: 26px; border-radius: 4px; }
.bill-skel--note { height: 14px; margin-top: 12px; border-radius: 3px; }
.bill-skel--box { height: 110px; }
.bill-skel--box + .bill-skel--label { margin-top: 24px; }
.bill-skel--marks { height: 120px; margin-top: 14px; }
/* The six steps of the path: a row of marks with a word under each, as the strip is drawn. */
.bill-skel-path { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); margin: 52px 0 18px; }
.bill-skel-step { display: grid; justify-items: center; gap: 16px; }
.bill-skel-step::before { content: ""; width: 18px; height: 18px; border-radius: 50%; background: var(--line); }
.bill-skel-step::after { content: ""; width: 64%; height: 12px; border-radius: 3px; background: var(--ink-2); }
@media (max-width: 560px) {
  /* The waking line takes two lines on a phone; its slot has them from the start. */
  .bill-quiet, .bill-status > .cc-wake { min-height: 44px; }
  .bill-skel-tiles { order: 1; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 14px; }
  .bill-skel-tiles > .bill-skel { height: 76px; }
  .bill-skel-card--vote { order: 2; }
  /* The path runs down the card, a mark and its word on each line. */
  .bill-skel-path { grid-template-columns: none; grid-auto-rows: 52px; margin: 20px 0 14px; }
  .bill-skel-step { grid-template-columns: 22px 1fr; justify-items: start; align-items: start; gap: 0 22px; }
  .bill-skel-step::after { width: 45%; height: 14px; margin-top: 2px; }
}
.bill-members li.bill-skel--member { display: block; height: 20px; margin: 12px 0; padding: 0; border: 0; border-radius: 4px; }
.bill-skel--mine { display: inline-block; vertical-align: middle; width: 16em; max-width: 100%; height: 1.3em; border-radius: 4px; }
.bill-header { padding: 18px 0 6px; }
.bill-kicker { font-size: 12px; letter-spacing: .14em; text-transform: uppercase; color: var(--paper-mute); }
.bill-identifier { font-family: var(--serif); font-size: 34px; line-height: 1.15; margin: 6px 0 4px; }
.bill-title { font-size: 18px; line-height: 1.4; margin: 0 0 8px; color: var(--paper); }
.bill-meta { font-size: 13px; color: var(--paper-mute); margin: 0; }
.bill-facts { font-size: 15px; line-height: 1.5; margin: 10px 0 0; color: var(--paper-dim); }
.bill-facts p { margin: 0 0 4px; }

/* ── First screen: one sentence, four counts ───────────────────────────── */
.bill-lede { margin: 6px 0 0; }
.bill-lede__text { font-family: var(--serif); font-size: 21px; line-height: 1.4; margin: 4px 0 14px; max-width: 46em; color: var(--paper); overflow-wrap: anywhere; }
.bill-lede__text.is-facts { font-family: var(--sans); font-size: 17px; color: var(--paper-dim); }
.bill-lede__src { font-family: var(--mono); font-size: 12px; color: var(--gold); white-space: nowrap; }
.bill-lede__src:hover { text-decoration: underline; }
.bill-glance { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; margin: 0 0 4px; }
.bill-glance:empty { display: none; }
/* One tile alone keeps the width it has in a row of three, rather than stretching across. */
.bill-glance:has(> :only-child) { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.bill-glance__item { display: grid; align-content: start; gap: 2px; padding: 12px 14px; background: var(--ink-2); border: 1px solid var(--line-2); border-radius: 6px; color: var(--paper); min-width: 0; }
.bill-glance__item:hover { border-color: var(--paper-mute); background: var(--panel); }
.bill-glance__n { font-weight: 800; font-size: 28px; line-height: 1.05; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.bill-glance__label { font-weight: 600; font-size: 14px; line-height: 1.3; }
.bill-glance__note { font-family: var(--mono); font-size: 12px; color: var(--paper-mute); }

/* ── Section heads: a title, a share control, a "?" that opens the definitions ── */
.bill-shell .panel__head { align-items: center; }
.bill-shell h2.panel__title { margin: 0; }
.bill-head-tools { display: inline-flex; gap: 8px; }
.bill-share-toggle, .bill-linkbtn { font: 600 13px var(--sans); color: var(--paper-dim); background: transparent; border: 1px solid var(--line-2); border-radius: 999px; padding: 4px 12px; cursor: pointer; }
.bill-share-toggle:hover, .bill-share-toggle[aria-expanded="true"] { color: var(--paper); border-color: var(--paper-mute); }
.bill-linkbtn { padding: 2px 10px; }
.bill-sharebox { margin: 12px 0 0; padding: 12px 14px; background: var(--ink-2); border: 1px solid var(--line-2); border-radius: 6px; }
.bill-sharebox__text { margin: 0 0 10px; font-family: var(--mono); font-size: 13px; line-height: 1.5; white-space: pre-wrap; overflow-wrap: anywhere; color: var(--paper); }
/* The "?" sits in the section's head, before Share; it opens the note at the top of the section. */
.bill-head-tools { align-items: center; }
.bill-help { position: relative; flex: none; display: inline-grid; place-items: center; width: 26px; height: 26px; padding: 0; background: transparent; border: 1px solid var(--line-2); border-radius: 50%; font: 700 13px var(--sans); color: var(--paper-dim); cursor: pointer; }
.bill-help:hover, .bill-help[aria-expanded="true"] { color: var(--paper); border-color: var(--paper-mute); }
.bill-help[hidden] { display: none; }
@media (pointer: coarse) {
  /* A finger gets a 44 px target around the 26 px ring. */
  .bill-head-tools { gap: 10px; }
  .bill-help::after { content: ""; position: absolute; inset: -9px; }
  /* The same for a vote's member-votes button: 28 px drawn, 44 px to a finger (its 26 px inside
     the border, 6 px more above and 12 below); the area overlaps, so no row grows. Above it is only
     6 px of margin (no source link, no official wording: the "...as a table" line sits right there),
     so the area reaches 5 px above the border and stops 1 px short of that line; below there is at
     least 12 px (the list's margin and padding, or the row's padding). */
  .bill-vote > .bill-expand { position: relative; }
  .bill-vote > .bill-expand::after { content: ""; position: absolute; inset: -6px 0 -12px; }
}
.bill-q__body { margin: 0 0 12px; padding: 10px 14px; border-left: 2px solid var(--line-2); }
.bill-q__body p:first-child { margin-top: 0; }
.bill-astable { margin: 12px 0 0; }
.bill-astable > summary, .bill-howto > summary, .bill-more > summary { cursor: pointer; font-size: 14px; color: var(--paper-dim); padding: 4px 0; }
.bill-astable > summary:hover, .bill-howto > summary:hover, .bill-more > summary:hover { color: var(--paper); }
.bill-more { margin: 6px 0 0; }
.bill-more > p { margin: 6px 0 0; }
/* A table wider than its box scrolls inside it, and the side that has more is shaded: two shades drawn
 * with the box (scroll), each hidden by a solid cover in the panel's colour, as wide as the shade, drawn
 * with the table (local) at its own ends. A shade shows only where the table goes on past the box, all
 * of it once the table goes on 10 px or more; a table that fits shows none. bill.js gives a box that
 * scrolls a tab stop; the ring is the page's focus ring. */
.bill-tablewrap { overflow-x: auto; margin-top: 8px;
  background:
    linear-gradient(var(--panel), var(--panel)) left / 10px 100% no-repeat local,
    linear-gradient(var(--panel), var(--panel)) right / 10px 100% no-repeat local,
    linear-gradient(to right, var(--paper-mute), transparent) left / 10px 100% no-repeat scroll,
    linear-gradient(to left, var(--paper-mute), transparent) right / 10px 100% no-repeat scroll; }
.bill-tablewrap:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; border-radius: 3px; }
.bill-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.bill-table th, .bill-table td { text-align: left; padding: 7px 10px 7px 0; border-bottom: 1px solid var(--line); vertical-align: top; overflow-wrap: break-word; }
/* A cell breaks between words, not inside one ("Democr/atic"): "anywhere" let the table squeeze its
 * columns to a few letters. A name link in a cell follows the cell, not the section's link rule. */
.bill-table th a, .bill-table td a { overflow-wrap: break-word; }
.bill-table thead th { font-family: var(--mono); font-size: 12px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--paper-mute); }
.bill-table tbody th { font-weight: 600; }
.bill-table a { color: var(--gold); }
.bill-st-code { display: none; }

/* ── Where it stands: the path ─────────────────────────────────────────── */
.bill-stage-label { font-family: var(--serif); font-size: 26px; line-height: 1.2; margin: 10px 0 2px; }
.bill-stage-meaning { margin: 0 0 6px; color: var(--paper-dim); font-size: 15px; }
.bill-pic { position: relative; margin: 10px 0 0; min-width: 0; }
.bill-pic > svg { display: block; max-width: 100%; height: auto; overflow: visible; }
.path-seg { stroke-width: 3; stroke-linecap: round; }
.path-seg--done { stroke: var(--paper-dim); }
.path-seg--unknown { stroke: var(--paper-mute); stroke-dasharray: 2 6; }
/* Not reached yet: a thin line that still holds 3:1, so the road ahead is visible but quiet. */
.path-seg--ahead { stroke: var(--paper-mute); stroke-width: 1.5; }
.path-node { stroke-width: 2.5; }
.path-step--done .path-node { fill: var(--paper-dim); stroke: var(--paper-dim); }
.path-step--now .path-node { fill: var(--paper); stroke: var(--paper); }
.path-step--now .path-halo, .path-step--stop .path-halo { fill: none; stroke: var(--paper); stroke-width: 2; opacity: .55; }
.path-step--stop .path-node { fill: var(--panel); stroke: var(--paper); }
.path-x { stroke: var(--paper); stroke-width: 2.2; stroke-linecap: round; }
.path-step--unknown .path-node { fill: var(--panel); stroke: var(--paper-mute); stroke-dasharray: 3 3; }
.path-step--ahead .path-node { fill: var(--panel); stroke: var(--paper-mute); }
.path-q { font: 700 12px var(--sans); fill: var(--paper-dim); }
.path-name { font: 600 14px var(--sans); fill: var(--paper-dim); }
.path-name.is-now { font-weight: 800; fill: var(--paper); }
.path-step--ahead .path-name, .path-step--unknown .path-name { fill: var(--paper-mute); }
.path-note { font: 400 12px var(--mono); fill: var(--paper-mute); }
.path-step--done .path-note, .path-step--now .path-note, .path-step--stop .path-note { fill: var(--paper-dim); }
.path-doc { cursor: pointer; outline: none; }
.path-doc__hit { fill: transparent; }
/* A text version: drawn in ink, not gold — gold in a picture marks only "yours". */
.path-doc__page { fill: var(--panel); stroke: var(--paper-dim); stroke-width: 1.5; stroke-linejoin: round; }
.path-doc__lines { stroke: var(--paper-dim); stroke-width: 1.2; }
.path-doc:hover .path-doc__page, .path-doc:focus-visible .path-doc__page { fill: var(--paper-dim); }
.path-doc:focus-visible .path-doc__hit { stroke: var(--focus); stroke-width: 2; }
.bill-basis { font-family: var(--mono); font-size: 13px; color: var(--paper-dim); margin: 12px 0 4px; overflow-wrap: anywhere; }
.bill-latest { margin: 4px 0; color: var(--paper-dim); font-size: 14px; }
.bill-define { color: var(--paper-mute); font-size: 14px; margin: 6px 0 10px; }
.bill-note { color: var(--paper-dim); font-size: 14px; margin: 10px 0 4px; }
.bill-source { margin: 4px 0; font-size: 13px; }

/* ── What the bill does ────────────────────────────────────────────────── */
.bill-summary-heading { font-weight: 600; margin: 14px 0 4px; overflow-wrap: anywhere; }
.bill-summary-text { margin: 8px 0; line-height: 1.55; overflow-wrap: anywhere; }
.bill-summary-list { margin: 6px 0 8px; padding-left: 20px; line-height: 1.55; }
.bill-summary-list li { margin: 4px 0; overflow-wrap: anywhere; }
/* A long summary is folded: the lines past the first part stay in the page and are only hidden. */
#bill-summary-body[data-folded="true"] [data-fold] { display: none; }
.bill-summary-foot { padding: 0 18px 16px; }
.bill-summary-foot[hidden] { display: none; }
.bill-summary-foot .bill-expand { margin-top: 0; }
.bill-source a, .bill-row a, .bill-people a, .bill-card a { color: var(--gold); overflow-wrap: anywhere; }

/* ── Who introduced it: a card ─────────────────────────────────────────── */
.bill-people { list-style: none; margin: 0; padding: 0; }
.bill-sponsor-cards { display: grid; gap: 10px; padding: 6px 0 2px; }
.bill-card { display: flex; gap: 14px; align-items: center; }
.bill-face { position: relative; flex: none; display: grid; place-items: center; width: 64px; height: 64px; border-radius: 50%; overflow: hidden; background: var(--panel-2); border: 1px solid var(--line-2); }
.bill-face__initials { font: 800 20px var(--sans); color: var(--paper-dim); letter-spacing: .02em; }
.bill-face__img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 50% 18%; }
.bill-card__body { min-width: 0; }
.bill-card__name { margin: 0; font-weight: 700; font-size: 18px; }
.bill-card__meta { margin: 2px 0 0; color: var(--paper-dim); font-size: 14px; }
.bill-card__when { margin: 2px 0 0; color: var(--paper-mute); font-family: var(--mono); font-size: 12px; }

/* ── Dot pictures (votes, cosponsors) ──────────────────────────────────── */
.viz-glyph { flex: none; vertical-align: -1px; }
.viz-glyph.dem, .viz-dot.dem .viz-dot__mark { fill: var(--dem-fill); }
.viz-glyph.rep, .viz-dot.rep .viz-dot__mark { fill: var(--rep-fill); }
.viz-glyph.ind, .viz-dot.ind .viz-dot__mark { fill: var(--ind-fill); }
.viz-glyph.oth, .viz-dot.oth .viz-dot__mark { fill: var(--oth-fill); }
.viz-dot.anon { cursor: default; }
.viz-dot.anon .viz-dot__mark { fill: var(--anon-fill); }
/* Yes solid, No hatched, Present dotted, Did not vote an outline: the member page's language. The
 * hatch and the dots are patterns bill.js names on each mark; the outline is the mark's own colour. */
.bill-defs { position: absolute; width: 0; height: 0; overflow: hidden; }
.bill-pat.dem { fill: var(--dem-fill); }
.bill-pat.rep { fill: var(--rep-fill); }
.bill-pat.ind { fill: var(--ind-fill); }
.bill-pat.oth { fill: var(--oth-fill); }
.bill-pat.anon { fill: var(--anon-fill); }
.bill-pat.ink { fill: var(--paper-dim); }
.viz-dot.v-no .viz-dot__mark, .viz-dot.v-present .viz-dot__mark { stroke-width: 1; }
.viz-dot.v-nv .viz-dot__mark { fill: transparent; stroke-width: 1.4; }
.viz-dot.dem.v-no .viz-dot__mark, .viz-dot.dem.v-present .viz-dot__mark, .viz-dot.dem.v-nv .viz-dot__mark { stroke: var(--dem-fill); }
.viz-dot.rep.v-no .viz-dot__mark, .viz-dot.rep.v-present .viz-dot__mark, .viz-dot.rep.v-nv .viz-dot__mark { stroke: var(--rep-fill); }
.viz-dot.ind.v-no .viz-dot__mark, .viz-dot.ind.v-present .viz-dot__mark, .viz-dot.ind.v-nv .viz-dot__mark { stroke: var(--ind-fill); }
.viz-dot.oth.v-no .viz-dot__mark, .viz-dot.oth.v-present .viz-dot__mark, .viz-dot.oth.v-nv .viz-dot__mark { stroke: var(--oth-fill); }
.viz-dot.anon.v-no .viz-dot__mark, .viz-dot.anon.v-present .viz-dot__mark, .viz-dot.anon.v-nv .viz-dot__mark { stroke: var(--anon-fill); }
.viz-dots { display: block; max-width: none; }
.viz-dots__label { font: 700 13px var(--sans); fill: var(--paper); }
/* A vote's caption: the count and answer bold, the parties after it lighter. */
.viz-dots__label-rest { font-weight: 500; fill: var(--paper-dim); }
.viz-dot { cursor: pointer; outline: none; }
.viz-dot__hit { fill: transparent; }
.viz-dot__mark { stroke: transparent; stroke-width: 2; }
/* Yours: the one place gold is used, a ring round the mark. */
.viz-dot.is-mine .viz-dot__mark, .viz-glyph.is-mine path, .viz-glyph.is-mine circle, .viz-glyph.is-mine rect { stroke: var(--gold); stroke-width: 1.8; }
.viz-dot:hover .viz-dot__mark, .viz-dot.is-at .viz-dot__mark { stroke: var(--paper); }
.viz-dot:focus-visible .viz-dot__hit { stroke: var(--focus); stroke-width: 2; }
.viz-dot:focus-visible .viz-dot__mark { stroke: var(--paper); }
/* The ring for "yours" and the pointer's outline win over an answer's outline. */
.bill-shell .viz-dot.is-mine .viz-dot__mark { stroke: var(--gold); stroke-width: 1.8; }
.bill-shell .viz-dot:hover .viz-dot__mark, .bill-shell .viz-dot.is-at .viz-dot__mark, .bill-shell .viz-dot:focus-visible .viz-dot__mark { stroke: var(--paper); }
.dot-tip { position: absolute; z-index: 4; display: grid; gap: 1px; max-width: 260px; padding: 7px 10px 8px; background: var(--paper); color: var(--ink); border-radius: 5px; font-size: 13px; line-height: 1.35; pointer-events: none; box-shadow: 0 10px 26px -10px rgba(0,0,0,.9); white-space: nowrap; }
.dot-tip b { font-size: 14px; }
.bill-readout { margin: 8px 0 0; min-height: 24px; font-size: 14px; color: var(--paper-dim); }
.bill-readout b { color: var(--paper); }
.bill-readout__go { color: var(--paper); text-decoration: underline; text-underline-offset: 3px; white-space: nowrap; }

/* ── Votes ─────────────────────────────────────────────────────────────── */
.bill-mine { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; margin: 6px 0 4px; padding: 12px 14px; background: var(--ink-2); border: 1px solid var(--line-2); border-radius: 6px; }
.bill-mine__label { font-weight: 700; font-size: 14px; }
.bill-select { font: 500 14px var(--sans); color: var(--paper); background: var(--panel); border: 1px solid var(--line-2); border-radius: 4px; padding: 6px 8px; max-width: 100%; }
.bill-mine__list { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 14px; flex: 1 1 260px; min-width: 0; font-size: 14px; }
.bill-mine__hint, .bill-mine__cos { color: var(--paper-dim); }
.bill-mine__cos { flex-basis: 100%; font-size: 13px; }
.bill-mine__item { display: inline-flex; align-items: center; gap: 4px; color: var(--paper); }
.bill-mine__item:hover .bill-mine__name { text-decoration: underline; }
.bill-mine__pos { margin-left: 4px; font-family: var(--mono); font-size: 12px; text-transform: uppercase; color: var(--paper-dim); border: 1px solid var(--line-2); border-radius: 3px; padding: 0 5px; }
.bill-vote__note { margin: 8px 0 0; font-size: 14px; color: var(--paper-dim); }
.bill-vote__pic { margin-top: 8px; }
.bill-vote > .bill-astable { margin-top: 6px; }
/* The names button under a vote is a slim one: 28 px tall, still a full-width tap target on a phone. */
.bill-vote > .bill-expand { margin-top: 6px; padding: 6px 12px; }
.bill-vote.is-deciding .bill-row__head { font-family: var(--serif); font-size: 20px; line-height: 1.3; font-weight: 600; }
.bill-vote__tie { color: var(--paper); }
.bill-vote__hint { color: var(--paper-mute); font-size: 13px; }
/* The key: one colour chip per party. */
.bill-vote-key { margin: 10px 0 2px; font-size: 13px; color: var(--paper-dim); }
.bill-vote-key__fills { display: flex; flex-wrap: wrap; gap: 4px 14px; margin: 0; }
.bill-vote-key__note { margin: 3px 0 0; font-size: 12px; color: var(--paper-mute); }
.bill-vote-key__item { display: inline-flex; align-items: center; gap: 5px; white-space: nowrap; }
.bill-vote-key__chip { flex: none; }
.bill-vote-key__chip.dem > * { fill: var(--dem-fill); }
.bill-vote-key__chip.rep > * { fill: var(--rep-fill); }
.bill-vote-key__chip.ind > * { fill: var(--ind-fill); }
.bill-vote-key__chip.oth > * { fill: var(--oth-fill); }

/* The other roll calls: one row each, opened in place. */
.bill-votes-other { margin: 16px 0 0; padding-top: 14px; border-top: 1px solid var(--line-2); }
.bill-votes-other__title { margin: 0; font-size: 16px; font-weight: 700; }
.bill-votes-other__note { margin: 2px 0 6px; font-size: 13px; color: var(--paper-mute); }
.bill-roll { border-bottom: 1px solid var(--line); }
.bill-roll__sum { display: grid; grid-template-columns: 14px 10.5em minmax(0, 1fr) auto 140px 8.5em; grid-template-areas: "mk when q res bar n";
  align-items: center; gap: 4px 14px; padding: 10px 0; cursor: pointer; list-style: none; font-size: 14px; }
.bill-roll__sum--bare { grid-template-areas: "mk when res res bar n"; }
.bill-roll__sum::-webkit-details-marker { display: none; }
.bill-roll__sum::before { content: ""; grid-area: mk; justify-self: center; width: 6px; height: 6px; border-right: 2px solid var(--paper-mute); border-bottom: 2px solid var(--paper-mute); transform: rotate(-45deg); }
.bill-roll[open] > .bill-roll__sum::before { transform: rotate(45deg); }
.bill-roll__sum:hover .bill-roll__q { color: var(--paper); text-decoration: underline; text-decoration-color: var(--line-2); text-underline-offset: 3px; }
.bill-roll__when { grid-area: when; font-size: 12px; color: var(--paper-mute); white-space: nowrap; }
/* A row's line is at most two lines (a long Senate description); the opened row has it whole. */
.bill-roll__q { grid-area: q; font-size: 15px; color: var(--paper); min-width: 0; overflow-wrap: anywhere; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; line-clamp: 2; overflow: hidden; }
.bill-roll__res { grid-area: res; color: var(--paper-dim); white-space: nowrap; }
.bill-roll__bar { grid-area: bar; display: block; min-width: 0; }
.bill-roll__n { grid-area: n; font-size: 12px; color: var(--paper-dim); white-space: nowrap; text-align: right; font-variant-numeric: tabular-nums; }
.bill-roll__body { padding: 0 0 14px 28px; }
.bill-roll__body > .bill-row__line:first-child { margin-top: 0; }
.bill-minibar { display: block; width: 100%; height: 10px; overflow: visible; }
.bill-minibar__seg { fill: var(--paper-dim); stroke: var(--paper-dim); stroke-width: 1; }
.bill-minibar__seg.is-nv { fill: transparent; stroke: var(--paper-mute); stroke-dasharray: 2 1.5; }
.bill-minibar__gap { fill: var(--panel); }
.bill-minibar__mid { fill: var(--paper); opacity: .55; }
/* With the party split on file, each slice takes its party's colour: solid Yes, hatched No (the
 * pattern bill.js names on it), dotted Present, a dashed outline for Did not vote. */
.bill-minibar__seg.dem { stroke: var(--dem-fill); }
.bill-minibar__seg.rep { stroke: var(--rep-fill); }
.bill-minibar__seg.ind { stroke: var(--ind-fill); }
.bill-minibar__seg.oth { stroke: var(--oth-fill); }
.bill-minibar__seg.dem:not(.is-nv) { fill: var(--dem-fill); }
.bill-minibar__seg.rep:not(.is-nv) { fill: var(--rep-fill); }
.bill-minibar__seg.ind:not(.is-nv) { fill: var(--ind-fill); }
.bill-minibar__seg.oth:not(.is-nv) { fill: var(--oth-fill); }
/* A mark counted before the names arrive opens nothing. */
.viz-dot.is-tally { cursor: default; }
.bill-row { padding: 12px 0; border-bottom: 1px solid var(--line); }
.bill-row:last-child { border-bottom: 0; }
.bill-row__head { font-weight: 600; margin: 0 0 4px; }
.bill-row__line { margin: 2px 0; color: var(--paper-dim); font-size: 14px; }
.bill-row__line.mono { font-size: 12px; }
.bill-expand { margin-top: 10px; }
.bill-members { list-style: none; margin: 8px 0 0; padding: 0; }
.bill-members li { display: flex; flex-wrap: wrap; gap: 4px 10px; padding: 6px 0; border-top: 1px solid var(--line); font-size: 14px; }
.bill-members .bill-pos { margin-left: auto; font-family: var(--mono); font-size: 12px; text-transform: uppercase; color: var(--paper-dim); }
.bill-people .bill-person-meta, .bill-members .bill-person-meta { color: var(--paper-mute); font-size: 13px; font-family: var(--mono); margin-left: 6px; }
/* At 900 px and wider an opened member list (up to 432 names) runs in columns, down then across in
   the list's own order (Yes, then No, ...), so screen readers and find-in-page read it as before.
   Phones keep one column. */
@media (min-width: 900px) {
  .bill-members { columns: 3 17em; column-gap: 32px; }
  /* A row that does not fit its column wraps, as on phones: the answer moves to its own line rather than
     sharing one with the party and state (which painted over "Did not vote" at 1100 px and wider). */
  .bill-members li { break-inside: avoid; align-items: baseline; }
  .bill-members li > :first-child, .bill-members .bill-pos { flex: none; }
}

/* ── What members said: a month strip, then the list ───────────────────── */
.said-base { stroke: var(--line-2); stroke-width: 1; }
.said-bar { cursor: pointer; outline: none; }
.said-bar__hit { fill: transparent; }
.said-bar__mark { fill: var(--paper-dim); }
.said-bar:hover .said-bar__mark, .said-bar.is-on .said-bar__mark { fill: var(--paper); }
.said-bar:focus-visible .said-bar__hit { stroke: var(--focus); stroke-width: 2; }
.said-count { font: 700 12px var(--sans); fill: var(--paper); }
.said-tick { fill: var(--line-2); }
.said-month { font: 400 12px var(--mono); fill: var(--paper-mute); }
/* How the text changed: one short row per version. */
.bill-version { display: grid; grid-template-columns: 7.5rem minmax(0, 1fr) auto; grid-template-areas: "date name link" ". what what"; align-items: baseline; gap: 0 14px; padding: 9px 0; }
.bill-version__date { grid-area: date; margin: 0; font-size: 12px; color: var(--paper-mute); }
.bill-version .bill-version__name { grid-area: name; margin: 0; }
.bill-version__link { grid-area: link; margin: 0; font-size: 12px; white-space: nowrap; }
.bill-version .bill-version__what { grid-area: what; margin: 2px 0 0; font-size: 13px; }
.bill-said__filter { margin: 6px 0 2px; font-size: 14px; color: var(--paper-dim); }
.bill-said .bill-row__head a { color: var(--paper); }
.bill-said .bill-row__head a:hover { text-decoration: underline; }

/* ── Share and notes ───────────────────────────────────────────────────── */
.bill-share { display: grid; gap: 10px; padding-top: 14px; }
.bill-share-text { margin: 0; font-family: var(--mono); font-size: 13px; line-height: 1.5; white-space: pre-wrap; overflow-wrap: anywhere; color: var(--paper-dim); }
.bill-share-row { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.bill-share-status { color: var(--paper-dim); font-size: 13px; }
.bill-howto { margin-top: 8px; }
.bill-disclaimers { margin: 8px 0 0; padding-left: 18px; color: var(--paper-dim); font-size: 14px; }
.bill-disclaimers li { margin: 6px 0; }
/* The sections with nothing on file are not drawn as cards; bill.js names them in this one line. */
.bill-missing { margin: 18px 0 0; padding: 0 2px; font-size: 14px; line-height: 1.5; color: var(--paper-dim); }
.bill-missing a { color: var(--gold); white-space: nowrap; }
.bill-missing a:hover { text-decoration: underline; }

@media (max-width: 560px) {
  /* On a phone the path comes straight after the sentence; the four counts follow it. */
  #bill-content { display: flex; flex-direction: column; }
  .bill-lede { display: contents; }
  #bill-glance { order: 1; margin-top: 14px; }
  #bill-content > section:not(#bill-stage-section), #bill-missing { order: 3; }
  /* How the deciding votes went comes before the folded summary and the rest. */
  #bill-content > section#bill-votes-section { order: 2; }
  .bill-identifier { font-size: 28px; }
  .bill-title { font-size: 16px; }
  .bill-lede__text { font-size: 18px; }
  .bill-glance, .bill-glance:has(> :only-child) { grid-template-columns: 1fr 1fr; gap: 8px; }
  .bill-glance__item { padding: 10px 12px; }
  .bill-glance__n { font-size: 24px; }
  .bill-stage-label { font-size: 22px; }
  .bill-shell .panel__body { padding: 8px 14px 14px; }
  .bill-shell .panel__head { padding: 11px 14px; }
  /* A member row on a phone is two lines: the name on the first with the answer at its right end, and the
     party and state under the name. The answer's column is as wide as that row's own answer ("Yes" needs
     far less room than "Did not vote"), so a long name stays on one line. Tight (4 px above and below, a
     16 px second line): 45 px a row. The name's link is 20 px of text; its ::after stretches its tap area
     over the whole row, 45 px, under the answer, which stays on top: readable, selectable, and not part
     of the link or its name. */
  .bill-members li:not(.placeholder):not(.bill-skel--member) { position: relative; display: grid; grid-template-columns: minmax(0, 1fr) auto;
    gap: 0 14px; align-items: baseline; padding: 4px 0; line-height: 20px; }
  .bill-members li > :first-child { grid-area: 1 / 1; min-width: 0; overflow-wrap: anywhere; }
  .bill-members li > a:first-child::after { content: ""; position: absolute; inset: 0; }
  .bill-members .bill-pos { grid-area: 1 / 2; position: relative; z-index: 1; margin-left: 0; line-height: 20px; }
  .bill-members .bill-person-meta { grid-area: 2 / 1 / 3 / 3; margin-left: 0; line-height: 16px; }
  .bill-share .btn { flex: 1 1 auto; justify-content: center; }
  .bill-face { width: 56px; height: 56px; }
  /* The four-column vote table fits a phone with whole words: the state is its two-letter code, as in the
     member list (a screen reader still hears the name), and at 359 px and narrower the type is 12 px. */
  .bill-table th, .bill-table td { padding-right: 6px; }
  .bill-vote-table .bill-table { font-size: 13px; }
  .bill-st-name { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; border: 0; }
  .bill-st-code { display: inline; }
  .bill-summary-foot { padding: 0 14px 14px; }
  .bill-vote.is-deciding .bill-row__head { font-size: 18px; }
  .bill-roll__body { padding-left: 24px; }
  .bill-version { grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "date link" "name name" "what what"; padding: 8px 0; }
}
@media (max-width: 359px) {
  .bill-vote-table .bill-table { font-size: 12px; }
  .bill-vote-table .bill-table th, .bill-vote-table .bill-table td { padding-right: 4px; }
}
@media (max-width: 860px) {
  /* A narrow column: the date and the numbers on top, the question across the row (a Senate motion's
     description is up to 90 characters), then the result, then the bar. */
  .bill-roll__sum { grid-template-columns: 14px minmax(0, 1fr) auto; grid-template-areas: "mk when n" "mk q q" ". res res" ". bar bar"; gap: 3px 10px; }
  /* A bare "On the Motion" row leads with its result: two lines, not three. */
  .bill-roll__sum--bare { grid-template-areas: "mk when n" "mk res res" ". bar bar"; }
  .bill-roll__bar { margin-top: 3px; }
  /* The date gives way to the numbers: at 320 px a House count of three digits a side keeps its line. */
  .bill-roll__when { min-width: 0; white-space: normal; }
}

@media (prefers-reduced-motion: reduce) {
  .bill-shell * { transition: none !important; animation: none !important; scroll-behavior: auto !important; }
  .bill-skel { background: var(--line); }
}

/* Light, when the reader's system asks for it. The colour tokens come from the shared light theme
 * in record.css (every page uses the same ones); only this page's mark fills and tip shadow are set here. */
@media (prefers-color-scheme: light) {
  body:has(main.bill-shell) .bill-shell { --dem-fill: #2f6bc0; --rep-fill: #b83c38; --ind-fill: #687080; --oth-fill: #806d36; --anon-fill: #6b7482; }
  body:has(main.bill-shell) .dot-tip { box-shadow: 0 10px 26px -12px rgba(0,0,0,.45); }
}
.bill-said__who { margin: 8px 0 4px; font-size: 15px; line-height: 1.7; color: var(--paper-dim); }
.bill-said__who a { color: var(--paper); text-decoration: underline; text-decoration-color: var(--line-2); text-underline-offset: 3px; }
.bill-said__who a:hover { text-decoration-color: var(--paper); }
.bill-said__more { margin-left: 4px; }
.bill-mine__tally { display: inline-flex; flex-wrap: wrap; gap: 4px 14px; font-size: 15px; color: var(--paper-dim); }
.bill-mine__count b { color: var(--paper); font-size: 18px; font-weight: 800; font-variant-numeric: tabular-nums; }
.bill-mine__all { flex-basis: 100%; }
.bill-mine__all > summary { cursor: pointer; font-size: 14px; color: var(--paper-dim); }
.bill-mine__names { display: flex; flex-wrap: wrap; gap: 6px 14px; margin-top: 8px; }
