﻿/* 新闻列表页主容器 - 宽度1300px，居中显示 */
.news-list-container {
    width: 1300px;
    max-width: 100%;
    margin: 0 auto;
    padding: 20px 0;
    box-sizing: border-box;
}

/* 当前位置导航容器 */
.news-position-container {
    margin-bottom: 20px;
    padding: 10px 15px;
    background-color: #f8f8f8;
    border-radius: 4px;
}

/* 当前位置内容 */
.news-position-content {
    font-size: 16px;
    color: #666;
}

/* 主要内容区域 - 使用Flex布局实现自适应 */
.news-main-content {
    display: flex;
    gap: 20px;
}

/* 左侧新闻列表区域 - 自适应宽度 */
.news-list-section {
    flex: 1;
    min-width: 0; /* 防止flex项目溢出 */
}

/* 新闻列表容器 */
.news-list-box {
    background: #fff;
    border-radius: 6px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    overflow: hidden;
    margin-bottom: 20px;
}

/* 新闻文章列表 */
.news-article-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

/* 新闻文章列表项 */
.news-article-list li {
    padding: 15px 20px;
    border-bottom: 1px solid #f0f0f0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: background-color 0.2s;
}

/* 列表项悬停效果 */
.news-article-list li:hover {
    background-color: #f9f9f9;
}

/* 新闻标题链接 */
.news-article-list li a {
    flex: 1;
    color: #333;
    text-decoration: none;
    font-size: 16px;
    line-height: 1.4;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    margin-right: 15px;
}

/* 新闻标题链接悬停效果 */
.news-article-list li a:hover {
    color: #e74c3c;
}

/* 新闻时间 */
.news-article-list li span {
    color: #999;
    font-size: 14px;
    white-space: nowrap;
}

/* 分页容器 */
.news-pagination-container {
    text-align: center;
    padding: 15px 0;
}

/* 分页内容 */
.news-pagination-content {
    display: inline-block;
}

/* 右侧侧边栏区域 - 固定宽度 */
.news-sidebar-section {
    width: 300px;
    flex-shrink: 0;
}

/* 侧边栏模块 */
.news-sidebar-module {
    background: #fff;
    border-radius: 6px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    margin-bottom: 20px;
    overflow: hidden;
}

/* 侧边栏标题 */
.news-sidebar-title {
    padding: 12px 15px;
    background: #f8f8f8;
    border-bottom: 1px solid #eee;
    font-size: 16px;
    color: #333;
}

/* 侧边栏内容 */
.news-sidebar-content {
    padding: 15px;
}

/* 更新列表 */
.news-update-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

/* 更新列表项 */
.news-update-list li {
    padding: 8px 0;
    border-bottom: 1px dashed #eee;
}

/* 更新列表最后一项 */
.news-update-list li:last-child {
    border-bottom: none;
}

/* 热门列表 */
.news-popular-list {
    margin: 0;
    padding-left: 20px;
}

/* 热门列表项 */
.news-popular-list li {
    padding: 8px 0;
    border-bottom: 1px dashed #eee;
}

/* 热门列表最后一项 */
.news-popular-list li:last-child {
    border-bottom: none;
}

/* 响应式设计 - 小屏幕设备 */
@media (max-width: 768px) {
    .news-main-content {
        flex-direction: column;
        display: block; /* 关键修复：将flex布局改为块级布局 */
    }
    
    .news-sidebar-section {
        width: 100%;
        margin-top: 20px; /* 确保与上方内容有间距 */
    }
    
    .news-list-container {
        padding: 10px;
    }
    
    .news-article-list li {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .news-article-list li a {
        margin-right: 0;
        margin-bottom: 5px;
        white-space: normal;
    }
    
    /* 确保侧边栏模块在移动端宽度为100% */
    .news-sidebar-module {
        width: 100%;
    }
}