/*
 * Base layer: the live build's Tailwind v4 preflight (the parts this site relies on) + its body/focus rules
 * [M css:@layer base], plus the shared layout primitives (container, section, visually-hidden).
 */
*, ::before, ::after, ::backdrop {
	box-sizing: border-box;
	border: 0 solid;
	margin: 0;
	padding: 0;
}
html {
	-webkit-text-size-adjust: 100%;
	tab-size: 4;
	line-height: 1.5;
	font-family: var(--font-sans);
	-webkit-tap-highlight-color: transparent;
	scroll-behavior: smooth;
}
@media (prefers-reduced-motion: reduce) {
	html { scroll-behavior: auto; }
}
body {
	background-color: var(--color-white);
	font-family: var(--font-sans);
	color: var(--color-brand-dark);
	-webkit-font-smoothing: antialiased;
	-moz-osx-font-smoothing: grayscale;
}
h1, h2, h3, h4, h5, h6 { font-size: inherit; font-weight: inherit; }
a { color: inherit; text-decoration: inherit; }
b, strong { font-weight: bolder; }
small { font-size: 80%; }
ol, ul, menu { list-style: none; }
img, svg, video, canvas, audio, iframe, embed, object { vertical-align: middle; display: block; }
img, video { max-width: 100%; height: auto; }
/* WordPress (6.7+) gives lazy images with sizes="auto" a contain-intrinsic-size of 3000px 1500px until they load. An image that
   never loads (a deleted media file) keeps that 3000px and stretches single-column grids sideways on phones. Our images size from
   their width/aspect-ratio instead, so drop that placeholder size. Do not remove: found on staging when one upload was missing. */
img:is([sizes="auto" i], [sizes^="auto," i]) { contain-intrinsic-size: none; }
button, input, select, optgroup, textarea {
	font: inherit;
	letter-spacing: inherit;
	color: inherit;
	opacity: 1;
	background-color: transparent;
	border-radius: 0;
}
button, input:where([type="button"], [type="reset"], [type="submit"]) { appearance: button; }
::placeholder { opacity: 1; color: color-mix(in oklab, currentcolor 50%, transparent); }
textarea { resize: vertical; }
[hidden]:where(:not([hidden="until-found"])) { display: none !important; }
button, [role="button"] { cursor: pointer; }

/* [M css::focus-visible] Buttons/fields override this with their own ring. */
:focus-visible {
	outline: 2px solid var(--color-brand-orange);
	outline-offset: 2px;
}

/* Page frame: min-h-screen flex column, main grows [M js:layout]. */
.site {
	min-height: 100vh;
	display: flex;
	flex-direction: column;
}
.site-main { flex: 1 1 0%; }

/* Container: mx-auto px-4 sm:px-6 lg:px-8 max-w-6xl [M js:f68174f0 75003]. */
.container {
	margin-inline: auto;
	padding-inline: var(--gutter);
	max-width: var(--container-6xl);
}

/* Section: py-16 md:py-24 (64/96) is the sub-page default; home sections use --home (80/112) [M computed §3.2]. */
.section { padding-block: calc(var(--spacing) * 16); }
.section--home { padding-block: calc(var(--spacing) * 20); }
.section--white { background-color: var(--color-white); }
.section--gray { background-color: var(--color-gray-50); }
.section--dark { background-color: var(--color-brand-dark); color: var(--color-white); }
@media (min-width: 48rem) {
	.section { padding-block: calc(var(--spacing) * 24); }
	.section--home { padding-block: calc(var(--spacing) * 28); }
}

/* Screen-reader-only text and the skip link. */
.sr-only {
	position: absolute;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	white-space: nowrap;
	border-width: 0;
}
.skip-link {
	position: absolute;
	inset-inline-start: 1rem;
	top: -100px;
	z-index: 100;
	padding: 0.5rem 1rem;
	border-radius: var(--radius-full);
	background: var(--color-brand-orange);
	color: var(--color-white);
	font-size: var(--text-sm);
	line-height: var(--text-sm-lh);
	font-weight: var(--font-weight-semibold);
}
.skip-link:focus { top: 0.5rem; }

/*
 * Reveal hidden state (motion.js). Gated on .js so content is visible without JavaScript, and never applied under
 * reduced motion. Do not move this into a component file: the failsafe class in header.php relies on it being global.
 */
@media (prefers-reduced-motion: no-preference) {
	/* `translate` (not `transform`) so a component's own transform/hover transform never fights the reveal. */
	.js [data-reveal]:not(.is-revealed) {
		opacity: var(--reveal-from-opacity, 0);
		translate: 0 var(--reveal-y, 0);
	}
	.js.reveal-failsafe [data-reveal] { opacity: 1; translate: none; }
}
.site-main:focus { outline: none; }
