/* ============ Tokens ============ */
:root {
  --foot: 42svh;  /* footer height (the black brand box) */
  --bg: #F7F7F4;
  --fg: #232323;
  --muted: #5E5E5B;
  --line: #232323;
  --ink: #2B2B2B;         /* dark tiles */
  --on-ink: #F7F7F4;
  --on-ink-strong: #FFFFFF;
  --line-soft: #DCDCD8;   /* quiet hairlines */
  --paper: #FFFFFF;       /* bright white box behind the hero name */
  --ink-muted: #A8A8A3;
  --grey: #D9D9D6;        /* grey tiles */
  --accent: #F7AC99;      /* the one accent */
  --on-accent: #232323;
  --coral: #FF6B5B;       /* section titles */
  --on-coral: #2B2B2B;
  --dot: #1E1E1E;

  --h: 60px;              /* header height */
  --pad: 16px;
  --display: clamp(84px, 12.5vw, 260px);
  --shout: clamp(56px, 8.2vw, 170px);
  --stmt: clamp(28px, 5vw, 104px);   /* "I design…" and "Measured impact and growth" */
  --ease: cubic-bezier(.2, .7, 0, 1);
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #161616; --fg: #EDEDEA; --muted: #A3A3A0; --line: #4A4A48;
    --ink: #EDEDEA; --on-ink: #161616; --on-ink-strong: #000; --line-soft: #3A3A38; --paper: #161616; --ink-muted: #5A5A57;
    --grey: #2B2B2A; --dot: #D8D8D4;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #161616; --fg: #EDEDEA; --muted: #A3A3A0; --line: #4A4A48;
  --ink: #EDEDEA; --on-ink: #161616; --on-ink-strong: #000; --line-soft: #3A3A38; --paper: #161616; --ink-muted: #5A5A57;
  --grey: #2B2B2A; --dot: #D8D8D4;
  color-scheme: dark;
}

/* ============ Base ============ */
*, *::before, *::after { box-sizing: border-box; }
html { overflow-x: clip; scroll-behavior: smooth; scroll-padding-top: var(--h); -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: "Inter Tight", "Helvetica Neue", Arial, system-ui, sans-serif;
  font-weight: 400;
  font-size: 16px;
  line-height: 1.3;
  letter-spacing: -0.02em;
  overflow-x: clip;
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3, p, ul, ol, dl, dd, blockquote, figure { margin: 0; padding: 0; font-weight: inherit; font-size: inherit; }
ul, ol { list-style: none; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; letter-spacing: inherit; }
:focus-visible { outline: 2px solid var(--fg); outline-offset: -2px; }
.ink :focus-visible, .ink:focus-visible { outline-color: var(--on-ink); }

.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: fixed; left: 8px; top: -60px; z-index: 100; background: var(--accent); color: var(--on-accent); padding: 10px 14px; }
.skip:focus { top: 8px; }

/* Small uppercase labels (Aspen's mono tags, set in the same grotesk) */
.label {
  font-size: 12px; font-weight: 500; line-height: 1.3;
  letter-spacing: .02em; text-transform: uppercase;
  font-variant-numeric: tabular-nums;
}
.sq::before { content: ""; display: inline-block; width: 7px; height: 7px; background: currentColor; margin-right: 10px; vertical-align: 1px; }
.muted { color: var(--muted); }
.arrow { display: inline-block; transition: transform .3s var(--ease); }
a:hover .arrow, button:hover .arrow { transform: translateX(4px); }

.display {
  font-size: var(--display); line-height: .8; letter-spacing: -0.055em;
  font-weight: 400; margin-left: -0.05em;
}
.shout {
  display: block; font-size: var(--shout); line-height: .86; letter-spacing: -0.05em;
  text-transform: uppercase; font-weight: 400; margin-left: -0.04em;
}

/* ============ Background media ============ */
.bg { position: absolute; left: 0; top: 0; width: 100%; z-index: 0; overflow: hidden; background: var(--bg); pointer-events: none; }
.bg video, .bg img { width: 100%; height: 100%; object-fit: cover; display: block; }
.bg video { filter: grayscale(1); }
/* Dithered dot pattern, drawn by main.js in page-height strips */
.bg canvas { position: absolute; left: 0; }

main, .site-footer { position: relative; z-index: 1; }

/* ============ Grid ============ */
.grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin-right: -1px;             /* hide the outer right rule */
}
.cell {
  position: relative;
  background: var(--bg);
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  padding: var(--pad);
  min-width: 0;
}
.window { background: transparent; padding: 0; }
.ink { background: var(--ink); color: var(--on-ink); }
.ink .muted, .ink .label.muted { color: var(--ink-muted); }
.grey { background: var(--grey); }
.accent { background: var(--accent); color: var(--on-accent); }
.coral { background: var(--coral); color: var(--on-coral); }
.bright .cell:not(.ink):not(.coral) { background: var(--paper); }
.accent ::selection { background: var(--on-accent); color: var(--accent); }

.c1 { grid-column: 1 / 2; } .c2 { grid-column: 2 / 3; } .c3 { grid-column: 3 / 4; } .c4 { grid-column: 4 / 5; }
.c12 { grid-column: 1 / 3; } .c23 { grid-column: 2 / 4; } .c34 { grid-column: 3 / 5; }
.c13 { grid-column: 1 / 4; } .c14 { grid-column: 1 / 5; } .c24 { grid-column: 2 / 5; }

/* ============ Buttons ============ */
.btn {
  display: inline-flex; align-items: center; justify-content: space-between; gap: 32px;
  background: var(--ink); color: var(--on-ink);
  padding: 11px 14px; min-height: 40px;
  font-size: 12px; font-weight: 500; letter-spacing: .02em; text-transform: uppercase;
}
.ink .btn { background: var(--on-ink); color: var(--ink); }
.line-btn {
  display: flex; align-items: center; justify-content: space-between;
  font-size: 12px; font-weight: 500; letter-spacing: .02em; text-transform: uppercase;
  padding: 12px 0; min-height: 44px;
}

/* ============ Header ============ */
.site-header {
  position: sticky; top: 0; z-index: 50;
  display: grid; grid-template-columns: repeat(4, minmax(0, 1fr));
  height: var(--h);
  background: var(--paper);
  border-bottom: 1px solid var(--line);
  margin-right: -1px;
}
.h-brand { grid-column: 1 / 3; display: flex; align-items: center; gap: 18px; border-right: 1px solid var(--line); padding-right: var(--pad); }
.h-logo {
  flex: none; width: var(--h); height: var(--h); margin-top: -1px;
  display: grid; place-items: center;
  background: var(--ink); color: var(--on-ink);
  font-weight: 500; font-size: 17px; letter-spacing: -0.04em;
}
.h-logo img { width: 26px; height: auto; filter: invert(1); }   /* black mark shown white on the dark square */
:root[data-theme="dark"] .h-logo img { filter: none; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .h-logo img { filter: none; } }
.h-name { font-weight: 500; transition: opacity .4s ease, visibility .4s; }
.js .site-header:not(.named) .h-name { opacity: 0; visibility: hidden; }
.h-tools { grid-column: 3 / 4; display: flex; align-items: center; justify-content: space-between; padding: 0 var(--pad); border-right: 1px solid var(--line); }
.h-menu { height: 100%; display: flex; align-items: center; padding-right: 12px; }
.h-menu[aria-expanded="true"] { text-decoration: underline; text-underline-offset: 4px; }
.theme-toggle { display: flex; align-items: center; padding: 12px 0 12px 12px; }
.theme-toggle span { width: 11px; height: 11px; border-radius: 50%; border: 1px solid var(--fg); }
.theme-toggle .tt-b { background: var(--fg); margin-left: -1px; }
.h-contact {
  grid-column: 4 / 5; display: flex; align-items: center; justify-content: space-between;
  padding: 0 var(--pad); background: var(--ink); color: var(--on-ink); margin-bottom: -1px;
  transition: background-color .35s ease, color .35s ease;
}
.site-header.past-coral .h-contact { background: var(--coral); color: var(--on-coral); }

.menu {
  position: absolute; top: 100%; right: 0; width: 50%;
  background: var(--paper); border: 1px solid var(--line); border-top: 0; border-right: 0;
}
.menu a {
  display: flex; align-items: baseline; gap: 24px;
  padding: 14px var(--pad); border-bottom: 1px solid var(--line);
  font-size: clamp(32px, 3.4vw, 56px); line-height: 1; letter-spacing: -0.04em;
}
.menu li:last-child a { border-bottom: 0; }
.menu a:hover { background: var(--accent); color: var(--on-accent); }

/* ============ Hero ============ */
.hero {
  min-height: calc(100svh - var(--h));
  grid-template-rows: minmax(0, 1fr) minmax(0, 1fr);
}
.name-cell { display: flex; align-items: flex-end; padding-bottom: 0; overflow: hidden; }
.name-cell .display { line-height: 1; padding-bottom: .12em; }
.hero .name-cell { flex-direction: column; justify-content: flex-end; align-items: flex-start; }
.hero .name-cell { background: var(--paper); }
.hello { font-size: clamp(20px, 1.65vw, 28px); line-height: 1.15; letter-spacing: -0.03em; margin-bottom: .2em; }
.hero-intro, .hero-pos { display: flex; flex-direction: column; justify-content: space-between; gap: 24px; }
.lead { font-size: clamp(20px, 1.65vw, 28px); line-height: 1.15; letter-spacing: -0.03em; }
.lead-sm { font-size: clamp(16px, 1.25vw, 21px); line-height: 1.15; letter-spacing: -0.02em; margin-bottom: 14px; }
.services { flex: 1; font-size: clamp(20px, 1.65vw, 28px); line-height: 1.2; letter-spacing: -0.03em; }
.services li { display: flex; align-items: center; gap: 12px; }
.services li::before { content: ""; flex: none; width: 8px; height: 8px; background: var(--coral); }
.pos-text { font-size: clamp(16px, 1.2vw, 20px); line-height: 1.25; letter-spacing: -0.02em; }
.pos-text p + p { margin-top: .7em; }
.hero-intro .line-btn { border-top: 1px solid color-mix(in srgb, var(--on-ink) 25%, transparent); margin: 0 calc(-1 * var(--pad)) calc(-1 * var(--pad)); padding: 14px var(--pad); }

/* Logo ticker */
.ticker { overflow: hidden; margin: 0 calc(-1 * var(--pad)); -webkit-mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent); mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent); }
.ticker-track { display: flex; width: max-content; animation: tick 40s linear infinite; }
.ticker:hover .ticker-track, .ticker:focus-within .ticker-track { animation-play-state: paused; }
.logo { flex: none; display: flex; align-items: center; height: 40px; margin-right: 36px; }
.logo img { height: auto; max-height: 22px; width: auto; filter: grayscale(1) contrast(1.2); opacity: .9; }
@keyframes tick { to { transform: translateX(-50%); } }

/* Statement rows */
.statement { grid-template-rows: auto auto; }
.rotator-cell { background: var(--paper); display: flex; align-items: flex-end; min-height: clamp(180px, 15vw, 300px); }
.rotator { font-size: var(--stmt); line-height: 1.05; letter-spacing: -0.04em; white-space: nowrap; }

.rot-words { display: inline-grid; vertical-align: bottom; }
.rot-word {
  grid-area: 1 / 1;
  opacity: 0; transform: translateY(.12em);
  transition: opacity .55s ease, transform .9s var(--ease);
}
.rot-word.is-on { opacity: 1; transform: none; }
.shout-cell {
  display: grid; grid-template-columns: auto minmax(0, 1fr); grid-template-rows: auto auto 1fr;
  column-gap: var(--pad); min-height: clamp(360px, 32vw, 560px);
}
.shout-cell .shout { display: contents; font-size: var(--stmt); line-height: 1; letter-spacing: -0.04em; }
.sh1 { grid-column: 1 / 3; grid-row: 1; }
.sh2 { grid-column: 1 / 3; grid-row: 2; }
.shout-wheel { grid-column: 1 / 3; grid-row: 3; align-self: end; justify-self: end; width: min(100%, 320px); aspect-ratio: 1; margin-top: 8px; }

/* ============ Impact ============ */
.big-text { font-size: clamp(24px, 2.35vw, 40px); line-height: 1.12; letter-spacing: -0.035em; max-width: 24ch; }

/* ============ Numbers ============ */
.numbers .stat { min-height: clamp(220px, 17vw, 320px); padding-top: 24px; padding-bottom: 24px; }
.stat { display: flex; flex-direction: column; justify-content: space-between; gap: 24px; container-type: inline-size; }
.stat-num {
  font-size: min(104px, calc(150cqi / 7));
  line-height: .9; letter-spacing: -0.05em; white-space: nowrap;
  font-variant-numeric: tabular-nums;
}
.stat-label { font-size: 15px; line-height: 1.3; max-width: 30ch; }
.stat-src { font-size: 13px; line-height: 1.3; margin-top: 8px; opacity: .72; max-width: 32ch; }
.sec-head-row { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; }

.gap-window { height: clamp(120px, 11vw, 220px); }

/* Rolling digits */
.roll .d { display: inline-block; height: .9em; overflow: hidden; vertical-align: top; }
.roll .strip { display: flex; flex-direction: column; transform: translateY(0); transition: transform 1.8s var(--ease); }
.roll .strip span { display: block; height: .9em; line-height: .9; }
.roll .ch { display: inline-block; height: .9em; }

/* ============ Approach ============ */
.approach-side { display: flex; flex-direction: column; justify-content: space-between; gap: 40px; }
.approach-sticky { position: sticky; top: calc(var(--h) + var(--pad)); }
.approach-foot { margin-top: 40px; }
.approach-foot p { max-width: 38ch; }
.approach-list { padding: 0; }
.step {
  display: grid; grid-template-columns: 1fr 1fr; gap: 28px var(--pad);
  padding: var(--pad) var(--pad) 24px;
  min-height: 32vh; align-content: space-between;
  border-bottom: 1px solid color-mix(in srgb, var(--on-ink) 25%, transparent);
}
.step:last-child { border-bottom: 0; }
.step-head { display: flex; gap: 28px; align-items: baseline; }
.step-head .label { color: var(--ink-muted); }
.step h3 { font-size: clamp(28px, 2.2vw, 38px); line-height: 1; letter-spacing: -0.035em; font-weight: 600; color: var(--on-ink-strong); }
.step-desc { font-size: 15px; line-height: 1.35; max-width: 40ch; }
.bullets { grid-column: 2; }
.bullets li { display: flex; align-items: center; gap: 10px; padding: 3px 0; }
.bullets li::before { content: ""; width: 7px; height: 7px; background: var(--coral); flex: none; }

/* ============ Work ============ */
/* Section titles: a full-width strip with a coral rule above */
.sec-strip { position: relative; }
.sec-strip::before {
  content: ""; position: absolute; left: 0; right: 0; top: -1px; height: 1px;
  background: var(--coral); z-index: 2;
}
.sec-strip .cell { padding-top: 18px; padding-bottom: 18px; }
.sec-title {
  color: var(--coral); text-transform: uppercase; font-weight: 600;
  font-size: clamp(28px, 2.2vw, 38px); line-height: 1; letter-spacing: -0.025em;
}
.approach-sticky .sec-title { margin-bottom: 24px; }
.work .cell { min-height: 0; }
.work-intro p { max-width: 32ch; margin-bottom: 24px; }
.work-list { padding: 0; display: flex; flex-direction: column; }
.case { flex: 1; border-bottom: 1px solid var(--line); }
.case:last-child { border-bottom: 0; }
.case a {
  height: 100%; min-height: 112px;
  display: grid; grid-template-columns: 1fr auto; grid-template-rows: 1fr auto;
  gap: 8px 24px; padding: var(--pad);
  transition: background-color .25s;
}
.case a:hover, .case a:focus-visible { background: var(--accent); color: var(--on-accent); }
.case-name { font-size: clamp(28px, 2.7vw, 46px); line-height: 1; letter-spacing: -0.04em; }
.case-outcome { align-self: end; max-width: 42ch; }
.case-read { grid-column: 2; grid-row: 1 / 3; align-self: center; }

/* ============ Testimonials ============ */
.testimonials .cell { min-height: 14vw; }
.t-side { display: flex; flex-direction: column; justify-content: space-between; }
.t-nav { display: flex; align-items: center; gap: 4px; }
.t-arrow { padding: 6px 8px; font-size: 16px; line-height: 1; color: var(--muted); transition: color .2s, transform .2s; }
.t-arrow:hover { color: var(--fg); }
[data-t-prev]:hover { transform: translateX(-2px); }
[data-t-next]:hover { transform: translateX(2px); }
.t-quote { display: flex; flex-direction: column; justify-content: space-between; gap: 20px; }
.t-quote::before { content: "“"; font-size: 48px; line-height: .6; }
.t-item { font-size: clamp(20px, 1.8vw, 30px); line-height: 1.2; letter-spacing: -0.03em; max-width: 44ch; }
.t-item:not([hidden]) { animation: fade .5s var(--ease); }
.t-foot { display: flex; justify-content: space-between; align-items: flex-end; gap: 24px; }
.t-role { color: var(--muted); }
.t-count { color: var(--muted); }
@keyframes fade { from { opacity: 0; transform: translateY(8px); } }

/* ============ CTA ============ */
.cta {
  position: relative;
  height: calc(100svh - var(--h) - var(--foot));
  min-height: 300px;
  border-bottom: 1px solid var(--line);
}

/* ============ Footer ============ */
/* Footer: black brand box on the left; email + LinkedIn along its top edge; coral box beneath them */
.f-grid { grid-template-rows: auto 1fr; }
.f-brand { grid-row: 1 / 3; display: flex; flex-direction: column; justify-content: space-between; gap: 24px; height: 42svh; min-height: 320px; }
.f-mark { font-size: var(--shout); line-height: 1; letter-spacing: -0.05em; }   /* same size as "Diagnose to scale" */
.f-brand .label { color: var(--ink-muted); }
.f-row { grid-row: 1; border-top: 1px solid var(--line); margin-top: -1px; display: flex; justify-content: space-between; align-items: center; min-height: 52px; }
a.f-row { transition: background-color .25s; }
a.f-row:hover, a.f-row:focus-visible { background: color-mix(in srgb, var(--coral) 28%, var(--bg)); }
.f-cta { grid-row: 2; display: grid; grid-template-columns: 1fr auto; grid-template-rows: 1fr auto; gap: 12px 24px; }
.f-cta-title { font-size: clamp(28px, 3vw, 52px); line-height: 1; letter-spacing: -0.04em; }
.f-cta-arrow { grid-column: 2; grid-row: 1 / 3; align-self: end; width: clamp(56px, min(8vw, 12svh), 150px); }
.f-cta-meta { grid-column: 1; grid-row: 2; align-self: end; }


/* ============ Case study page ============ */
.case-main { grid-column: 1 / 4; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); align-content: start; min-width: 0; }
.case-main > .cell, .case-main > figure { grid-column: 1 / -1; }
.case-facts, .case-stats, .case-sec { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); margin: 0; }

.case-head { padding-top: 48px; }
.case-title { font-size: clamp(56px, 7vw, 140px); line-height: .92; letter-spacing: -0.05em; margin-top: 18px; }
.case-title .keep { white-space: nowrap; }   /* if the title wraps, it breaks before this part */
.case-lede { padding-bottom: 40px; }
.case-lede .big-text { max-width: 30ch; }
.case-facts dd { font-size: 17px; letter-spacing: -0.02em; margin-top: 4px; }
.case-facts .cell { padding-top: 12px; padding-bottom: 12px; border-right-color: transparent; }
.case-facts .cell:last-child { border-right-color: var(--line); }
.case-media { height: clamp(200px, 22vw, 400px); }
.case-stats .stat { min-height: 9vw; gap: 16px; }
.case-stats .stat-num { font-size: min(96px, calc(150cqi / 9)); }   /* sized so "~12 weeks" fits */

.case-sec-label h2 { font-size: clamp(24px, 2vw, 34px); line-height: 1.05; letter-spacing: -0.03em; font-weight: 600; margin-top: 10px; }
.case-sec-body { grid-column: 2 / 4; padding-bottom: 48px; }
.case-sec-body p { font-size: 16px; line-height: 1.5; max-width: 62ch; }
.case-sec-body p + p { margin-top: 1em; }
.case-sec-body .case-intro { font-size: clamp(20px, 1.6vw, 26px); line-height: 1.25; letter-spacing: -0.025em; max-width: 36ch; margin-bottom: 20px; }
.case-sec-body .bullets { grid-column: auto; margin-top: 8px; }
.case-stages { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 var(--pad); margin-top: 8px; }
.case-stages li { padding: 14px 0 18px; }
.case-stages .label { color: var(--muted); }
.case-stages h3 { font-size: 20px; font-weight: 600; letter-spacing: -0.02em; margin: 6px 0 6px; }
.case-stages p { font-size: 15px; }

.case-next { margin-top: 40px; }
.case-sec-body .case-note { font-size: 15px; color: var(--muted); max-width: 52ch; }
.case-next-btn {
  display: inline-flex; align-items: center; gap: 24px; margin-top: 10px;
  padding: 14px 16px; background: var(--ink); color: var(--on-ink);
  font-size: 15px; line-height: 1.3; letter-spacing: -0.01em; max-width: 52ch;
}
.case-next-btn:hover .arrow { transform: translateX(4px); }
.case-list li { display: flex; gap: 12px; align-items: baseline; font-size: clamp(18px, 1.4vw, 22px); line-height: 1.3; letter-spacing: -0.02em; padding: 8px 0; max-width: 44ch; }
.case-list li::before { content: ""; flex: none; width: 8px; height: 8px; background: var(--coral); transform: translateY(-2px); }

/* Work list column: plain, no imagery */
.case-aside { grid-column: 4 / 5; min-width: 0; background: var(--bg); border-right: 1px solid var(--line); }
.case-aside { position: relative; }
.case-aside::before {            /* coral rule between the case study and the work list */
  content: ""; position: absolute; left: -1px; top: 0; bottom: 0; width: 1px; background: var(--coral); z-index: 3;
}
.aside-box { padding: 14px var(--pad) 0; }
.aside-title { color: var(--coral); font-weight: 600; padding-bottom: 10px; }
.more-item { display: flex; gap: 12px; align-items: baseline; padding: 10px 0; border-top: 1px solid var(--line-soft); transition: color .2s; }
.more-list li:last-child .more-item { border-bottom: 1px solid var(--line-soft); }
.more-item .label { color: var(--muted); }
.more-item:hover .more-name { text-decoration: underline; text-underline-offset: 3px; }
.more-item[aria-current="page"], .more-item[aria-current="page"] .label { color: var(--coral); }
.more-name { font-size: 15px; line-height: 1.25; letter-spacing: -0.01em; }

/* ============ CV page (portfolio/cv.html) ============ */
/* The CV is a fixed 1600×900 sheet (16:9), sized in px so its proportions never change.
   main.js scales the whole sheet to fit the screen; the website's dot texture shows around it.
   Inside there are no boxes: four horizontal bands separated by rules, on the site's 4-column grid
   (360px columns, 32px gaps, 32px margins), so everything lines up from band to band.
     1 intro · 2 how I work + industry · 3 experience timeline + education/contact rail · 4 clients */
.cv-page { min-height: calc(100svh - var(--h)); display: flex; align-items: center; justify-content: center; padding: 32px; }
.cv-stage { --s: .8; flex: none; position: relative; width: calc(1600px * var(--s)); height: calc(900px * var(--s)); }
.cv-card {
  --cv-faint: #8C8C88; --cv-rule: var(--line-soft); --cv-band: #C9C9C4;
  --cv-accent: color-mix(in srgb, var(--coral) 80%, #000);
  position: absolute; left: 0; top: 0; width: 1600px; height: 900px; box-sizing: border-box;
  transform: scale(var(--s)); transform-origin: 0 0;
  display: grid; grid-template-rows: 172px 76px 1fr 108px;
  background: var(--bg); border: 1px solid var(--line); overflow: hidden;
  font-size: 14px; line-height: 20px; letter-spacing: -0.01em;
}
:root[data-theme="dark"] .cv-card { --cv-accent: var(--coral); --cv-faint: #77776F; --cv-band: #4A4A48; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .cv-card { --cv-accent: var(--coral); --cv-faint: #77776F; --cv-band: #4A4A48; } }

.cv-band { display: grid; grid-template-columns: repeat(4, 360px); column-gap: 32px; padding: 0 32px; border-bottom: 1px solid var(--cv-band); min-height: 0; }
.cv-band:last-child { border-bottom: 0; }
.cv-sec { color: var(--cv-accent); text-transform: uppercase; font-weight: 600; font-size: 12px; line-height: 16px; letter-spacing: .04em; }
.cv-muted { color: var(--muted); }
.cv-card .label { font-size: 11px; line-height: 16px; color: var(--cv-faint); }

/* Band 1: name and services | summary */
.cv-intro { align-items: end; padding-bottom: 24px; }
.cv-intro-name { grid-column: 1 / 3; }
.cv-intro h1 { font-size: 88px; line-height: 1; font-weight: 500; letter-spacing: -0.05em; margin-left: -4px; white-space: nowrap; }
.cv-services { display: flex; gap: 22px; margin-top: 14px; font-size: 16px; }
.cv-services li { display: flex; align-items: center; gap: 8px; }
.cv-services li::before { content: ""; width: 7px; height: 7px; background: var(--coral); }
.cv-intro-sum { grid-column: 3 / 5; font-size: 18px; line-height: 26px; letter-spacing: -0.02em; }
.cv-intro-sum p + p { margin-top: 8px; color: var(--muted); }

/* Band 2: how I work, as soft pills */
.cv-how { align-items: center; }
.cv-how .cv-sec { grid-column: 1; }
.cv-pills { display: flex; flex-wrap: wrap; gap: 8px; }
.cv-how .cv-pills { grid-column: 2 / 5; }
.cv-pill { display: inline-flex; padding: 6px 14px; border-radius: 999px; font-size: 14px; line-height: 20px; background: color-mix(in srgb, var(--coral) 13%, var(--bg)); }
.cv-pills-quiet .cv-pill { padding: 5px 12px; font-size: 13px; line-height: 18px; background: color-mix(in srgb, var(--fg) 6%, var(--bg)); }

/* Band 3: experience timeline (columns 1–3) | education and contact (column 4) */
.cv-main { padding-top: 16px; }
.cv-exp { grid-column: 1 / 4; display: flex; flex-direction: column; min-height: 0; }
/* when | company + title | my role | impact (figure + project). Role and project text are the same width */
.cv-row { display: grid; grid-template-columns: 96px 220px 318px 438px; column-gap: 24px; }
.cv-row-head { padding-bottom: 8px; }
.cv-row-head .cv-h-imp { grid-column: 4; }
.cv-job { padding: 11px 0 12px; border-top: 1px solid var(--cv-rule); transition: background-color .2s; }
.cv-job:hover { background: color-mix(in srgb, var(--coral) 6%, var(--bg)); box-shadow: -12px 0 0 color-mix(in srgb, var(--coral) 6%, var(--bg)), 12px 0 0 color-mix(in srgb, var(--coral) 6%, var(--bg)); }
.cv-when { padding-top: 3px; }
.cv-co { font-size: 17px; line-height: 22px; font-weight: 600; letter-spacing: -0.02em; }
.cv-title { color: var(--muted); font-size: 13px; line-height: 18px; margin-top: 2px; }
.cv-imps { display: flex; flex-direction: column; gap: 8px; }
.cv-job > p, .cv-imp > span:last-child { text-wrap: balance; }   /* even line lengths, no one-word last lines */
.cv-imp { display: grid; grid-template-columns: 96px 318px; column-gap: 24px; align-items: baseline; }
.cv-num { color: var(--cv-accent); font-size: 22px; line-height: 22px; letter-spacing: -0.03em; font-variant-numeric: tabular-nums; white-space: nowrap; }
.cv-num.roll .d, .cv-num.roll .ch, .cv-num.roll .strip span { height: 22px; line-height: 22px; }
.cv-earlier { border-top: 1px solid var(--cv-rule); padding-top: 10px; color: var(--muted); font-size: 13px; }
.cv-earlier a { color: var(--fg); text-decoration: underline; text-underline-offset: 3px; }

.cv-rail { grid-column: 4; display: flex; flex-direction: column; gap: 28px; font-size: 13px; line-height: 18px; }
.cv-rail .cv-sec { margin-bottom: 10px; }
.cv-edu li + li { margin-top: 10px; }
.cv-edu b { display: block; font-weight: 600; }
.cv-edu span { color: var(--muted); }
.cv-contact li + li { margin-top: 4px; }
.cv-contact a { color: var(--cv-accent); }
.cv-contact a:hover { text-decoration: underline; text-underline-offset: 3px; }

/* Band 4: industry | clients, two equal halves. Logos drift left to right; every logo in place in the PDF */
.cv-foot { align-items: start; padding-top: 20px; }   /* both labels on one line */
.cv-foot-half { grid-column: 1 / 3; display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.cv-foot-half + .cv-foot-half { grid-column: 3 / 5; }
.cv-foot .ticker { margin: 0; }
.cv-card .logo { height: 32px; margin-right: 40px; }
.cv-card .logo img { max-height: 17px; max-width: 92px; }
:root[data-theme="dark"] .cv-card .logo img { filter: grayscale(1) invert(1); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .cv-card .logo img { filter: grayscale(1) invert(1); } }

.h-contact[download] { white-space: nowrap; }   /* "Download CV" stays on one line; on small phones it reads "CV ↓" */
@media screen and (max-width: 420px) {
  .h-contact[download] .dl-word { display: none; }
  .h-contact[download] .arrow { display: inline-block; }
}

/* Menu: an item that isn't live yet */
.menu .menu-soon { display: flex; align-items: baseline; gap: 24px; padding: 14px var(--pad); font-size: clamp(32px, 3.4vw, 56px); line-height: 1; letter-spacing: -0.04em; color: var(--muted); }
.menu .menu-soon .label:last-child { margin-left: auto; }
.menu a[aria-current="page"] { color: var(--coral); }

@media screen and (max-width: 700px) {
  .cv-page { padding: 12px; align-items: flex-start; }   /* the sheet shrinks to the phone's width; pinch to zoom */
}

/* The downloadable PDF is printed from this page: the sheet alone on one 16:9 page, always light */
@page cv { size: 1600px 900px; margin: 0; }
@media print {
  :root:root {
    --bg: #F7F7F4; --fg: #232323; --muted: #5E5E5B; --line: #232323; --ink: #2B2B2B; --on-ink: #F7F7F4;
    --on-ink-strong: #FFFFFF; --line-soft: #DCDCD8; --paper: #FFFFFF; --ink-muted: #A8A8A3; --grey: #D9D9D6; --dot: #1E1E1E;
    color-scheme: light;
  }
  body { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  .skip, .site-header, .bg { display: none !important; }
  *, *::before, *::after { transition: none !important; animation: none !important; }
  .cv-page { display: block; padding: 0; min-height: 0; }
  .cv-stage { page: cv; width: 1600px; height: 900px; }
  .cv-card { transform: none; }
  .cv-foot .ticker { -webkit-mask-image: none; mask-image: none; }
  .cv-foot .ticker-track { width: 100%; flex-wrap: wrap; justify-content: space-between; gap: 6px 18px; animation: none; }
  .cv-foot .ticker-track [aria-hidden="true"] { display: none; }
  .cv-card .logo { margin-right: 0; height: 22px; }
  .cv-card .logo img { filter: grayscale(1) contrast(1.2); }
}

/* ============ Reveal ============ */
.js .reveal { opacity: 0; transform: translateY(16px); transition: opacity .9s var(--ease), transform .9s var(--ease); }
.js .reveal.in { opacity: 1; transform: none; }

/* ============ Responsive ============ */
@media screen and (max-width: 900px) {
  :root { --h: 56px; --display: 25vw; --shout: 16vw; }
  .grid { grid-template-columns: 1fr; }
  .grid > .cell { grid-column: 1 / -1 !important; grid-row: auto !important; min-height: 0; }

  .site-header { grid-template-columns: 1fr auto auto; }
  .h-brand { grid-column: 1; border-right: 0; }
  .h-tools { grid-column: 2; gap: 4px; padding: 0 12px; border-left: 1px solid var(--line); }
  .h-contact { grid-column: 3; gap: 12px; }
  .menu { width: 100%; }

  .hero { min-height: 0; grid-template-rows: none; }
  .hero .name-cell { min-height: 38vw; }
  .hero .window, .statement .window { min-height: 44vw; }
  .hero-intro, .hero-pos { min-height: 260px; }
  .rotator-cell { min-height: 36vw; }
  .rotator { font-size: 5.6vw; }
  .shout-cell { min-height: 0; grid-template-columns: 1fr; }
  .shout-cell .shout { font-size: 10vw; }
  .sh1, .sh2 { grid-column: 1; }
  .shout-wheel { grid-column: 1; grid-row: 3; width: 72vw; max-width: none; margin-top: 8px; }


  .numbers .stat { min-height: 44vw; }

  .approach-sticky { position: static; }
  .step { grid-template-columns: 1fr; min-height: 0; gap: 20px; padding-bottom: 28px; }
  .bullets { grid-column: 1; }

  .work .cell, .testimonials .cell { min-height: 0; }
  .work-intro { padding-bottom: 28px; }
  .case a { grid-template-columns: 1fr; }
  .case-read { grid-column: 1; grid-row: auto; }

  .t-side { flex-direction: row; align-items: flex-start; }
  .t-quote { min-height: 44vw !important; }

  .cta { height: 50svh; }

  .f-brand { height: auto; min-height: 70vw; }

  .case-main, .case-aside { grid-column: 1 / -1; }
  .case-main, .case-facts, .case-stats, .case-sec { grid-template-columns: 1fr; }
  .case-sec-body { grid-column: 1; }
  .case-sec-label { border-bottom: 0; padding-bottom: 0; }
  .case-stages { grid-template-columns: 1fr; }
  .case-title .keep { white-space: normal; }
  .case-stats .stat { min-height: 44vw; }
  .case-aside::before { display: none; }
  .f-cta { min-height: 44vw; }
}
@media screen and (max-width: 420px) {
  .h-brand { gap: 12px; }
  .h-name { font-size: 14px; white-space: nowrap; }
  .h-contact .arrow { display: none; }
  .h-tools { padding: 0 10px; }
}
@media screen and (max-width: 340px) {
  .h-name { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .js .reveal { opacity: 1; transform: none; }
}
