/* Hero, about, stack and contact. Static by default: everything pinned or
   layered lives under .motion, so no-JS and reduced motion get a normal page. */
section { position: relative; padding: 96px var(--pad); }

/* ---------- hero ---------- */
.hero__poster { display: block; width: min(60vw, 340px); height: auto; margin: 0 0 24px auto; }
.motion .hero__poster { display: none; }
.motion .hero {
  height: 100dvh; min-height: 560px; padding: 72px var(--pad) calc(var(--rail) + 8px);
  display: flex; flex-direction: column; justify-content: flex-end;
}
.hero__copy { display: grid; gap: 18px; justify-items: start; }
.hero__eyebrow a { font-family: var(--mono); font-size: 13px; color: var(--dim); transition: color 0.2s; }
.hero__eyebrow a:hover { color: var(--fg); }
.hero__title {
  font-size: clamp(58px, 13.5vw, 230px); line-height: 0.84; padding-bottom: 0.2em; letter-spacing: -0.02em;
  font-weight: 900; font-variation-settings: "wdth" 125; white-space: nowrap; margin-left: -0.04em;
}
.motion.is-loading .hero__title { overflow: hidden; }
.hero__line { display: inline-block; }
.motion.is-loading .hero__line { transform: translateY(120%); }
.hero__name { display: inline-block; }
.word { display: inline-block; white-space: nowrap; }
.hero__name .ch { display: inline-block; will-change: transform; }
.motion.is-loading .hero__rest { visibility: hidden; }
.hero__sub { max-width: 34ch; font-size: clamp(17px, 1.5vw, 22px); line-height: 1.35; font-weight: 300; }

/* ---------- about ---------- */
.motion .about {
  height: 100dvh; display: flex; flex-direction: column; justify-content: center; gap: 36px;
  padding-bottom: calc(var(--rail) + 8px);
}
.about__text {
  max-width: 1200px; font-size: clamp(27px, 4.1vw, 66px); line-height: 1.12;
  font-weight: 600; font-variation-settings: "wdth" 105; letter-spacing: -0.01em;
}
.about__more { margin-top: 28px; }
.motion .about__more { margin-top: 0; }
.about__text .w { display: inline-block; will-change: transform, opacity; }

/* ---------- stack ---------- */
.stack__groups { display: grid; gap: 40px; }
.group h3 {
  font-size: clamp(32px, 6vw, 96px); font-weight: 800; line-height: 1;
  font-variation-settings: "wdth" 115; letter-spacing: -0.015em; margin-bottom: 18px;
}
.group .tech { font-family: var(--mono); font-size: clamp(13px, 1.3vw, 18px); color: var(--dim); }
.motion .stack { height: 100dvh; overflow: hidden; }
.motion .stack__groups { position: absolute; left: var(--pad); right: var(--pad); bottom: calc(var(--rail) + 40px); display: block; }
.motion .group { position: absolute; left: 0; right: 0; bottom: 0; will-change: transform, opacity; }

/* ---------- contact ---------- */
.contact { display: flex; flex-direction: column; justify-content: flex-end; gap: 26px; }
.motion .contact { min-height: 100dvh; padding-bottom: calc(var(--rail) + 22px); }
.contact__title {
  font-size: clamp(40px, 7vw, 124px); line-height: 0.92; font-weight: 900;
  font-variation-settings: "wdth" 120; letter-spacing: -0.02em;
}
.contact__title span { display: block; }
.contact__mail {
  align-self: flex-start; max-width: 100%; overflow-wrap: anywhere;
  font-size: clamp(20px, 3vw, 44px); font-weight: 300;
  border-bottom: 1px solid var(--line-strong); padding-bottom: 6px; transition: border-color 0.2s;
}
.contact__mail:hover { border-color: var(--fg); }
.contact__links { display: flex; flex-wrap: wrap; gap: 8px 28px; font-family: var(--mono); font-size: 14px; }
.contact__links a { color: var(--dim); transition: color 0.2s; display: inline-block; padding: 6px 0; }
.contact__links a:hover { color: var(--fg); }

@media (max-width: 767px) {
  .motion .contact { justify-content: flex-end; }
}
