/* ================================================
   STARTSEITE: SCROLL-HERO „VOM ATOM ZUM VERMÖGEN“
   Technik wie der IAB-Hero: Bühne sticky, Bildfolge per Thread, nur transform/opacity animiert,
   keine backdrop-filter, keine Vollbild-Masken.
   ================================================ */
.gh {
  --gh-bg: #000714;
  --gh-ink: #ffffff;
  --gh-sub: rgba(255, 255, 255, 0.78);
  --gh-blue: #9cbce6;
  --gh-gold: #d6b878;
  position: relative;
  background: var(--gh-bg);
  color: var(--gh-ink);
}
.gh.gh-js { height: 640vh; }
.gh-stage { position: relative; height: 100vh; height: 100svh; min-height: 560px; overflow: hidden; }
.gh-js .gh-stage { position: sticky; top: 0; }
.gh-bg {
  position: absolute; inset: 0;
  background:
    radial-gradient(ellipse 50% 58% at 66% 50%, #04102a 0%, rgba(4, 16, 42, 0) 72%),
    var(--gh-bg);
}
.gh-host { position: absolute; inset: 0; pointer-events: none; }
.gh-vig {
  position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(to right, rgba(0, 7, 20, 0.86) 0%, rgba(0, 7, 20, 0.62) 28%, rgba(0, 7, 20, 0.18) 46%, rgba(0, 7, 20, 0) 58%);
}

/* Startbild: liegt exakt dort, wo die Bildfolge später liegt (kein Sprung beim Übergang) */
.gh-poster {
  position: absolute; display: block;
  height: 96%; width: auto; max-width: none;
  left: 66%; top: 50%;
  transform: translate(-50%, -50%);
}
.gh-js.gh-ready .gh-poster { visibility: hidden; }

.gh-seqwrap { position: absolute; left: 0; top: 0; width: 1600px; height: 1200px; transform-origin: 0 0; will-change: transform, opacity; }
.gh-seqin { position: absolute; inset: 0; opacity: 0; transition: opacity 0.4s ease; }
.gh-ready .gh-seqin { opacity: 1; }
.gh-seq { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.gh-fx { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.gh-fx.gh-hide { visibility: hidden; }

/* ---------- Akt 1: Titel (Text wie bisher, links) ---------- */
.gh-title {
  position: relative; z-index: 3;
  max-width: var(--grk-container, 1200px); margin: 0 auto;
  padding: 150px var(--grk-gutter, 24px) 60px;
}
/* mit Skript: senkrecht mittig unter der Kopfzeile, blendet beim Scrollen aus */
.gh-js .gh-title {
  position: absolute; left: 0; right: 0; top: 50%; padding: 36px var(--grk-gutter, 24px) 0;
  opacity: calc(1 - var(--gh-to, 0));
  transform: translate3d(0, calc(-50% - var(--gh-to, 0) * 40px), 0);
  will-change: transform, opacity;
}
@media (max-height: 980px) { .gh-js .gh-copy .gh-more { display: none; } .gh-js h1 { margin: 26px 0 22px; } }
@media (max-height: 700px) { .gh-js .gh-trust { display: none; } }
.gh-title-in { max-width: 470px; }
.gh-title[aria-hidden="true"] { visibility: hidden; }
.gh-eyebrow { display: inline-block; font-size: 10px; font-weight: 600; letter-spacing: 0.26em; text-transform: uppercase; color: rgba(255, 255, 255, 0.65); }
.gh h1 { color: #fff; font-size: clamp(40px, 5.6vw, 68px); font-weight: 300; letter-spacing: -0.034em; line-height: 1.09; margin: 40px 0 34px; }
.gh-copy { font-size: 15px; line-height: 1.9; color: var(--gh-sub); margin-bottom: 36px; max-width: 440px; }
.gh-copy p { margin: 0 0 14px; color: var(--gh-sub); font-size: 15px; line-height: 1.85; }
.gh-copy strong { color: #fff; font-weight: 500; }
.gh-copy small { display: block; margin-top: 16px; color: rgba(255, 255, 255, 0.6); font-size: 12px; line-height: 1.7; }
.gh-cta { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 44px; }
.gh-trust { display: flex; flex-wrap: wrap; gap: 14px 30px; padding-top: 26px; border-top: 1px solid rgba(255, 255, 255, 0.08); }
.gh-trust span { display: inline-flex; align-items: center; gap: 10px; color: rgba(255, 255, 255, 0.72); font-size: 12px; letter-spacing: 0.03em; }
.gh-trust i { width: 16px; height: 16px; border-radius: 50%; background: var(--grk-blue-mid, #2f5d9a); display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; }
.gh-trust i::after { content: ''; width: 6px; height: 3px; border-left: 1.6px solid #fff; border-bottom: 1.6px solid #fff; transform: translateY(-1px) rotate(-45deg); }
.gh-js .gh-title-in > * { animation: gh-rise 1s cubic-bezier(0.16, 1, 0.3, 1) both; }
.gh-js .gh-title-in > :nth-child(2) { animation-delay: 0.06s; }
.gh-js .gh-title-in > :nth-child(3) { animation-delay: 0.12s; }
.gh-js .gh-title-in > :nth-child(4) { animation-delay: 0.18s; }
.gh-js .gh-title-in > :nth-child(5) { animation-delay: 0.24s; }
@keyframes gh-rise { from { opacity: 0; transform: translate3d(0, 18px, 0); } to { opacity: 1; transform: none; } }

/* ---------- Akt 2: vier Merkmale ---------- */
.gh-steps {
  position: absolute; z-index: 4;
  left: max(24px, calc((100% - 1200px) / 2 + 24px)); top: 50%;
  width: 360px; transform: translateY(-50%);
  opacity: 0; visibility: hidden;
  transition: opacity 0.35s ease, visibility 0s 0.35s;
}
.gh-steps.on { opacity: 1; visibility: visible; transition: opacity 0.35s ease, visibility 0s; }
.gh-steps-k { font-size: 11px; font-weight: 600; letter-spacing: 0.24em; text-transform: uppercase; color: var(--gh-blue); margin: 0 0 18px; }
.gh-steps ol { list-style: none; margin: 0 0 26px; padding: 0; display: flex; gap: 6px; }
.gh-step { flex: 1; }
.gh-step > button {
  display: block; width: 100%; padding: 10px 0 0; border: 0; border-top: 2px solid rgba(255, 255, 255, 0.14);
  background: none; font: inherit; font-size: 12px; font-weight: 600; letter-spacing: 0.04em; text-align: left;
  color: rgba(255, 255, 255, 0.4); cursor: pointer; transition: color 0.4s ease, border-color 0.4s ease;
}
.gh-step > button:hover { color: rgba(255, 255, 255, 0.75); }
.gh-step.on > button { color: #fff; border-top-color: var(--gh-gold); }
.gh-st-c {
  position: absolute; left: 0; right: 0; top: 112px;
  opacity: 0; transform: translate3d(0, 10px, 0);
  transition: opacity 0.3s ease, transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}
.gh-step.on .gh-st-c { opacity: 1; transform: none; transition-delay: 0.04s; }
.gh-st-c h3 { display: inline-block; font-size: clamp(30px, 2.6vw, 40px); font-weight: 400; letter-spacing: -0.02em; line-height: 1.1; margin: 0 0 14px; color: #fff; }
.gh-st-c p { margin: 0; font-size: 16px; line-height: 1.6; color: var(--gh-sub); max-width: 330px; }
.gh-steps-note { position: absolute; left: 0; top: 268px; margin: 0; font-size: 11px; color: rgba(255, 255, 255, 0.42); }

/* Merkpunkt und Verbindungslinie */
.gh-marker { position: absolute; left: 0; top: 0; width: 0; height: 0; z-index: 5; opacity: 0; transition: opacity 0.4s ease; pointer-events: none; }
.gh-marker.on { opacity: 1; }
.gh-marker i { position: absolute; left: -5px; top: -5px; width: 10px; height: 10px; border-radius: 50%; background: #fff; box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.2), 0 0 14px rgba(255, 230, 180, 0.6); }
.gh-marker i::after { content: ''; position: absolute; inset: -9px; border-radius: 50%; border: 1px solid rgba(255, 255, 255, 0.8); animation: gh-ring 2.4s cubic-bezier(0.16, 1, 0.3, 1) infinite; }
@keyframes gh-ring { 0% { transform: scale(0.6); opacity: 0.9; } 100% { transform: scale(1.8); opacity: 0; } }
.gh-lead { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 5; pointer-events: none; opacity: 0; transition: opacity 0.35s ease; overflow: visible; }
.gh-lead.on { opacity: 1; }
.gh-lead-line { fill: none; stroke: rgba(255, 255, 255, 0.82); stroke-width: 1.2; stroke-dasharray: 1; stroke-dashoffset: 0; }
.gh-lead-halo { fill: none; stroke: rgba(5, 11, 23, 0.5); stroke-width: 4; stroke-dasharray: 1; stroke-dashoffset: 0; }
.gh-lead-dot { fill: #fff; transform-box: fill-box; transform-origin: center; }

/* Periodensystem-Kacheln neben den Barren */
.gh-tiles { position: absolute; inset: 0; z-index: 4; pointer-events: none; opacity: 0; visibility: hidden; transition: opacity 0.35s ease, visibility 0s 0.35s; }
.gh-tiles.on { opacity: 1; visibility: visible; transition: opacity 0.4s ease, visibility 0s; }
.gh-tile {
  position: absolute; left: 0; top: 0; width: 74px; height: 82px; padding: 7px 9px;
  background: rgba(10, 22, 42, 0.72); border: 1px solid rgba(255, 255, 255, 0.28);
  font-variant-numeric: tabular-nums; will-change: transform;
}
.gh-tile b { display: block; font-size: 11px; font-weight: 500; color: rgba(255, 255, 255, 0.75); }
.gh-tile strong { display: block; font-size: 30px; line-height: 1.05; font-weight: 500; color: #fff; margin-top: 2px; }
.gh-tile span { display: block; font-size: 11px; color: rgba(255, 255, 255, 0.8); margin-top: 3px; }
.gh-tile:first-child { border-color: rgba(214, 184, 120, 0.7); }
.gh-tiles.on .gh-tile { animation: gh-tile 0.7s cubic-bezier(0.16, 1, 0.3, 1) both; }
.gh-tiles.on .gh-tile:nth-child(2) { animation-delay: 0.06s; }
.gh-tiles.on .gh-tile:nth-child(3) { animation-delay: 0.12s; }
.gh-tiles.on .gh-tile:nth-child(4) { animation-delay: 0.18s; }
.gh-tiles.on .gh-tile:nth-child(5) { animation-delay: 0.24s; }
@keyframes gh-tile { from { opacity: 0; } to { opacity: 1; } }

/* ---------- Akt 3: Karte ---------- */
.gh-map, .gh-hubbox, .gh-pulsecv { position: absolute; pointer-events: none; }
.gh-map { overflow: hidden; opacity: 0; transition: opacity 0.8s ease 0.1s; }
.gh-map.on { opacity: 1; }
.gh-land { fill: rgba(156, 188, 230, 0.03); stroke: rgba(156, 188, 230, 0.34); stroke-width: 0.9; vector-effect: non-scaling-stroke; stroke-linejoin: round; stroke-dasharray: 1; stroke-dashoffset: 1; transition: stroke-dashoffset 1.8s cubic-bezier(0.4, 0, 0.2, 1) 0.1s; }
.gh-map.on .gh-land { stroke-dashoffset: 0; }
.gh-prer .gh-map:not(.on), .gh-prer .gh-hubbox:not(.on) { opacity: 0.002; }
.gh-hub { position: absolute; width: 0; height: 0; opacity: 0; transition: opacity 0.5s ease; will-change: opacity; }
.gh-hubbox.on .gh-hub { opacity: 1; }
.gh-hubbox:not(.on) .gh-hub { transition-delay: 0s !important; }
.gh-dot { position: absolute; left: -5px; top: -5px; width: 10px; height: 10px; border-radius: 50%; background: #ffe2b0; box-shadow: 0 0 10px 2px rgba(255, 196, 120, 0.7); }
.gh-halo { position: absolute; left: -16px; top: -16px; width: 32px; height: 32px; border-radius: 50%; border: 1px solid rgba(255, 214, 160, 0.55); animation: gh-ring 3s ease-out infinite; }
.gh-lbl { position: absolute; left: 14px; top: -9px; white-space: nowrap; font-size: 14px; font-weight: 500; letter-spacing: 0.01em; color: #fff; text-shadow: 0 1px 8px rgba(0, 0, 0, 0.8); }
.gh-pulsecv { opacity: 0; transition: opacity 0.5s ease 0.7s; }
.gh-pulsecv.on { opacity: 1; }
.gh-legend { position: absolute; display: flex; gap: 18px; font-size: 12px; color: rgba(255, 255, 255, 0.72); opacity: 0; transition: opacity 0.5s ease 1s; pointer-events: none; }
.gh-legend.on { opacity: 1; }
.gh-legend span { display: inline-flex; align-items: center; gap: 7px; }
.gh-legend b { width: 8px; height: 8px; border-radius: 50%; }
.gh-lg-hub { background: #ffe2b0; box-shadow: 0 0 8px rgba(255, 196, 120, 0.8); }
.gh-lg-dst { background: transparent; border: 1px solid #ffdcae; }

.gh-mapvig { position: absolute; pointer-events: none; opacity: 0; transition: opacity 0.6s ease;
  background:
    linear-gradient(to right, var(--gh-bg) 0%, rgba(0, 7, 20, 0) 14%, rgba(0, 7, 20, 0) 86%, var(--gh-bg) 100%),
    linear-gradient(to bottom, var(--gh-bg) 0%, rgba(0, 7, 20, 0) 12%, rgba(0, 7, 20, 0) 84%, var(--gh-bg) 100%); }
.gh-mapvig.on { opacity: 1; }
.gh-prer .gh-mapvig:not(.on) { opacity: 0.002; }

/* Schlusstext */
.gh-finale {
  position: absolute; z-index: 4;
  left: max(24px, calc((100% - 1200px) / 2 + 24px)); top: 50%;
  width: 380px; transform: translate3d(0, -46%, 0);
  opacity: 0; visibility: hidden;
  transition: opacity 0.5s ease, transform 0.7s cubic-bezier(0.16, 1, 0.3, 1), visibility 0s 0.5s;
}
.gh-final .gh-finale { opacity: 1; visibility: visible; transform: translate3d(0, -50%, 0); transition: opacity 0.6s ease 0.15s, transform 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.15s, visibility 0s; }
.gh-fin-k { display: block; font-size: 11px; font-weight: 600; letter-spacing: 0.24em; text-transform: uppercase; color: var(--gh-blue); margin-bottom: 16px; }
.gh-finale h2 { font-size: clamp(32px, 3vw, 46px); font-weight: 300; letter-spacing: -0.03em; line-height: 1.1; margin: 0 0 18px; color: #fff; }
.gh-finale p { font-size: 16px; line-height: 1.65; color: var(--gh-sub); margin: 0 0 26px; }
.gh-finale .gh-cta { margin-bottom: 18px; }
.gh-fin-note { font-size: 11px !important; color: rgba(255, 255, 255, 0.45) !important; margin: 0 !important; }

/* Scrollhinweis */
.gh-hint { position: absolute; z-index: 3; left: 50%; bottom: 26px; width: 22px; height: 34px; margin-left: -11px; border: 1.5px solid rgba(255, 255, 255, 0.4); border-radius: 12px; opacity: calc(1 - var(--gh-to, 0)); pointer-events: none; display: none; }
.gh-js .gh-hint { display: block; }
@media (max-width: 640px) { .gh-js .gh-hint { display: none; } }
.gh-hint i { position: absolute; left: 50%; top: 7px; width: 3px; height: 7px; margin-left: -1.5px; border-radius: 2px; background: #fff; animation: gh-hint 1.8s ease-in-out infinite; }
@keyframes gh-hint { 0% { transform: translateY(0); opacity: 1; } 70% { transform: translateY(10px); opacity: 0; } 100% { opacity: 0; } }

/* ---------- Handy ---------- */
.gh[data-set="m"] .gh-vig { background: linear-gradient(to bottom, rgba(5, 11, 23, 0) 30%, rgba(5, 11, 23, 0.7) 62%, rgba(5, 11, 23, 0.92) 100%); }
.gh[data-set="m"] .gh-title { padding-top: 0; position: absolute; left: 0; right: 0; top: auto; bottom: 0; transform: translate3d(0, calc(var(--gh-to, 0) * -30px), 0); }
.gh[data-set="m"] .gh-title-in { max-width: none; }
.gh[data-set="m"] h1 { margin: 16px 0 14px; font-size: 40px; }
.gh[data-set="m"] .gh-copy { font-size: 14px; line-height: 1.7; margin-bottom: 20px; }
.gh[data-set="m"] .gh-copy .gh-more { display: none; }
.gh[data-set="m"] .gh-trust { display: none; }
.gh[data-set="m"] .gh-cta { margin-bottom: 26px; }
.gh[data-set="m"] .gh-steps { left: 20px; right: 20px; width: auto; top: auto; bottom: 22px; transform: none; min-height: 210px; }
.gh[data-set="m"] .gh-steps ol { margin-bottom: 14px; }
.gh[data-set="m"] .gh-st-c { top: 74px; }
.gh[data-set="m"] .gh-st-c h3 { font-size: 28px; margin-bottom: 8px; }
.gh[data-set="m"] .gh-st-c p { font-size: 15px; }
.gh[data-set="m"] .gh-steps-note { display: none; }
.gh[data-set="m"] .gh-tiles { inset: auto 12px 268px 12px; display: flex; justify-content: center; gap: 6px; }
.gh[data-set="m"] .gh-tile { position: relative; width: 58px; height: 66px; padding: 5px 6px; transform: none !important; }
.gh[data-set="m"] .gh-tile strong { font-size: 22px; }
.gh[data-set="m"] .gh-tile span { font-size: 9.5px; }
.gh[data-set="m"] .gh-finale { left: 20px; right: 20px; width: auto; top: auto; bottom: 24px; transform: translate3d(0, 12px, 0); }
.gh-final[data-set="m"] .gh-finale { transform: none; }
.gh[data-set="m"] .gh-finale h2 { font-size: 30px; }
.gh[data-set="m"] .gh-finale p { font-size: 14.5px; margin-bottom: 18px; }
.gh[data-set="m"] .gh-legend { font-size: 11px; }
.gh[data-set="m"] .gh-lbl { font-size: 12px; }
@media (max-width: 999px) {
  .gh:not(.gh-js) .gh-poster { left: 50%; top: 34%; height: auto; width: max(130vw, 83svh); }
}

/* ---------- Ruhige Fassung (reduzierte Bewegung, ohne Skript, Vorschau-Renderer) ---------- */
.gh:not(.gh-js) .gh-stage { height: auto; min-height: 100vh; }
.gh:not(.gh-js) .gh-steps, .gh:not(.gh-js) .gh-finale, .gh:not(.gh-js) .gh-tiles {
  position: relative; left: auto; top: auto; right: auto; bottom: auto; width: auto; transform: none;
  opacity: 1; visibility: visible; z-index: 3;
  max-width: var(--grk-container, 1200px); margin: 0 auto; padding: 0 var(--grk-gutter, 24px);
}
.gh:not(.gh-js) .gh-steps ol { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 28px; }
.gh:not(.gh-js) .gh-st-c { position: static; opacity: 1; transform: none; margin-top: 14px; }
.gh:not(.gh-js) .gh-st-c h3 { font-size: 26px; }
.gh:not(.gh-js) .gh-steps-note { position: static; margin-top: 18px; }
.gh:not(.gh-js) .gh-tiles { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 30px; margin-bottom: 30px; }
.gh:not(.gh-js) .gh-tile { position: relative; transform: none; }
.gh:not(.gh-js) .gh-finale { padding-bottom: 90px; max-width: 760px; margin-left: max(0px, calc((100% - 1200px) / 2)); }
.gh:not(.gh-js) .gh-hint { display: none; }
.gh:not(.gh-js) .gh-poster { height: 100vh; top: 50vh; }

/* Startseite: das Sicherheitsnetz gegen waagerechtes Scrollen (colors_and_type.css, html/body overflow-x: hidden
   bis 900 px) macht den Body zum Scroll-Container, dann bleibt die Hero-Bühne nicht stehen (sticky).
   overflow-x: clip schneidet genauso ab, ohne Scroll-Container. Browser ohne clip bekommen die ruhige Fassung. */
@supports (overflow-x: clip) {
  @media (max-width: 900px) { html, body { overflow-x: clip; } }
}
