/* Print stylesheet: shows #pdf-summary, hides interactive UI. */
@media print {
  .topbar,
  .panel,
  #map,
  .maplibregl-ctrl-attrib,
  #consent,
  .sitefooter,
  .hero__actions { display: none !important; }

  #pdf-summary { display: block !important; }

  body {
    background: white !important;
    color: #1a1a1a !important;
    font-family: "Hanken Grotesk", sans-serif;
    font-size: 13px;
  }

  .layout { display: block !important; padding: 0 !important; width: 100% !important; }
  .journey { display: block !important; }

  /* Keep the ribbon readable in print */
  .ribbon {
    box-shadow: none !important;
    border: 1px solid #ccc !important;
    break-inside: avoid;
  }

  /* Override all CSS vars with print-safe values */
  :root, [data-theme], [data-palette] {
    --accent: #e07b00 !important;
    --accent-strong: #b55e00 !important;
    --charge: #1aab78 !important;
    --rest: #d45c3b !important;
    --bg: white !important;
    --bg-glow: none !important;
    --surface: white !important;
    --surface-2: #f5f5f5 !important;
    --text: #1a1a1a !important;
    --text-dim: #555 !important;
    --border: #ccc !important;
    --spine: rgba(181,94,0,0.5) !important;
    --accent-soft: rgba(224,123,0,0.1) !important;
    --on-accent: white !important;
    --shadow: none !important;
  }

  @page { size: A4; margin: 20mm; }
}

/* pdf-summary structure (only visible when printing) */
.pdf-header { margin-bottom: 16px; }
.pdf-title { font-size: 18pt; font-weight: 700; margin: 0 0 6px; }
.pdf-meta { font-size: 10pt; color: #555; margin-bottom: 4px; display: flex; gap: 6px; flex-wrap: wrap; }
.pdf-brand { font-size: 9pt; color: #888; margin: 0; }
.pdf-table { width: 100%; border-collapse: collapse; font-size: 10pt; margin-top: 12px; }
.pdf-table th { border-bottom: 2px solid #333; text-align: left; padding: 4px 8px; font-weight: 600; }
.pdf-table td { padding: 4px 8px; border-bottom: 1px solid #ddd; }
.pdf-row--charge td { color: #1aab78; }
.pdf-row--break td { color: #d45c3b; }
.pdf-time { font-family: monospace; white-space: nowrap; }
