/**
 * Home Page Specific Styles
 * Standardizes news thumbnails and grid alignment.
 */

/* News Section Thumbnails */
.home-news-section-thumb {
    display: block;
    width: 100%;
    margin-bottom: 15px;
    overflow: hidden;
    border-radius: 12px;
}

/* Fix for thumbnails being inside <picture> tags or direct children */
.home-news-section-thumb img {
    display: block;
    width: 100%;
    height: 260px;
    /* Standardize height */
    object-fit: cover;
    /* Background-like behavior */
    object-position: center;
    transition: transform 0.4s ease;
}

/* Subtle hover effect for the entire item */
.home-news-section-item:hover .home-news-section-thumb img {
    transform: scale(1.05);
}

/* Title and Content Alignment Tweaks */
.home-news-section-title {
    font-size: 18px;
    line-height: 1.3;
    color: #0073e6;
    margin: 10px 0;
    /* Ensure title occupies consistent space for grid alignment */
    min-height: 48px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.home-news-section-excerpt {
    font-size: 14px;
    color: #666;
    line-height: 1.5;
    /* Consistent excerpt height */
    min-height: 63px;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.home-news-section-date {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
}

/* Responsive adjustments */
@media (max-width: 991px) {
    .home-news-section {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 575px) {
    .home-news-section {
        grid-template-columns: 1fr;
    }

    .home-news-section-thumb img {
        height: 200px;
    }
}