/* 主页布局样式 */
.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.main-content-wrapper {
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    padding: 20px;
    margin-top: 20px;
    margin-bottom: 30px;
}

/* 三栏布局样式 - 确保完全一致的尺寸和适当的间距 */
.content-columns {
    display: flex;
    justify-content: space-between;
    gap: 20px; /* 增加间距使其不那么紧凑 */
    flex-wrap: wrap; /* 允许内容换行 */
    align-items: stretch; /* 确保所有列高度一致 */
}

.column {
    flex: 1 1 0;
    min-width: 280px;
    max-width: calc(33.333% - 13px);
    background-color: #f9f9f9;
    border-radius: 8px;
    padding: 20px;
    height: auto;
    min-height: 500px;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    overflow: hidden; /* 防止内容溢出 */
}

/* 新闻栏目通用样式 */
.news.tag-section {
    height: 100%;
    display: flex;
    flex-direction: column;
    /* 移除flex-grow以确保标题不被压缩 */
}

.news.tag-section h2 {
    font-size: 18px;
    color: #333;
    margin-top: 0;
    margin-bottom: 20px; /* 增加下方间距 */
    padding-top: 10px;
    padding-bottom: 10px;
    border-bottom: 2px solid #e64398;
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 10; /* 确保标题显示在最上层 */
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.more-link {
    font-size: 14px;
    color: #e64398;
    text-decoration: none;
}

.more-link:hover {
    text-decoration: underline;
}

/* 新闻列表和项目样式 - 统一内容显示 */
.news-list {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 15px; /* 增加新闻项之间的间距 */
}

/* 确保所有新闻卡片大小一致 */
.news-item {
    padding-bottom: 12px;
    border-bottom: 1px solid #eee;
    display: flex;
    gap: 15px; /* 增加内部间距 */
    align-items: flex-start;
    min-height: 110px; /* 使用最小高度而不是固定高度，允许内容适当扩展 */
    overflow: hidden; /* 防止内容溢出 */
}

.news-item:last-child {
    padding-bottom: 0;
    border-bottom: none;
}

/* 统一缩略图尺寸 - 适用于所有类型的缩略图 */
.news-thumbnail, .news-image {
    flex-shrink: 0;
    width: 75px;
    height: 120px;
    border-radius: 4px;
    overflow: hidden;
}

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

.news-thumbnail:hover img, .news-image:hover img {
    transform: scale(1.05);
}

/* 统一内容区域样式 - 适用于所有内容区块 */
.news-content {
    flex: 1;
    min-width: 0;
    overflow: hidden; /* 防止内容溢出 */
}

.news-content h3 {
    font-size: 16px; /* 调整标题字体大小 */
    margin-bottom: 8px;
    line-height: 1.5;
    font-weight: bold;
}

.news-content h3 a {
    color: #333;
    text-decoration: none;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
}

.news-content h3 a:hover {
    color: #e64398;
}

/* 统一日期显示 - 适用于所有日期格式 */
.news-content .date, .date-badge {
    font-size: 13px; /* 增大日期字体大小 */
    color: #999;
    display: block;
    margin-bottom: 8px;
    font-weight: normal;
    background: none;
    padding: 0;
    width: auto;
    height: auto;
    text-align: left;
    line-height: 1.3;
}

/* 统一描述文本显示 - 确保所有描述文本样式一致 */
.news-content p {
    font-size: 14px; /* 调整内容字体大小 */
    color: #666;
    line-height: 1.8; /* 增加行高确保文本完整显示 */
    margin: 0;
    display: -webkit-box;
    -webkit-line-clamp: 3; /* 限制显示行数 */
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    position: relative;
    padding-bottom: 2px; /* 增加底部内边距 */
}

/* 最新资讯区域特殊样式 - 确保与其他栏目布局一致 */
.full-width-section {
    width: 100%;
    background-color: white;
    padding: 1.5rem 0;
    margin: 0.5rem 0;
}

.full-width-section .container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.full-width-section .section-header {
    text-align: center;
    margin-bottom: 1rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #e0e0e0;
}

.full-width-section .section-header h2 {
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.full-width-section .content-columns {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap; /* 允许内容换行 */
    align-items: stretch;
}

.full-width-section .content-columns .news-item {
    flex: 1 1 0;
    min-width: 280px;
    max-width: calc(33.333% - 13px);
    background-color: #f9f9f9;
    border-radius: 8px;
    padding: 20px; /* 增加内边距 */
    height: auto; /* 改为自适应高度，根据内容调整 */
    min-height: 380px; /* 进一步减小最小高度 */
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    overflow: hidden; /* 防止内容溢出 */
}

.full-width-section .news-item .news-thumbnail {
    flex-shrink: 0;
    width: 100%;
    height: 200px;
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 1rem;
}

.full-width-section .news-item .news-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.full-width-section .news-item .news-thumbnail:hover img {
    transform: scale(1.05);
}

.full-width-section .news-item .news-content {
    flex: 0 1 auto; /* 不自动拉伸内容区域 */
    min-width: 0;
    margin-bottom: 0; /* 确保底部没有额外间距 */
}

.full-width-section .news-item .news-content .date {
    font-size: 13px; /* 增大日期字体大小 */
    color: #999;
    display: block;
    margin-bottom: 8px;
    font-weight: normal;
    background: none;
    padding: 0;
    width: auto;
    height: auto;
    text-align: left;
    line-height: 1.3;
}

.full-width-section .news-item .news-content h3 {
    font-size: 17px; /* 增大标题字体大小 */
    margin-bottom: 8px;
    line-height: 1.5;
}

.full-width-section .news-item .news-content h3 a {
    color: #333;
    text-decoration: none;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
}

.full-width-section .news-item .news-content h3 a:hover {
    color: #e64398;
}

.full-width-section .news-item .news-content p {
    font-size: 16px; /* 进一步增大内容字体大小 */
    color: #666;
    line-height: 1.8; /* 增加行高确保文本完整显示 */
    margin: 0; 
    display: -webkit-box;
    -webkit-line-clamp: 4; /* 保持显示行数 */
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    padding-bottom: 2px; /* 增加底部内边距 */
}

/* 响应式设计 */
@media (max-width: 992px) {
    .content-columns {
        flex-direction: column;
    }
    
    .column {
        max-width: 100%;
        margin-bottom: 20px; /* 增加间距 */
        height: auto; /* 在响应式布局中使用自适应高度 */
        min-height: 450px; /* 减小最小高度 */
    }
    
    .full-width-section .content-columns .news-item {
        max-width: 100%;
        margin-bottom: 20px; /* 增加间距 */
        height: auto; /* 在响应式布局中使用自适应高度 */
        min-height: 350px; /* 进一步减小响应式布局中的最小高度 */
    }
    
    .full-width-section .content-columns {
        flex-direction: column;
    }
    
    .full-width-section .news-item .news-thumbnail {
        height: 180px;
    }
}

@media (max-width: 768px) {
    .main-content-wrapper {
        padding: 15px;
    }
    
    .column,
    .full-width-section .content-columns .news-item {
        padding: 12px;
        min-width: auto;
    }
    
    .news-item {
        flex-direction: column;
        gap: 10px;
    }
    
    .news-thumbnail {
        width: 100%;
        height: 120px;
    }
    
    .full-width-section .news-item .news-thumbnail {
        height: 150px;
    }
    
    .full-width-section .container {
        padding: 0 15px;
    }
}