/* =========================================================================
   Pluxbox Portfolio — Shared Case-Study Design System
   Geist / Geist Mono. Consumed by every /case/<slug>/ page.
   Tokens + type scale + reusable section components.
   ========================================================================= */

/* ---------- Design tokens ---------- */
:root {
  /* semantic colors */
  --bg-canvas: #ffffff;
  --bg-muted: #fafafa;
  --bg-inverse: #0a0a0a;
  --text-primary: #0a0a0a;
  --text-secondary: #525252;
  --text-muted: #a3a3a3;
  --text-inverse: #ffffff;
  --text-inverse-muted: rgba(255, 255, 255, 0.6);
  --text-accent: #2d5bff;
  --accent: #2d5bff;
  --border-default: #d4d4d4;
  --border-strong: #0a0a0a;

  /* site nav (pill menu) */
  --nav-bg: rgba(45, 91, 255, 0.09);
  --nav-cta: #f54900;

  /* type families */
  --sans: "Geist", "Inter", system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  --mono: "Geist Mono", ui-monospace, "SF Mono", Menlo, Consolas, monospace;

  /* layout */
  --content: 1248px;
  --pad-x: 96px;

  /* motion system — tweak these live (some are mirrored in shared/motion.js) */
  --dur-fast: 150ms;     /* hovers */
  --dur-base: 350ms;     /* element entrances */
  --dur-slow: 600ms;     /* large reveals / image blur-up */
  --ease-entrance: cubic-bezier(.2, .7, .2, 1);
  --ease-sharp: cubic-bezier(.76, 0, .24, 1);   /* mechanical — same as the wipe */
  --reveal-shift: 18px;            /* entrance translateY distance */
  --reveal-dur: var(--dur-base);   /* entrance duration */
  --reveal-stagger: 70ms;          /* delay between sibling reveals */
  --img-blur: 12px;                /* image blur-up start amount */
  --card-hover-scale: 1.03;        /* work-card image hover */
  --link-nudge: 3px;               /* arrow / link hover shift */
}

/* reduced motion: kill movement everywhere — keep a quick opacity fade only.
   Done with tokens so the selector lists below never need repeating. */
@media (prefers-reduced-motion: reduce) {
  :root {
    --reveal-shift: 0px;
    --reveal-dur: 200ms;
    --img-blur: 0px;
    --card-hover-scale: 1;
    --link-nudge: 0px;
  }
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
  margin: 0;
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.5;
  color: var(--text-primary);
  background: var(--bg-canvas);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}
img { display: block; max-width: 100%; }
p, h1, h2, h3, figure, blockquote { margin: 0; }
h1, h2, h3 { font-weight: 500; }

/* ---------- Type scale (matches Figma styles) ---------- */
.display-xxl { font-family: var(--sans); font-weight: 500; font-size: 80px; line-height: 1;    letter-spacing: -0.03em; }
.display-xl  { font-family: var(--sans); font-weight: 500; font-size: 72px; line-height: 1;    letter-spacing: -0.02em; }
.display-l   { font-family: var(--sans); font-weight: 500; font-size: 64px; line-height: 1.05; letter-spacing: -0.02em; }
.heading-xl  { font-family: var(--sans); font-weight: 500; font-size: 48px; line-height: 1.1;  letter-spacing: -0.015em; }
.heading-l   { font-family: var(--sans); font-weight: 500; font-size: 32px; line-height: 1.2;  letter-spacing: -0.01em; }
.heading-m   { font-family: var(--sans); font-weight: 500; font-size: 24px; line-height: 1.3;  letter-spacing: -0.005em; }
.heading-s   { font-family: var(--sans); font-weight: 500; font-size: 18px; line-height: 1.4; }
.body-l      { font-family: var(--sans); font-weight: 400; font-size: 20px; line-height: 1.5; }
.body-m      { font-family: var(--sans); font-weight: 400; font-size: 16px; line-height: 1.5; }
.body-s      { font-family: var(--sans); font-weight: 400; font-size: 14px; line-height: 1.5; }
.label-m     { font-family: var(--mono); font-weight: 500; font-size: 12px; line-height: 1.4; letter-spacing: 0.04em; }
.label-s     { font-family: var(--mono); font-weight: 500; font-size: 11px; line-height: 1.4; letter-spacing: 0.06em; }
.mono-m      { font-family: var(--mono); font-weight: 400; font-size: 14px; line-height: 1.5; }
.mono-s      { font-family: var(--mono); font-weight: 400; font-size: 12px; line-height: 1.5; }

/* color helpers */
.c-secondary { color: var(--text-secondary); }
.c-muted     { color: var(--text-muted); }
.c-accent    { color: var(--text-accent); }

/* ---------- Section shell ---------- */
.section { width: 100%; }
.section__inner {
  max-width: calc(var(--content) + 2 * var(--pad-x));
  margin: 0 auto;
  padding: 120px var(--pad-x);
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}
.section--dark  { background: var(--bg-inverse); color: var(--text-inverse); }
.section--muted { background: var(--bg-muted); }

.gap-24 { gap: 24px; }
.gap-32 { gap: 32px; }
.gap-48 { gap: 48px; }
.gap-64 { gap: 64px; }
.gap-80 { gap: 80px; }

/* full-bleed black hairline divider */
.divider { width: 100%; height: 1px; background: var(--border-strong); }

/* a 1000px measure column with 24px rhythm (TL;DR + Key Insight bodies) */
.body-1000 { display: flex; flex-direction: column; gap: 24px; align-items: flex-start; width: 100%; max-width: 1000px; }

/* ---------- Section header ---------- */
.sec-head { display: flex; flex-direction: column; gap: 24px; align-items: flex-start; width: 100%; }
.sec-head__label { display: flex; gap: 12px; align-items: center; }
.sec-head__dot { width: 8px; height: 8px; background: var(--accent); flex: none; }
.sec-head__kicker { color: var(--text-muted); white-space: nowrap; }
.sec-head__title { color: var(--text-primary); }
.sec-head--inverse .sec-head__title { color: var(--text-inverse); }

/* =========================================================================
   SITE NAV (pill menu) — shared across every page
   ========================================================================= */
.site-nav { display: flex; justify-content: center; padding-top: 30px; }
.navpills {
  display: inline-flex; align-items: center; gap: 4px;
  background: var(--nav-bg); border-radius: 23px; padding: 4.5px;
}
.navpills a {
  font-family: var(--sans); font-weight: 500; font-size: 18px; line-height: 1.5;
  color: #0a0a0a; background: #fff; border-radius: 23px; padding: 7px 16px;
  text-decoration: none; transition: background-color .15s ease, color .15s ease;
}
.navpills a:hover { background: var(--accent); color: #fff; }
.navpills a.is-cta { background: var(--nav-cta); color: #fff; }
.navpills a.is-cta:hover { background: var(--accent); color: #fff; }

/* =========================================================================
   HERO
   ========================================================================= */
.hero {
  background: linear-gradient(180deg,
      rgb(5, 10, 31) 0%,
      rgb(13, 42, 107) 38%,
      rgb(43, 84, 196) 68%,
      rgb(197, 205, 240) 100%);
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 104px var(--pad-x) 0;  /* top room for the fixed pill nav */
}
/* case-page menu: fixed to the top so it travels with the page on scroll */
.hero__nav {
  position: fixed; top: 24px; left: 50%; transform: translateX(-50%);
  z-index: 200; margin: 0;
  background: rgba(230, 236, 255, 0.25);  /* lighter menu bg over the dark case hero */
  -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
  box-shadow: 0 10px 30px rgba(10, 10, 10, 0.14);
}
.hero__kicker { color: var(--text-muted); }
.hero__title-block {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 32px;
  max-width: var(--content);
  margin-top: 50px;
}
.hero__title { color: var(--bg-canvas); }
.hero__subtitle { color: var(--bg-muted); white-space: nowrap; }
.hero__media {
  width: 976px;
  max-width: 100%;
  margin-top: 49px;
  border-radius: var(--media-radius, 11px);
  overflow: hidden;
  box-shadow: 0 40px 80px -20px rgba(5, 10, 31, 0.45);
}
.hero__media img { width: 100%; height: auto; }

/* =========================================================================
   METADATA  (dark)
   ========================================================================= */
.meta__inner { padding-top: 56px; padding-bottom: 56px; gap: 48px; }
.meta-row { display: flex; align-items: flex-start; justify-content: space-between; width: 100%; }
.meta-cell { display: flex; flex-direction: column; gap: 8px; width: 192px; }
.meta-cell__label { color: var(--text-muted); }
.meta-cell__value { color: var(--text-inverse); }
.meta-cell--ghost { visibility: hidden; }

/* =========================================================================
   METRICS  (dark) — cards flex to fill (works at 2 / 3 / 4 up)
   ========================================================================= */
.metrics-grid { display: flex; align-items: stretch; width: 100%; }
.metric-card {
  flex: 1 1 0;
  min-width: 0;
  min-height: 240px;
  display: flex;
  flex-direction: column;
  gap: 24px;
  padding: 40px 32px;
  background: var(--bg-inverse);
  border-top: 1px solid var(--border-default);
}
.metric-card__label { color: var(--text-muted); white-space: nowrap; }
.metric-card__num { display: flex; flex-direction: column; gap: 4px; }
.metric-card__value { color: var(--text-inverse); white-space: nowrap; }
.metric-card__sub { color: var(--text-inverse-muted); }
.metric-card__strip { width: 64px; height: 4px; background: var(--accent); margin-top: auto; }

/* detail table */
.dtable { width: 100%; border-top: 1px solid var(--border-default); }
.dtable__row { display: flex; align-items: flex-start; border-bottom: 1px solid var(--border-default); }
.dtable__row--head { padding: 16px 0; color: var(--text-muted); }
.dtable__row--data { padding: 20px 0; }
.dtable__metric { flex: 1 1 0; min-width: 0; color: var(--text-inverse); }
.dtable__before { width: 240px; flex: none; color: var(--text-muted); }
.dtable__after  { width: 240px; flex: none; color: var(--text-inverse); }
.dtable__row--head .dtable__metric,
.dtable__row--head .dtable__before,
.dtable__row--head .dtable__after { color: var(--text-muted); }

/* footnote under a section block (e.g. sample-size disclaimer) */
.table-note { width: 100%; color: var(--text-muted); }

/* =========================================================================
   CONTEXT
   ========================================================================= */
.figure { width: 100%; }
.figure img { width: 100%; height: auto; }

.context-body { display: flex; flex-direction: column; gap: 32px; align-items: flex-start; width: 100%; }
.measure { max-width: 1000px; }
.pullquote {
  width: 100%;
  padding: 24px 0;
  border-top: 1px solid var(--border-strong);
  border-bottom: 1px solid var(--border-strong);
}
.pullquote p { color: var(--text-primary); }
.sub-block { display: flex; flex-direction: column; gap: 8px; max-width: 1000px; }
.sub-block--pad { padding-top: 16px; gap: 16px; }
.sub-block__label { color: var(--text-muted); }
.sub-block p + p { color: var(--text-primary); }

/* two-up persona row (label + body) */
.persona-row { display: flex; gap: 64px; align-items: flex-start; width: 100%; }
.persona { flex: 1 1 0; min-width: 0; display: flex; flex-direction: column; gap: 8px; }
.persona__label { color: var(--text-muted); }
.persona__body { color: var(--text-primary); }

/* =========================================================================
   ROLE  (column order is set per page in markup)
   ========================================================================= */
.role-cols { display: flex; gap: 96px; align-items: flex-start; justify-content: center; width: 100%; }
.role-col {
  flex: 1 1 0;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 24px;
  padding-top: 24px;
  border-top: 1px solid var(--border-strong);
}
.role-col__label { color: var(--text-muted); white-space: nowrap; }

/* =========================================================================
   PROCESS — grid, --cols controls columns (5 default, 4 for the 7-step case)
   ========================================================================= */
.process-row {
  display: grid;
  grid-template-columns: repeat(var(--cols, 5), minmax(0, 1fr));
  gap: 16px;
  width: 100%;
  align-items: stretch;
}
.process-row--4 { --cols: 4; }
.step {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 24px;
  padding: 32px 24px;
  background: var(--bg-canvas);
  border-top: 1px solid var(--border-strong);
}
.step__head { display: flex; gap: 16px; align-items: center; }
.step__num { color: var(--text-primary); }
.step__tag { color: var(--text-muted); white-space: nowrap; }
.step__title { color: var(--text-primary); }
.step__desc { color: var(--text-secondary); }

.callout {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding: 40px 48px;
  background: var(--bg-muted);
}
.callout__label { color: var(--text-muted); }
.callout__text { color: var(--text-primary); }

/* =========================================================================
   DECISIONS
   ========================================================================= */
.decisions__inner { gap: 64px; }
.decisions-stack { display: flex; flex-direction: column; width: 100%; }
.decision-img { width: 100%; height: auto; }

.decision-featured {
  display: flex;
  flex-direction: column;
  gap: 48px;
  padding: 64px 0;
  border-top: 1px solid var(--border-strong);
  background: var(--bg-canvas);
}
/* featured blocks that sit directly below an image need no top rule */
.decision-featured--flush { border-top: none; }
.decision-featured__head { display: flex; gap: 64px; align-items: flex-start; width: 100%; }
.decision-featured__left { width: 320px; flex: none; display: flex; flex-direction: column; gap: 16px; }
.decision-featured__num { color: var(--text-primary); }
.decision-featured__tag { color: var(--text-muted); }
.decision-featured__right { flex: 1 1 0; min-width: 0; display: flex; flex-direction: column; gap: 24px; }
.decision-featured__title { color: var(--text-primary); }
.decision-featured__lead { color: var(--text-secondary); }
.decision-featured__body { padding-left: 384px; padding-top: 32px; }
.decision-featured__body p { color: var(--text-primary); }
.decision-featured__body p + p { margin-top: 24px; }

.decision-compact { padding: 40px 0; width: 100%; }
/* soft rule when two compacts stack with no image between them */
.decision-compact--rule { border-top: 1px solid var(--border-default); }
.decision-compact__head { display: flex; gap: 32px; align-items: flex-start; width: 100%; }
.decision-compact__left { width: 160px; flex: none; display: flex; flex-direction: column; gap: 8px; }
.decision-compact__num { color: var(--text-primary); }
.decision-compact__tag { color: var(--text-muted); }
.decision-compact__center { flex: 1 1 0; min-width: 0; display: flex; flex-direction: column; gap: 12px; }
.decision-compact__title { color: var(--text-primary); }
.decision-compact__desc { color: var(--text-secondary); }
.decision-compact__right { width: 240px; flex: none; visibility: hidden; }

/* =========================================================================
   ARTIFACTS
   ========================================================================= */
.artifacts-list { display: flex; flex-direction: column; width: 100%; }
.artifact-row {
  display: flex;
  gap: 32px;
  align-items: center;
  padding: 24px 0;
  border-bottom: 1px solid var(--border-default);
}
.artifact-row__num { width: 40px; flex: none; color: var(--text-muted); }
.artifact-row__name { width: 320px; flex: none; color: var(--text-primary); }
.artifact-row__desc { flex: 1 1 0; min-width: 0; color: var(--text-secondary); }

/* access markers: one or more 36px dots (tool logos and/or preview thumbnails) */
.access-pill { display: flex; gap: 2px; align-items: center; flex: none; }
.access-dot {
  width: 36px;
  height: 36px;
  flex: none;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.access-dot--thumb { border-radius: 4px; background: var(--text-muted); }
.access-dot--thumb img { width: 100%; height: 100%; object-fit: cover; }
.access-dot--logo img { max-width: 30px; max-height: 30px; width: auto; height: auto; }
/* single-logo convenience (design-system case) */
.artifact-row__logo { width: 36px; height: 36px; flex: none; display: flex; align-items: center; justify-content: center; }
.artifact-row__logo img { max-width: 30px; max-height: 30px; width: auto; height: auto; }

/* =========================================================================
   QUALITATIVE  (two columns)
   ========================================================================= */
.qual-body { display: flex; gap: 96px; align-items: flex-start; width: 100%; }
.qual-col { flex: 1 1 0; min-width: 0; display: flex; flex-direction: column; gap: 24px; }
.qual-col__label { color: var(--text-muted); }
.qual-col p + p,
.qual-col__text { color: var(--text-primary); }

/* =========================================================================
   REFLECTION
   ========================================================================= */
.reflection-list { display: flex; flex-direction: column; gap: 48px; width: 100%; }
.reflection { display: flex; gap: 48px; align-items: flex-start; width: 100%; }
.reflection__num { width: 120px; flex: none; color: var(--text-muted); }
.reflection__right { flex: 1 1 0; min-width: 0; display: flex; flex-direction: column; gap: 8px; }
.reflection__title { color: var(--text-primary); }
.reflection__desc { color: var(--text-secondary); }

/* =========================================================================
   NEXT  (muted) — cards flex to fill (works at 3 / 4 up)
   ========================================================================= */
.next-grid { display: flex; gap: 24px; align-items: stretch; width: 100%; }
.next-card {
  flex: 1 1 0;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding: 32px 28px;
  background: var(--bg-canvas);
}
.next-card__tag { color: var(--text-accent); }
.next-card__title { color: var(--text-primary); }
.next-card__desc { color: var(--text-secondary); }

/* =========================================================================
   FOOTER  (dark)
   ========================================================================= */
.footer__inner { gap: 64px; }
.footer-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 48px; width: 100%; }
.footer-top__left { display: flex; flex-direction: column; gap: 16px; }
.footer-top__kicker { color: var(--text-muted); }
.footer-top__title { color: var(--text-inverse); }
.footer-top__sub { color: var(--text-inverse-muted); }
.footer-top__right { color: var(--text-muted); white-space: nowrap; }
.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  width: 100%;
  padding-top: 48px;
  border-top: 1px solid var(--border-default);
  color: var(--text-inverse-muted);
}
/* footer links (case pages) — next-case teaser + contact line */
.footer-next { text-decoration: none; color: inherit; transition: transform .2s ease; will-change: transform; }
.footer-next:hover { transform: translateX(6px); }
.footer-link { color: inherit; text-decoration: none; transition: color .15s ease; }
.footer-link:hover { color: var(--text-inverse); }

/* =========================================================================
   ADDITIONS — used by the Stolpersteine case (shared / reusable)
   ========================================================================= */
/* generic vertical stack (combine with .gap-*) */
.stack { display: flex; flex-direction: column; align-items: flex-start; width: 100%; }

/* hero — warm / amber gradient variant + narrower media */
.hero--amber {
  background: linear-gradient(180deg,
      rgb(31, 23, 5) 0%,
      rgb(107, 68, 13) 38%,
      rgb(196, 132, 43) 68%,
      rgb(240, 220, 197) 100%);
}
.hero--amber .hero__media { box-shadow: 0 40px 80px -20px rgba(31, 23, 5, 0.5); }

/* footnote variant for dark sections */
.table-note--inverse { color: var(--text-inverse-muted); }

/* award feature-callout — bordered box on a dark section */
.award-callout {
  width: 100%;
  border: 1px solid var(--border-default);
  padding: 48px;
  display: flex;
  flex-direction: column;
  gap: 48px;
}
.award-callout__top { display: flex; gap: 48px; align-items: flex-start; width: 100%; }
.award-callout__left { width: 320px; flex: none; display: flex; flex-direction: column; gap: 12px; }
.award-callout__label { color: var(--text-muted); }
.award-callout__title { color: var(--text-inverse); }
.award-callout__meta { color: var(--text-inverse-muted); }
.award-callout__right { flex: 1 1 0; min-width: 0; border-left: 1px solid var(--border-default); padding-left: 48px; }
.award-callout__right p { color: var(--text-inverse); }
.award-callout__img { width: 100%; aspect-ratio: 1152 / 367; overflow: hidden; }
.award-callout__img img { width: 100%; height: 100%; object-fit: cover; }

/* "what carries forward into B2B" transfer block — muted panel + definition list */
.b2b-block {
  width: 100%;
  background: var(--bg-muted);
  padding: 48px;
  display: flex;
  flex-direction: column;
  gap: 32px;
}
.b2b-block__label { color: var(--text-muted); }
.b2b-block__heading { color: var(--text-primary); }
.b2b-list { display: flex; flex-direction: column; gap: 20px; width: 100%; }
.b2b-item { display: flex; gap: 24px; align-items: flex-start; width: 100%; }
.b2b-item__term { width: 280px; flex: none; color: var(--text-primary); }
.b2b-item__desc { flex: 1 1 0; min-width: 0; color: var(--text-secondary); }

/* access-dot variants — app store / play / award badge */
.access-dot--store { border-radius: 4px; }
.access-dot--store img { width: 100%; height: 100%; object-fit: cover; }
.access-dot--play { border-radius: 4px; background: #f2f2f7; }
.access-dot--play img { max-width: 26px; max-height: 26px; width: auto; height: auto; }
.access-dot--badge img { width: 100%; height: 100%; object-fit: cover; }

/* =========================================================================
   CUSTOM CURSOR (mouse only; toggled by shared/cursor.js adding .has-custom-cursor)
   ========================================================================= */
html.has-custom-cursor, html.has-custom-cursor * { cursor: none !important; }
.cursor { position: fixed; left: 0; top: 0; z-index: 99999; pointer-events: none; opacity: 0; transition: opacity .2s ease; will-change: transform; }
.cursor.is-visible { opacity: 1; }
.cursor__dot, .cursor__label { position: absolute; left: 0; top: 0; }
.cursor__dot {
  width: 17px; height: 17px; border-radius: 50%; background: var(--nav-cta);
  transform: translate(-50%, -50%);
  transition: opacity .18s ease, transform .18s ease;
}
.cursor__label {
  display: flex; align-items: center; height: 22px; padding: 0 11px;
  background: var(--nav-cta); color: #fff; border-radius: 11px;
  font-family: var(--sans); font-weight: 500; font-size: 11px; line-height: 1;
  letter-spacing: 0.03em; text-transform: uppercase; white-space: nowrap;
  opacity: 0; transform: translate(-50%, -50%) scale(0.6);
  transition: opacity .18s ease, transform .18s ease;
}
.cursor.is-label .cursor__dot { opacity: 0; transform: translate(-50%, -50%) scale(0.4); }
.cursor.is-label .cursor__label { opacity: 1; transform: translate(-50%, -50%) scale(1); }
.cursor.is-down .cursor__dot { transform: translate(-50%, -50%) scale(0.7); }

/* =========================================================================
   PIXEL-WIPE TRANSITION (intro loader + page transitions)
   A full-screen overlay of brand-blue square cells that scale 0↔1 in a
   diagonal TL→BR wave. Built / torn down by shared/transition.js; the tunable
   timing constants live there. Reduced-motion → a plain solid-blue fade.
   ========================================================================= */
/* Pre-paint cover: a tiny inline <head> script adds .wipe-cover so the very
   first paint of an intro / transition-arrival is already solid blue (no flash
   of page content before the JS grid is ready). transition.js removes it once
   the grid covers; an inline safety-timeout also clears it if JS never runs. */
html.wipe-cover::before {
  content: ""; position: fixed; inset: 0; background: var(--accent);
  z-index: 9998; pointer-events: none;
}

.wipe { position: fixed; inset: 0; z-index: 9999; pointer-events: none; }
.wipe__grid { position: absolute; inset: 0; }
.wipe__grid.is-instant .wipe__cell { transition: none !important; }
.wipe__cell {
  position: absolute; background: var(--accent);
  transform: scale(0); transform-origin: center;
  transition: transform var(--wipe-cell-dur, 260ms) var(--wipe-ease, cubic-bezier(.76, 0, .24, 1));
}
.wipe__cell.is-on { transform: scale(1); }
/* promote to a layer only while a wave is running, never at idle (lightweight) */
.wipe__grid.is-anim .wipe__cell { will-change: transform; }

/* reduced-motion: no cell wave — the overlay is one solid panel that fades */
.wipe--solid { background: var(--accent); }

.wipe__logo {
  position: absolute; inset: 0; display: grid; place-items: center;
  opacity: 0; transform: scale(.92);
  transition: opacity .15s ease, transform .42s cubic-bezier(.2, .8, .2, 1);
}
.wipe__logo.is-show { opacity: 1; transform: scale(1); }
.wipe__logo img { width: 150px; height: auto; display: block; }
.wipe__logo.is-big img { width: 230px; }

/* =========================================================================
   MOTION SYSTEM — entrance reveals, hover, image blur-up, nav-on-scroll.
   Engine: shared/motion.js. The hidden state is gated on <html class="motion">
   (added pre-paint by the inline head snippet) so there's no FOUC and JS-off
   visitors see everything. The selector lists below MUST stay in sync with
   HERO_SEL / SCROLL_SEL / the image list in shared/motion.js.
   ========================================================================= */

/* entrance reveal — opacity + small rise, once. Per-element stagger delay is
   set inline by motion.js; `.is-revealed` (added by JS) wins on specificity. */
html.motion :where(
  .hero__kicker, .hero__title, .hero__subtitle, .hero__media,
  .brand, .hero-headline, .recent-card,
  .work-header__kicker, .work-header__title, .work-header__body,
  .about-hero__text > div,
  .sec-head, .metric-card, .dtable, .figure, .pullquote, .sub-block,
  .role-col, .step, .callout, .decision-featured, .decision-compact,
  .artifact-row, .qual-col, .reflection, .next-card, .footer-next, .footer-bottom,
  .stats__label, .stat, .feat-card, .grid-card, .contact__cta, .contact__right,
  .work-card, .work-mini, .work-wide, .work-nda,
  .about-band__group, .howiwork-row, .teaching__cell, .about-beyond .about-kicker,
  .beyond-photo, .beyond__text, .about-details, .about-cta
) {
  opacity: 0;
  transform: translateY(var(--reveal-shift));
  transition: opacity var(--reveal-dur) var(--ease-entrance),
              transform var(--reveal-dur) var(--ease-entrance);
}
html.motion .is-revealed { opacity: 1; transform: none; }

/* image blur-up — settle filter + opacity on load (motion.js adds .is-loaded) */
html.motion :where(
  .hero__media img, .figure img, img.decision-img, .work-card__img img, .feat-card__img img,
  .grid-card__thumb > img, .recent-card__thumb img, .beyond-photo img, .hero-portrait img,
  .about-hero__portrait img, .work-tile-card__thumb > img
) {
  transition: filter var(--dur-slow) ease, opacity var(--dur-slow) ease,
              transform var(--dur-fast) var(--ease-entrance);
}
html.motion :where(
  .hero__media img, .figure img, img.decision-img, .work-card__img img, .feat-card__img img,
  .grid-card__thumb > img, .recent-card__thumb img, .beyond-photo img, .hero-portrait img,
  .about-hero__portrait img, .work-tile-card__thumb > img
):not(.is-loaded) {
  filter: blur(var(--img-blur));
  opacity: 0;
}

/* hover — card image scale (fast), contained */
.work-card__img, .feat-card__img, .recent-card__thumb,
.grid-card__thumb, .work-tile-card__thumb { overflow: hidden; }
.work-card__img img, .feat-card__img img, .recent-card__thumb img,
.grid-card__thumb > img, .work-tile-card__thumb > img {
  transition: transform var(--dur-fast) var(--ease-entrance),
              filter var(--dur-slow) ease, opacity var(--dur-slow) ease;
}
.work-card:hover .work-card__img img,
.feat-card:hover .feat-card__img img,
.recent-card:hover .recent-card__thumb img,
a.grid-card:hover .grid-card__thumb > img { transform: scale(var(--card-hover-scale)); }

/* hover — link / arrow colour shift + nudge (no underline, matches the site) */
.feat-card__link {
  transition: color var(--dur-fast) var(--ease-entrance),
              transform var(--dur-fast) var(--ease-entrance);
}
.feat-card:hover .feat-card__link { color: var(--accent); transform: translateX(var(--link-nudge)); }
.work-card__arrow { transition: transform var(--dur-fast) var(--ease-entrance); }
.work-card:hover .work-card__arrow { transform: translate(var(--link-nudge), calc(-1 * var(--link-nudge))); }

/* nav-on-scroll — the fixed case nav hides on scroll-down, returns on scroll-up */
.hero__nav { transition: transform var(--dur-base) var(--ease-entrance),
             background-color var(--dur-base) ease; }
.hero__nav.nav-hidden { transform: translate(-50%, -180%); }

/* =========================================================================
   RESPONSIVE
   ========================================================================= */
@media (max-width: 1280px) {
  :root { --pad-x: 56px; }
  .decision-featured__body { padding-left: 0; }
}

@media (max-width: 1000px) {
  :root { --pad-x: 40px; }
  .section__inner { padding-top: 88px; padding-bottom: 88px; }
  .display-xxl { font-size: 56px; }
  .heading-xl  { font-size: 36px; }
  .hero__subtitle { white-space: normal; }

  .metrics-grid { flex-wrap: wrap; }
  .metric-card { flex-basis: 50%; }

  .next-grid { flex-wrap: wrap; }
  .next-card { flex-basis: calc(50% - 12px); }

  .process-row { grid-template-columns: repeat(2, minmax(0, 1fr)); }

  .role-cols, .qual-body { gap: 48px; }

  .decision-featured__head { flex-direction: column; gap: 24px; }
  .decision-featured__left { width: 100%; flex-direction: row; align-items: baseline; gap: 16px; }
}

@media (max-width: 680px) {
  :root { --pad-x: 20px; }
  .section__inner { padding-top: 64px; padding-bottom: 64px; }
  .display-xxl { font-size: 40px; }
  .display-xl  { font-size: 52px; }
  .heading-xl  { font-size: 30px; }
  .heading-l   { font-size: 26px; }

  .meta-row { flex-direction: column; gap: 24px; }
  .meta-cell, .meta-cell--ghost { width: 100%; }
  .meta-cell--ghost { display: none; }

  .metric-card { flex-basis: 100%; }
  .next-card { flex-basis: 100%; }

  .process-row { grid-template-columns: 1fr; }

  .persona-row { flex-direction: column; gap: 32px; }
  .role-cols, .qual-body { flex-direction: column; gap: 40px; }

  .dtable__before, .dtable__after { width: 96px; }

  .decision-compact__head { flex-direction: column; gap: 16px; }
  .decision-compact__left { flex-direction: row; align-items: baseline; gap: 16px; width: 100%; }
  .decision-compact__right { display: none; }

  .reflection { gap: 20px; }
  .reflection__num { width: 56px; }

  .artifact-row { flex-wrap: wrap; gap: 8px 20px; }
  .artifact-row__name { width: auto; }
  .artifact-row__desc { flex-basis: 100%; }

  .footer-top { flex-direction: column; gap: 24px; }
  .footer-bottom { flex-direction: column; align-items: flex-start; gap: 12px; }

  .award-callout { padding: 28px; gap: 28px; }
  .award-callout__top { flex-direction: column; gap: 24px; }
  .award-callout__left { width: 100%; }
  .award-callout__right { border-left: none; padding-left: 0; border-top: 1px solid var(--border-default); padding-top: 24px; }

  .b2b-block { padding: 28px; }
  .b2b-item { flex-direction: column; gap: 4px; }
  .b2b-item__term { width: 100%; }
}
