/* Lazy Loading Visual Enhancements */

/* Smooth fade-in for images */
img[loading="lazy"] {
    opacity: 1; /* Start visible */
    transition: opacity 0.3s ease-in-out;
}

img[loading="lazy"].loaded {
    opacity: 1;
}

/* Loading placeholder */
img[loading="lazy"]:not(.loaded) {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: loading 1.5s infinite;
}

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

/* Error state */
img[data-error="true"] {
    display: none;
}

/* Responsive images */
img {
    max-width: 100%;
    height: auto;
    display: block;
    margin: 1rem auto;
}

/* Gallery images */
.post-body img {
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

/* Featured images */
.post-head-wrapper img {
    border-radius: 0;
    box-shadow: none;
} 