/* index.css - 完全响应式优化版 */
/* 仅修改样式，未改动任何HTML结构和PHP逻辑 */

.clear {
    clear: both;
}

body {
    background-color: #f0f0f0;
    font-family: "Microsoft YaHei", Arial, "宋体", Arial Narrow, sans-serif;
}

/* 主容器：改为弹性 + 最大宽度，实现居中与自适应 */
section {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
    box-sizing: border-box;
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
}

/* 左侧区域：弹性宽度，允许缩放 */
.left {
    flex: 1;
    min-width: 0;          /* 防止flex子项溢出 */
    background-color: transparent;
    margin-right: 20px;
    box-sizing: border-box;
}

/* 左侧每个区块：高度自动，内边距微调 */
.left > div {
    background-color: #fff;
    margin: 10px 0;
    border-radius: 4px;
    overflow: hidden;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

/* 右侧区域：固定宽度在桌面，平板和手机自适应 */
.right {
    width: 360px;
    flex-shrink: 0;
    background-color: transparent;
    box-sizing: border-box;
}

/* 右侧每个卡片 */
.right-one, .right-two, .right-three {
    background-color: #fff;
    margin-bottom: 15px;
    border-radius: 4px;
    overflow: hidden;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

.right > div:last-child {
    margin-bottom: 0;
}

/* 公用卡片头部 */
.vF_title_bar2, .VF_t1-2 {
    margin: 0 12px;
}

.vF_title_bar2 {
    height: 48px;
    line-height: 48px;
    border-bottom: 1px solid #e1e1e1;
}

.vF_title_bar2 h2.current2 {
    border-bottom: 2px solid #bf0d0d;
    height: 44px;
    margin-bottom: 1px;
}

.vF_title_bar2 h2 {
    font-size: 18px;
    font-weight: bolder;
    color: #1f376d;
}

.vF_title_bar2 h2.current2 a {
    font-size: 18px;
    font-weight: bolder;
    color: #1f376d;
    text-decoration: none;
    line-height: 44px;
    display: inline-block;
}

/* 右侧头部 */
.VF_t1-2 {
    height: 42px;
    line-height: 42px;
    border-bottom: 1px solid #e1e1e1;
}

.VF_t1-2 h2.current2 {
    border-bottom: 2px solid #bf0d0d;
    height: 38px;
}

.VF_t1-2 h2.current2 a {
    font-size: 16px;
    font-weight: bolder;
    color: #1f376d;
    text-decoration: none;
    line-height: 38px;
}

/* 列表项通用样式：弹性布局，自动换行 */
.c_list, .r_list {
    display: flex;
    align-items: center;
    padding: 6px 12px;
    transition: background 0.2s;
}

.c_list:hover, .r_list:hover {
    background-color: #fafafa;
}

.c_list_img, .r_list_img {
    width: 20px;
    flex-shrink: 0;
    margin-right: 8px;
}

.c_list_img img, .r_list_img img {
    width: 16px;
    display: block;
}

/* 标题区域：自适应宽度，文本溢出隐藏 */
.c_list_title {
    flex: 1;
    min-width: 0;
    font-size: 14px;
    line-height: 1.4;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.r_list_title {
    flex: 1;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: 13px;
    line-height: 1.4;
}

.c_list_title a, .r_list_title a {
    font-size: inherit;
    color: #000;
    text-decoration: none;
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
}

.c_list_time, .r_list_time {
    flex-shrink: 0;
    margin-left: 12px;
    font-size: 13px;
    color: #666;
    white-space: nowrap;
}

/* 右侧列表时间宽度自适应 */
.r_list_time {
    width: auto;
    min-width: 70px;
    text-align: right;
}

/* 链接悬停效果 */
.c_list div a:hover, .r_list div a:hover {
    text-decoration: underline;
    color: #ba2636;
}

/* ========== 平板响应式 (宽度 <= 992px) ========== */
@media screen and (max-width: 992px) {
    section {
        flex-direction: column;
        padding: 0 12px;
    }

    .left {
        margin-right: 0;
        width: 100%;
    }

    .right {
        width: 100%;
        margin-top: 10px;
    }

    .c_list_title {
        white-space: normal;
        word-break: break-word;
    }

    /* 平板下标题可换行，更易读 */
    .c_list_title a {
        white-space: normal;
        line-height: 1.3;
    }

    .c_list {
        align-items: flex-start;
        padding: 8px 12px;
    }
}

/* ========== 手机响应式 (宽度 <= 768px) ========== */
@media screen and (max-width: 768px) {
    body {
        font-size: 14px;
    }

    section {
        padding: 0 10px;
    }

    .left > div, .right-one, .right-two, .right-three {
        margin: 8px 0;
        border-radius: 6px;
    }

    .vF_title_bar2 h2, .vF_title_bar2 h2.current2 a {
        font-size: 16px;
    }

    .VF_t1-2 h2.current2 a {
        font-size: 15px;
    }

    /* 列表项改为垂直方向更适合触摸？不，仍保持水平，但内边距增大 */
    .c_list, .r_list {
        padding: 8px 10px;
    }

    .c_list_img, .r_list_img {
        width: 18px;
        margin-right: 6px;
    }

    .c_list_title {
        font-size: 13px;
    }

    .c_list_time, .r_list_time {
        font-size: 11px;
        margin-left: 8px;
    }

    /* 右侧列表时间宽度灵活 */
    .r_list_time {
        min-width: 60px;
    }

    /* 完全避免溢出，标题可换行 */
    .c_list_title a, .r_list_title a {
        white-space: normal;
        word-break: break-word;
    }

    .c_list_title, .r_list_title {
        white-space: normal;
    }
}

/* ========== 超小手机 (<= 480px) 进一步优化 ========== */
@media screen and (max-width: 480px) {
    .c_list, .r_list {
        flex-wrap: wrap;
        padding: 10px 8px;
    }

    .c_list_img, .r_list_img {
        align-self: flex-start;
        margin-top: 2px;
    }

    .c_list_title {
        width: calc(100% - 70px);
        flex: auto;
        margin-right: 0;
    }

    .c_list_time {
        margin-left: auto;
        font-size: 10px;
    }

    /* 右侧列表强制换行展示 */
    .r_list {
        flex-wrap: wrap;
    }

    .r_list_title {
        width: calc(100% - 70px);
        flex: auto;
        margin-bottom: 2px;
    }

    .r_list_time {
        text-align: left;
        margin-left: 26px;  /* 与图标对齐 */
        width: 100%;
        font-size: 10px;
        color: #888;
    }

    /* 头部内边距减小 */
    .vF_title_bar2, .VF_t1-2 {
        margin: 0 8px;
    }

    .vF_title_bar2 h2.current2 a {
        font-size: 15px;
    }
}

/* 辅助改善触摸区域 */
a, .c_list, .r_list {
    cursor: pointer;
}

/* 保持原有背景色和卡片干净 */
.left > div, .right-one, .right-two, .right-three {
    background-color: #fff;
}

.right_t2, .newslist {
    background-color: #fff;
}

/* 修复右侧背景色继承问题 */
.right_t2 {
    background-color: #fff;
}

/* 确保所有卡片内容不溢出 */
.newslist_bl, .newslist, .vF_t3 {
    width: 100%;
    overflow: hidden;
}