.ks { position: relative; height: 1000vh; }
.ks-sticky { position: sticky; top: 0; height: 100vh; height: 100svh; overflow: hidden; }
.ks-canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }

.ks-intro { position: absolute; inset: 69px 0 0; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 0 16px 56px; text-align: center; pointer-events: none; }
.ks-intro h1 { display: flex; flex-direction: column; align-items: center; margin: 0; color: var(--kz-strong); font-size: clamp(40px, min(6.3vw, 10vh), 104px); line-height: .94; letter-spacing: -.055em; }
.ks-line { display: block; white-space: nowrap; }
.ks-br { display: none; }
.ks-logo-slot { display: block; width: min(50vw, 760px, 64vh * 2.77); aspect-ratio: 1800 / 650; margin: .14em 0 .2em; }
.ks-intro em, .ks-outro em { color: var(--kz-accent); font-style: normal; }
.ks-intro p { max-width: 500px; margin: clamp(18px, 3vh, 30px) auto 0; color: var(--kz-muted); font-size: clamp(15px, 1.15vw, 17px); line-height: 1.6; }

/* Variant: wordmark to the right of the headline (?hero=side). */
.ks[data-hero="side"] .ks-intro { align-items: stretch; padding-left: max(28px, calc((100vw - 1240px) / 2)); padding-right: max(28px, calc((100vw - 1240px) / 2)); text-align: left; }
.ks[data-hero="side"] .ks-intro h1 { align-items: flex-start; font-size: clamp(40px, min(5.4vw, 10vh), 100px); }
.ks[data-hero="side"] .ks-br { display: block; }
.ks[data-hero="side"] .ks-logo-slot { position: absolute; right: max(28px, calc((100vw - 1240px) / 2)); top: 50%; width: min(42vw, 640px); margin: 0; transform: translateY(-50%); }
.ks[data-hero="side"] .ks-intro p { margin-left: 0; }

.ks-hint { position: absolute; left: 50%; bottom: 22px; transform: translateX(-50%); pointer-events: none; }
.ks-hint { display: inline-flex; flex-direction: column; align-items: center; gap: 10px; color: var(--kz-faint); font: 500 11px/1 "IBM Plex Mono", monospace; letter-spacing: .14em; text-transform: uppercase; }
.ks-hint i { width: 1px; height: 38px; background: linear-gradient(var(--kz-accent), transparent); animation: ks-hint 1.8s ease-in-out infinite; transform-origin: top; }
@keyframes ks-hint { 0% { transform: scaleY(0); } 50% { transform: scaleY(1); } 100% { transform: scaleY(1); opacity: 0; } }

.ks-panel { --accent: #5c93ff; position: absolute; left: max(28px, calc((100vw - 1240px) / 2)); top: 50%; width: min(400px, 34vw); transform: translateY(-50%); opacity: 0; pointer-events: none; transition: opacity .35s ease; }
.ks-panel.is-visible { opacity: 1; pointer-events: auto; }
.ks-panel > * { transition: opacity .28s ease, transform .28s ease; }
.ks-panel.is-swapping > * { opacity: 0; transform: translateY(8px); }
.ks-panel-num { color: var(--accent); font: 500 12px/1 "IBM Plex Mono", monospace; letter-spacing: .14em; }
.ks-panel h2 { margin: 16px 0 0; color: var(--kz-strong); font-size: clamp(32px, 3.6vw, 50px); line-height: 1; letter-spacing: -.04em; }
.ks-panel p { margin: 18px 0 0; color: var(--kz-muted); font-size: 16px; line-height: 1.6; }
.ks-panel ul { margin: 22px 0 0; padding: 0; list-style: none; border-top: 1px solid var(--kz-border); }
.ks-panel li { padding: 11px 0; border-bottom: 1px solid var(--kz-border); color: var(--kz-soft); font-size: 14px; }
.ks-panel li::before { content: ""; display: inline-block; width: 5px; height: 5px; margin: 0 12px 2px 0; border-radius: 50%; background: var(--accent); box-shadow: 0 0 10px var(--accent); }
.ks-panel a { display: inline-block; margin-top: 22px; color: var(--accent); font-weight: 600; text-decoration: none; }

.ks-rail { position: absolute; right: max(28px, calc((100vw - 1240px) / 2)); top: 50%; display: grid; gap: 14px; margin: 0; padding: 0; list-style: none; transform: translateY(-50%); opacity: 0; transition: opacity .35s ease; }
.ks-rail.is-visible { opacity: 1; }
.ks-rail li { display: flex; align-items: center; justify-content: flex-end; gap: 10px; color: var(--kz-faint); font: 500 11px/1 "IBM Plex Mono", monospace; transition: color .3s ease; }
.ks-rail li i { width: 18px; height: 2px; border-radius: 2px; background: currentColor; opacity: .5; transition: width .3s ease, opacity .3s ease, background .3s ease; }
.ks-rail li.active { color: var(--kz-strong); }
.ks-rail li.active i { width: 34px; opacity: 1; background: var(--accent); }

.ks-outro { position: absolute; left: 50%; bottom: 14vh; transform: translateX(-50%); text-align: center; opacity: 0; pointer-events: none; transition: opacity .4s ease; }
.ks-outro.is-visible { opacity: 1; pointer-events: auto; }
.ks-outro h2 { margin: 0 0 26px; color: var(--kz-strong); font-size: clamp(34px, 4.4vw, 60px); line-height: 1; letter-spacing: -.045em; }


/* ---------------------------------------------------------- approach */
.kp-approach { --accent: #49c7cf; padding-block: clamp(72px, 10vh, 120px); }
.kp-approach-head { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 20px 48px; align-items: end; }
.kp-approach-head .kp-heading { max-width: none; }
.kp-approach-head h2 { font-size: clamp(32px, 3.4vw, 50px); }
.kp-approach-head > p { max-width: 400px; margin: 0 0 4px; color: var(--kz-muted); font-size: 16px; line-height: 1.6; }
.kp-approach-body { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); gap: clamp(24px, 4vw, 56px); align-items: start; margin-top: clamp(28px, 4vh, 44px); align-items: stretch; }
.kp-goals { display: flex; flex-direction: column; border-top: 1px solid var(--kz-border); }
.kp-goals button { --goal-accent: var(--kz-faint); position: relative; display: flex; flex: 1 1 0; align-items: center; gap: 18px; width: 100%; min-height: 54px; padding: 12px 4px; border: 0; border-bottom: 1px solid var(--kz-border); background: none; color: var(--kz-muted); font: 500 17px/1.2 "Manrope", sans-serif; text-align: left; cursor: pointer; transition: color .25s ease, padding .35s cubic-bezier(.16,1,.3,1); }
.kp-goals button b { color: var(--kz-faint); font: 500 11px/1 "IBM Plex Mono", monospace; transition: color .25s ease; }
.kp-goals button::after { content: "→"; margin-left: auto; color: var(--goal-accent); opacity: 0; transform: translateX(-8px); transition: opacity .25s ease, transform .35s ease; }
.kp-goals button:hover { color: var(--kz-strong); }
.kp-goals button.active { padding-left: 14px; color: var(--kz-strong); }
.kp-goals button.active b { color: var(--goal-accent); }
.kp-goals button.active::after { opacity: 1; transform: none; }
.kp-goals button.active::before { content: ""; position: absolute; left: 0; top: 50%; width: 3px; height: 22px; border-radius: 3px; background: var(--goal-accent); box-shadow: 0 0 14px var(--goal-accent); transform: translateY(-50%); }



/* ---------------------------------------------------------- process */
.kp-process { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: clamp(32px, 6vw, 96px); align-items: start; }
.kp-process-heading { position: sticky; top: 130px; }
.kp-timeline { --progress: 0; position: relative; display: grid; gap: clamp(40px, 7vh, 72px); margin: 0; padding: 12px 0 12px 64px; list-style: none; }
.kp-timeline-track { position: absolute; left: 15px; top: 20px; bottom: 20px; width: 2px; border-radius: 2px; background: var(--kz-border); }
.kp-timeline-track i { position: absolute; inset: 0; border-radius: inherit; background: linear-gradient(#5c93ff, #35d6e8); box-shadow: 0 0 14px rgba(92,147,255,.7); transform: scaleY(var(--progress)); transform-origin: top; }
.kp-step { position: relative; display: grid; grid-template-columns: 54px 1fr; gap: 6px; opacity: .38; transition: opacity .6s ease; }
.kp-step.is-active { opacity: 1; }
.kp-step-node { position: absolute; left: -57px; top: 8px; width: 18px; height: 18px; border: 2px solid var(--kz-border-strong); border-radius: 50%; background: var(--kz-bg); transition: border-color .5s ease, box-shadow .5s ease, transform .5s ease; }
.kp-step.is-active .kp-step-node { border-color: #5c93ff; box-shadow: 0 0 0 5px rgba(92,147,255,.14), 0 0 18px rgba(92,147,255,.8); transform: scale(1.1); }
.kp-step-num { padding-top: 8px; color: var(--kz-faint); font: 500 12px/1 "IBM Plex Mono", monospace; transition: color .5s ease; }
.kp-step.is-active .kp-step-num { color: #5c93ff; }
.kp-step h3 { margin: 0; color: var(--kz-strong); font-size: clamp(26px, 2.4vw, 34px); letter-spacing: -.035em; }
.kp-step h3 small { margin-left: 8px; color: #35d6e8; font: 500 11px/1 "IBM Plex Mono", monospace; letter-spacing: .1em; text-transform: uppercase; vertical-align: middle; }
.kp-step p { max-width: 460px; margin: 10px 0 0; color: var(--kz-muted); font-size: 16px; line-height: 1.6; }
.kp-step em { display: inline-block; margin-top: 16px; padding: 7px 12px; border: 1px solid var(--kz-border); border-radius: 99px; color: var(--kz-soft); font: 500 11px/1 "IBM Plex Mono", monospace; font-style: normal; letter-spacing: .06em; transition: border-color .5s ease; }
.kp-step.is-active em { border-color: rgba(92,147,255,.4); }

/* ---------------------------------------------------------- results */
.kp-stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; margin-top: 52px; }
.kp-stat { position: relative; overflow: hidden; padding: 30px 28px; border: 1px solid var(--kz-border); border-radius: 22px; background: var(--kz-panel); transition: opacity .7s ease, transform .5s ease, border-color .35s ease; }
.kp-stat::before { content: ""; position: absolute; inset: 0 0 auto; height: 2px; background: linear-gradient(90deg, transparent, var(--accent), transparent); opacity: .8; }
.kp-stat::after { content: ""; position: absolute; right: -60px; top: -60px; width: 200px; height: 200px; border-radius: 50%; background: radial-gradient(circle, color-mix(in srgb, var(--accent) 22%, transparent), transparent 70%); pointer-events: none; }
.kp-stat:hover { border-color: color-mix(in srgb, var(--accent) 45%, transparent); transform: translateY(-4px); }
.kp-stat-tag { color: var(--accent); font: 500 11px/1 "IBM Plex Mono", monospace; letter-spacing: .14em; text-transform: uppercase; }
.kp-stat strong { display: block; margin-top: 26px; color: var(--kz-strong); font: 600 clamp(54px, 5.4vw, 80px)/.9 "Space Grotesk", sans-serif; letter-spacing: -.05em; font-variant-numeric: tabular-nums; }
.kp-stat-label { margin: 12px 0 0; color: var(--kz-soft); font-size: 15px; line-height: 1.45; }
.kp-stat dl { display: grid; gap: 12px; margin: 26px 0 0; padding-top: 20px; border-top: 1px solid var(--kz-border); }
.kp-stat dl div { display: grid; grid-template-columns: 54px 1fr; gap: 10px; }
.kp-stat dt { color: var(--kz-faint); font: 500 10px/1.8 "IBM Plex Mono", monospace; letter-spacing: .1em; text-transform: uppercase; }
.kp-stat dl div:last-child dt { color: var(--accent); }
.kp-stat dd { margin: 0; color: var(--kz-muted); font-size: 14px; line-height: 1.5; }
.kp-stats .kp-stat:nth-child(2) { transition-delay: .08s; }
.kp-stats .kp-stat:nth-child(3) { transition-delay: .16s; }

@media (max-width: 960px) {
  .kp-approach-head, .kp-approach-body, .kp-process { grid-template-columns: 1fr; }
  .kp-goal-card, .kp-process-heading { position: static; }
  .kp-stats { grid-template-columns: 1fr; }
}

@media (max-width: 760px) {
  .kp-goals button { font-size: 16px; }
  .kp-timeline { padding-left: 48px; }
  .kp-timeline-track { left: 9px; }
  .kp-step { grid-template-columns: 1fr; }
  .kp-step-node { left: -48px; }
  .kp-step-num { padding-top: 0; margin-bottom: 6px; }
  .ks-panel { left: 16px; right: 16px; top: auto; bottom: 64px; width: auto; transform: none; padding: 18px; border: 1px solid var(--kz-border); border-radius: 18px; background: rgba(5,7,13,.72); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); }
  .ks-panel h2 { margin-top: 10px; font-size: 28px; }
  .ks-panel p { margin-top: 10px; font-size: 14px; }
  .ks-panel ul { display: none; }
  .ks-panel a { margin-top: 12px; }
  .ks-rail { top: 92px; right: 16px; transform: none; gap: 8px; }
  .ks-rail li span { display: none; }
  .ks-outro { width: calc(100% - 32px); bottom: 14vh; }
  .ks-intro h1, .ks[data-hero="side"] .ks-intro h1 { align-items: center; font-size: clamp(38px, 11.5vw, 60px); }
  .ks[data-hero="side"] .ks-intro { align-items: center; text-align: center; }
  .ks[data-hero="side"] .ks-br { display: none; }
  .ks-logo-slot, .ks[data-hero="side"] .ks-logo-slot { position: static; width: min(88vw, 420px); margin: .3em 0 .35em; transform: none; }
  .ks[data-hero="side"] .ks-intro p { margin-left: auto; }
}
