/* print.css: pick list and decklist print views (ARCHITECTURE.md 7 step 2,
   INFORMATION-ARCHITECTURE.md 6, 9). Loaded media="print" on every page and
   unscoped on /print/ views, whose body carries class print (render/print.py).

   Two scopes only. body.print for the print views. The page shell's
   landmarks under @media print so a regular page prints without header,
   nav, breadcrumb, status bar, skip link; those are structural selectors on
   the render/page.py shell, not components.css or base.css selectors.
   Colors by token only: --night ink on --cream paper, no raw hex.
   tests/test_team_assets.py greps for all of it. */

@page { margin: 12mm; }

@media print {
  body > a[href="#main"],
  body > header[role="banner"],
  body > div > nav[aria-label="Breadcrumb"],
  body > footer[role="contentinfo"] { display: none; }
}

/* Paper on screen too, so the view reads the same before and after Print. */
body.print {
  background: var(--cream);
  color: var(--night);
  font-family: var(--mono);
  font-size: 11pt;
  line-height: 1.3;
}
body.print #main {
  max-width: none;
  padding: var(--s5) var(--pad-lg);
}

/* Monospace table: static head, ink rules, no zebra, no hover, links as
   text. content-visibility off so every group renders on paper. */
body.print .dt { border: var(--bw) solid var(--night); }
body.print .dt__head {
  position: static;
  background: none;
}
body.print .dt__head [role="columnheader"] {
  color: var(--night);
  border-bottom: var(--bw) solid var(--night);
}
body.print .dt__row > * {
  padding: var(--s1) var(--s2);
  border-bottom: 1px solid var(--night);
}
body.print .dt__group .dt__row:nth-child(even),
body.print .dt__group .dt__row:hover { background: none; }
body.print .dt a {
  color: var(--night);
  text-decoration: none;
}
body.print .dt__group {
  content-visibility: visible;
  contain-intrinsic-height: auto;
}

/* Pick list checkbox column drawn as a box (INFORMATION-ARCHITECTURE.md 6):
   a span with class print-box, or a bare checkbox input. */
body.print .print-box,
body.print input[type="checkbox"] {
  display: inline-block;
  appearance: none;
  width: 1.2em;
  height: 1.2em;
  margin: 0;
  border: var(--bw) solid var(--night);
  vertical-align: middle;
}

/* Borrower, date, and the staff signature line (INFORMATION-ARCHITECTURE.md 6). */
body.print .print-meta {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s5);
  margin-bottom: var(--s4);
}
body.print .print-sig {
  display: inline-block;
  min-width: 32ch;
  border-bottom: var(--bw) solid var(--night);
}

/* StockPip on paper (T14 axe: 18 color-contrast failures on /print/decks/): the ok, warn,
   and muted tokens are for --panel; on --cream every pip state prints as ink. */
body.print .pip,
body.print .pip[data-state="in"],
body.print .pip[data-state="low"],
body.print .pip[data-state="out"] { color: var(--night); }
