/* ═════════════════════════════════════════════════════════════════════
   Story — Light-Mode Override (shared across all four story components:
   HomeStory, FunktionenStory, DigitalisierungStory, KIStory).
   Loaded AFTER funktionen-story.css. Activates only on html.light.
   Scoped to .story-wrap so dark-mode pages stay unaffected.
   ═════════════════════════════════════════════════════════════════════ */

html.light .story-wrap {
  /* Brand accent in light = Flow Office orange */
  --brand-secondary: #efa23c;
  --brand-secondary-rgb: 239, 162, 60;
  --brand-primary: #798fb6;
  --brand-dark: #080d14;

  /* Override the dark-token forces from funktionen-story.css */
  --foreground: #080d14;
  --background: #faf7f4;
  --card-foreground: #080d14;
  --muted-foreground: rgba(8, 13, 20, 0.62);
  --border: rgba(8, 13, 20, 0.1);
}

/* ───────────────────────────────────────────────────────── */
/* Stage background — bright surface                          */
/* ───────────────────────────────────────────────────────── */
html.light .story-wrap .story-stage {
  background:
    radial-gradient(ellipse at 50% 0%, rgba(121, 143, 182, 0.12) 0%, transparent 55%),
    linear-gradient(180deg, #faf7f4 0%, #f3ece2 50%, #faf7f4 100%);
}

html.light .story-wrap .story-bg-grad {
  background:
    radial-gradient(ellipse at 20% 30%, rgba(239, 162, 60, 0.10) 0%, transparent 40%),
    radial-gradient(ellipse at 85% 70%, rgba(121, 143, 182, 0.14) 0%, transparent 45%);
}

html.light .story-wrap .story-orb {
  opacity: 0.35;
}
html.light .story-wrap .story-orb--a {
  background: radial-gradient(circle, rgba(239, 162, 60, 0.55) 0%, transparent 70%);
}
html.light .story-wrap .story-orb--b {
  background: radial-gradient(circle, rgba(121, 143, 182, 0.55) 0%, transparent 70%);
}
html.light .story-wrap .story-orb--c {
  background: radial-gradient(circle, rgba(196, 144, 255, 0.3) 0%, transparent 70%);
}

html.light .story-wrap .story-grid {
  background-image:
    linear-gradient(rgba(8, 13, 20, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(8, 13, 20, 0.05) 1px, transparent 1px);
}

/* ───────────────────────────────────────────────────────── */
/* HUD                                                        */
/* ───────────────────────────────────────────────────────── */
html.light .story-wrap .story-counter .text-foreground\/30 { color: rgba(8, 13, 20, 0.30); }
html.light .story-wrap .story-counter .text-foreground\/40 { color: rgba(8, 13, 20, 0.40); }
html.light .story-wrap .story-counter .text-foreground\/60 { color: rgba(8, 13, 20, 0.60); }

html.light .story-wrap .story-progress {
  background: rgba(8, 13, 20, 0.10);
}
html.light .story-wrap .story-progress-fill {
  background: var(--brand-secondary);
  box-shadow: 0 0 12px rgba(239, 162, 60, 0.55);
}

/* ───────────────────────────────────────────────────────── */
/* Frame text                                                 */
/* ───────────────────────────────────────────────────────── */
html.light .story-wrap .frame-num   { color: rgba(8, 13, 20, 0.45); }
html.light .story-wrap .frame-pain  {
  color: rgba(8, 13, 20, 0.62);
  border-left-color: var(--brand-secondary);
}
html.light .story-wrap .frame-title { color: #080d14; }
html.light .story-wrap .frame-body  { color: rgba(8, 13, 20, 0.72); }
html.light .story-wrap .frame-bullets li { color: rgba(8, 13, 20, 0.78); }
html.light .story-wrap .frame-bullets li svg { color: var(--brand-secondary); }

html.light .story-wrap .frame-proof {
  background: rgba(239, 162, 60, 0.10);
  border-color: rgba(239, 162, 60, 0.45);
  backdrop-filter: blur(8px);
}
html.light .story-wrap .frame-proof-num   {
  color: #b86b0a;
}
html.light .story-wrap .frame-proof-label {
  color: rgba(8, 13, 20, 0.65);
}

html.light .story-wrap .frame-body strong {
  color: #080d14;
}

/* ───────────────────────────────────────────────────────── */
/* Frame glow colors — tone down for light bg                 */
/* ───────────────────────────────────────────────────────── */
html.light .story-wrap .story-frame[data-state='active'] .frame-glow { opacity: 0.20; }
html.light .story-wrap .frame-glow--blue   { background: radial-gradient(circle, #4c7dff 0%, transparent 70%); }
html.light .story-wrap .frame-glow--violet { background: radial-gradient(circle, #c490ff 0%, transparent 70%); }
html.light .story-wrap .frame-glow--lime   { background: radial-gradient(circle, var(--brand-secondary) 0%, transparent 70%); }
html.light .story-wrap .frame-glow--cyan   { background: radial-gradient(circle, #4ad7ff 0%, transparent 70%); }
html.light .story-wrap .frame-glow--power  { background: radial-gradient(circle, var(--brand-secondary) 0%, transparent 65%); }
html.light .story-wrap .story-frame[data-state='active'] .frame-glow--power { opacity: 0.18; }

/* ───────────────────────────────────────────────────────── */
/* Mockup chrome                                              */
/* ───────────────────────────────────────────────────────── */
html.light .story-wrap .mockup-frame {
  background: linear-gradient(160deg, #ffffff 0%, #faf7f4 100%);
  border-color: rgba(8, 13, 20, 0.10);
  box-shadow:
    0 30px 70px rgba(49, 60, 79, 0.18),
    0 0 0 1px rgba(8, 13, 20, 0.04) inset;
}
html.light .story-wrap .mockup-bar {
  background: rgba(8, 13, 20, 0.04);
  border-bottom-color: rgba(8, 13, 20, 0.06);
}
html.light .story-wrap .mockup-bar i {
  background: rgba(8, 13, 20, 0.12);
}
html.light .story-wrap .mockup-bar i:nth-child(1) { background: #ff5f57; }
html.light .story-wrap .mockup-bar i:nth-child(2) { background: #febc2e; }
html.light .story-wrap .mockup-bar i:nth-child(3) { background: #28c840; }
html.light .story-wrap .mockup-bar span {
  color: rgba(8, 13, 20, 0.48);
}

html.light .story-wrap .mockup-card {
  background: linear-gradient(160deg, #ffffff 0%, #faf7f4 100%);
  border-color: rgba(8, 13, 20, 0.10);
  box-shadow: 0 14px 40px rgba(49, 60, 79, 0.18);
}
html.light .story-wrap .mockup-card-label {
  color: rgba(8, 13, 20, 0.50);
}

/* ── Frame 1: Gantt ─────────────────────────────── */
html.light .story-wrap .gantt::after {
  background: linear-gradient(180deg, transparent 0%, var(--brand-secondary) 25%, var(--brand-secondary) 75%, transparent 100%);
  box-shadow: 0 0 10px var(--brand-secondary);
}
html.light .story-wrap .gantt::before {
  background: linear-gradient(90deg, transparent 0%, rgba(239, 162, 60, 0.10) 45%, rgba(239, 162, 60, 0.18) 50%, rgba(239, 162, 60, 0.10) 55%, transparent 100%);
}
html.light .story-wrap .gantt-row > span {
  color: rgba(8, 13, 20, 0.65);
}

/* Recolour Gantt bars to the orange brand */
html.light .story-wrap .gantt-row:nth-child(1) > b { --c: #efa23c; }
html.light .story-wrap .gantt-row:nth-child(5) > b { --c: #efa23c; }

html.light .story-wrap .load-bars > div {
  color: rgba(8, 13, 20, 0.70);
}
/* Re-tint load bars: keep variety but harmonise greens to orange */
html.light .story-wrap .load-bars > div:nth-child(2) b { --c: #efa23c; }
html.light .story-wrap .load-bars > div:nth-child(3) b { --c: #efa23c; }

html.light .story-wrap .gantt-row:hover {
  background: rgba(239, 162, 60, 0.12);
}
html.light .story-wrap .gantt-row:hover > span {
  color: #b86b0a;
}
html.light .story-wrap .load-bars > div:hover {
  background: rgba(239, 162, 60, 0.14);
}
html.light .story-wrap .load-bars > div:hover i,
html.light .story-wrap .load-bars > div:hover span {
  color: #b86b0a;
}

/* ── Frame 2: Pipeline ──────────────────────────── */
html.light .story-wrap .pipe-col {
  background: rgba(8, 13, 20, 0.025);
  border-color: rgba(8, 13, 20, 0.08);
}
html.light .story-wrap .pipe-col h6 {
  color: rgba(8, 13, 20, 0.50);
}
html.light .story-wrap .pipe-card {
  background: linear-gradient(160deg, #ffffff 0%, #faf7f4 100%);
  border-color: rgba(8, 13, 20, 0.10);
  color: rgba(8, 13, 20, 0.85);
  box-shadow: 0 2px 8px rgba(49, 60, 79, 0.06);
}
html.light .story-wrap .pipe-card em {
  color: var(--brand-primary);
}
html.light .story-wrap .pipe-card--hot {
  border-color: rgba(255, 109, 192, 0.55);
  box-shadow: 0 0 14px rgba(255, 109, 192, 0.18);
}
html.light .story-wrap .pipe-card--won {
  border-color: rgba(239, 162, 60, 0.6);
  box-shadow: 0 0 14px rgba(239, 162, 60, 0.22);
}
html.light .story-wrap .pipe-card--won em {
  color: #b86b0a;
}
html.light .story-wrap .pipe-card--won::before {
  border-color: rgba(239, 162, 60, 0.7);
}
html.light .story-wrap .pipe-card:hover {
  border-color: rgba(239, 162, 60, 0.75);
  box-shadow:
    0 22px 50px rgba(49, 60, 79, 0.22),
    0 0 32px rgba(239, 162, 60, 0.35);
}
html.light .story-wrap .pipe-card--hot:hover {
  border-color: rgba(255, 109, 192, 0.85);
  box-shadow:
    0 22px 50px rgba(49, 60, 79, 0.22),
    0 0 36px rgba(255, 109, 192, 0.5);
}
html.light .story-wrap .pipe-col:hover {
  background: rgba(8, 13, 20, 0.04);
  border-color: rgba(239, 162, 60, 0.35);
}
html.light .story-wrap .pipe-col:hover h6 {
  color: #b86b0a;
}

html.light .story-wrap .mail-row .dot {
  background: var(--brand-secondary);
  box-shadow: 0 0 8px var(--brand-secondary);
}
html.light .story-wrap .mail-row b  { color: rgba(8, 13, 20, 0.92); }
html.light .story-wrap .mail-row em { color: rgba(8, 13, 20, 0.45); }
html.light .story-wrap .mockup-card--mail p {
  color: rgba(8, 13, 20, 0.70);
}

/* ── Frame 3: Chat (Flow AI) ────────────────────── */
html.light .story-wrap .bubble--user {
  background: rgba(239, 162, 60, 0.18);
  border-color: rgba(239, 162, 60, 0.45);
  color: #080d14;
}
html.light .story-wrap .bubble--ai {
  background: rgba(8, 13, 20, 0.04);
  border-color: rgba(8, 13, 20, 0.10);
  color: rgba(8, 13, 20, 0.88);
}
html.light .story-wrap .bubble--typing span {
  background: rgba(8, 13, 20, 0.45);
}
html.light .story-wrap .bubble--user:hover {
  border-color: rgba(239, 162, 60, 0.85);
  background: rgba(239, 162, 60, 0.28);
  box-shadow: 0 16px 36px rgba(239, 162, 60, 0.30);
}
html.light .story-wrap .bubble--ai:not(.bubble--typing):hover {
  border-color: rgba(239, 162, 60, 0.45);
  background: rgba(8, 13, 20, 0.06);
  box-shadow: 0 16px 36px rgba(49, 60, 79, 0.18), 0 0 22px rgba(239, 162, 60, 0.18);
}
html.light .story-wrap .bubble--user {
  animation: digi-user-bubble-glow 3.6s ease-in-out 1.5s infinite;
}
@keyframes digi-user-bubble-glow {
  0%, 100% { box-shadow: 0 0 0 transparent; }
  50%      { box-shadow: 0 0 22px rgba(239, 162, 60, 0.30); }
}

html.light .story-wrap .module-head {
  color: rgba(8, 13, 20, 0.85);
}
html.light .story-wrap .module-head svg {
  color: var(--brand-secondary);
}
html.light .story-wrap .module-bar {
  background: rgba(8, 13, 20, 0.08);
}
html.light .story-wrap .module-bar b {
  background: linear-gradient(90deg, var(--brand-secondary), #ffd28a);
}
html.light .story-wrap .module-bar::after {
  background: linear-gradient(90deg, transparent 0%, rgba(255, 255, 255, 0.7) 50%, transparent 100%);
}
html.light .story-wrap .module-meta {
  color: rgba(8, 13, 20, 0.60);
}
html.light .story-wrap .mockup-card--module:hover .module-bar {
  box-shadow: 0 0 22px rgba(239, 162, 60, 0.55);
}

/* ── Frame 4: Vault ─────────────────────────────── */
html.light .story-wrap .vault-shield {
  background: rgba(239, 162, 60, 0.10);
  border-color: rgba(239, 162, 60, 0.50);
  box-shadow: 0 0 60px rgba(239, 162, 60, 0.30);
}
html.light .story-wrap .vault-shield svg {
  color: var(--brand-secondary) !important;
}
@keyframes digi-vault-breathe {
  0%, 100% { box-shadow: 0 0 60px rgba(239, 162, 60, 0.30); }
  50%      { box-shadow: 0 0 100px rgba(239, 162, 60, 0.55); }
}
html.light .story-wrap .vault-shield {
  animation: digi-vault-breathe 4s ease-in-out infinite;
}
html.light .story-wrap .vault:hover .vault-shield {
  box-shadow: 0 0 140px rgba(239, 162, 60, 0.85), 0 0 60px rgba(239, 162, 60, 0.55);
}
html.light .story-wrap .vault-ring {
  border-color: rgba(239, 162, 60, 0.40);
}

html.light .story-wrap .folder--3 { background: linear-gradient(180deg, var(--brand-secondary), #b86b0a); }
html.light .story-wrap .folder:hover {
  box-shadow: 0 14px 30px rgba(49, 60, 79, 0.22), 0 0 22px rgba(239, 162, 60, 0.40);
}

html.light .story-wrap .badge {
  color: rgba(8, 13, 20, 0.85);
  background: rgba(239, 162, 60, 0.12);
  border-color: rgba(239, 162, 60, 0.35);
}
html.light .story-wrap .badge svg {
  color: var(--brand-secondary);
}
html.light .story-wrap .badge:hover {
  background: rgba(239, 162, 60, 0.30);
  border-color: rgba(239, 162, 60, 0.85);
  box-shadow: 0 10px 22px rgba(239, 162, 60, 0.32);
}

/* ── Frame 5: Stack (Power) ─────────────────────── */
html.light .story-wrap .stack-aura {
  background: radial-gradient(
    ellipse at 50% 50%,
    rgba(239, 162, 60, 0.30) 0%,
    rgba(239, 162, 60, 0.10) 35%,
    transparent 70%
  );
}

html.light .story-wrap .stack-layer {
  background: linear-gradient(160deg, #ffffff 0%, #faf7f4 100%);
  border-color: rgba(8, 13, 20, 0.10);
}
html.light .story-wrap .stack-layer--1 {
  background: linear-gradient(160deg, #ffffff 0%, #f6f1ea 100%);
}
html.light .story-wrap .stack-layer--2 {
  background: linear-gradient(160deg, rgba(121, 143, 182, 0.10) 0%, #faf7f4 100%);
  border-color: rgba(121, 143, 182, 0.35);
}
html.light .story-wrap .stack-layer--3 {
  background: linear-gradient(160deg, rgba(239, 162, 60, 0.10) 0%, #faf7f4 80%);
  border-color: rgba(239, 162, 60, 0.70);
  box-shadow: 0 0 24px rgba(239, 162, 60, 0.20) inset;
}
@keyframes digi-layer-3-pulse {
  0%, 100% { box-shadow: 0 0 30px rgba(239, 162, 60, 0.20) inset, 0 0 0 rgba(239, 162, 60, 0); }
  50%      { box-shadow: 0 0 40px rgba(239, 162, 60, 0.35) inset, 0 0 32px rgba(239, 162, 60, 0.30); }
}
html.light .story-wrap .story-frame[data-idx='5'][data-state='active'] .stack-layer--3 {
  animation:
    layer-3-in 0.95s cubic-bezier(0.22, 1, 0.36, 1) 1.6s backwards,
    digi-layer-3-pulse 3.6s ease-in-out 2.7s infinite;
}

html.light .story-wrap .stack-layer-head {
  color: rgba(8, 13, 20, 0.85);
}
html.light .story-wrap .stack-layer--1 .stack-layer-head svg { color: rgba(8, 13, 20, 0.70); }
html.light .story-wrap .stack-layer--2 .stack-layer-head svg { color: rgba(121, 143, 182, 1); }
html.light .story-wrap .stack-layer--3 .stack-layer-head svg { color: var(--brand-secondary); }
html.light .story-wrap .stack-layer--3 .stack-layer-head     { color: #080d14; }

html.light .story-wrap .stack-tag {
  background: var(--brand-secondary);
  color: #ffffff;
  box-shadow: 0 0 14px rgba(239, 162, 60, 0.55);
}

html.light .story-wrap .stack-bar--2a { background: rgba(121, 143, 182, 0.6); }
html.light .story-wrap .stack-bar--2b { background: rgba(121, 143, 182, 0.4); }
html.light .story-wrap .stack-bar--3a {
  background: linear-gradient(90deg, var(--brand-secondary), rgba(239, 162, 60, 0.50));
  box-shadow: 0 0 12px rgba(239, 162, 60, 0.50);
}
html.light .story-wrap .stack-bar--3b {
  background: linear-gradient(90deg, var(--brand-secondary), rgba(239, 162, 60, 0.30));
  box-shadow: 0 0 10px rgba(239, 162, 60, 0.30);
}
html.light .story-wrap .stack-bar--3a::after {
  background: linear-gradient(90deg, transparent 0%, rgba(255, 255, 255, 0.7) 50%, transparent 100%);
}

html.light .story-wrap .stack-cell {
  background: rgba(8, 13, 20, 0.04);
  border-color: rgba(8, 13, 20, 0.10);
  color: rgba(8, 13, 20, 0.78);
}
@keyframes digi-cell-boot {
  0%   { opacity: 0; transform: scale(0.5) translateY(8px); background: rgba(8, 13, 20, 0.02); border-color: rgba(8, 13, 20, 0.06); color: rgba(8, 13, 20, 0.55); }
  60%  { opacity: 1; transform: scale(1.18); background: rgba(239, 162, 60, 0.28); border-color: rgba(239, 162, 60, 0.7); color: #b86b0a; box-shadow: 0 0 16px rgba(239, 162, 60, 0.5); }
  100% { opacity: 1; transform: scale(1); background: rgba(8, 13, 20, 0.04); border-color: rgba(8, 13, 20, 0.08); color: rgba(8, 13, 20, 0.60); box-shadow: none; }
}
html.light .story-wrap .story-frame[data-idx='5'][data-state='active'] .stack-cell {
  animation: digi-cell-boot 0.5s cubic-bezier(0.22, 1, 0.36, 1) backwards;
}
html.light .story-wrap .stack-cell:hover {
  background: rgba(239, 162, 60, 0.25);
  border-color: rgba(239, 162, 60, 0.85);
  color: #b86b0a;
  box-shadow: 0 0 22px rgba(239, 162, 60, 0.55);
}

html.light .story-wrap .stack-layer:hover {
  border-color: rgba(239, 162, 60, 0.75);
  background: linear-gradient(160deg, rgba(239, 162, 60, 0.10) 0%, rgba(239, 162, 60, 0.02) 100%);
}
html.light .story-wrap .stack-layer:hover .stack-layer-head svg,
html.light .story-wrap .stack-layer:hover .stack-layer-head {
  color: #b86b0a;
}

html.light .story-wrap .stack-beam {
  background: linear-gradient(180deg,
    transparent 0%,
    rgba(239, 162, 60, 0.4) 15%,
    var(--brand-secondary) 50%,
    rgba(239, 162, 60, 0.4) 85%,
    transparent 100%
  );
}
@keyframes digi-stack-beam-pulse {
  0%, 100% { opacity: 0.4; box-shadow: 0 0 6px var(--brand-secondary); }
  50%      { opacity: 0.95; box-shadow: 0 0 18px var(--brand-secondary), 0 0 36px rgba(239, 162, 60, 0.55); }
}
html.light .story-wrap .story-frame[data-idx='5'][data-state='active'] .stack-beam {
  animation:
    stack-beam-in 0.7s cubic-bezier(0.22, 1, 0.36, 1) 2.5s backwards,
    digi-stack-beam-pulse 2.6s ease-in-out 3.3s infinite;
}
html.light .story-wrap .stack-beam-particle {
  background: radial-gradient(circle, var(--brand-secondary) 0%, rgba(239, 162, 60, 0.6) 40%, transparent 70%);
  box-shadow: 0 0 16px var(--brand-secondary);
}

/* Power-Card */
html.light .story-wrap .mockup-card--power {
  border-color: rgba(239, 162, 60, 0.60);
  background: linear-gradient(160deg, rgba(239, 162, 60, 0.10) 0%, #faf7f4 75%);
  box-shadow: 0 20px 50px rgba(49, 60, 79, 0.20), 0 0 26px rgba(239, 162, 60, 0.20);
}
html.light .story-wrap .power-num {
  color: #b86b0a;
  text-shadow: 0 0 22px rgba(239, 162, 60, 0.50);
}
html.light .story-wrap .power-label {
  color: rgba(8, 13, 20, 0.92);
}
html.light .story-wrap .power-pulse {
  border-color: rgba(239, 162, 60, 0.55);
}
html.light .story-wrap .mockup-card--power:hover .power-num {
  text-shadow: 0 0 36px rgba(239, 162, 60, 0.85);
}

/* Infinity card */
html.light .story-wrap .mockup-card--infinity {
  border-color: rgba(239, 162, 60, 0.40);
}
html.light .story-wrap .infinity-icon {
  color: var(--brand-secondary);
  filter: drop-shadow(0 0 8px rgba(239, 162, 60, 0.55));
}
@keyframes digi-infinity-breath {
  0%, 100% { transform: scale(1);   filter: drop-shadow(0 0 8px rgba(239, 162, 60, 0.55)); }
  50%      { transform: scale(1.2); filter: drop-shadow(0 0 22px rgba(239, 162, 60, 0.95)); }
}
html.light .story-wrap .story-frame[data-idx='5'][data-state='active'] .infinity-icon {
  animation: digi-infinity-breath 2.8s ease-in-out 3.4s infinite;
}
html.light .story-wrap .infinity-text   { color: rgba(8, 13, 20, 0.80); }
html.light .story-wrap .infinity-text b { color: #080d14; }
html.light .story-wrap .infinity-text em{ color: rgba(8, 13, 20, 0.55); }
html.light .story-wrap .mockup-card--infinity:hover .infinity-icon {
  filter: drop-shadow(0 0 30px rgba(239, 162, 60, 1));
}

html.light .story-wrap .frame-proof--power {
  background: rgba(239, 162, 60, 0.15);
  border-color: rgba(239, 162, 60, 0.55);
  box-shadow: 0 0 24px rgba(239, 162, 60, 0.18);
}
html.light .story-wrap .frame-proof--power .frame-proof-num {
  text-shadow: 0 0 14px rgba(239, 162, 60, 0.55);
}

html.light .story-wrap .power-rays {
  background:
    conic-gradient(
      from 0deg at 50% 50%,
      transparent 0deg,
      rgba(239, 162, 60, 0.10) 30deg,
      transparent 60deg,
      rgba(239, 162, 60, 0.07) 110deg,
      transparent 140deg,
      rgba(239, 162, 60, 0.09) 200deg,
      transparent 230deg,
      rgba(239, 162, 60, 0.05) 290deg,
      transparent 320deg,
      transparent 360deg
    );
}

/* ───────────────────────────────────────────────────────── */
/* Intro frame (Frame 0)                                      */
/* ───────────────────────────────────────────────────────── */
html.light .story-wrap .intro-ring         { border-color: rgba(239, 162, 60, 0.30); }
html.light .story-wrap .intro-ring--b      { border-color: rgba(121, 143, 182, 0.35); }
html.light .story-wrap .intro-ring--c      { border-color: rgba(239, 162, 60, 0.45); }
html.light .story-wrap .intro-ring::before {
  background: var(--brand-secondary);
  box-shadow: 0 0 14px var(--brand-secondary);
}
html.light .story-wrap .intro-ring--b::before {
  background: var(--brand-primary);
  box-shadow: 0 0 14px var(--brand-primary);
}
html.light .story-wrap .intro-hub {
  background: rgba(239, 162, 60, 0.15);
  box-shadow: 0 0 60px rgba(239, 162, 60, 0.40);
}
html.light .story-wrap .intro-hub svg {
  color: var(--brand-secondary) !important;
}
@keyframes digi-intro-hub-pulse {
  0%, 100% { box-shadow: 0 0 60px rgba(239, 162, 60, 0.40); }
  50%      { box-shadow: 0 0 100px rgba(239, 162, 60, 0.70); }
}
html.light .story-wrap .intro-hub {
  animation: digi-intro-hub-pulse 3s ease-in-out infinite;
}
html.light .story-wrap .intro-mark:hover .intro-hub {
  box-shadow: 0 0 140px rgba(239, 162, 60, 0.85), 0 0 60px rgba(239, 162, 60, 0.55);
}
html.light .story-wrap .intro-mark:hover .intro-ring {
  border-color: rgba(239, 162, 60, 0.55);
}
html.light .story-wrap .intro-rays {
  background: conic-gradient(
    from 0deg at 50% 50%,
    transparent 0deg,
    rgba(239, 162, 60, 0.08) 30deg,
    transparent 60deg,
    rgba(121, 143, 182, 0.08) 90deg,
    transparent 120deg,
    rgba(239, 162, 60, 0.08) 180deg,
    transparent 210deg,
    rgba(121, 143, 182, 0.08) 270deg,
    transparent 300deg
  );
}
html.light .story-wrap .intro-copy .text-foreground\/50 {
  color: rgba(8, 13, 20, 0.55);
}
html.light .story-wrap .intro-copy .text-foreground\/70 {
  color: rgba(8, 13, 20, 0.70);
}
html.light .story-wrap .intro-copy .text-secondary,
html.light .story-wrap .frame-title .text-secondary,
html.light .story-wrap .outro-copy .text-secondary {
  color: var(--brand-secondary);
}

/* ───────────────────────────────────────────────────────── */
/* Outro frame (Frame 6)                                      */
/* ───────────────────────────────────────────────────────── */
html.light .story-wrap .outro-pulse {
  border-color: rgba(239, 162, 60, 0.45);
}
html.light .story-wrap .outro-aura {
  background: radial-gradient(circle, rgba(239, 162, 60, 0.22) 0%, transparent 60%);
}
html.light .story-wrap .outro-mark svg {
  color: var(--brand-secondary) !important;
}
html.light .story-wrap .outro-cta {
  background: var(--brand-secondary);
  color: #ffffff;
  box-shadow: 0 8px 30px rgba(239, 162, 60, 0.40);
}
html.light .story-wrap .outro-cta:hover {
  box-shadow: 0 16px 40px rgba(239, 162, 60, 0.60);
}
html.light .story-wrap .outro-copy .text-foreground\/70 {
  color: rgba(8, 13, 20, 0.70);
}

/* Secondary outro button */
html.light .story-wrap .outro-copy a[href="/kontakt/"] {
  border-color: rgba(8, 13, 20, 0.20);
  color: #080d14;
}
html.light .story-wrap .outro-copy a[href="/kontakt/"]:hover {
  border-color: rgba(8, 13, 20, 0.55);
}

/* ───────────────────────────────────────────────────────── */
/* Skip button                                                */
/* ───────────────────────────────────────────────────────── */
html.light .story-wrap .story-skip {
  border-color: rgba(239, 162, 60, 0.50);
  background: rgba(239, 162, 60, 0.10);
  box-shadow: 0 0 0 0 rgba(239, 162, 60, 0.55), 0 12px 30px rgba(239, 162, 60, 0.18);
}
@keyframes digi-skip-pulse {
  0%   { box-shadow: 0 0 0 0 rgba(239, 162, 60, 0.45), 0 12px 30px rgba(239, 162, 60, 0.18); }
  70%  { box-shadow: 0 0 0 16px rgba(239, 162, 60, 0), 0 12px 30px rgba(239, 162, 60, 0.18); }
  100% { box-shadow: 0 0 0 0 rgba(239, 162, 60, 0), 0 12px 30px rgba(239, 162, 60, 0.18); }
}
html.light .story-wrap .story-skip {
  animation: digi-skip-pulse 2.4s ease-out infinite;
}
html.light .story-wrap .story-skip:hover {
  border-color: var(--brand-secondary);
  background: rgba(239, 162, 60, 0.22);
}
html.light .story-wrap .story-skip-ping {
  border-color: var(--brand-secondary);
}
html.light .story-wrap .story-skip span.text-secondary {
  color: #b86b0a;
}
html.light .story-wrap .story-skip-arrow {
  background: var(--brand-secondary);
  color: #ffffff;
  box-shadow: 0 0 14px rgba(239, 162, 60, 0.55);
}
html.light .story-wrap .story-skip:hover .story-skip-arrow {
  box-shadow: 0 0 22px rgba(239, 162, 60, 0.90);
}
@keyframes digi-bolt-spark {
  0%, 92%, 100% { transform: rotate(0); filter: drop-shadow(0 0 0 transparent); }
  94%           { transform: rotate(-12deg); filter: drop-shadow(0 0 6px var(--brand-secondary)); }
  96%           { transform: rotate(8deg); }
  98%           { transform: rotate(-4deg); }
}
html.light .story-wrap .story-skip-bolt {
  animation: digi-bolt-spark 2.2s ease-in-out infinite;
}

/* ───────────────────────────────────────────────────────── */
/* Hover micro-interactions — overrides for orange accent     */
/* ───────────────────────────────────────────────────────── */
html.light .story-wrap .story-frame[data-state='active'] .mockup-frame:hover {
  box-shadow:
    0 60px 120px rgba(49, 60, 79, 0.30),
    0 0 0 1px rgba(239, 162, 60, 0.35) inset,
    0 0 90px rgba(239, 162, 60, 0.30);
}
html.light .story-wrap .story-frame[data-state='active'] .mockup-card:hover {
  border-color: rgba(239, 162, 60, 0.70);
  box-shadow:
    0 40px 90px rgba(49, 60, 79, 0.25),
    0 0 50px rgba(239, 162, 60, 0.30);
}
html.light .story-wrap .story-frame[data-state='active'] .mockup:hover .mockup-card {
  border-color: rgba(239, 162, 60, 0.55);
  box-shadow:
    0 35px 80px rgba(49, 60, 79, 0.22),
    0 0 40px rgba(239, 162, 60, 0.28);
}
html.light .story-wrap .story-frame[data-state='active'] .mockup:hover .mockup-card:hover {
  border-color: rgba(239, 162, 60, 0.85);
  box-shadow:
    0 45px 100px rgba(49, 60, 79, 0.28),
    0 0 65px rgba(239, 162, 60, 0.50);
}
html.light .story-wrap .story-frame[data-state='active'] .mockup:hover .mockup-frame {
  box-shadow:
    0 70px 140px rgba(49, 60, 79, 0.30),
    0 0 0 1px rgba(239, 162, 60, 0.45) inset,
    0 0 110px rgba(239, 162, 60, 0.40);
}
html.light .story-wrap .mockup::before,
html.light .story-wrap .intro-mark::before,
html.light .story-wrap .outro-mark::before {
  background: radial-gradient(
    ellipse at 50% 50%,
    rgba(239, 162, 60, 0.55) 0%,
    rgba(239, 162, 60, 0.18) 35%,
    transparent 70%
  );
}

/* ═════════════════════════════════════════════════════════════════════
   Frame 3 — TIME + DOC (FunktionenStory · mockup--time)
   ═════════════════════════════════════════════════════════════════════ */
html.light .story-wrap .timer-row {
  background: rgba(239, 162, 60, 0.08);
  border-color: rgba(239, 162, 60, 0.30);
}
html.light .story-wrap .timer-row:hover {
  border-color: rgba(239, 162, 60, 0.75);
  box-shadow: 0 18px 42px rgba(49, 60, 79, 0.20), 0 0 40px rgba(239, 162, 60, 0.30);
}
html.light .story-wrap .timer-pulse {
  background: var(--brand-secondary);
  box-shadow: 0 0 14px var(--brand-secondary);
}
html.light .story-wrap .timer-info p {
  color: rgba(8, 13, 20, 0.60);
}
html.light .story-wrap .timer-clock {
  color: #b86b0a;
}
@keyframes digi-clock-breathe {
  0%, 100% { text-shadow: 0 0 0 transparent; }
  50%      { text-shadow: 0 0 14px rgba(239, 162, 60, 0.55); }
}
html.light .story-wrap .timer-clock {
  animation: digi-clock-breathe 2.6s ease-in-out infinite;
}
html.light .story-wrap .timer-btn {
  border-color: rgba(8, 13, 20, 0.15);
  background: transparent;
  color: rgba(8, 13, 20, 0.85);
}
html.light .story-wrap .timer-btn:hover {
  background: var(--brand-secondary);
  border-color: var(--brand-secondary);
  color: #ffffff;
}
html.light .story-wrap .timer-list > div {
  color: rgba(8, 13, 20, 0.70);
}
html.light .story-wrap .timer-list b {
  background: linear-gradient(90deg, var(--brand-secondary), rgba(239, 162, 60, 0.40));
}
html.light .story-wrap .timer-list em {
  color: rgba(8, 13, 20, 0.55);
}
html.light .story-wrap .timer-list > div:hover {
  background: rgba(239, 162, 60, 0.12);
}
html.light .story-wrap .timer-list > div:hover b {
  box-shadow: 0 0 16px rgba(239, 162, 60, 0.55);
}
html.light .story-wrap .timer-list > div:hover em,
html.light .story-wrap .timer-list > div:hover span {
  color: #b86b0a;
}

html.light .story-wrap .doc-head {
  color: rgba(8, 13, 20, 0.85);
  border-bottom-color: rgba(8, 13, 20, 0.08);
}
html.light .story-wrap .doc-head svg {
  color: var(--brand-secondary);
}
html.light .story-wrap .doc-line {
  background: rgba(8, 13, 20, 0.06);
}
html.light .story-wrap .doc-line--filled {
  background: rgba(239, 162, 60, 0.6);
}
html.light .story-wrap .doc-line--filling::after {
  background: var(--brand-secondary);
}
html.light .story-wrap .doc-badge {
  color: #b86b0a;
  background: rgba(239, 162, 60, 0.10);
  border-color: rgba(239, 162, 60, 0.35);
}

/* ═════════════════════════════════════════════════════════════════════
   KIStory · Frame 1 — VOICE
   ═════════════════════════════════════════════════════════════════════ */
html.light .story-wrap .voice-header {
  border-bottom-color: rgba(8, 13, 20, 0.08);
}
html.light .story-wrap .voice-avatar {
  background: linear-gradient(135deg, #4ad7ff 0%, #2a7eb8 100%);
  color: #ffffff;
  box-shadow: 0 0 18px rgba(74, 215, 255, 0.45);
}
html.light .story-wrap .voice-meta p {
  color: rgba(8, 13, 20, 0.85);
}
html.light .story-wrap .voice-status {
  color: rgba(8, 13, 20, 0.60);
}
html.light .story-wrap .voice-dot {
  background: var(--brand-secondary);
  box-shadow: 0 0 8px var(--brand-secondary);
}
html.light .story-wrap .voice-wave i {
  background: linear-gradient(180deg, #4ad7ff 0%, var(--brand-secondary) 100%);
  box-shadow: 0 0 8px rgba(74, 215, 255, 0.40);
}
html.light .story-wrap .voice-transcript {
  color: rgba(8, 13, 20, 0.72);
  background: rgba(74, 215, 255, 0.08);
  border-color: rgba(74, 215, 255, 0.25);
}

html.light .story-wrap .lang-pills span {
  background: rgba(74, 215, 255, 0.14);
  border-color: rgba(74, 215, 255, 0.35);
  color: rgba(8, 13, 20, 0.85);
}
html.light .story-wrap .lang-pills span:last-child {
  background: rgba(239, 162, 60, 0.16);
  border-color: rgba(239, 162, 60, 0.45);
  color: #b86b0a;
}

html.light .story-wrap .audio-row {
  color: rgba(8, 13, 20, 0.78);
}
html.light .story-wrap .audio-row svg {
  color: var(--brand-secondary);
}
html.light .story-wrap .audio-row b {
  color: rgba(8, 13, 20, 0.92);
}
html.light .story-wrap .audio-row em {
  color: rgba(8, 13, 20, 0.50);
}

/* ═════════════════════════════════════════════════════════════════════
   KIStory · Frame 2 — IMAGEGRID
   ═════════════════════════════════════════════════════════════════════ */
html.light .story-wrap .img-prompt {
  background: rgba(255, 109, 192, 0.06);
  border-color: rgba(255, 109, 192, 0.25);
}
html.light .story-wrap .img-prompt-text {
  color: rgba(8, 13, 20, 0.82);
}
html.light .story-wrap .img-prompt-cat--biz { color: #b86b0a; }
html.light .story-wrap .img-tile {
  border-color: rgba(8, 13, 20, 0.10);
  background-color: #faf7f4;
}
html.light .story-wrap .img-tile::before {
  background: linear-gradient(180deg, transparent 55%, rgba(8, 13, 20, 0.55) 100%);
}
html.light .story-wrap .img-tag {
  background: rgba(255, 255, 255, 0.85);
  color: #b86b0a;
  box-shadow: 0 1px 2px rgba(8, 13, 20, 0.20);
}
html.light .story-wrap .img-progress {
  background: rgba(8, 13, 20, 0.08);
}
html.light .story-wrap .img-progress b {
  background: linear-gradient(90deg, #ff6dc0, var(--brand-secondary));
}

html.light .story-wrap .ab-thumb {
  border-color: rgba(8, 13, 20, 0.12);
}
html.light .story-wrap .ab-thumb--2 {
  background: linear-gradient(135deg, var(--brand-secondary), #4ad7ff);
}

html.light .story-wrap .format-chip {
  background: rgba(255, 109, 192, 0.10);
  border-color: rgba(255, 109, 192, 0.35);
  color: rgba(8, 13, 20, 0.88);
}
html.light .story-wrap .mockup-card--vidformats .format-chip {
  background: rgba(196, 144, 255, 0.12);
  border-color: rgba(196, 144, 255, 0.35);
}

/* "Generated by Flow Office" badge — light surface, orange accent */
html.light .story-wrap .mockup-card--genbadge {
  background:
    linear-gradient(135deg, rgba(239, 162, 60, 0.20) 0%, rgba(239, 162, 60, 0.04) 60%, rgba(255, 255, 255, 0.95) 100%),
    linear-gradient(160deg, #ffffff 0%, #faf7f4 100%);
  border-color: rgba(239, 162, 60, 0.55);
  box-shadow:
    0 12px 30px rgba(49, 60, 79, 0.18),
    0 0 0 1px rgba(239, 162, 60, 0.10),
    0 0 24px rgba(239, 162, 60, 0.22);
}
@keyframes digi-genbadge-glow {
  0%, 100% {
    box-shadow:
      0 12px 30px rgba(49, 60, 79, 0.18),
      0 0 0 1px rgba(239, 162, 60, 0.10),
      0 0 24px rgba(239, 162, 60, 0.22);
  }
  50% {
    box-shadow:
      0 12px 34px rgba(49, 60, 79, 0.22),
      0 0 0 1px rgba(239, 162, 60, 0.18),
      0 0 38px rgba(239, 162, 60, 0.45);
  }
}
html.light .story-wrap .story-frame[data-idx='2'][data-state='active'] .mockup-card--genbadge {
  animation: digi-genbadge-glow 4s ease-in-out infinite;
}
html.light .story-wrap .genbadge-pulse,
html.light .story-wrap .genbadge-pulse::before,
html.light .story-wrap .genbadge-pulse::after {
  background: var(--brand-secondary);
}
html.light .story-wrap .genbadge-pulse {
  box-shadow: 0 0 10px rgba(239, 162, 60, 0.90);
}
html.light .story-wrap .genbadge-icon {
  color: var(--brand-secondary);
  filter: drop-shadow(0 0 6px rgba(239, 162, 60, 0.55));
}
html.light .story-wrap .genbadge-label {
  color: rgba(8, 13, 20, 0.60);
}
html.light .story-wrap .genbadge-brand {
  color: rgba(8, 13, 20, 0.96);
}
html.light .story-wrap .genbadge-shimmer {
  background: linear-gradient(
    100deg,
    transparent 20%,
    rgba(239, 162, 60, 0.28) 45%,
    rgba(255, 255, 255, 0.65) 50%,
    rgba(239, 162, 60, 0.28) 55%,
    transparent 80%
  );
  background-size: 250% 100%;
  background-position: 200% 0;
  mix-blend-mode: normal;
}

/* ═════════════════════════════════════════════════════════════════════
   KIStory · Frame 3 — CHATBOT (mockup--chatbot · models + filedoc)
   ═════════════════════════════════════════════════════════════════════ */
html.light .story-wrap .model-chips span {
  background: rgba(8, 13, 20, 0.04);
  border-color: rgba(8, 13, 20, 0.10);
  color: rgba(8, 13, 20, 0.60);
}
html.light .story-wrap .model-chips span.active {
  background: rgba(239, 162, 60, 0.18);
  border-color: rgba(239, 162, 60, 0.70);
  color: #b86b0a;
  box-shadow: 0 0 12px rgba(239, 162, 60, 0.30);
}

html.light .story-wrap .filedoc-head {
  color: rgba(8, 13, 20, 0.85);
  border-bottom-color: rgba(8, 13, 20, 0.08);
}
html.light .story-wrap .filedoc-head svg {
  color: var(--brand-secondary);
}
html.light .story-wrap .filedoc-line {
  background: rgba(8, 13, 20, 0.06);
}
html.light .story-wrap .filedoc-line--filled {
  background: rgba(239, 162, 60, 0.55);
}
html.light .story-wrap .filedoc-line--filling::after {
  background: var(--brand-secondary);
}
html.light .story-wrap .filedoc-tag {
  color: #b86b0a;
  background: rgba(239, 162, 60, 0.10);
  border-color: rgba(239, 162, 60, 0.35);
}

/* ═════════════════════════════════════════════════════════════════════
   KIStory · Frame 4 — VIDEO (mockup--video)
   ═════════════════════════════════════════════════════════════════════ */
html.light .story-wrap .vid-stage {
  background:
    radial-gradient(ellipse at 40% 35%, rgba(196, 144, 255, 0.45) 0%, transparent 55%),
    radial-gradient(ellipse at 70% 80%, rgba(76, 125, 255, 0.35) 0%, transparent 50%),
    linear-gradient(160deg, #2a2050 0%, #1a1430 100%);
  border-color: rgba(196, 144, 255, 0.30);
}
html.light .story-wrap .vid-grain {
  background-image:
    radial-gradient(rgba(255, 255, 255, 0.06) 1px, transparent 1px);
  mix-blend-mode: overlay;
}
html.light .story-wrap .vid-play {
  background: rgba(255, 255, 255, 0.98);
  color: #2a2050;
}
html.light .story-wrap .vid-cameo {
  background: rgba(255, 255, 255, 0.85);
  border-color: rgba(196, 144, 255, 0.55);
  color: #6e4cb8;
}
html.light .story-wrap .vid-cameo svg { color: #6e4cb8; }
html.light .story-wrap .vid-time {
  color: #ffffff;
  background: rgba(8, 13, 20, 0.65);
}
html.light .story-wrap .vid-key {
  border-color: rgba(8, 13, 20, 0.10);
}
html.light .story-wrap .vid-track {
  background: rgba(8, 13, 20, 0.08);
}
html.light .story-wrap .vid-progress {
  background: linear-gradient(90deg, #c490ff, var(--brand-secondary));
  box-shadow: 0 0 10px rgba(196, 144, 255, 0.6);
}
html.light .story-wrap .mockup-card--prompt .prompt-text {
  color: rgba(8, 13, 20, 0.85);
}

/* ═════════════════════════════════════════════════════════════════════
   KIStory · Frame 5 — UNIFIED (hub stage with 4 module nodes)
   ═════════════════════════════════════════════════════════════════════ */
html.light .story-wrap .hub-aura {
  background: radial-gradient(circle, rgba(239, 162, 60, 0.30) 0%, rgba(239, 162, 60, 0.08) 40%, transparent 70%);
}
html.light .story-wrap .hub-line {
  stroke: rgba(239, 162, 60, 0.55);
}
html.light .story-wrap .hub-center {
  background: linear-gradient(160deg, rgba(239, 162, 60, 0.20) 0%, #ffffff 80%);
  border-color: rgba(239, 162, 60, 0.65);
  color: #b86b0a;
  box-shadow:
    0 0 0 1px rgba(239, 162, 60, 0.15) inset,
    0 0 50px rgba(239, 162, 60, 0.35),
    0 20px 50px rgba(49, 60, 79, 0.22);
}
html.light .story-wrap .hub-center em {
  color: rgba(8, 13, 20, 0.92);
}
@keyframes digi-hub-center-pulse {
  0%, 100% { box-shadow: 0 0 0 1px rgba(239, 162, 60, 0.15) inset, 0 0 40px rgba(239, 162, 60, 0.30), 0 20px 50px rgba(49, 60, 79, 0.22); }
  50%      { box-shadow: 0 0 0 1px rgba(239, 162, 60, 0.30) inset, 0 0 80px rgba(239, 162, 60, 0.55), 0 20px 50px rgba(49, 60, 79, 0.22); }
}
html.light .story-wrap .story-frame[data-idx='5'][data-state='active'] .hub-center {
  animation:
    hub-center-in 0.8s cubic-bezier(0.22, 1, 0.36, 1) 0.3s backwards,
    digi-hub-center-pulse 3.6s ease-in-out 1.4s infinite;
}

html.light .story-wrap .hub-node {
  background: linear-gradient(160deg, #ffffff 0%, #faf7f4 100%);
  border-color: rgba(8, 13, 20, 0.12);
  color: rgba(8, 13, 20, 0.92);
  box-shadow: 0 14px 30px rgba(49, 60, 79, 0.18);
}
html.light .story-wrap .hub-node em {
  color: rgba(8, 13, 20, 0.88);
}
html.light .story-wrap .hub-node--voice  { border-color: rgba(74, 215, 255, 0.45); }
html.light .story-wrap .hub-node--image  { border-color: rgba(255, 109, 192, 0.45); }
html.light .story-wrap .hub-node--chat   { border-color: rgba(239, 162, 60, 0.55); }
html.light .story-wrap .hub-node--chat   svg { color: var(--brand-secondary); }
html.light .story-wrap .hub-node--video  { border-color: rgba(196, 144, 255, 0.50); }
html.light .story-wrap .hub-node:hover {
  box-shadow: 0 20px 40px rgba(49, 60, 79, 0.22), 0 0 30px rgba(239, 162, 60, 0.30);
}
html.light .story-wrap .hub-node--voice:hover  { box-shadow: 0 20px 40px rgba(49, 60, 79, 0.22), 0 0 30px rgba(74, 215, 255, 0.55); }
html.light .story-wrap .hub-node--image:hover  { box-shadow: 0 20px 40px rgba(49, 60, 79, 0.22), 0 0 30px rgba(255, 109, 192, 0.55); }
html.light .story-wrap .hub-node--chat:hover   { box-shadow: 0 20px 40px rgba(49, 60, 79, 0.22), 0 0 30px rgba(239, 162, 60, 0.60); }
html.light .story-wrap .hub-node--video:hover  { box-shadow: 0 20px 40px rgba(49, 60, 79, 0.22), 0 0 30px rgba(196, 144, 255, 0.60); }

html.light .story-wrap .mockup-card--unilogin,
html.light .story-wrap .mockup-card--unidsgvo {
  border-color: rgba(239, 162, 60, 0.40);
}
html.light .story-wrap .mockup-card--unilogin svg,
html.light .story-wrap .mockup-card--unidsgvo svg {
  color: var(--brand-secondary);
  filter: drop-shadow(0 0 8px rgba(239, 162, 60, 0.50));
}
html.light .story-wrap .uni-text b {
  color: rgba(8, 13, 20, 0.98);
}
html.light .story-wrap .uni-text em {
  color: rgba(8, 13, 20, 0.55);
}

/* ───────────────────────────────────────────────────────── */
/* Mobile fallback                                            */
/* ───────────────────────────────────────────────────────── */
html.light .story-mobile-card {
  background: rgba(8, 13, 20, 0.03);
  border-color: rgba(8, 13, 20, 0.08);
  color: rgba(8, 13, 20, 0.78);
}
html.light .story-mobile-card b {
  color: #b86b0a;
}
