/* ============================================================
   spiritbasel.newearthuman.com — style.css
   Spirit of Basel · 13.–15. Januar 2006
   ============================================================ */

/* --- Reset & Base ------------------------------------------ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
    --bg:       #050510;
    --orange:   #f97316;
    --gold:     #fbbf24;
    --cyan:     #06b6d4;
    --magenta:  #ff00cc;
    --purple:   #6d28d9;
    --white:    #ffffff;
    --font-headline: 'Oswald', sans-serif;
    --font-body:     'Space Grotesk', sans-serif;
}

html {
    width: 100%; height: 100%;
    overflow: hidden;
    background: var(--bg);
}

body {
    width: 100%; height: 100%;
    overflow: hidden;
    color: var(--white);
    font-family: var(--font-body);
    user-select: none;
}

body.page-landing {
    height: auto;
    overflow-y: scroll;
    overflow-x: hidden;
}

html:has(body.page-landing) {
    overflow-y: scroll;
    height: auto;
}

/* --- Background Stack --------------------------------------- */
#bg-video-wrap {
    position: fixed;
    inset: 0;
    z-index: 0;
    overflow: hidden;
}
#bg-video {
    width: 100%; height: 100%;
    object-fit: cover;
    opacity: 0.20;
    transition: opacity 2s ease;
}
#bg-video.fade-out { opacity: 0; }
#bg-video.fade-in  { opacity: 0.20; }

/* Lotus layer — unter dem Molekül */
#lotus-wrap {
    position: fixed;
    inset: 0;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    pointer-events: none;
}
#lotus-img {
    width: min(80vw, 80vh);
    height: auto;
    opacity: 0.12;
    filter: blur(0.5px);
}
/* Hauptseite: Lotus größer + 66px nach unten */
body.page-landing #lotus-img {
    width: min(104vw, 104vh);
    opacity: 0.08;
}
body.page-landing #lotus-wrap {
    transform: translateY(22px);
}
#lotus-img.rotating {
    animation: lotus-spin 180s linear infinite;
}
@keyframes lotus-spin {
    from { transform: rotate(0deg); }
    to   { transform: rotate(360deg); }
}

/* --- Canvas (Vortex) ---------------------------------------- */
#vortex-canvas {
    position: fixed;
    inset: 0;
    z-index: 2;
    cursor: crosshair;
}

/* --- Fibonacci Button --------------------------------------- */
#fibonacci-btn {
    position: fixed;
    z-index: 10;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 165px;
    height: 165px;
    border-radius: 50%;
    border: 2px solid rgba(255,255,255,0.35);
    background: transparent;
    cursor: pointer;
    box-shadow:
        0 0 30px rgba(249,115,22,0.5),
        0 0 70px rgba(255,0,204,0.25),
        0 0 120px rgba(251,191,36,0.1);
    animation: fib-pulse 3s ease-in-out infinite;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    padding: 0;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}
#fib-logo {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
    display: block;
}
#fibonacci-btn:hover {
    transform: translate(-50%, -50%) scale(1.12);
    box-shadow:
        0 0 60px rgba(249,115,22,0.8),
        0 0 120px rgba(255,0,204,0.5),
        0 0 180px rgba(251,191,36,0.3);
}
#fibonacci-btn.assembling {
    animation: fib-pulse-fast 0.5s ease-in-out infinite;
    box-shadow:
        0 0 100px rgba(251,191,36,0.9),
        0 0 200px rgba(249,115,22,0.7);
}
@keyframes fib-gradient {
    0%   { background-position: 0% 50%; }
    50%  { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}
@keyframes fib-pulse {
    0%, 100% { box-shadow: 0 0 30px rgba(249,115,22,0.4), 0 0 60px rgba(255,0,204,0.2), inset 0 0 20px rgba(255,255,255,0.1); }
    50%       { box-shadow: 0 0 50px rgba(249,115,22,0.7), 0 0 90px rgba(255,0,204,0.4), inset 0 0 30px rgba(255,255,255,0.2); }
}
@keyframes fib-pulse-fast {
    0%, 100% { transform: translate(-50%, -50%) scale(1.0); }
    50%       { transform: translate(-50%, -50%) scale(1.15); }
}

/* --- Video Overlay ----------------------------------------- */
#video-overlay {
    position: fixed;
    inset: 0;
    z-index: 20;
    background: rgba(5,5,16,0.92);
    backdrop-filter: blur(10px);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 28px;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.5s ease;
}
#video-overlay.active {
    opacity: 1;
    pointer-events: all;
}
#clip-title {
    font-family: var(--font-headline);
    font-size: clamp(0.7rem, 1.5vw, 0.95rem);
    letter-spacing: 0.22em;
    color: rgba(255,255,255,0.45);
    text-align: center;
    pointer-events: none;
    flex-shrink: 0;
}

#main-player {
    max-width: 90vw;
    max-height: 78vh;
    border-radius: 12px;
    box-shadow:
        0 0 60px rgba(249,115,22,0.3),
        0 0 120px rgba(255,0,204,0.15);
    outline: none;
    flex-shrink: 0;
}
#player-controls {
    display: flex;
    gap: 36px;
    align-items: center;
    flex-shrink: 0;
}
#close-player {
    background: rgba(249,115,22,0.25);
    border: 2px solid rgba(249,115,22,0.6);
    color: var(--white);
    width: 52px; height: 52px;
    border-radius: 50%;
    font-size: 1.6rem;
    cursor: pointer;
    display: flex; align-items: center; justify-content: center;
    transition: background 0.2s, transform 0.2s, box-shadow 0.2s;
    backdrop-filter: blur(8px);
    box-shadow: 0 0 20px rgba(249,115,22,0.3);
}
#close-player:hover {
    background: rgba(249,115,22,0.6);
    transform: scale(1.12);
    box-shadow: 0 0 35px rgba(249,115,22,0.6);
}
#prev-btn, #next-btn {
    background: rgba(255,255,255,0.08);
    border: 1px solid rgba(255,255,255,0.25);
    color: var(--white);
    width: 52px; height: 52px;
    border-radius: 50%;
    font-size: 1.3rem;
    cursor: pointer;
    display: flex; align-items: center; justify-content: center;
    transition: all 0.2s;
    backdrop-filter: blur(8px);
}
#prev-btn:hover, #next-btn:hover {
    background: rgba(249,115,22,0.3);
    border-color: rgba(249,115,22,0.6);
    box-shadow: 0 0 20px rgba(249,115,22,0.4);
    transform: scale(1.1);
}

/* --- Photo Slideshow Player -------------------------------- */
#photo-player {
    position: fixed;
    inset: 0;
    z-index: 20;
    background: rgba(5,5,16,0.96);
    backdrop-filter: blur(12px);
    display: none;
    align-items: center;
    justify-content: center;
}
#photo-player.active {
    display: flex;
}
/* Wrapper hält Bild + Controls fest zusammen */
#photo-inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 22px;
    max-height: 92vh;
}
#photo-img {
    max-width: 88vw;
    max-height: 75vh;
    object-fit: contain;
    border-radius: 6px;
    box-shadow:
        0 0 60px rgba(251,191,36,0.22),
        0 8px 40px rgba(0,0,0,0.7);
    display: block;
}
#photo-controls {
    display: flex;
    align-items: center;
    gap: 32px;
    flex-shrink: 0;
}
#photo-prev, #photo-next {
    background: rgba(255,255,255,0.08);
    border: 1px solid rgba(255,255,255,0.25);
    color: var(--white);
    width: 52px; height: 52px;
    border-radius: 50%;
    font-size: 1.3rem;
    cursor: pointer;
    display: flex; align-items: center; justify-content: center;
    transition: all 0.2s;
    backdrop-filter: blur(8px);
}
#photo-prev:hover, #photo-next:hover {
    background: rgba(251,191,36,0.25);
    border-color: rgba(251,191,36,0.6);
    box-shadow: 0 0 20px rgba(251,191,36,0.4);
    transform: scale(1.1);
}
#photo-close {
    background: rgba(249,115,22,0.2);
    border: 2px solid rgba(249,115,22,0.5);
    color: var(--white);
    width: 52px; height: 52px;
    border-radius: 50%;
    font-size: 1.4rem;
    cursor: pointer;
    display: flex; align-items: center; justify-content: center;
    transition: all 0.2s;
    backdrop-filter: blur(8px);
}
#photo-close:hover {
    background: rgba(249,115,22,0.55);
    box-shadow: 0 0 25px rgba(249,115,22,0.5);
    transform: scale(1.1);
}
#photo-counter {
    font-family: var(--font-body);
    font-size: 0.82rem;
    letter-spacing: 0.12em;
    color: rgba(255,255,255,0.38);
    min-width: 56px;
    text-align: center;
}

/* --- Landing ----------------------------------------------- */
#landing {
    position: relative;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    gap: 8px;
    padding: 28px 20px 40px;
}

#landing-title {
    text-align: center;
    line-height: 1;
    flex-shrink: 0;
    margin-top: 20px;
}

#site-title {
    font-family: var(--font-headline);
    font-size: clamp(1.8rem, 5vw, 3.5rem);
    font-weight: 700;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    background: linear-gradient(90deg, var(--magenta), var(--orange), var(--gold), var(--cyan));
    background-size: 300% 100%;
    animation: fib-gradient 6s ease infinite;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

#site-subtitle {
    font-family: var(--font-body);
    font-size: clamp(0.65rem, 1.5vw, 0.85rem);
    color: rgba(255,255,255,0.4);
    letter-spacing: 0.35em;
    text-transform: uppercase;
    margin-top: 8px;
}

/* --- Molekül Navigation ------------------------------------ */
#molecule-nav {
    position: relative;
    width: min(90vh, 90vw);
    height: min(90vh, 90vw);
    flex-shrink: 0;
    z-index: 6;
    margin-top: 164px;
}

#molecule-img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    opacity: 0.65;
    filter: invert(1) brightness(2)
            drop-shadow(0 0 8px rgba(255,255,255,0.9))
            drop-shadow(0 0 20px rgba(200,220,255,0.6))
            drop-shadow(0 0 40px rgba(100,180,255,0.3));
}

/* Kategorie-Knoten */
.mol-node {
    position: absolute;
    left: var(--nx);
    top:  var(--ny);
    transform: translate(-50%, -50%);
    width: 62px;
    height: 62px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: none;
    box-shadow:
        0 0 16px rgba(249,115,22,0.5),
        0 0 40px rgba(249,115,22,0.25);
    opacity: 0.9;
    cursor: pointer;
    transition: all 0.3s ease;
    animation: node-pulse 3s ease-in-out infinite;
    animation-delay: calc(var(--ni, 0) * 0.3s);
    text-decoration: none;
    z-index: 2;
}
.mol-smiley {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
    opacity: 0.7;
    filter: drop-shadow(0 0 8px rgba(249,115,22,0.7));
}

.mol-node:hover {
    width: 76px;
    height: 76px;
    box-shadow:
        0 0 30px rgba(251,191,36,0.9),
        0 0 70px rgba(249,115,22,0.6),
        0 0 120px rgba(251,191,36,0.3);
}
.mol-node:hover .mol-smiley {
    filter: drop-shadow(0 0 14px rgba(251,191,36,1));
}


/* Label direkt am Knoten */
.mol-node::after {
    content: attr(data-name);
    position: absolute;
    left: 50%;
    top: calc(100% + 10px);
    transform: translateX(-50%);
    font-family: var(--font-headline);
    font-size: 0.85rem;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: rgba(255,255,255,0.85);
    white-space: nowrap;
    pointer-events: none;
    text-shadow:
        0 0 12px rgba(0,0,0,1),
        0 1px 4px rgba(0,0,0,1),
        0 0 30px rgba(249,115,22,0.4);
}
.mol-node:hover::after {
    color: var(--gold);
    text-shadow:
        0 0 12px rgba(0,0,0,1),
        0 0 20px rgba(251,191,36,0.8);
}

@keyframes node-pulse {
    0%, 100% {
        box-shadow: 0 0 16px rgba(249,115,22,0.8), 0 0 40px rgba(249,115,22,0.4), 0 0 80px rgba(249,115,22,0.15), inset 0 1px 2px rgba(255,255,255,0.3);
    }
    50% {
        box-shadow: 0 0 25px rgba(249,115,22,1), 0 0 60px rgba(249,115,22,0.6), 0 0 110px rgba(249,115,22,0.25), inset 0 1px 2px rgba(255,255,255,0.3);
    }
}

/* Tooltip */
#mol-tooltip {
    position: fixed;
    z-index: 100;
    background: rgba(5,5,16,0.9);
    border: 1px solid rgba(249,115,22,0.4);
    border-radius: 8px;
    padding: 8px 14px;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.15s;
    display: flex;
    flex-direction: column;
    gap: 2px;
    backdrop-filter: blur(8px);
}
#mol-tooltip.visible { opacity: 1; }
.tip-name {
    font-family: var(--font-headline);
    font-size: 0.85rem;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: var(--white);
}
.tip-count {
    font-family: var(--font-body);
    font-size: 0.65rem;
    color: rgba(255,255,255,0.4);
    letter-spacing: 0.1em;
}

/* --- Back button ------------------------------------------- */
#back-btn {
    position: fixed;
    top: 24px;
    left: 28px;
    z-index: 15;
    background: rgba(255,255,255,0.08);
    border: 1px solid rgba(255,255,255,0.2);
    color: rgba(255,255,255,0.7);
    padding: 8px 18px;
    border-radius: 30px;
    font-family: var(--font-body);
    font-size: 0.8rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    cursor: pointer;
    transition: all 0.25s;
    backdrop-filter: blur(6px);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 8px;
}
#back-btn:hover {
    background: rgba(249,115,22,0.2);
    border-color: rgba(249,115,22,0.5);
    color: var(--white);
}

/* --- Category label (vortex view) -------------------------- */
#cat-label {
    position: fixed;
    top: 24px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 15;
    font-family: var(--font-headline);
    font-size: clamp(0.9rem, 2.5vw, 1.4rem);
    letter-spacing: 0.25em;
    text-transform: uppercase;
    color: rgba(255,255,255,0.5);
    pointer-events: none;
}

/* --- Hint text --------------------------------------------- */
#hint {
    position: fixed;
    bottom: 28px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 15;
    font-size: 0.72rem;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: rgba(255,255,255,0.25);
    pointer-events: none;
    white-space: nowrap;
    animation: hint-fade 4s ease-in-out 2s both;
}
@keyframes hint-fade {
    0%   { opacity: 0; }
    20%  { opacity: 1; }
    80%  { opacity: 1; }
    100% { opacity: 0; }
}

/* --- NEH Back Button — oben rechts ------------------------- */
#neh-back-btn {
    position: fixed;
    top: 24px;
    right: 28px;
    z-index: 50;
    background: rgba(255,255,255,0.07);
    border: 1px solid rgba(255,255,255,0.18);
    color: rgba(255,255,255,0.55);
    padding: 8px 16px;
    border-radius: 30px;
    font-family: var(--font-body);
    font-size: 0.72rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    cursor: pointer;
    transition: all 0.25s;
    backdrop-filter: blur(6px);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 8px;
}
#neh-back-btn:hover {
    background: rgba(249,115,22,0.18);
    border-color: rgba(249,115,22,0.5);
    color: var(--white);
}

/* --- Hero Screen ------------------------------------------- */
#hero-screen {
    position: relative;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    gap: 0;
    padding-top: 37px;
    padding-bottom: 60px;
}

/* Regenbogen-Rahmen wrapper */
#hero-video-wrap {
    position: relative;
    width: min(96vw, 1092px);   /* 40% größer als original 780px */
    border-radius: 16px;
    padding: 3px;
    background: linear-gradient(90deg,
        #ff0000, #ff7700, #ffff00, #00ff00,
        #0099ff, #6600ff, #ff00cc, #ff0000);
    background-size: 300% 100%;
    animation: rainbow-border 4s linear infinite;
    flex-shrink: 0;
    box-shadow: 0 0 40px rgba(249,115,22,0.2), 0 0 80px rgba(255,0,204,0.1);
}
@keyframes rainbow-border {
    0%   { background-position: 0% 0%; }
    100% { background-position: 300% 0%; }
}
#hero-video {
    width: 100%;
    height: 555px;
    object-fit: cover;
    display: block;
    border-radius: 14px;
}

/* spiritbasel.png — über dem Video */
#hero-twentyyears {
    align-self: center;
    height: clamp(64px, 11.2vh, 144px);
    width: auto;
    opacity: 0.5;
    margin-top: 34px;
    margin-bottom: 12px;
    display: block;
}
#hero-logo-wrap {
    margin-top: 8px;
    margin-bottom: 63px;
    flex-shrink: 0;
    text-align: center;
}
#hero-logo {
    width: min(96vw, 1020px);
    height: auto;
    display: block;
    filter: drop-shadow(0 0 16px rgba(251,191,36,0.4)) drop-shadow(0 0 40px rgba(251,191,36,0.15)) drop-shadow(0 0 70px rgba(255,0,204,0.08));
}
#hero-date {
    font-family: var(--font-body);
    font-size: clamp(0.6rem, 1.3vw, 0.82rem);
    color: rgba(255,255,255,0.4);
    letter-spacing: 0.35em;
    text-transform: uppercase;
    margin-top: 10px;
}

/* Sound Button — Smiley, overlayed oben auf dem Video */
#sound-btn {
    position: absolute;
    top: 14px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 5;
    background: transparent;
    border: none;
    cursor: pointer;
    width: auto;
    padding: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 5px;
    transition: opacity 0.5s ease;
}
#sound-btn img {
    width: 52px;
    height: 52px;
    object-fit: contain;
    filter: drop-shadow(0 0 12px rgba(249,115,22,0.7));
    transition: filter 0.3s ease;
    animation: sound-pulse 2.5s ease-in-out infinite;
}
#sound-btn span {
    font-family: var(--font-body);
    font-size: 0.6rem;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: rgba(255,255,255,0.55);
    white-space: nowrap;
}
#sound-btn:hover img {
    filter: drop-shadow(0 0 22px rgba(249,115,22,1)) drop-shadow(0 0 40px rgba(255,0,204,0.5));
}
@keyframes sound-pulse {
    0%, 100% { filter: drop-shadow(0 0 6px rgba(249,115,22,0.4)); }
    50%       { filter: drop-shadow(0 0 18px rgba(249,115,22,0.9)); }
}



/* --- Mobile: Molekül-Nav zeigen, Grid verstecken --- */
#cat-grid { display: none !important; }

@media (max-width: 780px) {
    /* Hero Screen Höhe auf Mobile begrenzen, um das Loch zu schließen */
    #hero-screen {
        min-height: auto !important;
        padding-bottom: 0 !important;
    }

    /* Exakter Abstand von 44px zum nachfolgenden Textblock-Container */
    #hero-screen + div {
        margin-top: 44px !important;
    }

    /* Hero Video responsiv anpassen */
    #hero-video {
        height: 55vw;
        min-height: 220px;
        max-height: 400px;
    }

    /* Fibonacci Button verkleinern */
    #fibonacci-btn {
        width: 110px;
        height: 110px;
    }

    /* Smileys leicht vergrößern: von 0.5 auf 0.6 */
    .mol-node {
        transform: translate(-50%, -50%) scale(0.6) !important;
    }

    /* Molekül größer: von 1.15 auf 1.35 */
    #molecule-nav {
        display: block !important;
        margin-top: 160px !important;
        width: 100vw;
        height: 100vw;
        max-width: 500px;
        max-height: 500px;
        transform: scale(1.35);
        transform-origin: top center;
    }

    /* Mobile Positionskorrekturen der Smileys (Desktop bleibt unangetastet) */
    a[href="?cat=tuneout"]            { --ny: calc(8% - 56px) !important; }
    a[href="?cat=fixecam"]            { --nx: calc(48% - 30px) !important; --ny: calc(2% - 23px) !important; }
    a[href="?cat=freitag-start"]      { --nx: calc(95% - 184px) !important; --ny: calc(30% - 25px) !important; }
    a[href="?cat=akasha"]             { --nx: calc(8% + 275px) !important; --ny: calc(58% - 148px) !important; }
    a[href="?cat=freitag-referenten"] { --nx: calc(90% - 52px) !important; }
    a[href="?cat=lsd-interview"]      { --nx: calc(5% + 124px) !important; --ny: calc(30% + 78px) !important; }
    a[href="?cat=samstag"]            { --nx: calc(25% + 41px) !important; --ny: calc(82% - 50px) !important; }
    a[href="?cat=konzert"]            { --nx: calc(72% + 23px) !important; --ny: calc(82% + 20px) !important; }
    a[href="?cat=guruguru"]           { --nx: calc(48% + 13px) !important; --ny: calc(94% - 7px) !important; }
    a[href="?cat=tunein"]             { --nx: calc(78% - 237px) !important; --ny: calc(8% + 114px) !important; }
}

/* --- Galerie-Spezialsteuerungen --- */

/* Standardmäßig (Desktop) verstecken wir den mobilen Originalgröße-Button */
.sg-orig-btn-mobile {
    display: none !important;
}

/* Auf Mobile zeigen wir ihn an */
@media (max-width: 780px) {
    .sg-orig-btn-mobile {
        display: flex !important;
    }
}

