/* ============================================================
   JUNIOR 1 – Startanimation: Vollbild-Intro (Partikel / Aurora) + Überblendung auf die Startseite
   ============================================================ */

/* Bis die Animation startet: Header, Hero-Inhalt und Kacheln verstecken (kein Aufblitzen) */
html.intro-hold .site-header,
html.intro-hold .hero-media,
html.intro-hold .hero-scrim,
html.intro-hold .hero-content > *,
html.intro-hold .fac-card { opacity: 0; }

/* Überschrift wird beim Reveal in Zeilen/Wörter zerlegt */
.hl-line { display: block; overflow: hidden; padding-bottom: .08em; margin-bottom: -.08em; }
.hl-in { display: inline-block; }
.hl-w { display: inline-block; will-change: transform, opacity, filter; transform-origin: 50% 100%; }

/* ---------- Vollbild-Intro ---------- */
.splash { display: none; position: fixed; inset: 0; z-index: 300; overflow: hidden; }
html.splash-on { overflow: hidden; }
html.splash-on .splash { display: block; }
.splash-cover { position: absolute; inset: 0; background: radial-gradient(120% 90% at 50% 40%, #1d4a2f 0%, #0b2216 70%); }
[data-splash="aurora"] .splash-cover { background: #faf5ea; }
.splash-grain {
  position: absolute; inset: -50%; pointer-events: none; opacity: .07; mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  animation: splash-grain .6s steps(4) infinite;
}
@keyframes splash-grain { 25% { transform: translate(-3%, 2%); } 50% { transform: translate(2%, -3%); } 75% { transform: translate(-2%, -2%); } }
.splash canvas { position: absolute; inset: 0; }
.splash-skip {
  position: absolute; right: 24px; bottom: 22px; z-index: 5; display: inline-flex; align-items: center; gap: 8px; padding: 8px 14px;
  border: 1px solid rgba(255, 255, 255, .22); border-radius: 999px; background: rgba(255, 255, 255, .06); color: rgba(255, 255, 255, .75);
  font-family: inherit; font-weight: 700; font-size: .75rem; line-height: 1; letter-spacing: .08em; text-transform: uppercase; backdrop-filter: blur(8px); cursor: pointer; transition: background .2s, color .2s;
}
.splash-skip:hover { background: rgba(255, 255, 255, .16); color: #fff; }
[data-splash="aurora"] .splash-skip { color: rgba(30, 40, 25, .7); border-color: rgba(30, 40, 25, .2); background: rgba(255, 255, 255, .5); }
.splash-tag { position: absolute; left: 0; right: 0; text-align: center; color: rgba(255, 255, 255, .82); font-size: .78rem; font-weight: 700; letter-spacing: .42em; text-transform: uppercase; padding-left: .42em; }

/* Aurora */
.splash-orb { position: absolute; left: 50%; top: 50%; width: 46vmax; height: 46vmax; margin: -23vmax 0 0 -23vmax; border-radius: 50%; filter: blur(80px); will-change: transform; }
.splash-center { position: absolute; inset: 0; display: grid; place-content: center; justify-items: center; gap: 22px; z-index: 2; }
.splash-center img { width: min(62vw, 520px); height: auto; }
.splash-center .splash-tag { position: static; color: #3b4a33; padding-left: .42em; }
@media (max-width: 640px) { .splash-skip { right: 16px; bottom: 16px; } }

/* ---------- DEV-Leiste (Umschalter) ---------- */
.dev-bar { position: fixed; left: 12px; top: 86px; z-index: 120; display: flex; align-items: center; gap: 4px; padding: 4px 5px 4px 4px; border-radius: 999px; background: rgba(18, 48, 31, .82); backdrop-filter: blur(6px); box-shadow: 0 6px 16px -8px rgba(0, 0, 0, .5); font-size: 11px; line-height: 1; }
.dev-tag { padding: 4px 7px; border-radius: 999px; background: #f59a1f; color: #1d1405; font-weight: 800; letter-spacing: .1em; }
.dev-bar a { padding: 5px 9px; border-radius: 999px; color: rgba(255, 255, 255, .85); text-decoration: none; font-weight: 700; }
.dev-bar a:hover { background: rgba(255, 255, 255, .16); color: #fff; }
.dev-bar a.is-on { background: #fff; color: var(--deep); }
@media (max-width: 900px) { .dev-bar { top: 74px; left: 8px; } }

/* Startmusik: kleine Ton-Schaltfläche (oben rechts, über dem Intro) */
.snd { position: fixed; z-index: 450; top: 84px; right: 18px; display: inline-flex; align-items: center; gap: 8px; height: 42px; min-width: 42px; padding: 0 13px; justify-content: center; border: 0; border-radius: 999px; cursor: pointer; font: inherit; font-size: 14px; font-weight: 700; color: #12301f; background: rgba(255, 255, 255, .92); box-shadow: 0 12px 26px -12px rgba(0, 0, 0, .55); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); transition: transform .25s ease, background-color .2s; }
.snd:hover { transform: scale(1.05); background: #fff; }
.snd svg { width: 20px; height: 20px; flex: none; }
.snd.is-on svg { animation: sndPulse 1.8s ease-in-out infinite; }
@keyframes sndPulse { 0%, 100% { opacity: 1; } 50% { opacity: .55; } }
@media (max-width: 640px) { .snd { top: 78px; right: 12px; } }
@media (prefers-reduced-motion: reduce) { .snd.is-on svg { animation: none; } }

/* Hinweis „Tippen, um Ton zu hören“: Schaltfläche pulsiert, der Lautsprecher „sendet“ Wellen, der Text wippt leicht */
.snd.is-hint { padding: 0 16px 0 13px; font-size: 14.5px; }
.snd.is-hint::after { content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none; box-shadow: 0 0 0 0 rgba(143, 208, 169, .9); animation: sndRing 2.2s ease-out infinite; }
.snd.is-hint span { animation: sndNudge 2.2s ease-in-out infinite; }
.snd:not(.is-on) svg path:nth-of-type(2) { animation: sndWave 2.2s ease-in-out infinite; transform-origin: 0 50%; }
@keyframes sndRing { 0% { box-shadow: 0 0 0 0 rgba(26, 127, 69, .55); } 70%, 100% { box-shadow: 0 0 0 16px rgba(26, 127, 69, 0); } }
@keyframes sndNudge { 0%, 100% { transform: translateX(0); } 50% { transform: translateX(-3px); } }
@keyframes sndWave { 0%, 100% { opacity: 1; } 50% { opacity: .35; } }
@media (max-width: 640px) { .snd.is-hint { font-size: 13px; padding: 0 13px 0 11px; } }
@media (prefers-reduced-motion: reduce) { .snd.is-hint::after, .snd.is-hint span, .snd:not(.is-on) svg path:nth-of-type(2) { animation: none; } }
