/* Print / "Download PDF" layout (Michael, 15 Nov 2026: the PDF must always match
   the app, never an old design). There is no separate PDF template: the PDF is
   the live page, printed with these rules, so every chart and number change in
   the app shows up in the PDF automatically. */
@page { size: A4 landscape; margin: 12mm; }

html, body { background: #fff !important; }
* { -webkit-print-color-adjust: exact; print-color-adjust: exact; }

/* App chrome that means nothing on paper. */
.side, .viewing, .head-tools, .tabs-row, .tt, .cmdk, .tips, .tip, .glossary, .print-btn, .dp, .src-switch,
.cs-btn, .upsell form, .lead .marks form, nav.seg { display: none !important; }

.shell { display: block !important; min-height: 0 !important; }
.main { padding: 0 !important; max-width: none !important; gap: 12px !important; }
.head { margin-bottom: 4px; }
.head .eyebrow { display: none; }
.head h1 { font-size: 22px !important; }

/* The heading on paper: logo, business, report, dates and when it was downloaded. */
.print-head { display: flex !important; justify-content: space-between; align-items: flex-end; gap: 16px; padding-bottom: 10px; margin-bottom: 4px; border-bottom: 2px solid #14213d; }
.print-head .ph-brand { font: 900 18px Montserrat, Arial, sans-serif; }
.print-head .ph-meta { text-align: right; font-size: 12px; color: #4b5a70; line-height: 1.5; }
.print-head .ph-meta b { color: #14213d; font-size: 14px; }

.card { box-shadow: none !important; border: 1px solid #dde3ee; }
/* Small cards stay whole; long ones (tables, lead lists) may run onto the next page. */
.kpi, .donut-card, .lead, tr, .combo { break-inside: avoid; page-break-inside: avoid; }
.grid { gap: 10px !important; }
.kpi .value { font-size: 26px !important; }
.cb-cols, .cb-col:hover { background: none !important; }
.cb-dot { transform: none !important; }
a { color: inherit !important; text-decoration: none !important; }
table { font-size: 12px; }
th, td { padding: 6px 8px !important; }
.table-wrap { overflow: visible !important; }

/* Keep the desktop layout on paper (the phone layout must not kick in). */
.kpis { grid-template-columns: repeat(4, minmax(0, 1fr)) !important; }
.two-one { grid-template-columns: 2fr 1fr !important; }
.halves { grid-template-columns: 1fr 1fr !important; }
.thirds { grid-template-columns: repeat(3, minmax(0, 1fr)) !important; }
/* A chart card stays on one page. */
.card:has(.combo), .card:has(.donut) { break-inside: avoid; page-break-inside: avoid; }
/* The business name is in the paper heading already; links and hover hints mean nothing on paper. */
.head { display: none !important; }
.card-head a { display: none !important; }
.jargon { border-bottom: 0 !important; }

/* Short cards never split across pages; only long tables and lead lists may. */
.card:not(:has(.table-wrap)):not(:has(.lead)) { break-inside: avoid; page-break-inside: avoid; }
