/* Reset + base — minimal, modern, mobile-first. */

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

* { margin: 0; }

html {
	-webkit-text-size-adjust: 100%;
	-moz-tab-size: 4;
	tab-size: 4;
	scroll-behavior: smooth;
}

body {
	min-height: 100vh;
	font-family: var(--font-body);
	font-size: var(--font-size-base);
	line-height: var(--line-height-normal);
	color: var(--color-ink);
	background: var(--color-cream);
	-webkit-font-smoothing: antialiased;
	-moz-osx-font-smoothing: grayscale;
	text-rendering: optimizeLegibility;
}

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

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

p, ul, ol, dl, blockquote, figure, pre, table {
	margin-block: 0 var(--space-4);
}

ul, ol { padding-inline-start: 1.4em; }

a {
	color: var(--color-ink);
	text-decoration: underline;
	text-decoration-thickness: 1.5px;
	text-decoration-color: rgba(20,33,61,0.35);
	text-underline-offset: 3px;
	transition: color var(--motion-duration-fast) var(--motion-ease-standard),
	            text-decoration-color var(--motion-duration-fast) var(--motion-ease-standard);
}
/* Anchor-as-button is common (.btn applied to <a>); the :not() chain prevents this
   global hover from overriding button colors on dark surfaces. Same chain on §footer
   in components.css must match this specificity (0,3,2). See Pick3-Lessons §5. */
a:not(.btn):not(.btn *):hover { color: var(--color-ink); text-decoration-color: var(--color-mustard); }
a:focus-visible {
	outline: 2px solid var(--color-mustard);
	outline-offset: 2px;
	border-radius: 2px;
}

h1, h2, h3, h4, h5, h6 {
	font-family: var(--font-display);
	font-weight: 600;
	line-height: var(--line-height-tight);
	letter-spacing: -0.02em;
	color: var(--color-ink);
	margin-block: 0 var(--space-4);
	/* Avoid orphan words on the last line of multi-line headings (Chromium 117+,
	   Safari 17.5+, Firefox 124+). Older browsers ignore the value gracefully. */
	text-wrap: pretty;
}

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

@media (min-width: 1024px) {
	h1 { font-size: var(--font-size-4xl); }
}

p {
	max-width: var(--max-width-content);
	color: var(--color-ink-soft);
}

article p, .prose p { color: var(--color-ink); }

strong { font-weight: 600; }
em { font-style: italic; }

hr {
	border: 0;
	height: 1px;
	background: var(--color-divider);
	margin-block: var(--space-12);
}

::selection { background: var(--color-mustard-soft); color: var(--color-ink); }

/* Layout container */
.container {
	max-width: var(--max-width-wide);
	margin-inline: auto;
	padding-inline: var(--space-4);
}
@media (min-width: 768px)  { .container { padding-inline: var(--space-6); } }
@media (min-width: 1024px) { .container { padding-inline: var(--space-8); } }
.container--full { max-width: var(--max-width-full); }
.container--narrow { max-width: var(--max-width-content); }

/* Section spacing */
section { padding-block: var(--space-16); }
@media (min-width: 1024px) { section { padding-block: var(--space-24); } }

/* Skip link */
.skip-link {
	position: absolute;
	top: -100px;
	left: var(--space-4);
	background: var(--color-ink);
	color: var(--color-cream);
	padding: var(--space-3) var(--space-6);
	z-index: 1000;
	border-radius: var(--radius-md);
	text-decoration: none;
}
.skip-link:focus { top: var(--space-4); }

/* Visually-hidden helper */
.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;
}

/* Admin-bar offset for sticky header — Master CLAUDE.md §13 / design fix list */
body.admin-bar .site-header { top: 32px; }
@media (max-width: 782px) {
	body.admin-bar .site-header { top: 46px; }
}
