/* Zweitlicht – start page only. Builds on css/site.css: no own colours, buttons or type scale here, only layout and motion.
   Motion rule: only transform / opacity animate. Hidden-for-animation states exist only under html.js AND no reduced motion. */
/* Back button: Chrome restores the scroll position by a scroll-anchor node; on this page (headline split into words by js/main.js,
   reveal transforms) that node lands 18–115 px off. Without anchoring the plain pixel offset is restored, which is exact here. */
html{overflow-anchor:none}

/* ---------- pointer light + ghost words ---------- */
.fx-light{position:fixed;left:0;top:0;z-index:50;width:620px;height:620px;margin:-310px 0 0 -310px;border-radius:50%;pointer-events:none;
  opacity:0;visibility:hidden;will-change:transform,opacity;transform:translate3d(-999px,-999px,0)}
.fx-light::before{content:"";position:absolute;inset:0;border-radius:50%;background:var(--zl-halo);opacity:.32}
.ghost{position:absolute;left:0;z-index:0;pointer-events:none;user-select:none;-webkit-user-select:none;white-space:nowrap;will-change:transform}
.ghost::before{content:attr(data-ghost);display:block;font:800 clamp(120px,18vw,290px)/1 var(--zl-f-head);letter-spacing:-.03em;color:transparent;
  -webkit-text-stroke:1.5px color-mix(in srgb,var(--zl-amber) 8.5%,transparent)}
.ghost-doors{top:-1vw}
.ghost-doors::before{-webkit-text-stroke-color:color-mix(in srgb,var(--zl-amber) 6%,transparent)}
.ghost-lit{bottom:-5vw}
.ghost-lit::before{-webkit-text-stroke-color:color-mix(in srgb,var(--zl-clear) 7%,transparent)}

/* ---------- 1 · hero ---------- */
/* the shared night (.site-sky): its room glow sits behind the lamp */
.hero{position:relative;overflow:hidden;min-height:100svh;display:flex;align-items:center;padding:calc(var(--zl-header) + 28px) 0 48px;--sky-x:72%;--sky-y:50%}
.hero-grid{position:relative;z-index:2;display:grid;grid-template-columns:minmax(0,1fr) auto;grid-template-rows:1fr auto auto auto 1fr;column-gap:clamp(40px,6vw,104px);align-items:end}
.hero-copy{grid-column:1;grid-row:2;max-width:620px}
.hero-copy h1{margin:0}
.hero-lead{margin-top:clamp(18px,2.6vh,28px)}
.hero-stage{position:relative;grid-column:2;grid-row:1 / 6;align-self:center;margin:0;
  height:clamp(440px,calc(100svh - var(--zl-header) - 84px),780px);aspect-ratio:4 / 5;will-change:transform}
.hero-halo{position:absolute;left:50%;top:58%;width:150%;aspect-ratio:1;margin-left:-75%;transform:translateY(-50%);border-radius:50%;pointer-events:none;
  background:var(--zl-halo)}
/* img/start-an|aus.webp: the lamp alone with real transparency (no room, no rectangle); its glow fades to alpha 0 inside
   the picture. The lamp spans the middle 73% of the picture, so the picture overhangs the stage and the lamp fills it. */
.hero-photo{position:absolute;left:-12.5%;top:-12.5%;width:125%;height:125%}
.hero-fallback{position:absolute;left:50%;top:50%;height:66%;width:auto;transform:translate(-50%,-50%)}
.hero-photo img{position:absolute;inset:0;width:100%;height:100%;object-fit:contain}
.hero-photo.no-photo img,.hero-photo:not(.no-photo) .hero-fallback{display:none}  /* the drawn lamp only stands in for a missing picture */
/* both pictures have transparency, so the unlit one must leave once the lit one is in (static / reduced motion: lit only) */
.lamp-off{opacity:0}
.hero-chip{position:absolute;left:4%;bottom:16%;z-index:3}
.buy-head{grid-column:1;grid-row:3;display:flex;align-items:flex-end;justify-content:space-between;gap:16px 32px;max-width:620px;
  margin-top:clamp(28px,5vh,52px);padding-top:clamp(18px,2.6vh,26px);border-top:1px solid var(--zl-line)}
.buy-name{font:600 clamp(22px,1.8vw,27px)/1.15 var(--zl-f-head);letter-spacing:-.015em;margin-bottom:8px}
.buy-act{grid-column:1;grid-row:4;display:flex;align-items:center;gap:14px 24px;max-width:620px;margin-top:clamp(16px,2.4vh,24px)}
.buy-head .nw{white-space:nowrap}  /* «LED-Licht» never breaks at its hyphen */
.buy-note{font-size:var(--zl-fs-small);line-height:1.5;color:var(--zl-fg-3);max-width:24em}

/* ---------- 2 · doors ---------- */
.doors{position:relative;overflow:hidden;background:var(--zl-night);padding:clamp(56px,9vh,104px) 0 var(--zl-section)}
.doors > .site-wrap{position:relative;z-index:1}
.doors .site-door{background-color:var(--zl-night)}  /* cards stay the same, but the ghost word no longer shows through */
.site-door.tilting{transition:transform .12s linear,box-shadow var(--zl-t) var(--zl-ease)}

/* ---------- 3 · Wir ---------- */
.wir{overflow:hidden;padding:var(--zl-section) 0}
.wir-grid{position:relative;z-index:1;display:grid;grid-template-columns:minmax(0,1.1fr) minmax(0,.9fr);gap:clamp(32px,6vw,96px);align-items:center}
.wir-copy h2{max-width:none}
.wir-text{margin-top:var(--zl-s5);color:var(--zl-fg-2);max-width:34em}
.wir-team{margin-top:var(--zl-s4);font-weight:600;color:var(--zl-fg);max-width:34em}
.partner{position:relative;overflow:hidden;border-radius:var(--zl-r-lg);padding:clamp(28px,3vw,40px);
  background:color-mix(in srgb,var(--zl-night) 34%,transparent);box-shadow:inset 0 0 0 1px var(--zl-line)}
.partner-row{height:58px;margin:-4px 0 18px;overflow:hidden;
  -webkit-mask-image:linear-gradient(90deg,transparent,black 18%,black 82%,transparent);mask-image:linear-gradient(90deg,transparent,black 18%,black 82%,transparent)}
.partner-row i{display:block;width:300%;height:100%;will-change:transform;
  background:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 46 58'%3E%3Cpath d='M20 3H26V14C26 18 35 20 35 27V52C35 54 33 56 31 56H15C13 56 11 54 11 52V27C11 20 20 18 20 14Z' fill='none' stroke='%23EDF2EE' stroke-opacity='.32' stroke-width='1.3' stroke-linejoin='round'/%3E%3C/svg%3E") repeat-x 0 0/46px 58px}
.partner h3{font-size:var(--zl-fs-h3);font-weight:800;letter-spacing:var(--zl-track-head)}
.partner p{margin:var(--zl-s3) 0 var(--zl-s5);color:var(--zl-fg-2)}

/* ---------- phone / small ---------- */
@media (max-width:900px){
  .hero{min-height:0;align-items:flex-start;padding:calc(var(--zl-header) + 22px) 0 40px}
  .hero-grid{grid-template-columns:52% minmax(0,1fr);grid-template-rows:auto auto auto;column-gap:18px}
  .hero-copy{grid-column:1 / -1;grid-row:1;max-width:none}
  .hero-copy h1{font-size:clamp(34px,9.4vw,56px)}
  .hero-lead{font-size:16px;line-height:1.5;margin-top:14px}
  .hero-stage{grid-column:1;grid-row:2;height:auto;width:100%;margin-top:18px}
  .hero-chip{left:6px;bottom:6%}
  .buy-head{grid-column:2;grid-row:2;flex-direction:column;align-items:flex-start;align-self:center;gap:14px;margin:18px 0 0;padding:0;border:0}
  .buy-name{font-size:20px}
  .buy-head .site-spec{font-size:10.5px;letter-spacing:.1em}
  .buy-head .site-price{font-size:30px}
  .buy-act{grid-column:1 / -1;grid-row:3;flex-direction:column;align-items:stretch;gap:10px;margin-top:16px;max-width:none}
  .buy-act .site-btn{width:100%}
  .buy-note{text-align:center;max-width:none}
  .wir-grid{grid-template-columns:1fr}
}
@media (max-width:599px){
  .hero{--sky-x:50%;--sky-y:44%;padding-bottom:30px}
  .hero-grid{grid-template-columns:minmax(0,1fr);grid-template-rows:none}
  .hero-copy{display:contents}
  .hero-copy .site-tag{grid-row:1;margin-bottom:12px}
  .hero-copy h1{grid-row:2}
  .hero-stage{grid-column:1;grid-row:3;justify-self:center;width:auto;height:clamp(232px,calc(100svh - 430px),440px);margin-top:4px}  /* min 232: the pick-up note still fits on 360x640 */
  .hero-photo{left:-16%;top:-16%;width:132%;height:132%}  /* phone: the lamp itself fills ~96% of the stage height */
  .hero-chip{left:calc(50% - 50vw + var(--zl-gutter));right:auto;bottom:5%;width:max-content}  /* starts at the page gutter and leans on the base, always inside the screen */
  .buy-head{grid-column:1;grid-row:4;flex-direction:row;align-items:flex-end;justify-content:space-between;align-self:auto;gap:12px;margin:0;padding-top:12px;border-top:1px solid var(--zl-line)}
  .buy-name{font-size:18px;margin-bottom:4px}
  .buy-head .site-price{font-size:28px;line-height:1;white-space:nowrap}
  .buy-act{grid-row:5;margin-top:14px}
  .hero-lead{grid-row:6;margin-top:22px}
}
@media (min-width:600px) and (max-width:900px){.hero-grid{grid-template-columns:44% minmax(0,1fr);column-gap:32px}.buy-act{flex-direction:row;align-items:center}.buy-act .site-btn{width:auto}.buy-note{text-align:left}}
@media (max-width:760px){
  .doors{padding:32px 0 56px}
  .wir{padding:60px 0}
  /* Die Geschichte: the wide bar motif is shown larger around its lifted bottle; the bar fades out at the sides */
  .doors .site-door-art:has(.art-geschichte){overflow:visible;-webkit-mask-image:linear-gradient(90deg,transparent,black 24%,black 76%,transparent);mask-image:linear-gradient(90deg,transparent,black 24%,black 76%,transparent);
    margin:-24px -20px -24px -12px;padding:24px 0}
  .doors .site-doors .site-door-art svg.art-geschichte{width:200%;max-width:none;max-height:none;margin:0 -50%}
  .ghost::before{font-size:34vw}
}

/* ---------- arrival + motion (only with JS and when motion is welcome) ---------- */
.reveal{transition:opacity 1s var(--zl-ease-out),transform 1.1s var(--zl-ease-out)}
.site-doors .reveal:nth-child(2){transition-delay:.1s}
.site-doors .reveal:nth-child(3){transition-delay:.2s}
.kinetic .w{display:inline-block;overflow:hidden;vertical-align:top;padding:0 .04em .14em;margin:0 -.04em -.14em}
.kinetic .wi{display:inline-block}
@media (prefers-reduced-motion:no-preference){
  html.js .kinetic:not(.is-split){opacity:0}
  html.js .kinetic .wi{transform:translateY(108%)}
  html.js .rise{opacity:0;transform:translateY(18px)}
  html.js .lamp-on{opacity:0}
  html.js .lamp-off{opacity:1}
  html.js .hero-halo{opacity:0;transform:translateY(-50%) scale(.6)}
  html.js .reveal{opacity:0;transform:translateY(40px)}
  html.js .reveal.in{opacity:1;transform:none}
  html.js .reveal.in.site-door{transition:opacity 1s var(--zl-ease-out),transform 1.1s var(--zl-ease-out),box-shadow var(--zl-t) var(--zl-ease)}

  html.ready .kinetic .wi{animation:zl-rise 1.05s var(--zl-ease-out) forwards;animation-delay:var(--d,.3s)}
  html.ready .rise{animation:zl-fade-up .9s var(--zl-ease-out) forwards}
  html.ready .rise.r1{animation-delay:.15s}
  html.ready .rise.r2{animation-delay:.85s}
  html.ready .rise.r3{animation-delay:1.15s}
  html.ready .rise.r4{animation-delay:2.1s}
  html.ready .lamp-on{animation:zl-ignite 2.1s linear .45s forwards}
  html.ready .lamp-off{animation:zl-unlit 2.1s linear .45s forwards}
  html.ready .hero-halo{animation:zl-halo 2.4s var(--zl-ease-out) .7s forwards,zl-breathe 6s ease-in-out 3.2s infinite}
}
@keyframes zl-rise{to{transform:none}}
@keyframes zl-fade-up{to{opacity:1;transform:none}}
@keyframes zl-ignite{0%{opacity:0}7%{opacity:.42}11%{opacity:.08}17%{opacity:.6}22%{opacity:.3}34%{opacity:.82}55%{opacity:.95}100%{opacity:1}}
@keyframes zl-unlit{0%,60%{opacity:1}100%{opacity:0}}
@keyframes zl-halo{to{opacity:1;transform:translateY(-50%) scale(1)}}
@keyframes zl-breathe{0%,100%{opacity:1;transform:translateY(-50%) scale(1)}50%{opacity:.82;transform:translateY(-50%) scale(1.04)}}
@media (prefers-reduced-motion:reduce){.fx-light{display:none}.reveal{transition:none}}
