/* TRUMAP — main page sections.
   Everything reads complete without script. The class "motion" on <html> (set in <head> only when the
   visitor has not asked for reduced motion) turns on the hidden start states, the pinned steps scene
   and the scroll fill; assets/js/home.js then animates them. */

.h-display {
  font-size: var(--fs-display); font-weight: 800; line-height: 1.12; letter-spacing: -.04em;
}
.h-poster {
  font-size: var(--fs-poster); font-weight: 850; line-height: 1.04; letter-spacing: -.05em;
}
.br-d { display: none; }
@media (min-width: 720px) { .br-m { display: none; } }
@media (min-width: 960px) { .br-d { display: inline; } }

/* 1. Hero */
.hero { padding: clamp(20px, 3vw, 40px) 0 clamp(72px, 9vw, 128px); }
.hero-grid { display: grid; gap: 40px; }
.hero-copy { container-type: inline-size; }
.hero-label { font-size: var(--fs-body); font-weight: 700; color: var(--accent); letter-spacing: -.01em; }
.hero-title {
  margin-top: 18px;
  font-size: clamp(40px, 15.2cqi, 64px);   /* phone: three short lines */
  font-weight: 850; line-height: 1.1; letter-spacing: -.045em;
}
@media (min-width: 720px) { .hero-title { font-size: clamp(48px, 10.2cqi, 104px); } }  /* two lines */
.hero-title .w { display: inline-block; overflow: hidden; vertical-align: top; padding-bottom: .1em; margin-bottom: -.1em; }
.hero-title .w > span { display: inline-block; }
.hero-desc { margin-top: 24px; font-size: var(--fs-statement); line-height: 1.5; color: var(--ink-2); letter-spacing: -.02em; max-width: 30em; }
.hero .store-row { margin-top: 36px; }

.hero-panel {
  position: relative; overflow: hidden;
  display: grid; place-items: center;
  background: var(--surface); border-radius: var(--radius);
  padding: 64px 0;
}
.hero-mark img { width: min(52vw, 240px); height: auto; }

@media (min-width: 960px) {
  .hero { padding-top: clamp(24px, 3vw, 48px); }
  .hero-grid {
    grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gutter);
    align-items: center;
    min-height: calc(100svh - var(--header-h) - clamp(24px, 3vw, 48px) - 24px);
  }
  .hero-copy { grid-column: 1 / span 7; }
  .hero-media { grid-column: 8 / -1; align-self: stretch; display: flex; }
  .hero-panel { flex: 1; min-height: 560px; }
  .hero-title { margin-top: 24px; font-size: min(var(--fs-display), 10.2cqi); }
  .hero-desc { margin-top: 32px; }
  .hero .store-row { margin-top: 48px; }
  .hero-mark img { width: min(360px, 25vw); }
}

/* 2. Problem */
.problem { background: var(--night); color: var(--on-dark); padding: clamp(104px, 13vw, 200px) 0; }
.problem-text { margin-top: clamp(40px, 6vw, 88px); font-size: var(--fs-statement); line-height: 1.55; letter-spacing: -.02em; max-width: 24em; }
@media (min-width: 960px) {
  .problem-grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gutter); }
  .problem-grid .h-poster { grid-column: 1 / -1; }
  .problem-text { grid-column: 7 / -1; }
}

/* 3. Features: the four promo images. Four in a staggered row on wide screens, two by two on
   tablets, a swipeable strip on phones. */
.features { background: var(--surface); padding: clamp(104px, 12vw, 180px) 0; overflow: hidden; }
.shots {
  margin-top: clamp(40px, 5vw, 72px);
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(12px, 1.4vw, 20px);
}
.shots:focus-visible { outline-offset: 8px; }
.shot-card {
  margin: 0; overflow: hidden; border-radius: var(--radius); background: #fff;
  transition: transform .6s var(--ease-out);
}
.shot-card img { width: 100%; height: auto; }
.shot-card:hover { transform: translateY(-8px) scale(1.02); }
@media (min-width: 1200px) {
  .shots { grid-template-columns: repeat(4, minmax(0, 1fr)); align-items: start; }
  .shot:nth-child(even) { margin-top: clamp(48px, 6vw, 96px); }
}
@media (max-width: 719px) {
  .shots {
    display: flex; overflow-x: auto; scroll-snap-type: x mandatory; overscroll-behavior-x: contain;
    margin-inline: calc(-1 * var(--gutter)); padding: 4px var(--gutter) 12px; scroll-padding-inline: var(--gutter);
    scrollbar-width: none;
  }
  .shots::-webkit-scrollbar { display: none; }
  .shot { flex: 0 0 80%; scroll-snap-align: start; }
  .shot-card { border-radius: 22px; }
}

/* 4. Steps, in words only: a list; with motion a pinned scene where each step takes the stage in turn */
.steps { padding: clamp(104px, 12vw, 180px) 0; }
.steps-grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: clamp(32px, 4vw, 56px); }
.steps-nav { min-width: 0; }
.steps-title { container-type: inline-size; }
.steps-title .h-display { font-size: min(var(--fs-display), 12.4cqi); }

.step-progress { display: none; gap: 6px; margin-bottom: clamp(20px, 2.4vw, 36px); }
.step-progress span { flex: 1; height: 4px; border-radius: 2px; background: var(--surface-2); overflow: hidden; }
.step-progress i { display: block; height: 100%; background: var(--accent); transform-origin: 0 50%; transform: scaleX(0); }

.step-list { display: grid; gap: clamp(6px, 1.2vw, 16px); }
.step-line {
  display: grid; grid-template-columns: 1.9em 1fr; align-items: baseline; column-gap: .25em;
  width: fit-content; max-width: calc(100% - 24px); padding: .12em 0; text-align: left;
  font-size: clamp(22px, 3.5vw, 54px); font-weight: 800; line-height: 1.3; letter-spacing: -.04em;
}
.step-num { color: var(--accent); font-variant-numeric: tabular-nums; }

.motion .steps { padding: 0; height: 330svh; }
.motion .steps-sticky {
  position: sticky; top: var(--header-h);
  height: calc(100svh - var(--header-h));
  display: flex; align-items: center; overflow: hidden;
}
.motion .steps-sticky > .wrap { width: min(100% - 2 * var(--gutter), var(--maxw)); }
.motion .step-progress { display: flex; }
.motion .step-line { opacity: .16; transition: opacity .5s var(--ease-out), transform .6s var(--ease-out); }
.motion .step-line:hover { opacity: .45; }
.motion .step.is-active .step-line { opacity: 1; transform: translateX(clamp(10px, 1.6vw, 24px)); }

@media (max-width: 719px) {
  .motion .steps { height: 320svh; }
  .motion .steps-grid { height: 100%; align-content: center; gap: 32px; padding: 16px 0; }
  .motion .steps-nav { display: flex; flex-direction: column-reverse; gap: 32px; }
  .motion .step-progress { margin-bottom: 0; }
  /* The steps sit side by side in a clipped track; --i (set by home.js) moves the active one into view
     at once, and its number and sentence then rise in. Nothing slides across the screen edge. */
  .motion .step-list { display: flex; gap: 0; overflow: hidden; min-height: min(44svh, 340px); }
  .motion .step {
    flex: 0 0 100%; display: flex; align-items: flex-end;
    opacity: 0; pointer-events: none;
    transform: translateX(calc(var(--i, 0) * -100%));
  }
  .motion .step.is-active { opacity: 1; pointer-events: auto; }
  .motion .step.is-active .step-num, .motion .step.is-active .step-text { animation: step-in .6s var(--ease-out) both; }
  .motion .step.is-active .step-text { animation-delay: .08s; }
  .motion .step .step-line, .motion .step.is-active .step-line {
    display: flex; flex-direction: column; align-items: flex-start; gap: 16px;
    width: auto; max-width: none; opacity: 1; transform: none; padding: 0;
    font-size: clamp(28px, 8.6vw, 40px); line-height: 1.3;
  }
  .motion .step-num { font-size: clamp(96px, 32vw, 150px); line-height: .85; letter-spacing: -.06em; }
}
@keyframes step-in { from { opacity: 0; transform: translateY(24px); } }

/* 5. Emphasis: lines darken one by one as the section scrolls past */
.emphasis { background: var(--accent); color: #fff; padding: clamp(112px, 14vw, 220px) 0; }
.fill-wrap { container-type: inline-size; }
.emph-title { font-size: clamp(32px, 9.4cqi, 104px); font-weight: 850; line-height: 1.14; letter-spacing: -.045em; }
.emph-text { margin-top: clamp(40px, 6vw, 80px); font-size: var(--fs-statement); font-weight: 700; line-height: 1.5; letter-spacing: -.025em; }
.fl { display: block; }
@media (min-width: 720px) { .emph-text { margin-left: 40%; } }
@media (min-width: 960px) { .emph-text { margin-left: calc(50% + var(--gutter) / 2); } }
.motion .fl { opacity: .28; }

/* 6. Who it is for */
.fit { padding: clamp(104px, 12vw, 200px) 0; }
.fit-grid { display: grid; gap: clamp(32px, 4vw, 56px); }
.fit-list { display: grid; gap: clamp(24px, 3vw, 44px); }
.fit-list li {
  font-size: clamp(22px, 2.8vw, 40px); font-weight: 800; line-height: 1.35; letter-spacing: -.035em;
  transition: transform .5s var(--ease-out), color .25s;
}
.fit-list li:hover { transform: translateX(8px); color: var(--accent); }
@media (min-width: 720px) {
  .fit-grid { grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gutter); align-items: start; }
  .fit-grid .h-display { grid-column: 1 / span 4; }
  .fit-list { grid-column: 5 / -1; }
}

/* 7. Download */
.cta { background: var(--night); color: var(--on-dark); padding: clamp(104px, 13vw, 200px) 0; overflow: hidden; }
.cta-grid { display: grid; gap: 48px; }
.cta-copy { container-type: inline-size; }
.cta .h-poster { font-size: min(var(--fs-poster), 16cqi); }
.cta .store-row { margin-top: clamp(36px, 4vw, 56px); }
.cta-note { margin-top: 20px; font-size: 15px; color: var(--on-dark-2); }
.cta-media { display: flex; justify-content: flex-start; }
.cta-icon { width: min(42vw, 200px); height: auto; transform: rotate(-6deg); }
@media (min-width: 720px) {
  .cta-grid { grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gutter); align-items: center; }
  .cta-copy { grid-column: 1 / span 9; }
  .cta-media { grid-column: 10 / -1; justify-content: center; }
  .cta-icon { width: min(300px, 22vw); }
}
.cta :focus-visible, .problem :focus-visible, .emphasis :focus-visible { outline-color: #fff; }

/* Start states for the entrance; home.js plays them. Only the first screen is hidden by CSS. */
.motion [data-hero], .motion .hero-panel { opacity: 0; }
.motion .hero-title .w > span { transform: translateY(110%); }
