/* Reset, typography, layout primitives. */
*,
*::before,
*::after {
	box-sizing: border-box;
}

html {
	-webkit-text-size-adjust: 100%;
	scroll-behavior: smooth;
}

body {
	margin: 0;
	font-family: var(--font-body);
	font-weight: var(--fw-regular);
	font-size: var(--fs-body-secondary);
	line-height: 1.4;
	letter-spacing: var(--ls-body);
	color: var(--color-dark);
	background: var(--color-light);
	-webkit-font-smoothing: antialiased;
}

h1,
h2,
h3,
h4,
h5,
p,
ul,
ol,
figure,
blockquote {
	margin: 0;
}

/* :where() keeps this at zero specificity so component classes can set padding */
:where(ul[class], ol[class]) {
	padding: 0;
	list-style: none;
}

img,
svg,
video {
	display: block;
	max-width: 100%;
}

a {
	color: inherit;
	text-decoration: none;
}

button {
	font: inherit;
	color: inherit;
	letter-spacing: inherit;
	background: none;
	border: 0;
	padding: 0;
	cursor: pointer;
}

:focus-visible {
	outline: 2px solid var(--color-primary);
	outline-offset: 3px;
}

/* Typography scale (Figma text styles) */
.fv-h1,
.fv-h2,
.fv-h3,
.fv-h4,
.fv-h5 {
	font-weight: var(--fw-semibold);
	letter-spacing: var(--ls-heading);
}

.fv-h1 { font-size: var(--fs-h1); line-height: 1.1; }
.fv-h2 { font-size: var(--fs-h2); line-height: 1.15; }
.fv-h3 { font-size: var(--fs-h3); line-height: 1.15; }
.fv-h4 { font-size: var(--fs-h4); line-height: 1.3; }
.fv-h5 { font-size: var(--fs-h5); line-height: 1.3; }

.fv-body-main {
	font-size: var(--fs-body-main);
	font-weight: var(--fw-medium);
	line-height: 1.4;
	letter-spacing: var(--ls-body);
}

.fv-body-secondary {
	font-size: var(--fs-body-secondary);
	line-height: 1.4;
	letter-spacing: var(--ls-body);
}

.fv-body-small {
	font-size: var(--fs-body-small);
	line-height: 1.4;
	letter-spacing: var(--ls-body);
}

.fv-label {
	font-size: var(--fs-label);
	font-weight: var(--fw-medium);
	line-height: 1.4;
	letter-spacing: var(--ls-label);
	text-transform: uppercase;
}

/* Layout */
.container {
	width: 100%;
	max-width: calc(var(--container) + 2 * var(--gutter));
	margin-inline: auto;
	padding-inline: var(--gutter);
}

.skip-link {
	position: absolute;
	left: var(--gutter);
	top: -100px;
	z-index: 1000;
	padding: 10px 16px;
	background: var(--color-primary);
	color: var(--color-dark);
	border-radius: var(--radius-btn);
}

.skip-link:focus {
	top: 10px;
}

.screen-reader-text {
	position: absolute;
	width: 1px;
	height: 1px;
	overflow: hidden;
	clip: rect(0 0 0 0);
	white-space: nowrap;
}

/* Generic page content (page.php / index.php) */
.page-content {
	padding-block: var(--section-y);
}

.page-content__title {
	margin-bottom: 32px;
}

.page-content__body > * + * {
	margin-top: 1em;
}

@media (prefers-reduced-motion: reduce) {
	html {
		scroll-behavior: auto;
	}

	*,
	*::before,
	*::after {
		animation-duration: 0.01ms !important;
		animation-iteration-count: 1 !important;
		transition-duration: 0.01ms !important;
	}
}
