/* SLASHED — core/print.css
   @layer slashed.print
   Print-only visibility, page defaults, ink-saving resets, and URL disclosure.
   Prefix: .print-* for explicit print helpers. */

@layer slashed.print {

  @media print {

    @page {
      size:   a4 portrait;
      margin: 2cm;
    }

    body {
      font-size: 11pt;
    }

    *,
    *::before,
    *::after {
      box-shadow:  none;
      text-shadow: none;
    }

    a[href]:not([href^="#"], [href^="javascript:" i], [href^="mailto:" i], [href^="tel:" i], .sf-link-external)::after {
      content:    " (" attr(href) ")";
      font-size:  90%;
      word-break: break-all;
    }

    abbr[title]::after {
      content: " (" attr(title) ")";
    }

    img, svg, canvas, figure, table, pre, blockquote {
      break-inside: avoid;

    }

    thead {
      display: table-header-group;
    }

    tr {
      break-inside: avoid;
    }

    h1, h2, h3, h4, h5, h6 {
      break-after: avoid;

    }

    /* Fluid --sf-h*-size tokens resolve via 100vw clamp()s, which have no
       reliable meaning on a print page box. Pin print heading sizes to
       static pt values instead. */
    h1 { font-size: 24pt; }
    h2 { font-size: 20pt; }
    h3 { font-size: 16pt; }
    h4 { font-size: 14pt; }
    h5 { font-size: 12pt; }
    h6 { font-size: 11pt; }

    p {
      orphans: 3;
      widows:  3;
    }

    pre, blockquote {
      border:  var(--sf-border-width-1) solid var(--sf-color-border--strong);
      padding: var(--sf-space-s);
    }

    nav, aside, button, input, select, textarea,
    audio, video, dialog, [popover], .no-print {
      display: none !important;
    }

    details { display: block; }
    details > summary { display: none !important; }
    details > :not(summary) { display: block; }

  }

}
