/* --------------------------------------------------------------------------- Filter bar --- */
/*
 * A plain GET form. No client state: the page a reader is looking at is the page they can paste,
 * which is the whole point of an artifact meant to be cited.
 */
.filters {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: var(--s3) var(--s4);
  margin: var(--s4) 0;
  padding: var(--s3) 0;
  border-top: var(--hair) solid var(--rule);
  border-bottom: var(--hair) solid var(--rule);
}

.filters label {
  display: flex;
  flex-direction: column;
  gap: var(--s1);
}

.filters select,
.filters input[type="checkbox"] {
  font-family: var(--font-mono);
  font-size: 13px;
  color: var(--fg);
  background: var(--card);
  border: var(--hair) solid var(--rule);
  border-radius: var(--r);
  padding: 6px 8px;
}

.filters input[type="checkbox"] { padding: 0; }

/* The permalink rendered AS TEXT, so a screenshot carries its own citation. */
.as-of__perma { color: var(--fg-3); }

/* ------------------------------------------------------------------- Narrow transpose --- */
/*
 * P6: narrow carries the SAME data as wide. No truncated feature set, no "see full table on
 * desktop". The row transposes into stacked label/value pairs and every field survives.
 *
 * The labels come from the header row via `data-k` on each cell, so there is one markup and the
 * two layouts cannot drift apart. A horizontally scrolling table on a phone hides the comparison,
 * which on this site is the entire content.
 */
@media (max-width: 720px) {
  .rows thead {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip-path: inset(50%);
  }

  .rows tr {
    display: block;
    border-top: var(--hair) solid var(--rule);
    padding-block: var(--s3);
  }

  .rows td,
  .rows th {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: var(--s3);
    align-items: baseline;
    min-height: var(--row-h);
    border: 0;
    padding-inline: 0;
    text-align: left;
  }

  .rows td::before,
  .rows th[data-k]::before {
    content: attr(data-k);
    font: 500 10px/1.2 var(--font-mono);
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--fg-3);
  }

  .rows td { justify-items: start; }
  .rows__num { text-align: left; }

  .filters { flex-direction: column; align-items: stretch; }
}
