/**
 * Base — reset, editorial typography, layout primitives, a11y.
 */

/* Brand display face — the logo's typeface (Cheltenham Bold Extra Condensed). */
@font-face {
	font-family: "Cheltenham BT";
	src: url("../fonts/cheltenham-bold-xcond.otf") format("opentype");
	font-weight: 700;
	font-style: normal;
	font-display: swap;
}

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

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
.lenis.lenis-smooth [data-lenis-prevent] { overscroll-behavior: contain; }
.lenis.lenis-stopped { overflow: hidden; }

body {
	margin: 0;
	background: var(--bg);
	color: var(--text);
	font-family: var(--font-body);
	font-size: var(--fs-body);
	line-height: var(--lh-body);
	font-feature-settings: "kern" 1, "liga" 1;
	-webkit-font-smoothing: antialiased;
	-moz-osx-font-smoothing: grayscale;
	overflow-x: hidden;
}

img, svg, video, canvas { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; transition: color var(--dur-fast) var(--ease-out); }
ul, ol { margin: 0; padding: 0; list-style: none; }
button { font: inherit; color: inherit; cursor: pointer; border: 0; background: none; }

/* --- Headings (serif display, matches the logo) --- */
h1, h2, h3, h4, h5, h6 {
	font-family: var(--font-display);
	font-weight: 700;
	font-optical-sizing: auto;
	line-height: var(--lh-snug);
	letter-spacing: -0.015em;
	margin: 0 0 0.5em;
	color: inherit;
	text-wrap: balance;
}

p { margin: 0 0 1.2em; }
p:last-child { margin-bottom: 0; }
strong, b { font-weight: 600; }
em { font-style: italic; }

.mega    { font-size: var(--fs-mega); line-height: var(--lh-tight); letter-spacing: -0.025em; font-weight: 700; }
.display { font-size: var(--fs-display); line-height: var(--lh-snug); letter-spacing: -0.02em; font-weight: 700; }

.lead { font-size: var(--fs-lead); color: var(--text-soft); line-height: 1.5; }

/* Accent word in the headline — color only (Cheltenham has no italic). */
.accent-italic { font-style: normal; }
.accent-color  { color: var(--brand); }

/* --- Monospace technical label (the editorial signature) --- */
.label {
	display: inline-flex;
	align-items: center;
	gap: 0.7em;
	font-family: var(--font-label);
	font-size: var(--fs-label);
	font-weight: 600;
	letter-spacing: var(--track-label);
	text-transform: uppercase;
	color: var(--brand-strong);
	margin: 0;
}
.label::before { content: ""; width: 1.9em; height: 1px; background: currentColor; opacity: 0.5; flex: none; }
.label--muted  { color: var(--text-muted); }
.label--invert { color: var(--c-gold); }

/* --- Layout primitives --- */
.container {
	width: 100%;
	max-width: var(--container);
	margin-inline: auto;
	padding-inline: var(--gutter);
}
.container--wide   { max-width: var(--container-wide); }
.container--narrow { max-width: var(--container-narrow); }

.section { padding-block: var(--space-section); position: relative; }
.section--tight { padding-block: var(--space-2xl); }

/* Full-bleed color blocks */
.section--navy   { background: var(--bg-dark); color: var(--text-invert); }
.section--navy h1, .section--navy h2, .section--navy h3 { color: var(--c-white); }
.section--orange { background: var(--c-orange); color: #2a1407; }
.section--orange h1, .section--orange h2, .section--orange h3 { color: #2a1407; }
.section--paper  { background: var(--bg); }
.section--white  { background: var(--bg-alt); }
.section--soft   { background: var(--bg-soft); }

/* Hairline rule used throughout the editorial grid */
.rule { height: 1px; background: var(--rule); border: 0; margin: 0; }
.rule--invert { background: var(--rule-invert); }

/* --- Accessibility helpers --- */
.screen-reader-text {
	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 {
	position: fixed; top: -100px; left: var(--space-sm);
	z-index: var(--z-overlay);
	background: var(--c-dark); color: var(--c-paper);
	padding: 0.75rem 1.25rem; border-radius: var(--radius-sm);
	transition: top var(--dur) var(--ease-out);
}
.skip-link:focus { top: var(--space-sm); }

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

@media (prefers-reduced-motion: reduce) {
	html { scroll-behavior: auto; }
	*, *::before, *::after {
		animation-duration: 0.001ms !important;
		animation-iteration-count: 1 !important;
		transition-duration: 0.001ms !important;
		scroll-behavior: auto !important;
	}
}
