/* Pacnft frontend CSS — only what theme.json cannot express. */

/* Dark mode: overrides the same CSS custom properties theme.json already
   generates on :root, so every block/component that reads
   var(--wp--preset--color--*) picks up the dark palette automatically.
   Every value below was checked against WCAG AA (4.5:1 text) before use —
   see 05-design-system.md §1. Light values are NOT redeclared here;
   theme.json is the single source of truth for those. */
@media (prefers-color-scheme: dark) {
	:root:not([data-theme="light"]) {
		--wp--preset--color--background: #101418;
		--wp--preset--color--surface: #1A2028;
		--wp--preset--color--text: #E9EDF2;
		--wp--preset--color--muted: #A3ADB8;
		--wp--preset--color--border: #A3ADB8;
		--wp--preset--color--accent: #FF8098;
		--wp--preset--color--accent-secondary: #82B7E3;
	}
}
:root[data-theme="dark"] {
	--wp--preset--color--background: #101418;
	--wp--preset--color--surface: #1A2028;
	--wp--preset--color--text: #E9EDF2;
	--wp--preset--color--muted: #A3ADB8;
	--wp--preset--color--border: #A3ADB8;
	--wp--preset--color--accent: #FF8098;
	--wp--preset--color--accent-secondary: #82B7E3;
}

/* Visible focus ring everywhere (reference 02 §19 accessibility). */
:focus-visible {
	outline: 2px solid var(--wp--preset--color--accent);
	outline-offset: 2px;
}

/* Skip link */
.skip-link {
	position: absolute;
	left: -9999px;
	top: 0;
	background: var(--wp--preset--color--text);
	color: var(--wp--preset--color--background);
	padding: 12px 16px;
	z-index: 100;
}
.skip-link:focus {
	left: 16px;
	top: 16px;
}

/* Breadcrumbs (two-level: Home / Article — no hub level, see functions.php). */
.pacnft-breadcrumbs {
	font-size: var(--wp--preset--font-size--small);
	color: var(--wp--preset--color--muted);
	margin-bottom: var(--wp--preset--spacing--20);
}
.pacnft-breadcrumbs a {
	color: var(--wp--preset--color--muted);
	text-decoration: underline;
}
.pacnft-breadcrumbs [aria-current="page"] {
	color: var(--wp--preset--color--text);
}

/* Last-updated freshness line. */
.pacnft-last-updated {
	font-size: var(--wp--preset--font-size--small);
	color: var(--wp--preset--color--muted);
	margin-top: -8px;
	margin-bottom: var(--wp--preset--spacing--10);
}

/* "Reviewed against our editorial standards" line — this site's authorship
   treatment in place of a named byline (05-design-system.md §3). */
.pacnft-checked-line {
	font-size: var(--wp--preset--font-size--small);
	color: var(--wp--preset--color--muted);
	margin-bottom: var(--wp--preset--spacing--30);
}
.pacnft-checked-line a {
	color: var(--wp--preset--color--accent);
}

/* Body links: crimson underline that thickens on hover rather than changing
   colour — a quieter treatment than any sibling site's link styling
   (05-design-system.md §3). */
.entry-content a,
.wp-block-post-content a {
	text-decoration-color: var(--wp--preset--color--accent);
	text-underline-offset: 3px;
	text-decoration-thickness: 1px;
}
.entry-content a:hover,
.wp-block-post-content a:hover {
	text-decoration-thickness: 3px;
}

/* Article images: hairline border, minimal radius — restrained, matching the
   instrument register rather than a card treatment. */
.entry-content figure.wp-block-image img,
.wp-block-post-content figure.wp-block-image img {
	width: 100%;
	height: auto;
	border-radius: 3px;
	border: 1px solid var(--wp--preset--color--border);
}
.entry-content figcaption,
.wp-block-post-content figcaption {
	font-size: var(--wp--preset--font-size--small);
	color: var(--wp--preset--color--muted);
	margin-top: 8px;
}
.entry-content figure.wp-block-image,
.wp-block-post-content figure.wp-block-image {
	margin: var(--wp--preset--spacing--40) 0;
}

.wp-block-post-featured-image img {
	border-radius: 3px;
	border: 1px solid var(--wp--preset--color--border);
}

/* Tables: tabular numerals are a functional requirement here — the Worked
   Examples page is entirely numeric comparison tables (05-design-system.md §2). */
.entry-content table,
.wp-block-post-content table {
	border-collapse: collapse;
	width: 100%;
	margin: var(--wp--preset--spacing--30) 0;
	border: 1px solid var(--wp--preset--color--border);
	font-variant-numeric: tabular-nums;
}
.entry-content th,
.entry-content td,
.wp-block-post-content th,
.wp-block-post-content td {
	border: 1px solid var(--wp--preset--color--border);
	padding: var(--wp--preset--spacing--10) var(--wp--preset--spacing--20);
	text-align: left;
	vertical-align: top;
}
.entry-content thead th,
.wp-block-post-content thead th {
	background: rgba(168, 15, 44, 0.07);
	font-family: var(--wp--preset--font-family--heading);
}

/* Wide tables must scroll inside their own container on narrow viewports
   rather than forcing the page to scroll horizontally. */
.entry-content .wp-block-table,
.wp-block-post-content .wp-block-table {
	overflow-x: auto;
}

/* Banded callout — a marked range rather than a boxed card
   (05-design-system.md §3). Colour is never the sole carrier of meaning:
   the band always contains explicit text. */
.pacnft-band {
	border-top: 3px solid var(--wp--preset--color--accent);
	border-bottom: 3px solid var(--wp--preset--color--accent);
	padding: var(--wp--preset--spacing--30) 0;
	margin: var(--wp--preset--spacing--40) 0;
}

/* Visible FAQ list — see functions.php pacnft_faq_list_shortcode(). Each
   answer keeps a hairline top border, matching this site's restrained
   instrument register rather than a card treatment. */
.pacnft-faq-list {
	margin: var(--wp--preset--spacing--30) 0;
}
.pacnft-faq-item {
	padding: var(--wp--preset--spacing--20) 0;
	border-top: 1px solid var(--wp--preset--color--border);
}
.pacnft-faq-item:last-child {
	border-bottom: 1px solid var(--wp--preset--color--border);
}
.pacnft-faq-question {
	margin: 0 0 var(--wp--preset--spacing--10) 0;
	font-size: var(--wp--preset--font-size--large);
}
.pacnft-faq-answer {
	margin: 0;
	color: var(--wp--preset--color--muted);
}

/* Tick rule — a measurement-scale separator between major sections. */
.pacnft-rule {
	position: relative;
	height: 1px;
	background: var(--wp--preset--color--border);
	margin: var(--wp--preset--spacing--50) 0;
	border: 0;
}
.pacnft-rule::before {
	content: "";
	position: absolute;
	inset: -5px 0 auto 0;
	height: 11px;
	background-image: repeating-linear-gradient(
		to right,
		var(--wp--preset--color--border) 0,
		var(--wp--preset--color--border) 1px,
		transparent 1px,
		transparent 24px
	);
}

/* Mobile navigation is the core Navigation block's own overlay menu
   (overlayMenu:"mobile" in parts/header.html) — no custom toggle CSS/JS
   needed. Only re-skin its colors to match the palette. */
.wp-block-navigation__responsive-container.is-menu-open {
	background: var(--wp--preset--color--background);
}

/* Respect reduced motion. */
@media (prefers-reduced-motion: reduce) {
	* {
		animation-duration: 0.001ms !important;
		transition-duration: 0.001ms !important;
	}
}
