/* Jensdotter.se — print stylesheet (A4 with footnotes). */

@page {
	size: A4;
	margin: 22mm 22mm 26mm 22mm;
	@bottom-center {
		content: "jensdotter.se · " counter(page) " / " counter(pages);
		font-family: 'JetBrains Mono', ui-monospace, monospace;
		font-size: 9pt;
		color: #6b6357;
	}
}

html, body {
	background: #fff !important;
	color: #1c1a16 !important;
}

body {
	font-family: 'Newsreader', 'Iowan Old Style', Georgia, serif !important;
	font-size: 11pt;
	line-height: 1.55;
}

/* Hide chrome */
.doc-nav, .site-nav, .site-footer, .pagination, .tag-index,
.entry-summary-en, .pub-filters, .comments-area,
.search-form, .now-writing, .hero-aside, .kontakt-form,
.kontakt-socials, .site-footer-socials {
	display: none !important;
}

main, .site-main { display: block !important; }

.entry, article, .pub-table, .pub-group, .kontakt, .about {
	max-width: none !important;
	padding: 0 !important;
	margin: 0 !important;
	display: block !important;
	grid-template-columns: none !important;
}

a, a:visited {
	color: inherit !important;
	text-decoration: none !important;
	background: none !important;
}

/* Surface URLs as superscript footnote markers and emit a list at end. */
.entry-content { counter-reset: footnote; }
.entry-content a[href]::after {
	counter-increment: footnote;
	content: " [" counter(footnote) "]";
	font-family: 'JetBrains Mono', monospace;
	font-size: 8pt;
	vertical-align: super;
	color: #6b6357;
}
.entry-content a[href^="#"]::after,
.entry-content a[href^="javascript:"]::after { content: ""; counter-increment: none; }

.entry-content::after {
	counter-reset: footref;
	display: block;
	margin-top: 28pt;
	padding-top: 14pt;
	border-top: 1px solid #1c1a16;
	content: "";
}

/* Lay out a generated reference list using the print CSS technique:
   we copy URLs via [data-print-footnotes] block; if absent, browsers won't synthesize
   a list, so we always emit the URLs inline as a fallback in print preview. */
.entry-content a[href^="http"]:not([data-print-skip])::before {
	content: "";
}

/* Article header */
.entry-header h1 {
	font-size: 28pt !important;
	line-height: 1.05 !important;
	margin-top: 0 !important;
}
.entry-header .h-eyebrow {
	font-family: 'JetBrains Mono', monospace !important;
	font-size: 8pt !important;
	color: #6b6357 !important;
	letter-spacing: 0.18em !important;
}
.entry-header .lede {
	font-size: 13pt;
	color: #1c1a16;
	max-width: none;
}

/* Pull quote / blockquote */
.entry-content blockquote {
	border-left: 1.5pt solid #6b6357 !important;
	padding-left: 12pt !important;
	color: #1c1a16 !important;
	font-style: italic;
	font-size: 13pt;
}

/* Tables (publications, etc.) */
.pub-table-head, .pub-row {
	display: grid !important;
	grid-template-columns: 60pt 1fr 200pt 100pt !important;
	gap: 12pt !important;
	padding: 8pt 0 !important;
	border-bottom: 0.5pt solid #d6cebc !important;
}
.pub-row { page-break-inside: avoid; }
.pub-citation { page-break-inside: avoid; padding: 8pt 0; }

/* Page break behavior */
h1, h2, h3 { page-break-after: avoid; }
img, figure, blockquote { page-break-inside: avoid; }

/* Header dateline before article */
.entry::before {
	content: "jensdotter.se · " attr(data-print-date);
	display: block;
	font-family: 'JetBrains Mono', monospace;
	font-size: 8pt;
	letter-spacing: 0.18em;
	color: #6b6357;
	text-transform: uppercase;
	margin-bottom: 18pt;
	padding-bottom: 6pt;
	border-bottom: 0.5pt solid #d6cebc;
}
