/* ============================================
   GZ ULTIMATE CINEMATIC LOOP (6s Cycle)
   "Final Polish: 3D Tilt, Enhanced Glow, Burst"
   ============================================ */

.gz-logo-container {
    position: relative;
    width: 600px;
    height: 300px;
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 0 auto;
    /* Removed drop-shadow for perf */
    /* Slightly reduced for perf */
    perspective: 1000px;
    /* Enable 3D space */
    transform-style: preserve-3d;

    /* Hardware Acceleration */
}

.gz-animated-logo {
    width: 100%;
    height: 100%;
    overflow: visible;
    z-index: 10;
    /* Subtle 3D Tilt Animation */
    animation: floatingTilt 8s ease-in-out infinite;

    /* Hardware Acceleration */
}

@keyframes floatingTilt {

    0%,
    100% {
        transform: rotateX(0deg) rotateY(0deg) translateY(0);
    }

    25% {
        transform: rotateX(5deg) rotateY(3deg) translateY(-10px);
    }

    50% {
        transform: rotateX(0deg) rotateY(0deg) translateY(-5px);
    }

    75% {
        transform: rotateX(-5deg) rotateY(-3deg) translateY(0px);
    }
}

/* ============================================
   TEXT ANIMATION (6s Cycle)
   Refined for deeper impact
   ============================================ */
.gz-text {
    font-family: 'Orbitron', sans-serif;
    font-weight: 900;
    font-size: 180px;
    letter-spacing: 12px;
    /* Slightly wider */

    /* Base State */
    fill: transparent;
    stroke: url(#textGradient);
    stroke-width: 3px;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-dasharray: 1000;
    stroke-dashoffset: 1000;

    /* 6s Infinite Loop */
    animation: compactTextLoop 6s cubic-bezier(0.4, 0, 0.2, 1) infinite;

    /* Hardware Acceleration */
}

@keyframes compactTextLoop {

    /* ENTRANCE: Snap to center -> Draw -> Fill */
    0% {
        opacity: 0;
        transform: scale(0.98);
        stroke-dashoffset: 1000;
        fill: transparent;
        stroke-width: 3px;
        filter: drop-shadow(0 0 0px transparent);
    }

    10% {
        opacity: 1;
        transform: scale(1);
        stroke-dashoffset: 1000;
        filter: drop-shadow(0 0 0px transparent);
    }

    /* ... Draw Path ... */
    30% {
        stroke-dashoffset: 0;
        fill: transparent;
        stroke-width: 3px;
        filter: drop-shadow(0 0 0px transparent);
    }

    40% {
        fill: rgba(255, 255, 255, 1);
        stroke-width: 0;
        /* filter removed for perf */
    }

    /* HOLD */
    70% {
        fill: rgba(255, 255, 255, 1);
        stroke-width: 0;
        opacity: 1;
        transform: scale(1);
        /* filter removed for perf */
    }

    /* EXIT: STATIC FADE (No Slide, No Blur) */
    85% {
        opacity: 0.5;
        fill: transparent;
        stroke-width: 3px;
        stroke-dashoffset: 0;
        transform: scale(1);
        filter: drop-shadow(0 0 0px transparent);
    }

    100% {
        opacity: 0;
        stroke-dashoffset: 1000;
        fill: transparent;
        stroke-width: 3px;
        transform: scale(1);
    }
}

@keyframes dynamicIconLoop {

    /* ENTRANCE */
    0% {
        stroke-dashoffset: 100;
        fill: transparent;
        opacity: 0;
        transform: scale(0.5) rotate(-10deg);
    }

    20% {
        opacity: 1;
        transform: scale(1.1) rotate(0deg);
        stroke-dashoffset: 0;
    }

    40% {
        fill: currentColor;
        stroke-width: 0;
        filter: drop-shadow(0 0 15px currentColor);
    }

    /* HOLD */
    70% {
        fill: currentColor;
        stroke-width: 0;
        opacity: 1;
        transform: scale(1) rotate(0deg);
    }

    /* EXIT: STATIC FADE OUT (No Slide, No Spin, No Blur) */
    100% {
        stroke-dashoffset: 100;
        fill: transparent;
        opacity: 0;
        transform: scale(1) rotate(0deg);
    }
}

/* ============================================
   THE CELESTIAL ORBITALS - Phase 15
   "Floating, Ethereal, Magical"
   ============================================ */

.celestial-nodes {
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 15;
}

.celestial-node {
    position: absolute;
    width: 54px;
    height: 54px;
    pointer-events: all;
    cursor: pointer;
    z-index: 10;

    /* Hardware Acceleration */

    /* Cinematic GZ Sync */
    animation: celestialMasterLoop 6s cubic-bezier(0.4, 0, 0.2, 1) infinite;
}

.node-glass {
    position: relative;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3), 0 0 10px rgba(34, 211, 238, 0.08)
    /* Slightly optimized shadow */
    transition: transform 0.2s, opacity 0.2s, background-color 0.2s, border-color 0.2s;

    /* Hardware Acceleration */
}

.node-glass svg {
    width: 26px;
    height: 26px;
    fill: currentColor;
    /* shadow removed for perf */
    /* Reduced from 8px */
}

.node-aura {
    position: absolute;
    inset: -5px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(43, 80, 188, 0.15) 0%, transparent 70%);
    /* Reduced opacity */
    animation: nodeBreathe 3s ease-in-out infinite;
    z-index: -1;

    /* Hardware Acceleration */
}

.node-glass:hover {
    background: rgba(255, 255, 255, 0.15);
    border-color: #2b50bc;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3), 0 0 10px rgba(34, 211, 238, 0.08)
    transform: scale(1.15) rotate(5deg);
}

/* Master Loop: Entrance -> Orbit -> Static Fade */
@keyframes celestialMasterLoop {
    0% {
        opacity: 0;
        transform: scale(0.5);
    }

    15% {
        opacity: 1;
        transform: scale(1);
    }

    85% {
        opacity: 1;
        transform: scale(1);
    }

    100% {
        opacity: 0;
        transform: scale(0.9);
    }
}

@keyframes nodeBreathe {

    0%,
    100% {
        opacity: 0.3;
        transform: scale(1);
    }

    50% {
        opacity: 0.6;
        transform: scale(1.1);
    }
}

/* Individual Elliptical Orbits */
.cn-1 {
    top: 15%;
    left: 20%;
    animation: celestialMasterLoop 6s infinite, orbit1 12s ease-in-out infinite;
}

.cn-2 {
    top: 10%;
    right: 18%;
    animation: celestialMasterLoop 6s infinite, orbit2 14s ease-in-out infinite;
}

.cn-3 {
    bottom: 20%;
    left: 15%;
    animation: celestialMasterLoop 6s infinite, orbit3 13s ease-in-out infinite;
}

.cn-4 {
    bottom: 15%;
    right: 22%;
    animation: celestialMasterLoop 6s infinite, orbit4 15s ease-in-out infinite;
}

@keyframes orbit1 {

    0%,
    100% {
        transform: translate(0, 0);
    }

    25% {
        transform: translate(15px, -10px);
    }

    50% {
        transform: translate(30px, 5px);
    }

    75% {
        transform: translate(10px, 15px);
    }
}

@keyframes orbit2 {

    0%,
    100% {
        transform: translate(0, 0);
    }

    25% {
        transform: translate(-20px, 15px);
    }

    50% {
        transform: translate(-40px, -5px);
    }

    75% {
        transform: translate(-15px, -20px);
    }
}

@keyframes orbit3 {

    0%,
    100% {
        transform: translate(0, 0);
    }

    25% {
        transform: translate(25px, 20px);
    }

    50% {
        transform: translate(50px, -10px);
    }

    75% {
        transform: translate(15px, -15px);
    }
}

@keyframes orbit4 {

    0%,
    100% {
        transform: translate(0, 0);
    }

    25% {
        transform: translate(-10px, -25px);
    }

    50% {
        transform: translate(-30px, 10px);
    }

    75% {
        transform: translate(-5px, 20px);
    }
}

@keyframes hiEntrance {
    0% {
        opacity: 0;
        transform: scale(0.8);
    }

    25% {
        opacity: 1;
        transform: scale(1);
    }

    85% {
        opacity: 1;
        transform: scale(1);
    }

    100% {
        opacity: 0;
        transform: scale(1);
    }
}

@keyframes iconPulse {
    0% {
        transform: scale(1);
    }

    100% {
        transform: scale(1.15);
    }
}

/* ============================================
   BACKGROUND PARTICLES (Faster)
   ============================================ */
.particle-lines {
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: -1;
    opacity: 0.6;
}

.particle-line {
    position: absolute;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
    width: 0;
    opacity: 0;
    animation: fastStreak 3s infinite linear;

    /* Hardware Acceleration */
}

.pl-1 {
    top: 20%;
    left: -10%;
    animation-delay: 0s;
}

.pl-2 {
    top: 80%;
    right: -10%;
    animation-delay: 1.5s;
    transform: rotate(180deg);
}

.pl-3 {
    top: 50%;
    left: 10%;
    animation-delay: 0.8s;
    width: 100px;
    background: linear-gradient(90deg, transparent, #2b50bc, transparent);
}

.pl-4 {
    top: 30%;
    right: 20%;
    animation-delay: 2.2s;
    width: 80px;
    transform: rotate(180deg);
    background: linear-gradient(90deg, transparent, #a78bfa, transparent);
}

@keyframes fastStreak {
    0% {
        width: 0;
        opacity: 0;
        transform: translateX(0);
    }

    20% {
        width: 150px;
        opacity: 0.8;
    }

    100% {
        width: 0;
        opacity: 0;
        transform: translateX(800px);
    }
}

/* Responsive */
/* Responsive */
@media (max-width: 768px) {
    .gz-logo-container {
        width: 100%;
        height: 200px;
    }

    .gz-text {
        font-size: 100px;
        stroke-width: 2px;
        letter-spacing: 6px;
    }

    .celestial-node {
        width: 40px;
        height: 40px;
    }

    .node-glass svg {
        width: 18px;
        height: 18px;
    }
}

@media (max-width: 480px) {
    .gz-logo-container {
        height: 140px;
    }

    .gz-text {
        font-size: 70px;
        stroke-width: 1.5px;
        letter-spacing: 4px;
    }

    .celestial-node {
        width: 32px;
        height: 32px;
    }
}
