/* ============================================================
   Prose bundle — the generic page template (page.php) and the
   not-found page (404.php).

   Long-form running text is the one place the design system's
   very tight leading doesn't apply: the cards and callouts
   elsewhere set body copy at line-height 1.2, which is right for
   two lines in a box and unreadable for a page of legal text.
   These rules open it up and cap the measure instead.
   ============================================================ */

.prose-page,
.error-page {
	padding: clamp(130px, 15vw, 200px) var(--gutter) clamp(90px, 10vw, 150px);
	color: var(--navy);
}
.prose-page__inner { max-width: 768px; margin: 0 auto; }

/* ---------- Page head ---------- */
.prose-page__title { color: var(--black); }
.prose-page__meta {
	margin-top: 24px;
	font-family: var(--font-ui); font-weight: 600; font-size: 12px;
	letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted-text);
}
.prose-page__rule {
	border: 0; border-top: 1px solid var(--taupe);
	margin: clamp(34px, 4vw, 48px) 0 clamp(34px, 4vw, 48px);
}

/* ---------- Editor content ----------
   Styles the_content() output, so it has to cover whatever the
   block editor emits rather than a fixed set of theme classes. */
.prose {
	font-family: var(--font-body);
	font-size: 18px;
	line-height: 1.65;
	/* Legal copy runs long URLs and statute citations that have no break
	   opportunity; without this they push the column past the viewport. */
	overflow-wrap: break-word;
}
.prose > * + * { margin-top: 1.1em; }

.prose h2, .prose h3 {
	font-family: var(--font-display); font-weight: 200;
	line-height: 1.05; letter-spacing: 0.01em; color: var(--black);
}
.prose h2 { font-size: clamp(28px, 3.1vw, 38px); }
.prose h3 { font-size: clamp(22px, 2.3vw, 27px); }
.prose h4, .prose h5, .prose h6 {
	font-family: var(--font-ui); font-weight: 600; font-size: 15px;
	letter-spacing: 0.08em; text-transform: uppercase; line-height: 1.35;
	color: var(--green);
}
.prose > * + h2 { margin-top: clamp(42px, 4.6vw, 62px); }
.prose > * + h3 { margin-top: clamp(32px, 3.4vw, 42px); }
.prose > * + h4, .prose > * + h5, .prose > * + h6 { margin-top: 30px; }
.prose > :is(h2, h3, h4, h5, h6) + * { margin-top: 0.65em; }

.prose ul, .prose ol { padding-left: 1.4em; }
.prose li + li { margin-top: 0.4em; }
.prose li > ul, .prose li > ol { margin-top: 0.4em; }
.prose li::marker { color: var(--olive-text); }

.prose a {
	text-decoration: underline;
	text-decoration-color: var(--gold);
	text-decoration-thickness: 2px;
	text-underline-offset: 3px;
}
.prose a:hover { text-decoration-color: var(--navy); }
.prose strong, .prose b { font-weight: 600; }

.prose blockquote {
	margin-left: 0; margin-right: 0;
	padding: 2px 0 2px 26px;
	border-left: 3px solid var(--olive);
	color: var(--green);
}
.prose hr {
	border: 0; border-top: 1px solid var(--taupe);
	margin-top: clamp(34px, 4vw, 48px); margin-bottom: clamp(34px, 4vw, 48px);
}
.prose figure { margin-left: 0; margin-right: 0; }
.prose img { border-radius: 4px; }
.prose figcaption {
	margin-top: 10px; font-size: 14px; line-height: 1.5; color: var(--muted-text);
}

/* Tables scroll inside their own box rather than widening the page. */
.prose .wp-block-table, .prose figure:has(> table) { overflow-x: auto; }
.prose table { width: 100%; border-collapse: collapse; font-size: 0.94em; }
.prose th, .prose td {
	text-align: left; vertical-align: top;
	padding: 11px 14px; border-bottom: 1px solid var(--taupe);
}
.prose th {
	font-family: var(--font-ui); font-size: 12px; font-weight: 600;
	letter-spacing: 0.08em; text-transform: uppercase; color: var(--green);
}

.prose code {
	font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
	font-size: 0.88em; background: var(--field); padding: 1px 5px; border-radius: 3px;
}
.prose pre {
	background: var(--field); padding: 16px 18px; border-radius: 4px;
	overflow-x: auto; line-height: 1.5;
}
.prose pre code { background: none; padding: 0; }

.prose-page__pages {
	margin-top: clamp(34px, 4vw, 48px);
	font-family: var(--font-ui); font-size: 13px; font-weight: 600;
	letter-spacing: 0.06em;
}

/* ============================================================
   404
   ============================================================ */
.error-page { text-align: center; }
.error-page__inner {
	max-width: 720px; margin: 0 auto;
	display: flex; flex-direction: column; align-items: center;
}
.error-page__code { color: var(--green); font-size: 15px; }
.error-page__title { color: var(--black); margin-top: 26px; max-width: 640px; }
.error-page__body {
	margin-top: clamp(24px, 2.8vw, 34px);
	font-family: var(--font-body); font-size: 18px; line-height: 1.6;
	max-width: 540px;
}
.error-page__links-label {
	margin-top: clamp(46px, 5.5vw, 72px);
	font-family: var(--font-ui); font-weight: 600; font-size: 12px;
	letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted-text);
}
.error-page__links {
	display: flex; flex-wrap: wrap; justify-content: center;
	gap: 14px 32px; margin-top: 20px;
}
.error-page__links a {
	font-family: var(--font-ui); font-weight: 600; font-size: 12px;
	letter-spacing: 0.1em; text-transform: uppercase; line-height: 1.2;
	text-decoration: underline; text-decoration-color: var(--gold);
	text-decoration-thickness: 2px; text-underline-offset: 4px;
}
.error-page__links a:hover { text-decoration-color: var(--navy); }
.error-page__home { margin-top: clamp(40px, 4.6vw, 58px); }

@media (max-width: 640px) {
	.prose { font-size: 17px; }
	.error-page__body { font-size: 17px; }
}
