/* ============================================================
   AI 产品页（list-product-ai.html）PC 端布局适配
   ------------------------------------------------------------
   旧站该页面是「整屏 banner + 1380px 内容宽」，
   而 CMS 默认给内容套了 .ep-container（max-width:1200px + 20px 内边距），
   导致：横幅内容居中后左右被裁、板块宽度错位、窄屏溢出。

   本文件只作用于 body.mxq-product-ai-page，不影响其它页面。
   ============================================================ */

/* 1. 还原为整屏布局，去掉 CMS 容器约束 */
body.mxq-product-ai-page .ep-main {
    margin: 0;
    padding: 0;
}

body.mxq-product-ai-page .ep-main > .ep-container {
    width: 100%;
    max-width: none;
    margin: 0;
    padding: 0;
}

/* 2. 内容宽度跟随视口，任何宽度都不溢出 */
body.mxq-product-ai-page {
    --mainWidth: min(1380px, calc(100vw - 80px));
}

@media screen and (max-width: 1535px) {
    body.mxq-product-ai-page {
        --mainWidth: min(1200px, calc(100vw - 64px));
    }
}

/* 3. 横幅图片改用百分比：100vw 会把滚动条宽度算进去，造成横向滚动 */
body.mxq-product-ai-page .banner .swiper-slide img {
    display: block;
    width: 100%;
    height: auto;
    object-fit: cover;
}

/* 4. 横幅文字随视口缩放，避免长标题撑出容器 */
body.mxq-product-ai-page .banner-title {
    font-size: clamp(28px, 3.4vw, 48px);
    line-height: 1.25;
}

body.mxq-product-ai-page .banner-m-title {
    font-size: clamp(18px, 2vw, 28px);
}

body.mxq-product-ai-page .banner-des {
    width: auto;
    max-width: 690px;
    font-size: clamp(14px, 1.15vw, 18px);
    line-height: 1.65;
}

body.mxq-product-ai-page .banner-btn {
    margin-top: clamp(24px, 4vw, 68px);
}

body.mxq-product-ai-page .btn-item {
    min-width: clamp(140px, 13vw, 180px);
    height: clamp(46px, 3.8vw, 56px);
    line-height: clamp(46px, 3.8vw, 56px);
    font-size: clamp(16px, 1.5vw, 22px);
}

/* 5. 窄屏：板块间距收紧，四宫格改两列 */
@media screen and (max-width: 1200px) {

    body.mxq-product-ai-page .problem,
    body.mxq-product-ai-page .detail6 {
        margin-top: 60px;
    }

    body.mxq-product-ai-page .problem-main {
        flex-wrap: wrap;
        gap: 20px;
    }

    body.mxq-product-ai-page .problem-main-item {
        flex: 1 1 calc(50% - 20px);
        height: auto;
        min-height: 320px;
    }

    body.mxq-product-ai-page .problem-main-item ~ .problem-main-item {
        margin-left: 0;
    }
}

/* 6. 竖屏平板以下再收一档 */
@media screen and (max-width: 900px) {

    body.mxq-product-ai-page .banner-title {
        font-size: clamp(22px, 4vw, 32px);
    }

    body.mxq-product-ai-page .banner-m-title {
        font-size: 16px;
    }

    body.mxq-product-ai-page .banner-des {
        font-size: 14px;
    }

    body.mxq-product-ai-page .problem-main-item {
        flex: 1 1 100%;
        min-height: 280px;
    }
}
