/* ==========================================================================
   Case study page
   ========================================================================== */
.hero { margin-top: 20px; }

.case-titles { margin-top: 80px; display: flex; flex-direction: column; gap: 40px; }
.case-title { font-size: clamp(36px, 4.286vw, 72px); line-height: 1.2222; font-weight: 500; }
.case-meta-row { display: flex; justify-content: space-between; align-items: flex-start; gap: var(--g); }
.case-overview { font-size: 24px; line-height: 38px; }
.meta { display: flex; flex-direction: column; gap: 8px; }
.meta dt { font-size: 14px; line-height: 32px; font-weight: 600; color: var(--muted); margin-bottom: -4px; }
.meta dd { margin: 0; font-size: 18px; line-height: 26px; }
.meta .dot { font-size: 24px; margin-inline: 0.4em; }

.case-body { margin-top: var(--section-gap); display: flex; flex-direction: column; gap: var(--section-gap); }

.prose { display: flex; flex-direction: column; gap: 24px; }

/* 1 · intro paragraph (centered, 4 columns) */
.s-intro { margin-inline: auto; }

/* 2 · flows */
.s-flows { display: flex; justify-content: flex-end; align-items: flex-start; gap: var(--g); }
.s-flows__img { position: relative; aspect-ratio: 600 / 487; overflow: hidden; }
.s-flows__img img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; }

/* 3 · users + quotes */
.s-users { display: flex; flex-direction: column; gap: 32px; }
.focus { display: flex; align-items: flex-start; }
.focus__list { display: flex; flex-direction: column; gap: 24px; list-style: none; }
.focus__item { display: flex; align-items: center; gap: 16px; }
.focus__item:first-child { align-items: baseline; }
.focus__num { flex: none; width: 24px; text-align: center; font-family: "Instrument Serif", serif; font-size: 56px; line-height: 56px; color: var(--red); }
.focus__text { font-size: 18px; line-height: 24px; max-width: 333px; }
.focus__item:first-child .focus__text { max-width: none; white-space: nowrap; }
.quotes-col { flex: 1 0 0; min-width: 1px; display: flex; justify-content: flex-end; padding-top: 165px; }
.quotes { display: flex; flex-direction: column; gap: 40px; }
.quote { display: flex; align-items: flex-start; gap: 10px; }
.quote:first-child { gap: 8px; }
.quote__mark { flex: none; width: 40px; height: 27.334px; }
.quote__text {
  flex: 1 0 0; min-width: 1px;
  font-family: "Instrument Serif", serif; font-size: 32px; line-height: 40px; letter-spacing: 0.32px;
}
.quote:not(:last-child) .quote__text { padding-bottom: 40px; border-bottom: 1px solid var(--rule); }

/* 4 · sketches + defaults */
.s-default { display: flex; justify-content: center; align-items: flex-start; gap: var(--g); }
.s-default__fig { display: flex; flex-direction: column; gap: 16px; padding-top: 8px; }
.sketch { position: relative; aspect-ratio: 981 / 457; }
.sketch img { position: absolute; left: -1.94%; top: -4.16%; width: 103.88%; height: 108.32%; }
.s-default__fig figcaption { max-width: 600px; }

/* 5 · streaming state */
.s-stream { display: flex; justify-content: space-between; align-items: center; }
.s-stream .prose { width: calc((100% - 5 * var(--g)) / 2 + 3 * var(--g)); }

/* 6 · recover */
.s-recover { display: flex; justify-content: space-between; align-items: center; }
.s-recover__media { display: flex; justify-content: center; }

/* 7 · final experience */
.s-final { display: flex; flex-direction: column; gap: 80px; }
.final-row { display: flex; align-items: center; gap: var(--g); }
.final-row .device--desktop { width: 77.03%; }
.final-row__text { flex: 1 0 0; min-width: 1px; }
.final-row--phone { padding-left: calc((100% - 5 * var(--g)) / 3 + 2 * var(--g)); }

/* Prototype (recorded-flow animation) */
.proto { display: flex; flex-direction: column; gap: 16px; }
.proto .device--desktop { width: 100%; }
.proto .imgbox { --iu: calc(100cqw / 2732); }
.proto__layer { position: absolute; inset: 0; }
.proto__layer img { width: 100%; height: 100%; }
.proto__test, .proto__stream { opacity: 0; }
.crop {
  position: absolute;
  left: calc(var(--x) * var(--iu)); top: calc(var(--y) * var(--iu));
  width: calc(var(--w) * var(--iu)); height: calc(var(--h) * var(--iu));
  background-size: calc(var(--bw, 2732) * var(--iu)) auto;
  background-position: calc(var(--x) * var(--iu) * -1) calc(var(--y) * var(--iu) * -1);
  background-repeat: no-repeat;
}
.crop--pie { border-radius: 50%; opacity: 0; }
.proto__cursor {
  position: absolute; z-index: 10; left: 70%; top: 105%;
  width: calc(44 * var(--iu)); height: auto;
  transform-origin: 0 0; opacity: 0;
  filter: drop-shadow(0 calc(3 * var(--iu)) calc(5 * var(--iu)) rgba(0,0,0,.25));
  pointer-events: none;
}
.proto__ripple {
  position: absolute; z-index: 9; width: calc(90 * var(--iu)); aspect-ratio: 1;
  border-radius: 50%; background: rgba(74, 20, 140, 0.22);
  transform: translate(-50%, -50%) scale(0); opacity: 0; pointer-events: none;
}

/* 8 · expansion */
.s-expand { display: flex; align-items: flex-start; gap: var(--g); padding-block: 80px; }
.s-expand__texts { flex: 1 0 0; min-width: 1px; }

/* Live streaming overlay text */
.live { position: absolute; inset: 0; width: 100%; height: 100%; }
.live__timer { font-family: "Inter", system-ui, sans-serif; font-weight: 600; font-variant-numeric: tabular-nums; }

/* Pager + footer on case pages */
.site-footer--case { margin-top: var(--section-gap); }

/* ---------- Tablet ---------- */
@media (max-width: 1199px) {
  .case-overview { font-size: 21px; line-height: 33px; }
  .quote__text { font-size: 26px; line-height: 34px; }
  .quotes-col { padding-top: 96px; }
  .focus__item:first-child .focus__text { white-space: normal; }
}

/* ---------- Mobile ---------- */
.meta { margin: 0; }
.quotes { width: calc(100% - var(--g)); }
.s-recover__media .device--phone { width: 62.2%; }
.final-row--phone .device--phone { width: calc((100% - var(--g)) / 2); }

/* ---------- Tablet + mobile: case-study sections stack ---------- */
@media (max-width: 1199px) {
  .case-body .w2, .case-body .w3, .case-body .w4, .s-stream .prose { width: 100%; }
  .s-flows, .s-default, .s-stream, .s-recover, .final-row, .s-expand, .focus { flex-direction: column; align-items: stretch; gap: 32px; }
  .case-body .prose, .case-body figcaption, .final-row__text, .focus { max-width: 760px; }
  .s-intro { margin-inline: 0; }
  .s-flows__img { order: -1; }
  .s-default .prose { order: -1; }
  .s-recover .prose { order: -1; }
  .quotes-col { padding-top: 16px; justify-content: flex-start; }
  .quotes { width: 100%; gap: 28px; }
  .quote:not(:last-child) .quote__text { padding-bottom: 28px; }
  .focus__text { max-width: none; }
  .device--phone,
  .s-recover__media .device--phone,
  .final-row--phone .device--phone { width: min(340px, 100%); align-self: center; }
  .s-recover__media { width: 100%; }
  .final-row .device--desktop { width: 100%; }
  .final-row--phone { padding-left: 0; }
  .s-final { gap: 64px; }
  .s-expand { padding-block: 0; }
}

/* ---------- Mobile ---------- */
@media (max-width: 899px) {
  .hero { margin-top: 8px; }
  .case-titles { margin-top: 40px; gap: 28px; }
  .case-meta-row { flex-direction: column; gap: 32px; }
  .case-meta-row > * { width: 100%; }
  .case-overview { font-size: 20px; line-height: 31px; }
  .quote__text { font-size: 24px; line-height: 32px; }
  .device--phone,
  .s-recover__media .device--phone,
  .final-row--phone .device--phone { width: min(320px, 100%); }
  .s-final { gap: 56px; }
}

/* ---------- Mobile: shared fixes for all three case studies ---------- */
@media (max-width: 899px) {
  /* Order: hero, title, overview, metadata (project 1 has the metadata next to the title on desktop) */
  .case-titles .p1-head { display: contents; }
  .case-titles .p1-head .meta { order: 2; margin-top: 4px; }   /* 28 gap + 4 = the 32px used on projects 2 and 3 */
  .p1 .case-overview { order: 1; }

  /* Every caption: small, muted, left-aligned, 16px below its image */
  .case-body figcaption.t-caption, .case-body .final-row__text {
    font-size: 14px; line-height: 24px; font-weight: 600; color: var(--muted);
    text-align: left; max-width: none;
  }
  .s-flows, .final-row, .p2-initial, .p2-branch__fig, .s-default__fig, .p1-before__fig, .proto { gap: 16px; }
  .p2-initial figcaption { order: 2; }

  /* "The final experience": heading → first screen = the 24px heading → text gap used elsewhere */
  .s-final > .t-h2 { margin-bottom: -32px; }   /* 56px section gap − 32 */

  /* Phones: 250 wide (the project 1 statuses phone keeps its tall, many-cards proportion) */
  .case-body .device--phone,
  .case-body .s-recover__media .device--phone,
  .case-body .final-row--phone .device--phone,
  .case-body .p1-status__media .device--phone { width: min(250px, 100%); }

  /* Project 2: "The final experience" left-aligned like the other two */
  .p2 .case-body .s-final > .t-h2 { text-align: left; }

  /* Project 3 sketches: the image overhangs its box by 1.94% a side — shrink the box so it fits the margins */
  .s-default__fig .sketch { width: calc(100% / 1.0388); margin-inline: auto; }

  /* Project 1: let the result label wrap naturally */
  .p1-result .stat__label br { display: none; }
  /* Project 1 statuses: 16px indent, bar as in the results list */
  .marks .mark { padding-left: 16px; }
  .marks .mark::before { width: 6px; }

  /* Project 1 results: sub-results line up with everything else */
  .p1-results .p1-result__list { padding-left: 0; }
  /* Project 2: the wrapped "60%" / "100%" rows get air between them */
  .stat__figures { row-gap: 12px; }
  /* Project 3: more room between the numbered list and the quotes */
  .quotes-col { padding-top: 32px; }   /* + the 32px column gap: 64px, up from 48 */
}

/* Phone in landscape: desktop frames and prototypes shrink (centred) so each fits on
   screen with 24px to spare above and below. Width = available height × the frame's ratio. */
@media (max-width: 899px) and (orientation: landscape) {
  .case-body .device--desktop {
    --fit-h: calc(100vh - 48px);
    --fit-h: calc(100svh - 48px);
    width: min(100%, var(--fit-h) * 986 / 512) !important;   /* beats the per-flow widths */
    align-self: center;
  }
  .case-body .device--desktop[style*="986/556"] { width: min(100%, var(--fit-h) * 986 / 556) !important; }
  .case-body .device--desktop[style*="986/560"] { width: min(100%, var(--fit-h) * 986 / 560) !important; }
  .case-body .device--desktop[style*="986/622"] { width: min(100%, var(--fit-h) * 986 / 622) !important; }
}

/* Instrument Serif ships in one weight only — thicken the numerals with a
   stroke in the same colour so they read bolder without a fake-bold smear. */
.focus__num { -webkit-text-stroke: 0.04em currentColor; paint-order: stroke fill; }

.proto__caption { text-align: center; }

/* Audio test complete: full purple disc over the progress pie (pie centre 1016, 869.5; Ø 44) */
.proto__done {
  position: absolute;
  left: calc(993.5 * var(--iu)); top: calc(847 * var(--iu));
  width: calc(45 * var(--iu)); height: calc(45 * var(--iu));
  border-radius: 50%; background: #4a148c; opacity: 0;
}

/* ==========================================================================
   Project 2 · Unifying complex ordering workflows
   ========================================================================== */
.hero--p2 { --band: var(--blue); --cx0: 221; --cx1: 1060; --cy0: 65; --cy1: 595; }

/* Titles: overview spans the full width, metadata sits in a 3 × 2-column row */
.case-meta-col { display: flex; flex-direction: column; gap: 40px; }
.meta--row { flex-direction: row; gap: var(--g); }

/* 1 · concept: heading left, text right */
.p2-concept { display: flex; justify-content: space-between; align-items: flex-start; }

/* 2 · initial designs: two small grey desktops (630 × 355, 5px inset) */
.p2-initial { display: flex; flex-direction: column; gap: 16px; }
.p2-initial figcaption { text-align: center; }
.p2-initial__pair { display: flex; gap: 1.40625%; }
.p2-initial__pair .device { width: 49.219%; }
.device--small { --u: calc(100cqw / 630); --r: 16; --sw: 620; --sh: 345; --sr: 16; aspect-ratio: 630 / 355; }
.device--small .device__screen { left: calc(5 * var(--u)); top: calc(5 * var(--u)); }

/* 3 · defaults: stats on the right; the image hangs 321px below them (Figma: 984–1463 vs 1142) */
.p2-effort {
  display: flex; justify-content: space-between; align-items: stretch;
  padding-bottom: calc(((100% - 5 * var(--g)) / 2 + 2 * var(--g)) * 321 / 600);
}
.p2-effort__main { display: flex; flex-direction: column; justify-content: space-between; gap: 40px; }
.p2-effort__img { position: relative; aspect-ratio: 600 / 479; margin-bottom: -53.5%; }
.p2-effort__img img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; }
.stats { display: flex; flex-direction: column; gap: 70px; padding-top: 212px; }
/* divider: same rule as between the project 3 quotes; Figma frames end 61px below the text */
.stat:not(:last-child) { padding-bottom: 60px; border-bottom: 1px solid var(--rule); }
.stat__figures { display: flex; flex-wrap: wrap; column-gap: 16px; }
.stat__fig { display: flex; align-items: baseline; gap: 8px; height: 48px; }  /* Figma row height */
/* same numerals as project 3 (.focus__num): Instrument Serif, thickened with a stroke */
.stat__num { font-family: "Instrument Serif", serif; font-size: 56px; line-height: 48px; font-weight: 400; color: var(--blue); -webkit-text-stroke: 0.04em currentColor; paint-order: stroke fill; }
.stat__unit { font-size: 14px; line-height: 32px; font-weight: 600; color: var(--muted); }
.stat__label { margin-top: 4px; font-size: 18px; line-height: 24px; font-weight: 600; }
.stat__text { margin-top: 8px; margin-left: auto; width: calc((100% - 2 * var(--g)) * 2 / 3 + var(--g)); }

/* 5 · shared flow */
.p2-branch { display: flex; justify-content: space-between; align-items: flex-start; }
.p2-branch__fig { display: flex; flex-direction: column; gap: 16px; }
.p2-branch__img { position: relative; aspect-ratio: 600 / 255.908; }
.p2-branch__img img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; }

/* 7 · next steps */
.p2-next { display: flex; flex-direction: column; gap: 24px; padding-block: 80px; }
.p2-next__cols { display: flex; justify-content: space-between; }

/* "The final experience" heading is centred on this page only */
.p2 .s-final > .t-h2 { text-align: center; }

/* Pager title widths for this page's titles */
.p2 .pager__link--prev .pager__title { max-width: 372px; }
.p2 .pager__link--next .pager__title { max-width: 410px; }


@media (max-width: 1199px) {
  .meta--row { flex-wrap: wrap; row-gap: 24px; }
  .p2-concept, .p2-effort, .p2-branch, .p2-next__cols { flex-direction: column; align-items: stretch; gap: 32px; }
  .p2-effort { padding-bottom: 0; }
  .p2-effort__main { display: contents; }
  .p2-effort__img { order: 2; margin-bottom: 0; max-width: 600px; }
  .p2-effort .prose { order: 0; }
  .stats { order: 1; padding-top: 8px; gap: 32px; max-width: 760px; }
  .stat:not(:last-child) { padding-bottom: 32px; }
  .stat__text { width: auto; margin-left: 0; max-width: 560px; }
  .p2-concept .t-h2, .p2-next .t-h2 { max-width: 760px; }
  .p2-branch__img { order: 0; }


  .p2-next { padding-block: 0; }
  .p2-next__cols { gap: 24px; }
  .p2-next__cols p { max-width: 760px; }
}
@media (max-width: 899px) {
  .meta--row { flex-direction: column; gap: 16px; }
  .meta--row > div { width: 100%; }
  .p2-initial__pair { flex-direction: column; gap: 24px; }
  .p2-initial__pair .device { width: 100%; }
  .stat__num { font-size: 48px; line-height: 48px; }
}

/* ==========================================================================
   Project 2 · recorded-prototype flows (js/flows.js)
   Layers are Figma exports at 2× (2732 × 1536) positioned in those pixels;
   --iu is one of those pixels. Without JS (or with reduced motion) only the
   final screen shows, because every [data-s] layer starts hidden.
   ========================================================================== */
.pflow__box { position: absolute; inset: 0; width: 100%; height: 100%; --iu: calc(100cqw / 2732); }
.pf-full { position: absolute; inset: 0; width: 100%; height: 100%; }
.pf-at {
  position: absolute;
  left: calc(var(--x) * var(--iu)); top: calc(var(--y) * var(--iu));
  width: calc(var(--w) * var(--iu)); height: calc(var(--h) * var(--iu));
}
.pflow__box > img.pf-at { display: block; inset: auto; left: calc(var(--x) * var(--iu)); top: calc(var(--y) * var(--iu)); width: calc(var(--w) * var(--iu)); height: calc(var(--h) * var(--iu)); }
.pf-scene > img.pf-at { display: block; }
.pflow [data-s] { opacity: 0; }
.pf-scene { position: absolute; inset: 0; }
.pf-strip { background: #fff; will-change: transform; }
.pf-strip img { width: 100%; height: 100%; display: block; }
.pf-caret { background: #222; }
.pf-caret.is-blinking { animation: pf-blink 1s steps(1) infinite; }
@keyframes pf-blink { 50% { visibility: hidden; } }
.pf-white { background: #fff; }
.pf-bar img { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.pf-hover { background: rgba(0, 0, 0, 0.036); mix-blend-mode: multiply; }   /* list row hover, same grey as the Figma hover (246,245,245) */

/* ==========================================================================
   Project 1 · Designing clarity into bank account management
   Figma node 2791:338. Section comments give the Figma frame.
   ========================================================================== */
.hero--p1 { --band: var(--yellow); --cx0: 102; --cx1: 1177; --cy0: 64; --cy1: 597; }
/* map texture (Figma 2820:2828: 1677 × 830 at y −2, colour burn 70%) — spans the whole band */
.hero--p1 .card__texture { left: 0; right: 0; top: calc(var(--oy) - 2 * var(--k)); height: calc(830 * var(--k)); pointer-events: none; }
.hero--p1 .card__texture img { width: 100%; height: 100%; object-fit: cover; mix-blend-mode: color-burn; opacity: 0.7; }

/* Titles: title (3 columns + gutter) and metadata share a bottom edge; the overview spans the full width */
.p1-head { display: flex; justify-content: space-between; align-items: flex-end; gap: var(--g); }
.p1-head__title { width: calc((100% - 5 * var(--g)) / 2 + 3 * var(--g)); }
.p1-head .meta { margin-bottom: 11px; }   /* Figma metadata frame has 11px below the last item */

/* 1 · before (2797:328): the grey frame is 610 wide in a 600 column, as in Figma */
.p1-before { display: flex; justify-content: space-between; align-items: flex-start; }
.p1-before__fig { display: flex; flex-direction: column; gap: 16px; padding-top: 10px; }
.device--before { --u: calc(100cqw / 610); --sw: 600; --sh: 301; aspect-ratio: 610 / 311; width: calc(100% * 610 / 600); }
.p1-before__h2 { max-width: 418px; }

/* 2 · prioritization (2793:284) */
.p1-prio { display: flex; justify-content: space-between; align-items: flex-start; }
.p1-prio__img { position: relative; aspect-ratio: 827 / 644; border-radius: 16px; overflow: hidden; }
.p1-prio__img img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
/* Figma: 2px stroke rgba(34,34,34,.15), drawn inside like the device frames */
.p1-prio__img::after { content: ""; position: absolute; inset: 0; border-radius: inherit; box-shadow: inset 0 0 0 2px var(--stroke); pointer-events: none; }

/* 4 · statuses (2806:317): text 3 columns + gutter, phone 77px lower */
.p1-status { display: flex; justify-content: space-between; align-items: flex-start; }
.p1-status__text { width: calc((100% - 5 * var(--g)) / 2 + 3 * var(--g)); }
.p1-status__text .t-h2 { width: calc(100% * 747 / 680); }   /* Figma: the heading box is 747 wide, so it stays on one line */
.p1-status__media { padding-top: 77px; }
.p1-status__media .device--phone { width: 100%; }
.marks { display: flex; flex-direction: column; gap: 24px; }
.mark { position: relative; display: flex; flex-direction: column; gap: 24px; padding-left: 34px; }
.mark::before { content: ""; position: absolute; left: 0; top: 0; width: 10px; height: 32px; background: var(--yellow); }

/* 5 · structure (2797:332): explorations reuse project 2's pair of small grey frames, 630 × 398 here */
.p1-scale { display: flex; flex-direction: column; gap: 80px; }
.p1-scale .p2-initial figcaption { order: 2; }
.device--p1pair { --sh: 388; aspect-ratio: 630 / 398; }

/* 6 · verification flows (2791:517) */
.p1-flow { display: flex; flex-direction: column; gap: 24px; }
.p1-flow__cols { display: flex; justify-content: space-between; align-items: flex-start; }
.p1-flow__img { position: relative; aspect-ratio: 827 / 261; margin: 56px auto 0; }
.p1-flow__img img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }

/* 8 · results (2791:570): two blocks 80px either side of a centred rule */
.p1-results { display: flex; flex-direction: column; align-items: center; gap: 120px; padding-bottom: 80px; }
.p1-results__row { display: flex; justify-content: center; gap: var(--g); width: 100%; }
.p1-results__rule { flex: none; width: 1px; margin-inline: -0.5px; background: var(--rule); }
.p1-result { width: calc((100% - 5 * var(--g)) / 3 + 2 * var(--g)); display: flex; }
.p1-result--a { justify-content: flex-end; }
.p1 .stat__fig { align-items: flex-start; }
.p1 .stat__num { line-height: 36px; color: var(--yellow); }
.p1 .stat__unit { margin-top: 16px; }
.p1-result__list { list-style: none; display: flex; flex-direction: column; gap: 8px; margin-top: 8px; padding-left: 86px; }
.p1-result__list li { position: relative; padding-left: 16px; }
.p1-result__list li::before { content: ""; position: absolute; left: 0; top: 4px; width: 6px; height: 24px; background: var(--yellow); }

/* Pager title widths for this page's titles */
.p1 .pager__link--prev .pager__title { max-width: 361px; }
.p1 .pager__link--next .pager__title { max-width: 259px; }

@media (max-width: 1199px) {
  .p1-before, .p1-prio, .p1-status, .p1-flow__cols { flex-direction: column; align-items: stretch; gap: 32px; }
  .p1-before .prose { order: -1; }
  .device--before { width: 100%; }
  .p1-before__fig { padding-top: 0; }
  .p1-before__h2 { max-width: none; }
  .p1-status__text { width: 100%; max-width: 760px; }
  .p1-status__text .t-h2 { width: auto; }
  .p1-head .meta { margin-bottom: 0; }
  .p1-status__media { padding-top: 0; display: flex; justify-content: center; }
  .p1-status__media .device--phone { width: min(340px, 100%); }
  .p1-scale { gap: 48px; }
  .p1-flow__img { margin-top: 24px; width: 100%; }
  .p1-results { align-items: stretch; gap: 48px; padding-bottom: 0; }
  .p1-results .t-h2 { text-align: center; }
  .p1-result { flex: 1 1 0; width: auto; min-width: 0; }
  .p1-result__list { padding-left: 24px; }
}
@media (max-width: 899px) {
  .p1-head { flex-direction: column; align-items: stretch; gap: 32px; }
  .p1-head > * { width: 100%; }
  .p1-status__media .device--phone { width: min(320px, 100%); }
  .p1-results .t-h2 { text-align: left; }
  .p1-results__row { flex-direction: column; gap: 32px; }
  .p1-results__rule { width: 100%; height: 1px; margin: 0; }
  .p1-result, .p1-result--a { justify-content: flex-start; }
}

/* Project 1 · table prototype: selected-row grey (Figma table cell fill 247,247,247) over the full row */
.pf-row { background: rgba(0, 0, 0, 0.0314); mix-blend-mode: multiply; }
/* The table prototype's screen is 16:10 (1440 × 900), taller than projects 2 and 3. Narrow it so the
   frame is as tall as project 2's prototypes (986 × 560 at full width) and centre it; nothing is cropped. */
.proto .device--desktop[data-flow="p1table"], .proto .device--desktop[data-flow="p1verify"] { width: calc(100% * 560 / 622); align-self: center; }
.pf-full.pf-top { object-fit: cover; object-position: top; }   /* PD start is 1440 × 938: keep the top, crop the empty bottom */
@media (max-width: 899px) {
  .proto .device--desktop[data-flow="p1table"], .proto .device--desktop[data-flow="p1verify"] { width: 100%; }
}

/* Mirrored phone row: caption in columns 1–2, phone in the same centred spot as the other phone rows */
.final-row--rev { flex-direction: row-reverse; padding-left: 0; padding-right: calc((100% - 5 * var(--g)) / 3 + 2 * var(--g)); }
@media (max-width: 1199px) {
  .final-row--rev { flex-direction: column; padding-right: 0; }
}

/* "The final experience" heading is centred on this page too (as on project 2), from tablet up */
@media (min-width: 900px) {
  .p1 .s-final > .t-h2 { text-align: center; }
}

/* Project 2 stats, 1920px and up: the numbers and titles move one gutter right, towards
   the indented paragraphs (which stay put), so the block sits farther from the centre */
@media (min-width: 1920px) {
  .p2-effort .stat__figures, .p2-effort .stat__label { padding-left: var(--g); }
}
