/**
 * 新闻列表页样式
 */

/* 新闻页容器 */
.news-page {
    min-height: calc(100vh - 200px);
    padding: 120px 0 60px;
    background-color: #f8f9fa;
}

.news-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* 新闻页头部 */
.news-header {
    text-align: center;
    margin-bottom: 40px;
}

.news-header h1 {
    font-size: 32px;
    font-weight: 600;
    color: #1a1a1a;
    margin: 0 0 12px;
}

.news-header p {
    font-size: 16px;
    color: #666;
    margin: 0;
}

/* 新闻网格布局 */
.news-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

@media (max-width: 992px) {
    .news-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 576px) {
    .news-grid {
        grid-template-columns: 1fr;
    }
}

/* 新闻卡片 */
.news-card {
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.news-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
}

.news-card a {
    display: block;
    text-decoration: none;
    color: inherit;
}

/* 新闻卡片图片 */
.news-card-image {
    position: relative;
    height: 180px;
    overflow: hidden;
    background-color: #eee;
}

.news-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.news-card:hover .news-card-image img {
    transform: scale(1.05);
}

/* 视频徽章 */
.news-card-video-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    background: rgba(0, 0, 0, 0.7);
    color: #fff;
    padding: 4px 10px;
    border-radius: 4px;
    font-size: 12px;
    display: flex;
    align-items: center;
    gap: 4px;
}

/* 新闻卡片内容 */
.news-card-content {
    padding: 16px 20px;
}

.news-card-date {
    font-size: 13px;
    color: #888;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.news-card-title {
    font-size: 16px;
    font-weight: 600;
    color: #1a1a1a;
    margin: 0 0 8px;
    line-height: 1.5;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.news-card-excerpt {
    font-size: 14px;
    color: #666;
    margin: 0;
    line-height: 1.6;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

/* 新闻卡片底部 */
.news-card-footer {
    padding: 12px 20px;
    border-top: 1px solid #f0f0f0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.news-card-views {
    font-size: 13px;
    color: #999;
    display: flex;
    align-items: center;
    gap: 4px;
}

.news-card-more {
    font-size: 13px;
    color: #E50012;
    display: flex;
    align-items: center;
    gap: 4px;
    transition: gap 0.2s ease;
}

.news-card:hover .news-card-more {
    gap: 8px;
}

/* 加载状态 */
.news-loading {
    text-align: center;
    padding: 60px 0;
    color: #666;
    font-size: 16px;
}

.news-loading i {
    margin-right: 8px;
}

/* 空状态 */
.news-empty {
    text-align: center;
    padding: 80px 0;
    color: #999;
}

.news-empty i {
    font-size: 48px;
    margin-bottom: 16px;
    display: block;
    color: #ddd;
}

.news-empty p {
    font-size: 16px;
    margin: 0;
}

/* 分页 */
.news-pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    margin-top: 40px;
    padding: 20px 0;
    flex-wrap: wrap;
}

.news-pagination-btn {
    min-width: 36px;
    height: 36px;
    padding: 0 12px;
    border: 1px solid #ddd;
    border-radius: 6px;
    background: #fff;
    color: #333;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.news-pagination-btn:hover:not(:disabled) {
    border-color: #E50012;
    color: #E50012;
}

.news-pagination-btn.active {
    background: #E50012;
    border-color: #E50012;
    color: #fff;
}

.news-pagination-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.news-pagination-info {
    margin-left: 12px;
    font-size: 14px;
    color: #666;
}

/* 响应式调整 */
@media (max-width: 768px) {
    .news-page {
        padding: 100px 0 40px;
    }
    
    .news-header h1 {
        font-size: 26px;
    }
    
    .news-header p {
        font-size: 14px;
    }
    
    .news-card-image {
        height: 160px;
    }
    
    .news-pagination {
        gap: 6px;
    }
    
    .news-pagination-btn {
        min-width: 32px;
        height: 32px;
        padding: 0 8px;
        font-size: 13px;
    }
}

/* ===================== */
/* 新闻详情页样式 */
/* ===================== */

.news-detail-page {
    min-height: calc(100vh - 200px);
    padding: 100px 0 80px;
    background: linear-gradient(180deg, #f8f9fa 0%, #fff 100%);
}

.news-detail-container {
    max-width: 860px;
    margin: 0 auto;
    padding: 0 24px;
}

/* 面包屑导航 */
.news-breadcrumb {
    padding: 20px 0;
    font-size: 13px;
    color: #888;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
}

.news-breadcrumb a {
    color: #666;
    text-decoration: none;
    transition: color 0.2s;
    font-weight: 500;
}

.news-breadcrumb a:hover {
    color: #E50012;
}

.news-breadcrumb span {
    margin: 0 10px;
    color: #ccc;
}

.news-breadcrumb span:last-child {
    color: #333;
    font-weight: 500;
    margin-left: 10px;
    margin-right: 0;
}

/* 文章容器 */
#news-article {
    background: #fff;
    border-radius: 16px;
    padding: 48px 56px;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.06), 0 1px 2px rgba(0, 0, 0, 0.04);
}

/* 文章头部 */
.news-detail-header {
    margin-bottom: 36px;
    padding-bottom: 28px;
    border-bottom: 1px solid #eee;
    text-align: center;
}

.news-detail-title {
    font-size: 32px;
    font-weight: 700;
    color: #1a1a1a;
    line-height: 1.45;
    margin: 0 0 20px;
    letter-spacing: -0.5px;
}

.news-detail-meta {
    display: flex;
    justify-content: center;
    gap: 32px;
    font-size: 14px;
    color: #999;
}

.news-detail-meta span {
    display: flex;
    align-items: center;
    gap: 8px;
}

.news-detail-meta i {
    color: #E50012;
    opacity: 0.7;
    font-size: 13px;
}

/* 文章媒体（图片/视频） */
.news-detail-media {
    margin: 0 -56px 36px;
    overflow: hidden;
}

.news-detail-media img {
    width: 100%;
    height: auto;
    display: block;
    transition: transform 0.3s ease;
}

.news-detail-media:hover img {
    transform: scale(1.01);
}

.news-detail-media video {
    width: 100%;
    max-height: 520px;
    background: #000;
    border-radius: 0;
}

.news-detail-media iframe {
    width: 100%;
    height: 480px;
    border: none;
    background: #000;
}

/* 文章正文 */
.news-detail-content {
    font-size: 17px;
    line-height: 1.9;
    color: #333;
    letter-spacing: 0.2px;
}

.news-detail-content p {
    margin: 0 0 20px;
    text-align: justify;
}

.news-detail-content p:last-child {
    margin-bottom: 0;
}

.news-detail-content img {
    max-width: 100%;
    height: auto;
    border-radius: 12px;
    margin: 28px 0;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
}

.news-detail-content h2 {
    font-size: 24px;
    font-weight: 700;
    margin: 40px 0 20px;
    color: #1a1a1a;
    padding-left: 16px;
    border-left: 4px solid #E50012;
}

.news-detail-content h3 {
    font-size: 20px;
    font-weight: 600;
    margin: 32px 0 16px;
    color: #1a1a1a;
}

.news-detail-content ul,
.news-detail-content ol {
    padding-left: 28px;
    margin: 20px 0;
}

.news-detail-content li {
    margin: 10px 0;
    line-height: 1.8;
}

.news-detail-content blockquote {
    margin: 28px 0;
    padding: 24px 28px;
    background: linear-gradient(135deg, #fafafa 0%, #f5f5f5 100%);
    border-left: 4px solid #E50012;
    border-radius: 0 12px 12px 0;
    font-style: italic;
    color: #555;
    position: relative;
}

.news-detail-content blockquote::before {
    content: '"';
    position: absolute;
    top: 12px;
    left: 16px;
    font-size: 48px;
    color: #E50012;
    opacity: 0.2;
    font-family: Georgia, serif;
    line-height: 1;
}

.news-detail-content pre {
    background: linear-gradient(135deg, #1a1a1a 0%, #2d2d2d 100%);
    color: #e0e0e0;
    padding: 24px;
    border-radius: 12px;
    overflow-x: auto;
    margin: 28px 0;
    font-size: 14px;
}

.news-detail-content code {
    font-family: 'SF Mono', 'Consolas', 'Monaco', monospace;
    font-size: 14px;
}

.news-detail-content a {
    color: #E50012;
    text-decoration: none;
    border-bottom: 1px solid transparent;
    transition: border-color 0.2s;
}

.news-detail-content a:hover {
    border-bottom-color: #E50012;
}

/* 文章底部 */
.news-detail-footer {
    margin-top: 48px;
    padding-top: 28px;
    border-top: 1px solid #eee;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
}

/* 分享按钮 */
.news-share {
    display: flex;
    align-items: center;
    gap: 16px;
}

.news-share-label {
    font-size: 14px;
    color: #888;
    font-weight: 500;
}

.news-share-buttons {
    display: flex;
    gap: 10px;
}

.news-share-btn {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 17px;
    cursor: pointer;
    transition: all 0.25s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.news-share-btn.wechat {
    background: linear-gradient(135deg, #07c160 0%, #05a14d 100%);
    color: #fff;
}

.news-share-btn.weibo {
    background: linear-gradient(135deg, #e6162d 0%, #c41222 100%);
    color: #fff;
}

.news-share-btn.copy {
    background: linear-gradient(135deg, #666 0%, #4a4a4a 100%);
    color: #fff;
}

.news-share-btn:hover {
    transform: translateY(-3px) scale(1.05);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.15);
}

/* 返回按钮 */
.news-back {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 12px 24px;
    background: linear-gradient(135deg, #E50012 0%, #c7000f 100%);
    color: #fff;
    text-decoration: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.25s ease;
    box-shadow: 0 2px 8px rgba(229, 0, 18, 0.25);
}

.news-back:hover {
    background: linear-gradient(135deg, #ff1a2b 0%, #E50012 100%);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(229, 0, 18, 0.35);
    color: #fff;
}

.news-back i {
    transition: transform 0.2s;
}

.news-back:hover i {
    transform: translateX(-3px);
}

/* 加载和错误状态美化 */
.news-detail-page .news-loading {
    text-align: center;
    padding: 80px 0;
    color: #888;
    font-size: 16px;
}

.news-detail-page .news-loading i {
    font-size: 32px;
    color: #E50012;
    display: block;
    margin-bottom: 16px;
}

.news-detail-page .news-empty {
    text-align: center;
    padding: 100px 0;
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.06);
}

.news-detail-page .news-empty i {
    font-size: 64px;
    color: #ddd;
    margin-bottom: 20px;
}

.news-detail-page .news-empty p {
    font-size: 18px;
    color: #888;
    margin-bottom: 24px;
}

/* 详情页响应式 */
@media (max-width: 768px) {
    .news-detail-page {
        padding: 90px 0 50px;
    }
    
    .news-detail-container {
        padding: 0 16px;
    }
    
    #news-article {
        padding: 28px 20px;
        border-radius: 12px;
    }
    
    .news-detail-header {
        text-align: left;
        padding-bottom: 20px;
        margin-bottom: 24px;
    }
    
    .news-detail-title {
        font-size: 24px;
        letter-spacing: 0;
    }
    
    .news-detail-meta {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    
    .news-detail-media {
        margin: 0 -20px 28px;
    }
    
    .news-detail-content {
        font-size: 16px;
        line-height: 1.85;
    }
    
    .news-detail-content h2 {
        font-size: 20px;
        padding-left: 12px;
    }
    
    .news-detail-content h3 {
        font-size: 18px;
    }
    
    .news-detail-media iframe {
        height: 260px;
    }
    
    .news-detail-footer {
        flex-direction: column;
        align-items: stretch;
        gap: 16px;
    }
    
    .news-share {
        justify-content: center;
    }
    
    .news-back {
        justify-content: center;
    }
}
