:root {
  color-scheme: light;
  --ivory: #fcf3e5;
  --ink: #2c211b;
  --gold: #ffc071;
  font-family: system-ui, sans-serif;
}
* { box-sizing: border-box; }
body { margin: 0; }
h1, h2, h3, p { margin: 0; }
a { color: inherit; }
a:focus-visible, summary:focus-visible { outline: 3px solid #da7927; outline-offset: 5px; }
.sequence { background: var(--ivory); }
.stage {
  position: sticky;
  top: 0;
  height: 100svh;
  min-height: 575px;
  isolation: isolate;
  transform: translateY(var(--video-lift, 0px));
  overflow: hidden;
  background: radial-gradient(ellipse at 95% 0%, #654029, #2e221b 63%, #211913);
  color: var(--ivory);
}
.scene {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: -2;
}
.stage::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(90deg, #1c110ce8, #1c110c70 58%, transparent);
  opacity: var(--interior-opacity, 1);
  pointer-events: none;
}
.interior {
  max-width: 1350px;
  min-height: 100%;
  margin: auto;
  padding: clamp(16px, 4vh, 36px) clamp(20px, 6vw, 92px);
  display: flex;
  flex-direction: column;
  opacity: var(--interior-opacity, 1);
  transform: translateY(var(--interior-y, 0));
}
.hero { flex: 1; display: grid; align-items: center; padding-block: 10px 58px; }
.intro {
  display: grid;
  grid-template-columns: minmax(0, max-content);
  width: fit-content;
  max-width: 100%;
}
/* Let the headline alone determine the width of the hero content. */
.intro > :not(h1) { contain: inline-size; }
.architecture {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 3 / 2;
  margin-bottom: 12px;
  filter: drop-shadow(0 7px 12px #170e0959);
}
@media (min-width: 701px) and (min-height: 900px) {
  .architecture { transform: translateY(-80px); }
}
h1 {
  font-size: 3.75rem;
  letter-spacing: -.031em;
  font-weight: 650;
  line-height: 1.04;
  text-wrap: balance;
}
h1 em { color: var(--gold); font-weight: inherit; }
.intro p { margin-block: 23px; max-width: 42ch; line-height: 1.55; color: #f2dfca; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.button { display: inline-block; border-radius: 7px; padding: 12px 18px; color: #23170f; background: var(--gold); text-decoration: none; font-weight: 650; }
.button:hover { background: #ffd39d; }
.story-play { border: 0; font-family: inherit; font-size: inherit; cursor: pointer; }
.story-play:focus-visible { outline: 3px solid var(--gold); outline-offset: 4px; }
.scroll-hint { color: #f8dec0; font-size: .875rem; letter-spacing: .025em; }
.beat {
  position: relative;
  min-height: calc(100svh - min(300px, 28svh));
  display: grid;
  align-items: center;
  justify-items: start;
  padding: clamp(24px, 7vw, 110px);
  pointer-events: none;
}
.beat:nth-child(even) { justify-items: end; }
.panel {
  width: min(100%, 520px);
  padding: clamp(20px, 3.2vw, 44px);
  border: 1px solid #f5d3ad;
  border-radius: 15px;
  background: var(--ivory);
  color: var(--ink);
  box-shadow: 0 24px 65px #21130e60;
  opacity: var(--panel-opacity, 1);
  transform: translateY(var(--panel-offset, 0));
  pointer-events: auto;
}
.panel:focus-within { opacity: 1; transform: none; }
.panel h2 {
  font-size: clamp(1.75rem, 3.7vw, 3.15rem);
  letter-spacing: -.055em;
  line-height: 1.02;
  text-wrap: balance;
}
.panel p { margin-top: 15px; line-height: 1.55; }
.back-link { display: inline-block; margin-top: 16px; text-underline-offset: 4px; }
.roles { display: grid; gap: 12px; margin: 18px 0 0; }
.roles dt { font-weight: 700; }
.roles dd { margin: 3px 0 0; }
.beat:last-child { min-height: 100svh; }
.product-section {
  --product-line: #dce4f1;
  --product-accent: #2848b6;
  display: grid;
  padding: clamp(50px, 10vw, 150px) clamp(24px, 9vw, 150px);
  background: linear-gradient(180deg, #f2f6ff, #fff 36%);
  color: #172340;
}
.product-inner {
  width: min(100%, 1180px);
  margin-inline: auto;
  display: flex;
  flex-direction: column;
  min-width: 0;
}
.product-heading h2 {
  font-size: clamp(2rem, 4.8vw, 4.35rem);
  line-height: .98;
  letter-spacing: -.065em;
  text-wrap: balance;
}
.product-inner p { margin-top: 14px; max-width: 60ch; line-height: 1.6; color: #43536f; }
.product-features, .project-walkthrough {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(24px, 4vw, 60px);
  margin-top: clamp(42px, 7svh, 96px);
  padding-top: clamp(24px, 4vw, 55px);
  border-top: 1px solid var(--product-line);
}
.product-inner h3 { font-size: clamp(1.55rem, 3.3vw, 3rem); letter-spacing: -.04em; line-height: 1.08; }
.connection-roadmap { margin-top: 24px; }
.connection-roadmap h3 { font-size: 1rem; letter-spacing: 0; }
.connection-viewport { overflow: clip; }
.connection-list {
  display: flex;
  flex: none;
  width: max-content;
  gap: 16px;
  list-style: none;
  margin: 10px 0 0;
  padding: 4px 10px 12px 2px;
}
.connection-list li {
  flex: none;
  padding: 8px 18px;
  border: 1px solid var(--product-line);
  border-radius: 8px;
  background: #fff;
  font-weight: 650;
  white-space: nowrap;
}
.gantt-chart {
  --labels: clamp(4.5rem, 8vw, 6.25rem);
  --chart-padding: clamp(14px, 2.4vw, 32px);
  position: relative;
  min-height: 0;
  padding: var(--chart-padding);
  border: 1px solid var(--product-line);
  border-radius: 12px;
  background: #fff;
}
.gantt-axis { display: flex; justify-content: space-between; margin: 0 0 8px var(--labels); font-size: .78rem; }
.gantt-chart ol { list-style: none; margin: 0; padding: 0; }
.gantt-chart li {
  position: relative;
  display: grid;
  align-items: center;
  grid-template-columns: var(--labels) 1fr;
  min-height: 22px;
  border-bottom: 1px solid #edf1f7;
  font-size: .8rem;
}
.gantt-chart li i {
  grid-column: 2;
  position: relative;
  left: var(--start);
  width: var(--span);
  height: 8px;
  border-radius: 4px;
  background: #94a7ca;
}
.gantt-highlight {
  position: absolute;
  inset: calc(var(--chart-padding) + 21px) var(--chart-padding) var(--chart-padding)
    calc(var(--chart-padding) + var(--labels));
  pointer-events: none;
}
.gantt-highlight span {
  position: absolute;
  inset: 0 auto 0 48%;
  width: 25%;
  border: 1px solid #5574c8;
  border-radius: 4px;
  background: #5376dd26;
}
.gantt-highlight b {
  position: absolute;
  inset: 2px 0 auto;
  color: #223b8e;
  font-size: .72rem;
  text-align: center;
}
.product-features > section {
  display: grid;
  grid-template-rows: subgrid;
  grid-row: span 3;
  row-gap: 14px;
}
.product-features > section p { margin: 0; }
.feature-image { margin: 4px 0 0; }
.feature-image img {
  display: block;
  width: 100%;
  height: auto;
  border: 1px solid var(--product-line);
  border-radius: 12px;
  background: #fff;
}
.feature-image figcaption { margin-top: 8px; color: #43536f; font-size: .875rem; }
.project-walkthrough { grid-template-columns: minmax(0, 1fr); gap: 18px; }
.walkthrough-steps { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px 36px; margin: 0; }
.walkthrough-steps div { padding-top: 12px; border-top: 1px solid var(--product-line); }
.walkthrough-steps dt { font-weight: 700; }
.walkthrough-steps dd { margin: 4px 0 0; color: #43536f; line-height: 1.48; }
.project-recording { min-width: 0; margin: 0; }
.project-recording video {
  display: block;
  width: 100%;
  height: auto;
  background: #131313;
  border: 1px solid var(--product-line);
  border-radius: 14px;
}
.project-recording figcaption { margin-top: 10px; color: #43536f; font-size: .9rem; }
.product-inner .back-link { align-self: flex-start; margin-top: 36px; color: var(--product-accent); }

@media (max-width: 700px) {
  .stage { min-height: 630px; }
  .hero { padding-block: 12px; }
  h1 { font-size: clamp(2.25rem, 7vw, 3.25rem); }
  .intro p { margin-block: 12px; }
  .product-features { grid-template-columns: 1fr; }
  .walkthrough-steps { grid-template-columns: 1fr; }
}
@media (min-width: 701px) and (max-height: 700px) {
  h1 { font-size: clamp(2.35rem, 7svh, 3.75rem); }
}
@media (prefers-reduced-motion: reduce) {
  .beat, .beat:last-child { min-height: auto; }
  .stage { position: relative; height: auto; }
  .interior { min-height: min(100svh, 770px); }
  .scroll-hint { display: none; }
  .connection-list { width: auto; flex-wrap: wrap; }
}
