/* Neon glow effect for the floating wizard ball */
.wizard-ball {
    box-shadow: 0 0 15px rgba(0, 255, 255, 0.8);
}

/* Cyber Wizard Navbar Styles */
.typing-text {
    display: inline-block;
    overflow: hidden;
    border-right: 2px solid cyan;
    white-space: nowrap;
    animation: typing 3.5s steps(40, end) infinite, blink-caret 0.75s step-end infinite;
}

@keyframes typing {
    0%, 100% { width: 0 }
    50% {opacity: 1}
}

@keyframes blink-caret {
    from, to { border-color: transparent }
    50% { border-color: cyan }
}

.animate-blink {
    animation: blink 1s step-end infinite;
}

@keyframes blink {
    0%, 100% { opacity: 1 }
    50% { opacity: 0 }
}

/* VS Code-inspired typing animation */
.typing-animation {
    display: inline-block;
    position: relative;
    white-space: nowrap;
}

.typing-cursor {
    position: absolute;
    right: -0.15em;
    animation: blink 1s step-end infinite;
}

@keyframes blink {
    0%, 100% { opacity: 1 }
    50% { opacity: 0 }
}

/* Responsive adjustments */
@media (max-width: 640px) {
    .typing-animation,
    .typing-cursor {
        display: none;
    }
}

/* Holographic Navigation Items */
.nav-hologram {
    position: relative;
    padding: 0.5rem 1rem;
    color: #7dd3fc;
    font-family: 'Courier New', monospace;
    text-transform: uppercase;
    font-size: 0.85rem;
    letter-spacing: 0.05em;
    border-radius: 4px;
    overflow: hidden;
    transition: all 0.3s ease;
    background: rgba(8, 47, 73, 0.3);
    border: 1px solid rgba(125, 211, 252, 0.2);
}

.nav-hologram:hover {
    color: #bae6fd;
    text-shadow: 0 0 8px rgba(187, 247, 255, 0.6);
    background: rgba(8, 47, 73, 0.5);
    border-color: rgba(125, 211, 252, 0.4);
    transform: translateY(-2px);
}



/* Arcane Orb Mobile Menu Button */
.arcane-orb {
    position: relative;
    background: radial-gradient(
        circle at 35% 35%,
        rgba(20, 184, 166, 0.8) 0%,
        rgba(6, 78, 59, 0.8) 70%,
        transparent 90%
    );
    box-shadow: 0 0 15px rgba(16, 185, 129, 0.6),
                0 0 30px rgba(6, 182, 212, 0.4),
                inset 0 0 10px rgba(255, 255, 255, 0.2);
    border: 1px solid rgba(110, 231, 183, 0.4);
    transition: all 0.3s ease;
}

.arcane-orb:hover {
    box-shadow: 0 0 20px rgba(16, 185, 129, 0.8),
                0 0 40px rgba(6, 182, 212, 0.6),
                inset 0 0 15px rgba(255, 255, 255, 0.3);
    transform: scale(1.05);
}

.orb-core {
    position: absolute;
    width: 8px;
    height: 8px;
    background: white;
    border-radius: 50%;
    filter: blur(1px);
    box-shadow: 0 0 5px white,
                0 0 10px cyan;
    animation: pulse 2s infinite alternate;
}

@keyframes pulse {
    0% { transform: scale(1); opacity: 0.8; }
    100% { transform: scale(1.3); opacity: 1; }
}

.orb-rings {
    position: absolute;
    width: 100%;
    height: 100%;
}

.orb-rings .ring {
    position: absolute;
    border: 1px solid rgba(110, 231, 183, 0.6);
    border-radius: 50%;
    animation: rotate infinite linear;
}

.orb-rings .ring-1 {
    width: 80%;
    height: 80%;
    top: 10%;
    left: 10%;
    animation-duration: 8s;
}

.orb-rings .ring-2 {
    width: 60%;
    height: 60%;
    top: 20%;
    left: 20%;
    animation-duration: 12s;
    animation-direction: reverse;
}

.orb-rings .ring-3 {
    width: 40%;
    height: 40%;
    top: 30%;
    left: 30%;
    animation-duration: 15s;
}

@keyframes rotate {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.orb-icon {
    position: relative;
    z-index: 2;
}

/* Spell Tome Mobile Menu */
.spell-tome-pages {
    background: linear-gradient(
        to right,
        rgba(17, 24, 39, 0.9) 0%,
        rgba(17, 24, 39, 0.95) 50%,
        rgba(17, 24, 39, 0.9) 100%
    );
    position: relative;
    z-index: 2;
}

.tome-spine {
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 8px;
    background: linear-gradient(
        to bottom,
        #0f172a,
        #1e293b,
        #0f172a
    );
    border-right: 1px solid rgba(94, 234, 212, 0.3);
    box-shadow: 2px 0 5px rgba(0, 0, 0, 0.5);
}

/* Shared Footer Styles */
.terminal-footer, .terminal-footer-mobile {
    box-shadow: inset 0 0 10px rgba(94, 234, 212, 0.1);
}

.rune-button, .rune-button-mobile {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 50%;
    transition: all 0.3s ease;
}

.rune-button {
    background: rgba(30, 41, 59, 0.5);
    border: 1px solid rgba(94, 234, 212, 0.3);
}

.rune-button-mobile {
    background: rgba(30, 41, 59, 0.7);
    border: 1px solid rgba(94, 234, 212, 0.2);
}

.rune-button:hover, .rune-button-mobile:hover {
    background: rgba(94, 234, 212, 0.1);
    border-color: rgba(94, 234, 212, 0.5);
    transform: translateY(-2px);
}

/* Desktop Specific */
.magic-orb {
    background: radial-gradient(
        circle at center,
        rgba(94, 234, 212, 0.8) 0%,
        rgba(168, 85, 247, 0.6) 70%,
        transparent 90%
    );
    border: 1px solid rgba(167, 139, 250, 0.4);
    border-radius: 50%;
    box-shadow: 
        0 0 15px rgba(94, 234, 212, 0.6),
        0 0 30px rgba(168, 85, 247, 0.4);
    animation: pulse 3s infinite alternate;
}

/* Mobile Specific */
.terminal-footer-mobile {
    max-width: 200px;
    margin: 0 auto;
}

@keyframes pulse {
    0% { transform: scale(1); opacity: 0.8; }
    100% { transform: scale(1.05); opacity: 1; }
}

@keyframes pan {
    0% { background-position: 0% 0%; }
    100% { background-position: 100% 100%; }
}
.animate-pan { 
    animation: pan 60s linear infinite alternate; 
}

/* Add these to your existing CSS */

/* Fix for mobile menu */
#mobile-menu {
    transition: all 0.3s ease;
    transform-origin: top right;
}

#mobile-menu:not(.hidden) {
    display: block;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: scale(0.95); }
    to { opacity: 1; transform: scale(1); }
}

/* Fix for orb active state */
.arcane-orb.orb-active {
    box-shadow: 0 0 25px rgba(16, 185, 129, 1),
                0 0 50px rgba(6, 182, 212, 0.8),
                inset 0 0 20px rgba(255, 255, 255, 0.4);
}

/* Ensure typing animation container has proper dimensions */
.typing-animation {
    min-width: 120px; /* Adjust based on your longest text */
    display: inline-block;
    text-align: left;
}

/* Mobile specific fixes */
@media (max-width: 768px) {
    #mobile-menu {
        right: 1rem;
        width: calc(100% - 2rem);
        max-width: 280px;
    }
    
    .typing-animation {
        min-width: 80px;
    }
}

/* Scroll header styles */
#scroll-header {
    transform: translateY(-100%);
}

#scroll-header.visible {
    transform: translateY(0);
    display: block;
}

/* Main nav initially visible */
#main-nav {
    position: relative;
    transition: transform 0.3s ease;
}

/* When scroll header is visible, push main nav down */
#scroll-header.visible + #main-nav {
    transform: translateY(60px);
}

/* Typing animation */
.typing-animation {
    display: inline-block;
    position: relative;
    white-space: nowrap;
}

.typing-cursor {
    position: absolute;
    right: -0.15em;
    animation: blink 1s step-end infinite;
}

@keyframes blink {
    0%, 100% { opacity: 1 }
    50% { opacity: 0 }
}

/* Mobile menu fixes */
#mobile-menu {
    transition: all 0.3s ease;
    transform-origin: top right;
    display: none;
}

#mobile-menu.open {
    display: block;
    animation: fadeIn 0.3s ease;
    position: fixed;
}

@keyframes fadeIn {
    from { opacity: 0; transform: scale(0.95); }
    to { opacity: 1; transform: scale(1); }
}

.arcane-orb.active {
    box-shadow: 0 0 25px rgba(16, 185, 129, 1),
                0 0 50px rgba(6, 182, 212, 0.8),
                inset 0 0 20px rgba(255, 255, 255, 0.4);
}

/* Rest of your existing styles */
/* ... */