/* Mobile Performance Optimizations */

/* Reduce animations on mobile for better performance */
@media (max-width: 768px) {
    * {
        animation-duration: 0.3s !important;
        transition-duration: 0.2s !important;
    }
    
    /* Disable complex animations on mobile */
    .hover-lift,
    .hover-tilt,
    .service-card-3d,
    .portfolio-card-3d,
    .blog-card-3d {
        transform: none !important;
    }
    
    /* Optimize backdrop filters for mobile */
    .glass-card,
    .glass-card-dark,
    .glass-card-light {
        backdrop-filter: blur(10px) !important;
    }
    
    /* Reduce box shadows for better performance */
    .card-luxury,
    .admin-card,
    .stat-card {
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1) !important;
    }
    
    /* Optimize images for mobile */
    img {
        image-rendering: optimizeSpeed;
        image-rendering: -webkit-optimize-contrast;
    }
    
    /* Reduce gradient complexity */
    .brand-gradient-text {
        background: var(--brand-lime) !important;
        -webkit-background-clip: unset !important;
        -webkit-text-fill-color: unset !important;
        color: var(--brand-lime) !important;
    }
}

/* Touch optimizations */
@media (hover: none) and (pointer: coarse) {
    /* Remove hover effects on touch devices */
    .hover-lift:hover,
    .hover-tilt:hover,
    .hover-glow:hover,
    .hover-scale:hover {
        transform: none !important;
        box-shadow: inherit !important;
    }
    
    /* Optimize touch targets */
    .btn,
    .nav-link,
    .mobile-nav-link {
        min-height: 44px;
        min-width: 44px;
        padding: 12px 16px;
    }
    
    /* Improve form controls for touch */
    .form-control,
    .form-select {
        min-height: 48px;
        font-size: 16px; /* Prevents zoom on iOS */
    }
}

/* Reduce motion for users who prefer it */
@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;
    }
    
    .floating-actions {
        animation: none !important;
    }
    
    .brand-gradient-text {
        animation: none !important;
    }
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    :root {
        --brand-text: #FFFFFF !important;
        --brand-text-muted: #CCCCCC !important;
        --brand-lime: #FFFF00 !important;
    }
    
    .glass-card,
    .glass-card-dark,
    .glass-card-light {
        background: #000000 !important;
        border: 2px solid #FFFFFF !important;
    }
}

/* Dark mode preference */
@media (prefers-color-scheme: dark) {
    /* Already optimized for dark theme */
}

/* Print optimizations */
@media print {
    .floating-actions,
    .mobile-menu-overlay,
    .hamburger-menu,
    .navbar,
    footer {
        display: none !important;
    }
    
    body {
        background: white !important;
        color: black !important;
    }
    
    .glass-card,
    .admin-card,
    .card-luxury {
        background: white !important;
        border: 1px solid #ccc !important;
        box-shadow: none !important;
    }
}