.tap-page .ft-hero { padding-bottom: 28px; }
.tap-page .tap-reference { padding-top: 0; }
.tap-page .tap-example { padding-top: 3rem; }

.tap-controls {
  display: flex;
  flex-wrap: wrap;
  align-items: end;
  gap: .75rem 1rem;
  padding: 1rem;
  border: 1px solid #ccd5d5;
  border-radius: 12px;
  background: #f3f7f6;
  color: #193131;
}

.tap-controls[hidden], .tap-tables [hidden] { display: none; }
.tap-controls label { display: grid; gap: .35rem; font-weight: 600; }
.tap-controls label:first-child { flex: 1 1 12rem; }
.tap-controls input, .tap-controls select {
  min-height: 44px;
  min-width: 0;
  padding: .45rem .7rem;
  border: 1px solid #6c8582;
  border-radius: 6px;
  background: #fff;
  color: inherit;
  font: inherit;
}

.tap-controls :focus-visible { outline: 2px solid #08706a; outline-offset: 2px; }
.tap-controls button { min-height: 44px; cursor: pointer; }
.tap-controls [role="status"] { flex-basis: 100%; margin: 0; }
.tap-tables { display: grid; gap: 1.5rem; align-items: start; }
.tap-tables h3 { margin: 1.25rem 0 .5rem; }
.tap-table { width: 100%; border-collapse: collapse; text-align: left; font-variant-numeric: tabular-nums; }
.tap-table th, .tap-table td { padding: .5rem .65rem; border-bottom: 1px solid var(--line); }
.tap-table th[scope="col"] { background: var(--paper-2); }
.tap-table th[scope="row"] { font-weight: 600; white-space: nowrap; }
.tap-sources { margin-top: 1rem; }
.tap-example .button-primary { margin-top: .75rem; }

@media screen and (min-width: 720px) {
  .tap-tables { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .tap-tables:has(> section[hidden]) { grid-template-columns: minmax(0, 1fr); }
}

@media print {
  @page { margin: 12mm; }

  .tap-page, .tap-page main { margin: 0; padding: 0; overflow: visible; background: #fff; color: #000; }
  .tap-page > :not(main), .tap-page main > :not(.ft-hero, .tap-reference), .tap-controls { display: none !important; }
  .tap-page .ft-hero, .tap-page .tap-reference { margin: 0; padding: 0; width: auto; }
  .tap-page .ft-hero h1 { font-size: 18pt; margin: 0 0 2mm; color: #000; }
  .tap-page .ft-hero__lead, .tap-sources { font-size: 8pt; margin: 0 0 2mm; color: #000; }
  .tap-tables { gap: 5mm; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .tap-tables section[hidden] { display: block; }
  .tap-tables tr[hidden] { display: table-row; }
  .tap-tables h3 { font-size: 10pt; margin: 2mm 0 1mm; color: #000; }
  .tap-table { border-collapse: collapse; font-size: 8pt; }
  .tap-table thead { display: table-header-group; }
  .tap-table tr { break-inside: avoid; }
  .tap-table th, .tap-table td { padding: 1mm 1.5mm; border: 1px solid #aaa; background: #fff; color: #000; }
  .tap-table th[scope="col"] { background: #fff; }
  .tap-sources { margin-top: 3mm; }
}
