/* ==========================================================================
   Shared report PDF export
   --------------------------------------------------------------------------
   A "Download PDF" control plus print rules so any assessment report can be
   saved to PDF through the browser's own print dialog (no library, no server).
   report-pdf.js injects the button — inline into a `.report-actions` row where
   one exists, otherwise as a floating control — and this file styles it and
   strips the site chrome from the printed page. All colours from tokens.css.
   ========================================================================== */

.report-pdf-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 48px; padding: 12px 22px;
  border: 1px solid var(--border-strong); border-radius: var(--radius-md);
  background: var(--white); color: var(--charcoal);
  font-family: var(--font-display); font-weight: var(--w-bold); font-size: 15px; line-height: 1;
  cursor: pointer;
  transition: border-color .18s var(--ease-out), color .18s var(--ease-out), box-shadow .18s var(--ease-out), transform .18s var(--ease-out);
}
.report-pdf-btn:hover { border-color: var(--brand-primary); color: var(--brand-primary); box-shadow: var(--shadow-xs); transform: translateY(-1px); }
.report-pdf-btn:focus-visible { outline: 2px solid var(--brand-primary); outline-offset: 2px; }

/* Floating variant for report pages without an actions row. Sits bottom-left
   so it never collides with the bottom-right WhatsApp / back-to-top controls. */
.report-pdf-btn--float { position: fixed; left: 20px; bottom: 20px; z-index: 400; border-radius: var(--radius-pill); background: var(--white); box-shadow: var(--shadow-lg); }
@media (max-width: 768px) { .report-pdf-btn--float { left: 14px; bottom: 14px; } }

@media print {
  site-header, .nav, site-footer, .footer,
  .cookie-consent-banner, .lfth-float-actions, .report-pdf-btn, [data-no-print] { display: none !important; }
  html, body { background: #fff !important; }
  body { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  main { max-width: none !important; padding: 0 !important; }
  @page { margin: 14mm; }
}

@media (prefers-reduced-motion: reduce) {
  .report-pdf-btn { transition: none; }
  .report-pdf-btn:hover { transform: none; }
}
