/* ============================================================
 * 后厨管家官网 — 移动端响应式适配
 * 策略：所有规则均包裹在媒体查询内，桌面端 (>1300px) 零影响
 * 断点：1300px 容器流体化 / 1024px 汉堡导航+单列堆叠 / 768px 手机精调
 * ============================================================ */

/* 汉堡按钮默认隐藏，仅 ≤1024px 显示（按钮由 mobile.js 注入） */
.nav-toggle { display: none; }

/* ===== ≤1300px：容器流体化，防止横向滚动 ===== */
@media (max-width: 1300px) {
    html, body { overflow-x: hidden; }
    body { min-width: 0 !important; }
    .container { width: 100% !important; padding-left: 20px; padding-right: 20px; }
    .advisory { left: auto; right: 16px; margin-left: 0; transform: none; }
}

/* ===== ≤1024px：汉堡导航 + 单列堆叠布局 ===== */
@media (max-width: 1024px) {

    /* ---- 头部导航 ---- */
    .header { height: 56px; }
    .header .logo { margin: 16px 0; }
    .header .title { display: none; }

    .nav-toggle {
        position: absolute;
        top: 0;
        right: 12px;
        display: flex;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: 5px;
        width: 44px;
        height: 56px;
        cursor: pointer;
        -webkit-tap-highlight-color: transparent;
    }
    .nav-toggle > span {
        display: block;
        width: 22px;
        height: 2px;
        border-radius: 1px;
        background: #333333;
        transition: transform 0.25s ease, opacity 0.25s ease;
    }
    .header.nav-open .nav-toggle > span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
    .header.nav-open .nav-toggle > span:nth-child(2) { opacity: 0; }
    .header.nav-open .nav-toggle > span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

    .header .nav {
        display: none;
        position: absolute;
        top: 56px;
        left: 0;
        right: 0;
        height: auto;
        max-height: calc(100vh - 56px);
        overflow-y: auto;
        background: #ffffff;
        border-top: 1px solid #F0F2F5;
        box-shadow: 0 12px 24px rgba(17, 30, 57, 0.10);
    }
    .header.nav-open .nav { display: block; }
    .header .nav > ul { white-space: normal; }
    .header .nav > ul > li {
        display: block;
        margin: 0;
        height: auto;
        line-height: 48px;
    }
    .header .nav > ul > li + li { border-top: 1px solid #F0F2F5; }
    .header .nav > ul > li > a { display: block; padding: 0 20px; font-size: 15px; }
    .header .nav > ul > li.active::after { display: none; }
    .header .nav > ul > li.dropdown .icon { display: none; }
    .header .nav .dropdown-menu {
        position: static;
        display: block !important;
        margin: 0;
        padding: 0;
        transform: none;
        border: none;
        border-radius: 0;
        box-shadow: none;
        background: #F7F9FE;
        animation: none;
    }
    .header .nav .dropdown-menu::before,
    .header .nav .dropdown-menu::after { display: none; }
    .header .nav .dropdown-menu > li > a {
        padding-left: 36px;
        line-height: 44px;
        text-align: left;
        white-space: normal;
    }

    /* ---- banner ---- */
    .banner { padding-top: 56px; }
    .banner .swiper-container { height: 320px !important; }
    .banner .swiper-container .swiper-slide img {
        left: 0;
        width: 100% !important;
        transform: none;
        object-fit: cover;
    }
    .banner .swiper-slide-wrap {
        height: 100% !important;
        background-size: cover !important;
        background-position: center !important;
    }
    .swiper-slide-abs { font-size: 30px !important; line-height: 44px !important; }
    .swiper-slide-sub { font-size: 20px !important; line-height: 30px !important; margin-top: 14px !important; }
    .banner-news, .banner-about, .banner-join { height: 320px !important; }
    .banner-join .banner-join-title { font-size: 32px !important; }

    /* ---- 全局堆叠 ---- */
    .box-title { font-size: 26px !important; }
    section:not(.banner) img, .footer img { max-width: 100% !important; height: auto !important; }
    [class*="col-"]:not(.col-center) { width: 100% !important; float: none !important; }

    /* ---- footer ---- */
    .footer { height: auto !important; padding: 10px 0 30px; }
    .footer .footer-left, .footer .footer-mid, .footer .footer-right {
        float: none;
        margin: 30px 0 0;
        width: 100%;
    }
    .footer .footer-left { text-align: left; }
    .footer .footer-left .footer-qrcode { width: 120px; height: 120px; }
    .footer .footer-mid .footer-map { width: 100%; max-width: 260px; }
    .footer .footer-link { width: 100%; height: 44px; line-height: 44px; }
    .footer .footer-link:nth-child(even) { margin-left: 0; }
    .filing { height: auto; padding: 12px 16px; line-height: 1.8; }

    /* ---- 咨询浮窗 / 试用弹窗 ---- */
    .advisory { left: auto; right: 10px; bottom: 20px; margin-left: 0; transform: none; }
    .advisory .advisory-btn { width: 52px; height: 52px; padding: 8px; font-size: 10px; }
    .advisory .advisory-btn .advisory-btn-phone { width: 17px; height: 19px; margin-bottom: 3px; }
    .advisory .advisory-btn .advisory-btn-wechat { width: 19px; height: 19px; margin-bottom: 3px; }
    .advisory .advisory-btn .advisory-btn-try { width: 17px; height: 17px; margin-bottom: 4px; }
    .advisory .advisory-panel { right: 60px; }
    .advisory .advisory-panel.advisory-panel__phone { padding: 8px 16px; }
    .advisory .advisory-panel.advisory-panel__phone .advisory-panel-item { padding: 12px 0; font-size: 14px; }
    .try-dialog { width: 92%; }
    .try-dialog .try-dialog-header { padding: 24px; }
    .try-dialog .try-dialog-header > h1 { font-size: 24px; }
    .try-dialog .try-dialog-body { padding: 0 24px 30px; }

    /* ---- 首页 ---- */
    .advantage { padding-top: 50px; }
    .advantage .box { flex-direction: column; align-items: center; gap: 28px; margin-top: 36px; padding-bottom: 50px; }
    .advantage .box > div { width: 100% !important; }
    .solution { padding: 50px 0 60px; }
    .solution .box-title, .chooseus .box-title { margin-bottom: 40px !important; }
    .solution .solution-link { margin-bottom: 36px; }
    .solution .solution-link:last-child { margin-bottom: 0; }
    .solution .solution-img { width: 100% !important; height: auto !important; }
    .solution p { width: 100% !important; }
    .chooseus { padding: 50px 0 40px; }
    .chooseus .chooseus-item { width: 100% !important; }
    .customer { padding: 50px 0 60px; }
    .customer .customer-img { height: auto !important; margin-top: 30px; }
    .evaluate { padding: 50px 0 60px; }
    .evaluate .evaluate-img { width: 100% !important; height: auto !important; }
    .evaluate .evaluate-box { float: none; width: 100% !important; height: auto !important; padding: 26px; margin-top: 20px; }

    /* ---- 解决方案页（school/tuancan/liansuo 共用 solution.css） ---- */
    .feature { padding: 40px 0 50px; }
    .feature .box-title { margin-bottom: 44px !important; }
    .feature .feature-label { font-size: 17px; }
    .why { padding: 40px 0 50px; }
    .why .box-title { margin-bottom: 48px !important; }
    .why .why-box { display: block; width: 100% !important; min-height: 0; margin-bottom: 32px; }
    .painspot { padding: 40px 0 60px; }
    .painspot .box-title { margin-bottom: 48px !important; }
    .painspot .painspot-content { padding: 0; }
    .painspot .painspot-box { display: block; width: 100% !important; margin-bottom: 36px; padding-bottom: 22px; }
    .solution .solution-content { width: 100% !important; padding: 0; }
    .solution .solution-box {
        position: relative !important;
        top: auto !important;
        right: auto !important;
        width: 100% !important;
        height: auto !important;
        margin-bottom: 20px;
    }
    .solution .solution-img { position: relative !important; width: 100% !important; height: auto !important; }
    .composition { height: auto !important; padding-bottom: 50px; }
    .composition .composition-content { height: auto !important; padding-top: 40px; }
    .composition .composition-bg-img { width: 100% !important; height: 120px !important; }
    .composition .composition-box { position: static !important; margin-top: 24px; }
    .composition .composition-box .composition-box-cal { position: relative; top: auto; margin-bottom: 16px; }
    .composition .composition-box .composition-box-line { display: none; }
    .composition .composition-box .composition-box-img {
        display: block;
        width: 100% !important;
        height: auto !important;
        margin-bottom: 20px;
    }
    .composition .composition-box .composition-box-img > img { height: auto !important; }
    .flow { padding: 40px 0 50px; }
    .flow .box-title { margin-bottom: 36px !important; }
    .flow .flow-img { width: 100% !important; height: auto !important; }
    .handle { padding: 40px 0; }
    .handle .box-title { margin-bottom: 40px !important; }
    .handle .handle-content { padding-top: 0; border-top: none; }
    .handle .handle-box { display: block; width: 100% !important; margin-bottom: 24px; }
    .handle .handle-box::before { display: none; }
    .info { padding: 40px 0 50px; }
    .info .box-title { margin-bottom: 36px !important; }
    .info .info-show-title { margin-top: 40px; }
    .info .info-show-swiper {
        width: 100% !important;
        height: auto !important;
        padding-top: 0 !important;
        background: none !important;
    }
    .info .swiper-container { width: 100% !important; height: auto !important; }
    .info .swiper-container .swiper-slide img {
        position: static !important;
        width: 100% !important;
        height: auto !important;
        transform: none !important;
    }
    .info .swiper-container .swiper-slide p {
        position: static !important;
        transform: none !important;
        padding: 12px 0 24px;
        font-size: 14px;
        text-align: center;
        white-space: normal;
    }
    .gov { height: auto !important; padding-bottom: 40px; overflow: visible; }
    .gov .gov-img { width: 100% !important; height: auto !important; margin: 30px 0 0 !important; }
    .effect { padding: 40px 0 50px; }
    .effect .box-title { margin-bottom: 36px !important; }

    /* ---- 团餐页 ---- */
    .benefit { height: auto !important; padding-bottom: 40px; }
    .benefit .composition-box { top: auto; }
    .benefit .time { position: static !important; margin-top: 30px; }
    .benefit .time > img { margin-top: 20px; }
    .stock { padding-top: 40px; }
    .stock .container .img-box { margin: 30px 0 40px; }
    .stock .container .img-box > img { width: 100% !important; height: auto !important; }
    .safe .container, .purchase .container, .management .container, .monitor .container {
        flex-direction: column;
        padding: 40px 20px !important;
    }
    .safe .container .content, .management .container .content { text-align: left; margin-bottom: 24px; }
    .safe .safe-img, .purchase .purchase-img, .management .management-img, .monitor .tv-monitor-img {
        width: 100% !important;
        height: auto !important;
        margin-top: 24px;
    }
    .safe .container .scale { width: 60% !important; margin: 24px auto 0 !important; }
    .example { padding: 40px 0; }
    .example-img { width: 100% !important; }

    /* ---- 生鲜 / 中央厨房页 ---- */
    .desc { padding: 40px 0 50px; }
    .desc-content { flex-direction: column; padding: 24px 16px; }
    .desc-content img { order: -1; margin-bottom: 16px; }
    .desc-p { width: 100% !important; margin: 0 !important; }
    .group { padding-bottom: 40px; }
    .group-content { flex-direction: column; align-items: center; margin-top: 36px; }
    .group-list { width: 100% !important; }
    .group-list li, .group-list:nth-child(1) li {
        justify-content: flex-start !important;
        padding-left: 20px !important;
        padding-right: 0 !important;
        text-align: left !important;
    }
    .group-content > img { margin: 20px 0; }
    .cases { padding: 40px 0 30px; }
    .cases-content { margin-top: 30px; }
    .case-item { width: 100% !important; height: auto !important; padding: 24px 16px; }
    .case-desc { width: 100% !important; }
    .tools { padding: 40px 0 30px; }
    .tools-content { flex-direction: column; margin-top: 24px; }
    .system { padding: 40px 0; }
    .system img { margin-top: 24px; }
    .admin { padding: 40px 0 50px; }
    .good { padding-bottom: 40px; }
    .good-imgs { margin-top: 24px; }
    .power { padding: 40px 0; }
    .power img { margin-top: 24px; }
    .power-desc { flex-direction: column; height: auto !important; gap: 8px; margin-top: 16px; }
    .power-desc > span { padding: 0; }
    .advantage-list { margin-top: 36px; }
    .advantage-item { flex-direction: column; align-items: flex-start; margin-bottom: 24px; }
    .advantage-item-border { width: 100%; margin-top: 12px; }
    .advantage-item-title { font-size: 18px; }
    .advantage-item-desc { font-size: 14px; }

    /* ---- 智能装备页 ---- */
    .pdt { margin-top: 0 !important; padding-bottom: 40px; }
    .pdt .pdt-box { padding: 20px 16px; margin-bottom: 20px; }
    .pdt-box-title { font-size: 22px; margin-bottom: 20px; }
    .pdt .pdt-box .pdt-box-img__a, .pdt .pdt-box .pdt-box-img__b, .pdt .pdt-box .pdt-box-img__c {
        display: block;
        margin: 0 auto 20px !important;
        width: auto !important;
        height: auto !important;
        max-width: 70% !important;
        max-height: 320px;
    }
    .pdt .pdt-box .pdt-box-info__a, .pdt .pdt-box .pdt-box-info__b, .pdt .pdt-box .pdt-box-info__c {
        margin-top: 0 !important;
        padding: 0 !important;
    }
    .pdt .pdt-box .pdt-box-feature { height: auto !important; margin-top: 16px; }
    .pdt .pdt-box .pdt-box-feature [class*="col-feature"] { width: 100% !important; margin-bottom: 16px; }
    .pdt .pdt-box .pdt-box-parameter .pdt-box-parameter__box { white-space: normal; }
    .pdt .pdt-box .pdt-box-parameter .pdt-box-parameter__item {
        display: block;
        padding: 10px 0;
        border-left: none !important;
        border-top: 1px dashed #DFDFDF;
    }
    .pdt .pdt-box .pdt-box-parameter .pdt-box-parameter__item:first-child { border-top: none; }
    .pdt .pdt-customize { height: auto !important; line-height: 1.6 !important; padding: 20px 16px; }
    .pdt .pdt-customize .icon { margin-left: 0; }
    .pdt .pdt-customize .pdt-customize-title { margin: 0 10px; font-size: 20px; }
    .pdt .pdt-customize .pdt-customize-text { display: block; margin-top: 6px; font-size: 14px; }
    .pdt .pdt-customize .pdt-customize-img { display: none; }

    /* ---- 农贸市场 / 配送页 ---- */
    .introduce { padding: 40px 0 50px; }
    .introduce .content-box { flex-direction: column; }
    .introduce .content-box img { width: 100% !important; height: auto !important; }
    .introduce .content-box .text { padding: 24px 20px; font-size: 15px; }
    .construct { padding: 40px 0 50px; }
    .construct img { width: 100% !important; height: auto !important; margin-top: 30px; }
    .wisdom { padding: 40px 0; }
    .wisdom img { width: 100% !important; height: auto !important; }

    /* ---- 加入我们页 ---- */
    .recruit .recruit-box { padding: 30px 0 40px; }
    .recruit .recruit-box ul.recruit-box-position {
        float: none;
        display: flex;
        width: 100% !important;
        border-left: none;
        border-bottom: 2px solid rgba(51, 51, 51, 0.10);
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
    .recruit .recruit-box ul.recruit-box-position > li { flex-shrink: 0; padding: 12px 16px; }
    .recruit .recruit-box ul.recruit-box-position > li.active::before {
        left: 0;
        top: auto;
        bottom: -2px;
        width: 100%;
        height: 2px;
        transform: none;
    }
    .recruit .recruit-box .recruit-box-content { float: none; width: 100% !important; margin-top: 20px; }

    /* ---- 关于我们页 ---- */
    .about .container { width: 100% !important; }
    .about-title { font-size: 24px; }
    .introduce .introduce-text { width: 100% !important; margin: 24px 0; }
    .introduce .company-img { position: static !important; width: 100% !important; height: auto !important; margin-top: 20px; }
    .achievement { padding: 40px 0 20px; }
    .achievement .achievement-box { display: block; width: 100% !important; }
    .achievement .achievement-box .achievement-box-img { height: auto !important; }
    .achievement .achievement-box .achievement-box-label { height: auto !important; }
    .contact { padding: 30px 0; }
    .contact .contact-qrcode { position: static !important; margin-top: 20px; font-size: 14px; }
    .contact .contact-qrcode > .contact-qrcode-box { margin: 0 16px 0 0; }
    .contact .contact-qrcode > .contact-qrcode-box > img { width: 100px; height: 100px; }
    .contact .contact-map { padding-top: 30px; }
    .contact .contact-map > #map_container { height: 260px !important; }
    .value { padding: 40px 0 60px; }
    .value-tabs { width: 100% !important; }
    .value-tab { font-size: 16px !important; line-height: 24px !important; margin-bottom: 24px; }
    .value-tab-active { font-size: 20px !important; line-height: 30px !important; }
    .value-tab-text { margin-bottom: 10px; }
    .value-arrow { border-bottom-width: 10px; border-left-width: 6px; border-right-width: 6px; }
    .value-tab-content { font-size: 15px !important; line-height: 24px !important; }
    .value-tab-content-1, .value-tab-content-3 { flex-direction: column; gap: 20px; }
    .network { padding: 40px 0 50px; }
    .network-title { font-size: 22px; margin-bottom: 20px; }
    .network-between { flex-direction: column; margin-bottom: 20px; }

    /* ---- 城市合伙人页 ---- */
    .copartner-banner-abs, .apply .apply-content > img { display: none; }
    .apply { padding: 40px 0 50px; }
    .apply .apply-content { flex-direction: column; margin-top: 36px; }
    .apply-content .apply-form-item { flex-direction: column; margin-bottom: 0; }
    .apply-form-item-single { margin-bottom: 16px; }
    .apply-form-item-single input {
        width: 100% !important;
        height: 44px;
        padding: 0 12px;
        font-size: 16px;
    }
    .apply-form-item-single textarea {
        width: 100% !important;
        height: 100px !important;
        padding: 10px 12px;
        font-size: 16px;
    }
    .margin-right-40 { margin-right: 0 !important; }
    .apply .layui-form { position: static !important; top: auto !important; margin: 0 !important; width: 100%; }
    .apply .layui-form .layui-form-item { margin-bottom: 16px; }
    .apply .layui-inline, .apply .layui-inline-site, .apply .layui-form .layui-inline {
        display: block;
        width: 100% !important;
        margin: 0 0 10px !important;
    }
    .apply .layui-form .layui-input { width: 100%; height: 44px; font-size: 16px; }
    .apply .layui-form .layui-form-select { width: 100%; }
    .apply-form-submit { width: 100% !important; height: 46px !important; margin-top: 10px; font-size: 16px; }
    .apply-form-submit > span { line-height: 46px; }
    .advantage-wrap { justify-content: center; gap: 16px; }
    .advantage-wrap img { width: 46% !important; margin-top: 0; }
    .support { padding: 40px 0; }
    .support-list { flex-wrap: wrap; gap: 24px 0; margin-top: 36px; }
    .support-item { width: 48% !important; }
    .support-item-title { font-size: 16px; }
    .layui-layer { width: 92% !important; left: 4% !important; }
}

/* copartner banner 按钮图（swiper-slide-abs 为 247×75 图片按钮） */
@media (max-width: 1024px) {
    .banner .swiper-slide-abs[src*="cp-banner"] {
        left: 50% !important;
        top: auto !important;
        bottom: 26px !important;
        width: 170px !important;
        height: 52px !important;
        transform: translateX(-50%) !important;
    }
}

/* ===== ≤768px：手机端精调（字号 / 间距 / banner 高度） ===== */
@media (max-width: 768px) {
    .container { padding-left: 16px; padding-right: 16px; }
    .box-title { font-size: 22px !important; }
    .box-title.with-line::after { bottom: -5px; height: 10px; }
    .banner .swiper-container { height: 200px !important; }
    .banner-news, .banner-about, .banner-join { height: 200px !important; }
    .banner-join .banner-join-title { font-size: 24px !important; }
    .banner-join .banner-join-text { font-size: 14px !important; }
    .swiper-slide-abs { font-size: 22px !important; line-height: 32px !important; }
    .swiper-slide-sub { font-size: 15px !important; line-height: 24px !important; margin-top: 10px !important; }
    .try-dialog .try-dialog-header > h1 { font-size: 20px; }

    /* 表单输入 16px，避免 iOS 聚焦自动缩放 */
    input, select, textarea { font-size: 16px; }

    /* 触控目标加高 */
    .footer .footer-link { height: 46px; line-height: 46px; }
    .solution a { width: 132px; height: 36px; line-height: 36px; }
}
