/* T1 Terminal, printed.
   On screen the page is a window with a prompt pinned to its bottom edge.
   On paper it is a transcript: the whole session, every project, the about
   text and both links, on white, with the prompt and the shortcuts gone.

   The live scrollback only ever holds what was typed in this session, so
   print swaps it for the record the script reads its content from. Both
   carry the same text; the record carries all of it. */

@page {
  margin: 16mm 18mm;
}

html,
body {
  background: #fff !important;
}

body {
  /* a window-sized flex column means nothing on paper */
  display: block !important;
  min-height: 0 !important;
  margin: 0;
  padding: 0;
  max-width: none;
  color: #14140F;
  font-size: 10.5pt;
  line-height: 1.5;
}

.screen {
  display: block;
  max-width: none;
}

/* screen furniture: the prompt, its hairline, the shortcut buttons */
.tail {
  display: none !important;
}

/* the full record, and nothing generated from it */
.scrollback > :not(#record) {
  display: none !important;
}
#record,
#record[hidden] {
  display: block !important;
}

/* "JavaScript is off" is only worth printing when it is true */
html.js .banner-note {
  display: none;
}

/* grey is the first thing a laser printer loses; keep the hierarchy, drop the
   risk. 8.94:1 on white instead of 5.39:1. */
:root {
  --dim: #4A4A42;
}

/* a command and its answer should not be split across a page break */
.echo {
  break-after: avoid;
  page-break-after: avoid;
}
.banner,
.proj {
  break-inside: avoid;
  page-break-inside: avoid;
}

.prose p {
  orphans: 2;
  widows: 2;
}

/* the prompt rule and the focus ring are states, not content */
.prompt::after {
  display: none;
}

a {
  color: #14140F;
  text-decoration: underline;
  text-decoration-color: #4A4A42;
}
