/*
* @Author: jeffb
* @Date:   2025-12-27 17:36:38
* @Last Modified by:   jeffb
* @Last Modified time: 2025-12-27 17:37:03
*/
/**
 * AZ.Coupons - Blog Images CSS
 * Styles for blog post images, thumbnails, and media elements
 */

/* ============================================
   Blog Featured Images
   ============================================ */

.blog-featured-image {
    width: 100%;
    height: auto;
    max-height: 400px;
    object-fit: cover;
    border-radius: 12px;
    margin-bottom: 1.5rem;
}

.blog-featured-image-wrapper {
    position: relative;
    overflow: hidden;
    border-radius: 12px;
    margin-bottom: 1.5rem;
    background: rgba(255, 255, 255, 0.05);
}

.blog-featured-image-wrapper::before {
    content: '';
    display: block;
    padding-top: 56.25%; /* 16:9 aspect ratio */
}

.blog-featured-image-wrapper img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* ============================================
   Blog Thumbnail Images
   ============================================ */

.blog-thumbnail {
    width: 100%;
    height: 180px;
    object-fit: cover;
    border-radius: 10px;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

.blog-thumbnail:hover {
    transform: scale(1.02);
    opacity: 0.9;
}

.blog-thumbnail-wrapper {
    position: relative;
    overflow: hidden;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.05);
    aspect-ratio: 16 / 9;
}

.blog-thumbnail-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.blog-thumbnail-wrapper:hover img {
    transform: scale(1.05);
}

/* ============================================
   Blog Card Images
   ============================================ */

.blog-card-image {
    width: 100%;
    height: 200px;
    object-fit: cover;
    border-radius: 12px 12px 0 0;
}

.blog-card .image-container {
    position: relative;
    overflow: hidden;
    border-radius: 12px 12px 0 0;
}

.blog-card .image-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(180deg, transparent 60%, rgba(0, 0, 0, 0.7) 100%);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.blog-card:hover .image-overlay {
    opacity: 1;
}

/* ============================================
   Blog Content Images
   ============================================ */

.blog-content img {
    max-width: 100%;
    height: auto;
    border-radius: 10px;
    margin: 1.5rem 0;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
}

.blog-content figure {
    margin: 2rem 0;
    text-align: center;
}

.blog-content figcaption {
    margin-top: 0.75rem;
    font-size: 0.875rem;
    color: rgba(255, 255, 255, 0.6);
    font-style: italic;
}

/* ============================================
   Blog Image Gallery
   ============================================ */

.blog-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin: 2rem 0;
}

.blog-gallery-item {
    position: relative;
    overflow: hidden;
    border-radius: 10px;
    aspect-ratio: 1;
    cursor: pointer;
}

.blog-gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.blog-gallery-item:hover img {
    transform: scale(1.1);
}

.blog-gallery-item::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.3);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.blog-gallery-item:hover::after {
    opacity: 1;
}

/* ============================================
   Blog Author Avatar
   ============================================ */

.blog-author-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid rgba(255, 255, 255, 0.2);
}

.blog-author-avatar-lg {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid rgba(87, 211, 255, 0.3);
}

/* ============================================
   Blog Category/City Images
   ============================================ */

.blog-city-image {
    width: 100%;
    height: 150px;
    object-fit: cover;
    border-radius: 10px;
    filter: brightness(0.7);
    transition: filter 0.3s ease;
}

.blog-city-image:hover {
    filter: brightness(0.9);
}

.blog-category-icon {
    width: 60px;
    height: 60px;
    padding: 15px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

/* ============================================
   Placeholder Images
   ============================================ */

.blog-image-placeholder {
    width: 100%;
    height: 200px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.03));
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    color: rgba(255, 255, 255, 0.4);
    font-size: 3rem;
}

.blog-image-placeholder.small {
    height: 120px;
    font-size: 2rem;
}

.blog-image-placeholder.large {
    height: 300px;
    font-size: 4rem;
}

/* ============================================
   Lazy Loading
   ============================================ */

.blog-image-lazy {
    opacity: 0;
    transition: opacity 0.5s ease;
}

.blog-image-lazy.loaded {
    opacity: 1;
}

.blog-image-loading {
    position: relative;
    background: rgba(255, 255, 255, 0.05);
}

.blog-image-loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 30px;
    height: 30px;
    margin: -15px 0 0 -15px;
    border: 3px solid rgba(255, 255, 255, 0.1);
    border-top-color: var(--az-accent, #57d3ff);
    border-radius: 50%;
    animation: blog-image-spin 1s linear infinite;
}

@keyframes blog-image-spin {
    to {
        transform: rotate(360deg);
    }
}

/* ============================================
   Responsive Adjustments
   ============================================ */

@media (max-width: 768px) {
    .blog-featured-image {
        max-height: 250px;
        border-radius: 8px;
    }
    
    .blog-thumbnail {
        height: 140px;
    }
    
    .blog-card-image {
        height: 160px;
    }
    
    .blog-gallery {
        grid-template-columns: repeat(2, 1fr);
        gap: 0.5rem;
    }
    
    .blog-author-avatar {
        width: 40px;
        height: 40px;
    }
    
    .blog-author-avatar-lg {
        width: 60px;
        height: 60px;
    }
}

@media (max-width: 480px) {
    .blog-featured-image {
        max-height: 180px;
    }
    
    .blog-thumbnail {
        height: 120px;
    }
    
    .blog-card-image {
        height: 140px;
    }
    
    .blog-gallery {
        grid-template-columns: 1fr;
    }
}

/* ============================================
   Dark Mode Enhancements (default for AZ.Coupons)
   ============================================ */

.blog-image-shadow {
    box-shadow: 0 15px 50px rgba(0, 0, 0, 0.4);
}

.blog-image-glow {
    box-shadow: 0 0 30px rgba(87, 211, 255, 0.2);
}

.blog-image-border {
    border: 1px solid rgba(255, 255, 255, 0.1);
}

/* ============================================
   Image Hover Effects
   ============================================ */

.blog-image-zoom {
    overflow: hidden;
    border-radius: 12px;
}

.blog-image-zoom img {
    transition: transform 0.5s ease;
}

.blog-image-zoom:hover img {
    transform: scale(1.1);
}

.blog-image-fade:hover {
    opacity: 0.85;
}

.blog-image-lift {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.blog-image-lift:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4);
}