/*
Theme Name: Bhubezi
Description: Custom theme for Bhubezi Projects (Pty) Ltd. Structural, mechanical, platework and piping.
Author: Aleph Technologies
Author URI: https://aleph-techs.com
Version: 1.0.0
Requires PHP: 8.0
Requires at least: 6.4
Text Domain: bhubezi
*/

/* ---------- Tokens ---------- */
:root {
	--ink: #0a1230;        /* deep shaft navy */
	--ink-2: #111b42;
	--blue: #1e3fa8;       /* pride blue, from the Bhubezi mark */
	--blue-lift: #6f8df0;  /* blue that reads on navy */
	--oxide: #b4412b;      /* red-oxide primer */
	--galv: #c9d0d8;       /* galvanised steel */
	--mill: #eef1f4;       /* mill-white ground */
	--paper: #ffffff;
	--steel: #556072;      /* muted text on light */
	--line: rgba(10, 18, 48, .16);
	--line-dark: rgba(255, 255, 255, .18);
	--gutter: clamp(20px, 4vw, 76px);
	--display: "Big Shoulders Display", "Arial Narrow", Impact, sans-serif;
	--body: "IBM Plex Sans", "Segoe UI", system-ui, sans-serif;
	--mono: "IBM Plex Mono", ui-monospace, Consolas, monospace;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
	margin: 0;
	background: var(--mill);
	color: var(--ink);
	font-family: var(--body);
	font-size: clamp(16px, 0.55vw + 12px, 20px);
	line-height: 1.6;
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
h1, h2, h3, p, ul, ol, figure, dl, dd { margin: 0; padding: 0; }
ul, ol { list-style: none; }
:focus-visible { outline: 3px solid var(--oxide); outline-offset: 3px; }
.skip { position: absolute; left: -999px; top: 0; background: var(--paper); padding: 12px 16px; z-index: 100; }
.skip:focus { left: 8px; top: 8px; }

/* ---------- Type ---------- */
.display {
	font-family: var(--display);
	font-weight: 900;
	text-transform: uppercase;
	line-height: .9;
	letter-spacing: -.005em;
}
.d-xl { font-size: clamp(52px, 9.6vw, 190px); }
.d-lg { font-size: clamp(42px, 6.4vw, 124px); }
.d-md { font-size: clamp(32px, 3.6vw, 68px); line-height: .95; }
.d-sm { font-size: clamp(24px, 2vw, 36px); line-height: 1; font-weight: 800; }
.label {
	font-family: var(--mono);
	font-size: clamp(11px, .2vw + 10px, 13px);
	letter-spacing: .09em;
	text-transform: uppercase;
	font-weight: 500;
}
.lead { font-size: clamp(19px, 1.25vw + 10px, 30px); line-height: 1.4; }
.muted { color: var(--steel); }

/* ---------- Layout ---------- */
.wrap { padding-left: var(--gutter); padding-right: var(--gutter); }
.band { padding-top: clamp(64px, 8vw, 150px); padding-bottom: clamp(64px, 8vw, 150px); }
.band-dark { background: var(--ink); color: var(--paper); }
.band-paper { background: var(--paper); }
.band-blue { background: var(--blue); color: var(--paper); }
.split { display: grid; grid-template-columns: repeat(12, 1fr); gap: clamp(24px, 3vw, 56px); }
.col-4 { grid-column: span 4; } .col-5 { grid-column: span 5; } .col-6 { grid-column: span 6; }
.col-7 { grid-column: span 7; } .col-8 { grid-column: span 8; } .col-12 { grid-column: span 12; }
.band-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 24px; flex-wrap: wrap; margin-bottom: clamp(32px, 4vw, 72px); }
.stack > * + * { margin-top: 1.1em; }

/* ---------- Buttons ---------- */
.btn {
	display: inline-flex; align-items: center; gap: 14px;
	font-family: var(--mono); font-size: 14px; font-weight: 500; letter-spacing: .08em; text-transform: uppercase;
	text-decoration: none; padding: 18px 24px; border: 2px solid currentColor; background: transparent; color: inherit; cursor: pointer;
	transition: background .2s, color .2s, border-color .2s;
}
.btn::after { content: ""; width: 22px; height: 2px; background: currentColor; box-shadow: 0 0 0 0 currentColor; transition: width .2s; }
.btn:hover::after { width: 34px; }
.btn-solid { background: var(--oxide); border-color: var(--oxide); color: #fff; }
.btn-solid:hover { background: #fff; border-color: #fff; color: var(--ink); }
.band-paper .btn-solid:hover, .on-light .btn-solid:hover { background: var(--ink); border-color: var(--ink); color: #fff; }
.btn-ghost:hover { background: currentColor; }
.btn-ghost:hover > span { color: var(--ink); }
.on-light .btn-ghost:hover > span { color: #fff; }
.textlink { font-family: var(--mono); font-size: 14px; letter-spacing: .08em; text-transform: uppercase; text-decoration: none; border-bottom: 2px solid var(--oxide); padding-bottom: 4px; }
.textlink:hover { border-color: currentColor; }

/* ---------- Header ---------- */
.site-head {
	position: sticky; top: 0; z-index: 50;
	background: var(--ink); color: #fff;
	display: flex; align-items: center; justify-content: space-between; gap: 24px;
	padding: 12px var(--gutter);
	border-bottom: 1px solid var(--line-dark);
}
.brand { display: flex; align-items: center; text-decoration: none; }
.brand img { height: clamp(46px, 3.8vw, 72px); width: auto; }
.nav ul { display: flex; align-items: center; gap: clamp(18px, 2.2vw, 44px); }
.nav a { font-family: var(--mono); font-size: 13px; letter-spacing: .09em; text-transform: uppercase; text-decoration: none; padding: 10px 0; border-bottom: 2px solid transparent; }
.nav a:hover, .nav .current-menu-item > a, .nav .current-page-ancestor > a, .nav .current_page_parent > a { border-bottom-color: var(--oxide); }
.nav li.menu-cta > a { background: var(--oxide); padding: 14px 20px; border: 0; }
.nav li.menu-cta > a:hover { background: #fff; color: var(--ink); }
.nav-toggle { display: none; background: none; border: 2px solid #fff; color: #fff; font-family: var(--mono); font-size: 13px; letter-spacing: .09em; text-transform: uppercase; padding: 10px 14px; cursor: pointer; }

/* ---------- Hero ---------- */
.hero { position: relative; background: var(--ink); color: #fff; min-height: calc(100vh - 80px); display: flex; flex-direction: column; justify-content: flex-end; overflow: hidden; }
.hero-media { position: absolute; inset: 0; }
.hero-media img { width: 100%; height: 100%; object-fit: cover; }
.hero-media::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(10,18,48,.5) 0%, rgba(10,18,48,.42) 30%, rgba(10,18,48,.9) 76%, var(--ink) 100%), linear-gradient(90deg, rgba(10,18,48,.55), rgba(10,18,48,0) 70%); }
.hero-body { position: relative; padding: clamp(120px, 16vh, 220px) var(--gutter) clamp(28px, 3vw, 48px); }
.hero-tag { display: flex; align-items: center; gap: 14px; margin-bottom: clamp(18px, 2vw, 32px); }
.hero-tag::before { content: ""; width: 44px; height: 8px; background: var(--oxide); }
.hero h1 span { display: block; }
.hero h1 .thin { -webkit-text-stroke: 2px #fff; color: transparent; }
.hero-foot { display: grid; grid-template-columns: 7fr 5fr; gap: clamp(24px, 3vw, 56px); align-items: end; margin-top: clamp(24px, 3vw, 48px); }
.hero-actions { display: flex; gap: 14px; flex-wrap: wrap; justify-content: flex-end; }

/* spec strip: reads like a drawing title block */
.specs { position: relative; display: grid; grid-template-columns: repeat(5, 1fr); border-top: 1px solid var(--line-dark); }
.specs > div { padding: clamp(16px, 1.6vw, 28px) var(--gutter) clamp(18px, 1.8vw, 30px) 0; border-right: 1px solid var(--line-dark); padding-left: clamp(14px, 1.6vw, 28px); }
.specs > div:first-child { padding-left: var(--gutter); }
.specs > div:last-child { border-right: 0; }
.specs dt { color: var(--blue-lift); margin-bottom: 6px; }
.specs dd { font-family: var(--display); font-weight: 800; font-size: clamp(24px, 2.5vw, 48px); line-height: 1; text-transform: uppercase; }
.specs dd small { font-family: var(--mono); font-size: .36em; font-weight: 500; letter-spacing: .08em; margin-left: 6px; }

/* ---------- Intro ---------- */
.scope-list { display: grid; grid-template-columns: 1fr 1fr; border-top: 2px solid var(--ink); margin-top: clamp(24px, 2.4vw, 40px); }
.scope-list li { padding: 14px 0; border-bottom: 1px solid var(--line); font-family: var(--display); font-weight: 800; text-transform: uppercase; font-size: clamp(20px, 1.6vw, 30px); line-height: 1.1; }

/* ---------- Workflow (signature) ---------- */
.flow { display: grid; grid-template-columns: 5fr 7fr; gap: clamp(24px, 4vw, 90px); }
.flow-stage { position: sticky; top: 110px; align-self: start; height: calc(100vh - 150px); min-height: 460px; display: flex; flex-direction: column; justify-content: space-between; }
.flow-count { font-family: var(--display); font-weight: 900; font-size: clamp(110px, 15vw, 300px); line-height: .8; color: transparent; -webkit-text-stroke: 2px var(--blue-lift); }
.flow-count b { color: #fff; -webkit-text-stroke: 0; font-weight: 900; }
.beam { width: 100%; height: auto; overflow: visible; }
.beam .steel { fill: transparent; stroke: var(--blue-lift); stroke-width: 2; stroke-dasharray: 7 6; transition: fill .6s, stroke .6s, stroke-dasharray .6s; }
.beam .dim, .beam .weld, .beam .tag, .beam .bolt, .beam .frame, .beam .truck { opacity: 0; transition: opacity .5s; }
.beam .dim line, .beam .dim path { stroke: #fff; stroke-width: 1; fill: none; }
.beam text { font-family: var(--mono); font-size: 13px; fill: #fff; letter-spacing: .08em; }
.beam .weld path { stroke: #ffd27a; stroke-width: 3; fill: none; stroke-linecap: round; }
.beam .bolt circle { fill: var(--ink); stroke: #fff; stroke-width: 1.5; }
.beam .frame path, .beam .truck path, .beam .truck circle { stroke: var(--galv); stroke-width: 2; fill: none; }
.beam .member { transition: transform .8s cubic-bezier(.6, .1, .2, 1); transform-box: fill-box; transform-origin: center; }
[data-stage="1"] .beam .dim { opacity: 1; }
[data-stage="2"] .beam .steel { fill: #8b95a3; stroke: #dfe4ea; stroke-dasharray: 0; }
[data-stage="2"] .beam .weld { opacity: 1; }
[data-stage="3"] .beam .steel, [data-stage="4"] .beam .steel { fill: var(--oxide); stroke: #e58d79; stroke-dasharray: 0; }
[data-stage="4"] .beam .tag, [data-stage="4"] .beam .truck { opacity: 1; }
[data-stage="4"] .beam .member { transform: translateY(-14px); }
[data-stage="5"] .beam .steel { fill: var(--blue); stroke: var(--blue-lift); stroke-dasharray: 0; }
[data-stage="5"] .beam .bolt, [data-stage="5"] .beam .frame { opacity: 1; }
.flow-steps > li { min-height: 78vh; display: flex; flex-direction: column; justify-content: center; padding: 40px 0; border-top: 1px solid var(--line-dark); }
.flow-steps > li:first-child { border-top: 0; }
.flow-steps figure { margin-top: 28px; aspect-ratio: 16 / 9; overflow: hidden; background: var(--ink-2); }
.flow-steps figure img { width: 100%; height: 100%; object-fit: cover; }
.flow-steps .label { color: var(--blue-lift); margin-bottom: 12px; display: block; }
.flow-steps p { margin-top: 16px; color: #d5daea; }
.flow-steps .facts { display: flex; flex-wrap: wrap; gap: 8px 28px; margin-top: 20px; font-family: var(--mono); font-size: 14px; letter-spacing: .04em; }
.flow-steps .facts li::before { content: "+ "; color: var(--oxide); }
.flow-steps .textlink { margin-top: 24px; align-self: flex-start; }

/* ---------- Projects ---------- */
.proj-grid { display: grid; grid-template-columns: repeat(12, 1fr); gap: clamp(14px, 1.4vw, 26px); }
.proj { grid-column: span 4; position: relative; background: var(--ink); color: #fff; min-height: clamp(300px, 28vw, 520px); display: flex; flex-direction: column; justify-content: flex-end; overflow: hidden; }
.proj.wide { grid-column: span 8; }
.proj.half { grid-column: span 6; }
.proj img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform .8s cubic-bezier(.2, .6, .2, 1); }
.proj:hover img { transform: scale(1.04); }
.proj::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(10,18,48,0) 35%, rgba(10,18,48,.92) 100%); }
.proj.no-img { background: var(--blue); }
.proj.no-img::after { display: none; }
.proj-body { position: relative; z-index: 1; padding: clamp(18px, 1.8vw, 32px); }
.proj-body .label { display: flex; gap: 12px; align-items: center; margin-bottom: 10px; }
.proj-body .label::before { content: ""; width: 10px; height: 10px; background: var(--oxide); }
.proj-body p { margin-top: 8px; font-size: .92em; color: #d5daea; }
.filters { display: flex; flex-wrap: wrap; gap: 8px; }
.filters button { font-family: var(--mono); font-size: 13px; letter-spacing: .08em; text-transform: uppercase; background: transparent; color: var(--ink); border: 1.5px solid var(--ink); padding: 10px 16px; cursor: pointer; }
.filters button[aria-pressed="true"] { background: var(--ink); color: #fff; }
.proj[hidden] { display: none; }

/* ---------- Client wall ---------- */
.clients { display: flex; flex-wrap: wrap; gap: 0 .5em; font-family: var(--display); font-weight: 900; text-transform: uppercase; font-size: clamp(30px, 4.3vw, 84px); line-height: 1.04; }
.clients li::after { content: "/"; color: var(--oxide); margin-left: .5em; font-weight: 400; }
.clients li:last-child::after { content: ""; }
.clients li:nth-child(3n+2) { color: var(--blue); }

/* ---------- Footprint plot ---------- */
.plot { width: 100%; height: auto; display: block; }
.plot .grat { stroke: var(--line-dark); stroke-width: 1; }
.plot .eq { stroke: var(--blue-lift); stroke-dasharray: 4 6; }
.plot text { font-family: var(--mono); font-size: 12px; letter-spacing: .06em; fill: #fff; text-transform: uppercase; }
.plot .axis { fill: #8f9bc4; font-size: 10px; }
.plot .work { fill: var(--oxide); stroke: #fff; stroke-width: 1.5; }
.plot .base { fill: var(--blue-lift); stroke: #fff; stroke-width: 2; }
.plot .ring { fill: none; stroke: var(--blue-lift); stroke-width: 1.5; }
.legend { display: flex; gap: 28px; flex-wrap: wrap; }
.legend span { display: inline-flex; align-items: center; gap: 10px; }
.legend i { width: 12px; height: 12px; border-radius: 50%; display: inline-block; border: 1.5px solid #fff; }
.country-list { columns: 2; column-gap: 32px; }
.country-list li { padding: 10px 0; border-bottom: 1px solid var(--line-dark); break-inside: avoid; display: flex; justify-content: space-between; gap: 12px; font-family: var(--display); font-weight: 800; text-transform: uppercase; font-size: clamp(19px, 1.5vw, 28px); line-height: 1.1; }
.country-list li small { font-family: var(--mono); font-size: 11px; letter-spacing: .08em; font-weight: 500; color: var(--blue-lift); align-self: center; }

/* ---------- Promise ---------- */
.promise { display: grid; grid-template-columns: repeat(4, 1fr); border-top: 2px solid #fff; margin-top: clamp(32px, 4vw, 64px); }
.promise li { padding: 22px 22px 0 0; border-right: 1px solid rgba(255,255,255,.35); padding-left: 22px; }
.promise li:first-child { padding-left: 0; }
.promise li:last-child { border-right: 0; }
.promise p { margin-top: 10px; font-size: .95em; }

/* ---------- Page head ---------- */
.page-head { position: relative; background: var(--ink); color: #fff; overflow: hidden; }
.page-head .hero-media::after { background: linear-gradient(90deg, rgba(10,18,48,.9) 0%, rgba(10,18,48,.55) 60%, rgba(10,18,48,.35) 100%); }
.page-head-body { position: relative; padding: clamp(90px, 11vw, 200px) var(--gutter) clamp(36px, 4vw, 72px); }
.page-head .lead { margin-top: clamp(18px, 2vw, 32px); }
.crumb { display: flex; gap: 10px; margin-bottom: 20px; color: var(--blue-lift); }
.crumb a { text-decoration: none; color: #fff; }

/* ---------- Capability ---------- */
.spec-table { border-top: 2px solid var(--ink); }
.spec-table div { display: flex; justify-content: space-between; align-items: baseline; gap: 20px; padding: 14px 0; border-bottom: 1px solid var(--line); }
.spec-table dt { font-family: var(--mono); font-size: 13px; letter-spacing: .08em; text-transform: uppercase; color: var(--steel); }
.spec-table dd { font-family: var(--display); font-weight: 800; font-size: clamp(22px, 1.9vw, 36px); text-transform: uppercase; text-align: right; line-height: 1; }
.prose > * + * { margin-top: 1.1em; }
.prose h2 { font-family: var(--display); font-weight: 900; text-transform: uppercase; font-size: clamp(28px, 2.6vw, 48px); line-height: 1; margin-top: 1.6em; }
.prose ul { border-top: 1px solid var(--line); }
.prose ul li { padding: 10px 0 10px 26px; border-bottom: 1px solid var(--line); position: relative; }
.prose ul li::before { content: ""; position: absolute; left: 0; top: 1.15em; width: 12px; height: 3px; background: var(--oxide); }
.video { position: relative; aspect-ratio: 16 / 9; background: var(--ink); }
.video iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.gallery { display: grid; grid-template-columns: repeat(4, 1fr); gap: clamp(10px, 1vw, 18px); }
.gallery figure { aspect-ratio: 4 / 3; overflow: hidden; background: var(--galv); }
.gallery figure:first-child { grid-column: span 2; grid-row: span 2; aspect-ratio: auto; }
.gallery img { width: 100%; height: 100%; object-fit: cover; }
.stage-nav { display: grid; grid-template-columns: 1fr 1fr; }
.stage-nav a { display: block; padding: clamp(28px, 4vw, 72px) var(--gutter); text-decoration: none; background: var(--ink); color: #fff; border-top: 1px solid var(--line-dark); }
.stage-nav a + a { border-left: 1px solid var(--line-dark); text-align: right; }
.stage-nav a:hover { background: var(--blue); }
.stage-nav .label { color: var(--blue-lift); display: block; margin-bottom: 10px; }
.stage-nav a:hover .label { color: #fff; }
.cap-index li { border-top: 1px solid var(--line); }
.cap-index li:last-child { border-bottom: 1px solid var(--line); }
.cap-index a { display: grid; grid-template-columns: 1fr 5fr 5fr auto; gap: clamp(16px, 2.4vw, 48px); align-items: center; padding: clamp(20px, 2.4vw, 40px) 0; text-decoration: none; transition: background .2s, padding .2s; }
.cap-index a:hover { background: var(--ink); color: #fff; padding-left: 24px; padding-right: 24px; }
.cap-index a:hover .muted { color: #d5daea; }
.cap-index .arrow { font-family: var(--mono); }

/* ---------- Timeline ---------- */
.timeline { border-top: 2px solid var(--ink); }
.timeline li { display: grid; grid-template-columns: 2fr 10fr; gap: clamp(16px, 2.4vw, 48px); padding: clamp(18px, 2vw, 32px) 0; border-bottom: 1px solid var(--line); align-items: start; }
.timeline b { font-family: var(--display); font-weight: 900; font-size: clamp(40px, 4.6vw, 88px); line-height: .9; color: var(--blue); }

/* ---------- Contact ---------- */
.form { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.form .full { grid-column: 1 / -1; }
.form label { display: block; font-family: var(--mono); font-size: 12px; letter-spacing: .09em; text-transform: uppercase; margin-bottom: 8px; }
.form input, .form select, .form textarea { width: 100%; font: inherit; color: var(--ink); background: var(--paper); border: 1.5px solid var(--ink); border-radius: 0; padding: 15px 16px; }
.form textarea { min-height: 170px; resize: vertical; }
.form .hp { position: absolute; left: -9999px; }
.notice { padding: 18px 20px; border-left: 8px solid var(--blue); background: var(--paper); margin-bottom: 24px; }
.office + .office { margin-top: 36px; padding-top: 36px; border-top: 1px solid var(--line); }
.office a { text-decoration: none; border-bottom: 2px solid var(--oxide); }
.office .big { font-family: var(--display); font-weight: 800; font-size: clamp(26px, 2.4vw, 44px); line-height: 1.05; text-transform: uppercase; display: block; margin: 8px 0 12px; }

/* ---------- CTA + footer ---------- */
.cta { display: grid; grid-template-columns: 8fr 4fr; gap: clamp(24px, 3vw, 56px); align-items: end; }
.cta-actions { display: flex; flex-direction: column; gap: 14px; align-items: flex-start; }
.site-foot { background: var(--ink); color: #fff; border-top: 1px solid var(--line-dark); }
.foot-grid { display: grid; grid-template-columns: 4fr 3fr 3fr 2fr; gap: clamp(24px, 3vw, 56px); padding-top: clamp(48px, 5vw, 90px); padding-bottom: clamp(40px, 4vw, 72px); }
.foot-grid img { height: 96px; filter: brightness(1.55) saturate(1.1); width: auto; margin-bottom: 20px; }
.foot-grid .label { color: var(--blue-lift); display: block; margin-bottom: 14px; }
.foot-grid a { text-decoration: none; }
.foot-grid a:hover { text-decoration: underline; text-decoration-color: var(--oxide); text-underline-offset: 5px; }
.foot-grid li + li { margin-top: 8px; }
.foot-base { display: flex; justify-content: space-between; gap: 20px; flex-wrap: wrap; padding-top: 20px; padding-bottom: 24px; border-top: 1px solid var(--line-dark); color: #a8b2d4; }

/* ---------- Motion ---------- */
.motion .reveal { opacity: 0; transform: translateY(26px); transition: opacity .7s ease, transform .7s cubic-bezier(.2, .7, .2, 1); }
.motion .reveal.in { opacity: 1; transform: none; }
.hero h1 span { opacity: 0; transform: translateY(40px); animation: rise .9s cubic-bezier(.2, .7, .2, 1) forwards; }
.hero h1 span:nth-child(2) { animation-delay: .12s; }
.hero h1 span:nth-child(3) { animation-delay: .24s; }
@keyframes rise { to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) {
	html { scroll-behavior: auto; }
	.reveal, .hero h1 span { opacity: 1; transform: none; animation: none; transition: none; }
	.proj img, .beam * { transition: none !important; }
}

/* ---------- Responsive ---------- */
@media (max-width: 1100px) {
	.col-4, .col-5, .col-6, .col-7, .col-8 { grid-column: span 12; }
	.hero-foot, .cta, .flow { grid-template-columns: 1fr; }
	.hero-actions { justify-content: flex-start; }
	.specs { grid-template-columns: repeat(2, 1fr); }
	.specs > div { padding-left: var(--gutter); border-bottom: 1px solid var(--line-dark); }
	.flow-stage { position: relative; top: 0; height: auto; min-height: 0; gap: 20px; }
	.flow-count { font-size: 120px; }
	.flow-steps > li { min-height: 0; }
	.proj, .proj.wide, .proj.half { grid-column: span 6; }
	.promise { grid-template-columns: 1fr 1fr; }
	.promise li { padding: 22px 16px 22px 0; border-right: 0; border-bottom: 1px solid rgba(255,255,255,.35); }
	.foot-grid { grid-template-columns: 1fr 1fr; }
	.gallery { grid-template-columns: repeat(2, 1fr); }
	.cap-index a { grid-template-columns: auto 1fr; }
	.cap-index a > .muted, .cap-index .arrow { grid-column: 2; }
}
@media (max-width: 820px) {
	.nav-toggle { display: block; }
	.nav { display: none; position: absolute; left: 0; right: 0; top: 100%; background: var(--ink); border-bottom: 1px solid var(--line-dark); padding: 12px var(--gutter) 24px; }
	.nav.open { display: block; }
	.nav ul { flex-direction: column; align-items: flex-start; gap: 4px; }
	.nav a { display: block; padding: 14px 0; }
	.nav li.menu-cta { margin-top: 10px; }
	.hero h1 .thin { -webkit-text-stroke-width: 1.2px; }
}
@media (max-width: 640px) {
	.proj, .proj.wide, .proj.half { grid-column: span 12; }
	.scope-list, .form, .stage-nav, .foot-grid, .promise { grid-template-columns: 1fr; }
	.stage-nav a + a { border-left: 0; text-align: left; }
	.country-list { columns: 1; }
	.timeline li { grid-template-columns: 1fr; gap: 6px; }
	.specs { grid-template-columns: 1fr; }
}

/* =====================================================================
   Motion layer
   ===================================================================== */
.sr-only { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }

/* scroll progress: a weld bead along the top edge */
.progress { position: fixed; left: 0; top: 0; width: 100%; height: 4px; background: var(--oxide); transform: scaleX(0); transform-origin: 0 50%; z-index: 60; pointer-events: none; }

/* header tucks away going down, returns going up */
.site-head { transition: transform .45s cubic-bezier(.2, .7, .2, 1), background .3s; }
.site-head.hide { transform: translateY(-101%); }
.brand img { filter: brightness(1.55) saturate(1.1); }

/* opening curtain on the home page */
.motion body::before { content: ""; position: fixed; inset: 0; background: var(--blue); z-index: 80; transform-origin: 50% 0; animation: curtain .8s cubic-bezier(.7, 0, .2, 1) .05s both; pointer-events: none; }
.motion body.home::before { animation-duration: 1s; animation-delay: .15s; }
.motion.leaving body::before { transform-origin: 50% 100%; animation: cover .42s cubic-bezier(.7, 0, .2, 1) both; }
@keyframes cover { from { transform: scaleY(0); } to { transform: scaleY(1); } }
.motion .home::after { content: ""; position: fixed; inset: 0; background: var(--ink); z-index: 79; transform-origin: 50% 0; animation: curtain 1s cubic-bezier(.7, 0, .2, 1) .3s both; pointer-events: none; }
@keyframes curtain { to { transform: scaleY(0); } }

/* hero */
.hero-media img { scale: 1.12; will-change: translate; }
.motion .hero-media img { animation: settle 2.4s cubic-bezier(.2, .7, .2, 1) .3s both; }
@keyframes settle { from { scale: 1.3; } to { scale: 1.12; } }
.hero h1 .line { display: block; overflow: hidden; padding-top: .04em; margin-top: -.04em; }
.hero h1 .line > span { display: inline-block; opacity: 1; transform: none; animation: none; }
.motion .hero h1 .line > span { transform: translateY(105%); animation: line-up 1.1s cubic-bezier(.2, .8, .2, 1) forwards; animation-delay: calc(.75s + var(--i, 0) * .12s); }
@keyframes line-up { to { transform: none; } }
.hero h1 .thin > span {
	-webkit-text-stroke: 2px #fff; color: transparent;
	background: linear-gradient(90deg, #fff calc(var(--fill, 0) * 100%), transparent calc(var(--fill, 0) * 100%));
	-webkit-background-clip: text; background-clip: text;
}
.hero h1 .thin { -webkit-text-stroke: 0; }
.motion .hero-tag, .motion .hero-foot, .motion .specs > div { opacity: 0; animation: fade-up .9s cubic-bezier(.2, .7, .2, 1) forwards; }
.motion .hero-tag { animation-delay: .7s; }
.motion .hero-foot { animation-delay: 1.25s; }
.motion .specs > div { animation-delay: calc(1.4s + var(--i, 0) * .08s); }
@keyframes fade-up { from { opacity: 0; transform: translateY(24px); } to { opacity: 1; transform: none; } }
.hero-tag::before { transform-origin: 0 50%; }
.motion .hero-tag::before { animation: grow-x .8s cubic-bezier(.7, 0, .2, 1) .9s both; }
@keyframes grow-x { from { transform: scaleX(0); } }
.scroll-cue { position: absolute; right: var(--gutter); top: clamp(110px, 14vh, 180px); writing-mode: vertical-rl; display: flex; align-items: center; gap: 14px; z-index: 2; }
.scroll-cue::after { content: ""; width: 2px; height: 90px; background: linear-gradient(#fff 50%, rgba(255,255,255,.25) 50%); background-size: 100% 200%; animation: cue 1.8s linear infinite; }
@keyframes cue { from { background-position: 0 100%; } to { background-position: 0 -100%; } }

/* headings: words rise out of a mask */
.rise .w { display: inline-block; overflow: hidden; vertical-align: top; padding-top: .05em; margin-top: -.05em; }
.rise .w > span { display: inline-block; transform: translateY(108%); transition: transform .95s cubic-bezier(.2, .8, .2, 1); transition-delay: calc(var(--i) * 45ms); }
.rise.in .w > span { transform: none; }

/* scrubbed statement: words light up with the scroll */
[data-scrub] .sw > span { opacity: .22; transition: opacity .35s; }
[data-scrub] .sw.lit > span { opacity: 1; }

/* images wipe in, then drift */
.motion .proj.reveal { opacity: 1; transform: none; }
.proj img { height: 116%; top: -8%; inset-inline: 0; translate: 0 var(--py, 0%); }
.motion .proj img { clip-path: inset(0 0 100% 0); transition: clip-path 1.2s cubic-bezier(.7, 0, .2, 1), scale .9s cubic-bezier(.2, .6, .2, 1); scale: 1.14; }
.motion .proj.in img { clip-path: inset(0); scale: 1; }
.proj:hover img { transform: none; scale: 1.05; }
.proj .proj-body { transition: transform .5s cubic-bezier(.2, .7, .2, 1); }
.proj:hover .proj-body { transform: translateY(-8px); }
.proj::before { content: ""; position: absolute; inset: 0; z-index: 1; opacity: 0; transition: opacity .4s; pointer-events: none; background: radial-gradient(420px circle at var(--mx, 50%) var(--my, 50%), rgba(111,141,240,.34), transparent 70%); }
.proj:hover::before { opacity: 1; }
.proj-body { z-index: 2; }
.proj.no-img { background: linear-gradient(135deg, var(--blue), var(--ink)); }
.flow-steps figure img { height: 116%; margin-top: -4%; translate: 0 var(--py, 0%); }
.motion .clip { clip-path: inset(0 100% 0 0); transition: clip-path 1.2s cubic-bezier(.7, 0, .2, 1); }
.motion .clip.in { clip-path: inset(0); }
.page-head .hero-media img { scale: 1.06; }
.motion .page-head .hero-media img { animation: settle 2.2s cubic-bezier(.2, .7, .2, 1) both; }
.motion .page-head h1, .motion .page-head .lead, .motion .page-head .crumb { animation: fade-up 1s cubic-bezier(.2, .7, .2, 1) both; }
.motion .page-head .lead { animation-delay: .18s; }

/* workflow extras */
.flow-count b { display: inline-block; }
.flow-count b.tick { animation: tick .6s cubic-bezier(.2, .8, .2, 1); }
@keyframes tick { from { transform: translateY(40%); opacity: 0; } }
.beam .dim line { stroke-dasharray: 600; stroke-dashoffset: 600; transition: stroke-dashoffset 1s ease .1s; }
[data-stage="1"] .beam .dim line { stroke-dashoffset: 0; }
.beam .weld path { stroke-dasharray: 3 9; animation: spark 0.5s linear infinite; }
@keyframes spark { to { stroke-dashoffset: -12; } }
.beam .truck circle { transform-box: fill-box; transform-origin: center; stroke-dasharray: 20 6; }
[data-stage="4"] .beam .truck circle { animation: spin 1.2s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
[data-stage="4"] .beam .member, [data-stage="4"] .beam .truck { animation: haul 2.4s ease-in-out infinite alternate; }
@keyframes haul { from { translate: -10px 0; } to { translate: 10px 0; } }
.flow-rail { position: absolute; left: 0; top: 0; bottom: 0; width: 2px; background: var(--line-dark); }

/* client marquee */
.marquees { margin-inline: calc(var(--gutter) * -1); display: grid; gap: .1em; font-family: var(--display); font-weight: 900; text-transform: uppercase; font-size: clamp(44px, 7vw, 140px); line-height: 1; overflow: hidden; }
.marquee .track { display: flex; width: max-content; animation: slide 70s linear infinite; }
.marquee.rev .track { animation-direction: reverse; }
.marquees:hover .track { animation-play-state: paused; }
.marquee span { white-space: nowrap; padding-right: .35em; }
.marquee span::after { content: "/"; color: var(--oxide); font-weight: 400; margin-left: .35em; }
.marquee span:nth-child(even) { color: transparent; -webkit-text-stroke: 1.5px var(--ink); }
@keyframes slide { to { transform: translateX(-50%); } }

/* footprint plot comes alive */
.plot .link { fill: none; stroke: var(--blue-lift); stroke-width: 1; opacity: .7; stroke-dasharray: 1; stroke-dashoffset: 1; }
.plot circle.work, .plot circle.base, .plot text.name { transform-box: fill-box; transform-origin: center; }
.motion .plot circle.work, .motion .plot circle.base { scale: 0; transition: scale .6s cubic-bezier(.3, 1.6, .5, 1); transition-delay: calc(.2s + var(--i) * 70ms); }
.motion .plot text.name { opacity: 0; transition: opacity .6s; transition-delay: calc(.35s + var(--i) * 70ms); }
.motion .plot.in circle.work, .motion .plot.in circle.base { scale: 1; }
.motion .plot.in text.name { opacity: 1; }
.plot .link { transition: stroke-dashoffset 1.4s cubic-bezier(.6, 0, .2, 1); transition-delay: calc(.1s + var(--i) * 70ms); }
.plot.in .link, html:not(.motion) .plot .link { stroke-dashoffset: 0; }
.plot .ring { transform-box: fill-box; transform-origin: center; }
.motion .plot .ring { animation: ping 2.6s ease-out infinite; }
@keyframes ping { from { scale: .5; opacity: 1; } to { scale: 2.6; opacity: 0; } }

/* promise columns draw their rule */
.promise { border-top: 0; position: relative; }
.promise::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 2px; background: #fff; }

/* capability index hover preview */
.peek { position: fixed; left: 0; top: 0; width: clamp(260px, 24vw, 460px); aspect-ratio: 4 / 3; margin: -12% 0 0 28px; z-index: 40; pointer-events: none; overflow: hidden; clip-path: inset(50%); transition: clip-path .5s cubic-bezier(.7, 0, .2, 1); }
.peek.on { clip-path: inset(0); }
.peek img { width: 100%; height: 100%; object-fit: cover; }
.btn { will-change: translate; transition: background .2s, color .2s, border-color .2s, translate .35s cubic-bezier(.2, .7, .2, 1); }
.timeline b { transition: color .3s; }
.timeline li:hover b { color: var(--oxide); }
.spec-table div { transition: padding .3s, background .3s; }
.spec-table div:hover { background: var(--mill); padding-inline: 14px; }
.gallery figure img { transition: scale .9s cubic-bezier(.2, .6, .2, 1); }
.gallery figure:hover img { scale: 1.06; }

@media (prefers-reduced-motion: reduce) {
	*, *::before, *::after { animation: none !important; transition: none !important; }
	.proj img, .hero-media img { clip-path: none; scale: 1; }
	
}
@media (max-width: 1100px) { .scroll-cue { display: none; } }
.foot-base .credit { color: #fff; text-decoration: none; border-bottom: 1px solid var(--oxide); padding-bottom: 2px; }
.foot-base .credit:hover { border-bottom-color: #fff; }


/* ---------- Content-driven layouts ---------- */
.specs { grid-template-columns: repeat(var(--n, 5), 1fr); }
.promise { grid-template-columns: repeat(var(--n, 4), 1fr); }
.proj h3 a { color: inherit; text-decoration: none; }
.proj h3 a::after { content: ""; position: absolute; inset: -200vmax; z-index: 3; }
.proj h3 a:focus-visible { outline: none; }
.proj:focus-within { outline: 3px solid var(--oxide); outline-offset: 3px; }
.crumb span + span, .crumb a + span { color: var(--blue-lift); }
.prose img { height: auto; }
.prose figure { margin: 1.4em 0; }
.prose figcaption { font-family: var(--mono); font-size: 13px; letter-spacing: .04em; color: var(--steel); margin-top: 8px; }
.prose h3 { font-family: var(--display); font-weight: 800; text-transform: uppercase; font-size: clamp(22px, 1.9vw, 34px); line-height: 1.05; margin-top: 1.4em; }
.prose ol { list-style: decimal; padding-left: 1.3em; }
.prose ol li { padding: 6px 0; }
.prose a { color: var(--blue); text-underline-offset: 4px; }
.prose blockquote { margin: 1.4em 0; padding-left: 22px; border-left: 6px solid var(--oxide); font-size: 1.15em; }
.prose table { width: 100%; border-collapse: collapse; }
.prose th, .prose td { text-align: left; padding: 12px 10px; border-bottom: 1px solid var(--line); }
@media (max-width: 1100px) { .specs { grid-template-columns: repeat(2, 1fr); } .promise { grid-template-columns: 1fr 1fr; } }
@media (max-width: 640px) { .specs, .promise { grid-template-columns: 1fr; } }

/* Signed-in editors: keep the header below the WordPress toolbar. */
.admin-bar .site-head { top: 32px; }
.admin-bar .progress { top: 32px; }
@media (min-width: 1101px) { .admin-bar .flow-stage { top: 142px; } }
@media (max-width: 782px) { .admin-bar .site-head, .admin-bar .progress { top: 46px; } }

.opened:not(.leaving) body::before, .opened:not(.leaving) body::after { display: none; }


/* Country names keep a dark outline so the route lines never run through the letters. */
.plot text.name { paint-order: stroke; stroke: var(--ink); stroke-width: 5px; stroke-linejoin: round; }

