/**
 * 全站移动端与平板响应式补充（≤1024px 为主，768/480 细化）
 * 在 common.css、main.css 之后加载
 */

@media only screen and (max-width: 1024px) {
    html {
        -webkit-text-size-adjust: 100%;
    }
    body,
    #app {
        overflow-x: hidden;
        max-width: 100%;
    }
    img,
    video,
    iframe {
        max-width: 100%;
    }

    .header .ph-box .marginAuto {
        height: var(--header-mobile-h, 48px);
        min-height: 0;
        padding-top: 0;
        padding-bottom: 0;
        align-items: center;
    }
    .header .ph-box .logo {
        display: flex;
        align-items: center;
        min-height: 0;
    }
    .header .ph-box .logo img {
        max-width: 132px;
        max-height: 28px;
        width: auto;
        height: auto;
        object-fit: contain;
        display: block;
    }
    .header .phone-menu {
        display: flex;
        align-items: center;
        min-height: 0;
        padding-left: 8px;
        flex-shrink: 0;
    }
    .header .phone-menu .mobile-menu {
        width: 40px;
        height: 40px;
        padding: 0;
        display: flex;
        align-items: center;
        justify-content: center;
        position: relative;
    }
    .header .phone-menu .menu-i-1 {
        top: 12px;
    }
    .header .phone-menu .menu-i-2 {
        top: 19px;
    }
    .header .phone-menu .menu-i-3 {
        top: 26px;
    }
    .phone-more-menu .pd .cell {
        background: #fff;
        border-bottom-color: #eee;
    }

    /* 新闻详情：避免右侧 padding 造成横向溢出 */
    .news-c .left {
        padding-right: 0 !important;
        box-sizing: border-box;
    }
    .news-c .left .content {
        overflow-wrap: break-word;
        word-break: break-word;
    }
    .news-c .left .content table {
        display: block;
        width: 100% !important;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    /* 产品列表：触控设备无 hover，摘要常显 */
    .p-main .list .cell .cell-link {
        display: flex;
        flex-direction: column;
    }
    .p-main .list .cell img {
        height: 200px;
        object-fit: cover;
        border-radius: 8px 8px 0 0;
    }
    /* 移动端常显 .info，隐藏叠在图上的 .p-title，避免标题重复 */
    .p-main .list .cell .p-title {
        display: none;
    }
    .p-main .list .cell .info {
        display: block;
        position: static;
        height: auto;
        min-height: 0;
        border-radius: 0 0 8px 8px;
        padding: 18px 20px 22px;
    }
    .p-main .list .cell .info .label {
        font-size: 18px;
        line-height: 1.4;
        padding-bottom: 4px;
    }
    .p-main .list .cell .info .value {
        padding: 10px 0 14px;
        font-size: 14px;
        line-height: 1.6;
    }

    .p-case-videos {
        padding: 40px 0 48px;
    }
    .p-case-videos .label {
        font-size: 22px;
        margin-bottom: 20px;
    }
    .p-case-videos .value {
        padding: 0;
    }
    .p-case-videos .case-video-grid__item {
        width: 100%;
        max-width: 100%;
    }
    .case-video-thumb {
        max-width: 100%;
    }
    .case-video-modal__dialog {
        padding: 16px 12px 20px;
    }
    body.case-video-modal-open {
        overflow: hidden;
    }

    /* 产品详情参数表 */
    .p-details .cell .value {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
    .p-details .cell .value table {
        min-width: 280px;
    }
    .p-details .cell .value table tr td {
        font-size: 14px;
        padding: 8px;
        white-space: nowrap;
    }
    .p-details .cell .label {
        font-size: 22px;
        margin-bottom: 16px;
    }

    .page-path {
        font-size: 18px;
        line-height: 1.4;
        padding: 14px 0;
    }

    .list-category-filter,
    .product-filter {
        padding: 12px 14px;
        gap: 8px;
        margin-bottom: 24px;
    }
    .list-category-filter a,
    .product-filter a {
        padding: 7px 14px;
        font-size: 14px;
    }
    .list-section-title,
    .product-section-title {
        font-size: 18px;
    }

    .pages {
        padding-top: 24px;
        flex-wrap: wrap;
        justify-content: center;
        gap: 4px;
    }
    .pages .prev,
    .pages .next,
    .pages .num {
        margin: 4px 2px;
    }

    .solution .text-main,
    .solution .text-main p {
        overflow-wrap: break-word;
        word-break: break-word;
    }

    /* 页脚搜索：标题与输入框纵向排列，避免标题被压成竖排单字 */
    .footer .top {
        padding: 28px 0;
    }
    .footer .top .marginAuto {
        flex-direction: column;
        align-items: stretch;
    }
    .footer .top .left {
        flex: none !important;
        width: 100% !important;
        min-width: 0;
        max-width: 100%;
        font-size: 20px;
        line-height: 1.45;
        padding-bottom: 16px;
        white-space: normal;
        word-break: normal;
    }
    .footer .top .marginAuto > form {
        width: 100%;
        max-width: 100%;
    }
    .footer .top .form {
        width: 100% !important;
        max-width: 100%;
        box-sizing: border-box;
    }
    .footer .top .form input {
        width: 0 !important;
        min-width: 0;
        flex: 1 1 auto;
        max-width: 100%;
        height: 48px;
        box-sizing: border-box;
    }
    .footer .top .form button {
        flex-shrink: 0;
        height: 48px;
    }

    .footer .bottom .copyright {
        font-size: 12px;
        line-height: 1.6;
        text-align: center;
    }

    /* 产品详情：资料下载等白底区块 */
    .p-details .cell .value {
        padding: 16px;
    }
    .p-details .cell .value table tr td {
        white-space: normal;
        word-break: break-word;
    }
    .p-details .cell .value a {
        display: inline-block;
        color: #B81D22;
        font-size: 15px;
        line-height: 1.5;
        padding: 4px 0;
    }

    /* 手机侧栏：搜索与联系 */
    .phone-more-menu .phone-menu-search {
        padding: 12px 16px 16px;
        background: #fff;
        border-bottom: 1px solid #eee;
        position: sticky;
        top: 0;
        z-index: 1;
    }
    .phone-more-menu .phone-menu-search .search-row {
        display: flex;
        align-items: center;
        border: 1px solid #ddd;
        border-radius: 4px;
        overflow: hidden;
        background: #fff;
    }
    .phone-more-menu .phone-menu-search input {
        flex: 1;
        border: none;
        padding: 12px 14px;
        font-size: 15px;
        min-width: 0;
    }
    .phone-more-menu .phone-menu-search button {
        border: none;
        background: #B81D22;
        color: #fff;
        padding: 12px 16px;
        font-size: 14px;
        cursor: pointer;
    }
    .phone-more-menu .phone-menu-cta {
        padding: 20px 16px 28px;
    }
    .phone-more-menu .phone-menu-cta a {
        display: block;
        text-align: center;
        background: #B81D22;
        color: #fff !important;
        padding: 14px;
        border-radius: 4px;
        font-size: 16px;
    }

    body.nav-open-noscroll {
        overflow: hidden !important;
        height: 100%;
    }

    /* 全站：flex 子项防撑破视口 */
    .flex-row,
    .flex-row.align-items-center {
        flex-wrap: wrap;
    }
    .flex-row > .flex-1 {
        min-width: 0;
    }
    .marginAuto {
        box-sizing: border-box;
    }

    /* 首页轮播 */
    .banner,
    .banner .swiper-wrapper,
    .banner .swiper-slide {
        max-width: 100%;
    }

    /* 工具计算器 */
    .tools-hero {
        padding: 28px 0 22px;
    }
    .tools-hero-title {
        font-size: 22px;
        line-height: 1.35;
    }
    .tools-hero-desc {
        font-size: 14px;
        padding: 0 4px;
    }
    .tools-grid-wrap {
        padding: 24px 0 40px;
    }
    .tool-topbar {
        padding: 10px 0;
    }
    .tool-topbar .marginAuto {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    .tool-breadcrumb {
        font-size: 13px;
        line-height: 1.5;
        word-break: break-word;
    }
    .tool-sibling-links {
        width: 100%;
        gap: 6px;
    }
    .tool-sibling-links a {
        flex: 1 1 calc(50% - 6px);
        text-align: center;
        font-size: 12px;
        padding: 8px 6px;
        min-width: 0;
        box-sizing: border-box;
    }
    .tool-embed-wrap {
        padding: 0 0 28px;
        overflow-x: hidden;
    }
    .tool-embed-frame {
        width: 100% !important;
        max-width: 100%;
        min-height: 480px;
    }
    .tool-page .tool-main {
        padding: 20px 0 40px;
    }
    .tool-page-title {
        flex-direction: column;
        align-items: flex-start;
    }
    .tool-actions {
        width: 100%;
        flex-wrap: wrap;
    }
    .tool-actions .btn-tool {
        flex: 1 1 calc(50% - 6px);
        text-align: center;
    }
    .cauchy-panel {
        min-width: 0;
        width: 100%;
        flex: 1 1 100%;
    }
    .cauchy-table-wrap {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    /* 页脚信息区 */
    .footer .bottom .info {
        flex-direction: column;
    }
    .footer .bottom .info .center {
        width: 100%;
        padding-top: 20px;
    }
    .footer .bottom .info .center .flex-row {
        flex-direction: column;
    }
    .footer .bottom .info .center .cell {
        width: 100%;
        margin-bottom: 12px;
    }
    .footer .bottom .info .right {
        width: 100%;
        padding-top: 16px;
    }

    /* 联系我们 / 关于 */
    .cc1 .marginAuto .wrap .label {
        font-size: 24px !important;
        line-height: 1.35;
    }
    .cc2 .left iframe {
        max-width: 100%;
    }

    /* 详情与富文本 */
    .p-top .content,
    .solution .text-main,
    .about-content {
        overflow-wrap: break-word;
        word-break: break-word;
    }
    .p-details .cell .value img,
    .news-c .left .content img {
        max-width: 100% !important;
        height: auto !important;
    }

    /* 表格横向滚动 */
    .content table,
    .text-main table,
    .value table {
        display: block;
        max-width: 100%;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
}

@media only screen and (max-width: 768px) {
    .title-box .name {
        font-size: 26px !important;
    }
    .title-box .des {
        width: 100% !important;
    }

    .news-main .cell .left .title {
        font-size: 20px;
    }
    .news-c .left .title {
        font-size: 20px !important;
    }
    .news-c .right .cell .text {
        font-size: 15px;
    }

    .p-top .content .label {
        font-size: 26px !important;
    }

    .about-nav .cell {
        font-size: 13px;
    }

    .ac2 .left .label,
    .ac7 .label {
        font-size: 26px !important;
    }
}

@media only screen and (max-width: 480px) {
    .header .ph-box .logo img {
        max-width: 118px;
        max-height: 24px;
    }
    .page-path {
        font-size: 16px;
    }
    .pages .num {
        min-width: 28px;
        width: auto;
        padding: 0 6px;
        font-size: 12px;
    }
    .news-c .right .cell img {
        width: 88px;
        height: 56px;
    }

    .tools-hero-title {
        font-size: 20px;
    }
    .tool-sibling-links a {
        flex: 1 1 100%;
    }
    .list-category-filter a,
    .product-filter a {
        flex: 1 1 calc(50% - 8px);
        text-align: center;
    }
    .title-box .name {
        font-size: 22px !important;
    }
    .footer .top .left {
        font-size: 18px;
    }
}
