/**
 * Lazy Ads Loader Styles
 * Loading placeholder and spinner for lazy-loaded advertisements
 */

/* Advertisement Label */
.ad-label-wrapper {
    width: 100%;
    text-align: center;
    margin-bottom: 8px;
}

.ad-label {
    margin: 0;
    padding: 0;
    font-size: 10px;
    line-height: 0.8;
    color: #999;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 400;
    font-family: var(--vr-font-secondary);
}

/* Ad Loading Placeholder */
.ad-loading-placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 8px;
    transition: opacity 0.3s ease;
    width: 100%;
    text-align: center;
    text-transform: uppercase;
    font-family: var(--vr-font-secondary);
}

/* Loading Spinner */
.ad-spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #e0e0e0;
    border-top: 4px solid #667eea;
    border-radius: 50%;
    animation: ad-spin 1s linear infinite;
    margin-bottom: 12px;
}

@keyframes ad-spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Loading Text */
.ad-loading-text {
    margin: 0;
    font-size: 13px;
    color: #666;
    font-weight: 500;
    letter-spacing: 0.3px;
}

/* Ad Content Wrapper */
.ad-content-wrapper {
    opacity: 0;
    transition: opacity 0.5s ease;
}

.ad-content-wrapper.loaded {
    opacity: 1;
}

/* Lazy Ad Container */
.lazy-ad-container {
    position: relative;
    min-height: 100px;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .ad-loading-placeholder {
        padding: 30px 15px;
        min-height: 100px;
    }
    
    .ad-spinner {
        width: 35px;
        height: 35px;
        border-width: 3px;
    }
    
    .ad-loading-text {
        font-size: 12px;
    }
}

/* Sidebar ads - smaller placeholder */
.bn-sidebar-content .ad-loading-placeholder {
    min-height: 80px;
    padding: 25px 15px;
}

.bn-sidebar-content .ad-spinner {
    width: 30px;
    height: 30px;
}

/* Header ads - wider placeholder */
.container-bn-header .ad-loading-placeholder {
    min-height: 90px;
}

/* Smooth fade-in animation */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.ad-content-wrapper {
    animation: fadeIn 0.5s ease-out;
}

/* Loading state variations */
.ad-loading-placeholder.loading {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
}

@keyframes shimmer {
    0% {
        background-position: -200% 0;
    }
    100% {
        background-position: 200% 0;
    }
}


/* Accessibility - reduce motion */
@media (prefers-reduced-motion: reduce) {
    .ad-spinner {
        animation: none;
        border-top-color: #667eea;
    }
    
    .ad-content-wrapper {
        animation: none;
    }
    
    .ad-loading-placeholder {
        animation: none;
    }
}
