/**
 * Featured Articles - Circle Outline on Left with Colored Letters
 * Version: 2.2 - Professional, mobile-optimized, ad-safe
 */

/* Featured Section Container - Ad Safe */
.featured-section {
    margin-bottom: 3rem;
}

.featured-section .section-header {
    margin-bottom: 1.5rem;
    border-bottom: 2px solid #e3e8ef;
    padding-bottom: 0.75rem;
}

.featured-section .section-title {
    font-size: 1.75rem;
    font-weight: 700;
    color: #1a1a1a;
    margin: 0;
}

/* Featured Grid - 2 columns desktop, 1 column mobile */
.news-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
}

@media (max-width: 968px) {
    .news-grid {
        grid-template-columns: 1fr;
        gap: 1.25rem;
    }
}

/* Featured Card */
.featured-card {
    display: flex;
    flex-direction: column;
    padding: 1.25rem;
    background: #ffffff;
    border: 1px solid #e3e8ef;
    border-radius: 8px;
    transition: all 0.2s ease;
    min-height: 200px;
}

.featured-card:hover {
    border-color: #0066cc;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

/* Header Row - Circle on left, tags on right */
.featured-header-row {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
}

/* Circle Outline with Colored Letters or Image */
.featured-circle-outline {
    flex-shrink: 0;
    width: 64px;
    height: 64px;
    border-radius: 50%;
    border: 3px solid #e3e8ef;
    background: white;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.featured-circle-outline img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Colored Letters in Circle */
.circle-letters {
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: 0.5px;
}

/* Category Tags - Next to Circle */
.featured-categories {
    flex: 1;
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    align-items: center;
}

.featured-category-tag {
    font-size: 0.7rem;
    font-weight: 600;
    color: #0066cc;
    background: #f0f7ff;
    padding: 0.25rem 0.6rem;
    border-radius: 4px;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    text-decoration: none;
    transition: all 0.2s ease;
    white-space: nowrap;
}

.featured-category-tag:hover {
    background: #0066cc;
    color: white;
}

/* Content - Full Width Below Header */
.featured-content-full {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    width: 100%;
}

/* Title - Full Width */
.featured-title {
    margin: 0;
    font-size: 1.1rem;
    line-height: 1.4;
    width: 100%;
}

.featured-title a {
    color: #1a1a1a;
    text-decoration: none;
    font-weight: 600;
}

.featured-title a:hover {
    color: #0066cc;
}

/* Meta - Full Width */
.featured-meta {
    font-size: 0.8rem;
    color: #666;
    width: 100%;
}

/* Excerpt - Full Width */
.featured-excerpt {
    font-size: 0.9rem;
    line-height: 1.6;
    color: #444;
    margin: 0;
    flex: 1;
    width: 100%;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Footer - Full Width */
.featured-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    margin-top: 0.5rem;
    width: 100%;
}

.featured-source {
    font-size: 0.85rem;
    color: #0066cc;
    text-decoration: none;
    font-weight: 500;
}

.featured-source:hover {
    text-decoration: underline;
}

/* Share button */
.featured-card .article-share-inline {
    margin: 0;
}

.featured-card .article-share-btn {
    font-size: 0.75rem;
    padding: 0.4rem 0.75rem;
    white-space: nowrap;
}

/* Mobile Optimization - Critical for ads */
@media (max-width: 640px) {
    .featured-card {
        padding: 1rem;
        min-height: auto;
    }
    
    .featured-header-row {
        gap: 0.75rem;
        margin-bottom: 0.75rem;
    }
    
    .featured-circle-outline {
        width: 56px;
        height: 56px;
        border-width: 2px;
    }
    
    .circle-letters {
        font-size: 1.3rem;
    }
    
    .featured-category-tag {
        font-size: 0.65rem;
        padding: 0.2rem 0.5rem;
    }
    
    .featured-title {
        font-size: 1rem;
    }
    
    .featured-excerpt {
        font-size: 0.875rem;
        line-height: 1.5;
    }
    
    .featured-footer {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }
    
    .featured-card .article-share-btn {
        width: 100%;
        justify-content: center;
    }
}

/* Trending Section - Compact, Ad-Safe */
.trending-stories-section {
    margin-top: 4rem;
    padding: 2rem 0;
    background: #f8f9fa;
}

.trending-stories-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.trending-heading {
    font-size: 1.5rem;
    font-weight: 700;
    color: #1a1a1a;
    margin-bottom: 1.5rem;
}

#trending-stories-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
}

@media (max-width: 968px) {
    #trending-stories-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1.25rem;
    }
}

@media (max-width: 640px) {
    #trending-stories-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .trending-stories-section {
        padding: 1.5rem 0;
    }
}

.trending-story-card {
    padding: 1rem;
    background: #ffffff;
    border: 1px solid #e3e8ef;
    border-radius: 6px;
    transition: all 0.2s ease;
    min-height: 200px;
    display: flex;
    flex-direction: column;
}

.trending-story-card:hover {
    border-color: #0066cc;
    transform: translateY(-2px);
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

.trending-story-card .story-categories {
    margin-bottom: 0.5rem;
}

.trending-story-card .category-tag {
    font-size: 0.65rem;
    padding: 0.2rem 0.5rem;
    background: #f0f7ff;
    color: #0066cc;
    border-radius: 3px;
    text-decoration: none;
    display: inline-block;
    margin-right: 0.35rem;
}

.trending-story-card .story-title {
    font-size: 0.95rem;
    margin: 0 0 0.5rem 0;
    line-height: 1.4;
}

.trending-story-card .story-title a {
    color: #1a1a1a;
    text-decoration: none;
    font-weight: 600;
}

.trending-story-card .story-title a:hover {
    color: #0066cc;
}

.trending-story-card .story-meta {
    font-size: 0.75rem;
    color: #666;
    margin-bottom: 0.5rem;
}

.trending-story-card .story-excerpt {
    font-size: 0.8rem;
    line-height: 1.5;
    color: #444;
    margin: 0 0 0.75rem 0;
    flex: 1;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.trending-story-card .source-link {
    font-size: 0.75rem;
    color: #0066cc;
    text-decoration: none;
    display: block;
}

.trending-story-card .source-link:hover {
    text-decoration: underline;
}

.trending-story-card .article-share-inline {
    margin-top: 0.5rem;
}

.trending-story-card .article-share-btn {
    font-size: 0.7rem;
    padding: 0.3rem 0.6rem;
}

/* Print Styles - Ad Safe */
@media print {
    .featured-circle-outline,
    .trending-story-card {
        break-inside: avoid;
    }
}
