/*
 * PlanSmartFi — Print Stylesheet
 *
 * Ensures blog posts and pages print cleanly.
 * Loaded via wp_enqueue_scripts with media="print".
 *
 * @package PlanSmartFi
 */

@media print {

	/* ── Page setup ── */
	@page {
		margin: 2cm;
	}

	/* ── Hide non-essential elements ── */
	.nav,
	.nav-toggle,
	.hero-stats,
	.marquee,
	.topics-grid,
	.blog-grid,
	.book-right,
	.guide-wrap,
	.mission-cards,
	.post-navigation,
	.related-posts,
	.comments-area,
	.site-footer,
	.skip-link,
	.btn-primary,
	.btn-ghost,
	.post-tags,
	.topic-arrow,
	.hero-glow,
	.hero-btns,
	.hero-stats,
	.footer,
	aside,
	nav {
		display: none !important;
	}

	/* ── Base resets for print ── */
	*,
	*::before,
	*::after {
		background: transparent !important;
		color: #000 !important;
		box-shadow: none !important;
		text-shadow: none !important;
	}

	body {
		font-family: Georgia, 'Times New Roman', serif;
		font-size: 12pt;
		line-height: 1.6;
		color: #000;
		background: #fff;
	}

	/* ── Links ── */
	a,
	a:visited {
		color: #000;
		text-decoration: underline;
	}

	/* Show full URLs for links (useful in articles) */
	.entry-content a[href]::after {
		content: ' (' attr(href) ')';
		font-size: 10pt;
		color: #444;
	}

	/* Don't show URL for internal anchors or javascript links */
	.entry-content a[href^='#']::after,
	.entry-content a[href^='javascript:']::after {
		content: '';
	}

	/* ── Headings ── */
	h1, h2, h3, h4, h5, h6 {
		font-family: Georgia, serif;
		page-break-after: avoid;
		page-break-inside: avoid;
		color: #000;
	}

	/* ── Images ── */
	img {
		max-width: 100% !important;
		page-break-inside: avoid;
	}

	/* ── Paragraphs & block elements ── */
	p,
	blockquote,
	pre,
	ul,
	ol,
	dl,
	table {
		page-break-inside: avoid;
	}

	/* ── Blockquotes ── */
	blockquote {
		border-left: 3px solid #999;
		padding-left: 16px;
		margin: 16px 0;
		font-style: italic;
	}

	/* ── Code ── */
	code, pre {
		font-family: 'Courier New', Courier, monospace;
		font-size: 10pt;
	}

	pre {
		border: 1px solid #ccc;
		padding: 12px;
		overflow: visible;
		white-space: pre-wrap;
	}

	/* ── Post header ── */
	.post-header {
		margin-bottom: 24pt;
		border-bottom: 1pt solid #ccc;
		padding-bottom: 12pt;
	}

	.post-title {
		font-size: 24pt;
		margin-bottom: 8pt;
	}

	.post-meta {
		font-size: 10pt;
		color: #666 !important;
	}

	/* ── Disclaimer ── */
	.post-disclaimer {
		border: 1pt solid #999;
		padding: 10pt;
		margin-top: 20pt;
		font-size: 9pt;
		color: #444 !important;
	}

	/* ── Page breaks ── */
	.entry-content h2,
	.entry-content h3 {
		page-break-before: auto;
	}

	.site-main {
		max-width: 100%;
	}
}
