/*
 * Base: element defaults. Uses tokens only.
 */

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

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

body {
	margin: 0;
	background: var(--color-bg);
	color: var(--color-text);
	font-family: var(--font-body);
	font-size: var(--text-base);
	line-height: var(--leading-body);
}

h1,
h2,
h3,
h4,
h5,
h6 {
	font-family: var(--font-heading);
	font-style: var(--font-heading-style);
}

h1,
h2,
h3,
h4 {
	margin: 0 0 var(--space-4);
	line-height: var(--leading-tight);
	color: var(--color-brand-strong);
}

h1 { font-size: var(--text-3xl); }
h2 { font-size: var(--text-2xl); }
h3 { font-size: var(--text-xl); }
h4 { font-size: var(--text-lg); }

p,
ul,
ol,
figure {
	margin: 0 0 var(--space-4);
}

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

a {
	color: var(--color-brand);
	text-underline-offset: 0.15em;
}

a:hover {
	color: var(--color-brand-strong);
}

:focus-visible {
	outline: var(--focus-width) solid var(--color-focus);
	outline-offset: var(--space-1);
}

button,
input,
select,
textarea {
	font: inherit;
	color: inherit;
}

label {
	display: block;
	font-weight: var(--weight-bold);
	margin-bottom: var(--space-1);
}

input[type="text"],
input[type="email"],
input[type="search"],
input[type="tel"],
select,
textarea {
	display: block;
	width: 100%;
	padding: var(--space-2) var(--space-3);
	background: var(--color-surface);
	border: var(--border-width) solid var(--color-border-strong);
	border-radius: var(--radius-sm);
}

textarea {
	min-height: 8rem;
	resize: vertical;
}
