/* ═══════════════════════════════════════════
   ÜBER UNS — Story Edition · Netflix-style
═══════════════════════════════════════════ */

.story { background:#000; color:#fff; }
.story, .story * { font-family:'Inter',-apple-system,BlinkMacSystemFont,sans-serif; }

/* ───────────────────────────────────────
   1 · NETFLIX INTRO (4s overlay)
─────────────────────────────────────── */
.nx-intro {
  position:fixed; inset:0; z-index:9999;
  background:#000;
  display:flex; align-items:center; justify-content:center;
  pointer-events:none;
  animation:nxIntroOut 0.8s ease 4.0s forwards;
}
.nx-intro.dismissed { display:none; }

@keyframes nxIntroOut { to { opacity:0; visibility:hidden; transform:scale(1.04); } }

.nx-logo-wrap {
  position:relative;
  display:flex; flex-direction:column; align-items:center; gap:12px;
  animation:nxLogoZoom 1.1s ease-in 2.9s forwards;
}
@keyframes nxLogoZoom { to { transform:scale(6); opacity:0; } }

/* Logo image (white Cogswell logo) */
.nx-logo-img {
  height:120px; width:auto; max-width:80vw;
  filter:drop-shadow(0 12px 40px rgba(2,132,199,0.55))
         drop-shadow(0 0 60px rgba(6,182,212,0.3));
  opacity:0;
  animation:nxLogoFadeIn 0.9s cubic-bezier(.2,.8,.2,1) 0.2s forwards;
}
@keyframes nxLogoFadeIn {
  0% { opacity:0; transform:scale(0.85); filter:drop-shadow(0 0 0 rgba(2,132,199,0)); }
  100% { opacity:1; transform:scale(1); filter:drop-shadow(0 12px 40px rgba(2,132,199,0.55)) drop-shadow(0 0 60px rgba(6,182,212,0.3)); }
}
@media (max-width:640px){ .nx-logo-img { height:78px; } }

/* Subtle shimmer sweep across logo */
.nx-logo-frame {
  position:relative;
  display:inline-flex;
  align-items:center; justify-content:center;
}
.nx-logo-frame::after {
  content:''; position:absolute; inset:0;
  background:linear-gradient(110deg, transparent 30%, rgba(255,255,255,0.45) 50%, transparent 70%);
  mix-blend-mode:overlay;
  opacity:0;
  animation:nxShimmer 1.6s ease 1.4s forwards;
  pointer-events:none;
  border-radius:8px;
}
@keyframes nxShimmer {
  0%   { opacity:0; transform:translateX(-100%); }
  40%  { opacity:1; }
  100% { opacity:0; transform:translateX(100%); }
}

.nx-tagline {
  position:absolute; left:50%; bottom:-50px; transform:translateX(-50%);
  font-size:13px; color:rgba(255,255,255,0.5);
  letter-spacing:0.3em; text-transform:uppercase;
  white-space:nowrap;
  opacity:0;
  animation:nxFadeIn 0.6s ease 2s forwards;
}
@keyframes nxFadeIn { to { opacity:1; } }

/* Sound-wave bars unter dem Logo */
.nx-wave {
  position:absolute; left:50%; bottom:-110px; transform:translateX(-50%);
  display:flex; gap:4px; align-items:center; height:40px;
  opacity:0; animation:nxFadeIn 0.6s ease 2.2s forwards;
}
.nx-wave .b {
  width:4px; border-radius:2px;
  background:linear-gradient(180deg,#06b6d4,#0284c7);
  animation:nxBars 0.6s ease-in-out infinite alternate;
}
@keyframes nxBars { from { height:6px; } to { height:30px; } }

/* Skip button */
.nx-skip {
  position:fixed; right:24px; bottom:24px; z-index:10000;
  background:rgba(255,255,255,0.08); backdrop-filter:blur(20px);
  border:1px solid rgba(255,255,255,0.18);
  border-radius:100px; padding:8px 18px;
  font-size:12px; color:rgba(255,255,255,0.85); font-weight:500;
  cursor:pointer; pointer-events:auto;
  opacity:0; animation:nxFadeIn 0.4s ease 1s forwards;
}
.nx-skip:hover { background:rgba(255,255,255,0.16); }

/* ───────────────────────────────────────
   COMMON · Chapter scaffolding
─────────────────────────────────────── */
.ch {
  position:relative; min-height:100vh;
  padding:120px clamp(20px,4vw,80px);
  display:flex; flex-direction:column; justify-content:center;
  overflow:hidden;
}
.ch-inner { position:relative; z-index:2; max-width:1280px; margin:0 auto; width:100%; }

.ch-marker {
  display:inline-flex; align-items:center; gap:14px;
  font-size:11px; letter-spacing:0.4em; text-transform:uppercase;
  color:rgba(255,255,255,0.4); font-weight:500;
  margin-bottom:32px;
}
.ch-marker::before {
  content:''; width:48px; height:1px;
  background:linear-gradient(90deg, #06b6d4, transparent);
}
.ch-marker .num {
  color:#06b6d4; letter-spacing:0.4em;
}

.ch-h {
  font-size:clamp(34px,5vw,72px); font-weight:600;
  letter-spacing:-0.022em; line-height:1.05;
  color:#fff; margin:0 0 32px;
}
.ch-h .grad {
  background:linear-gradient(135deg,#0284c7 0%,#06b6d4 50%,#5ef77f 100%);
  background-size:200% 200%; background-clip:text; -webkit-background-clip:text;
  color:transparent; -webkit-text-fill-color:transparent;
  animation:gradMove 7s ease infinite;
}
@keyframes gradMove { 0%,100% { background-position:0% 50%; } 50% { background-position:100% 50%; } }

.ch-p {
  font-size:clamp(16px,1.4vw,21px); line-height:1.6; letter-spacing:-0.005em;
  color:rgba(255,255,255,0.72); max-width:680px; margin:0 0 40px;
}
.ch-p strong { color:#fff; font-weight:500; }
.ch-p em { color:#7dd3fc; font-style:normal; font-weight:500; }

/* Scroll reveal — slower, more cinematic */
.r-cinema { opacity:0; transform:translateY(40px); transition:opacity 1.1s cubic-bezier(.2,.8,.2,1), transform 1.1s cubic-bezier(.2,.8,.2,1); }
.r-cinema.in { opacity:1; transform:none; }
.r-cinema.d1 { transition-delay:0.1s; }
.r-cinema.d2 { transition-delay:0.25s; }
.r-cinema.d3 { transition-delay:0.4s; }
.r-cinema.d4 { transition-delay:0.55s; }
.r-cinema.d5 { transition-delay:0.7s; }

/* ───────────────────────────────────────
   2 · CHAPTER 1 — The Problem (2018)
─────────────────────────────────────── */
.ch-problem {
  background:
    radial-gradient(ellipse 60% 40% at 50% 30%, rgba(2,132,199,0.15), transparent 70%),
    radial-gradient(ellipse 80% 60% at 50% 100%, rgba(0,0,0,1), transparent 50%),
    #050810;
}
.ch-problem::before {
  content:''; position:absolute; inset:0; pointer-events:none;
  background-image:
    linear-gradient(rgba(125,211,252,0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(125,211,252,0.04) 1px, transparent 1px);
  background-size:80px 80px;
  mask-image:radial-gradient(ellipse 70% 50% at 50% 50%, black 30%, transparent 80%);
  -webkit-mask-image:radial-gradient(ellipse 70% 50% at 50% 50%, black 30%, transparent 80%);
}

.year-badge {
  display:inline-flex; align-items:baseline; gap:14px;
  font-size:13px; color:rgba(255,255,255,0.5);
  padding:10px 22px;
  background:rgba(255,255,255,0.03);
  border:1px solid rgba(255,255,255,0.1);
  border-radius:100px; backdrop-filter:blur(20px);
  margin-bottom:32px;
  letter-spacing:0.06em;
}
.year-badge .y {
  font-size:20px; font-weight:600; color:#7dd3fc;
  letter-spacing:0.05em;
  font-variant-numeric:tabular-nums;
}

/* Typewriter sub-line under chapter 1 */
.tw {
  font-size:clamp(15px,1.1vw,17px);
  font-family:'JetBrains Mono', 'SF Mono', Monaco, monospace;
  color:#7dd3fc;
  letter-spacing:0.02em;
}
.tw::after {
  content:'│'; color:#5ef77f;
  animation:twBlink 1s step-end infinite;
  margin-left:4px;
}
@keyframes twBlink { 50% { opacity:0; } }

/* Floating problem cards (chaotic communication) */
.problem-orbit {
  position:absolute; inset:0; pointer-events:none; z-index:1;
}
.po-card {
  position:absolute;
  background:rgba(15,20,30,0.7); backdrop-filter:blur(20px);
  border:1px solid rgba(255,255,255,0.1);
  border-radius:14px; padding:14px 16px;
  display:flex; align-items:center; gap:10px;
  font-size:13px; color:rgba(255,255,255,0.85);
  box-shadow:0 24px 60px rgba(0,0,0,0.6);
  min-width:220px;
  animation:poFloat 8s ease-in-out infinite;
}
.po-card .dot {
  width:8px; height:8px; border-radius:50%; flex-shrink:0;
}
.po-card .dot.red { background:#ef4444; box-shadow:0 0 12px rgba(239,68,68,0.7); }
.po-card .dot.yellow { background:#f59e0b; box-shadow:0 0 12px rgba(245,158,11,0.7); }
.po-card .dot.gray { background:rgba(255,255,255,0.3); }
.po-card .meta { font-size:10px; color:rgba(255,255,255,0.4); margin-left:auto; flex-shrink:0; }
.po-1 { top:14%; right:6%; animation-delay:0s; }
.po-2 { top:30%; left:5%; animation-delay:-2s; }
.po-3 { bottom:22%; right:10%; animation-delay:-4s; }
.po-4 { bottom:14%; left:8%; animation-delay:-1s; }
@keyframes poFloat { 0%,100% { transform:translateY(0) rotate(-1deg); } 50% { transform:translateY(-14px) rotate(1deg); } }
@media (max-width:1100px){ .problem-orbit { display:none; } }

/* ───────────────────────────────────────
   3 · CHAPTER 2 — The Idea
─────────────────────────────────────── */
.ch-idea {
  background:
    radial-gradient(ellipse 70% 60% at 80% 50%, rgba(6,182,212,0.18), transparent 70%),
    radial-gradient(ellipse 50% 40% at 20% 30%, rgba(2,132,199,0.12), transparent 70%),
    #060a14;
}
.idea-grid {
  display:grid; grid-template-columns:1fr 1fr; gap:80px; align-items:center;
}
@media (max-width:980px){ .idea-grid { grid-template-columns:1fr; gap:48px; } }

/* Communication flow visual — animated SVG */
.flow-stage {
  position:relative; aspect-ratio:1/1; max-width:520px;
  display:flex; align-items:center; justify-content:center;
}
.flow-stage svg { width:100%; height:100%; overflow:visible; }
.fs-node {
  fill:#0c1422; stroke:rgba(125,211,252,0.4); stroke-width:1.5;
  filter:drop-shadow(0 8px 24px rgba(2,132,199,0.25));
}
.fs-node.center {
  fill:url(#flowCenterGrad); stroke:#06b6d4; stroke-width:2;
  filter:drop-shadow(0 12px 40px rgba(6,182,212,0.6));
}
.fs-line {
  fill:none; stroke:rgba(125,211,252,0.25); stroke-width:1.5;
  stroke-dasharray:6 4;
}
.fs-pulse {
  fill:none; stroke:#5ef77f; stroke-width:2.5; stroke-linecap:round;
  stroke-dasharray:8 200;
  animation:fsPulse 2.5s linear infinite;
}
@keyframes fsPulse { to { stroke-dashoffset:-208; } }
.fs-label {
  fill:#fff; font-size:11px; font-weight:500;
  text-anchor:middle; font-family:'Inter';
}
.fs-icon { font-size:18px; }

/* ───────────────────────────────────────
   4 · CHAPTER 3 — What we build
─────────────────────────────────────── */
.ch-build {
  background:
    radial-gradient(ellipse 60% 50% at 50% 0%, rgba(94,247,127,0.08), transparent 70%),
    #04070d;
}
.build-stack {
  display:flex; flex-direction:column; gap:22px;
  margin-top:60px;
}
.build-row {
  display:grid; grid-template-columns:80px 1fr 1.4fr; gap:32px; align-items:start;
  padding:32px 0;
  border-top:1px solid rgba(255,255,255,0.06);
  position:relative;
  transition:all 0.4s;
}
.build-row:hover { background:rgba(2,132,199,0.04); padding-left:20px; padding-right:20px; }
.build-row::before {
  content:''; position:absolute; left:0; top:0; height:1px; width:0%;
  background:linear-gradient(90deg, #06b6d4, transparent);
  transition:width 0.6s ease;
}
.build-row.in::before { width:100%; }

.build-num {
  font-size:48px; font-weight:300; letter-spacing:-0.03em;
  color:rgba(125,211,252,0.5);
  font-variant-numeric:tabular-nums;
  line-height:1;
}
.build-title {
  font-size:clamp(20px,1.9vw,28px); font-weight:600; letter-spacing:-0.022em;
  line-height:1.2; color:#fff; margin:0 0 10px;
}
.build-tagline {
  font-size:13px; color:#7dd3fc; letter-spacing:0.04em; text-transform:uppercase;
  margin-bottom:14px; font-weight:500;
}
.build-desc {
  font-size:15px; line-height:1.6; color:rgba(255,255,255,0.65);
}
.build-vis { position:relative; min-height:140px; display:flex; align-items:center; justify-content:flex-end; }
@media (max-width:900px){
  .build-row { grid-template-columns:1fr; gap:14px; padding:24px 0; }
  .build-vis { min-height:120px; justify-content:flex-start; }
}

/* Mini visual blocks */
.mv-chat {
  display:flex; flex-direction:column; gap:8px;
  background:rgba(255,255,255,0.03); border:1px solid rgba(255,255,255,0.08);
  border-radius:14px; padding:16px; max-width:340px; width:100%;
}
.mv-bubble { padding:9px 13px; border-radius:14px; font-size:13px; max-width:88%; line-height:1.4; }
.mv-bubble.them { background:rgba(255,255,255,0.06); align-self:flex-start; border-bottom-left-radius:5px; }
.mv-bubble.me { background:linear-gradient(135deg,#0284c7,#06b6d4); align-self:flex-end; border-bottom-right-radius:5px; color:#fff; }

.mv-voice {
  display:flex; gap:3px; align-items:center; height:60px;
  padding:18px 22px;
  background:rgba(255,255,255,0.03); border:1px solid rgba(255,255,255,0.08);
  border-radius:14px;
  width:100%; max-width:340px;
  position:relative;
}
.mv-voice::before {
  content:'📞'; font-size:18px; margin-right:14px;
}
.mv-voice .bar {
  width:3px; border-radius:2px;
  background:linear-gradient(180deg,#06b6d4,#0284c7);
  animation:vBar 0.8s ease-in-out infinite alternate;
}
@keyframes vBar { from { height:8px; } to { height:34px; } }

.mv-network {
  width:100%; max-width:340px; aspect-ratio:1.6/1;
  position:relative;
  background:rgba(255,255,255,0.03); border:1px solid rgba(255,255,255,0.08);
  border-radius:14px;
  display:flex; align-items:center; justify-content:center;
}
.mv-network svg { width:80%; height:80%; }
.mv-net-node { fill:#0c1422; stroke:rgba(125,211,252,0.5); stroke-width:1.5; }
.mv-net-node.live { fill:url(#netGrad); stroke:#06b6d4; }
.mv-net-line { fill:none; stroke:rgba(125,211,252,0.25); stroke-width:1; stroke-dasharray:4 3; }
.mv-net-pulse { fill:none; stroke:#5ef77f; stroke-width:2; stroke-linecap:round; stroke-dasharray:6 80; animation:fsPulse 2s linear infinite; }

/* ───────────────────────────────────────
   5 · CHAPTER 4 — Industries (constellation)
─────────────────────────────────────── */
.ch-industries {
  background:
    radial-gradient(ellipse 50% 40% at 50% 50%, rgba(2,132,199,0.15), transparent 70%),
    #050810;
  min-height:auto; padding-top:140px; padding-bottom:140px;
}
.constellation {
  position:relative; aspect-ratio:1.6/1; max-width:900px; margin:60px auto 0;
}
.constellation svg { position:absolute; inset:0; width:100%; height:100%; }
.cs-line { fill:none; stroke:rgba(125,211,252,0.18); stroke-width:1; }
.cs-line.active { stroke:#06b6d4; stroke-width:1.5; opacity:0.8; }

.cs-node {
  position:absolute; transform:translate(-50%,-50%);
  display:inline-flex; align-items:center; gap:8px;
  background:rgba(15,20,30,0.85); backdrop-filter:blur(20px);
  border:1px solid rgba(125,211,252,0.25); border-radius:100px;
  padding:9px 16px;
  font-size:13px; color:#fff; font-weight:500;
  white-space:nowrap;
  box-shadow:0 8px 24px rgba(0,0,0,0.4);
  cursor:default;
  transition:all 0.3s;
}
.cs-node:hover {
  border-color:#06b6d4;
  background:rgba(6,182,212,0.15);
  transform:translate(-50%,-50%) scale(1.06);
  box-shadow:0 12px 36px rgba(6,182,212,0.3);
}
.cs-node .ico { font-size:14px; }

.cs-center {
  position:absolute; left:50%; top:50%; transform:translate(-50%,-50%);
  width:140px; height:140px; border-radius:50%;
  background:radial-gradient(circle, rgba(2,132,199,0.4), transparent 70%);
  display:flex; align-items:center; justify-content:center;
  z-index:0;
}
.cs-center::before {
  content:''; position:absolute; width:80px; height:80px; border-radius:50%;
  background:linear-gradient(135deg,#0284c7,#06b6d4);
  box-shadow:0 0 40px rgba(6,182,212,0.6);
  animation:csPulse 2.5s ease-in-out infinite;
}
.cs-center::after {
  content:'C'; position:relative; z-index:2;
  font-size:36px; font-weight:700; color:#fff;
  letter-spacing:-0.04em;
}
@keyframes csPulse { 0%,100% { transform:scale(1); opacity:1; } 50% { transform:scale(1.1); opacity:0.85; } }

@media (max-width:780px){
  .constellation { aspect-ratio:1/1.2; }
  .cs-node { font-size:11px; padding:7px 12px; }
  .cs-center { width:100px; height:100px; }
  .cs-center::before { width:60px; height:60px; }
  .cs-center::after { font-size:28px; }
}

/* ───────────────────────────────────────
   6 · CHAPTER 5 — Anspruch (Pillars)
─────────────────────────────────────── */
.ch-anspruch {
  background:
    radial-gradient(ellipse 80% 60% at 50% 100%, rgba(94,247,127,0.08), transparent 70%),
    #04070d;
}
.pillars {
  display:grid; grid-template-columns:repeat(3,1fr); gap:24px;
  margin-top:60px;
}
@media (max-width:900px){ .pillars { grid-template-columns:1fr; } }
.pillar {
  position:relative; padding:48px 32px;
  background:rgba(255,255,255,0.02);
  border:1px solid rgba(255,255,255,0.08);
  border-radius:24px;
  overflow:hidden;
  display:flex; flex-direction:column; gap:14px;
  transition:all 0.4s;
}
.pillar::before {
  content:''; position:absolute; inset:0; padding:1px;
  background:linear-gradient(135deg, var(--c1), var(--c2));
  border-radius:24px;
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor; mask-composite: exclude;
  opacity:0; transition:opacity 0.4s;
  pointer-events:none;
}
.pillar:hover { transform:translateY(-6px); border-color:transparent; }
.pillar:hover::before { opacity:1; }
.pillar::after {
  content:''; position:absolute; top:-100px; left:50%; transform:translateX(-50%);
  width:300px; height:300px;
  background:radial-gradient(circle, var(--glow), transparent 60%);
  filter:blur(40px); opacity:0; transition:opacity 0.4s;
  pointer-events:none;
}
.pillar:hover::after { opacity:0.4; }
.pillar > * { position:relative; z-index:1; }

.pillar-num {
  font-size:13px; color:rgba(255,255,255,0.5); letter-spacing:0.3em; text-transform:uppercase;
}
.pillar-h {
  font-size:clamp(22px,2.2vw,30px); font-weight:600; letter-spacing:-0.025em;
  color:#fff; line-height:1.1; margin:0;
}
.pillar-p {
  font-size:15px; line-height:1.6; color:rgba(255,255,255,0.65); margin:0;
}
.pillar-icon {
  width:56px; height:56px; border-radius:16px;
  background:linear-gradient(135deg, var(--c1), var(--c2));
  display:flex; align-items:center; justify-content:center;
  font-size:24px; margin-bottom:18px;
  box-shadow:0 12px 32px var(--glow);
}

/* ───────────────────────────────────────
   7 · EPILOG — Heute
─────────────────────────────────────── */
.ch-epilog {
  background:
    radial-gradient(ellipse 70% 60% at 50% 50%, rgba(2,132,199,0.18), transparent 70%),
    #050810;
  text-align:center;
  align-items:center; justify-content:center;
}
.ch-epilog .ch-inner { display:flex; flex-direction:column; align-items:center; gap:24px; }
.ch-epilog .ch-h { max-width:1100px; text-align:center; }
.ch-epilog .ch-p { text-align:center; margin:0 auto 0; }

/* Years counter at end */
.years-row {
  display:flex; gap:48px; flex-wrap:wrap; justify-content:center;
  margin-top:40px; padding:32px 0;
  border-top:1px solid rgba(255,255,255,0.08);
  border-bottom:1px solid rgba(255,255,255,0.08);
  width:100%; max-width:900px;
}
.year-item { display:flex; flex-direction:column; align-items:center; gap:4px; }
.year-num {
  font-size:clamp(28px,3vw,40px); font-weight:600; letter-spacing:-0.025em;
  background:linear-gradient(135deg,#0284c7,#06b6d4 50%,#5ef77f);
  background-clip:text; -webkit-background-clip:text;
  color:transparent; -webkit-text-fill-color:transparent;
  font-variant-numeric:tabular-nums;
}
.year-lbl { font-size:13px; color:rgba(255,255,255,0.55); }

/* Buttons (reuse hero ones) */
.btn-cta {
  display:inline-flex; align-items:center; gap:6px;
  padding:13px 28px; border-radius:980px;
  font-size:14px; font-weight:500; letter-spacing:-0.005em;
  text-decoration:none; transition:all 0.2s; border:1px solid transparent; cursor:pointer;
  color:#fff;
  background:linear-gradient(135deg,#0284c7,#06b6d4 50%,#5ef77f);
  background-size:200% 200%; animation:gradMove 6s ease infinite;
  box-shadow:0 12px 40px rgba(2,132,199,0.4);
}
.btn-cta:hover { transform:translateY(-2px); box-shadow:0 16px 48px rgba(2,132,199,0.55); }
.btn-ghost {
  display:inline-flex; align-items:center; gap:6px;
  padding:13px 28px; border-radius:980px;
  font-size:14px; font-weight:500;
  background:rgba(255,255,255,0.06); color:#fff;
  border:1px solid rgba(255,255,255,0.18); backdrop-filter:blur(20px);
  text-decoration:none; transition:all 0.2s;
}
.btn-ghost:hover { background:rgba(255,255,255,0.12); border-color:rgba(255,255,255,0.32); transform:translateY(-1px); }
