/* News Card Styles */
.news-card {
    display: flex;
    flex-direction: column;
    height: 100%;
    background: #fff;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.news-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.15);
}

.news-card__link {
    display: flex;
    flex-direction: column;
    height: 100%;
    color: inherit;
    text-decoration: none;
}

.news-card__image {
    position: relative;
    padding-top: 56.25%;
    /* 16:9 aspect ratio */
    overflow: hidden;
    background: #f5f5f5;
}

.news-card__img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.news-card:hover .news-card__img {
    transform: scale(1.05);
}

.news-card__content {
    flex: 1;
    display: flex;
    flex-direction: column;
    padding: 20px;
}

/* Text Elements */
.news-card__date {
    font-size: 0.8125rem;
    color: #666;
    margin-bottom: 12px;
    display: block;
    line-height: 1.3;
}

.news-card__title {
    font-size: 1.25rem;
    line-height: 1.4;
    margin: 0 0 12px;
    color: #222;
    font-weight: 600;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    max-height: calc(1.4em * 2);
}

.news-card__excerpt {
    font-size: 0.9375rem;
    line-height: 1.5;
    color: #555;
    margin-top: auto;
    margin-bottom: 5px;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
    line-clamp: 3;
    max-height: calc(1.5em * 3);
}

/* Grid Layout */
.news-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 30px;
    margin: 30px 0;
}

/* Pagination */
.news-pagination {
    margin-top: 40px;
    text-align: center;
}

.news-pagination .page-numbers {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin: 0 5px;
    min-width: 40px;
    height: 40px;
    padding: 0 10px;
    border-radius: 4px;
    background: #f5f5f5;
    color: #333;
    text-decoration: none;
    transition: all 0.3s ease;
}

.news-pagination .page-numbers.current,
.news-pagination .page-numbers:hover {
    background: #0073aa;
    color: #fff;
}

/* Responsive Adjustments */
@media (max-width: 992px) {
    .news-card__title {
        font-size: 1.15rem;
    }

    .news-card__excerpt {
        -webkit-line-clamp: 2;
        line-clamp: 2;
        max-height: calc(1.5em * 2);
    }
}

@media (max-width: 768px) {
    .news-grid {
        grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
        gap: 20px;
    }

    .news-card__content {
        padding: 18px;
    }

    .news-card__title {
        font-size: 1.1rem;
    }

    .news-card__excerpt {
        font-size: 0.875rem;
    }
}

@media (max-width: 480px) {
    .news-card__title {
        font-size: 1.05rem;
    }

    .news-card__excerpt {
        -webkit-line-clamp: 3;
        line-clamp: 3;
        max-height: calc(1.5em * 3);
        font-size: 0.85rem;
    }

    .news-card__content {
        padding: 15px;
    }
}