/* ==========================================================================
   ClaimLedge — Print & PDF Stylesheet
   Loaded on all pages with media="print". Owns the generated report sheet
   and browser-print behavior. Palette is hardcoded intentionally:
   print context must render identically regardless of screen theme.
   ========================================================================== */

/* ---- On-screen report preview ---- */
#print-sheet {
  position: fixed; top: 0; left: 0; width: 100%; height: 100%;
  background: #fff; color: #16202E;
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 10.5pt; line-height: 1.55;
  padding: 16mm 15mm; box-sizing: border-box;
  z-index: 9999; overflow: auto;
  -webkit-print-color-adjust: exact; print-color-adjust: exact;
}
#print-sheet * { box-sizing: border-box; -webkit-print-color-adjust: exact; print-color-adjust: exact; }

/* Letterhead */
.print-header {
  display: flex; justify-content: space-between; align-items: flex-end; gap: 24px;
  padding-bottom: 12px; margin-bottom: 0;
  border-bottom: 4px double #1A365D;
}
.print-brand { display: flex; align-items: center; gap: 12px; }
.print-brand img { width: 46px; height: 46px; display: block; }
.print-brand__name { display: block; font-family: 'Newsreader', Georgia, serif; font-size: 16pt; font-weight: 700; color: #122747; line-height: 1.1; letter-spacing: 0.01em; }
.print-brand__tag { display: block; margin-top: 3px; font-size: 7.5pt; font-weight: 600; letter-spacing: 0.14em; text-transform: uppercase; color: #5A6472; }
.print-meta { display: flex; flex-direction: column; align-items: flex-end; gap: 2px; font-size: 8.5pt; color: #5A6472; text-align: right; white-space: nowrap; }
.print-meta__ref { font-family: ui-monospace, 'SF Mono', Menlo, monospace; font-weight: 700; font-size: 8.5pt; letter-spacing: 0.06em; color: #1A365D; }

/* Document title */
.print-doc-title {
  display: flex; justify-content: space-between; align-items: flex-end; gap: 24px; flex-wrap: wrap;
  padding: 20px 0 14px; margin-bottom: 18px;
  border-bottom: 1px solid #D9DDE3;
}
.print-doc-title h1 { margin: 0; font-family: 'Newsreader', Georgia, serif; font-size: 20pt; font-weight: 700; line-height: 1.15; color: #122747; }
.print-sub { margin: 6px 0 0; font-size: 10.5pt; color: #43454C; }

/* Sections */
.print-section { margin: 0 0 22px; }
.print-section h2 {
  margin: 0 0 10px; padding-bottom: 6px;
  font-size: 9pt; font-weight: 700;
  letter-spacing: 0.16em; text-transform: uppercase; color: #1A365D;
  border-bottom: 1px solid #D9DDE3;
}

/* Tables */
.print-table { width: 100%; border-collapse: collapse; font-size: 10pt; }
.print-table th, .print-table td { padding: 7px 10px; text-align: left; vertical-align: top; }
.print-table thead th {
  background: #1A365D; color: #FFFFFF;
  font-size: 7.5pt; font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase;
  padding: 6px 10px; border: 0;
}
.print-table thead th:last-child, .print-table thead th.print-table__num { text-align: right; }
.print-table tbody th { width: 58%; font-weight: 600; color: #16202E; border-bottom: 1px solid #E4E7EC; }
.print-table tbody td { text-align: right; color: #24313F; font-variant-numeric: tabular-nums; border-bottom: 1px solid #E4E7EC; }
.print-table tbody tr:nth-child(even) th, .print-table tbody tr:nth-child(even) td { background: #F6F8FA; }
.print-total th, .print-total td {
  border-top: 2.5px solid #1A365D; border-bottom: 0;
  font-weight: 700; color: #122747; font-size: 10.5pt;
  background: #EDF1F7 !important;
}

/* Primary result banner */
.print-primary {
  background: #1A365D; color: #FFFFFF; text-align: center;
  padding: 18px 16px 16px; margin: 0 0 14px; border-radius: 3px;
}
.print-primary__label { display: block; margin-bottom: 6px; font-size: 8.5pt; font-weight: 600; letter-spacing: 0.18em; text-transform: uppercase; color: #B9C6D8; }
.print-primary__value { display: block; font-family: 'Newsreader', Georgia, serif; font-size: 22pt; font-weight: 700; line-height: 1.1; letter-spacing: 0.01em; }
.print-midpoint { margin: 0 0 4px; font-size: 9.5pt; font-weight: 600; color: #43454C; }
.print-caption { margin: 0 0 12px; font-size: 9pt; font-style: italic; color: #5A6472; }

/* Disclaimer & fine print */
.print-section--fine { margin-top: 26px; }
.print-section--fine h2 { font-size: 8.5pt; }
.print-disclaimer-box {
  border: 1px solid #D9DDE3; border-left: 3px solid #1A365D; background: #F6F8FA;
  padding: 12px 14px; margin: 0 0 10px;
  font-size: 9pt; line-height: 1.55; color: #43454C;
}
.print-fine { margin: 0; font-size: 8pt; line-height: 1.5; color: #6D7078; }

/* Footer */
.print-footer {
  margin-top: 28px; padding-top: 10px;
  border-top: 2px solid #1A365D;
  display: flex; justify-content: space-between; align-items: baseline; gap: 16px; flex-wrap: wrap;
  font-size: 8pt; color: #6D7078;
}
.print-footer__ref { font-family: ui-monospace, 'SF Mono', Menlo, monospace; font-weight: 600; letter-spacing: 0.05em; color: #1A365D; }

/* ---- Browser print ---- */
@media print {
  @page { size: letter; margin: 12mm 13mm 14mm; }
  body { background: #FFFFFF; }
  body > *:not(#print-sheet) { display: none !important; }
  #print-sheet { display: block !important; position: static; width: auto; height: auto; padding: 0; overflow: visible; font-size: 10pt; }
  .print-header, .print-doc-title, .print-section, .print-primary, .print-footer, .print-table tr { break-inside: avoid; page-break-inside: avoid; }
  .print-doc-title { break-after: avoid; page-break-after: avoid; }
  .print-table thead { display: table-header-group; }
  .scroll-progress, .site-header, .site-footer, .ad-slot, .ad-container,
  .nav-toggle, .theme-toggle, .search-open, .whatif, .compare-tray,
  .compare-add, .compare-pill, .wizard-nav, .wizard-progress,
  .callout--related, .tool-grid__toggle-wrap, .state-basis,
  .state-rules-of, .framework-rail, .states-jumplist, .result-next { display: none !important; }
  /* Answer-first summary: keep the text, drop the card chrome so it prints as body copy. */
  .answer-first { background: none; box-shadow: none; border: 0; border-left: 3px solid #1A365D; border-radius: 0; padding: 0 0 0 14px; margin-top: 12px; }
  form.wizarding .btn-row { display: flex !important; }
  .wizard-step[hidden] { display: contents !important; }
}
