/* monopole.boo — Fairycore bioluminescent ghost laboratory */

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

html {
    scroll-behavior: smooth;
}

body {
    background-color: #0A0612;
    color: #B8A9C8;
    font-family: 'Nunito', sans-serif;
    font-weight: 300;
    font-size: 17px;
    line-height: 1.8;
    overflow-x: hidden;
    min-height: 100vh;
}

/* ===== Bioluminescent Orbs ===== */
#orb-layer {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
}

.orb {
    position: absolute;
    border-radius: 50%;
    background: radial-gradient(circle at center, #7DF9FF 0%, rgba(125, 249, 255, 0.15) 40%, transparent 70%);
    opacity: 0;
    animation: orbFloat 6s ease-in-out infinite, orbPulse 4s ease-in-out infinite;
}

.orb-1 {
    width: 200px; height: 200px;
    top: 40%; left: 50%;
    opacity: 0.25;
    animation-delay: 0s, 0s;
}
.orb-2 {
    width: 120px; height: 120px;
    top: 20%; left: 25%;
    opacity: 0.20;
    animation-delay: -1.5s, -0.8s;
}
.orb-3 {
    width: 80px; height: 80px;
    top: 65%; left: 70%;
    opacity: 0.15;
    animation-delay: -3s, -1.6s;
}
.orb-4 {
    width: 160px; height: 160px;
    top: 80%; left: 15%;
    opacity: 0.18;
    animation-delay: -2s, -2.4s;
}
.orb-5 {
    width: 60px; height: 60px;
    top: 30%; left: 80%;
    opacity: 0.30;
    animation-delay: -4s, -0.4s;
}
.orb-6 {
    width: 140px; height: 140px;
    top: 55%; left: 40%;
    opacity: 0.15;
    animation-delay: -1s, -3s;
}
.orb-7 {
    width: 40px; height: 40px;
    top: 10%; left: 60%;
    opacity: 0.35;
    animation-delay: -5s, -1.2s;
}

@keyframes orbFloat {
    0%, 100% { transform: translateY(-8px); }
    50% { transform: translateY(8px); }
}

@keyframes orbPulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.15); }
}

/* Combined animation for orbs: float + pulse */
.orb {
    animation: orbCombined 6s ease-in-out infinite;
}

@keyframes orbCombined {
    0% { transform: translateY(-8px) scale(1); }
    25% { transform: translateY(0px) scale(1.08); }
    50% { transform: translateY(8px) scale(1.15); }
    75% { transform: translateY(0px) scale(1.08); }
    100% { transform: translateY(-8px) scale(1); }
}

/* ===== Particle Trails ===== */
#particle-layer {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 2;
}

.particle {
    position: absolute;
    border-radius: 50%;
    background: #7DF9FF;
    opacity: 0.4;
    animation: particleRise linear infinite;
}

@keyframes particleRise {
    0% { transform: translateY(0) scale(1); opacity: 0.4; }
    100% { transform: translateY(-100vh) scale(0.3); opacity: 0; }
}

/* ===== Spectral Navigation ===== */
#spectral-nav {
    position: fixed;
    top: 32px;
    left: 32px;
    z-index: 1000;
}

.nav-trigger {
    width: 20px;
    height: 20px;
    cursor: pointer;
    position: relative;
}

.nav-glow-dot {
    display: block;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #7DF9FF;
    box-shadow: 0 0 12px #7DF9FF, 0 0 24px rgba(125, 249, 255, 0.3);
    position: absolute;
    top: 6px;
    left: 6px;
}

.nav-links {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-top: 16px;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.5s ease;
}

#spectral-nav:hover .nav-links {
    opacity: 1;
    pointer-events: auto;
}

.ghost-link {
    font-family: 'Inconsolata', monospace;
    font-size: 13px;
    color: #E8D5F5;
    text-decoration: none;
    opacity: 0;
    transform: translateX(-10px);
    transition: opacity 0.4s ease, transform 0.4s ease, color 0.3s ease;
}

#spectral-nav:hover .ghost-link:nth-child(1) { opacity: 0.8; transform: translateX(0); transition-delay: 0s; }
#spectral-nav:hover .ghost-link:nth-child(2) { opacity: 0.8; transform: translateX(0); transition-delay: 0.4s; }
#spectral-nav:hover .ghost-link:nth-child(3) { opacity: 0.8; transform: translateX(0); transition-delay: 0.8s; }

.ghost-link:hover {
    color: #FF6EC7;
}

/* ===== Hero Section ===== */
#hero {
    height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: relative;
    z-index: 10;
}

.hero-title {
    font-family: 'Cormorant Garamond', Georgia, serif;
    font-weight: 300;
    font-size: 64px;
    color: #E8D5F5;
    letter-spacing: 0.12em;
    opacity: 0;
}

.hero-title.visible {
    opacity: 1;
}

.hero-title .letter {
    display: inline-block;
    opacity: 0;
    transition: opacity 0.4s ease;
}

.hero-title .letter.show {
    opacity: 1;
}

.hero-subtitle {
    font-family: 'Inconsolata', monospace;
    font-size: 15px;
    color: #B8A9C8;
    letter-spacing: 0.06em;
    margin-top: 20px;
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.hero-subtitle.visible {
    opacity: 0.7;
    transform: translateY(0);
}

/* ===== Content Sections ===== */
.content-section {
    position: relative;
    z-index: 10;
    padding: 0 15%;
    margin-bottom: 120px;
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94), transform 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.content-section.in-view {
    opacity: 1;
    transform: translateY(0);
}

.drift-left {
    padding-left: 10%;
    padding-right: 20%;
}

.drift-right {
    padding-left: 20%;
    padding-right: 10%;
}

/* Ghost Panel — Glassmorphic */
.ghost-panel {
    background: rgba(26, 16, 40, 0.4);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    padding: 48px;
    transition: border-color 0.5s ease, box-shadow 0.5s ease;
}

.ghost-panel:hover {
    border-color: rgba(255, 255, 255, 0.2);
    box-shadow: inset 0 0 30px rgba(125, 249, 255, 0.05);
}

.section-title {
    font-family: 'Cormorant Garamond', Georgia, serif;
    font-weight: 300;
    font-size: 36px;
    color: #E8D5F5;
    letter-spacing: 0.12em;
    margin-bottom: 24px;
}

.body-text {
    color: #B8A9C8;
    margin-bottom: 16px;
}

.body-text.muted {
    opacity: 0.65;
}

.annotation {
    display: block;
    font-family: 'Inconsolata', monospace;
    font-size: 13px;
    color: #7DF9FF;
    margin-top: 24px;
    opacity: 0.6;
}

/* ===== Sonar Rings ===== */
.sonar-ring {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 100px;
    height: 100px;
    border-radius: 50%;
    border: 1px solid rgba(232, 213, 245, 0.05);
    transform: translate(-50%, -50%) scale(1);
    animation: sonarExpand 8s ease-out infinite;
    pointer-events: none;
}

@keyframes sonarExpand {
    0% { transform: translate(-50%, -50%) scale(1); opacity: 0.05; }
    100% { transform: translate(-50%, -50%) scale(3); opacity: 0; }
}

/* ===== Fog Layers ===== */
.fog {
    position: fixed;
    border-radius: 50%;
    pointer-events: none;
    z-index: 0;
}

.fog-1 {
    width: 60vw;
    height: 60vw;
    top: -20%;
    left: -15%;
    background: radial-gradient(circle, #1A1028 0%, transparent 70%);
    opacity: 0.6;
}

.fog-2 {
    width: 50vw;
    height: 50vw;
    bottom: -10%;
    right: -10%;
    background: radial-gradient(circle, #3D1F6D 0%, transparent 70%);
    opacity: 0.3;
}

.fog-3 {
    width: 40vw;
    height: 40vw;
    top: 40%;
    left: 50%;
    background: radial-gradient(circle, #1A1028 0%, transparent 70%);
    opacity: 0.4;
}

/* ===== Mobile ===== */
@media (max-width: 768px) {
    .hero-title {
        font-size: 40px;
    }

    .section-title {
        font-size: 28px;
    }

    .drift-left,
    .drift-right {
        padding-left: 6%;
        padding-right: 6%;
    }

    .ghost-panel {
        padding: 28px;
    }

    .content-section {
        margin-bottom: 80px;
    }
}
