/* Base: reset, document, utilities. Tokens only. */

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

html {
	-webkit-text-size-adjust: 100%;
	text-size-adjust: 100%;
	scroll-behavior: smooth;
	scroll-padding-top: var(--space-4);
}

@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;
	}
}

/* Set by dialog.js while an overlay is open. */
html.is-scroll-locked {
	overflow: hidden;
}

body {
	margin: 0;
	background: var(--color-bg);
	color: var(--color-text);
	font-family: var(--font-body);
	font-size: var(--text-16);
	font-weight: var(--weight-book);
	line-height: var(--leading-body);
	-webkit-font-smoothing: antialiased;
	overflow-x: hidden;
}

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

h1,
h2,
h3,
p {
	margin: 0;
}

h1,
h2,
h3 {
	font-family: var(--font-display);
	font-weight: var(--weight-bold);
	line-height: var(--leading-tight);
	text-transform: uppercase;
}

a {
	color: inherit;
}

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

button {
	cursor: pointer;
}

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

[hidden] {
	display: none !important;
}

.site {
	min-height: 100vh;
	display: flex;
	flex-direction: column;
}

.site-main {
	flex: 1;
}

.site-main:focus {
	outline: none;
}

/* ---- Utilities ---------------------------------------------------------- */

/* .screen-reader-text: WooCommerce price HTML uses it and WC's CSS is dequeued on the front page. */
.u-sr-only,
.screen-reader-text,
.u-sr-only-focusable:not(:focus) {
	position: absolute !important;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip: rect(0 0 0 0);
	white-space: nowrap;
	border: 0;
}

.skip-link:focus {
	position: absolute;
	top: var(--space-2);
	left: var(--space-2);
	z-index: calc(var(--z-overlay) + 1);
	padding: var(--space-2) var(--space-4);
	border: var(--border-width) solid var(--color-border-strong);
	background: var(--color-surface);
	color: var(--color-text);
}

@media (max-width: 767.98px) {
	.u-desktop-only {
		display: none !important;
	}
}

@media (min-width: 768px) {
	.u-mobile-only {
		display: none !important;
	}
}
