/* =========================================================
   ════════  V5.7 — HYPERRAUM · EREIGNISHORIZONT · SIGNAL  ════════
   ========================================================= */

/* ---------- 1) Hyperraum-Sprung ---------- */
.warp-layer { position: fixed; inset: 0; z-index: 9800; width: 100%; height: 100%; pointer-events: none; }
/* Navigation + Sternfeld bekommen nur WÄHREND des Sprungs eigene
   Gruppen (sonst würde der Theme-Wechsel die Nav nicht mehr mitnehmen) */
html.warping #navbar { view-transition-name: ef-nav; }
html.warping .warp-layer:not(.solo) { view-transition-name: ef-warp; }
html.warping::view-transition { background: var(--warp-bg, #06050f); }
html.warping::view-transition-old(root),
html.warping::view-transition-new(root) {
    animation: none;
    mix-blend-mode: normal;
    transform-origin: var(--warp-o, 50% 50%);
}
html.warping::view-transition-group(ef-warp),
html.warping::view-transition-new(ef-warp) { animation: none; }
html.warping::view-transition-old(ef-warp) { animation: none; opacity: 0; }
html.warping::view-transition-group(ef-nav) { animation-duration: 0.5s; }

/* ---------- 2) Ereignishorizont ---------- */
.footer-giant.hz-on {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: clamp(260px, 32vw, 540px);
    padding: 0;
}
.footer-giant.hz-on span { visibility: hidden; animation: none !important; }
.hz-canvas {
    position: absolute;
    inset: 0;
    display: block;
    width: 100%;
    height: 100%;
    /* weiche Ränder → nahtlos in Marquee und Fusszeile */
    -webkit-mask-image: linear-gradient(to bottom, transparent 0, #000 16%, #000 84%, transparent 100%);
            mask-image: linear-gradient(to bottom, transparent 0, #000 16%, #000 84%, transparent 100%);
}
.hz-core {
    position: absolute;
    left: 0;
    top: 0;
    width: 64px;
    height: 64px;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: transparent;
    cursor: pointer;
    will-change: transform;
    -webkit-tap-highlight-color: transparent;
}
.hz-core:focus-visible { outline: 2px solid #C4B5FD; outline-offset: 8px; }
[data-theme="light"] .hz-core:focus-visible { outline-color: #4F35C9; }
.hz-core::after {
    content: 'Hineinfallen ↑';
    position: absolute;
    left: 50%;
    top: calc(100% + 30px);
    translate: -50% 4px;
    white-space: nowrap;
    font: 500 0.66rem var(--font-mono);
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: #C4B5FD;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease, translate 0.3s ease;
}
[data-theme="light"] .hz-core::after { color: #4F35C9; }
.hz-core:hover::after, .hz-core:focus-visible::after { opacity: 0.9; translate: -50% 0; }
@media (hover: none) { .hz-core::after { opacity: 0.7; translate: -50% 0; content: 'Tippen ↑'; } }

/* ---------- 3) Signal-Kapsel ---------- */
.sig-layer { position: fixed; inset: 0; z-index: 9650; width: 100%; height: 100%; pointer-events: none; }
.seal-btn.launching .seal { scale: 0.82; transition: scale 0.4s cubic-bezier(0.5, 0, 0.75, 0), transform 0.55s cubic-bezier(0.34, 1.56, 0.64, 1); }
.seal-btn .seal { transition: scale 0.5s cubic-bezier(0.34, 1.56, 0.64, 1), transform 0.55s cubic-bezier(0.34, 1.56, 0.64, 1); }
.pass-rx {
    position: absolute;
    inset: 0;
    z-index: 3;
    border-radius: inherit;
    pointer-events: none;
    animation: passRx 1.2s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
}
@keyframes passRx {
    0%   { box-shadow: 0 0 0 0 rgba(236, 72, 153, 0), 0 0 0 0 rgba(139, 92, 246, 0); background: rgba(196, 181, 253, 0); }
    16%  { box-shadow: 0 0 0 2px rgba(236, 72, 153, 0.75), 0 0 70px 8px rgba(139, 92, 246, 0.55); background: rgba(196, 181, 253, 0.14); }
    100% { box-shadow: 0 0 0 1px rgba(236, 72, 153, 0), 0 0 90px 24px rgba(139, 92, 246, 0); background: rgba(196, 181, 253, 0); }
}
[data-theme="light"] .pass-rx { animation-name: passRxLight; }
@keyframes passRxLight {
    0%   { box-shadow: 0 0 0 0 rgba(190, 24, 93, 0), 0 0 0 0 rgba(109, 40, 217, 0); }
    16%  { box-shadow: 0 0 0 2px rgba(190, 24, 93, 0.6), 0 0 60px 6px rgba(109, 40, 217, 0.35); }
    100% { box-shadow: 0 0 0 1px rgba(190, 24, 93, 0), 0 0 80px 20px rgba(109, 40, 217, 0); }
}

@media (prefers-reduced-motion: reduce) {
    .warp-layer, .sig-layer, .pass-rx { display: none; }
}
@media print {
    .warp-layer, .sig-layer, .hz-canvas, .hz-core, .pass-rx { display: none !important; }
    .footer-giant.hz-on span { visibility: visible; }
}
