/* Performance Optimization Styles */

/* Lazy Loading Implementation */
.lazy {
    opacity: 0;
    transition: opacity 0.3s;
}

.lazy-loaded {
    opacity: 1;
}

/* Video Lazy Loading */
.lazy-video {
    background-color: #1a1a1a;
    min-height: 200px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.5s ease-in-out;
}

.lazy-video::before {
    content: "Loading video...";
    color: rgba(255, 255, 255, 0.6);
    font-size: 14px;
    position: absolute;
    z-index: 1;
}

.lazy-video.loaded::before {
    display: none;
}

/* Video poster optimization */
.lazy-video[poster] {
    background-image: none;
}

.lazy-video[poster]::before {
    display: none;
}

/* Responsive video loading */
@media (max-width: 768px) {
    .lazy-video {
        min-height: 300px;
    }
    
    .lazy-video::before {
        font-size: 12px;
    }
}

/* Reduce font loading impact */
.font-loading {
    font-display: swap;
    font-family: system-ui, -apple-system, sans-serif;
}

/* Critical CSS for above-the-fold content */
.hero-section {
    min-height: 100vh;
    background-color: #000;
    position: relative;
}

.hero-video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: -1;
}

/* Optimize animations */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}