/* Performance and Layout Fixes */

/* Ensure standard cursor is visible */
body {
    cursor: auto !important;
}

/* Keep custom cursor but optimize it */
.cursor,
.cursor-follower {
    pointer-events: none !important;
    will-change: transform;
}

/* Disable magnetic link effect causing button movement */
.magnetic-link {
    transition: transform 0.2s ease !important;
}

.magnetic-link:hover {
    transform: translateY(-2px) !important;
}

/* Remove the magnetic effect JavaScript behavior */
.btn-primary,
.btn-secondary,
.work-link {
    position: relative !important;
    transform: none !important;
}

/* Stable button styles */
.hero-cta {
    display: flex;
    gap: 15px;
    justify-content: center;
    flex-wrap: wrap;
    margin-top: 30px;
}

.btn-primary,
.btn-secondary {
    position: relative !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    min-width: 160px !important;
    transition: all 0.2s ease !important;
}

.btn-primary:hover,
.btn-secondary:hover {
    transform: translateY(-2px) !important;
    box-shadow: 0 10px 25px rgba(0,0,0,0.2) !important;
}

/* Fix the thick black banners around stats */
.stats-section {
    background: linear-gradient(180deg, transparent, rgba(102, 126, 234, 0.03), transparent) !important;
    padding: 80px 20px !important;
    margin: 0 !important;
    border: none !important;
}

.stats-section::before,
.stats-section::after {
    display: none !important;
}

/* Center hero content properly */
.hero-text {
    text-align: center !important;
    width: 100% !important;
}

.hero-subtitle {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 100%;
}

.typewriter {
    display: flex !important;
    justify-content: center !important;
    width: 100% !important;
    font-size: 2rem !important;
    font-weight: 500 !important;
}

.typewriter-text {
    font-size: inherit !important;
}

.hero-description {
    text-align: center !important;
    max-width: 800px !important;
    margin: 0 auto 40px !important;
}

/* Remove parallax effects that cause performance issues */
.parallax-text {
    display: none !important;
}

/* Optimize animations for performance */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* Mobile-specific fixes */
@media (max-width: 768px) {
    .hero-cta {
        flex-direction: column;
        align-items: center;
        padding: 0 20px;
    }
    
    .btn-primary,
    .btn-secondary {
        width: 100% !important;
        max-width: 300px !important;
        margin: 0 !important;
    }
    
    .hero-subtitle {
        margin-bottom: 20px !important;
    }
    
    .subtitle-prefix {
        font-size: 1.5rem !important;
    }
    
    .hero-description {
        font-size: 1rem !important;
        padding: 0 20px !important;
    }
    
    /* Fix stats grid */
    .stats-grid {
        grid-template-columns: repeat(3, 1fr) !important;
        gap: 20px !important;
        padding: 0 20px !important;
    }
    
    .stat-item {
        padding: 20px 10px !important;
    }
    
    .stat-number {
        font-size: 2rem !important;
    }
    
    .stat-label {
        font-size: 0.8rem !important;
    }
}

@media (max-width: 480px) {
    .stats-grid {
        grid-template-columns: repeat(3, 1fr) !important;
        gap: 15px !important;
    }
    
    .stat-item {
        padding: 15px 5px !important;
    }
    
    .stat-number {
        font-size: 1.5rem !important;
    }
}

/* Disable heavy visual effects */
.hero-background canvas,
#space-canvas {
    opacity: 0.3 !important;
}

/* Reduce animation complexity */
@keyframes float {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-10px);
    }
}

/* Simplify particle effects */
.stars-layer {
    animation: none !important;
    opacity: 0.5 !important;
}