/**
 * Base typography and document defaults
 * html/body, headings, paragraphs, links, lists, inline text, code/pre,
 * blockquote, hr, ::selection.
 */

html {
	font-size: 16px;
	scroll-behavior: smooth;
}

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

body {
	font-size: 1rem;
	line-height: 1.65;
	color: var(--brand-text);
	background-color: var(--brand-page);
	font-family: var(--font-sans);
	-webkit-font-smoothing: antialiased;
	-moz-osx-font-smoothing: grayscale;
}

::selection {
	background: color-mix(in srgb, var(--brand-purple) 28%, transparent);
	color: var(--brand-black);
}

/* Headings */
h1, h2, h3, h4, h5, h6 {
	font-weight: 600;
	letter-spacing: -0.02em;
	line-height: 1.15;
	margin-bottom: 0.5em;
	color: var(--brand-black);
}

h1 {
	font-size: clamp(2rem, 4vw + 1rem, 2.75rem);
}

h2 {
	font-size: clamp(1.65rem, 2.5vw + 1rem, 2.125rem);
}

h3 {
	font-size: clamp(1.35rem, 1.5vw + 1rem, 1.75rem);
}

h4 {
	font-size: clamp(1.2rem, 1vw + 1rem, 1.5rem);
}

h5 {
	font-size: 1.2rem;
}

h6 {
	font-size: 1rem;
}

/* Paragraphs */
p {
	margin-bottom: 1em;
}

/* Links */
a {
	color: var(--brand-purple);
	text-decoration: underline;
	text-decoration-thickness: 1px;
	text-underline-offset: 0.2em;
	text-decoration-color: color-mix(in srgb, var(--brand-purple) 55%, transparent);
	transition: color 0.2s var(--ease-out), text-decoration-color 0.2s var(--ease-out);
}

a:visited {
	color: var(--brand-purple);
}

a:hover {
	color: var(--brand-black);
	text-decoration-color: color-mix(in srgb, var(--brand-black) 40%, transparent);
}

a:focus-visible {
	outline: 2px solid var(--brand-purple);
	outline-offset: 3px;
	border-radius: 2px;
}

/* Lists */
ul, ol {
	margin-bottom: 1em;
	padding-left: 2em;
}

ul {
	list-style-type: disc;
}

ol {
	list-style-type: decimal;
}

li {
	margin-bottom: 0.5em;
}

/* Inline text */
strong, b {
	font-weight: 700;
}

em, i {
	font-style: italic;
}

small {
	font-size: 0.875rem;
}

code {
	font-family: var(--font-mono);
	font-size: 0.9em;
	background-color: var(--brand-surface);
	padding: 0.2em 0.45em;
	border-radius: var(--radius-sm);
}

pre {
	font-family: var(--font-mono);
	font-size: 0.9em;
	background-color: var(--brand-surface);
	padding: 1.15em 1.25em;
	border-radius: var(--radius-md);
	border: 1px solid var(--brand-border);
	overflow-x: auto;
	margin-bottom: 1em;
	box-shadow: var(--shadow-sm);
}

blockquote {
	border-left: 3px solid var(--brand-mint);
	padding-left: 1.15em;
	padding-top: 0.75em;
	padding-bottom: 0.75em;
	margin: 1.25em 0;
	font-style: italic;
	color: var(--brand-text-muted);
	border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
	background: color-mix(in srgb, var(--brand-surface) 65%, var(--brand-white));
}

hr {
	border: none;
	height: 1px;
	margin: 2.5em 0;
	background: linear-gradient(90deg, transparent, var(--brand-border) 20%, var(--brand-border) 80%, transparent);
}

/* Modulus Pro display face — used by .nav-logo and editorial headings */
@font-face {
	font-family: 'Modulus Pro Bold';
	src: url('../fonts/Arkitype-Modulus-Pro-Bold.otf') format('opentype');
	font-weight: bold;
	font-style: normal;
	font-display: swap;
}
