/* What a printed or exported report looks like (decision B136).
   Kept apart from app.css because it is the only stylesheet WeasyPrint is given
   as a document rather than as a media query: the PDF is a page with margins, a
   running header and a page count, none of which a screen has. */
@page {
  size: A4;
  margin: 18mm 14mm 16mm;
  @bottom-right { content: counter(page) " of " counter(pages); font-size: 8pt; color: #666; }
  @bottom-left { content: string(document-title); font-size: 8pt; color: #666; }
}
/* Every page names the document it belongs to, from its own heading (B174). */
h1 { string-set: document-title content(); }
.appendix { break-before: page; }
.calendar-card { break-inside: avoid; }
.calendar-card .calendar-body { display: block !important; }
.calendar-card .month-figures { margin-top: 3mm; }
.review-charts { display: grid; grid-template-columns: 1fr 1fr; gap: 4mm; }
.review-charts > div { break-inside: avoid; }
.lessons { list-style: none; padding: 0; margin: 0; }
.lessons li p, .lesson-text { white-space: pre-line; }
.lessons li { break-inside: avoid; padding: 1.5mm 0; border-bottom: 0.3pt solid #ccc; }
body { background: #fff; color: #111; font-size: 9.5pt; }
main, main.with-rail { margin: 0; padding: 0; max-width: none; }
.shell, .rail, .tabs, .filters, .shortcuts, .flashes, .noprint, form, .back, .restored,
.actions { display: none !important; }
/* A browser never draws a closed dialog; WeasyPrint does, so the keyboard help
   came out as the last page of every PDF (decision B246). */
dialog:not([open]), dialog.shortcut-help { display: none !important; }
/* A printed report is its figures and tables. The notes on how they were worked
   out stay on the screen behind their info marks, and were printed in full at
   the end of every PDF (decision B248). A warning about the figures is `.warn`
   and still prints. */
p.note, div.note, details.note-tip, .info-mark { display: none !important; }
main.with-rail { margin-left: 0; }
.card, .cards .card, .kpi { box-shadow: none; }
.report-branding { color: #000; }
h1 { font-size: 16pt; margin: 0 0 2mm; }
h2 { font-size: 11pt; margin: 6mm 0 2mm; page-break-after: avoid; }
.report-branding { font-size: 9pt; color: #444; margin: 0 0 1mm; }
.scope { color: #444; margin: 0 0 3mm; }
.printonly { display: block; }
section { page-break-inside: auto; }
table { width: 100%; border-collapse: collapse; box-shadow: none; page-break-inside: auto; }
thead { display: table-header-group; }
tr { page-break-inside: avoid; }
th, td { border-bottom: 0.3pt solid #ccc; padding: 1.2mm 2mm; text-align: left; }
th.num, td.num { text-align: right; }
.kpis { display: flex; flex-wrap: wrap; gap: 3mm; margin: 0 0 3mm; }
.kpi { border: 0.4pt solid #bbb; border-radius: 1.5mm; padding: 2mm 3mm; min-width: 34mm; }
.kpi .label { display: block; font-size: 7pt; text-transform: uppercase; letter-spacing: .08em;
              color: #555; }
.kpi .figure { display: block; font-size: 12pt; font-weight: 600; }
.daychart { list-style: none; padding: 0; margin: 0 0 3mm; }
.daychart li { display: grid; grid-template-columns: 32mm 1fr 28mm; gap: 3mm;
               align-items: center; padding: 0.6mm 0; }
.daychart .track { position: relative; display: block; height: 3mm; background: #eee; }
.daychart .fill { position: absolute; top: 0; bottom: 0; display: block; background: var(--up); }
.daychart .fill.down { background: var(--down); }
.curve { width: 100%; height: 40mm; }
