/* Each scene is ordinary inline content until scroll motion is available. */
.story-intro {
  display: grid;
  grid-template-columns: 1.18fr 1fr;
  align-items: end;
  gap: clamp(2rem, 6vw, 7rem);
  padding-block: clamp(2.5rem, 6vw, 5.8rem) clamp(2rem, 4vw, 4rem);
}
.story-intro h1 { max-width: 15ch; font-size: clamp(3rem, 5.4vw, 5.7rem); }
.story-intro-reading { max-width: 46ch; font-size: clamp(1rem, 1.4vw, 1.2rem); }
.stage-menu { position: relative; width: fit-content; margin-top: 1rem; z-index: 3; }
.stage-menu summary {
  cursor: pointer; color: var(--blue); font-size: .92rem; font-weight: 700; padding-block: .4rem;
}
.stage-menu nav {
  position: absolute; top: 100%; left: 0; width: max-content; max-width: 87vw;
  display: grid; background: white; border: 1px solid var(--line); padding: .45rem;
  box-shadow: 0 .5rem 1.5rem #08075216;
}
.stage-menu a { padding: .57rem .85rem; font-size: .94rem; text-decoration: none; }
.stage-menu a:hover, .stage-menu a:focus-visible { background: var(--paper); text-decoration: underline; }
.process-list { margin-bottom: clamp(3rem, 6vw, 6rem); }
.process-list .process-step {
  display: grid; grid-template-columns: minmax(0,.73fr) minmax(0,1.27fr);
  gap: clamp(2.25rem, 6.3vw, 6.8rem); border: 0; padding: 0; margin: 0;
}
.stage-copy { padding-block: clamp(1.4rem, 3vw, 2.8rem) clamp(2.4rem, 5vw, 4.5rem); border-top: 1px solid var(--line); }
.process-list .process-step:first-child .stage-copy { border-color: var(--navy); }
.process-list .stage-prose .micro { margin-bottom: .8rem; color: var(--blue); }
.process-list .stage-prose h2 { font-size: clamp(2rem, 3.25vw, 3.4rem); margin-bottom: .7em; }
.stage-prose p:not(.micro), .story-outputs p { max-width: 49ch; font-size: clamp(1rem, 1.18vw, 1.14rem); }
.stage-link {
  display: inline-flex; align-items: baseline; gap: .55em; width: fit-content; min-height: 44px;
  padding-block: .7rem; margin-top: .8rem; color: var(--blue); font-weight: 700; line-height: 1.35;
}
.stage-link span { flex: none; }
.stack-example, .next-question { border-left: 3px solid var(--magenta); padding: .2rem 0 .2rem 1.05rem; margin: 1.6rem 0 0; }
.stack-example h3 { font-size: 1.14rem; letter-spacing: -.025em; margin-bottom: .35rem; }
.next-question { border-color: var(--blue); }
.next-question strong { display: block; color: var(--navy); font-size: .85rem; margin-bottom: .25rem; }
.visual-slot { min-width: 0; align-self: start; margin-bottom: clamp(2rem, 4vw, 4rem); }
.story-scene { container-type: inline-size; color: var(--navy); }
.story-scene svg { display: block; width: 100%; height: auto; }
.story-scene figcaption {
  margin-top: .62rem; font-size: .8rem; line-height: 1.45; color: var(--muted);
}
.caption-detail { display: block; }
.photo-credit { white-space: nowrap; }
.scene-frame { overflow: hidden; background: var(--paper); }
.scene-layer { min-width: 0; }
.table-photo { width: 100%; height: auto; aspect-ratio: 4/3; object-fit: cover; }
.source-label { font-size: clamp(.74rem, 2.1cqw, 1rem); line-height: 1.4; font-weight: 650; }
.prep-zoom { display: grid; align-content: center; gap: 1rem; background: var(--deep); color: white; }
.prep-zoom img { width: 100%; height: auto; }
.prep-zoom .source-label { padding-inline: 4%; }
.prep-brief, .prep-app {
  display: flex; flex-direction: column; justify-content: center; align-items: center; gap: 4%;
  padding: 5%; background: #f4f5fb;
}
.prep-brief img { width: 100%; height: auto; box-shadow: 0 .15rem .8rem #0b0b5014; }
.prep-brief blockquote {
  align-self: start; margin-block: 4%; color: var(--navy); font-weight: 700;
  font-size: clamp(1.15rem, 4.8cqw, 2.55rem); line-height: 1.14; letter-spacing: -.04em;
}
.prep-brief .source-label { align-self: start; color: var(--muted); }
.prep-app { background: #ecf0fa; }
.prep-app picture { display: block; width: min(100%, 91cqw); }
.prep-app img { display: block; width: 100%; height: auto; box-shadow: 0 .15rem .8rem #0b0b5014; }
.prep-app .source-label { color: var(--navy); text-align: center; }
.prep-frame > div { padding-block: 4%; }
.prep-frame .prep-app { padding: 2.5%; gap: .6rem; }
.process-list:not(.story-motion) .prep-frame { display: grid; grid-template-columns: 1.25fr 1fr; }
.process-list:not(.story-motion) .prep-zoom { grid-column: 1 / -1; }
.process-list:not(.story-motion) .prep-brief blockquote { font-size: clamp(.95rem, 3.5cqw, 1.6rem); }
@media (max-width: 460px) {
  .process-list:not(.story-motion) .prep-frame { grid-template-columns: 1fr; }
}
.evidence-questions {
  margin: 1.25rem 0 0; padding-top: .85rem; border-top: 1px solid var(--line);
}
.evidence-questions dt { color: var(--muted); font-size: .8rem; font-weight: 600; }
.evidence-questions dt:not(:first-child) { margin-top: .75rem; }
.evidence-questions dd { margin: .12rem 0 0; color: var(--navy); font-weight: 600; }
.idea-metrics { margin-top: .65rem; color: var(--ink); display: grid; grid-template-columns: 1.16fr 1fr; gap: 1px; background: var(--line); border: 1px solid var(--line); }
.idea-metrics p { background: #fff; padding: .65em .85em; margin: 0; line-height: 1.25; font-size: clamp(.85rem, 2.45cqw, 1.17rem); }
.idea-metrics strong { color: var(--blue); }
.testing-sequence { display: grid; gap: 1.3rem; }
.testing-interview, .testing-revision { min-width: 0; background: white; }
.testing-sequence img { display: block; width: 100%; height: auto; }
.testing-sequence .asset-caption {
  margin: .62rem 0 0; font-size: .84rem; line-height: 1.45; color: var(--muted);
}
.feedback-heading { margin: 1rem 0 .45rem; color: var(--navy); font-size: 1rem; font-weight: 700; }
.review-notes { display: grid; grid-template-columns: 1fr 1fr; gap: 6%; }
.review-notes p {
  border-top: 3px solid #3130ce; margin: 0; padding-top: .5em; line-height: 1.38;
  font-size: clamp(.82rem, 2.3cqw, 1.05rem);
}
.review-notes .review-note { border-color: #bc9416; }
.review-notes strong { display: block; margin-bottom: .2em; color: var(--navy); }
@container (max-width: 370px) {
  .review-notes { grid-template-columns: 1fr; gap: .75rem; }
}
.friday-cover { display: grid; align-content: center; background: var(--deep); }
.friday-cover img { height: auto; width: 100%; }
.friday-timeline { background: #f3f4fa; padding: 4.5% 6%; display: grid; align-content: center; }
.timeline-origin { display: flex; justify-content: space-between; align-items: baseline; flex-wrap: wrap; gap: .25em .8em; font-size: clamp(.85rem, 2.8cqw, 1.3rem); }
.timeline-origin span { color: var(--blue); font-weight: 700; }
.timeline-origin strong { font-weight: 500; }
.friday-timeline ol { list-style: none; margin: .7em 0 0; padding: 0; }
.friday-timeline li {
  display: grid; grid-template-columns: 3.35em 1fr; align-items: baseline; position: relative;
  border-top: 1px solid #cdd1e3; gap: .7em; padding: .52em 0 .52em .88em;
  font-size: clamp(.82rem, 2.55cqw, 1.25rem); line-height: 1.22;
}
.friday-timeline li::before { content: ''; position: absolute; left: 0; inset-block: 0; width: 2px; background: var(--tape); }
.friday-timeline li::after { content: ''; position: absolute; width: .48em; aspect-ratio: 1; left: -.17em; top: .9em; border-radius: 50%; background: var(--blue); }
.story-outputs { padding: clamp(2.5rem, 6vw, 6rem) 0; background: var(--deep); color: white; }
.story-outputs .shell { display: grid; grid-template-columns: .85fr 1fr; gap: 6%; }
.story-outputs h2, .story-outputs a { color: white; }
.story-outputs .stage-link { text-decoration-color: var(--cyan); }

.story-motion .scene-frame:not(.idea-frame) { display: grid; }
.story-motion .scene-frame:has(.scene-layer)::before { content: ""; grid-area: 1 / 1; width: 100%; aspect-ratio: 4/3; align-self: start; }
.story-motion .scene-layer { grid-area: 1 / 1; }
.story-motion .prep-zoom { opacity: var(--photo,1); }
.story-motion .prep-brief { opacity: var(--brief,0); }
.story-motion .prep-app { opacity: var(--companion,0); }
.story-pinned .testing-sequence { gap: 0; }
.story-pinned .testing-sequence > div { grid-area: 1 / 1; }
.story-pinned .testing-interview:nth-child(2) { opacity: var(--second-interview,0); }
.story-pinned .testing-revision { opacity: var(--prototype,0); }
.story-pinned .testing-revision img { max-height: calc(100svh - 14.5rem); object-fit: contain; }
.story-pinned .access-note { opacity: var(--access,0); }
.story-pinned .review-note { opacity: var(--review,0); }
.story-motion .idea-metrics { opacity: var(--stacks,0); }
.story-motion .metric-ideas { color: rgb(22 25 51 / var(--ideas,1)); }
.story-motion .metric-ideas strong { color: rgb(22 19 212 / var(--ideas,1)); }
.story-motion .friday-timeline { opacity: var(--timeline,0); }
.story-motion .friday-timeline li { opacity: var(--event,1); }

.story-pinned { display: grid; grid-template-columns: minmax(0,.73fr) minmax(0,1.27fr); column-gap: clamp(2.25rem, 6.3vw, 6.8rem); }
.story-pinned .process-step { display: contents; }
.story-pinned .stage-copy {
  grid-column: 1; grid-row: var(--row); min-height: 65svh; padding-bottom: 4rem;
}
.story-pinned .process-step:first-child .stage-copy { min-height: 86svh; }
.story-pinned .process-step:last-child .stage-copy { min-height: 110svh; }
.story-pinned .stage-prose { scroll-margin-top: min(32svh, 18rem); }
.story-pinned .process-step:has(.scene-ideation) .stage-copy { min-height: 165svh; display: flex; flex-direction: column; align-items: start; }
.story-pinned .process-step:has(.scene-testing) .stage-copy {
  min-height: 100svh; display: flex; flex-direction: column; align-items: start;
}
.story-pinned .stack-example, .story-pinned .next-question { margin-top: auto; }
.story-pinned .process-step:has(.scene-ideation) .stage-link { margin-block: auto 0; }
.story-pinned .visual-slot {
  pointer-events: none; align-self: stretch; grid-column: 2; grid-row: 1 / span 7; margin: 0;
}
.story-pinned .story-scene {
  position: sticky; top: 3.5svh; width: min(100%, calc((100svh - 8.5rem) * 1.3333)); margin-inline: auto 0;
  opacity: var(--visibility,0);
}
.story-pinned .scene-before-hamburg { opacity: var(--visibility,1); }

@media (min-width: 821px) {
  .process-list:not(.story-pinned) .process-step { display: block; }
  .process-list:not(.story-pinned) .stage-copy {
    display: grid; grid-template-columns: minmax(0,.73fr) minmax(0,1.27fr);
    grid-template-rows: auto auto 1fr; align-items: start;
    column-gap: clamp(2.25rem, 6.3vw, 6.8rem);
  }
  .process-list:not(.story-pinned) .stage-copy > * { grid-column: 1; }
  .process-list:not(.story-pinned) .stage-copy .visual-slot { grid-column: 2; grid-row: 1 / span 3; margin: 0; }
}
@media (max-width: 820px) {
  .story-intro { grid-template-columns: 1fr; gap: 1rem; }
  .story-intro-reading { max-width: 58ch; }
  .process-list .process-step { display: flex; flex-direction: column; gap: 0; padding: 1.65rem 0 2.25rem; border-top: 1px solid var(--line); }
  .stage-copy { display: contents; }
  .stage-prose { order: 1; }
  .visual-slot { width: 100%; margin: 1rem 0 0; order: 2; }
  .stack-example, .next-question, .evidence-questions { order: 3; }
  .process-step .stage-link { order: 4; }
  .story-outputs .shell { grid-template-columns: 1fr; gap: 1.1rem; }
}
@media (max-width: 430px) {
  .friday-timeline { padding: 5%; }
  .friday-timeline li { padding-block: .5em; gap: .25em; }
}
@media print {
  .stage-menu { display: none; }
  .process-list { display: block; }
  .process-list .process-step { display: block; break-inside: avoid; }
  .process-list .stage-copy { display: block; min-height: 0; }
  .process-list .story-scene { position: static; width: 100%; visibility: visible; opacity: 1; }
}
