/* =============================================================================
   FILE: print.css
   WHAT: Styling applied only when a page is PRINTED (or "printed to PDF").
   WHY: Readers of long technical articles (cybersecurity write-ups, cloud
        how-tos) sometimes print or PDF-export them for offline reading --
        this file hides on-screen-only UI (navigation, buttons, share
        icons) that make no sense on paper, and prints the actual URL next
        to each link so a paper copy doesn't lose that information.
   LOAD ORDER: enqueued with media="print" (see inc/enqueue.php), so the
        browser only downloads/applies it when actually printing -- it
        never affects or slows down normal on-screen browsing.
   ============================================================================= */

@media print {

	/* Hide anything that's only useful for on-screen interaction: nav,
	   the mobile menu button, share buttons, the accordion's decorative
	   +/x icon, carousel scroll buttons, and the skip link. */
	.site-header,
	.site-footer,
	.share-links,
	.carousel-controls,
	.skip-link,
	.pagination,
	.mini-cart,
	.nav-overlay {
		display: none !important;
	}

	body {
		color: #000; /* pure black for print -- ink/toner contrast matters more
		                 than the on-screen near-black readability choice */
	}

	a {
		color: #000;
		text-decoration: underline;
	}

	/* Print the actual destination URL right after each link's text, in
	   parentheses -- on paper you can't click a link, so this preserves
	   the information instead of losing it silently. We skip this for
	   internal "#" anchor links (like the accordion), since printing
	   "(#)" after every FAQ question would just be noise. */
	.single-post__content a[href]:not([href^="#"])::after {
		content: " (" attr(href) ")";
		font-size: 0.8em;
		font-weight: normal;
	}

	/* Avoid a heading being stranded as the very last line on a printed
	   page with its content starting on the next page. */
	h1, h2, h3, h4 {
		break-after: avoid;
	}

	/* Avoid an image or code block being split awkwardly across a page break. */
	img, pre, table {
		break-inside: avoid;
	}
}
