/*
 * INK — Typographic minimal
 *
 * Feels like a well-typeset personal document.
 * Serif headings, generous whitespace, near-zero decoration.
 * Inspired by academic papers and literary blogs.
 */

:root {
	--bg: #fdfdfc;
	--fg: #1a1a1a;
	--muted: #6b6b6b;
	--card-bg: transparent;
	--border: #d4d4d4;
	--accent: #1a1a1a;
	--maxw: 680px;
	--heading-font: Charter, 'Bitstream Charter', 'Sitka Text', Cambria, serif;
	--body-font:
		-apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
	--mono-font: 'Berkeley Mono', 'IBM Plex Mono', 'Fira Code', ui-monospace, monospace;
}

@media (prefers-color-scheme: dark) {
	:root {
		--bg: #161616;
		--fg: #e0ddd8;
		--muted: #8a8a8a;
		--border: #333;
		--accent: #e0ddd8;
	}
}

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

html {
	height: 100%;
}

body {
	margin: 0;
	background: var(--bg);
	color: var(--fg);
	font-family: var(--body-font);
	font-size: 17px;
	line-height: 1.7;
	-webkit-font-smoothing: antialiased;
}

h1,
h2,
h3 {
	font-family: var(--heading-font);
	font-weight: 400;
	line-height: 1.25;
	letter-spacing: -0.01em;
}

h1 {
	font-size: 2rem;
	margin: 0 0 0.4em;
}

h2 {
	font-size: 1.4rem;
	margin: 1.8em 0 0.5em;
}

a {
	color: var(--fg);
	text-decoration-thickness: 1px;
	text-underline-offset: 3px;
	text-decoration-color: var(--muted);
}

a:hover {
	text-decoration-color: var(--fg);
}

.container {
	max-width: var(--maxw);
	margin: 0 auto;
	padding: 48px 24px 80px;
}

.skip-link {
	position: absolute;
	left: 10px;
	top: 10px;
	padding: 8px 12px;
	background: var(--bg);
	border: 1px solid var(--border);
	transform: translateY(-200%);
	transition: transform 160ms ease;
}

.skip-link:focus {
	transform: translateY(0);
}

.topbar {
	display: flex;
	align-items: baseline;
	justify-content: space-between;
	gap: 16px;
	margin-bottom: 48px;
	padding-bottom: 16px;
	border-bottom: 1px solid var(--border);
}

.brand {
	font-family: var(--heading-font);
	font-size: 1.15rem;
	text-decoration: none;
	letter-spacing: 0.02em;
}

.nav {
	display: flex;
	flex-wrap: wrap;
	gap: 6px 18px;
	justify-content: flex-end;
}

.nav a {
	text-decoration: none;
	color: var(--muted);
	font-size: 0.92rem;
}

.nav a:hover {
	color: var(--fg);
}

.nav a[aria-current='page'] {
	color: var(--fg);
	text-decoration: underline;
	text-decoration-thickness: 1.5px;
	text-underline-offset: 4px;
}

.card {
	background: var(--card-bg);
	border: none;
	padding: 0;
}

.grid {
	display: grid;
	gap: 32px;
}

@media (min-width: 860px) {
	.grid.cols-2 {
		grid-template-columns: 1fr 1fr;
	}
}

.muted {
	color: var(--muted);
}

.footer {
	margin-top: 64px;
	padding-top: 16px;
	border-top: 1px solid var(--border);
	color: var(--muted);
	font-size: 0.85rem;
}

code,
pre {
	font-family: var(--mono-font);
	font-size: 0.9em;
}

p {
	margin: 0 0 1em;
}

ul,
ol {
	padding-left: 1.4em;
}

li {
	margin-bottom: 0.3em;
}
