/* ==========================================================================
   Konsepto — main stylesheet
   1. Tokens
   2. Reset & base
   3. Header
   4. Hero (grid + masks + headline)
   5. Scroll sections
   6. Pages / posts
   7. Footer
   8. Motion & responsive
   ========================================================================== */

/* 1. Tokens ---------------------------------------------------------------- */
:root {
	--k-ink: #000;
	--k-paper: #fff;
	--k-accent: #ff4d12;
	--k-mute: #767676;
	--k-line: #e4e4e4;

	--k-display: "Archivo", "Helvetica Neue", Helvetica, Arial, sans-serif;
	--k-mono: "IBM Plex Mono", ui-monospace, "SF Mono", Menlo, Consolas, monospace;

	--k-header-h: 44px;
	--k-gap: 4px;
	--k-pad: clamp(12px, 2.2vw, 28px);

	--k-ease: cubic-bezier(0.16, 1, 0.3, 1);

	/* Portfolio art is desaturated, then washed with these. Multiply over a
	   white logo ground reproduces the tone exactly. */
	--k-wash-lilac: #c6b4ee;
	--k-wash-coral: #ff6a3c;
	--k-wash-sage: #b7c5b4;
	--k-wash-magenta: #e86ab0;
	--k-wash-mist: #e2e4e2;
	--k-wash-strength: 0.92;
}

/* 2. Reset & base ---------------------------------------------------------- */
*,
*::before,
*::after { box-sizing: border-box; }

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

body {
	margin: 0;
	background: var(--k-paper);
	color: var(--k-ink);
	font-family: var(--k-display);
	font-size: 16px;
	line-height: 1.4;
	-webkit-font-smoothing: antialiased;
	overflow-x: hidden;
}

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

a { color: inherit; text-decoration: none; }

h1, h2, h3, p, ul, figure { margin: 0; padding: 0; }
ul { list-style: none; }

button {
	font: inherit;
	color: inherit;
	background: none;
	border: 0;
	padding: 0;
	cursor: pointer;
}

.screen-reader-text {
	position: absolute !important;
	width: 1px; height: 1px;
	margin: -1px; padding: 0;
	overflow: hidden;
	clip: rect(0 0 0 0);
	clip-path: inset(50%);
	white-space: nowrap;
	border: 0;
}

.skip-link:focus {
	position: fixed !important;
	top: 8px; left: 8px;
	z-index: 200;
	width: auto; height: auto;
	clip: auto; clip-path: none;
	padding: 10px 16px;
	background: var(--k-ink);
	color: var(--k-paper);
}

:focus-visible { outline: 2px solid var(--k-accent); outline-offset: 3px; }

/* Small mono label used throughout */
.eyebrow,
.tile__label,
.hero__footnote,
.scroll-cue,
.site-footer__meta,
.index-row__no {
	font-family: var(--k-mono);
	font-size: 10px;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	line-height: 1.5;
}

/* The "+" glyph, drawn so it can rotate on hover */
.plus {
	position: relative;
	display: inline-block;
	width: 9px;
	height: 9px;
	flex: none;
	transition: transform 0.4s var(--k-ease);
}
.plus::before,
.plus::after {
	content: "";
	position: absolute;
	inset: 50% 0 auto 0;
	height: 1.5px;
	background: currentColor;
	transform: translateY(-50%);
}
.plus::after { transform: translateY(-50%) rotate(90deg); }

a:hover > .plus,
li:hover .plus { transform: rotate(90deg); }

/* 3. Header ---------------------------------------------------------------- */
.site-header {
	position: fixed;
	inset: 0 0 auto 0;
	z-index: 100;
	height: var(--k-header-h);
	display: flex;
	align-items: stretch;
	justify-content: space-between;
	gap: 12px;
}

.site-header__left {
	display: flex;
	align-items: stretch;
	flex: none;
	min-width: 0;
	z-index: 2;
}

.brand {
	display: flex;
	align-items: center;
	flex: none;
	padding: 0 18px;
	background: var(--k-ink);
	color: var(--k-paper);
	font-weight: 600;
	font-size: 17px;
	letter-spacing: -0.02em;
}
.brand__img { max-height: calc(var(--k-header-h) - 16px); width: auto; }
.brand__mark {
	display: block;
	line-height: 1;
	font-weight: 600;
	letter-spacing: -0.02em;
	white-space: nowrap;
}

.header-cta {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 10px;
	min-width: min(38vw, 320px);
	padding: 0 20px;
	background: var(--k-accent);
	color: #fff;
	font-weight: 600;
	font-size: 14px;
	letter-spacing: -0.01em;
	transition: filter 0.3s ease;
}
.header-cta:hover { filter: brightness(1.08); }

.header-cta--inline {
	display: inline-flex;
	height: 40px;
	min-width: 0;
	margin-top: 24px;
}

.site-nav {
	display: flex;
	align-items: center;
	padding-right: var(--k-pad);
}

.nav__list {
	display: flex;
	align-items: center;
	gap: clamp(18px, 3vw, 48px);
}

.nav__list a {
	position: relative;
	display: inline-flex;
	align-items: center;
	gap: 8px;
	font-size: 14px;
	font-weight: 500;
	letter-spacing: -0.01em;
	padding: 4px 0;
}

/* "+" affordance on parents, mirroring the reference nav */
.nav__list .menu-item-has-children > a::after {
	content: "+";
	font-family: var(--k-mono);
	font-size: 13px;
	display: inline-block;
	transition: transform 0.4s var(--k-ease);
}
.nav__list .menu-item-has-children:hover > a::after { transform: rotate(90deg); }

.nav__list a::before {
	content: "";
	position: absolute;
	left: 0; right: 0; bottom: 0;
	height: 1px;
	background: currentColor;
	transform: scaleX(0);
	transform-origin: right;
	transition: transform 0.45s var(--k-ease);
}
.nav__list a:hover::before,
.nav__list .current-menu-item > a::before {
	transform: scaleX(1);
	transform-origin: left;
}

/* Sub menus */
.nav__list > li { position: relative; }
.nav__list .sub-menu {
	position: absolute;
	top: 100%;
	left: 0;
	min-width: 180px;
	padding: 12px 14px;
	background: var(--k-paper);
	border: 1px solid var(--k-line);
	display: grid;
	gap: 6px;
	opacity: 0;
	visibility: hidden;
	transform: translateY(-6px);
	transition: opacity 0.3s ease, transform 0.3s var(--k-ease), visibility 0.3s;
}
.nav__list > li:hover > .sub-menu,
.nav__list > li:focus-within > .sub-menu {
	opacity: 1;
	visibility: visible;
	transform: translateY(0);
}

.nav-toggle { display: none; }

/* WordPress renders its admin bar above the header when logged in. */
.admin-bar .site-header { top: 32px; }

/* 4. Hero ------------------------------------------------------------------ */
.hero {
	/* Lighter wash than the work grid so the hero artwork reads brighter */
	--k-wash-strength: 0.4;
	min-height: 100svh;
	padding-top: var(--k-header-h);
	display: flex;
	flex-direction: column;
}

/* -- Grid of masked tiles -- */
.hero__grid {
	display: grid;
	grid-template-columns: repeat(12, 1fr);
	gap: var(--k-gap);
	grid-auto-rows: clamp(122px, min(18.5vw, 25vh), 300px);
	padding-bottom: var(--k-gap);
}

/* An 8-tile repeating rhythm: 3+2+4+3 / 4+3+3+2 = two flush rows */
.tile { grid-column: span 3; }
.tile:nth-child(8n + 2) { grid-column: span 2; }
.tile:nth-child(8n + 3) { grid-column: span 4; }
.tile:nth-child(8n + 4) { grid-column: span 3; }
.tile:nth-child(8n + 5) { grid-column: span 4; }
.tile:nth-child(8n + 6) { grid-column: span 3; }
.tile:nth-child(8n + 7) { grid-column: span 3; }
.tile:nth-child(8n + 0) { grid-column: span 2; }

.tile {
	position: relative;
	display: block;
	overflow: hidden;
	isolation: isolate;
	background: #f0efed;
}

/* The mask: a clip-path wipe that opens on load */
.tile__mask {
	position: absolute;
	inset: 0;
	display: block;
	overflow: hidden;
	clip-path: inset(0 0 0 0);
	transition: clip-path 1s var(--k-ease);
	transition-delay: calc(var(--i, 0) * 70ms);
}

.tile__img,
.tile__fill {
	position: absolute;
	inset: 0;
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
	object-position: center;
	transform: scale(1);
	filter: grayscale(1) contrast(0.92) brightness(1.4);
	transition: transform 1.4s var(--k-ease), filter 0.6s ease;
	transition-delay: calc(var(--i, 0) * 70ms);
}

/* The colour wash. Multiply keeps the artwork's blacks black and turns the
   white logo grounds into the gradient's own tones. */
.tile__mask::after {
	content: "";
	position: absolute;
	inset: 0;
	z-index: 1;
	pointer-events: none;
	mix-blend-mode: multiply;
	opacity: var(--k-wash-strength);
	transition: opacity 0.6s ease;
	background:
		radial-gradient(120% 95% at 12% 18%, var(--k-wash-lilac) 0%, transparent 62%),
		radial-gradient(105% 85% at 88% 26%, var(--k-wash-coral) 0%, transparent 58%),
		radial-gradient(115% 100% at 62% 96%, var(--k-wash-sage) 0%, transparent 62%),
		var(--k-wash-mist);
}

/* Rotate the composition so no two neighbours share a wash */
.tile:nth-child(4n + 2) .tile__mask::after {
	background:
		radial-gradient(110% 90% at 82% 14%, var(--k-wash-magenta) 0%, transparent 60%),
		radial-gradient(120% 95% at 18% 72%, var(--k-wash-lilac) 0%, transparent 64%),
		radial-gradient(100% 80% at 55% 8%, var(--k-wash-sage) 0%, transparent 55%),
		var(--k-wash-mist);
}
.tile:nth-child(4n + 3) .tile__mask::after {
	background:
		radial-gradient(125% 100% at 50% 92%, var(--k-wash-coral) 0%, transparent 58%),
		radial-gradient(100% 90% at 8% 12%, var(--k-wash-sage) 0%, transparent 60%),
		radial-gradient(110% 85% at 92% 60%, var(--k-wash-lilac) 0%, transparent 62%),
		var(--k-wash-mist);
}
.tile:nth-child(4n + 0) .tile__mask::after {
	background:
		radial-gradient(115% 95% at 25% 88%, var(--k-wash-magenta) 0%, transparent 58%),
		radial-gradient(120% 90% at 78% 22%, var(--k-wash-sage) 0%, transparent 62%),
		radial-gradient(100% 95% at 45% 45%, var(--k-wash-lilac) 0%, transparent 66%),
		var(--k-wash-mist);
}

/* Hover lifts the wash and the artwork returns in full colour */
.tile:hover .tile__img,
.tile:focus-visible .tile__img { filter: none; }
.tile:hover .tile__mask::after,
.tile:focus-visible .tile__mask::after { opacity: 0; }

/* Closed state, held until JS lifts .k-preload */
.k-preload .tile__mask { clip-path: inset(0 100% 0 0); }
.k-preload .tile:nth-child(even) .tile__mask { clip-path: inset(100% 0 0 0); }
.k-preload .tile__img,
.k-preload .tile__fill { transform: scale(1.22); }

.tile__label {
	position: absolute;
	left: 8px;
	bottom: 8px;
	z-index: 3;
	padding: 4px 7px;
	background: rgba(255, 255, 255, 0.92);
	color: var(--k-ink);
	opacity: 0;
	transform: translateY(4px);
	transition: opacity 0.5s ease, transform 0.5s var(--k-ease);
	transition-delay: calc(600ms + var(--i, 0) * 70ms);
}
body:not(.k-preload) .tile__label { opacity: 1; transform: none; }

a.tile:hover .tile__img,
a.tile:hover .tile__fill { transform: scale(1.05); }

/* Placeholder gradients — stand in until real project images are set */
.tile__fill { background: linear-gradient(120deg, #d9d9d9, #f2f2f2); }
.tile--ramp-1 .tile__fill { background: linear-gradient(135deg, #a3b1bf 0%, #c3b2e6 38%, #ff8b6f 72%, #e6ebe6 100%); }
.tile--ramp-2 .tile__fill { background: linear-gradient(160deg, #e9e9e9 0%, #cfcfcf 55%, #b8b8b8 100%); }
.tile--ramp-3 .tile__fill { background: linear-gradient(200deg, #fdfaf3 0%, #efe7d8 60%, #cfc7bb 100%); }
.tile--ramp-4 .tile__fill { background: linear-gradient(120deg, #ff3d00 0%, #ff7a2f 45%, #ff2f92 100%); }
.tile--ramp-5 .tile__fill { background: linear-gradient(140deg, #a8d5c8 0%, #c9b6e4 45%, #ff8b6a 100%); }
.tile--ramp-6 .tile__fill { background: linear-gradient(90deg, #ffb703 0%, #fb8500 60%, #ffd28a 100%); }
.tile--ramp-7 .tile__fill { background: linear-gradient(180deg, #8895a1 0%, #b3c0cd 70%, #e9eef2 100%); }
.tile--ramp-8 .tile__fill { background: linear-gradient(60deg, #f6f2ec 0%, #e2d9cd 50%, #c2b6a5 100%); }

/* Grain overlay so the placeholder ramps read as texture, not flat CSS */
.tile__fill::after {
	content: "";
	position: absolute;
	inset: 0;
	opacity: 0.2;
	mix-blend-mode: overlay;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='3'/%3E%3C/filter%3E%3Crect width='140' height='140' filter='url(%23n)' opacity='0.6'/%3E%3C/svg%3E");
}

/* -- Headline block -- */
.hero__copy {
	flex: 1;
	display: grid;
	grid-template-columns: repeat(12, 1fr);
	align-content: center;
	gap: clamp(14px, 2vw, 24px) var(--k-gap);
	padding: clamp(16px, 3vw, 40px) var(--k-pad);
}

.hero__lede {
	grid-column: 1 / span 4;
	align-self: start;
	font-size: clamp(13px, 1.05vw, 15px);
	line-height: 1.45;
	letter-spacing: -0.01em;
}

.hero__title {
	grid-column: 5 / -1;
	font-size: clamp(40px, min(8.2vw, 11.5vh), 132px);
	line-height: 0.92;
	letter-spacing: -0.045em;
	font-weight: 600;
}

/* Line masks for the reveal */
.line {
	display: block;
	overflow: hidden;
}
.line__in {
	display: block;
	transform: translateY(0);
	opacity: 1;
	transition: transform 1s var(--k-ease), opacity 1s var(--k-ease);
	transition-delay: calc(420ms + var(--d, 0ms));
}
.k-preload .line__in {
	transform: translateY(110%);
	opacity: 0;
}
.hero__lede .line__in { transition-delay: 620ms; }

/* -- Bottom bar -- */
.hero__foot {
	display: grid;
	grid-template-columns: 1fr auto 1fr;
	align-items: end;
	gap: 16px;
	padding: 0 var(--k-pad) clamp(16px, 2.4vw, 28px);
	opacity: 1;
	transition: opacity 0.8s ease 900ms;
}
.k-preload .hero__foot { opacity: 0; }

.hero__footnote span { display: block; }

.scroll-cue {
	justify-self: center;
	display: inline-flex;
	align-items: center;
	gap: 8px;
}
.scroll-cue::after {
	content: "";
	width: 0;
	height: 1px;
	background: currentColor;
	transition: width 0.5s var(--k-ease);
}
.scroll-cue:hover::after { width: 24px; }

.scroll-arrow {
	justify-self: end;
	width: 14px;
	animation: k-bob 2.4s var(--k-ease) infinite;
}
.scroll-arrow svg { width: 100%; }

@keyframes k-bob {
	0%, 100% { transform: translateY(0); }
	50% { transform: translateY(6px); }
}

/* 5. Scroll sections ------------------------------------------------------- */
[data-reveal] {
	opacity: 0;
	transform: translateY(24px);
	transition: opacity 0.9s var(--k-ease), transform 0.9s var(--k-ease);
}
[data-reveal].is-in {
	opacity: 1;
	transform: none;
}

.statement {
	padding: clamp(80px, 14vh, 180px) var(--k-pad);
	border-top: 1px solid var(--k-line);
}
.statement__inner {
	max-width: 1100px;
	display: grid;
	gap: clamp(24px, 4vw, 48px);
}
.statement__body {
	font-size: clamp(24px, 3.4vw, 52px);
	line-height: 1.1;
	letter-spacing: -0.035em;
	font-weight: 500;
	text-wrap: balance;
}

.eyebrow { color: var(--k-mute); }

.index-list {
	padding: 0 var(--k-pad) clamp(80px, 12vh, 160px);
	display: grid;
	gap: 24px;
}

.index-row { border-top: 1px solid var(--k-line); }
.index-row:last-child { border-bottom: 1px solid var(--k-line); }

.index-row a {
	display: grid;
	grid-template-columns: 60px 1fr auto;
	align-items: center;
	gap: 16px;
	padding: clamp(18px, 2.6vw, 32px) 0;
	transition: padding-left 0.5s var(--k-ease), color 0.3s ease;
}
.index-row a:hover {
	padding-left: 16px;
	color: var(--k-accent);
}
.index-row__no { color: var(--k-mute); }
.index-row__title {
	font-size: clamp(22px, 3.2vw, 44px);
	letter-spacing: -0.035em;
	line-height: 1.05;
	font-weight: 500;
}

/* 6. Pages / posts --------------------------------------------------------- */
.page-head {
	padding: calc(var(--k-header-h) + clamp(60px, 12vh, 140px)) var(--k-pad) clamp(28px, 5vw, 56px);
	display: grid;
	gap: 12px;
}
.page-head--tall { min-height: 70svh; align-content: center; }
.page-head__title {
	font-size: clamp(36px, 7vw, 104px);
	line-height: 0.95;
	letter-spacing: -0.04em;
	font-weight: 600;
	max-width: 16ch;
}

.single__media { margin: 0 var(--k-pad) clamp(28px, 5vw, 56px); }
.single__media img { width: 100%; }

.prose {
	max-width: 720px;
	margin: 0 var(--k-pad) clamp(80px, 12vh, 140px);
	font-size: 17px;
	line-height: 1.6;
	display: grid;
	gap: 1.1em;
}
.prose h2 { font-size: clamp(24px, 3vw, 34px); letter-spacing: -0.03em; line-height: 1.1; margin-top: 0.6em; }
.prose h3 { font-size: clamp(19px, 2.2vw, 24px); letter-spacing: -0.02em; }
.prose a { text-decoration: underline; text-underline-offset: 3px; }
.prose img { margin: 0.4em 0; }

.entry-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
	gap: clamp(24px, 3vw, 44px);
	padding: 0 var(--k-pad) clamp(80px, 12vh, 140px);
}
.card__media { display: block; overflow: hidden; margin-bottom: 14px; }
.card__img { width: 100%; transition: transform 0.8s var(--k-ease); }
.card:hover .card__img { transform: scale(1.04); }
.card__title { font-size: 22px; letter-spacing: -0.025em; line-height: 1.15; }
.card__excerpt { color: var(--k-mute); font-size: 14px; margin-top: 6px; }

.empty { padding: 0 var(--k-pad) 120px; color: var(--k-mute); }

.pagination { padding: 0 var(--k-pad) 100px; font-family: var(--k-mono); font-size: 12px; }
.pagination .page-numbers { padding: 0 8px; }

/* Portfolio archive — the hero's mask language at a readable pace */
.work-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr));
	gap: clamp(20px, 2.6vw, 40px) var(--k-gap);
	padding: 0 var(--k-pad) clamp(80px, 12vh, 140px);
}

.work-card__mask {
	position: relative;
	display: block;
	overflow: hidden;
	isolation: isolate;
	aspect-ratio: 1 / 1;
	background: #f0efed;
	clip-path: inset(0 100% 0 0);
	transition: clip-path 1s var(--k-ease);
}
.work-card.is-in .work-card__mask { clip-path: inset(0 0 0 0); }

.work-card__img,
.work-card__fill {
	width: 100%;
	height: 100%;
	object-fit: cover;
	object-position: center;
	transform: scale(1.12);
	filter: grayscale(1) contrast(1.06);
	transition: transform 1.1s var(--k-ease), filter 0.6s ease;
}

/* Same wash as the homepage grid, alternating so the column reads varied */
.work-card__mask::after {
	content: "";
	position: absolute;
	inset: 0;
	z-index: 1;
	pointer-events: none;
	mix-blend-mode: multiply;
	opacity: var(--k-wash-strength);
	transition: opacity 0.6s ease;
	background:
		radial-gradient(120% 95% at 12% 18%, var(--k-wash-lilac) 0%, transparent 62%),
		radial-gradient(105% 85% at 88% 26%, var(--k-wash-coral) 0%, transparent 58%),
		radial-gradient(115% 100% at 62% 96%, var(--k-wash-sage) 0%, transparent 62%),
		var(--k-wash-mist);
}
.work-card:nth-child(3n + 2) .work-card__mask::after {
	background:
		radial-gradient(110% 90% at 82% 14%, var(--k-wash-magenta) 0%, transparent 60%),
		radial-gradient(120% 95% at 18% 72%, var(--k-wash-lilac) 0%, transparent 64%),
		radial-gradient(100% 80% at 55% 8%, var(--k-wash-sage) 0%, transparent 55%),
		var(--k-wash-mist);
}
.work-card:nth-child(3n + 3) .work-card__mask::after {
	background:
		radial-gradient(125% 100% at 50% 92%, var(--k-wash-coral) 0%, transparent 58%),
		radial-gradient(100% 90% at 8% 12%, var(--k-wash-sage) 0%, transparent 60%),
		radial-gradient(110% 85% at 92% 60%, var(--k-wash-lilac) 0%, transparent 62%),
		var(--k-wash-mist);
}
.work-card.is-in .work-card__img,
.work-card.is-in .work-card__fill { transform: none; }
.work-card__fill { background: linear-gradient(135deg, #ededed, #d9d9d9); }

.work-card a:hover .work-card__img {
	transform: scale(1.04);
	filter: none;
}
.work-card a:hover .work-card__mask::after,
.work-card a:focus-visible .work-card__mask::after { opacity: 0; }

.work-card__foot {
	display: flex;
	align-items: baseline;
	justify-content: space-between;
	gap: 12px;
	padding-top: 12px;
}
.work-card__title {
	font-size: 17px;
	letter-spacing: -0.025em;
	line-height: 1.2;
}
.work-card__label {
	font-family: var(--k-mono);
	font-size: 10px;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: var(--k-mute);
	flex: none;
}
.work-card a:hover .work-card__title { color: var(--k-accent); }

/* Work archive head */
.page-head--work { max-width: 1200px; }
.page-head__summary {
	max-width: 46ch;
	font-size: clamp(15px, 1.5vw, 19px);
	line-height: 1.5;
	letter-spacing: -0.01em;
	color: var(--k-mute);
}
.page-head__count {
	font-family: var(--k-mono);
	font-size: 10px;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: var(--k-mute);
}

/* Single project ----------------------------------------------------------- */
.project-head {
	padding: calc(var(--k-header-h) + clamp(60px, 12vh, 140px)) var(--k-pad) clamp(24px, 4vw, 44px);
	display: grid;
	gap: 14px;
}
.project-head__title {
	font-size: clamp(36px, 7vw, 104px);
	line-height: 0.95;
	letter-spacing: -0.04em;
	font-weight: 600;
	max-width: 16ch;
}
.project-head__summary {
	max-width: 52ch;
	font-size: clamp(16px, 1.7vw, 21px);
	line-height: 1.5;
	letter-spacing: -0.01em;
	color: var(--k-mute);
}

/* The spec list: mono labels, one row per fact */
.project-spec {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
	gap: 1px;
	margin: 0 var(--k-pad) clamp(32px, 5vw, 60px);
	background: var(--k-line);
	border: 1px solid var(--k-line);
}
.project-spec__row {
	display: grid;
	gap: 6px;
	padding: 16px 18px;
	background: var(--k-paper);
}
.project-spec dt {
	font-family: var(--k-mono);
	font-size: 10px;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: var(--k-mute);
}
.project-spec dd {
	margin: 0;
	font-size: 15px;
	letter-spacing: -0.01em;
	line-height: 1.35;
}
.project-spec__link {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	color: var(--k-accent);
}
.project-spec__link:hover { text-decoration: underline; text-underline-offset: 3px; }

.project-lead { margin: 0 var(--k-pad) clamp(28px, 4vw, 56px); }
.project-lead img { width: 100%; }

/* Project body: a run of Gutenberg images, each with a caption paragraph.
   The paragraphs are set as mono captions rather than body copy. */
.project-body {
	--project-gap: clamp(28px, 4vw, 64px);
	display: grid;
	gap: var(--project-gap);
	max-width: 1100px;
	margin: 0 var(--k-pad) clamp(80px, 12vh, 140px);
}
.project-body > * { margin: 0; }

.project-body figure { display: grid; gap: 10px; }
.project-body img {
	width: 100%;
	height: auto;
	background: #f0efed;
}
.project-body video,
.project-body iframe { width: 100%; height: auto; display: block; }

/* Caption paragraphs sit tight under the image they describe */
.project-body .wp-block-paragraph {
	/* Pull the caption back up against the image it describes. */
	margin-top: calc(10px - var(--project-gap));
	font-family: var(--k-mono);
	font-size: 10px;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: var(--k-mute);
	line-height: 1.5;
}
.project-body figcaption {
	font-family: var(--k-mono);
	font-size: 10px;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: var(--k-mute);
}
.project-body .wp-block-spacer { display: none; }
.project-body a { color: var(--k-accent); text-decoration: underline; text-underline-offset: 3px; }

/* Previous / next */
.project-nav {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
	gap: 1px;
	margin: 0 var(--k-pad) clamp(80px, 12vh, 140px);
	background: var(--k-line);
	border-top: 1px solid var(--k-line);
}
.project-nav__item {
	display: grid;
	gap: 8px;
	padding: clamp(20px, 3vw, 36px) 0;
	background: var(--k-paper);
	transition: color 0.3s ease;
}
.project-nav__item--next { text-align: right; justify-items: end; }
.project-nav__title {
	font-size: clamp(20px, 2.6vw, 32px);
	letter-spacing: -0.03em;
	line-height: 1.1;
	font-weight: 500;
}
.project-nav__item:hover { color: var(--k-accent); }

/* Archive closer */
.work-cta {
	display: grid;
	gap: 14px;
	justify-items: start;
	padding: clamp(60px, 10vh, 120px) var(--k-pad) clamp(80px, 12vh, 140px);
	border-top: 1px solid var(--k-line);
}
.work-cta__line {
	font-size: clamp(24px, 3.4vw, 52px);
	letter-spacing: -0.035em;
	line-height: 1.05;
	font-weight: 500;
	max-width: 18ch;
}

/* 7. Footer ---------------------------------------------------------------- */
.site-footer {
	border-top: 1px solid var(--k-line);
	padding: clamp(40px, 6vw, 72px) var(--k-pad) clamp(24px, 3vw, 40px);
}
.site-footer__inner { display: grid; gap: clamp(24px, 4vw, 40px); }
.site-footer__mark {
	font-size: clamp(34px, 9vw, 120px);
	line-height: 0.9;
	letter-spacing: -0.05em;
	font-weight: 600;
}
.footer-nav {
	display: flex;
	flex-wrap: wrap;
	gap: 20px;
	font-size: 14px;
}
.footer-nav a:hover { color: var(--k-accent); }
.site-footer__meta { color: var(--k-mute); }

/* 8. Motion & responsive --------------------------------------------------- */
@media (max-width: 1024px) {
	.hero__lede { grid-column: 1 / -1; }
	.hero__title { grid-column: 1 / -1; }
	.hero__grid { grid-auto-rows: clamp(118px, min(19vw, 23vh), 250px); }
}

@media (max-width: 780px) {
	:root { --k-header-h: 44px; }

	.header-cta { display: none; }

	/* The bar scrolls over artwork on a phone; without a ground the nav
	   toggle's black bars vanish against a dark tile. */
	.site-header {
		background: var(--k-paper);
		border-bottom: 1px solid var(--k-line);
	}

	.site-nav {
		position: fixed;
		inset: var(--k-header-h) 0 auto 0;
		padding: 24px var(--k-pad) 32px;
		background: var(--k-paper);
		border-bottom: 1px solid var(--k-line);
		transform: translateY(-102%);
		transition: transform 0.5s var(--k-ease);
	}
	.site-nav.is-open { transform: translateY(0); }
	.admin-bar .site-header { top: 46px; }
	.admin-bar .site-nav { top: calc(var(--k-header-h) + 46px); }

	.nav__list {
		flex-direction: column;
		align-items: flex-start;
		gap: 14px;
	}
	.nav__list a { font-size: 22px; letter-spacing: -0.03em; }
	.nav__list .sub-menu {
		position: static;
		opacity: 1;
		visibility: visible;
		transform: none;
		border: 0;
		padding: 8px 0 0 14px;
	}

	.nav-toggle {
		display: flex;
		align-items: center;
		justify-content: center;
		width: var(--k-header-h);
		height: var(--k-header-h);
		margin-left: auto;
	}
	.nav-toggle__bars { position: relative; }
	.nav-toggle__bars,
	.nav-toggle__bars::before,
	.nav-toggle__bars::after {
		display: block;
		width: 18px;
		height: 1.5px;
		background: var(--k-ink);
		transition: transform 0.35s var(--k-ease), background 0.2s ease;
	}
	.nav-toggle__bars::before,
	.nav-toggle__bars::after { content: ""; position: absolute; left: 0; }
	.nav-toggle__bars::before { top: -6px; }
	.nav-toggle__bars::after { top: 6px; }

	.nav-toggle[aria-expanded="true"] .nav-toggle__bars { background: transparent; }
	.nav-toggle[aria-expanded="true"] .nav-toggle__bars::before { transform: translateY(6px) rotate(45deg); }
	.nav-toggle[aria-expanded="true"] .nav-toggle__bars::after { transform: translateY(-6px) rotate(-45deg); }

	/* Simplify the grid rhythm to 2-up rows on phones */
	.tile,
	.tile:nth-child(8n + 2),
	.tile:nth-child(8n + 3),
	.tile:nth-child(8n + 4),
	.tile:nth-child(8n + 5),
	.tile:nth-child(8n + 6),
	.tile:nth-child(8n + 7),
	.tile:nth-child(8n + 0) { grid-column: span 6; }
	.tile:nth-child(4n + 1) { grid-column: span 7; }
	.tile:nth-child(4n + 2) { grid-column: span 5; }
	.tile:nth-child(4n + 3) { grid-column: span 5; }
	.tile:nth-child(4n + 0) { grid-column: span 7; }

	.hero__foot {
		grid-template-columns: 1fr auto;
		gap: 12px 16px;
	}
	.hero__footnote { grid-column: 1 / -1; order: 2; }
	.scroll-cue { justify-self: start; order: 1; }
	.scroll-arrow { order: 1; }

	.hero__grid { grid-auto-rows: clamp(128px, 42vw, 210px); }
	/* Two 2-up rows is all that fits above the headline on a short phone.
	   Three overflowed 100svh on an SE and on any phone with browser chrome. */
	.tile:nth-child(n + 5) { display: none; }

	.index-row a { grid-template-columns: 34px 1fr auto; }
}

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

	.k-preload .tile__mask { clip-path: inset(0 0 0 0); }
	.k-preload .tile__img,
	.k-preload .tile__fill { transform: none; }
	.k-preload .line__in { transform: none; opacity: 1; }
	.k-preload .hero__foot { opacity: 1; }
	.scroll-arrow { animation: none; }
	.work-card__mask { clip-path: inset(0 0 0 0); }
	.work-card__img,
	.work-card__fill { transform: none; }

	*,
	*::before,
	*::after {
		transition-duration: 0.01ms !important;
		animation-duration: 0.01ms !important;
	}
}

/* Single project: subtitle and the next-project link */
.page-head__sub {
	font-size: clamp(16px, 1.6vw, 20px);
	color: var(--k-mute);
	max-width: 46ch;
	letter-spacing: -0.01em;
}

.next-project {
	margin: 0 var(--k-pad) clamp(80px, 12vh, 140px);
	border-top: 1px solid var(--k-line);
}
.next-project a {
	display: grid;
	grid-template-columns: 1fr auto;
	align-items: center;
	gap: 8px 16px;
	padding: clamp(20px, 3vw, 36px) 0;
	transition: padding-left 0.5s var(--k-ease), color 0.3s ease;
}
.next-project a:hover { padding-left: 16px; color: var(--k-accent); }
.next-project .eyebrow { grid-column: 1; color: var(--k-mute); }
.next-project__title {
	grid-column: 1;
	font-size: clamp(24px, 3.4vw, 44px);
	letter-spacing: -0.035em;
	line-height: 1.05;
	font-weight: 500;
}
.next-project .plus { grid-column: 2; grid-row: 1 / span 2; }
