/* ============================================
   MOBILE PERFORMANCE OPTIMIZATIONS
   Disable heavy GPU effects on mobile for smooth scrolling
   Created: 2024-12-26
   ============================================ */

/* Disable heavy effects on tablets and mobile */
@media (max-width: 768px) {
    /* Disable backdrop-filter - main cause of scrolling lag */
    .header__inner,
    .banner-ads,
    .search-box,
    .search-dropdown,
    .modal-content,
    .dropdown-menu,
    .cover-stat,
    .sidebar-card,
    .feed-sidebar,
    .activity-card {
        backdrop-filter: none !important;
        -webkit-backdrop-filter: none !important;
    }
    
    /* Disable particle effects and background animations */
    .bg-spot,
    .bg-spot--1,
    .bg-spot--2,
    .bg-spot--3,
    .particles,
    .particle,
    .scanlines {
        display: none !important;
        animation: none !important;
    }
    
    /* Simplify box-shadows */
    .header__link:hover,
    .header__link.active,
    .card:hover,
    .movie-card:hover {
        box-shadow: 0 4px 15px rgba(0,0,0,0.3) !important;
    }
    
    /* Disable complex hover animations */
    .header__link:hover i {
        transform: none !important;
        filter: none !important;
        animation: none !important;
    }
    
    .header__link:hover span {
        animation: none !important;
        background: transparent !important;
        -webkit-text-fill-color: inherit !important;
    }
    
    /* Force hardware acceleration for smooth scrolling */
    body,
    .main,
    html {
        -webkit-overflow-scrolling: touch;
    }
    
    /* Simplify header on mobile */
    .header.scrolled .header__inner {
        backdrop-filter: none !important;
        background: rgba(10, 6, 8, 0.98) !important;
    }
    
    /* Reduce filter effects */
    .profile-cover img.cover-bg {
        filter: brightness(0.6) !important;
        animation: none !important;
        transform: none !important;
    }
    
    /* Disable cover zoom animation */
    @keyframes coverZoom {
        0%, 100% { transform: none; }
    }
}

/* Extra small devices - aggressive optimization */
@media (max-width: 480px) {
    /* Reduce all animation durations */
    *, *::before, *::after {
        animation-duration: 0.15s !important;
        transition-duration: 0.15s !important;
    }
    
    /* Hide decorative background effects */
    .bg-layer::after,
    .bg-layer::before {
        opacity: 0 !important;
    }
    
    /* Disable transforms on hover */
    .header__link:hover,
    .card:hover,
    .movie-card:hover,
    a:hover {
        transform: none !important;
    }
    
    /* Simpler shadows */
    * {
        text-shadow: none !important;
    }
}

/* Respect user's reduced motion preference */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
    
    .bg-spot,
    .particles,
    .particle,
    .scanlines,
    .bg-layer::after,
    .bg-layer::before {
        display: none !important;
    }
}
