/* "Follow one buyer": steps scroll on the left, the matching scene plays on the right. */
.journey__grid { display: grid; grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr); gap: clamp(32px, 6vw, 104px); align-items: start; }
.journey__step { min-width: 0; display: grid; align-content: center; gap: 16px; min-height: 76vh; opacity: 0.3; transition: opacity 0.6s var(--ease); }
.journey__step.is-active { opacity: 1; }
.journey__step p { max-width: 46ch; }
.journey__signal { display: grid; grid-template-columns: auto 1fr; gap: 12px; align-items: start; padding-top: 16px; border-top: 1px solid var(--line); color: var(--ink); font-weight: 600; font-size: 16px; }
.journey__signal svg { width: 18px; height: 18px; margin-top: 4px; color: var(--accent); }

.journey__stage { position: sticky; top: 100px; display: grid; gap: 14px; }
.journey__nav { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; }
.journey__nav button { position: relative; padding: 10px 2px 12px; color: var(--ink-3); font-size: 13.5px; font-weight: 700; text-align: left; transition: color 0.3s; }
.journey__nav button::before, .journey__nav button::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 2px; border-radius: 2px; background: var(--line); }
.journey__nav button::after { background: var(--accent); transform-origin: left; scale: 0 1; transition: scale 0.6s var(--ease); }
.journey__nav button.is-active { color: var(--ink); }
.journey__nav button.is-active::after, .journey__nav button.is-past::after { scale: 1 1; }
.journey__panels { display: grid; }

.jp { grid-area: 1 / 1; align-self: start; min-width: 0; display: grid; grid-template-rows: auto 1fr; gap: clamp(16px, 2.2vh, 26px); padding: clamp(20px, 2.6vw, 36px); border-radius: 20px; background: var(--navy); overflow: hidden; }
.jp__word { color: #fff; font-family: var(--font-display); font-weight: var(--display-weight); font-size: clamp(26px, 2.9vw, 44px); line-height: 1.05; letter-spacing: var(--display-track); }
.jp__ui { position: relative; min-width: 0; display: grid; align-content: start; gap: 12px; min-height: 0; padding: clamp(16px, 1.8vw, 24px); border-radius: 14px; background: #fff; color: var(--ink); font-size: 15px; overflow: hidden; }

/* 1. search terms */
.jp-search { min-width: 0; display: flex; align-items: center; gap: 10px; height: 46px; padding: 0 16px; border: 1.5px solid var(--line); border-radius: 999px; font-weight: 600; white-space: nowrap; overflow: hidden; }
.jp-search svg { width: 17px; height: 17px; flex: none; color: var(--ink-3); }
.jp-search i { width: 2px; height: 18px; margin-left: -6px; background: var(--accent); animation: caret 1s steps(2) infinite; }
@keyframes caret { 50% { opacity: 0; } }
.jp__ui > * { min-width: 0; }
.jp-terms { display: grid; gap: 8px; }
.jp-terms li, .jp-leads li { min-width: 0; }
.jp-leads li span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.jp-terms li { display: flex; align-items: center; justify-content: space-between; gap: 12px; height: 42px; padding: 0 14px; border-radius: 10px; background: var(--paper-2); font-weight: 600; font-size: 14.5px; }
.jp-terms li span { position: relative; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.jp-terms li:not(.is-fit) span::after { content: ""; position: absolute; left: 0; right: 0; top: 52%; height: 1.5px; background: currentColor; transform-origin: left; scale: var(--s, 0) 1; }
.jp-terms em, .jp-leads em { flex: none; padding: 3px 10px; border-radius: 999px; background: var(--ink); color: #fff; font-style: normal; font-size: 12px; font-weight: 700; }
.jp-terms .is-fit em, .jp-leads .is-fit em { background: var(--accent); }

/* 2. ad to page */
.jp-match { grid-template-rows: auto 1fr; gap: 16px; }
.jp-ad { display: grid; gap: 4px; padding: 14px 16px; border: 1.5px solid var(--line); border-radius: 12px; }
.jp-ad small { color: var(--ink-3); font-size: 12px; font-weight: 700; }
.jp-ad > span { color: var(--ink-3); font-size: 13.5px; }
.jp-promise-wrap { position: relative; justify-self: start; }
.jp-promise, .jp-fly { display: block; color: var(--blue); font-size: 17px; font-weight: 700; white-space: nowrap; letter-spacing: -0.01em; }
.jp-fly { position: absolute; left: 0; top: 0; transform-origin: 0 0; pointer-events: none; z-index: 3; }
.jp-page { display: grid; align-content: start; gap: 14px; padding: 0 18px 18px; border-radius: 12px; background: var(--paper-2); overflow: hidden; }
.jp-page__chrome { display: flex; gap: 5px; margin: 0 -18px; padding: 10px 14px; border-bottom: 1px solid var(--line); }
.jp-page__chrome i { width: 7px; height: 7px; border-radius: 50%; background: var(--line); }
.jp-page__h { position: relative; justify-self: start; margin-top: 4px; font-size: clamp(20px, 2vw, 26px); line-height: 1.15; font-weight: 700; letter-spacing: -0.025em; white-space: nowrap; }
.jp-page__h::after { content: ""; position: absolute; left: 0; right: 0; bottom: -5px; height: 3px; border-radius: 3px; background: var(--accent); transform-origin: left; scale: var(--u, 0) 1; }
.jp-page__lines { display: grid; gap: 8px; }
.jp-page__lines i { height: 8px; border-radius: 4px; background: var(--line); transform-origin: left; }
.jp-page__lines i:last-child { width: 62%; }
.jp-page__cta { justify-self: start; padding: 10px 18px; border-radius: 999px; background: var(--accent); color: #fff; font-size: 14px; font-weight: 700; }

/* 3. qualification form */
.jp-form { gap: 10px; }
.jp-field { display: grid; grid-template-columns: minmax(96px, 0.42fr) 1fr auto; align-items: center; gap: 10px; min-height: 44px; padding: 0 14px; border: 1.5px solid color-mix(in srgb, var(--accent) calc(var(--done, 0) * 100%), var(--line)); border-radius: 10px; }
.jp-field label { color: var(--ink-3); font-size: 13.5px; font-weight: 600; }
.jp-field span { font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.jp-field i { width: 18px; height: 18px; border-radius: 50%; background: var(--accent); scale: var(--done, 0); }
.jp-field i::after { content: ""; display: block; width: 8px; height: 4px; margin: 5.5px 0 0 5px; border-left: 2px solid #fff; border-bottom: 2px solid #fff; rotate: -45deg; }
.jp-why { padding-top: 4px; color: var(--ink-2); font-size: 14.5px; }

/* 4. feedback loop */
.jp-loop { gap: 14px; }
.jp-leads { display: grid; gap: 8px; }
.jp-leads li { display: flex; align-items: center; justify-content: space-between; gap: 12px; height: 40px; padding: 0 14px; border-radius: 10px; background: var(--paper-2); font-weight: 600; font-size: 14.5px; }
.jp-budget { display: grid; gap: 10px; padding-top: 12px; border-top: 1px solid var(--line); }
.jp-budget div { display: grid; gap: 6px; font-size: 13.5px; font-weight: 700; }
.jp-budget i { display: block; height: 8px; border-radius: 4px; background: var(--line); overflow: hidden; }
.jp-budget b { display: block; height: 100%; border-radius: 4px; background: var(--accent); transform-origin: left; }
.jp-budget div + div b { background: var(--ink-3); }

.journey.is-static .journey__grid { grid-template-columns: minmax(0, 1fr); }
.journey.is-static .journey__step { min-height: 0; padding-block: 28px; }
.journey.is-static .jp { grid-area: auto; max-width: 720px; }
@media (max-width: 960px) {
  .journey__grid { grid-template-columns: 1fr; }
  .journey__stage { display: none; }
  .journey__step { min-height: 0; opacity: 1; padding-block: 28px; gap: 14px; }
  .journey__step + .journey__step { border-top: 1px solid var(--line); }
  .journey__step .jp { grid-area: auto; margin-top: 10px; }
}
@media (max-height: 700px) and (min-width: 961px) {
  .jp-terms li, .jp-leads li { height: 36px; }
  .jp__word { font-size: 26px; }
}
