.results { list-style: none; margin: 0; padding: 0; }
.result { background: var(--colour-panel); margin: 0 0 var(--space-3); padding: var(--space-3) var(--space-4); }
.lines { list-style: none; margin: var(--space-2) 0 0; padding: 0; }
.lines li { padding: var(--space-1) var(--space-1) var(--space-1) var(--space-line-start); border-top: var(--size-hairline) solid var(--colour-page); }
/* Yea and Nay: each at least 4.5:1 on white; the word always shows too. */
.vote-yea { color: var(--colour-positive); font-weight: 500; }
.vote-nay { color: var(--colour-negative); font-weight: 500; }
.value-neutral { color: var(--colour-neutral); }
.outcome-text { color: var(--colour-neutral); font-size: var(--text-muted); }
.bar-yea { fill: var(--colour-positive); }
.bar-nay { fill: var(--colour-negative); }
/* The bar sits under the outcome and tally it restates, as wide as that text. */
.tally { display: inline-grid; vertical-align: top; }
.vote-bar { width: 100%; height: var(--size-vote-bar-height); margin: 0; }
/* "Vote:" and its word are one fact: they wrap together or not at all. */
.vote-pair { white-space: nowrap; }
.flag { font-size: var(--text-flag); border: var(--size-hairline) solid var(--colour-band); padding: var(--space-em-tight) var(--space-em-half); border-radius: var(--radius-pill); }
.sources, .bill-summary { float: inline-end; margin: var(--space-gutter); }
.sources { display: flex; gap: var(--space-2); }
/* The permalink sits on the summary row but outside <summary>, so the row holds one control inside another's box, not nested. */
.result { position: relative; }
.permalink { position: absolute; inset-inline-end: var(--space-4); top: var(--space-3); text-decoration: none; }
.permalink[data-copied]::after { content: " Copied"; font-size: var(--text-other-source); }
summary { cursor: pointer; }
/* Room for the permalink's offset, the glyph (about 1.5rem) and a gutter, so header text never runs under it. */
.result summary { padding-inline-end: calc(var(--space-4) + var(--space-6) + var(--space-2)); }
.more { margin: var(--space-2) 0 0; }
.description { margin: var(--space-2) 0 0; color: var(--colour-neutral); overflow: hidden; }

nav[aria-label="Pages"] { display: flex; gap: var(--space-4); padding: var(--space-4) 0; }

/* The filter panel: a white sidebar on desktop, above the results on a narrow screen. */
.search { display: flex; gap: var(--space-4); align-items: flex-start; }
.filter-box { background: var(--colour-panel); flex: 0 0 var(--size-filter-box); }
.filters { padding: var(--space-4); }
.filter-box summary { padding: var(--space-3) var(--space-4); font-weight: 700; }
.found { flex: 1 1 auto; min-width: 0; }
/* The person's record above the results: the Service Record. */
.service ol { list-style: none; margin: 0; padding: 0; }
.service { margin-bottom: var(--space-gutter); }
.control { margin: 0 0 var(--space-3); display: flex; flex-direction: column; }
.control select, .control input { width: 100%; }
.control select, .control input[type="text"], .filters button {
  font: inherit;
  min-height: var(--size-control-height);
  padding: var(--space-em-half) var(--space-em-wide);
  border: var(--size-hairline) solid var(--colour-control-border);
  border-radius: var(--radius-control);
  box-sizing: border-box;
}
.filters button { background: var(--colour-band); color: var(--colour-white); font-weight: 700; width: 100%; }
select:focus-visible, input:focus-visible, button:focus-visible, summary:focus-visible {
  outline: var(--size-focus-ring) solid var(--colour-focus);
  outline-offset: var(--size-focus-offset);
}

/* Desktop shows the form with no "Filters" bar. A browser without ::details-content keeps the bar, which still works:
   the summary hides only where the rule that shows the content is understood. */
@media (min-width: 641px) {
  @supports selector(::details-content) {
    .filter-box summary { display: none; }
    .filter-box details::details-content { content-visibility: visible; display: block; }
  }
}

.rates { display: grid; grid-template-columns: 1fr; gap: var(--space-3); margin: 0; }
.rates > div { background: var(--colour-panel); padding: var(--space-3) var(--space-4); }
.middle-half-note { color: var(--colour-neutral); font-size: var(--text-xsmall); }
.rates dt { color: var(--colour-neutral); font-weight: var(--weight-strong); font-size: var(--text-muted); }
.rates dd { margin: var(--space-1) 0 0; }
.rates .of, .rates .range { color: var(--colour-neutral); }
.rates .range { display: block; font-size: var(--text-muted); margin-top: var(--space-1); }
@media (min-width: 641px) {
  .rates { grid-template-columns: repeat(3, 1fr); }
}
.service summary h3 { display: inline; margin: 0; }
/* The asterisk on a vote line that could not be checked against another source; it reuses the ⓘ's note box. */
.info-button.unchecked-mark { width: auto; height: auto; color: var(--colour-neutral); border: 0; background: transparent; font: inherit; font-weight: var(--weight-strong); cursor: help; }
/* The dagger on a data-service outcome we computed or that the record states against its tally; it reuses the ⓘ's note box. */
.info-button.dagger-mark { width: auto; height: auto; color: var(--colour-neutral); border: 0; background: transparent; font: inherit; font-weight: var(--weight-strong); cursor: help; }
/* The word Unknown on an outcome we could not read; it is its own note's trigger and reuses the ⓘ's note box. */
.info-button.unknown-word { width: auto; height: auto; padding: 0; color: inherit; border: 0; background: transparent; font: inherit; text-decoration: underline dotted; cursor: help; }
/* The warning sign on a line whose two records disagree; it keeps its emoji colour and reuses the ⓘ's note box. */
.info-button.warning-sign { width: auto; height: auto; border: 0; background: transparent; font: inherit; cursor: help; }
/* The pencil on a record changed by hand; it reuses the ⓘ's note box like the dotted circle. */
.info-button.corrected-mark { width: auto; height: auto; color: var(--colour-neutral); border: 0; background: transparent; font: inherit; cursor: help; }
@media (max-width: 640px) {
  .search { flex-direction: column; }
  .filter-box { flex-basis: auto; width: 100%; }
}
