/* Sections 3–5 only: native document flow after the existing Fields scene. */
.site-shell.is-flow-chapters {
  height: auto;
}

.site-shell.is-flow-chapters .capabilities,
.site-shell.is-flow-chapters .founder,
.site-shell.is-flow-chapters .contact {
  height: auto;
  inset: auto;
  position: relative;
}

.site-shell.is-flow-chapters .capabilities {
  margin-top: 372dvh;
}

.site-shell.is-flow-chapters .capabilities,
.site-shell.is-flow-chapters .founder,
.site-shell.is-flow-chapters .contact {
  align-items: start;
  column-gap: clamp(20px, 2vw, 32px);
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  min-height: 0;
  overflow: visible;
  padding: clamp(72px, 7vw, 112px) var(--site-gutter) 0;
  pointer-events: auto;
}

.site-shell.is-flow-chapters .capabilities::before,
.site-shell.is-flow-chapters .founder::before {
  display: none;
}

/* Keep the original dot workspace behind every desktop card column. */
@media (min-width: 761px) {
  .site-shell.is-flow-chapters .capabilities::after,
  .site-shell.is-flow-chapters .founder::after,
  .site-shell.is-flow-chapters .contact::after {
    background-image: radial-gradient(circle, rgba(16, 18, 22, .24) 1px, transparent 1.1px);
    background-attachment: fixed;
    background-size: 12px 12px;
    bottom: 0;
    content: '';
    display: block;
    left: calc(50% + clamp(8px, .8vw, 16px));
    pointer-events: none;
    position: absolute;
    right: var(--site-gutter);
    top: 0;
    visibility: visible;
    z-index: 1;
  }
}

.site-shell.is-flow-chapters .capability-intro,
.site-shell.is-flow-chapters .founder-intro,
.site-shell.is-flow-chapters .contact-intro {
  align-self: start;
  grid-column: 1 / span 6;
  max-width: 42rem;
  opacity: 1;
  position: sticky;
  top: var(--flow-sticky-top, clamp(72px, 7vw, 112px));
  transform: none;
  visibility: visible;
}

/* Sections 3 and 4 stay centered via their calculated sticky top. Do not use
   a transform here: transformed bounds cannot release with the final card. */
.site-shell.is-flow-chapters .capability-intro,
.site-shell.is-flow-chapters .founder-intro {
  transform: none;
}

.site-shell.is-flow-chapters .capability-stage,
.site-shell.is-flow-chapters .founder-stage,
.site-shell.is-flow-chapters .contact-stage {
  align-self: start;
  grid-column: 7 / -1;
  height: auto;
  margin: 0;
  max-width: none;
  opacity: 1;
  overflow: visible;
  position: static;
  transform: none !important;
  visibility: visible;
  width: 100%;
}

@media (min-width: 761px) {
  .site-shell.is-flow-chapters .capability-stage,
  .site-shell.is-flow-chapters .founder-stage,
  .site-shell.is-flow-chapters .contact-stage {
    position: relative;
    z-index: 2;
  }
}

.site-shell.is-flow-chapters .capability-card,
.site-shell.is-flow-chapters .founder-stage .capability-card,
.site-shell.is-flow-chapters .contact-stage .capability-card {
  height: auto;
  margin: 0 auto clamp(28px, 3vw, 52px);
  opacity: 1;
  pointer-events: auto;
  position: relative;
  transform: none !important;
  width: 82%;
}

.site-shell.is-flow-chapters .capability-card:last-child,
.site-shell.is-flow-chapters .founder-stage .capability-card:last-child,
.site-shell.is-flow-chapters .contact-stage .capability-card:last-child {
  margin-bottom: 0;
}

.site-shell.is-flow-chapters .capability-examples {
  flex: 0 0 auto;
  overflow: visible;
}

.site-shell.is-flow-chapters .contact-action {
  margin: clamp(26px, 2.6vw, 42px) auto 0;
  width: 82%;
}

/* CONTACT occupies one viewport itself, so its center is the visible viewport
   center when the page reaches its end. */
.site-shell.is-flow-chapters .contact {
  align-items: center;
  margin-bottom: 0;
  min-height: 100dvh;
  padding-bottom: calc(clamp(72px, 7vw, 112px) + clamp(96px, 8dvh, 128px));
}

.site-shell.is-flow-chapters .contact-intro {
  align-self: center;
  position: static;
  top: auto;
  transform: none;
}

.site-shell.is-flow-chapters .contact-stage {
  align-self: center;
  transform: none !important;
}

@media (prefers-reduced-motion: no-preference) {
  .site-shell.is-flow-chapters .capabilities .wipe-text,
  .site-shell.is-flow-chapters .founder .wipe-text,
  .site-shell.is-flow-chapters .contact .wipe-text {
    opacity: 0;
  }

  .site-shell.is-flow-chapters .capabilities .wipe-cover,
  .site-shell.is-flow-chapters .founder .wipe-cover,
  .site-shell.is-flow-chapters .contact .wipe-cover {
    display: block;
  }

}

@media (max-width: 760px) {
  .site-shell.is-flow-chapters .capabilities,
  .site-shell.is-flow-chapters .founder,
  .site-shell.is-flow-chapters .contact {
    column-gap: 0;
    grid-template-columns: minmax(0, 1fr);
    min-height: 100dvh;
    padding: 72px 24px 0;
  }

  .site-shell.is-flow-chapters .capabilities {
    margin-top: 420dvh;
  }

  .site-shell.is-flow-chapters .contact {
    margin-bottom: 0;
    padding-bottom: 56px;
  }

  .site-shell.is-flow-chapters .capability-intro,
  .site-shell.is-flow-chapters .founder-intro,
  .site-shell.is-flow-chapters .contact-intro {
    grid-column: 1 / -1;
    margin: 0 0 42px;
    position: static;
    top: auto;
    transform: none;
  }

  .site-shell.is-flow-chapters .capability-stage,
  .site-shell.is-flow-chapters .founder-stage,
  .site-shell.is-flow-chapters .contact-stage {
    grid-column: 1 / -1;
    max-width: none;
    transform: none !important;
  }

  .site-shell.is-flow-chapters .capability-card,
  .site-shell.is-flow-chapters .founder-stage .capability-card,
  .site-shell.is-flow-chapters .contact-stage .capability-card,
  .site-shell.is-flow-chapters .contact-action {
    width: 100%;
  }
}
