/* 小屏适配（800px及以下）- 仅针对小屏生效，不干扰大屏 */
@media (max-width: 800px) {
    /* 1. 容器基础布局：顶部偏移避开导航栏，整体居中 */
    .pages-wrapper {
        width: 100vw;
        min-height: 100vh;
        margin-top: 50px !important; /* 导航栏高度，可按需调整 */
        display: flex;
        flex-direction: column;
        align-items: center;
        padding: 0;
        overflow-x: hidden;
    }

    /* 2. 所有板块基础样式：16:9等比缩放，居中对齐 */
    .pageone {
        width: 100%;
        height: calc(100vw * 9 / 16);
        max-height: calc(100vh - 50px);
        position: relative;
        margin: 0 !important;
        padding: 0 !important;
        display: flex;
        align-items: center;
        justify-content: center;
        transform: scale(calc(100vw / 1920));
        transform-origin: center center;
    }

    /* 3. 轮播图板块：完整显示+文字两行固定 */
    .page8 {
        height: calc(100vw * 9 / 16) !important;
        margin: 0 !important;
        padding: 0 !important;
    }
    .carousel {
        width: 100%;
        height: 100% !important;
    }
    .carousel-inner, .carousel-item {
        width: 100%;
        height: 100%;
    }
    .carousel-item img {
        width: 100%;
        height: 100%;
        object-fit: cover;
    }
    /* 轮播文字：两行显示+加宽，避免第三行 */
    .carousel-caption2 {
        font-size: calc(16px + 0.8vw) !important;
        padding: 0 !important;
        bottom: 10px !important;
        top: auto !important;
        font-weight: 500;
        line-height: 1.6;
        white-space: normal !important;
        width: 95% !important;
        max-width: none !important;
        text-align: center !important;
        margin: 0 auto !important;
    }
    .carousel-caption2 h3 {
        max-width: 90%;
        margin: 0 auto !important;
        word-break: keep-all !important;
        letter-spacing: 0.5px;
    }
    .carousel-caption4 {
        font-size: calc(18px + 0.5vw);
        padding: 0 10px;
        bottom: 10px !important;
        top: auto !important;
    }

    /* 4. 产品中心/解决方案/关于东辰：统一布局+各自样式 */
    .page4, .page5, .page2 {
        padding: 0 15px !important;
        margin: 0 !important;
        text-align: center !important;
        display: flex;
        flex-direction: column;
        align-items: center !important;
        justify-content: center !important;
        width: 100% !important;
    }
    /* 关于东辰（page2）：自定义背景+文字样式（已调整至满意） */
    .page2 {
        background-image: url('../img/imgindex/04.jpg'); /* 专属背景图 */
        color: #ffffff; /* 文字白色 */
    }
    .page2 h2 {
        font-size: 4vw;
        font-family: 'Arial', sans-serif;
        font-weight: bold;
        margin-left: 0%;
        margin-top: -5%;
        margin-bottom: 40px;
    }
    .page2 p {
        font-size: 1.2vw;
        font-family: 'Times New Roman', serif;
        margin: 1vw 0;
        margin-left: 0%;
        font-weight: bold;
        margin-bottom: -30px;
    }

    /* 5. 方案及产品咨询（page3）：强制重置容器，确保居中 */
    .page3 {
        padding: 0 !important;
        margin: 0 !important;
        text-align: center !important;
        display: flex;
        flex-direction: column;
        align-items: center !important;
        justify-content: center !important;
        width: 100% !important;
    }
    .page3 .container,
    .page3 .row,
    .page3 .col-md-12 {
        padding-left: 0 !important;
        padding-right: 0 !important;
        margin-left: 0 !important;
        margin-right: 0 !important;
        width: 100% !important;
        text-align: center !important;
        display: flex !important;
        flex-direction: column !important;
        align-items: center !important;
        justify-content: center !important;
    }
    .page3 .custom-line {
        margin: 0 auto !important;
        display: block !important;
    }

    /* 6. 通用文字/按钮：统一居中样式 */
    .pageone h2 {
        font-size: calc(18px + 1vw);
        margin-bottom: 10px;
        text-align: center !important;
    }
    .pageone p {
        font-size: calc(12px + 0.3vw);
        line-height: 1.5;
        margin-bottom: 20px;
        text-align: center !important;
        width: 100% !important;
    }
    .btnpageindex, .btnpage2 {
        padding: 8px 20px;
        font-size: calc(12px + 0.2vw);
        border-radius: 4px;
        text-decoration: none;
        display: inline-block;
        margin: 0 auto !important;
        float: none !important;
        left: 0 !important;
    }

    /* 7. 辅助样式：隐藏无关板块+滚动条+固定导航 */
    /* .pagelast {
        display: none !important; 隐藏合作公司板块（已注释，可显示）
    } */
    .indicator {
        display: none !important; /* 隐藏指示器 */
    }
    html, body {
        overflow: auto !important;
        height: auto !important;
        scrollbar-width: none; /* 隐藏火狐滚动条 */
        -ms-overflow-style: none; /* 隐藏IE滚动条 */
    }
    html::-webkit-scrollbar, body::-webkit-scrollbar {
        display: none !important; /* 隐藏Chrome滚动条 */
        width: 0 !important;
        height: 0 !important;
    }
    /* 关键修复：导航栏仅针对原生header标签，避免覆盖page9内的headername */
    body > header {
        position: fixed !important;
        top: 0 !important;
        left: 0 !important;
        width: 100%;
        z-index: 9999 !important; /* 导航栏置顶 */
    }

    /* ===================== 彻底修复：page9（合作公司+底部信息）小屏适配 ===================== */
    /* 8. 核心：page9脱离pageone的缩放逻辑，避免继承导致的错位/缩放问题 */
    .page9 {
        width: 100% !important;
        height: auto !important; /* 完全自适应内容高度 */
        max-height: none !important;
        margin: 0 !important;
        padding: 20px 15px !important;
        transform: none !important; /* 取消所有缩放 */
        display: block !important; /* 取消flex，用默认流布局，避免错位 */
        position: relative !important; /* 相对定位，固定自身区域 */
        z-index: 100 !important; /* 层级低于导航栏，但高于其他内容 */
        top: 0 !important; /* 重置top值，避免偏移 */
        left: 0 !important; /* 重置left值，避免偏移 */
    }
    /* 9. 重置page9内所有容器，避免继承外部样式 */
    .page9 .container,
    .page9 .row,
    .page9 [class*="col-"] {
        width: 100% !important;
        padding: 0 5px !important;
        margin: 0 !important;
        float: none !important;
        display: block !important;
    }
    /* 10. 合作公司左侧图标区 - 放大+居中 */
    .img-hzimg, .img-hzimg1, .image-hzhb {
        text-align: center !important;
        margin: 10px 0 !important;
    }
    .img-hzimg img, .img-hzimg1 img, .image-hzhb img {
        width: auto !important;
        height: 80px !important; /* 固定高度，强制放大图标 */
        max-width: 90% !important;
        display: inline-block !important;
    }

    /* 11. 合作公司右侧品牌图标 - 放大+2列布局（精准调整，解决单列问题） */
    .page9 .products-use {
        display: inline-block !important;
        width: 48% !important; /* 核心：48%宽度+左右1%间距，强制2列 */
        margin: 8px 1% !important; /* 增加上下间距，避免拥挤 */
        text-align: center !important;
        float: none !important; /* 取消浮动，避免错位 */
    }
    .products-use img {
        width: auto !important;
        height: 60px !important; /* 图标放大高度，保留 */
        max-width: 100% !important;
    }
    /* 12. 彻底修复logodc.png错位：限定在page9内 */
    .page9 .headername {
        text-align: center !important;
        margin: 20px 0 !important;
        display: block !important;
        position: relative !important; /* 相对定位，固定在自身区域 */
        top: 0 !important;
        left: 0 !important;
        z-index: 101 !important;
    }
    .page9 .logo {
        width: 100px !important; /* 固定logo大小 */
        height: auto !important;
        display: inline-block !important;
        margin: 0 auto !important;
        position: static !important; /* 取消所有定位，避免飘到导航栏 */
    }
    /* 13. 底部信息区 - 重置样式，避免错位 */
    .page9 .dom {
        margin-top: 20px !important;
        padding: 10px !important;
        text-align: center !important;
    }
    .page9 .main-title,
    .page9 .features,
    .page9 .contact-section,
    .page9 .image-row {
        text-align: center !important;
        margin: 10px 0 !important;
    }
    .page9 .feature-item {
        display: inline-block !important;
        width: 18% !important;
        margin: 0 1% !important;
    }
    .page9 .contact-info, .page9 .contact-info1, .page9 .contact-info2, .page9 .contact-info3 {
        text-align: center !important;
        margin: 5px 0 !important;
        display: block !important;
    }
    .page9 .image-item, .page9 .image-item5 {
        display: inline-block !important;
        width: 18% !important;
        margin: 5px 1% !important;
    }
    .page9 .small-icon {
        height: 30px !important;
        width: auto !important;
    }
    .page9 .large-icon {
        height: 60px !important;
        width: auto !important;
    }
    /* 14. 底部版权信息 */
    .page9 .footer {
        text-align: center !important;
        margin-top: 20px !important;
        font-size: 12px !important;
    }


}
/* ========== 合作公司图标 - 大屏/小屏切换 + 小屏强制2列 ========== */
/* 大屏 (>800px)：显示4列，隐藏小屏 */
#partner-lg {
    display: flex !important;
    flex-wrap: wrap !important;
    width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
}
#partner-sm {
    display: none !important;
}
/* 小屏 (≤800px)：隐藏大屏，显示2列+图标放大 */
@media (max-width: 800px) {
    #partner-lg {
        display: none !important;
    }
    #partner-sm {
        display: flex !important;
        flex-wrap: wrap !important;
        width: 100% !important;
        margin: 0 auto !important;
        padding: 0 15px !important;
        /* 核心：清除所有浮动/定位，避免布局错乱 */
        float: none !important;
        position: static !important;
    }
    /* 小屏每列强制50%，严格2列 */
    .partner-col-2 {
        width: 50% !important;
        flex: 0 0 50% !important; /* 固定宽度，不拉伸不压缩 */
        max-width: 50% !important;
        padding: 0 8px !important;
        margin: 10px 0 !important;
        float: none !important;
        position: static !important;
        /* 图标居中 */
        display: flex !important;
        justify-content: center !important;
        align-items: center !important;
    }
    /* 图标放大+防变形 */
    .partner-col-2 .products-use {
        width: 100% !important;
        text-align: center !important;
    }
    .partner-col-2 .products-use img {
        height: 60px !important; /* 保留你满意的尺寸，可微调 */
        width: auto !important;
        max-width: 90% !important;
        object-fit: contain !important;
        display: inline-block !important;
    }
}
/* 800px以下移动端适配 - page9合作伙伴两行布局 */
@media (max-width: 800px) {
    /* 1. 隐藏20.png（保留原有逻辑） */
    .img-hzimg1 {
        display: none !important;
    }

    /* 2. 最外层容器：防溢出+居中+允许换行 */
    .page9 {
        padding: 0 10px !important; /* 左右内边距，防贴边 */
        overflow-x: hidden !important; /* 兜底防溢出 */
    }
    .page9 .container,
    .page9 .row,
    .page9 .col-md-12 {
        padding-left: 0 !important;
        padding-right: 0 !important;
        margin-left: 0 !important;
        margin-right: 0 !important;
        width: 100% !important;
        box-sizing: border-box !important;
    }

    /* 3. 核心：图片父容器（col-md-2）- 两行布局关键 */
    .page9 .col-md-2.col-sm-2.mb-2 {
        width: 100% !important;        /* 占满父容器 */
        max-width: 100% !important;    /* 不超视口 */
        margin: 0 auto !important;     /* 整体居中 */
        padding: 0 !important;
        display: flex !important;
        flex-direction: column !important; /* 垂直排列（两行） */
        flex-wrap: wrap !important;    /* 允许换行 */
        justify-content: center !important; /* 垂直居中 */
        align-items: center !important; /* 水平居中 */
        gap: 10px !important;          /* 两行之间的间距 */
        box-sizing: border-box !important;
    }

    /* 4. 第一行：14.png容器 - 独占一行，居中 */
    .page9 .img-hzimg {
        width: 80% !important;         /* 宽度80%（不超视口） */
        max-width: 350px !important;   /* 最大宽度兜底 */
        display: flex !important;
        justify-content: center !important;
        align-items: center !important;
        margin: 0 auto !important;
    }
    /* 14.png样式：适配容器，不拉伸 */
    .page9 .img-hzimg img {
        width: 100% !important;
        height: auto !important;
        object-fit: contain !important;
        max-width: 350px !important;   /* 最大宽度限制，防过大 */
    }

    /* 5. 第二行：21+22.png容器 - 独占一行，居中 */
    .page9 .image-hzhb {
        width: 80% !important;         /* 和14.png同宽，视觉统一 */
        max-width: 350px !important;
        display: flex !important;
        justify-content: space-around !important; /* 两图均匀分布 */
        align-items: center !important;
        gap: 15px !important;          /* 两图之间的间距 */
        margin: 0 auto !important;
    }
    /* 21/22.png样式：等分宽度，不溢出 */
    .page9 .image-hzhb img {
        width: 45% !important;         /* 每图占容器45%（总90%，留间距） */
        height: auto !important;
        object-fit: contain !important;
        max-width: 350px !important;    /* 最大宽度兜底 */
    }

    /* 6. 隐藏大屏合作伙伴列表（移动端只显示14/21/22） */
    #partner-lg {
        display: none !important;
    }
    .page2 .container {
        margin-top: 20px !important; /* 容器整体下移，可按需调 */
    }
}

/* 小屏适配 - 底部header logo+分割线样式修复 */
@media (max-width: 800px) {
    /* 1. 父容器：垂直排列+整体居中，确保logo和分割线对齐 */
    .headername {
        display: flex !important;
        flex-direction: column !important;
        align-items: center !important; /* 水平居中 */
        justify-content: center !important; /* 垂直居中 */
        width: 100% !important; /* 占满父容器宽度，方便居中 */
        padding: 10px 0 !important; /* 增加上下内边距，视觉更舒适 */
    }

    /* 2. 增大logo尺寸（小屏下），可按需调整数值 */
    .headername .logo {
        width: 400px !important; /* 原尺寸基础上增大，比如从80px→120px */
        height: auto !important; /* 保持宽高比，不拉伸 */
        display: block !important; /* 块级元素，方便后续居中 */
        margin: 0 auto !important; /* 兜底居中 */
    }

    /* 3. 分割线：居中在logo正下方，调整样式+位置 */
    .headername .divider {
        width: 80% !important; /* 分割线宽度适配logo（比如logo120px，分割线96px=80%） */
        max-width: 100px !important; /* 限制最大宽度，避免过宽 */
        height: 2px !important; /* 分割线高度，可微调 */
        background-color: #ccc !important; /* 分割线颜色，按需改 */
        margin: 8px auto 0 !important; /* 关键：top=8px（和logo间距），auto左右居中 */
        display: block !important; /* 确保显示 */
    }
}

/* 小屏适配 - features纯百分比/视口单位适配（一行5个+无溢出+居中） */
@media (max-width: 800px) {
    /* 1. 整个features板块：100%宽度+居中+一行显示+无溢出 */
    .features {
        display: flex !important;
        flex-wrap: nowrap !important; /* 强制一行 */
        justify-content: space-around !important; /* 均匀分布，核心防溢出 */
        align-items: center !important;
        width: 95% !important; /* 占屏幕95%宽度，留边距防溢出 */
        max-width: 100% !important;
        margin: 0 auto !important; /* 整体水平居中 */
        padding: 2vw 0 !important; /* 上下内边距（视口百分比） */
        gap: 1vw !important; /* 间距（视口百分比，自适应屏幕） */
        overflow: hidden !important; /* 兜底防溢出 */
    }

    /* 2. 单个feature-item：百分比宽度，5个均分屏幕 */
    .feature-item {
        display: flex !important;
        flex-direction: column !important; /* 垂直排列 */
        align-items: center !important; /* 内部居中，文字正下方 */
        justify-content: center !important;
        flex: 1 1 0 !important; /* 5个item均分宽度（核心） */
        width: 18vw !important; /* 单个item占屏幕18%（5个=90%，留间距） */
        max-width: 20vw !important;
        margin: 0 !important; /* 清除固定边距 */
    }

    /* 3. feature容器（快/稳/优）：视口单位尺寸，适配屏幕 */
    .feature-container {
        display: flex !important;
        justify-content: center !important;
        align-items: center !important;
        width: 10vw !important; /* 容器宽度=屏幕10% */
        height: 10vw !important; /* 高度和宽度等比，不拉伸 */
        margin: 0 auto !important;
    }

    /* 4. 核心文字（快/稳/优）：视口单位字号，自适应 */
    .feature-text {
        display: block !important;
        text-align: center !important;
        font-size: 4vw !important; /* 字号=屏幕4%，自适应 */
        line-height: 1 !important; /* 清除行高干扰 */
    }

    /* 5. 描述文字（上线快/系统稳）：百分比间距+自适应字号 */
    .feature-desc {
        text-align: center !important; /* 文字居中 */
        margin: 1vw 0 0 0 !important; /* 顶部间距=屏幕1%，无左右边距 */
        padding: 0 !important;
        font-size: 2.5vw !important; /* 字号=屏幕2.5%，自适应 */
        white-space: nowrap !important; /* 不换行 */
        width: 100% !important; /* 占满item宽度 */
    }

    /* 兜底：清除所有可能导致溢出的样式 */
    .features * {
        box-sizing: border-box !important;
        max-width: 100% !important;
    }
}