/* Homepage: hero, journey map, what I do, contact. */

/* Hero */
.hero { padding: calc(var(--nav-h) + clamp(48px, 7vw, 104px)) 0 clamp(56px, 6vw, 88px); }
.hero-grid { max-width: 880px; }
.hero-title { margin-top: 26px; font-size: clamp(44px, 5.1vw, 76px); line-height: .99; letter-spacing: -.045em; word-spacing: .03em; font-weight: 900; }
.hero-title .ln { display: block; }
.hero-title .accent { color: var(--blue); }
.hero-lead { margin-top: 26px; max-width: 540px; color: var(--text); hyphens: manual; -webkit-hyphens: manual; }
.hero-lead .me { color: var(--ink); font-weight: 800; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 34px; }
.hero-in { animation: rise .95s var(--out) both; animation-delay: calc(var(--i, 0) * 70ms + 60ms); }
@keyframes rise { from { opacity: 0; transform: translateY(22px); } }

/* The mascot holding on to a card's top edge (contact card) */
.peek { position: absolute; z-index: 2; right: 6%; bottom: calc(100% - 10px); width: 46%; aspect-ratio: 520 / 326; clip-path: inset(-60% -30% 0 -30%); pointer-events: none; }
.peek img { width: 100%; height: auto; transform-origin: 50% 100%; animation: peek .9s var(--spring) .95s both; transition: transform .6s var(--spring); }
@keyframes peek { from { transform: translateY(78%); } }

/* Hover lifts use translate/scale so they never fight the reveal's transform */
html.js .wcard.rv { transition: opacity .7s ease, transform .9s var(--out), translate .5s var(--spring), scale .5s var(--spring), box-shadow .4s; transition-delay: calc(var(--d, 0) * 80ms), calc(var(--d, 0) * 80ms), 0s, 0s, 0s; }

/* Journey. Without JS: title + four chapters. Reduced motion: plus the whole route on a static map card. */
.jr { position: relative; padding: clamp(88px, 12vw, 160px) 0; }
.jr-map, .jr-steps { display: none; }
.jr-title { width: fit-content; font-size: var(--t-h2); }
.jr-chs { list-style: none; margin: clamp(40px, 5vw, 64px) 0 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 32px; }
.jr-ch .when { font-size: 15px; font-weight: 800; color: var(--blue); font-variant-numeric: tabular-nums; }
.jr-ch h3 { margin-top: 8px; font-size: var(--t-h3); line-height: 1.1; letter-spacing: -.035em; }
.jr-ch p:last-child { margin-top: 10px; font-size: 17px; line-height: 1.45; font-weight: 600; }
.jr.has-map:not(.live) .jr-stage { display: flex; flex-direction: column-reverse; }
.jr.has-map:not(.live) .jr-map { display: block; position: relative; width: calc(min(var(--wrap), 100%) - 2 * var(--gutter)); height: clamp(300px, 44vw, 500px); margin: clamp(40px, 5vw, 64px) auto 0; border-radius: var(--r-xl); overflow: hidden; box-shadow: 0 0 0 1px var(--mist); }
.jr-map svg { position: absolute; inset: 0; width: 100%; height: 100%; }

/* Live: a pinned stage, the page scroll flies the plane */
.jr.live { height: 460vh; padding: 0; }
.jr.live .jr-stage { position: sticky; top: 0; height: 100vh; height: 100svh; overflow: hidden; }
.jr.live .jr-map { display: block; position: absolute; inset: 0; }
.jr.live .jr-map::after { content: ''; position: absolute; inset: 0 auto 0 0; width: min(52%, 720px); background: linear-gradient(90deg, var(--snow) 55%, rgba(244, 246, 250, 0)); pointer-events: none; }
.jr.live .jr-ui { position: relative; height: 100%; display: flex; flex-direction: column; padding-top: calc(var(--nav-h) + clamp(32px, 6vh, 72px)); padding-bottom: clamp(32px, 7vh, 72px); pointer-events: none; }
.jr.live .jr-story { margin: auto 0; max-width: 400px; pointer-events: auto; }
.jr.live .jr-chs { grid-template-columns: 1fr; margin: 0; gap: 0; }
.jr.live .jr-ch { grid-area: 1 / 1; opacity: 0; visibility: hidden; will-change: transform, opacity; }
.jr.live .jr-ch h3 { font-size: clamp(30px, 3.6vw, 48px); line-height: 1.02; letter-spacing: -.045em; }
.jr.live .jr-ch p:last-child { font-size: 19px; max-width: 380px; }
.jr.live .jr-steps { display: flex; gap: 6px; margin-top: 28px; }
.jr-steps button { height: 32px; padding: 0 12px; border: 0; border-radius: 999px; background: rgba(35, 43, 61, .06); font-size: 13px; font-weight: 900; color: var(--muted); cursor: pointer; transition: background .3s, color .3s, transform .4s var(--spring); }
.jr-steps button:hover { color: var(--ink); }
.jr-steps button.on { background: var(--ink); color: var(--white); transform: scale(1.06); }

.jr-land path { fill: var(--white); stroke: var(--mist); stroke-width: 1; vector-effect: non-scaling-stroke; stroke-linejoin: round; transition: fill .9s, stroke .9s; }
.jr-land path.on { fill: var(--sky-soft); stroke: var(--sky); }
.jr-trail { fill: none; stroke: var(--blue); stroke-width: 2.5; stroke-linecap: round; stroke-dasharray: .5 8; }
.jr-dot { fill: var(--white); stroke: var(--faint); stroke-width: 2.5; transition: fill .5s, stroke .5s; }
.jr-dot.on { fill: var(--blue); stroke: var(--white); }
.jr-dot.now { fill: var(--green); }
.jr-ring { fill: none; stroke: var(--blue); stroke-width: 2; opacity: 0; transform-box: fill-box; transform-origin: center; }
.jr-ring.go { animation: ring 1.3s var(--out); }
.jr-ring.now { stroke: var(--green); animation: ring 2.4s ease-out infinite; }
@keyframes ring { from { opacity: .9; } to { opacity: 0; transform: scale(4.2); } }
.jr-name { font: 900 15px var(--font); letter-spacing: .01em; opacity: 0; transition: opacity .6s; }
.jr-label { fill: var(--ink); }
.jr-halo { fill: var(--snow); stroke: var(--snow); stroke-width: 5px; stroke-linejoin: round; }
.jr-name.on { opacity: 1; }
.jr-plane { fill: var(--ink); }
.jr-shadow { fill: rgba(35, 43, 61, .16); }

/* What I do */
.sec-title { font-size: var(--t-h2); }
.work-links { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; margin-top: clamp(36px, 4.4vw, 56px); }
.wcard { display: flex; flex-direction: column; padding: clamp(28px, 3.4vw, 44px); border-radius: var(--r-xl); color: var(--text); transition: translate .5s var(--spring), scale .5s var(--spring), box-shadow .4s; }
@media (hover: hover) { .wcard:hover { translate: 0 -5px; box-shadow: var(--shadow-3); } }
.wcard:active { scale: .985; }
.wlink { background: var(--ink); }
.wlink .link { font-size: clamp(20px, 1.9vw, 24px); letter-spacing: -.02em; color: var(--white); }
.wlink:hover .link::after { transform: translateX(3px); }

/* Contact */
.contact { padding-bottom: clamp(72px, 9vw, 120px); }
.contact-card { position: relative; margin-top: 70px; padding: clamp(48px, 7vw, 96px) clamp(28px, 6vw, 88px); border-radius: var(--r-xl); background: var(--ink); text-align: center; }
.contact-card h2 { font-size: var(--t-h1); color: var(--white); }
.contact-card .lead { max-width: 560px; margin: 20px auto 0; color: var(--mist); }
.contact-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin-top: 36px; }
.contact-card .btn { background: var(--white); color: var(--ink); box-shadow: none; }
.contact-card .btn.soft { background: rgba(255, 255, 255, .12); color: var(--white); }
.contact-card .btn.soft:hover { background: rgba(255, 255, 255, .2); }
.peek-c { right: auto; left: 50%; width: 190px; margin-left: -95px; bottom: calc(100% - 9px); aspect-ratio: 300 / 194; }
.peek-c img { animation: none; }
html.js .contact-card.rv .peek-c img { transition: transform .9s var(--spring) .35s; }
html.js .contact-card.rv:not(.in) .peek-c img { transform: translateY(80%); }
@media (hover: hover) { .contact-card:hover .peek-c img { transform: translateY(-8%); transition-delay: 0s; } }

/* Narrower screens */
@media (max-width: 900px) {
  .hero { padding-top: calc(var(--nav-h) + 28px); }
  .hero-title { margin-top: 22px; }
  .jr-chs { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .work-links { grid-template-columns: 1fr; gap: 12px; }
}
@media (max-width: 640px) {
  .hero-title { font-size: clamp(38px, 11vw, 52px); margin-top: 20px; }
  .hero-lead { margin-top: 16px; font-size: 18px; }
  .hero-cta { margin-top: 22px; }
  .hero-cta .btn { padding: 0 20px; font-size: 16px; }
  .jr-chs { grid-template-columns: 1fr; }
  .jr.live .jr-ui { padding-top: calc(var(--nav-h) + 24px); padding-bottom: calc(16px + env(safe-area-inset-bottom)); }
  .jr.live .jr-story { margin: auto 0 0; max-width: none; padding: 22px 22px 18px; border-radius: 26px; background: rgba(255, 255, 255, .86); -webkit-backdrop-filter: saturate(180%) blur(18px); backdrop-filter: saturate(180%) blur(18px); box-shadow: 0 0 0 1px rgba(35, 43, 61, .06), var(--shadow-2); }
  .jr.live .jr-map::after { inset: 0 0 auto; width: auto; height: calc(var(--nav-h) + 110px); background: linear-gradient(var(--snow) 70%, rgba(244, 246, 250, 0)); }
  .jr.live .jr-ch h3 { font-size: 28px; }
  .jr.live .jr-ch p:last-child { font-size: 16px; }
  .jr.live .jr-steps { margin-top: 16px; }
  .jr-steps button { flex: 1; padding: 0 6px; }
  .wcard { padding: 24px 28px; border-radius: 30px; }
  .contact-card { margin-top: 64px; padding: 64px 24px 32px; border-radius: 30px; }
  .contact-actions .btn { flex: 1 1 100%; }
  .peek-c { width: 150px; margin-left: -75px; }
}
:lang(de) .hero-title { font-size: clamp(40px, 4.7vw, 70px); }
@media (max-width: 640px) {
  :lang(de) .hero-title { font-size: clamp(34px, 9.4vw, 46px); }
}

@media (prefers-reduced-motion: reduce) {
  .hero-in, .peek img, .jr-ring.now { animation: none; }
  .wcard, .peek img { transition: none; }
}
