/* News Grid Layout */
.news-grid {
    display: grid;
    grid-template-columns: repeat(1, 1fr);
    gap: 2rem;
}

@media (min-width: 768px) {
    .news-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 3rem 2rem;
    }

    /* Dynamic wide cards pattern */
    .news-grid>article.span-2 {
        grid-column: span 2;
    }
}

.news-card-image {
    position: relative;
    overflow: hidden;
    aspect-ratio: 4 / 3;
    margin-bottom: 1rem;
}

@media (min-width: 768px) {
    .news-grid > article.span-2 .news-card-image {
        aspect-ratio: 2.8 / 1;
    }
}

.news-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.7s ease-in-out;
}

.news-grid>article:hover .news-card-image img {
    transform: scale(1.05);
}

/* Category Filter Styles */
.news-filter {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 1rem 2rem;
    margin-bottom: 4rem;
}

@media (min-width: 768px) {
    .news-filter {
        gap: 2rem 3rem;
    }
}

.news-filter a {
    text-transform: uppercase;
    font-size: 13px;
    letter-spacing: 0.1em;
    color: #6b7280;
    transition: color 0.3s ease;
    position: relative;
    padding-bottom: 1rem;
    text-align: center;
    flex: 1 1 auto;
    min-width: 100px;
    max-width: 180px;
}

.news-filter a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 1px;
    background-color: #e5e7eb;
    transition: background-color 0.3s ease;
}

.news-filter a:hover,
.news-filter a.active {
    color: #1a2b49;
}

.news-filter a.active::after {
    background-color: #1a2b49;
}

/* Pagination Styles */
.news-pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1.5rem;
    margin-top: 4rem;
}

@media (min-width: 768px) {
    .news-pagination {
        gap: 2.5rem;
    }
}

.news-pagination .page-numbers {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    font-size: 16px;
    color: #64748b;
    /* slate-500 */
    padding-bottom: 0.5rem;
    position: relative;
    transition: color 0.3s ease;
}

.news-pagination .page-numbers:hover,
.news-pagination .page-numbers.current {
    color: #1a2b49;
}

.news-pagination .page-numbers.current::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background-color: #1a2b49;
}