@font-face {
	font-family: Mallory;
	font-weight: 400;
	font-style: normal;
	font-display: swap;
	src: url("../assets/fonts/Mallory-Book.woff") format("woff");
}

@font-face {
	font-family: Mallory;
	font-weight: 400;
	font-style: italic;
	font-display: swap;
	src: url("../assets/fonts/Mallory-Book-Italic.woff") format("woff");
}

@font-face {
	font-family: Mallory;
	font-weight: 700;
	font-style: normal;
	font-display: swap;
	src: url("../assets/fonts/Mallory-Bold.woff") format("woff");
}

@font-face {
	font-family: Mallory;
	font-weight: 700;
	font-style: italic;
	font-display: swap;
	src: url("../assets/fonts/Mallory-Bold-Italic.woff") format("woff");
}

@font-face {
	font-family: "Pitch Sans";
	font-weight: 500;
	font-style: normal;
	font-display: swap;
	src: url("../assets/fonts/PitchSansWeb-Medium.woff") format("woff");
}

:root {
	--bg: #f3efe6;
	--surface: #fffcf8;
	--ink: #1c1915;
	--muted: #6d655c;
	--line: #e3dcd2;
	--shadow: 0 16px 40px rgba(28, 25, 21, 0.08);
	color-scheme: light;
}

html[data-theme="dark"] {
	--bg: #101010;
	--surface: #191919;
	--ink: #f4f0e8;
	--muted: #b7b0a6;
	--line: #2c2c2c;
	--shadow: 0 16px 40px rgba(0, 0, 0, 0.35);
	color-scheme: dark;
}

*,
*::before,
*::after {
	box-sizing: border-box;
}

html {
	scroll-behavior: smooth;
}

body {
	margin: 0;
	background: var(--bg);
	color: var(--ink);
	font-family: Mallory, "Segoe UI", sans-serif;
	font-size: 17px;
	line-height: 1.6;
}

img {
	max-width: 100%;
}

button,
input {
	font: inherit;
	color: inherit;
}

::selection {
	background: rgba(28, 25, 21, 0.16);
}

html[data-theme="dark"] ::selection {
	background: rgba(244, 240, 232, 0.22);
}

.skip {
	position: absolute;
	left: 1rem;
	top: 0;
	transform: translateY(-120%);
	background: var(--ink);
	color: var(--bg);
	padding: 0.6rem 0.9rem;
	border-radius: 999px;
	z-index: 100;
	text-decoration: none;
}

.skip:focus {
	transform: none;
	top: 0.75rem;
}

.sr-only {
	position: absolute;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	white-space: nowrap;
	border: 0;
}

.icon-button {
	width: 42px;
	height: 42px;
	display: grid;
	place-items: center;
	border-radius: 999px;
	border: 1px solid var(--line);
	background: var(--surface);
	color: var(--ink);
	cursor: pointer;
	padding: 0;
}

.icon-button:hover {
	border-color: var(--ink);
}

.icon-button svg {
	width: 18px;
	height: 18px;
	fill: none;
	stroke: currentColor;
	stroke-width: 1.8;
	stroke-linecap: round;
	stroke-linejoin: round;
}

.icon-button:focus-visible,
a:focus-visible,
button:focus-visible {
	outline: 2px solid var(--ink);
	outline-offset: 3px;
}

@media (prefers-reduced-motion: reduce) {
	html {
		scroll-behavior: auto;
	}
}
