*, *::before, *::after { box-sizing: border-box; }

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

body {
	margin: 0;
	background: var(--sand);
	color: var(--aubergine);
	font-family: var(--font-body);
	font-size: var(--fs-body);
	line-height: var(--lh-body);
	-webkit-font-smoothing: antialiased;
	-moz-osx-font-smoothing: grayscale;
	overflow-x: clip;
}

h1, h2, h3, h4, h5, p, ul, ol, figure, blockquote { margin: 0; }
:where(ul[role="list"], ol[role="list"]) { list-style: none; padding: 0; }
img, svg { display: block; max-width: 100%; }
img { height: auto; }
a { color: inherit; }
button { font: inherit; color: inherit; }

h1, h2, h3, h4, h5, .h3, .h4, .h5 {
	font-family: var(--font-display);
	font-weight: 700;
	line-height: var(--lh-heading);
	/* Figma uses optical size 14 for all Bricolage text */
	font-variation-settings: "opsz" 14;
	text-wrap: balance;
}
p, li, figcaption, blockquote { text-wrap: pretty; }

.h3 { font-size: var(--fs-h3); }
.h4 { font-size: var(--fs-h4); }
.h5 { font-size: var(--fs-h5); }

.text-muted { opacity: 0.7; }
.on-dark { color: var(--white); }
.on-dark-muted { color: rgb(255 255 255 / 0.7); }

/* Line break entered in the CMS: only from tablet up (avoids orphans on mobile) */
.br-md { display: none; }
@media (min-width: 768px) { .br-md { display: inline; } }

:focus-visible {
	outline: 2px solid var(--coral);
	outline-offset: 3px;
	border-radius: 4px;
}

.skip-link {
	position: absolute;
	left: 16px;
	top: -100px;
	z-index: 100;
	padding: 12px 20px;
	background: var(--ochre);
	color: var(--aubergine);
	font-weight: 700;
	border-radius: var(--r-pill);
	text-decoration: none;
}
.skip-link:focus { top: 16px; }

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

/* Space above/below follows the section setting (--space-top/--space-bottom), else the default */
.section {
	padding-top: var(--space-top, var(--section-y));
	padding-bottom: var(--space-bottom, var(--section-y));
}

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