/* BuidlHonduras frontend CSS — only what theme.json cannot express.
   Neumorphism register: soft-extruded tonal surfaces, low-contrast shadow
   pairs standing in for borders wherever contrast still holds up, a raised
   "lede" panel on the front page, and card-style FAQ entries. */

/* Dark mode: overrides the same CSS custom properties theme.json already
   generates on :root. 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. */
@media (prefers-color-scheme: dark) {
	:root:not([data-theme="light"]) {
		--wp--preset--color--background: #1B1D2B;
		--wp--preset--color--surface: #242737;
		--wp--preset--color--text: #E3E5F0;
		--wp--preset--color--muted: #9CA0BE;
		--wp--preset--color--border: #383C54;
		--wp--preset--color--accent: #E8825A;
	}
}
:root[data-theme="dark"] {
	--wp--preset--color--background: #1B1D2B;
	--wp--preset--color--surface: #242737;
	--wp--preset--color--text: #E3E5F0;
	--wp--preset--color--muted: #9CA0BE;
	--wp--preset--color--border: #383C54;
	--wp--preset--color--accent: #E8825A;
}

:focus-visible {
	outline: 2px solid var(--wp--preset--color--accent);
	outline-offset: 2px;
}

.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;
}

/* --- Utility bar: a slim strip above the main header row, holding About/
   Editorial-Guidelines links. Distinct from every prior site's header,
   which puts navigation beside or below the identity, never above it. --- */
.bhn-utility-bar {
	background: var(--wp--preset--color--surface);
	border-bottom: 1px solid var(--wp--preset--color--border);
	padding: var(--wp--preset--spacing--10) var(--wp--preset--spacing--20);
}
.bhn-utility-nav .wp-block-navigation__container {
	gap: var(--wp--preset--spacing--30) !important;
}
.bhn-utility-nav a {
	font-size: var(--wp--preset--font-size--small);
	color: var(--wp--preset--color--muted);
	text-decoration: none;
}
.bhn-utility-nav a:hover,
.bhn-utility-nav a:focus-visible {
	color: var(--wp--preset--color--accent);
}

.bhn-tagline {
	color: var(--wp--preset--color--muted);
	font-size: var(--wp--preset--font-size--small);
	margin: 0;
}

/* --- Footer: a genuine 3-column layout (identity / site links / a short
   standalone note), not the two-item or single-row arrangement every prior
   site used. --- */
.bhn-footer-columns {
	gap: var(--wp--preset--spacing--50);
}
.bhn-footer h3 {
	font-family: var(--wp--preset--font-family--body);
	text-transform: uppercase;
	letter-spacing: 0.06em;
	color: var(--wp--preset--color--muted);
	margin-bottom: var(--wp--preset--spacing--20);
}
.bhn-footer-nav .wp-block-navigation__container {
	gap: var(--wp--preset--spacing--10) !important;
}
.bhn-footer-nav a {
	color: var(--wp--preset--color--text);
	text-decoration: none;
	font-size: var(--wp--preset--font-size--small);
}
.bhn-footer-nav a:hover,
.bhn-footer-nav a:focus-visible {
	color: var(--wp--preset--color--accent);
}

/* --- Neumorphic soft-extruded shadow, used on the front-page lede panel
   and each FAQ item. A light shadow toward the top-left and a darker one
   toward the bottom-right, on a surface tone close to the page background,
   which is what gives a neumorphic "raised" read rather than a flat card.
   A 1px border is kept underneath as a non-shadow fallback for high-
   contrast/forced-colors modes, where box-shadow may not render. --- */
.bhn-lede {
	border: 1px solid var(--wp--preset--color--border);
	box-shadow:
		-10px -10px 24px rgba(255, 255, 255, 0.65),
		12px 12px 28px rgba(46, 49, 72, 0.12);
}
@media (prefers-color-scheme: dark) {
	:root:not([data-theme="light"]) .bhn-lede {
		box-shadow:
			-8px -8px 20px rgba(255, 255, 255, 0.04),
			10px 10px 24px rgba(0, 0, 0, 0.45);
	}
}
:root[data-theme="dark"] .bhn-lede {
	box-shadow:
		-8px -8px 20px rgba(255, 255, 255, 0.04),
		10px 10px 24px rgba(0, 0, 0, 0.45);
}
.bhn-lede-sub {
	margin-top: var(--wp--preset--spacing--20);
	margin-bottom: var(--wp--preset--spacing--20);
}
.bhn-last-updated,
.bhn-checked-line {
	font-size: var(--wp--preset--font-size--small);
	color: var(--wp--preset--color--muted);
	margin: 0 0 var(--wp--preset--spacing--10);
}
.bhn-checked-line a {
	color: var(--wp--preset--color--accent);
}

.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: 2px;
}

/* --- Tables: soft rounded surface panel rather than ruled lines, matching
   the neumorphic register instead of a print/ledger treatment. --- */
.entry-content table,
.wp-block-post-content table {
	width: 100%;
	margin: var(--wp--preset--spacing--40) 0;
	border-collapse: separate;
	border-spacing: 0;
	background: var(--wp--preset--color--surface);
	border-radius: 16px;
	overflow: hidden;
	border: 1px solid var(--wp--preset--color--border);
	font-variant-numeric: tabular-nums;
}
.entry-content th,
.wp-block-post-content th {
	text-align: left;
	padding: var(--wp--preset--spacing--20);
	background: var(--wp--preset--color--background);
	font-weight: 600;
	border-bottom: 1px solid var(--wp--preset--color--border);
}
.entry-content td,
.wp-block-post-content td {
	padding: var(--wp--preset--spacing--20);
	vertical-align: top;
	border-bottom: 1px solid var(--wp--preset--color--border);
}
.entry-content tr:last-child td,
.wp-block-post-content tr:last-child td {
	border-bottom: 0;
}
.entry-content .wp-block-table,
.wp-block-post-content .wp-block-table {
	overflow-x: auto;
}

/* --- Ordered-list steps: numerals in a small rounded pill, matching the
   soft-extruded register instead of large display numerals. --- */
.entry-content ol,
.wp-block-post-content ol {
	list-style: none;
	counter-reset: bhn-step;
	padding-left: 0;
}
.entry-content ol > li,
.wp-block-post-content ol > li {
	counter-increment: bhn-step;
	position: relative;
	padding-left: 2.6rem;
	margin-bottom: var(--wp--preset--spacing--20);
}
.entry-content ol > li::before,
.wp-block-post-content ol > li::before {
	content: counter(bhn-step);
	position: absolute;
	left: 0;
	top: -0.05em;
	width: 1.7rem;
	height: 1.7rem;
	display: flex;
	align-items: center;
	justify-content: center;
	border-radius: 999px;
	background: var(--wp--preset--color--surface);
	border: 1px solid var(--wp--preset--color--border);
	color: var(--wp--preset--color--accent);
	font-size: 0.85em;
	font-weight: 600;
}

/* --- Article images --- */
.entry-content figure.wp-block-image img,
.wp-block-post-content figure.wp-block-image img {
	width: 100%;
	height: auto;
	border-radius: 20px;
	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--30) 0;
}
.wp-block-post-featured-image img {
	border-radius: 20px;
	border: 1px solid var(--wp--preset--color--border);
}

/* --- Visible FAQ list: each entry as its own soft-raised card, the
   neumorphic equivalent of an accordion, matching the "knowledge base"
   content format. --- */
.bhn-faq-list {
	margin: var(--wp--preset--spacing--30) 0;
	display: grid;
	gap: var(--wp--preset--spacing--20);
}
.bhn-faq-item {
	background: var(--wp--preset--color--surface);
	border: 1px solid var(--wp--preset--color--border);
	border-radius: 18px;
	padding: var(--wp--preset--spacing--30);
	box-shadow:
		-6px -6px 16px rgba(255, 255, 255, 0.55),
		8px 8px 18px rgba(46, 49, 72, 0.10);
}
@media (prefers-color-scheme: dark) {
	:root:not([data-theme="light"]) .bhn-faq-item {
		box-shadow:
			-6px -6px 16px rgba(255, 255, 255, 0.03),
			8px 8px 18px rgba(0, 0, 0, 0.4);
	}
}
:root[data-theme="dark"] .bhn-faq-item {
	box-shadow:
		-6px -6px 16px rgba(255, 255, 255, 0.03),
		8px 8px 18px rgba(0, 0, 0, 0.4);
}
.bhn-faq-question {
	margin: 0 0 var(--wp--preset--spacing--10) 0;
	font-size: var(--wp--preset--font-size--large);
}
.bhn-faq-answer {
	margin: 0;
	color: var(--wp--preset--color--muted);
}

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