/* 
 * Mobile Critical CSS - Above-the-fold styles
 * Moved from mobile.blade.php for better organization
 */

/* Critical mobile styles for above-the-fold content */
/* Note: Typography (font-size, line-height) moved to mobile-ux-improvements.css to avoid duplicates */
body { 
    margin: 0; 
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif; 
    letter-spacing: 0.2px; 
}

.header { 
    height: 60px; 
    background: #fff; 
    box-shadow: 0 2px 4px rgba(0,0,0,0.1); 
}

.hero-section { 
    min-height: 50vh; 
    background: linear-gradient(135deg, #f5f5f5 0%, #e8e8e8 100%); 
}

.container { 
    max-width: 100%; 
    /* Note: Padding moved to mobile-ux-improvements.css to avoid duplicates */
}

/* LCP Optimization - Critical Image Styles */
.lcp-image { 
    width: 100%; 
    height: auto; 
    max-width: 100%; 
}

.lcp-container { 
    position: relative; 
    width: 100%; 
}

.lcp-container img { 
    width: 100%; 
    height: auto; 
    object-fit: cover; 
}

/* LCP Optimization - News Article Images */
.news-image { 
    width: 100%; 
    height: auto; 
    max-width: 412px; 
    max-height: 266px; 
    object-fit: cover; 
}

.news-container { 
    position: relative; 
    width: 100%; 
    max-width: 412px; 
}

/* LCP Optimization - Hero Images */
.hero-image { 
    width: 100%; 
    height: auto; 
    max-width: 100%; 
    object-fit: cover; 
}

.hero-container { 
    position: relative; 
    width: 100%; 
}

/* TASK 2: CLS Prevention - Image Stability with explicit dimensions */
img { 
    max-width: 100%; 
    height: auto; 
    aspect-ratio: attr(width) / attr(height);
    display: block; /* Prevent inline spacing issues */
}

.img-container { 
    position: relative; 
    overflow: hidden; 
    width: 100%;
}

.img-container::before { 
    content: ''; 
    display: block; 
    padding-top: 56.25%; /* 16:9 aspect ratio */
}

.img-container img { 
    position: absolute; 
    top: 0; 
    left: 0; 
    width: 100%; 
    height: 100%; 
    object-fit: cover; 
}

/* TASK 2: CLS Prevention - Reserve space for featured images */
.news-featured-image-mobile {
    aspect-ratio: 16/9;
    width: 100%;
    position: relative;
    overflow: hidden;
    background: #f0f0f0;
}

.news-featured-image-mobile img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* CLS Prevention - City Gallery */
.city-gallery { 
    min-height: 200px; 
}

.city-gallery .row { 
    min-height: 200px; 
}

.city-gallery .col { 
    min-height: 200px; 
}

.city-gallery img { 
    width: 100%; 
    height: 200px; 
    object-fit: cover; 
}

/* CLS Prevention - Places Around City */
.places-around-city-section { 
    min-height: 300px; 
}

.places-around-city-section .container { 
    min-height: 300px; 
}

/* CLS Prevention - Festivals Section */
.festivals-section { 
    min-height: 250px; 
}

.festivals-section .container { 
    min-height: 250px; 
}

/* TASK 2: CLS Prevention - Reserve space for ads to prevent layout shifts */
.ad-container { 
    min-height: 250px; 
    background: #f5f5f5; 
    display: flex; 
    align-items: center; 
    justify-content: center; 
    width: 100%;
    position: relative;
}

.ad-container::before { 
    content: 'Advertisement'; 
    color: #999; 
    font-size: 12px; 
}

/* Reserve space for common ad sizes */
.ad-container[data-ad-size="300x250"] { 
    min-height: 250px; 
    width: 100%; 
    max-width: 300px; 
    margin: 0 auto; 
}

.ad-container[data-ad-size="320x50"] { 
    min-height: 50px; 
    width: 100%; 
    max-width: 320px; 
    margin: 0 auto; 
}

.ad-container[data-ad-size="728x90"] { 
    min-height: 90px; 
    width: 100%; 
    max-width: 728px; 
    margin: 0 auto; 
}

/* LCP Optimization - Loading States */
.loading-skeleton { 
    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; } 
}

/* LCP Optimization - Critical Text */
.critical-text { 
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif; 
    font-weight: 400; 
    line-height: 1.4; 
}

.critical-heading { 
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif; 
    font-weight: 700; 
    line-height: 1.2; 
}

.btn { 
    display: inline-block; 
    padding: 12px 24px; 
    background: #FF6B35; 
    color: white; 
    text-decoration: none; 
    border-radius: 4px; 
}

.loading { 
    display: none; 
}

@media (max-width: 768px) {
    /* Note: Container padding moved to mobile-ux-improvements.css to avoid duplicates */
    
    .hero-section { 
        min-height: 40vh; 
    }
    
    .city-gallery { 
        min-height: 150px; 
    }
    
    .city-gallery .col { 
        min-height: 150px; 
    }
    
    .city-gallery img { 
        height: 150px; 
    }
    
    .places-around-city-section { 
        min-height: 250px; 
    }
    
    .festivals-section { 
        min-height: 200px; 
    }
    
    .news-image { 
        max-width: 100%; 
        max-height: 200px; 
    }
    
    .lcp-image { 
        max-width: 100%; 
    }
}

