/* 新闻资讯页面样式 */

/* 新闻卡片区域 */
.news-cards {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 15px;
    margin-bottom: 50px;
}

.news-card {
    background-color: rgba(245, 245, 245, 1);
    border-radius: 4px;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.news-card-image {
    width: 100%;
    height: 150px;
    overflow: hidden;
}

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

.news-card .news-card-image:hover img {
    transform: scale(1.2);
    cursor: pointer;
}

.news-card-title {
    font-size: 16px;
    color: rgba(0, 0, 0, 0.8);
    margin: 15px 0 10px;
    padding: 0 10px;
    font-weight: bold;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.news-card:hover .news-card-title {
    cursor: pointer;
    color: rgba(230, 28, 42, 1);
}

.news-card-excerpt {
    font-size: 14px;
    color: #999999;
    margin: 0 0 15px;
    padding: 0 10px 10px;
    line-height: 1.6;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    height: 44px;
}

/* 新闻列表 */
.news-list {
    margin-bottom: 40px;
}

.news-item {
    padding: 20px 30px;
    margin-bottom: 20px;
    background-color: rgba(245, 245, 245, 1);
    transition: background-color 0.3s ease, transform 0.3s ease;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
}

.news-item:hover {
    background-color: rgba(195, 11, 0, 0.1);
    transform: translateX(4px);
}

.news-item:hover .news-year,
.news-item:hover .news-day {
    color: #c30b00;
}

.news-item-content {
    flex: 1;
    margin-right: 110px;
}

.news-item-header {
    display: block;
    margin-bottom: 10px;
}

.news-item-title {
    font-size: 22px;
    color: #212529;
    margin: 0;
    font-weight: normal;
}

.news-item-title a {
    color: #212529;
    text-decoration: none;
    transition: color 0.3s ease;
}

.news-item-date {
    text-align: right;
    flex-shrink: 0;
    margin-left: 20px;
}

.news-year {
    display: block;
    font-size: 14px;
    color: #999999;
    margin-bottom: 5px;
}

.news-day {
    display: block;
    font-size: 34px;
    color: #999999;
    font-family: Impact;
}

.news-item-excerpt {
    font-size: 14px;
    color: #999999;
    line-height: 1.8;
    margin: 0;
    text-align: justify;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

/* 分页组件 */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
    margin: 40px 0;
}

.page-btn {
    min-width: 40px;
    height: 40px;
    border: 1px solid #e0e0e0;
    background-color: #fff;
    color: #6c757d;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    line-height: 1;
}

.page-btn:hover:not(.page-disabled):not(.page-active) {
    background-color: #27477d;
    color: #ffffff;
}

.page-active {
    background-color: #00bcd4;
    border-color: #00bcd4;
    color: #fff;
}

.page-disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.page-info {
    font-size: 14px;
    color: #6c757d;
    margin-left: 10px;
}

.page-info input {
    width: 50px;
    height: 30px;
    border: 1px solid #e0e0e0;
    text-align: center;
    margin: 0 5px;
    font-size: 14px;
    outline: none;
}

.page-info input:focus {
    border-color: #27477d;
}

/* 响应式设计 */
@media (max-width: 992px) {
    .news-cards {
        grid-template-columns: repeat(3, 1fr);
    }
    
    .page-info {
        display: none;
    }
    
    .pagination {
        gap: 5px;
    }
    
    .page-btn {
        min-width: 32px;
        height: 32px;
        font-size: 13px;
    }
}

@media (max-width: 768px) {
    .news-cards {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .news-item-header {
        flex-direction: column;
    }
    
    .news-item-date {
        display: none;
    }
    
    .news-item-content {
        margin-right: 0;
    }
    
    .news-day {
        font-size: 20px;
    }
}
