/* AutoNews AI Publisher - Responsive Images CSS */

/* Ensure all AutoNews generated post images are full-width and responsive */
.autonews-post img,
.autonews-generated img,
.post-content img,
.single-post img {
    width: 100%;
    max-width: 100%;
    height: auto;
    display: block;
    margin: 20px 0;
}

/* Featured images - full width and responsive */
.autonews-post .post-thumbnail img,
.autonews-generated .post-thumbnail img {
    width: 100%;
    height: auto;
    object-fit: cover;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

/* Content images - responsive with proper spacing */
.autonews-post .post-content img,
.autonews-generated .post-content img {
    max-width: 100%;
    height: auto;
    margin: 20px auto;
    border-radius: 6px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

/* Mobile optimization */
@media (max-width: 768px) {
    .autonews-post .post-thumbnail img,
    .autonews-generated .post-thumbnail img {
        border-radius: 4px;
        margin-bottom: 15px;
    }
    
    .autonews-post .post-content img,
    .autonews-generated .post-content img {
        margin: 15px auto;
        border-radius: 4px;
    }
}

/* Tablet optimization */
@media (min-width: 769px) and (max-width: 1024px) {
    .autonews-post .post-thumbnail img,
    .autonews-generated .post-thumbnail img {
        max-height: 400px;
        object-fit: cover;
    }
}

/* Desktop optimization */
@media (min-width: 1025px) {
    .autonews-post .post-thumbnail img,
    .autonews-generated .post-thumbnail img {
        max-height: 500px;
        object-fit: cover;
    }
}

/* Semantic heading styles for AutoNews posts */
.autonews-post h1,
.autonews-generated h1 {
    font-size: 2.5em;
    line-height: 1.2;
    margin-bottom: 0.5em;
    color: #333;
}

.autonews-post h2,
.autonews-generated h2 {
    font-size: 1.8em;
    line-height: 1.3;
    margin: 1.5em 0 0.8em 0;
    color: #444;
    border-bottom: 2px solid #eee;
    padding-bottom: 0.3em;
}

.autonews-post h3,
.autonews-generated h3 {
    font-size: 1.4em;
    line-height: 1.4;
    margin: 1.2em 0 0.6em 0;
    color: #555;
}

/* Mobile heading adjustments */
@media (max-width: 768px) {
    .autonews-post h1,
    .autonews-generated h1 {
        font-size: 2em;
    }
    
    .autonews-post h2,
    .autonews-generated h2 {
        font-size: 1.5em;
        margin: 1.2em 0 0.6em 0;
    }
    
    .autonews-post h3,
    .autonews-generated h3 {
        font-size: 1.2em;
        margin: 1em 0 0.5em 0;
    }
}

/* Paragraph spacing for better readability */
.autonews-post p,
.autonews-generated p {
    margin-bottom: 1.2em;
    line-height: 1.6;
}

/* Source attribution styling */
.autonews-source {
    margin-top: 2em;
    padding: 15px;
    background: #f8f9fa;
    border-left: 4px solid #007cba;
    border-radius: 4px;
    font-size: 0.9em;
    color: #666;
}

.autonews-source strong {
    color: #333;
}

.autonews-source a {
    color: #007cba;
    text-decoration: none;
}

.autonews-source a:hover {
    text-decoration: underline;
}

/* Loading placeholder for images */
.autonews-image-loading {
    background: #f0f0f0;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 200px;
    color: #999;
}

/* Image caption styling */
.autonews-post .wp-caption,
.autonews-generated .wp-caption {
    max-width: 100%;
    margin: 20px auto;
}

.autonews-post .wp-caption-text,
.autonews-generated .wp-caption-text {
    font-size: 0.9em;
    color: #666;
    text-align: center;
    margin-top: 8px;
    font-style: italic;
}
