/* ============================================================
   casestudy.css — Melissa Craddock Portfolio
   Case study pages: pipeline, commerce, template
   Requires portfolio.css (tokens, reset, nav, footer)
   ============================================================ */

/* ── Page layout ────────────────────────────────────────── */

/* ── Case study header ──────────────────────────────────── */
.cs-meta {
  display: flex; align-items: center; flex-wrap: wrap;
  gap: var(--sp-3);
  font-size: 0.8125rem;
  letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--ink-3); font-weight: 600;
  margin-bottom: var(--sp-6);
}
.cs-meta .dot { width: 5px; height: 5px; border-radius: 999px; background: var(--ink-3); }
.cs-meta .brand { color: var(--brand); font-weight: 700; }

/* ── Hero ───────────────────────────────────────────────── */
.cs-hero h1 { text-wrap: balance; }

.page--body > h1 {
  font-size: clamp(1.875rem, 3.2vw, 3rem);
  line-height: 1.1;
  letter-spacing: -0.03em;
  margin-top: 28px;
  margin-bottom: 18px;
}
.page--body > h1 .accent { color: var(--brand); }

@media (max-width: 640px) {
  .page--body > h1 {
    font-size: clamp(1.5rem, 7vw, 1.875rem);
    line-height: 1.15;
  }
}
.sub {
  max-width: 100%;
  width: 100%;
  font-size: 0.9375rem;
  line-height: 1.7;
  color: var(--ink-2);
  margin: 0 0 var(--sp-10);
}

/* ── Sections ───────────────────────────────────────────── */
.cs-section { margin-top: var(--space-section); }
.divider {
  height: 1px; background: var(--rule);
  margin: var(--sp-12) 0;
}

/* ── Compare / metrics strip ────────────────────────────── */
.compare {
  margin-top: var(--sp-6);
  background: #fff; border: 1px solid var(--rule);
  border-radius: var(--r-lg);
  padding: var(--sp-7) var(--sp-8);
  display: flex; flex-direction: column; gap: var(--sp-6);
}
.compare-lead {
  border-bottom: 1px solid var(--rule);
  padding-bottom: var(--sp-5);
}
.compare-lead .eyebrow { margin-bottom: var(--sp-2); }
.compare-lead h3 {
  font-weight: 800;
  font-size: 1.25rem;
  line-height: 1.2;
  letter-spacing: -0.02em;
  margin: 0 0 var(--sp-3);
  color: #0F2B4C;
}
.compare-lead p {
  margin: 0; font-size: 0.875rem;
  line-height: 1.65; color: var(--ink-2);
}

.compare-metrics {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
}
.metric { padding: 0 var(--sp-6) 0 0; }
.metric + .metric {
  padding-left: var(--sp-6);
  border-left: 1px solid var(--rule-2);
}
.metric .lbl {
  font-size: 0.6875rem;
  letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--ink-3); font-weight: 700;
  margin-bottom: var(--sp-2);
}
.metric .pair {
  display: flex; align-items: baseline; gap: var(--sp-3);
  font-weight: 800; letter-spacing: 0;
  margin-bottom: var(--sp-2);
}
.metric .before {
  font-size: 1.25rem;
  color: var(--ink-4);
  text-decoration: line-through;
  text-decoration-color: rgba(0,0,0,0.18);
  letter-spacing: -0.01em;
}
.metric .arrow { color: var(--ink-4); font-size: 0.875rem; font-weight: 600; }
.metric .after {
  font-size: 0.9375rem;
  font-weight: 700;
  color: #072369; line-height: 1.35;
  letter-spacing: -0.01em;
}
.metric .after small {
  font-size: 0.875rem; color: var(--brand-2);
  margin-left: 2px; font-weight: 700;
}
.metric .foot {
  margin-top: var(--sp-2);
  font-size: 0.8125rem;
  color: var(--ink-3); line-height: 1.55;
  letter-spacing: 0; font-weight: 400;
}

/* ── Platform stat strip ────────────────────────────────── */
.platform-strip {
  background: var(--paper); border: 1px solid var(--rule);
  border-radius: var(--r-lg);
  padding: var(--sp-6) var(--sp-8);
  margin-top: var(--sp-6);
  display: grid; grid-template-columns: 1fr 1fr 1fr; gap: var(--sp-8);
}
.platform-stat { display: flex; flex-direction: column; gap: var(--sp-1); }
.platform-stat .num {
  font-size: 1.75rem;
  font-weight: 800; color: #072369;
  letter-spacing: -0.02em; line-height: 1;
}
.platform-stat .lbl {
  font-size: 0.8125rem; font-weight: 500;
  color: var(--ink-3); line-height: 1.4;
}

/* ── Two-column intro ───────────────────────────────────── */
.cs-intro {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: var(--sp-12); margin-top: var(--sp-6);
}
.cs-intro-block h3 {
  color: var(--brand); font-size: 1.0625rem;
  margin-bottom: var(--sp-3);
}
.cs-intro-block p {
  font-size: 0.875rem; line-height: 1.7; color: var(--ink-2);
}

/* ── Thesis pullquote ───────────────────────────────────── */
.pullquote {
  border-left: 4px solid #072369;
  margin: 0 0 var(--sp-6);
  padding: var(--sp-5) var(--sp-6);
  background: #F0F4F8;
  border-radius: 0 var(--r-sm) var(--r-sm) 0;
}
.pullquote p {
  font-size: 1.125rem;
  font-weight: 700; line-height: 1.5;
  color: #072369; margin: 0;
  letter-spacing: -0.01em;
}

/* ── Note box ───────────────────────────────────────────── */
.note-box {
  background: #F0F4F8;
  border-left: 4px solid #072369;
  border-radius: 0 var(--r-sm) var(--r-sm) 0;
  padding: var(--sp-5) var(--sp-6);
  margin-top: var(--sp-5);
  font-size: 0.9375rem; line-height: 1.7; color: #253240;
}
.note-box strong { color: #072369; }

/* ── Cards ──────────────────────────────────────────────── */
.cs-card {
  background: var(--paper); border: 1px solid var(--rule);
  border-radius: var(--r-lg);
  padding: var(--sp-8) var(--sp-8);
  margin-top: var(--sp-6);
}
.cs-card h3 {
  color: var(--brand); margin-bottom: var(--sp-4);
  font-size: 1rem;
}

.cs-list { list-style: disc; padding-left: var(--sp-6); }
.cs-list li {
  padding: var(--sp-1) 0;
  font-size: 0.875rem; line-height: 1.5;
  color: var(--ink-2);
}
.cs-list li strong { color: var(--ink); font-weight: 600; }

.cs-grid {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: var(--sp-5); margin-top: var(--sp-6);
}
.cs-grid-card {
  background: #fff; border: 1px solid var(--rule);
  border-radius: var(--r-md);
  padding: var(--sp-5) var(--sp-6);
}
.cs-grid-card h4 {
  font-size: 0.75rem; font-weight: 800; color: #072369;
  margin-bottom: var(--sp-2);
  text-transform: uppercase; letter-spacing: 0.14em;
}
.cs-grid-card p {
  font-size: 0.875rem; line-height: 1.65;
  color: var(--ink-2); margin: 0;
}

.cs-bridge {
  background: #072369; color: #fff;
  border-radius: var(--r-lg);
  padding: var(--sp-7) var(--sp-8);
  margin-top: var(--sp-5);
}
.cs-bridge h4 {
  font-size: 0.6875rem; font-weight: 800;
  letter-spacing: 0.16em; text-transform: uppercase;
  color: rgba(255,255,255,0.85); margin-bottom: var(--sp-3);
}
.cs-bridge p {
  font-size: 0.875rem; line-height: 1.65;
  color: rgba(255,255,255,0.92); margin: 0;
}
.cs-bridge ul, .cs-bridge li {
  color: rgba(255,255,255,0.92);
  line-height: 1.6;
}

/* ── Methodology panel ──────────────────────────────────── */
.methodology {
  margin-top: var(--sp-6);
  background: var(--paper); border: 1px solid var(--rule);
  border-radius: var(--r-lg);
  padding: var(--sp-8) var(--sp-10);
  display: grid; grid-template-columns: 1fr 1.25fr; gap: var(--sp-10);
}
.methodology .eyebrow { margin-bottom: var(--sp-3); }
.methodology h3 {
  font-weight: 800; font-size: 1.25rem;
  line-height: 1.2; letter-spacing: -0.02em;
  margin: 0 0 var(--sp-4); color: #072369;
}
.methodology p {
  margin: 0; font-size: 0.875rem;
  line-height: 1.65; color: var(--ink-2);
}
.methodology p + p { margin-top: var(--sp-3); }

.mtable {
  border: 1px solid var(--rule); background: #fff;
  border-radius: var(--r-md); overflow: hidden;
}
.mtable .mhead {
  display: grid; grid-template-columns: 7rem 1fr 1fr;
  background: var(--brand); color: #fff;
}
.mtable .mhead > div {
  padding: var(--sp-4);
  font-size: 0.8125rem; letter-spacing: 0.14em;
  text-transform: uppercase; font-weight: 700;
}
.mtable .mhead > div + div { border-left: 1px solid rgba(255,255,255,0.15); }
.mtable .mrow { display: grid; grid-template-columns: 7rem 1fr 1fr; }
.mtable .mrow + .mrow { border-top: 1px solid var(--rule); }
.mtable .mrow > div {
  padding: var(--sp-4);
  font-size: 0.875rem; line-height: 1.55; color: var(--ink);
}
.mtable .mrow > div + div { border-left: 1px solid var(--rule); }
.mtable .mrow .rowlbl {
  font-size: 0.8125rem; letter-spacing: 0.12em;
  text-transform: uppercase; color: var(--ink-3);
  font-weight: 700; background: #fafafa; align-content: center;
}

/* ── Pipeline diagram lanes ─────────────────────────────── */
.lanes {
  display: flex; flex-direction: column;
  gap: var(--sp-5); margin-top: var(--sp-12);
}
.lane {
  position: relative; border-radius: var(--r-lg);
  padding: var(--sp-7) var(--sp-8) var(--sp-8);
}
.lane.trad { background: var(--paper); border: 1px solid var(--rule-2); }
.lane.ai   { background: #072369; color: #fff; border: 1px solid #072369; }

.lane-head {
  display: flex; align-items: flex-end;
  justify-content: space-between;
  padding-bottom: var(--sp-2);
  margin-bottom: var(--sp-7);
  border-bottom: 1px solid var(--rule-2);
}
.lane.ai .lane-head { border-bottom-color: var(--brand-line); }

.lane-title { display: flex; flex-direction: column; gap: var(--sp-2); }
.lane-kicker {
  font-size: 0.8125rem; letter-spacing: 0.14em;
  text-transform: uppercase; color: var(--ink-3); font-weight: 600;
}
.lane.ai .lane-kicker { color: rgba(255,255,255,0.8); }
.lane-name {
  font-weight: 800; font-size: 1.625rem;
  line-height: 1; letter-spacing: -0.02em; color: var(--ink);
}
.lane.ai .lane-name { color: #fff; }
.framework {
  margin-top: var(--sp-1); font-size: 0.9375rem;
  font-weight: 500; color: var(--ink-3);
}
.lane.ai .framework { color: rgba(255,255,255,0.85); }
.framework b { font-weight: 700; }

.lane-stats {
  display: flex; gap: var(--sp-6); align-items: baseline;
  font-size: 0.875rem; letter-spacing: 0.10em;
  text-transform: uppercase; color: var(--ink-3); font-weight: 600;
}
.lane.ai .lane-stats { color: rgba(255,255,255,0.8); }
.lane-stats span { display: inline-flex; align-items: baseline; gap: var(--sp-1); }
.lane-stats b {
  font-weight: 800; font-size: 1.25rem;
  color: var(--ink); letter-spacing: -0.02em;
}
.lane.ai .lane-stats b { color: #fff; }

.track {
  position: relative; display: flex;
  flex-direction: row;
  justify-content: space-between;
  align-items: start;
  padding-top: var(--sp-6);
  width: 100%;
  gap: 0;
}
.rule-line {
  position: absolute; left: 0; right: 0; top: 3.75rem;
  height: 2px; background: var(--rule);
  border-radius: 2px; z-index: 0;
}
.lane.ai .rule-line { background: rgba(255,255,255,0.22); }

.saved {
  position: absolute;
  left: calc(8/11 * 100% - 0.5px);
  right: 0; top: 3.25rem; height: 1.125rem;
  z-index: 0; display: flex; align-items: center;
  padding-left: var(--sp-4);
}
.saved::before {
  content: ""; position: absolute; inset: var(--sp-2) 0;
  border-top: 1.5px dashed rgba(255,255,255,0.32);
}
.saved-pill {
  position: relative; z-index: 1;
  background: #fff; color: var(--brand);
  font-size: 0.8125rem; font-weight: 700;
  letter-spacing: 0.12em; text-transform: uppercase;
  padding: var(--sp-2) var(--sp-3);
  border-radius: 999px;
  display: inline-flex; align-items: center;
  gap: var(--sp-2); line-height: 1;
}
.saved-pill svg { width: 11px; height: 11px; }

.node {
  position: relative; z-index: 1;
  flex: 1; min-width: 0;
  display: flex; flex-direction: column;
  align-items: center; text-align: center;
  padding: 0 var(--sp-2);
}
.num {
  font-size: 0.8125rem; font-weight: 700;
  letter-spacing: 0.12em; color: var(--ink-3);
  margin-bottom: var(--sp-2); line-height: 1;
}
.lane.ai .num { color: rgba(255,255,255,0.55); }

.circle {
  width: 4.25rem; height: 4.25rem;  /* 68px */
  border-radius: 999px;
  background: #fff; border: 1.5px solid #a8a8a2;
  display: flex; align-items: center; justify-content: center;
  color: var(--ink); position: relative;
}
.circle svg.glyph { width: 1.75rem; height: 1.75rem; display: block; }
.lane.ai .circle {
  background: #E6EFF4;
  border: 1.5px solid rgba(255,255,255,0.4); color: var(--brand);
}
/* Brand logo SVGs (Figma, Storybook, GitHub) use their own fill colors — don't override */
.lane.ai .circle svg.glyph[viewBox="0 0 38 57"],
.lane.ai .circle svg.glyph[viewBox="0 0 256 319"],
.lane.ai .circle svg.glyph[viewBox="0 0 24 24"][fill="#ffffff"] {
  color: inherit;
}
.node.loop .circle {
  border-color: var(--loop);
  box-shadow: 0 0 0 3px rgba(220,38,38,0.08);
}

.label {
  margin-top: var(--sp-3); font-size: 0.875rem;
  font-weight: 600; line-height: 1.3;
  color: var(--ink); max-width: 7.5rem;
}
.lane.ai .label { color: #fff; }
.label .sublabel {
  display: block; font-weight: 400;
  color: var(--ink-3); font-size: 0.8125rem;
  margin-top: var(--sp-1);
}
.lane.ai .label .sublabel { color: rgba(255,255,255,0.85); }

.loop-flag {
  margin-top: var(--sp-1);
  font-size: 0.5625rem; font-weight: 700;
  letter-spacing: 0.06em; text-transform: uppercase;
  color: var(--loop);
  display: inline-flex; align-items: center;
  gap: var(--sp-1); line-height: 1;
}
.loop-flag svg { width: 8px; height: 8px; }

.arcs {
  position: absolute; left: 0; right: 0;
  top: var(--sp-5); height: 3rem;
  pointer-events: none; z-index: 0;
}
.arcs svg { width: 100%; height: 100%; overflow: visible; }

/* ── Commerce loop diagram ──────────────────────────────── */
.loop-diagram {
  margin-top: var(--sp-6);
  background: var(--brand); border-radius: var(--r-lg);
  padding: var(--sp-8) var(--sp-8);
  display: flex; flex-direction: column; gap: 0;
}
.loop-diagram .loop-title {
  font-size: 0.8125rem; font-weight: 800;
  letter-spacing: 0.14em; text-transform: uppercase;
  color: rgba(255,255,255,0.7);
  margin-bottom: var(--sp-5);
}
.loop-steps {
  display: flex; align-items: center;
  gap: 0; flex-wrap: wrap;
}
.loop-step {
  display: flex; flex-direction: column;
  align-items: center; text-align: center;
  flex: 1; min-width: 6.25rem;
}
.loop-step .step-icon {
  width: 3.25rem; height: 3.25rem;
  border-radius: 999px;
  background: rgba(255,255,255,0.12);
  border: 1.5px solid rgba(255,255,255,0.3);
  display: flex; align-items: center; justify-content: center;
  margin-bottom: var(--sp-3);
}
.loop-step .step-icon svg { width: 1.375rem; height: 1.375rem; color: #fff; }
.loop-step .step-label {
  font-size: 0.8125rem; font-weight: 600;
  color: #fff; line-height: 1.3; max-width: 5.625rem;
}
.loop-step .step-sub {
  font-size: 0.8125rem; color: rgba(255,255,255,0.65);
  margin-top: var(--sp-1); line-height: 1.3; max-width: 5.625rem;
}
.loop-arrow {
  color: rgba(255,255,255,0.4); font-size: 1.125rem;
  font-weight: 300; padding: 0 var(--sp-1);
  margin-bottom: var(--sp-8); flex-shrink: 0;
}
.loop-step.human .step-icon {
  background: rgba(255,255,255,0.22);
  border-color: rgba(255,255,255,0.6);
}
.loop-step.human .step-label { font-weight: 700; }
.human-note {
  margin-top: var(--sp-5);
  padding-top: var(--sp-4);
  border-top: 1px solid rgba(255,255,255,0.15);
  font-size: 0.875rem; color: rgba(255,255,255,0.75); line-height: 1.6;
}
.human-note b { color: #fff; font-weight: 600; }

/* ── Phase cards ────────────────────────────────────────── */
.phase-grid {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: var(--sp-5); margin-top: var(--sp-6);
}
.phase-card {
  border: 1px solid var(--rule);
  border-radius: var(--r-lg);
  padding: var(--sp-7) var(--sp-8);
  background: #fff;
}
.phase-card.current { border-color: var(--brand); }
.phase-card .phase-eyebrow {
  font-size: 0.8125rem; font-weight: 800;
  letter-spacing: 0.14em; text-transform: uppercase;
  margin-bottom: var(--sp-3);
}
.phase-card.current .phase-eyebrow { color: var(--brand); }
.phase-card.future  .phase-eyebrow { color: var(--ink-3); }
.phase-card h3 { font-size: 1.125rem; margin-bottom: var(--sp-3); }
.phase-card p {
  font-size: 0.875rem; line-height: 1.65;
  color: var(--ink-2); margin: 0;
}
.phase-card p + p { margin-top: var(--sp-3); }
.phase-card .phase-tag {
  display: inline-block; margin-top: var(--sp-4);
  font-size: 0.8125rem; font-weight: 700;
  letter-spacing: 0.10em; text-transform: uppercase;
  padding: var(--sp-1) var(--sp-3); border-radius: var(--r-sm);
}
.phase-card.current .phase-tag { background: var(--brand-tint); color: var(--brand); }
.phase-card.future  .phase-tag { background: var(--paper); color: var(--ink-3); }

/* ── Pipeline stages ────────────────────────────────────── */
.stages { list-style: none; padding: 0; margin-top: var(--sp-5); }
.stage-phase {
  font-size: 0.75rem; font-weight: 700;
  letter-spacing: 0.16em; text-transform: uppercase;
  color: #072369;
  padding: var(--sp-5) 0 var(--sp-3);
}
.stage-phase:first-child { padding-top: var(--sp-1); }

.stage-item {
  display: grid; grid-template-columns: 3rem 1fr;
  gap: var(--sp-4);
  padding: var(--sp-6) 0;
  border-bottom: 1px solid var(--rule-2);
  align-items: start;
}
.stage-item:last-child { border-bottom: none; }

.stage-num {
  width: 2.5rem; height: 2.5rem;   /* 40px */
  border-radius: 999px;
  background: #072369; color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-weight: 800; font-size: 0.875rem;
  flex-shrink: 0; margin-top: 2px;
}
.stage-content h4 {
  font-size: 0.9375rem; font-weight: 700;
  color: #0F2B4C; margin-bottom: var(--sp-2);
}
.stage-content h4 .stage-tag {
  font-size: 0.6875rem; font-weight: 600;
  color: var(--brand); background: var(--brand-tint);
  padding: 2px var(--sp-2); border-radius: var(--r-sm);
  letter-spacing: 0.05em; text-transform: uppercase;
  margin-left: var(--sp-2); vertical-align: middle;
}
.stage-content p {
  font-size: 0.875rem; line-height: 1.65;
  color: var(--ink-2); margin: 0;
}

/* ── Status list ────────────────────────────────────────── */
.status-list { list-style: none; padding: 0; margin-top: var(--sp-4); }
.status-list li {
  padding: var(--sp-3) 0 var(--sp-3) var(--sp-7);
  border-bottom: 1px solid var(--rule-2);
  font-size: 0.9375rem; line-height: 1.7;
  color: var(--ink-2); position: relative;
}
.status-list li:last-child { border-bottom: none; }
.status-list li::before {
  content: "✓"; position: absolute; left: 0;
  color: var(--brand); font-weight: 700;
}

/* ── Image placeholders ─────────────────────────────────── */
.img-placeholder {
  background: var(--paper); border: 1px solid var(--rule);
  border-radius: var(--r-md); height: 23.75rem;
  display: flex; align-items: center;
  justify-content: center; margin-top: var(--sp-6);
}
.img-placeholder p {
  font-size: 0.9375rem; color: var(--ink-3);
  font-style: italic; text-align: center; padding: var(--sp-5);
}
.img-caption {
  font-size: 0.875rem; color: var(--ink-2);
  margin-top: var(--sp-3); text-align: left; font-style: italic;
}
.img-caption--left { text-align: left; }

/* ── Closing ────────────────────────────────────────────── */
.closing {
  background: var(--ink); color: #fff;
  border-radius: var(--r-lg);
  padding: var(--sp-12) var(--sp-14);
  margin-top: var(--space-section);
}
.closing h2 { color: #fff; margin-bottom: var(--sp-5); font-size: 1.5rem; }
.closing p {
  font-size: 0.9375rem; line-height: 1.75;
  color: rgba(255,255,255,0.82);
  margin-bottom: var(--sp-4);
}
.closing p:last-child { margin-bottom: 0; }

/* ── Bottom nav ─────────────────────────────────────────── */
.bottom-nav {
  border-top: 1px solid var(--rule);
  margin-top: var(--space-section);
  padding-top: var(--sp-6);
  display: flex;
  justify-content: flex-end;
  align-items: flex-end;
}
.bottom-nav-next {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  text-decoration: none;
  gap: 3px;
}
.bottom-nav-label {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-3);
}
.bottom-nav-title {
  font-size: 0.9375rem;
  font-weight: 600;
  color: #072369;
  transition: color 0.15s;
}
.bottom-nav-next:hover .bottom-nav-title { color: #1143A9; }

/* ══════════════════════════════════════════════════════════
   RESPONSIVE — coordinated with portfolio.css breakpoints
   xl: 1280px  lg: 1024px  md: 768px  sm: 480px
   ══════════════════════════════════════════════════════════ */

/* xl — 1280px */
@media (max-width: 80rem) {
  .page { padding-left: var(--sp-8); padding-right: var(--sp-8); }
  .compare-metrics { grid-template-columns: 1fr 1fr; gap: var(--sp-6); }
  .metric { padding: 0; }
  .metric + .metric { padding-left: 0; border-left: none; }
  .methodology { grid-template-columns: 1fr; gap: var(--sp-6); }
}

/* lg — 1024px */
@media (max-width: 64rem) {
  .page { padding-top: var(--sp-8); }
  .cs-intro { grid-template-columns: 1fr; gap: var(--sp-6); }
  .cs-grid  { grid-template-columns: 1fr; }
  .phase-grid { grid-template-columns: 1fr; }
  .platform-strip { grid-template-columns: 1fr 1fr; }
  .track { grid-template-columns: repeat(6, 1fr); overflow-x: auto; }
  .loop-steps { flex-wrap: wrap; gap: var(--sp-2); justify-content: center; }
  .loop-arrow { margin-bottom: var(--sp-5); }
}

/* md — 768px */
@media (max-width: 48rem) {
  .page { padding: var(--sp-6) var(--sp-6) var(--sp-16); }
  .compare-metrics { grid-template-columns: 1fr; gap: var(--sp-5); }
  .metric + .metric { border-top: 1px solid var(--rule-2); padding-top: var(--sp-5); }
  .closing { padding: var(--sp-8) var(--sp-6); }
  .closing h2 { font-size: 1.5rem; }
  .bottom-nav { flex-direction: column; align-items: flex-start; gap: var(--sp-4); }
  .loop-diagram { padding: var(--sp-6) var(--sp-5); }
  .loop-steps { flex-direction: column; align-items: flex-start; gap: var(--sp-4); }
  .loop-arrow { transform: rotate(90deg); margin: 0 0 0 var(--sp-5); }
  .platform-strip { grid-template-columns: 1fr; }
}

/* sm — 480px */
@media (max-width: 30rem) {
  .page { padding: var(--sp-5) var(--sp-5) var(--sp-12); }
  .compare { padding: var(--sp-5) var(--sp-5); }
  .cs-card  { padding: var(--sp-5) var(--sp-5); }
  .lane { padding: var(--sp-5) var(--sp-5) var(--sp-6); }
  .methodology { padding: var(--sp-5) var(--sp-5); }
  h1 { font-size: clamp(1.75rem, 8vw, 2.5rem); }
  .pullquote p { font-size: 1rem; }
}

/* ── SDLC composite two-column ── */
.sdlc-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--sp-8);
  align-items: start;
  margin: 0 0 var(--sp-8);
}
.sdlc-grid figure { margin: 0; }
@media (max-width: 48rem) {
  .sdlc-grid { grid-template-columns: 1fr; }
}

/* ── Combined chapter + prev/next bar ───────────────────────
   Replaces .cs-nav on case study pages.
   HTML structure:
     <div class="combined-nav" id="combined-nav">
       <div class="combined-nav-inner">
         <nav class="cnav-tabs" aria-label="Page sections">
           <a class="cnav-item" href="#section-id">Label</a>
           …
         </nav>
         <div class="cnav-pn">
           <a class="cnav-pn-link" href="prev.html">← <span>Prev project title</span></a>
           <div class="cnav-divider" aria-hidden="true"></div>
           <a class="cnav-pn-link" href="next.html"><span>Next project title</span> →</a>
         </div>
       </div>
     </div>
   ─────────────────────────────────────────────────────────── */

.combined-nav {
  position: sticky;
  top: 0;
  z-index: 90;
  background: var(--bg);
  border-bottom: 1px solid var(--rule);
  display: flex;
  justify-content: center;
}

.combined-nav-inner {
  width: 100%;
  max-width: var(--container-wide);
  padding: 0 var(--space-gutter);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-6);
  min-height: 0;
}

.combined-nav {
  position: sticky;
  top: 0;
  z-index: 90;
  background: var(--bg);
  border-bottom: 1px solid var(--rule);
  display: flex;
  flex-direction: column;
  justify-content: center;
}

/* ── Top bar: prev/next only ── */
.cnav-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--sp-2) var(--space-gutter);
  border-bottom: 1px solid var(--rule-2);
}
.cnav-pn {
  display: flex;
  align-items: center;
  gap: var(--sp-4);
}
.cnav-pn-link {
  display: flex;
  align-items: center;
  gap: var(--sp-2);
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--ink-3);
  text-decoration: none;
  white-space: nowrap;
  transition: color 0.15s;
}
.cnav-pn-link span {
  display: block;
  max-width: 12rem;
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--ink-4);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.cnav-pn-link:hover,
.cnav-pn-link:hover span { color: var(--brand); }
.cnav-divider {
  width: 1px;
  height: 1rem;
  background: var(--rule);
  flex-shrink: 0;
}

/* ── Progress bar: steps + connectors ── */
.cnav-progress {
  display: flex;
  align-items: center;
  padding: var(--sp-3) var(--space-gutter);
  overflow-x: auto;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
  gap: 0;
}
.cnav-progress::-webkit-scrollbar { display: none; }

.cnav-item {
  display: inline-flex;
  align-items: center;
  gap: 0;
  text-decoration: none;
  flex-shrink: 0;
  position: relative;
}

/* The connector line between steps */
.cnav-item::before {
  content: "";
  display: block;
  height: 2px;
  width: 2rem;
  background: var(--rule);
  flex-shrink: 0;
  transition: background 0.3s;
}
.cnav-item:first-child::before { display: none; }
.cnav-item.done::before,
.cnav-item.active::before { background: var(--brand); }

/* The step dot + label wrapper */
.cnav-step {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}

/* The circle dot */
.cnav-dot {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: 2px solid var(--rule);
  background: var(--bg);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: border-color 0.2s, background 0.2s;
  position: relative;
}
/* Inner fill for done steps */
.cnav-dot::after {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: transparent;
  transition: background 0.2s;
}

/* Step label */
.cnav-label {
  font-size: 0.6875rem;
  font-weight: 500;
  color: var(--ink-4);
  white-space: nowrap;
  transition: color 0.2s, font-weight 0.2s;
  letter-spacing: 0.01em;
}

/* ── States ── */
/* Active */
.cnav-item.active .cnav-dot {
  border-color: var(--brand);
  background: var(--brand);
  box-shadow: 0 0 0 3px var(--brand-tint);
}
.cnav-item.active .cnav-dot::after { display: none; }
.cnav-item.active .cnav-label {
  color: var(--brand);
  font-weight: 700;
}

/* Done (past) */
.cnav-item.done .cnav-dot {
  border-color: var(--brand);
  background: var(--brand);
}
.cnav-item.done .cnav-dot::after {
  background: #fff;
  width: 6px;
  height: 5px;
  border-radius: 0;
  /* checkmark via clip-path */
  clip-path: polygon(0 50%, 35% 100%, 100% 0, 35% 60%);
  background: #ffffff;
}
.cnav-item.done .cnav-label { color: var(--ink-3); }

/* Hover */
.cnav-item:hover .cnav-dot { border-color: var(--brand); }
.cnav-item:hover .cnav-label { color: var(--ink-2); }


/* ── Scroll margin — compensates for sticky site-nav + tab bar ──
   Keeps section headings visible when jumped to via anchor or JS.
   Value set dynamically by cs-tabs.js via --scroll-offset var,
   but CSS provides a safe fallback.                               */
[id] {
  scroll-margin-top: 120px;
}
/* ── Responsive ── */
@media (max-width: 64rem) {
  .cnav-pn-link span { display: none; }
  .cnav-item::before { width: 1.25rem; }
}
@media (max-width: 48rem) {
  .cnav-progress { padding: var(--sp-2) var(--sp-5); }
  .cnav-top { padding: var(--sp-2) var(--sp-5); }
  .cnav-label { font-size: 0.625rem; }
  .cnav-dot { width: 18px; height: 18px; }
  .cnav-item::before { width: 1rem; }
}
@media (max-width: 30rem) {
  .cnav-pn { display: none; }
}

/* ── Scroll reveal ──────────────────────────────────────────
   Sections fade + slide up as they enter the viewport.
   JS in scroll-nav.js adds .is-visible via IntersectionObserver */
.cs-section,
.compare,
.closing,
.cs-grid,
.cs-figure,
.cs-figure-annotated,
.img-placeholder,
.pullquote,
.cs-bridge {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}
.cs-section.is-visible,
.compare.is-visible,
.closing.is-visible,
.cs-grid.is-visible,
.cs-figure.is-visible,
.cs-figure-annotated.is-visible,
.img-placeholder.is-visible,
.pullquote.is-visible,
.cs-bridge.is-visible {
  opacity: 1;
  transform: translateY(0);
}
/* Stagger children of cs-grid */
.cs-grid.is-visible .cs-grid-card:nth-child(1),
.cs-grid.is-visible .cs-card:nth-child(1) { transition-delay: 0s; }
.cs-grid.is-visible .cs-grid-card:nth-child(2),
.cs-grid.is-visible .cs-card:nth-child(2) { transition-delay: 0.07s; }
.cs-grid.is-visible .cs-grid-card:nth-child(3),
.cs-grid.is-visible .cs-card:nth-child(3) { transition-delay: 0.14s; }
.cs-grid.is-visible .cs-grid-card:nth-child(4),
.cs-grid.is-visible .cs-card:nth-child(4) { transition-delay: 0.21s; }
.cs-grid.is-visible .cs-grid-card:nth-child(5),
.cs-grid.is-visible .cs-card:nth-child(5) { transition-delay: 0.28s; }
.cs-grid.is-visible .cs-grid-card:nth-child(6),
.cs-grid.is-visible .cs-card:nth-child(6) { transition-delay: 0.35s; }

/* ── Case study figures (real images) ──────────────────────
   Use .cs-figure for actual images; .img-placeholder for
   images not yet available. Both share .img-caption.       */
.cs-figure {
  margin-top: var(--sp-6);
  border-radius: var(--r-md);
  overflow: hidden;
  border: 1px solid var(--rule);
}
.cs-figure img {
  display: block;
  width: 100%;
  height: auto;
}
.cs-figure-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--sp-4);
  margin-top: var(--sp-6);
}
.cs-figure-row .cs-figure { margin-top: 0; }

/* Annotated figure wrapper */
.cs-figure-annotated {
  position: relative;
  margin-top: var(--sp-6);
  border-radius: var(--r-md);
  overflow: hidden;
  border: 1px solid var(--rule);
  background: var(--paper);
}
.cs-figure-annotated img {
  display: block;
  width: 100%;
  height: auto;
}
.cs-annotations {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: var(--sp-3);
  padding: var(--sp-5);
  border-top: 1px solid var(--rule);
  background: var(--bg);
}
.cs-annotation {
  font-size: 0.75rem;
  line-height: 1.5;
  color: var(--ink-2);
}
.cs-annotation b {
  display: block;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--brand);
  margin-bottom: 0.25rem;
}

@media (max-width: 48rem) {
  .cs-figure-row { grid-template-columns: 1fr; }
}

/* ── Thesis pullquote variant ───────────────────────────────
   Elevated version of .pullquote for the core strategic insight */
.pullquote--thesis {
  border-left: 4px solid #072369;
  background: #F0F4F8;
  padding: var(--sp-6) var(--sp-8);
  border-radius: 0 var(--r-md) var(--r-md) 0;
}
.pullquote--thesis .eyebrow {
  display: block;
  font-size: 0.6875rem;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #072369;
  margin-bottom: var(--sp-3);
}
.pullquote--thesis p {
  font-size: 1.25rem;
  font-weight: 700;
  line-height: 1.4;
  color: #0F2B4C;
  font-style: normal;
  margin: 0;
}

/* ── Project Snapshot strip ─────────────────────────────────
   Lightweight role/status/methods/tools summary block.
   Shared across pipeline.html and treatmentreadiness.html    */
.project-snapshot {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
  margin-top: var(--sp-10);
  padding: var(--sp-6);
  border: 1px solid var(--rule);
  border-radius: var(--r-md);
  background: var(--paper);
}
.project-snapshot--hero {
  margin-top: var(--sp-5);
  margin-bottom: var(--sp-8);
}
.snapshot-item {
  display: grid;
  grid-template-columns: 120px 1fr;
  gap: 20px;
  font-size: 0.9375rem;
  line-height: 1.6;
  color: var(--ink-2);
}
.snapshot-label {
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--brand);
}
@media (max-width: 48rem) {
  .snapshot-item { grid-template-columns: 1fr; gap: 4px; }
}

/* ── Secondary metadata line ────────────────────────────────
   Compact role/methods/tools strip under cs-meta            */
.cs-meta--secondary {
  margin-top: 10px;
  color: var(--ink-2);
}
.cs-meta--secondary b {
  color: var(--ink-2);
  font-weight: 700;
}

/* ── Case byline strip ──────────────────────────────────────
   Article-style role / status / tools line under the intro  */
.case-byline {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 18px;
  align-items: center;
  margin-top: var(--sp-5);
  padding-top: var(--sp-4);
  border-top: 1px solid var(--rule);
  color: var(--ink-2);
  font-size: 0.875rem;
  line-height: 1.5;
}
.byline-item {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  white-space: nowrap;
}
.byline-icon {
  color: var(--brand);
  font-size: 0.8125rem;
  line-height: 1;
}
@media (max-width: 48rem) {
  .case-byline { align-items: flex-start; gap: 8px; }
  .byline-item { white-space: normal; }
}

/* ── Case masthead ──────────────────────────────────────────
   Two-row editorial header: primary metadata + role/tools   */
.case-masthead {
  display: flex;
  flex-direction: column;
  gap: 5px;
  margin-bottom: 0;
  padding-top: 12px;
  padding-bottom: 22px;
  border-bottom: 1px solid var(--rule);
}
.masthead-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 12px;
  font-size: 0.8125rem;
  line-height: 1.5;
}
.masthead-row--primary {
  color: var(--ink-2);
  font-weight: 600;
}
.masthead-row--secondary {
  color: var(--ink-2);
}
.masthead-kicker {
  color: #072369;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-size: 0.75rem;
}
.masthead-row strong {
  color: var(--ink);
  font-weight: 700;
  margin-right: 4px;
}
.masthead-dot {
  width: 3px;
  height: 3px;
  border-radius: 999px;
  background: #A1AECF;
  display: inline-block;
}
@media (max-width: 48rem) {
  .case-masthead { gap: 8px; }
  .masthead-row { display: block; }
  .masthead-row span { display: inline; }
  .masthead-dot { margin: 0 6px 2px; }
}

/* ── Grid card icon support ─────────────────────────────────
   Add .cs-icon above the h4 in any cs-grid-card             */
.cs-icon {
  width: 28px;
  height: 28px;
  color: var(--brand);
  display: block;
  margin-bottom: var(--sp-3);
  opacity: 0.9;
  flex-shrink: 0;
}
.cs-grid-card:has(.cs-icon) {
  display: flex;
  flex-direction: column;
}

/* ── Apple-style section tab bar ───────────────────────────
   Lives OUTSIDE .page, sticky below site-nav (top set by JS).
   Pill tray left-aligns to page content edge.
   Sliding pill indicator animates via CSS vars set by JS.
   ─────────────────────────────────────────────────────────── */

/* ── Unified sticky header: metadata + jump nav ── */
.cs-sticky-header {
  position: fixed;
  top: var(--site-nav-h, 0px);
  left: 0;
  right: 0;
  z-index: 40;
  background: rgb(240, 244, 248);
  border: 0;
  margin: 0;
}

/* ── Case study pages: site-nav also fixed ── */
body:has(.cs-sticky-header) .site-nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  width: 100%;
  z-index: 100;
}

/* metadata row removed from sticky header */
.cs-sticky-meta-inner {
  max-width: var(--container-wide);
  margin: 0 auto;
  padding: 0.625rem clamp(1.25rem, 5vw, 3rem);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 8px;
  font-size: 0.8125rem;
  color: #253240;
  font-weight: 500;
  line-height: 1.4;
}
.cs-sticky-meta-inner strong {
  color: #072369;
  font-weight: 700;
}
.cs-sticky-meta-inner .masthead-kicker {
  color: #072369;
  font-weight: 800;
  letter-spacing: 0.08em;
}

/* Row 2: jump nav */
.cs-tabs {
  background: transparent;
  width: 100%;
}

.cs-tabs-inner {
  position: relative;
  isolation: isolate;
  max-width: var(--container-wide);
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 0.45rem;
  padding-top: 24px;
  padding-bottom: 10px;
  padding-left: clamp(1.25rem, 5vw, 3rem);
  padding-right: clamp(1.25rem, 5vw, 3rem);
  overflow-x: auto;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}
.cs-tabs-inner::-webkit-scrollbar { display: none; }


.cs-jump-label,
.cs-tab {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 30px;
  line-height: 1;
}

.cs-jump-label {
  margin-right: 0.25rem;
  font-size: 0.6875rem;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ink-3);
  white-space: nowrap;
  flex-shrink: 0;
}

/* ── Sliding pill (hidden — active class handles styling) ── */
.cs-tabs-inner::before {
  content: '';
  position: absolute;
  top: var(--pill-top, 0px);
  left: var(--pill-left, 0px);
  width: var(--pill-width, 80px);
  height: var(--pill-height, 30px);
  background: #1143A9;
  border-radius: 999px;
  transition: left 0.22s cubic-bezier(0.4, 0, 0.2, 1),
              width 0.22s cubic-bezier(0.4, 0, 0.2, 1);
  z-index: 0;
  pointer-events: none;
}

.cs-tab {
  position: relative;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 0.95rem;
  border-radius: 999px;
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--ink-2);
  text-decoration: none;
  white-space: nowrap;
  flex-shrink: 0;
  transition: color 0.15s;
}
.cs-tab:hover { color: var(--ink); }
.cs-tab.active,
.cs-tab[aria-current="true"] {
  background: transparent;
  color: #fff;
}

/* Body page wrapper */
.page--body {
  max-width: var(--container-wide);
  margin: 0 auto;
  padding: var(--sp-3) clamp(1.25rem, 5vw, 3rem) var(--sp-20);
}
/* Push body content below both fixed navs */


@media (max-width: 48rem) {
  .cs-jump-label { display: none; }
  .cs-tab { font-size: 0.75rem; padding: 5px 10px; }
}

/* ══════════════════════════════════════════════════════════
   CASE STUDY RESPONSIVE
   lg: 1024px  md: 768px  sm: 480px
   ══════════════════════════════════════════════════════════ */

/* lg — 1024px */
@media (max-width: 64rem) {

  /* Page */
  .page { padding: var(--sp-10) var(--sp-8) var(--sp-16); }

  /* Compare metrics: 2 columns */
  .compare-metrics {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: var(--sp-5);
  }
  .metric + .metric { border-left: none; padding-left: 0; }
  .metric:nth-child(odd) { border-right: none; }

  /* Methodology: stack */
  .methodology {
    grid-template-columns: 1fr;
    gap: var(--sp-6);
  }

  /* CS grid: stays 2-col at tablet */
  .cs-grid { grid-template-columns: 1fr 1fr; }

  /* CS intro: stack */
  .cs-intro { grid-template-columns: 1fr; gap: var(--sp-6); }

  /* Platform strip: 2-col */
  .platform-strip { grid-template-columns: 1fr 1fr; }

  /* Journey map header: stack */
  .tr-journey-header { grid-template-columns: 1fr; }

  /* Lanes: tighten */
  .lane { padding: var(--sp-5) var(--sp-6) var(--sp-6); }
  .track { gap: var(--sp-3); }
}

/* md — 768px */
@media (max-width: 48rem) {

  /* Page */
  .page { padding: var(--sp-8) var(--sp-6) var(--sp-12); }

  /* Compare metrics: single column */
  .compare-metrics {
    grid-template-columns: 1fr !important;
    gap: var(--sp-4);
  }
  .metric + .metric { border-left: none; padding-left: 0; }

  /* CS grid: single column */
  .cs-grid { grid-template-columns: 1fr; }

  /* Methodology table: scrollable */
  .mtable { overflow-x: auto; }
  .mtable .mhead,
  .mtable .mrow { grid-template-columns: 5rem 1fr 1fr; min-width: 480px; }

  /* Journey map: single column grid */
  .tr-journey-grid { grid-template-columns: 1fr; }

  /* Pipeline lane track: wrap */
  .track {
    flex-wrap: wrap;
    gap: var(--sp-3);
  }
  .node { width: auto; }

  /* Stage list */
  .stage-list { padding: 0; }
  .stage-item { gap: var(--sp-3); }

  /* Bridge and grid cards */
  .cs-bridge { padding: var(--sp-5) var(--sp-6); }

  /* Validation artifact two-column: stack */
  .compare > div[style*="grid-template-columns: 1fr 1fr"] {
    display: block;
  }
}

/* sm — 480px */
@media (max-width: 30rem) {

  /* Page */
  .page { padding: var(--sp-6) var(--sp-5) var(--sp-10); }

  /* h1 */
  h1 { font-size: clamp(1.75rem, 7vw, 2.25rem); }
  h2 { font-size: clamp(1.375rem, 5vw, 1.75rem); }

  /* Sub paragraph */
  .sub { font-size: 1rem; }

  /* Compare */
  .compare { padding: var(--sp-5) var(--sp-5); }
  .compare-metrics { grid-template-columns: 1fr !important; }
  .metric .after { font-size: 1.5rem; }

  /* CS grid single col */
  .cs-grid { grid-template-columns: 1fr; gap: var(--sp-4); }

  /* Methodology panel: stack fully */
  .methodology { padding: var(--sp-6); }
  .mtable .mhead,
  .mtable .mrow { grid-template-columns: 4rem 1fr 1fr; font-size: 0.8rem; }

  /* Journey map: tighten */
  .tr-journey-map { font-size: 0.8125rem; }
  .tr-journey-grid { grid-template-columns: 1fr; }

  /* Pipeline lane: stack nodes */
  .track { flex-direction: column; align-items: flex-start; }
  .node { flex-direction: row; align-items: center; gap: var(--sp-3); width: 100%; }
  .circle { width: 36px; height: 36px; flex-shrink: 0; }
  .label { font-size: 0.8125rem; }

  /* Closing */
  .closing { padding: var(--sp-8) var(--sp-5); }

  /* Bottom nav */
  .bottom-nav { flex-direction: column; gap: var(--sp-4); }
}

/* ── Insight box ─────────────────────────────────────────── */
.insight-box {
  background: #F0F4F8;
  border-left: 3px solid #072369;
  border-radius: 0 var(--r-md) var(--r-md) 0;
  padding: var(--sp-4) var(--sp-5);
  margin: var(--sp-6) 0;
}
.insight-box .insight-label {
  font-size: 0.6875rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #072369;
  margin-bottom: 6px;
  display: block;
}
.insight-box p {
  font-size: 0.9375rem;
  line-height: 1.65;
  color: #253240;
  margin: 0;
}

/* ── Two-column grid ─────────────────────────────────────── */
.two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--sp-5);
  margin-top: var(--sp-5);
}
@media (max-width: 640px) {
  .two-col { grid-template-columns: 1fr; }
}

/* ── Artifact grid ───────────────────────────────────────── */
.artifact-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--sp-4);
  margin-top: var(--sp-5);
}
.artifact-grid a {
  display: block;
  text-decoration: none;
  border: 1px solid var(--rule);
  border-radius: var(--r-md);
  overflow: hidden;
  background: var(--paper);
  transition: transform 160ms ease, box-shadow 160ms ease;
}
.artifact-grid a:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 16px rgba(0,0,0,0.08);
}
.artifact-grid img {
  width: 100%;
  aspect-ratio: 16/10;
  object-fit: cover;
  display: block;
  border-bottom: 1px solid var(--rule);
}
.artifact-grid span {
  display: block;
  padding: 10px 12px;
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--ink);
}
@media (max-width: 900px) {
  .artifact-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 640px) {
  .artifact-grid { grid-template-columns: 1fr; }
}

/* ── Case study images ───────────────────────────────────── */
.cs-img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: var(--r-md);
  border: 1px solid var(--rule);
}
.cs-img-wrap {
  margin: var(--sp-6) 0 var(--sp-2);
  display: flex;
  justify-content: center;
}
.cs-img-wrap + .img-caption {
  margin-bottom: var(--sp-8);
  text-align: center;
}

/* ── Voice blockquote ────────────────────────────────────── */
blockquote.voice {
  border-left: 3px solid var(--rule);
  margin: var(--sp-3) 0;
  padding: var(--sp-3) var(--sp-4);
  background: var(--paper);
  border-radius: 0 var(--r-sm) var(--r-sm) 0;
}
blockquote.voice p {
  font-size: 0.875rem;
  font-style: italic;
  color: var(--ink-2);
  margin: 0 0 4px;
}
blockquote.voice cite {
  font-size: 0.75rem;
  color: var(--ink-3);
  font-style: normal;
}
