/* ============================================================
   edwinvonlemberg.com — Erlebnis-Bausteine (assets/js/erlebnis.js).
   Baut auf den Markenvariablen aus style.css auf.
   ============================================================ */

/* Gemeinsames: Koi, Umschalter, Regler */
.koi-svg { display: block; width: 100%; height: auto; overflow: visible; }
.koi-svg .koi-schwanz { transform-box: fill-box; transform-origin: 50% 0; animation: koiSchwanz .9s ease-in-out infinite alternate; }
.koi-svg .koi-flosse { transform-box: fill-box; transform-origin: 50% 0; animation: koiSchwanz 1.3s ease-in-out infinite alternate-reverse; }
@keyframes koiSchwanz { from { rotate: -14deg; } to { rotate: 14deg; } }

.umschalter { display: inline-flex; flex-wrap: wrap; gap: 4px; padding: 4px; border-radius: 999px; border: 1px solid var(--border); background: rgba(5, 14, 18, .6); }
.umschalter button { all: unset; box-sizing: border-box; cursor: var(--zeiger); padding: 8px 16px; border-radius: 999px; font-size: .92rem; font-weight: 600; color: #c9d4d9; transition: color .25s, background-color .25s; }
.umschalter button:hover { color: var(--white); }
.umschalter button[aria-pressed="true"] { background: var(--verlauf); color: var(--primary); }
.umschalter button:focus-visible { outline: 2px solid var(--active); outline-offset: 2px; }

.regler { -webkit-appearance: none; appearance: none; width: 100%; height: 28px; background: transparent; cursor: var(--zeiger); margin: 0; }
.regler::-webkit-slider-runnable-track { height: 6px; border-radius: 6px; background: linear-gradient(90deg, var(--secondary), var(--active)) 0 / var(--f, 50%) 100% no-repeat, var(--border); }
.regler::-moz-range-track { height: 6px; border-radius: 6px; background: var(--border); }
.regler::-moz-range-progress { height: 6px; border-radius: 6px; background: var(--verlauf); }
.regler::-webkit-slider-thumb { -webkit-appearance: none; width: 24px; height: 24px; margin-top: -9px; border-radius: 50%; background: var(--white); border: 0; box-shadow: 0 0 0 5px rgba(113, 223, 233, .22), 0 4px 14px rgba(0, 0, 0, .5); transition: box-shadow .2s; }
.regler::-moz-range-thumb { width: 24px; height: 24px; border-radius: 50%; background: var(--white); border: 0; box-shadow: 0 0 0 5px rgba(113, 223, 233, .22); }
.regler:hover::-webkit-slider-thumb, .regler:focus-visible::-webkit-slider-thumb { box-shadow: 0 0 0 9px rgba(113, 223, 233, .28), 0 4px 14px rgba(0, 0, 0, .5); }
.regler:focus-visible { outline: none; }
.klein-hinweis { font-size: .82rem; color: var(--grey); margin: 14px 0 0; }

/* ---------- 1 · Hero: Tempo-Bahnen und Tiefe ---------- */
.hero { overflow: clip; }
.tempo-bahnen { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 0; pointer-events: none; opacity: 0; animation: bahnenEin 1.6s 1.2s ease-out forwards; }
@keyframes bahnenEin { to { opacity: 1; } }
.tempo-legende { grid-column: 1 / -1; display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; margin: clamp(8px, 2vw, 24px) 0 0; padding: 18px 0 0; border-top: 1px solid var(--border); list-style: none; animation: einAuf .8s 1.5s cubic-bezier(.2, .7, .2, 1) backwards; }
.tempo-legende .tl-titel { font-size: .8rem; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--grey); margin-right: 6px; }
.tempo-legende button { all: unset; box-sizing: border-box; cursor: var(--zeiger); display: inline-flex; align-items: center; gap: 10px; padding: 7px 14px 7px 12px; border-radius: 999px; border: 1px solid var(--border); background: rgba(11, 29, 41, .6); font-size: .9rem; color: #c9d4d9; transition: border-color .25s, color .25s, background-color .25s; }
.tempo-legende button::before { content: ''; width: 9px; height: 9px; border-radius: 50%; background: var(--tl); box-shadow: 0 0 12px var(--tl); }
.tempo-legende button:hover, .tempo-legende button[aria-pressed="true"] { border-color: var(--tl); color: var(--white); background: rgba(11, 29, 41, .9); }
.tempo-legende button:focus-visible { outline: 2px solid var(--active); outline-offset: 2px; }
.tempo-legende .tl-text { flex-basis: 100%; margin: 2px 0 0; min-height: 1.6em; font-size: .95rem; color: #c9d4d9; }
@media (hover: hover) and (pointer: fine) {
  .hero-ring { translate: calc(var(--px, 0) * -26px) calc(var(--py, 0) * -18px); }
  .hero-photo { translate: calc(var(--px, 0) * -9px) calc(var(--py, 0) * -6px); }
  .hero-phone { translate: calc(var(--px, 0) * 20px) calc(var(--py, 0) * 14px); }
  .hero-badge { translate: calc(var(--px, 0) * 32px) calc(var(--py, 0) * 20px); }
}

/* ---------- 2 · Problem: antippen, was du kennst ---------- */
.pains-liste { display: grid; gap: 10px; }
.pains-hinweis { margin: 0 0 4px; font-size: .82rem; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--grey); }
.pain { all: unset; box-sizing: border-box; cursor: var(--zeiger); display: grid; grid-template-columns: auto 1fr; gap: 2px 14px; align-items: center; padding: 14px 18px; border-radius: 10px; border: 1px solid rgba(255, 255, 255, .08); background: rgba(11, 29, 41, .5); transition: border-color .25s, background-color .25s, translate .25s cubic-bezier(.2, .7, .2, 1); }
.pain:hover { border-color: rgba(138, 92, 253, .5); translate: 4px 0; }
.pain:focus-visible { outline: 2px solid var(--active); outline-offset: 2px; }
.pain-haken { grid-row: span 2; width: 24px; height: 24px; border-radius: 50%; border: 1.5px solid var(--primary-dark); display: grid; place-items: center; transition: background .25s, border-color .25s, scale .3s cubic-bezier(.3, 1.6, .5, 1); }
.pain-haken svg { width: 13px; height: 13px; stroke: var(--primary); opacity: 0; transition: opacity .2s; }
.pain-zitat { font-weight: 600; font-size: 1.05rem; line-height: 1.35; color: var(--white); }
.pain-sub { font-size: .9rem; color: var(--grey); line-height: 1.4; }
.pain[aria-pressed="true"] { border-color: rgba(113, 223, 233, .45); background: linear-gradient(160deg, rgba(138, 92, 253, .16), rgba(113, 223, 233, .1)); }
.pain[aria-pressed="true"] .pain-haken { background: var(--verlauf); border-color: transparent; scale: 1.08; }
.pain[aria-pressed="true"] .pain-haken svg { opacity: 1; }
.pain.zeigt { border-color: var(--active); }
@keyframes painWechsel { from { opacity: 0; translate: 0 12px; filter: blur(4px); } }
/* ---------- 3 · Die Woche zwischen zwei Stunden ---------- */
.woche { display: grid; grid-template-columns: 1.35fr 1fr; gap: clamp(18px, 3vw, 40px); align-items: center; }
.woche-bild { padding: clamp(14px, 2vw, 24px); border-radius: 12px; border: 1px solid var(--border); background: rgba(11, 29, 41, .55); min-width: 0; }
.woche-bild svg { display: block; width: 100%; height: auto; overflow: visible; }
.woche-bild .achse { stroke: var(--border); stroke-width: 1; }
.woche-bild text { fill: var(--grey); font-size: 13px; font-family: inherit; }
.woche-bild text.jetzt { fill: var(--white); font-weight: 700; }
.woche-bild .k-ohne { fill: none; stroke: #7d8a90; stroke-width: 2.5; stroke-dasharray: 6 6; }
.woche-bild .k-mit { fill: none; stroke: url(#woche-v); stroke-width: 3.5; stroke-linecap: round; stroke-linejoin: round; }
.woche-bild .k-flaeche { fill: url(#woche-f); }
.woche-bild .zeiger { stroke: var(--white); stroke-width: 1; stroke-opacity: .35; }
.woche-bild .p-ohne { fill: #7d8a90; stroke: var(--primary); stroke-width: 3; }
.woche-bild .p-mit { fill: var(--active); stroke: var(--primary); stroke-width: 3; }
.woche-bild .einheit { fill: var(--secondary-light); opacity: .25; transition: opacity .3s; }
.woche-bild .einheit.war { opacity: 1; }
.woche-regler { margin-top: 10px; }
.woche-seite h3 { font-size: clamp(1.3rem, 2.2vw, 1.6rem); min-height: 1.2em; }
.woche-seite .woche-text { color: #c9d4d9; min-height: 5em; }
.woche-balken { display: grid; gap: 16px; margin-top: 20px; }
.woche-balken div { font-size: .9rem; color: var(--grey); }
.woche-balken i { display: block; height: 10px; margin-top: 7px; border-radius: 10px; background: var(--border); overflow: hidden; }
.woche-balken i::before { content: ''; display: block; height: 100%; width: calc(var(--w) * 100%); border-radius: 10px; background: #7d8a90; }
.woche-balken .mit { color: var(--white); }
.woche-balken .mit i::before { background: var(--verlauf); box-shadow: 0 0 14px rgba(113, 223, 233, .5); }
.woche-knopf { margin-top: 24px; }
@media (max-width: 860px) { .woche { grid-template-columns: 1fr; } .woche-seite .woche-text { min-height: 0; } }

/* ---------- 4 · Mini-Lektion zum Ausprobieren ---------- */
.demo { display: grid; grid-template-columns: 1fr auto; gap: clamp(28px, 6vw, 80px); align-items: center; }
.demo-merker { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.demo-merker li { display: grid; grid-template-columns: auto 1fr; gap: 4px 16px; padding: 16px 20px; border-radius: 10px; border: 1px solid var(--border); background: rgba(11, 29, 41, .45); opacity: .55; transition: opacity .4s, border-color .4s, background .4s; }
.demo-merker li::before { content: ''; grid-row: span 2; align-self: center; width: 12px; height: 12px; border-radius: 50%; border: 2px solid var(--primary-dark); transition: background .3s, border-color .3s, box-shadow .3s; }
.demo-merker strong { color: var(--white); }
.demo-merker span { color: #c9d4d9; font-size: .95rem; }
.demo-merker li.an { opacity: 1; border-color: rgba(113, 223, 233, .4); background: linear-gradient(160deg, rgba(138, 92, 253, .14), rgba(113, 223, 233, .08)); }
.demo-merker li.an::before { background: var(--active); border-color: var(--active); box-shadow: 0 0 14px var(--active); }
.demo-merker li.puls { animation: merkerPuls .8s cubic-bezier(.3, 1.4, .5, 1); }
@keyframes merkerPuls { 30% { scale: 1.03; } }
.demo-phone { width: min(320px, 82vw); justify-self: center; }
.demo-phone::before { z-index: 3; }
.app { --m1: var(--secondary); --m2: var(--active); position: relative; aspect-ratio: 9 / 18.4; border-radius: 28px; overflow: hidden; display: flex; flex-direction: column; background: radial-gradient(120% 60% at 50% 0, color-mix(in srgb, var(--m1) 34%, transparent), transparent 70%), #0a1218; font-size: 15px; line-height: 1.45; }
.app-kopf { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 38px 16px 10px; font-weight: 700; }
.app-name { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.app-xp { flex: none; font-size: .8rem; padding: 3px 10px; border-radius: 999px; background: rgba(255, 255, 255, .1); font-variant-numeric: tabular-nums; }
.app-xp.plus { animation: xpPlus .6s cubic-bezier(.3, 1.6, .5, 1); }
@keyframes xpPlus { 40% { scale: 1.25; background: var(--m2); color: #06121a; } }
.app-bahn { position: relative; height: 8px; margin: 6px 26px 0 16px; border-radius: 8px; background: rgba(255, 255, 255, .1); }
.app-bahn i { position: absolute; inset: 0 auto 0 0; width: calc(var(--p, 0) * 100%); border-radius: 8px; background: linear-gradient(90deg, var(--m1), var(--m2)); transition: width .7s cubic-bezier(.2, .7, .2, 1); }
.app-bahn .app-koi { position: absolute; top: 50%; left: calc(var(--p, 0) * 100%); width: 18px; translate: -50% -50%; rotate: 90deg; transition: left .7s cubic-bezier(.2, .7, .2, 1); filter: drop-shadow(0 2px 6px rgba(0, 0, 0, .5)); }
.app-inhalt { flex: 1; display: flex; flex-direction: column; padding: 22px 16px 16px; min-height: 0; }
.app-nr { font-size: .72rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--m2); margin-bottom: 8px; }
.app-frage { color: #b9c6cc; font-size: .9rem; margin: 0 0 8px; }
.app-satz { font-size: 1.3rem; font-weight: 700; line-height: 1.3; margin: 0 0 20px; min-height: 2.6em; }
.app-satz u { text-decoration: none; display: inline-block; min-width: 2.6em; border-bottom: 2px solid var(--m2); text-align: center; color: var(--m2); }
.app-opt { display: grid; gap: 9px; }
.app-opt button, .app-bank button { all: unset; box-sizing: border-box; cursor: var(--zeiger); text-align: center; padding: 11px 14px; border-radius: 12px; border: 1.5px solid rgba(255, 255, 255, .14); background: rgba(255, 255, 255, .04); font-weight: 600; transition: border-color .2s, background .2s, translate .2s, opacity .2s; }
.app-opt button:hover, .app-bank button:hover { border-color: var(--m2); translate: 0 -1px; }
.app-opt button:focus-visible, .app-bank button:focus-visible, .app-weiter:focus-visible { outline: 2px solid var(--white); outline-offset: 2px; }
.app-opt button.ok, .app-bank button.ok { border-color: #5fe3a1; background: rgba(95, 227, 161, .16); color: #b9f7d6; }
.app-opt button.falsch { border-color: #ff8f8f; background: rgba(255, 143, 143, .14); color: #ffc9c9; animation: wackeln .4s; }
.app-opt button[disabled] { cursor: default; translate: none; }
@keyframes wackeln { 25% { translate: -5px 0; } 75% { translate: 5px 0; } }
.app-bank { display: flex; flex-wrap: wrap; gap: 8px; }
.app-bank button { padding: 9px 13px; }
.app-bank button.weg { opacity: .2; pointer-events: none; }
.app-feedback { margin-top: auto; padding: 14px 14px 12px; border-radius: 16px; background: rgba(95, 227, 161, .14); border: 1px solid rgba(95, 227, 161, .35); animation: feedbackEin .45s cubic-bezier(.2, .7, .2, 1); }
.app-feedback.daneben { background: rgba(255, 143, 143, .12); border-color: rgba(255, 143, 143, .35); }
@keyframes feedbackEin { from { opacity: 0; translate: 0 40px; } }
.app-feedback strong { display: block; margin-bottom: 2px; }
.app-feedback p { margin: 0 0 10px; font-size: .86rem; color: #dbe5ea; }
.app-feedback em { display: block; font-style: normal; font-size: .8rem; color: var(--m2); margin: -4px 0 10px; }
.app-weiter { all: unset; box-sizing: border-box; cursor: var(--zeiger); display: block; width: 100%; text-align: center; padding: 11px; border-radius: 12px; font-weight: 700; color: #06121a; background: linear-gradient(120deg, var(--m1), var(--m2)); }
.app-weiter[disabled] { opacity: .35; cursor: default; }
.app-ende { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; gap: 6px; padding: 16px; animation: feedbackEin .6s cubic-bezier(.2, .7, .2, 1); }
.app-ende .app-koi-gross { width: 56px; margin-bottom: 10px; filter: drop-shadow(0 0 24px var(--m2)); animation: koiSprung 1.6s ease-in-out infinite alternate; }
@keyframes koiSprung { from { translate: 0 6px; } to { translate: 0 -8px; } }
.app-ende b { font-size: 1.35rem; }
.app-ende p { margin: 0 0 14px; font-size: .88rem; color: #c9d4d9; }
.app-ende .app-weiter { margin-top: 4px; }
.app-ende .app-nochmal { all: unset; cursor: var(--zeiger); margin-top: 10px; font-size: .85rem; color: var(--m2); text-decoration: underline; text-underline-offset: 3px; }
.app-ende a.app-weiter:hover { color: #06121a; }
@media (max-width: 860px) { .demo { grid-template-columns: 1fr; } .demo-phone { order: -1; } }

/* ---------- 5 · Tagesplan zum Mitspielen ---------- */
.plan { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); gap: clamp(18px, 3vw, 40px); align-items: stretch; margin-bottom: 18px; padding: clamp(20px, 3vw, 32px); border-radius: 12px; border: 1px solid var(--border); background: rgba(11, 29, 41, .55); }
.plan-steuer { display: flex; flex-direction: column; }
.plan-steuer label { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; font-weight: 600; }
.plan-steuer output { font-size: 1.5rem; font-weight: 800; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.plan-enden { display: flex; justify-content: space-between; font-size: .82rem; color: var(--grey); margin-top: 2px; }
.plan-knoepfe { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 22px; }
.plan-knoepfe button { padding: 10px 16px; font-size: .93rem; }
.plan-meldung { margin: 18px 0 0; padding-top: 16px; border-top: 1px solid var(--border); color: #c9d4d9; font-size: .95rem; min-height: 5.2em; }
.plan-meldung strong { color: var(--white); }
.plan-bild { position: relative; display: flex; flex-direction: column; min-height: 240px; }
.plan-balken { flex: 1; display: flex; align-items: flex-end; gap: clamp(3px, .6vw, 7px); padding-top: 26px; border-bottom: 1px solid var(--border); }
.plan-balken i { position: relative; flex: 1; min-width: 0; height: calc(var(--h) * 19%); border-radius: 6px 6px 2px 2px; background: linear-gradient(180deg, var(--active), var(--secondary)); opacity: .28; transition: opacity .3s, box-shadow .3s, height .4s cubic-bezier(.2, .7, .2, 1); animation: balkenEin .5s cubic-bezier(.2, .7, .2, 1) backwards; animation-delay: calc(var(--i) * 25ms); transform-origin: 50% 100%; }
@keyframes balkenEin { from { scale: 1 0; } }
.plan-balken i.war { opacity: .8; }
.plan-balken i.jetzt { opacity: 1; box-shadow: 0 0 22px rgba(113, 223, 233, .65); }
.plan-balken i.daneben { background: #ff8f8f; opacity: .9; }
.plan-balken i.fehler { background: repeating-linear-gradient(135deg, #ff8f8f 0 5px, rgba(255, 143, 143, .35) 5px 10px); }
.plan-balken i.vor { animation: balkenVor .7s cubic-bezier(.3, 1.4, .5, 1); }
.plan.still .plan-balken i:not(.vor) { animation: none; }
@keyframes balkenVor { from { translate: 60px 0; opacity: 0; } }
.plan-balken i[data-z]::before { content: attr(data-z); position: absolute; left: 50%; bottom: calc(100% + 6px); translate: -50% 0; white-space: nowrap; font-style: normal; font-size: .7rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--active); }
.plan-balken i.fehler[data-z]::before, .plan-balken i.daneben[data-z]::before { color: #ffb3b3; }
.plan-achse { display: flex; justify-content: space-between; margin-top: 8px; font-size: .78rem; color: var(--grey); }
#system .problem-grid .card { transition: border-color .4s, background .4s; }
#system .problem-grid .card.an { border-color: rgba(113, 223, 233, .5); }
#system .problem-grid .card.an .icon { background: var(--verlauf); color: var(--primary); border-color: transparent; }
#system .problem-grid .icon { transition: background .4s, color .4s; }
@media (max-width: 860px) { .plan { grid-template-columns: 1fr; } .plan-meldung { min-height: 0; } }
@media (max-width: 520px) { .plan-balken i[data-z]::before { display: none; } }

/* ---------- 6 · Deine App im Entwurf ---------- */
.marke { --m1: var(--secondary); --m2: var(--active); display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: clamp(24px, 5vw, 64px); align-items: center; margin: 36px auto 8px; max-width: 880px; text-align: left; }
.marke-feld { margin-bottom: 22px; }
.marke-feld > label, .marke-feld > span { display: block; font-weight: 600; margin-bottom: 10px; }
.marke-farben, .marke-motive { display: flex; flex-wrap: wrap; gap: 10px; }
.marke-farben button { all: unset; box-sizing: border-box; cursor: var(--zeiger); width: 40px; height: 40px; border-radius: 50%; background: linear-gradient(140deg, var(--a), var(--b)); border: 3px solid var(--primary-light); outline: 2px solid transparent; transition: outline-color .2s, scale .25s cubic-bezier(.3, 1.6, .5, 1); }
.marke-farben button:hover { scale: 1.1; }
.marke-farben button[aria-pressed="true"] { outline-color: var(--white); }
.marke-motive button { all: unset; box-sizing: border-box; cursor: var(--zeiger); display: inline-flex; align-items: center; gap: 8px; padding: 8px 14px; border-radius: 999px; border: 1px solid var(--border); background: rgba(5, 14, 18, .6); color: #c9d4d9; font-size: .92rem; transition: border-color .2s, color .2s; }
.marke-motive svg { width: 18px; height: 18px; }
.marke-motive button:hover, .marke-motive button[aria-pressed="true"] { border-color: var(--m2); color: var(--white); }
.marke-farben button:focus-visible, .marke-motive button:focus-visible { outline: 2px solid var(--active); outline-offset: 3px; }
.marke-buehne { position: relative; width: min(250px, 70vw); justify-self: center; padding-top: 34px; }
.marke-buehne .phone { transform: rotate(3deg); }
.marke-icon { position: absolute; z-index: 4; left: -46px; top: 0; width: 92px; text-align: center; font-size: .72rem; font-weight: 600; color: var(--white); rotate: -7deg; }
.marke-icon i { display: grid; place-items: center; width: 80px; height: 80px; margin: 0 auto 6px; border-radius: 22px; background: linear-gradient(140deg, var(--m1), var(--m2)); box-shadow: 0 16px 34px rgba(0, 0, 0, .55), inset 0 1px 0 rgba(255, 255, 255, .35); transition: background .4s; }
.marke-icon svg { width: 40px; height: 40px; color: #06121a; }
.marke-icon span { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.marke-icon.neu i { animation: iconNeu .5s cubic-bezier(.3, 1.6, .5, 1); }
@keyframes iconNeu { 40% { scale: 1.14; rotate: 6deg; } }
.marke .app { font-size: 13px; }
.marke-start { flex: 1; display: flex; flex-direction: column; align-items: center; text-align: center; padding: 44px 14px 16px; }
.marke-start small { color: #b9c6cc; }
.marke-start b { font-size: 1.35rem; line-height: 1.2; margin: 2px 0 14px; overflow-wrap: anywhere; }
.marke-ring { position: relative; width: 62%; aspect-ratio: 1; display: grid; place-items: center; }
.marke-ring svg.ring { position: absolute; inset: 0; width: 100%; height: 100%; rotate: -90deg; }
.marke-ring circle { fill: none; stroke-width: 9; stroke-linecap: round; }
.marke-ring .spur { stroke: rgba(255, 255, 255, .1); }
.marke-ring .wert { stroke: var(--m2); stroke-dasharray: 100; stroke-dashoffset: 38; transition: stroke .4s; }
.marke-motiv { width: 44%; color: var(--m2); transition: color .4s; }
.marke-motiv svg { display: block; width: 100%; height: auto; }
.marke-start p { margin: 12px 0 0; font-size: .8rem; color: #c9d4d9; }
.marke-start .app-weiter { margin-top: auto; transition: background .4s; }
.marke-fuss { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 18px; margin-top: 6px; }
.marke-fuss .klein-hinweis { margin: 0; flex: 1 1 220px; }
@media (max-width: 760px) { .marke { grid-template-columns: 1fr; } .marke-buehne { order: -1; margin-left: 34px; } }

/* ---------- 7 · Überblick für Lehrkräfte ---------- */
.ueberblick-kopf { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 24px; margin-bottom: 18px; }
.fenster { border-radius: 14px; border: 1px solid var(--border); background: rgba(11, 29, 41, .7); box-shadow: 0 30px 70px rgba(0, 0, 0, .45); overflow: hidden; }
.fenster-leiste { display: flex; align-items: center; gap: 7px; padding: 12px 16px; border-bottom: 1px solid var(--border); font-size: .82rem; color: var(--grey); }
.fenster-leiste i { width: 10px; height: 10px; border-radius: 50%; background: var(--border); }
.fenster-leiste span { margin-left: 10px; }
.fenster-inhalt { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); }
.lernende { list-style: none; margin: 0; padding: 8px; display: grid; gap: 4px; align-content: start; }
.lernende button { all: unset; box-sizing: border-box; cursor: var(--zeiger); width: 100%; display: grid; grid-template-columns: 38px minmax(0, 1fr) 84px auto; gap: 12px; align-items: center; padding: 10px 12px; border-radius: 10px; border: 1px solid transparent; transition: background .25s, border-color .25s; }
.lernende button:hover { background: rgba(255, 255, 255, .04); }
.lernende button[aria-pressed="true"] { background: linear-gradient(160deg, rgba(138, 92, 253, .16), rgba(113, 223, 233, .08)); border-color: rgba(113, 223, 233, .3); }
.lernende button:focus-visible { outline: 2px solid var(--active); outline-offset: -2px; }
.lernende .kopf { width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; font-weight: 700; color: var(--primary); background: var(--verlauf); }
.lernende .wer { min-width: 0; }
.lernende .wer b { display: block; line-height: 1.25; }
.lernende .wer small { color: var(--grey); font-size: .82rem; }
.lernende svg { width: 84px; height: 30px; overflow: visible; }
.lernende polyline { fill: none; stroke: var(--active); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 1; stroke-dashoffset: 0; }
.lernende .sinkt polyline { stroke: #ffb347; }
.fenster.frisch .lernende polyline { animation: zeichnen 1.1s cubic-bezier(.5, 0, .3, 1) backwards; animation-delay: calc(var(--i) * 90ms); }
.pille { justify-self: end; white-space: nowrap; font-size: .76rem; font-weight: 700; padding: 3px 10px; border-radius: 999px; color: var(--active); background: var(--active-dark); border: 1px solid rgba(113, 223, 233, .25); }
.pille.achtung { color: #ffcf8a; background: rgba(255, 179, 71, .12); border-color: rgba(255, 179, 71, .35); }
.pille.leer { color: var(--grey); background: transparent; border-color: var(--border); }
.fenster-detail { padding: clamp(18px, 2.4vw, 26px); border-left: 1px solid var(--border); background: rgba(5, 14, 18, .45); }
.fenster-detail h3 { font-size: 1.15rem; }
.fenster-detail dl { margin: 14px 0 0; display: grid; gap: 12px; }
.fenster-detail dt { font-size: .74rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--grey); }
.fenster-detail dd { margin: 2px 0 0; color: #dbe5ea; font-size: .95rem; }
.fenster-detail .vorschlag { margin-top: 16px; padding: 14px 16px; border-radius: 10px; background: linear-gradient(160deg, rgba(138, 92, 253, .18), rgba(113, 223, 233, .1)); border: 1px solid rgba(138, 92, 253, .3); font-size: .95rem; }
.fenster-detail .vorschlag strong { display: block; font-size: .74rem; letter-spacing: .1em; text-transform: uppercase; color: var(--secondary-light); margin-bottom: 4px; }
.fenster.ohne .lernende svg { opacity: 0; }
.fenster.ohne .lernende .kopf { background: var(--border); color: var(--grey); }
.fenster-detail > * { animation: painWechsel .45s cubic-bezier(.2, .7, .2, 1); }
@media (max-width: 860px) { .fenster-inhalt { grid-template-columns: 1fr; } .fenster-detail { border-left: 0; border-top: 1px solid var(--border); } }
@media (max-width: 520px) { .lernende button { grid-template-columns: 38px minmax(0, 1fr) auto; } .lernende svg { display: none; } }

/* ---------- 8 · Der Koi ersetzt die Scrollleiste ---------- */
/* Unten ist der Seitenanfang, oben das Seitenende. Mit der Maus lässt sich der Koi ziehen, ein Klick auf die Bahn springt dorthin. */
html.koi-an { scrollbar-width: none; }
html.koi-an::-webkit-scrollbar { display: none; width: 0; }
.koi-weg { --p: 0; --g: 1; position: fixed; z-index: 45; right: 4px; top: calc(var(--header-h) + 34px); bottom: 34px; width: 24px; pointer-events: none; touch-action: none; }
.koi-weg .wasser { position: absolute; top: 0; bottom: 0; left: 50%; width: 4px; translate: -50% 0; border-radius: 4px; background: var(--border); overflow: hidden; transition: width .2s; }
.koi-weg .wasser::before { content: ''; position: absolute; left: 0; right: 0; bottom: 0; height: calc(var(--p) * 100%); background: linear-gradient(0deg, var(--secondary), var(--active)); }
.koi-weg .fisch { position: absolute; left: 50%; bottom: calc(var(--p) * 100%); width: 22px; translate: -50% 50%; transition: scale .4s cubic-bezier(.3, 1.6, .5, 1); filter: drop-shadow(0 3px 8px rgba(0, 0, 0, .6)); }
.koi-weg .drache-svg { display: none; }
.koi-weg.oben .koi-svg { display: none; }
.koi-weg.oben .drache-svg { display: block; }
.koi-weg.oben .fisch { scale: 1.4; filter: drop-shadow(0 0 14px var(--active)); }
.koi-weg .gipfel { position: absolute; left: 50%; bottom: calc(var(--g) * 100%); translate: -50% 50%; width: 12px; height: 12px; border-radius: 50%; border: 2px solid var(--primary-dark); background: var(--primary); transition: border-color .4s, box-shadow .4s; }
.koi-weg.oben .gipfel { border-color: var(--active); box-shadow: 0 0 16px var(--active); }
.koi-ruf { position: absolute; right: 32px; bottom: calc(var(--g) * 100%); translate: 12px 50%; white-space: nowrap; padding: 9px 14px; border-radius: 10px; font-size: .86rem; font-weight: 600; color: var(--primary); background: var(--verlauf); box-shadow: 0 12px 30px rgba(0, 0, 0, .45); opacity: 0; transition: opacity .5s, translate .5s cubic-bezier(.2, .7, .2, 1); }
.koi-weg.ruft .koi-ruf { opacity: 1; translate: 0 50%; }
.drache-svg { width: 100%; height: auto; overflow: visible; }
.drache-svg .leib { animation: drachenLeib 1.4s ease-in-out infinite alternate; transform-box: fill-box; transform-origin: 50% 0; }
@keyframes drachenLeib { from { rotate: -5deg; } to { rotate: 5deg; } }
@media (hover: hover) and (pointer: fine) {
  .koi-weg { pointer-events: auto; cursor: grab; }
  .koi-weg:hover .wasser, .koi-weg.zieht .wasser { width: 8px; }
  .koi-weg:hover .fisch, .koi-weg.zieht .fisch { scale: 1.25; }
  .koi-weg.oben:hover .fisch { scale: 1.6; }
  .koi-weg.zieht { cursor: grabbing; }
  html.maus-an .koi-weg, html.maus-an .koi-weg.zieht { cursor: none; }
}
@media (max-width: 1023.98px) {
  .koi-weg { right: 0; width: 16px; top: calc(var(--header-h) + 16px); bottom: 16px; }
  .koi-weg .wasser { width: 3px; }
  .koi-weg .fisch { width: 14px; }
  .koi-weg .gipfel { width: 8px; height: 8px; }
  .koi-ruf { right: 20px; white-space: normal; width: max-content; max-width: calc(100vw - 48px); }
}
html.menue-auf .koi-weg { display: none; }
@media print { .koi-weg { display: none; } }
.wende-abschnitt .wende { margin-top: 0; }

/* ---------- 9 · Ablauf: Schritt für Schritt, mit Blick aufs Geld ---------- */
.ablauf { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: 18px; }
.ablauf-schiene { grid-column: 1 / -1; position: relative; display: grid; grid-template-columns: repeat(4, 1fr); margin-bottom: 10px; }
.ablauf-schiene::before, .ablauf-schiene::after { content: ''; position: absolute; top: 21px; left: 12.5%; height: 3px; border-radius: 3px; }
.ablauf-schiene::before { right: 12.5%; background: var(--border); }
.ablauf-schiene::after { width: calc(var(--s, 0) * 25%); background: var(--verlauf); box-shadow: 0 0 14px rgba(113, 223, 233, .5); transition: width .7s cubic-bezier(.2, .7, .2, 1); }
.ablauf-schiene button { all: unset; box-sizing: border-box; cursor: var(--zeiger); position: relative; z-index: 1; display: flex; flex-direction: column; align-items: center; gap: 6px; text-align: center; padding: 0 4px; }
.ablauf-schiene b { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 50%; background: var(--primary-light); border: 2px solid var(--border); color: var(--grey); font-size: 1.05rem; transition: background .4s, color .4s, border-color .4s, scale .4s cubic-bezier(.3, 1.6, .5, 1), box-shadow .4s; }
.ablauf-schiene span { font-weight: 600; font-size: .98rem; line-height: 1.25; color: var(--grey); transition: color .3s; }
.ablauf-schiene small { font-size: .8rem; color: var(--grey); }
.ablauf-schiene button.war b { border-color: var(--active); color: var(--active); }
.ablauf-schiene button[aria-selected="true"] b { background: var(--verlauf); border-color: transparent; color: var(--primary); scale: 1.14; box-shadow: 0 0 26px rgba(138, 92, 253, .55); }
.ablauf-schiene button[aria-selected="true"] span, .ablauf-schiene button:hover span { color: var(--white); }
.ablauf-schiene button:focus-visible b { outline: 2px solid var(--active); outline-offset: 3px; }
.ablauf-karte { padding: clamp(22px, 3vw, 32px); border-radius: 12px; }
.ablauf-karte .nr { font-size: .8rem; font-weight: 700; letter-spacing: .1em; color: var(--active); margin-bottom: 10px; }
.ablauf-karte h3 { font-size: clamp(1.4rem, 2.4vw, 1.8rem); }
.ablauf-karte p { color: #c9d4d9; }
.ablauf-karte .ablauf-kern > * { animation: painWechsel .45s cubic-bezier(.2, .7, .2, 1) backwards; }
.ablauf-karte .umschalter { margin: 6px 0 4px; }
.ablauf-nav { display: flex; justify-content: space-between; gap: 12px; margin-top: auto; padding-top: 20px; }
.ablauf-nav button { padding: 10px 18px; font-size: .93rem; }
.ablauf-nav [hidden] + * { margin-left: auto; }
.ablauf-geld { padding: clamp(22px, 3vw, 32px); border-radius: 12px; background: linear-gradient(var(--primary-light), var(--primary-light)) padding-box, var(--verlauf) border-box; border: 1px solid transparent; }
.ablauf-geld .tag { align-self: flex-start; display: inline-block; font-size: .78rem; font-weight: 600; color: var(--active); background: var(--active-dark); border: 1px solid rgba(113, 223, 233, .25); border-radius: 999px; padding: 3px 12px; margin-bottom: 14px; }
.geld-zahl { font-size: clamp(2.2rem, 4.6vw, 3.2rem); font-weight: 800; letter-spacing: -.03em; line-height: 1.1; font-variant-numeric: tabular-nums; }
.geld-von { font-size: .9rem; color: var(--grey); margin: 2px 0 14px; }
.geld-balken { height: 12px; border-radius: 12px; background: var(--border); overflow: hidden; }
.geld-balken i { display: block; height: 100%; width: calc(var(--w, 0) * 100%); border-radius: 12px; background: var(--verlauf); transition: width .8s cubic-bezier(.2, .7, .2, 1); }
.geld-balken.zurueck i { background: #5fe3a1; }
.geld-text { margin: 16px 0 0; color: #c9d4d9; font-size: .97rem; }
.geld-risiko { margin: 16px 0 0; padding-top: 16px; border-top: 1px solid var(--border); font-size: .97rem; color: #dbe5ea; }
.geld-risiko strong { display: block; font-size: .74rem; letter-spacing: .1em; text-transform: uppercase; color: var(--secondary-light); margin-bottom: 3px; }
@media (max-width: 860px) { .ablauf { grid-template-columns: 1fr; } }
@media (max-width: 560px) { .ablauf-schiene span { font-size: .78rem; } .ablauf-schiene small { display: none; } .ablauf-schiene b { width: 38px; height: 38px; } .ablauf-schiene::before, .ablauf-schiene::after { top: 18px; } }

/* ---------- 10 · Rechner: was es kostet und ab wann es sich trägt ---------- */
.rechner { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: clamp(22px, 4vw, 48px); padding: clamp(22px, 3.4vw, 40px); border-radius: 12px; }
.rechner-wahl { display: grid; gap: 24px; align-content: start; }
.rechner-wahl > div > span, .rechner-wahl label { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; font-weight: 600; margin-bottom: 10px; }
.rechner-wahl output { font-size: 1.35rem; font-weight: 800; font-variant-numeric: tabular-nums; }
.rechner-ergebnis { display: flex; flex-direction: column; padding: clamp(18px, 2.6vw, 28px); border-radius: 12px; background: rgba(5, 14, 18, .6); border: 1px solid var(--border); }
.re-zeile { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; padding: 11px 0; border-bottom: 1px solid var(--border); color: #c9d4d9; font-size: .95rem; }
.re-zeile b { color: var(--white); text-align: right; font-variant-numeric: tabular-nums; }
.re-zeile.gross b { font-size: 1.7rem; font-weight: 800; letter-spacing: -.02em; }
.re-trag { display: grid; grid-template-columns: auto 1fr; gap: 4px 18px; align-items: center; margin: 20px 0 6px; padding: 18px 20px; border-radius: 12px; background: linear-gradient(160deg, rgba(138, 92, 253, .2), rgba(113, 223, 233, .12)); border: 1px solid rgba(113, 223, 233, .3); }
.re-trag b { grid-row: span 2; font-size: clamp(2.4rem, 5vw, 3.4rem); font-weight: 900; line-height: 1; letter-spacing: -.03em; font-variant-numeric: tabular-nums; background: var(--verlauf); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.re-trag strong { align-self: end; }
.re-trag span { align-self: start; font-size: .9rem; color: #c9d4d9; }
.rechner-ergebnis .primary-button { margin-top: 18px; }
.preis.gewaehlt { box-shadow: 0 0 0 2px var(--active), 0 20px 50px rgba(113, 223, 233, .12); }
@media (max-width: 860px) { .rechner { grid-template-columns: 1fr; } }

/* ---------- 11 · Begleiter: Edwin bleibt erreichbar ---------- */
.dock { position: fixed; z-index: 48; right: 40px; bottom: 24px; display: flex; align-items: center; gap: 12px; max-width: min(520px, calc(100vw - 32px)); padding: 10px 12px 10px 10px; border-radius: 999px; border: 1px solid rgba(255, 255, 255, .1); background: rgba(11, 29, 41, .9); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); box-shadow: 0 20px 50px rgba(0, 0, 0, .5); opacity: 0; translate: 0 30px; visibility: hidden; transition: opacity .45s, translate .55s cubic-bezier(.2, .7, .2, 1), visibility 0s .5s; }
.dock.da { opacity: 1; translate: 0 0; visibility: visible; transition: opacity .45s, translate .55s cubic-bezier(.2, .7, .2, 1), visibility 0s; }
.dock img { width: 44px; height: 44px; flex: none; border-radius: 50%; object-fit: cover; border: 2px solid transparent; background: radial-gradient(circle at 50% 30%, rgba(138, 92, 253, .55), var(--primary-light) 72%) padding-box, var(--verlauf) border-box; }
.dock p { margin: 0; min-width: 0; font-size: .9rem; line-height: 1.35; color: #dbe5ea; }
.dock p span { display: block; animation: painWechsel .45s cubic-bezier(.2, .7, .2, 1); }
.dock .primary-button { flex: none; padding: 9px 16px; font-size: .9rem; border-radius: 999px; }
.dock-wa, .dock-zu { all: unset; box-sizing: border-box; cursor: var(--zeiger); flex: none; display: grid; place-items: center; width: 38px; height: 38px; border-radius: 50%; }
.dock-wa { background: #25d366; color: #fff; }
.dock-wa:hover { color: #fff; box-shadow: 0 6px 20px rgba(37, 211, 102, .45); }
.dock-wa svg { width: 20px; height: 20px; }
.dock-zu { width: 30px; height: 30px; color: var(--grey); font-size: 1.2rem; line-height: 1; }
.dock-zu:hover { color: var(--white); background: rgba(255, 255, 255, .08); }
.dock-wa:focus-visible, .dock-zu:focus-visible { outline: 2px solid var(--active); outline-offset: 2px; }
html.menue-auf .dock { display: none; }
@media (max-width: 640px) {
  .dock { left: 12px; right: 12px; bottom: calc(12px + env(safe-area-inset-bottom, 0px)); max-width: none; border-radius: 18px; }
  .dock { gap: 10px; }
  .dock img { width: 38px; height: 38px; }
  .dock p { flex: 1; font-size: .84rem; }
  .dock .primary-button { padding: 9px 13px; }
  .dock-wa { display: none; }
  body:has(.cookie-banner.offen) .dock { display: none; }
}
@media print { .dock { display: none; } }

/* ---------- 12 · Gesprächsnotiz: Sätze antippen, Nachricht und Antwort entstehen daneben ---------- */
.notiz { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); gap: clamp(18px, 3vw, 40px); align-items: start; margin-bottom: 44px; }
.notiz-seite { display: grid; gap: 18px; }
@media (min-width: 861px) and (min-height: 900px) { .notiz-seite { position: sticky; top: calc(var(--header-h) + 20px); } }
.notiz-zettel { position: relative; padding: 0; border-radius: 14px; overflow: hidden; }
.notiz-kopf { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 6px 16px; padding: 14px 20px; border-bottom: 2px dashed var(--border); font-size: .86rem; color: var(--grey); }
.notiz-kopf strong { font-size: 1.05rem; color: var(--white); }
.notiz-zeile { display: grid; grid-template-columns: 96px minmax(0, 1fr); gap: 6px 14px; align-items: start; padding: 11px 20px; border-bottom: 1px solid var(--border); }
.notiz-zeile:last-child { border-bottom: 0; }
.notiz-zeile > span { font-size: .74rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--grey); padding-top: 7px; }
.notiz-chips { display: flex; flex-wrap: wrap; gap: 7px; align-items: center; }
.notiz-chips button, .notiz-chips a, .notiz-chips em { all: unset; box-sizing: border-box; display: inline-flex; align-items: center; gap: 8px; padding: 5px 12px; border-radius: 999px; border: 1px solid var(--border); background: rgba(5, 14, 18, .6); font-size: .88rem; color: #c9d4d9; }
.notiz-chips button, .notiz-chips a { cursor: var(--zeiger); transition: border-color .2s, color .2s, background .2s; }
.notiz-chips button:hover, .notiz-chips a:hover { border-color: var(--active); color: var(--white); }
.notiz-chips button[aria-pressed="true"] { border-color: var(--active); background: var(--active-dark); color: var(--white); }
.notiz-chips a { border-style: dashed; color: var(--active); }
.notiz-chips button:focus-visible, .notiz-chips a:focus-visible { outline: 2px solid var(--active); outline-offset: 2px; }
.notiz-chips i { width: 12px; height: 12px; border-radius: 50%; background: linear-gradient(140deg, var(--a), var(--b)); }
.notiz-chips em { font-style: normal; }
.notiz-chat { display: grid; gap: 14px; }
.notiz-chat small { display: block; margin-bottom: 5px; font-size: .76rem; color: var(--grey); }
.chat-du { justify-self: end; max-width: 94%; }
.chat-du small { text-align: right; }
.blase { padding: 14px 17px; border-radius: 18px 4px 18px 18px; background: #0f3a33; border: 1px solid rgba(37, 211, 102, .3); color: #e8fff5; font-size: .95rem; line-height: 1.55; }
.blase.neu { animation: painWechsel .4s cubic-bezier(.2, .7, .2, 1); }
.chat-edwin { display: flex; align-items: flex-end; gap: 10px; max-width: 96%; }
.chat-edwin img { flex: none; width: 40px; height: 40px; border-radius: 50%; object-fit: cover; border: 2px solid transparent; background: radial-gradient(circle at 50% 30%, rgba(138, 92, 253, .55), var(--primary-light) 72%) padding-box, var(--verlauf) border-box; }
.blase.edwin { border-radius: 18px 18px 18px 4px; background: rgba(138, 92, 253, .14); border-color: rgba(138, 92, 253, .35); color: #dbe5ea; }
.blase.edwin strong { display: block; margin-bottom: 4px; color: var(--white); }
.notiz-knoepfe { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 4px; }
.notiz-knoepfe .secondary-button { padding: 11px 16px; font-size: .93rem; }
.notiz-chat .klein-hinweis { margin: 0; }
@media (max-width: 860px) { .notiz { grid-template-columns: 1fr; } }
@media (max-width: 520px) { .notiz-zeile { grid-template-columns: 1fr; } .notiz-zeile > span { padding-top: 0; } }

/* ==WEITER== */
