/* products — 全部限定 body.page-h5.page-products，不影响 PC */
@media (max-width: 992px) {
  /* 底部 Tabbar 固定定位，留白放在内容区底部，不再靠 --h5-main-h 锁高度 */
  body.page-h5.page-products {
    padding-bottom: 0;
    --cp-h5-edge: calc(40 / 1080 * 100vw);
    --cp-h5-cat-w: calc(238 / 1080 * 100vw);
    --cp-h5-cat-h: 36px;
    --cp-h5-cat-h-tall: 48px;
    --cp-h5-cat-gap-y: calc(32 / 1080 * 100vw);
    --cp-h5-cat-gap-x: calc(16 / 1080 * 100vw);
    --cp-h5-pic-col: calc(206 / 1080 * 100vw);
    --cp-h5-pic-h: calc(var(--cp-h5-pic-col) * 155 / 206);
    --cp-h5-pic-gap: calc(24 / 1080 * 100vw);
    --cp-h5-pic-offset: calc(20 / 1080 * 100vw);
    /* Banner 高度随文案自适应，硬件/软件切换共用同一套排版 */
    --cp-h5-banner-min-h: auto;
    --cp-h5-tabs-h: calc(12px + 56px + 12px);
    --cp-h5-modal-gap-x: 30px;
    --cp-h5-modal-main-h: calc(100vw - 2 * var(--cp-h5-modal-gap-x));
    --cp-h5-modal-thumb-gap: 8px;
    --cp-h5-modal-thumb-row-h: 62px;
    --cp-h5-modal-gallery-h: calc(var(--cp-h5-modal-main-h) + var(--cp-h5-modal-thumb-gap) + var(--cp-h5-modal-thumb-row-h));
    --cp-h5-modal-mask-top: 40px;
    --cp-h5-modal-lift: 56px;
    --cp-h5-modal-mode-gap: 12px;
  }

  body.page-h5.page-products .products-main.page-main {
    display: flex;
    flex-direction: column;
    margin-top: var(--h5-header);
    height: var(--h5-main-h);
    max-height: var(--h5-main-h);
    overflow: hidden;
  }

  /* 顶部 Banner：高度随文案自适应 */
  body.page-h5.page-products .cp-banner {
    flex-shrink: 0;
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: minmax(0, auto);
    position: relative;
    width: 100%;
    max-width: none;
    height: auto;
    min-height: 0;
    max-height: none;
    overflow: hidden;
  }

  body.page-h5.page-products .cp-banner-img,
  body.page-h5.page-products .cp-banner-inner,
  body.page-h5.page-products .cp-banner-toolbar {
    grid-area: 1 / 1;
  }

  body.page-h5.page-products .cp-banner-toolbar--software {
    display: none;
  }

  body.page-h5.page-products .products-main:has(#cp-cat-cabinet:checked) #cp-type-software:checked ~ .cp-banner .cp-banner-toolbar--software,
  body.page-h5.page-products .products-main:has(#cp-cat-cabinet:checked)[data-cp-type="software"] .cp-banner-toolbar--software {
    display: flex;
  }

  body.page-h5.page-products .cp-banner-img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    min-height: 0;
    max-height: none;
    object-fit: cover;
    z-index: 0;
  }

  body.page-h5.page-products .cp-banner-inner {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    height: auto;
    min-height: 0;
    padding: 14px 15px 12px;
    box-sizing: border-box;
  }

  body.page-h5.page-products .cp-banner-title {
    display: block !important;
    visibility: visible !important;
    margin: 0;
    font-size: 22px;
    font-weight: 700;
    line-height: 1.2;
    text-align: center;
    color: #C8CED6 !important;
    -webkit-text-fill-color: #C8CED6;
  }

  body.page-h5.page-products .cp-banner-line {
    width: 72px;
    margin-top: 8px;
    height: 2px;
  }

  body.page-h5.page-products .cp-banner-desc {
    width: 100%;
    margin: 8px 0 0;
    font-size: 11px;
    line-height: 18px;
    text-align: center;
    color: #C8CED6;
  }

  /* 软件平台 Banner：展示软件描述，硬件描述隐藏 */
  body.page-h5.page-products #cp-type-software:checked ~ .cp-banner .cp-banner-desc--software,
  body.page-h5.page-products .products-main[data-cp-type="software"] .cp-banner-desc--software {
    display: block;
    visibility: visible;
  }

  body.page-h5.page-products #cp-type-software:checked ~ .cp-banner .cp-banner-desc--hardware,
  body.page-h5.page-products .products-main[data-cp-type="software"] .cp-banner-desc--hardware {
    display: none;
  }

  body.page-h5.page-products #cp-type-software:checked ~ .cp-banner .cp-banner-img--hardware,
  body.page-h5.page-products .products-main[data-cp-type="software"] .cp-banner-img--hardware {
    display: none;
  }

  body.page-h5.page-products #cp-type-software:checked ~ .cp-banner .cp-banner-img--software,
  body.page-h5.page-products .products-main[data-cp-type="software"] .cp-banner-img--software {
    display: block;
  }

  body.page-h5.page-products #cp-type-hardware:checked ~ .cp-banner .cp-banner-desc--hardware,
  body.page-h5.page-products .products-main[data-cp-type="hardware"] .cp-banner-desc--hardware {
    display: block;
    visibility: visible;
  }

  body.page-h5.page-products #cp-type-hardware:checked ~ .cp-banner .cp-banner-img--hardware,
  body.page-h5.page-products .products-main[data-cp-type="hardware"] .cp-banner-img--hardware {
    display: block;
  }

  body.page-h5.page-products #cp-type-hardware:checked ~ .cp-banner .cp-banner-img--software,
  body.page-h5.page-products .products-main[data-cp-type="hardware"] .cp-banner-img--software {
    display: none;
  }


  body.page-h5.page-products .cp-body--hardware {
    flex: 1;
    display: grid;
    grid-template-columns: var(--cp-h5-cat-w) minmax(0, 1fr);
    align-items: start;
    gap: var(--cp-h5-cat-gap-y) var(--cp-h5-cat-gap-x);
    width: 100%;
    max-width: none;
    margin: 0;
    padding: 16px var(--cp-h5-edge) 16px;
    min-height: 0;
    overflow-x: hidden;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    box-sizing: border-box;
  }

  body.page-h5.page-products .cp-body--software {
    display: none;
    flex: 1;
    flex-direction: column;
    width: 100%;
    min-height: 0;
    margin: 0;
    padding: 16px 15px;
    overflow-x: hidden;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    box-sizing: border-box;
  }

  body.page-h5.page-products .products-main[data-cp-type="software"] .cp-body--hardware {
    display: none;
  }

  body.page-h5.page-products .products-main[data-cp-type="software"] .cp-body--software {
    display: flex;
  }

  body.page-h5.page-products #cp-type-software:checked ~ .cp-body--software {
    display: flex;
  }

  body.page-h5.page-products .products-main[data-cp-type="hardware"] .cp-body--hardware {
    display: grid;
  }

  /* H5：cp-wrap 不参与布局（PC 仍作内部滚动容器）；软件模式整层隐藏 */
  body.page-h5.page-products .cp-wrap {
    display: contents;
  }

  body.page-h5.page-products #cp-type-software:checked ~ .cp-wrap,
  body.page-h5.page-products .products-main[data-cp-type="software"] .cp-wrap {
    display: none;
  }

  /* 二级分类：左侧上方固定，滚动产品列表时不随页面移动 */
  body.page-h5.page-products .cp-categories-wrap {
    grid-column: 1;
    grid-row: 1;
    align-self: start;
    height: auto;
    position: sticky;
    top: 8px;
    z-index: 50;
    margin: 0;
    padding: 0;
    box-sizing: border-box;
  }

  body.page-h5.page-products .cp-main {
    grid-column: 2;
    grid-row: 1;
    flex: none;
    width: 100%;
    min-width: 0;
    max-width: none;
    margin: 0;
    padding: 0;
    overflow-x: visible;
    overflow-y: visible;
    box-sizing: border-box;
  }

  body.page-h5.page-products .cp-panel {
    width: 100%;
    min-width: 0;
    box-sizing: border-box;
  }

  body.page-h5.page-products #cp-cat-v:checked ~ .cp-main,
  body.page-h5.page-products #cp-cat-iii:checked ~ .cp-main,
  body.page-h5.page-products #cp-cat-ii:checked ~ .cp-main,
  body.page-h5.page-products #cp-cat-i:checked ~ .cp-main,
  body.page-h5.page-products #cp-cat-huawei:checked ~ .cp-main,
  body.page-h5.page-products #cp-cat-cabinet:checked ~ .cp-main {
    width: 100%;
    min-width: 0;
    max-width: none;
  }

  body.page-h5.page-products .cp-products.cp-products--5 {
    width: 100%;
    min-width: 0;
  }

  body.page-h5.page-products .cp-categories {
    display: flex;
    flex: none;
    flex-direction: column;
    flex-wrap: nowrap;
    align-items: stretch;
    width: var(--cp-h5-cat-w);
    min-width: var(--cp-h5-cat-w);
    max-width: var(--cp-h5-cat-w);
    height: auto;
    gap: var(--cp-h5-cat-gap-y);
    margin: 0;
    padding: 0;
    list-style: none;
  }

  body.page-h5.page-products .cp-categories li {
    width: 100%;
    flex: 0 0 auto;
  }

  body.page-h5.page-products .cp-category {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    height: var(--cp-h5-cat-h);
    min-height: var(--cp-h5-cat-h);
    max-height: var(--cp-h5-cat-h);
    flex: none;
    padding: 0 2px;
    font-size: clamp(14px, calc(28 / 1080 * 100vw), 16px);
    font-weight: 500;
    line-height: 1.25;
    color: #333;
    background: #FFFFFF99;
    border: 1px solid #fff;
    border-radius: 6px;
    box-sizing: border-box;
    justify-content: center;
    gap: 0;
    cursor: pointer;
    user-select: none;
  }

  body.page-h5.page-products .cp-category[for="cp-cat-huawei"],
  body.page-h5.page-products .cp-category[for="cp-cat-cabinet"] {
    height: var(--cp-h5-cat-h-tall);
    min-height: var(--cp-h5-cat-h-tall);
    max-height: var(--cp-h5-cat-h-tall);
  }

  body.page-h5.page-products .cp-category-name {
    display: block;
    width: 100%;
    text-align: center;
    font-size: inherit;
    line-height: inherit;
  }

  body.page-h5.page-products #cp-cat-v:checked ~ .cp-categories-wrap .cp-category[for="cp-cat-v"],
  body.page-h5.page-products #cp-cat-iii:checked ~ .cp-categories-wrap .cp-category[for="cp-cat-iii"],
  body.page-h5.page-products #cp-cat-ii:checked ~ .cp-categories-wrap .cp-category[for="cp-cat-ii"],
  body.page-h5.page-products #cp-cat-i:checked ~ .cp-categories-wrap .cp-category[for="cp-cat-i"],
  body.page-h5.page-products #cp-cat-huawei:checked ~ .cp-categories-wrap .cp-category[for="cp-cat-huawei"],
  body.page-h5.page-products #cp-cat-cabinet:checked ~ .cp-categories-wrap .cp-category[for="cp-cat-cabinet"] {
    font-weight: 700;
    color: #E10600;
    background: #FFFFFF1A;
    height: var(--cp-h5-cat-h);
    min-height: var(--cp-h5-cat-h);
    max-height: var(--cp-h5-cat-h);
    padding: 0 2px 2px;
    justify-content: flex-end;
    gap: 2px;
  }

  body.page-h5.page-products #cp-cat-huawei:checked ~ .cp-categories-wrap .cp-category[for="cp-cat-huawei"],
  body.page-h5.page-products #cp-cat-cabinet:checked ~ .cp-categories-wrap .cp-category[for="cp-cat-cabinet"] {
    height: var(--cp-h5-cat-h-tall);
    min-height: var(--cp-h5-cat-h-tall);
    max-height: var(--cp-h5-cat-h-tall);
  }

  body.page-h5.page-products .cp-category-line {
    width: 42%;
    height: 2px;
    flex-shrink: 0;
  }

  body.page-h5.page-products .cp-tabs-wrap {
    flex-shrink: 0;
    min-height: var(--cp-h5-tabs-h);
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    margin: 8px auto;
    padding: 0 15px;
    box-sizing: border-box;
  }

  /* I代、II代：隐藏「软件平台」（占位保留，不删布局） */
  body.page-h5.page-products .products-main:has(#cp-cat-i:checked) .cp-type-tabs li:has(.cp-type-tab[for="cp-type-software"]),
  body.page-h5.page-products .products-main:has(#cp-cat-ii:checked) .cp-type-tabs li:has(.cp-type-tab[for="cp-type-software"]) {
    visibility: hidden;
    pointer-events: none;
  }

  /* 硬件产品 / 软件平台：整组水平居中，两项等宽 */
  body.page-h5.page-products .cp-type-tabs {
    display: flex;
    justify-content: center;
    align-items: stretch;
    width: calc(828 / 1080 * 100vw);
    max-width: calc(100% - 30px);
    margin: 0 auto;
    height: 56px;
    gap: calc(20 / 1080 * 100vw);
    padding: 0;
    list-style: none;
    box-sizing: border-box;
  }

  body.page-h5.page-products .cp-type-tabs li {
    flex: 1 1 0;
    min-width: 0;
    margin: 0;
    padding: 0;
  }

  body.page-h5.page-products .cp-type-tab {
    position: relative;
    width: 100%;
    flex: 1 1 auto;
    min-width: 0;
    height: 56px;
    font-size: 16px;
    justify-content: center;
    padding-bottom: 8px;
  }

  body.page-h5.page-products .cp-type-tab-inner {
    flex: 0 0 auto;
  }

  body.page-h5.page-products .cp-type-tab-icon {
    width: 24px;
    height: 24px;
  }

  body.page-h5.page-products .cp-type-tab-line {
    bottom: 6px;
    width: min(160px, 70%);
  }

  /* 产品列表：每行固定「图栏 + 属性栏」，各行左缘对齐（避免按内容宽度单独居中） */
  body.page-h5.page-products .cp-products,
  body.page-h5.page-products .cp-products.cp-products--5 {
    display: flex;
    flex-direction: column;
    flex-wrap: nowrap;
    align-items: stretch;
    gap: 24px;
    width: 100%;
    min-width: 0;
    max-width: none;
    min-height: 0;
    margin: 0;
    padding: 0;
    list-style: none;
    box-sizing: border-box;
  }

  body.page-h5.page-products .cp-product,
  body.page-h5.page-products .cp-products--5 .cp-product {
    display: grid;
    grid-template-columns: var(--cp-h5-pic-col) minmax(0, 1fr);
    align-items: start;
    column-gap: var(--cp-h5-pic-gap);
    width: 100%;
    min-width: 0;
    max-width: none;
    min-height: 0;
    height: auto;
    background: transparent;
    border: 0;
    border-radius: 0;
    overflow: visible;
    list-style: none;
    box-sizing: border-box;
  }

  body.page-h5.page-products .cp-product-pic {
    grid-column: 1;
    flex: none;
    width: var(--cp-h5-pic-col);
    min-width: var(--cp-h5-pic-col);
    max-width: var(--cp-h5-pic-col);
    min-height: 0;
    height: auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    margin-left: var(--cp-h5-pic-offset);
    padding: 0;
    box-sizing: border-box;
    overflow: visible;
  }

  /* 统一 206×155 展示框，object-fit: contain 保证各产品图视觉尺寸一致 */
  body.page-h5.page-products .cp-product-pic img,
  body.page-h5.page-products .cp-product-pic .cp-product-pic-img {
    display: block;
    flex: 0 0 auto;
    width: var(--cp-h5-pic-col);
    height: var(--cp-h5-pic-h);
    max-width: 206px;
    max-height: 155px;
    aspect-ratio: unset;
    object-fit: contain;
    object-position: center;
    margin: 0 auto;
  }

  body.page-h5.page-products .cp-product-pic h3 {
    width: 100%;
    margin: 4px 0 0;
    font-size: 14px;
    font-weight: 700;
    line-height: 18px;
    text-align: center;
    color: #333;
    white-space: normal;
  }

  body.page-h5.page-products .cp-product-info {
    grid-column: 2;
    flex: none;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-start;
    width: 100%;
    min-width: 0;
    max-width: none;
    margin-top: 0;
    padding: 0;
    box-sizing: border-box;
  }

  body.page-h5.page-products .cp-product-body {
    width: 100%;
    min-width: 0;
    margin: 0;
    padding-left: 30px;
    box-sizing: border-box;
  }

  body.page-h5.page-products .cp-product-head {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
    min-height: 0;
    justify-content: flex-start;
  }

  body.page-h5.page-products .cp-product-pic .cp-product-head {
    width: 100%;
    margin: 4px 0 0;
    gap: 6px;
  }

  body.page-h5.page-products .cp-product-pic .cp-product-head h3 {
    margin: 0;
    font-size: 14px;
    font-weight: 700;
    line-height: 18px;
    text-align: center;
    color: #333;
    white-space: normal;
  }

  body.page-h5.page-products .cp-product-pic .cp-product-badge {
    padding: 0 4px;
    font-size: 11px;
    line-height: 16px;
  }

  body.page-h5.page-products .cp-product-series + .cp-product-models,
  body.page-h5.page-products .cp-product-series-block + .cp-product-models,
  body.page-h5.page-products .cp-product-series-block + .cp-product-models-block {
    margin-top: 20px;
  }

  body.page-h5.page-products .cp-product-label,
  body.page-h5.page-products .cp-product-item-btn {
    font-size: 12px;
  }

  /* 型号/系列：空间不足时自动换行，禁止右侧裁切 */
  body.page-h5.page-products .cp-product-body,
  body.page-h5.page-products .cp-product-info {
    overflow: visible;
  }

  body.page-h5.page-products .cp-product-series,
  body.page-h5.page-products .cp-product-series-block,
  body.page-h5.page-products .cp-product-models-block {
    display: grid;
    grid-template-columns: 4.5em minmax(0, 1fr);
    align-items: start;
    column-gap: 0;
    width: 100%;
    min-width: 0;
  }

  body.page-h5.page-products .cp-product-models {
    width: 100%;
    min-width: 0;
  }

  body.page-h5.page-products .cp-product-models-block {
    align-items: start;
  }

  body.page-h5.page-products .cp-product-series > .cp-product-label,
  body.page-h5.page-products .cp-product-series-block > .cp-product-label,
  body.page-h5.page-products .cp-product-models-block > .cp-product-label {
    grid-column: 1;
    grid-row: 1;
    flex: none;
    width: auto;
    white-space: nowrap;
  }

  body.page-h5.page-products .cp-product-series > em,
  body.page-h5.page-products .cp-product-series-block > .cp-product-series-list,
  body.page-h5.page-products .cp-product-models-block > .cp-product-model-rows {
    grid-column: 2;
    grid-row: 1;
    min-width: 0;
  }

  body.page-h5.page-products .cp-product-series {
    align-items: center;
  }

  body.page-h5.page-products .cp-product-label {
    width: auto;
    height: auto;
    flex-shrink: 0;
  }

  /* 型号行：标签占位固定，续行空 label 与首行「• 型号：」对齐 */
  body.page-h5.page-products .cp-product-model .cp-product-label {
    flex: 0 0 4.5em;
    width: 4.5em;
    min-width: 4.5em;
    box-sizing: border-box;
    white-space: nowrap;
  }

  body.page-h5.page-products .cp-product-series .cp-product-label {
    flex: 0 0 4.5em;
    width: 4.5em;
    min-width: 4.5em;
    box-sizing: border-box;
    white-space: nowrap;
  }

  body.page-h5.page-products .cp-product-series-list,
  body.page-h5.page-products .cp-product-models,
  body.page-h5.page-products .cp-product-model-rows {
    flex: 0 1 auto;
    width: auto;
    min-width: 0;
    max-width: 100%;
  }

  body.page-h5.page-products .cp-product-models-block .cp-product-model-rows,
  body.page-h5.page-products .cp-product-series-block .cp-product-series-list {
    flex: 0 1 auto;
    min-width: 0;
    max-width: 100%;
  }

  /* II代：系列/型号块同宽，标签列左缘对齐 */
  body.page-h5.page-products .cp-products--5 .cp-product-series-block,
  body.page-h5.page-products .cp-products--5 .cp-product-models-block {
    width: 100%;
    max-width: none;
  }

  body.page-h5.page-products .cp-products--5 .cp-product-series-block + .cp-product-models-block {
    margin-top: 20px;
  }

  body.page-h5.page-products .cp-products--5 .cp-product-pic .cp-product-head {
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    gap: 4px;
  }

  body.page-h5.page-products .cp-products--5 .cp-product-pic .cp-product-head h3 {
    font-size: 12px;
    line-height: 16px;
  }

  body.page-h5.page-products .cp-product-model-row.is-active {
    display: flex;
    align-items: flex-start;
  }

  body.page-h5.page-products .cp-product-model {
    display: flex;
    flex-wrap: nowrap;
    align-items: center;
    width: auto;
    max-width: 100%;
    min-width: 0;
  }

  body.page-h5.page-products .cp-product-model-items {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-start;
    gap: 4px 8px;
    width: auto;
    max-width: 100%;
    min-width: 0;
  }

  body.page-h5.page-products .cp-product-model .cp-product-item-btn,
  body.page-h5.page-products .cp-product-model-items .cp-product-item-btn {
    flex: 0 1 auto;
    max-width: 100%;
    white-space: normal;
    word-break: break-word;
    text-align: left;
  }

  /* 配套机柜颜色：标签一行、色块换行，避免右侧被裁切 */
  body.page-h5.page-products .cp-product-colors {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-start;
    gap: 4px 0;
    width: 100%;
    min-width: 0;
    margin: 8px 0 0;
    overflow: visible;
  }

  body.page-h5.page-products .cp-product-models + .cp-product-colors,
  body.page-h5.page-products .cp-product-series + .cp-product-colors,
  body.page-h5.page-products .cp-product-series-block + .cp-product-colors {
    margin-top: 8px;
  }

  body.page-h5.page-products .cp-product-colors .cp-product-label {
    flex: 0 0 auto;
    width: 100%;
  }

  body.page-h5.page-products .cp-product-color-list {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin: 0;
    padding: 0 0 0 52px;
    list-style: none;
    width: 100%;
    min-width: 0;
    box-sizing: border-box;
    overflow: visible;
  }

  body.page-h5.page-products .cp-product-color-btn {
    flex-shrink: 0;
    width: 34px;
    height: 20px;
  }

  body.page-h5.page-products .cp-product-color-btn span {
    width: 30px;
    height: 16px;
  }

  /* 配套机柜：系列/型号/颜色单行紧凑，行距适中（仅 H5，不与 PC 混用）。 */
  body.page-h5.page-products #cp-cat-cabinet:checked ~ .cp-main .cp-product-series {
    display: flex;
    flex-wrap: nowrap;
    align-items: center;
    min-height: 20px;
    margin: 0;
    line-height: 20px;
  }

  body.page-h5.page-products #cp-cat-cabinet:checked ~ .cp-main .cp-product-models {
    margin: 0;
    padding: 0;
  }

  body.page-h5.page-products #cp-cat-cabinet:checked ~ .cp-main .cp-product-model {
    display: flex;
    flex-wrap: nowrap;
    align-items: center;
    min-height: 20px;
    width: 100%;
  }

  body.page-h5.page-products #cp-cat-cabinet:checked ~ .cp-main .cp-product-model-items {
    flex-wrap: nowrap;
    align-items: center;
    gap: 8px;
  }

  body.page-h5.page-products #cp-cat-cabinet:checked ~ .cp-main .cp-product-colors {
    display: flex;
    flex-wrap: nowrap;
    align-items: center;
    min-height: 20px;
    margin: 0;
    gap: 0;
  }

  body.page-h5.page-products #cp-cat-cabinet:checked ~ .cp-main .cp-product-colors .cp-product-label {
    width: auto;
    flex: 0 0 auto;
    line-height: 20px;
  }

  body.page-h5.page-products #cp-cat-cabinet:checked ~ .cp-main .cp-product-color-list {
    flex: 0 1 auto;
    width: auto;
    padding: 0;
    gap: 6px;
  }

  body.page-h5.page-products #cp-cat-cabinet:checked ~ .cp-main .cp-product-series + .cp-product-models,
  body.page-h5.page-products #cp-cat-cabinet:checked ~ .cp-main .cp-product-models + .cp-product-colors {
    margin-top: 20px;
  }

  body.page-h5.page-products #cp-cat-cabinet:checked ~ .cp-main .cp-product-label,
  body.page-h5.page-products #cp-cat-cabinet:checked ~ .cp-main .cp-product-item-btn,
  body.page-h5.page-products #cp-cat-cabinet:checked ~ .cp-main .cp-product-series em {
    font-size: 12px;
    line-height: 20px;
  }

  body.page-h5.page-products .cp-soft-list--default {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    width: 100%;
    margin: 0;
    padding: 0 0 20px;
    list-style: none;
    box-sizing: border-box;
  }

  body.page-h5.page-products .products-main:has(#cp-cat-cabinet:checked) #cp-type-software:checked ~ .cp-body--software .cp-soft-list--default,
  body.page-h5.page-products .products-main:has(#cp-cat-cabinet:checked)[data-cp-type="software"] .cp-soft-list--default {
    display: none;
  }

  body.page-h5.page-products .products-main:has(#cp-cat-cabinet:checked) #cp-type-software:checked ~ .cp-body--software .cp-soft-list--cabinet,
  body.page-h5.page-products .products-main:has(#cp-cat-cabinet:checked)[data-cp-type="software"] .cp-soft-list--cabinet {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
    width: 100%;
    margin: 0;
    padding: 0 0 20px;
    list-style: none;
    box-sizing: border-box;
  }

  /* 配套机柜软件：一屏展示 kz 图，内容区内部不滚动 */
  body.page-h5.page-products .products-main:has(#cp-cat-cabinet:checked):has(#cp-type-software:checked) .cp-body--software,
  body.page-h5.page-products .products-main:has(#cp-cat-cabinet:checked)[data-cp-type="software"] .cp-body--software {
    display: flex;
    flex: 1;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 0;
    margin: 0;
    padding: 12px 15px 16px;
    overflow: hidden;
  }

  body.page-h5.page-products .products-main:has(#cp-cat-cabinet:checked):has(#cp-type-software:checked) .cp-soft-list--cabinet,
  body.page-h5.page-products .products-main:has(#cp-cat-cabinet:checked)[data-cp-type="software"] .cp-soft-list--cabinet {
    flex: 1;
    justify-content: center;
    min-height: 0;
    padding: 0;
    gap: 0;
  }

  body.page-h5.page-products .products-main:has(#cp-cat-cabinet:checked):has(#cp-type-software:checked) .cp-soft-cabinet-item,
  body.page-h5.page-products .products-main:has(#cp-cat-cabinet:checked)[data-cp-type="software"] .cp-soft-cabinet-item {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 0;
    max-height: 100%;
    width: 100%;
  }

  body.page-h5.page-products .products-main:has(#cp-cat-cabinet:checked):has(#cp-type-software:checked) .cp-soft-cabinet-item img,
  body.page-h5.page-products .products-main:has(#cp-cat-cabinet:checked)[data-cp-type="software"] .cp-soft-cabinet-item img {
    width: auto;
    max-width: 100%;
    max-height: 100%;
    height: auto;
    object-fit: contain;
  }

  body.page-h5.page-products .cp-soft-cabinet-item img {
    display: block;
    width: 100%;
    max-width: 320px;
    height: auto;
  }

  body.page-h5.page-products .cp-soft-item {
    width: 100%;
    height: 182px;
    border-radius: 8px;
    background-repeat: no-repeat;
    background-position: center top;
    background-size: cover;
    box-sizing: border-box;
  }

  body.page-h5.page-products .cp-soft-link {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    width: 100%;
    height: 100%;
    padding: 0 12px 12px;
    text-decoration: none;
    color: inherit;
    box-sizing: border-box;
  }

  body.page-h5.page-products .cp-soft-title {
    margin: 0;
    font-size: 17px;
    font-weight: 700;
    line-height: 1.2;
    text-align: center;
    color: #C8CED6;
  }

  body.page-h5.page-products .cp-soft-line {
    width: 80px;
    height: 3px;
    margin: 6px auto 0;
    flex-shrink: 0;
  }

  body.page-h5.page-products .cp-soft-desc {
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 4;
    overflow: hidden;
    margin: 6px 0 0;
    font-size: 12px;
    line-height: 18px;
    text-align: center;
    color: #C8CED6;
  }

  body.page-h5.page-products .cp-soft-more {
    align-self: flex-start;
    margin-top: 8px;
    font-size: 13px;
    line-height: 1;
    color: #E10600;
  }

  body.page-h5.page-products .cp-soft-more::after {
    content: " ↗";
  }

  body.page-h5.page-products .cp-modal.is-open {
    align-items: stretch;
    justify-content: center;
    padding: calc(var(--h5-header) + var(--cp-h5-modal-mask-top)) var(--cp-h5-modal-gap-x) calc(var(--h5-tabbar) + 12px);
    overflow: hidden;
    pointer-events: none;
  }

  body.page-h5.page-products .cp-modal-mask {
    pointer-events: auto;
    cursor: pointer;
  }

  body.page-h5.page-products .cp-modal-box {
    width: 100%;
    max-width: 100%;
    flex: 1 1 auto;
    max-height: 100%;
    min-height: 0;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: stretch;
    gap: var(--cp-h5-modal-mode-gap);
    overflow: visible;
    pointer-events: auto;
    margin-bottom: var(--cp-h5-modal-lift);
  }

  body.page-h5.page-products .cp-modal-close {
    top: 8px;
    right: 8px;
    width: 28px;
    height: 28px;
  }

  body.page-h5.page-products .cp-modal-close::before,
  body.page-h5.page-products .cp-modal-close::after {
    width: 12px;
  }

  body.page-h5.page-products .cp-modal.is-open .cp-modal-panel.active {
    flex: 0 0 auto;
    min-height: 0;
    display: flex;
    flex-direction: column;
    width: 100%;
    overflow: hidden;
  }

  body.page-h5.page-products .cp-modal-panel,
  body.page-h5.page-products .cp-modal.is-open .cp-modal-panel.active,
  body.page-h5.page-products .cp-modal-body {
    width: 100%;
  }

  body.page-h5.page-products .cp-modal.is-open .cp-modal-panel.active .cp-modal-body {
    flex: 0 0 auto;
    flex-direction: column;
    gap: var(--cp-h5-modal-thumb-gap);
    min-height: var(--cp-h5-modal-gallery-h);
    padding: 0;
    background: transparent;
    border-radius: 0;
    box-shadow: none;
    box-sizing: border-box;
    overflow: hidden;
  }

  body.page-h5.page-products .cp-modal.is-open .cp-modal-panel.active .cp-modal-gallery {
    display: flex;
    flex-direction: column;
    gap: var(--cp-h5-modal-thumb-gap);
    flex: 0 0 auto;
    width: 100%;
    min-width: 0;
    height: var(--cp-h5-modal-gallery-h);
    overflow: hidden;
  }

  body.page-h5.page-products .cp-modal.is-open .cp-modal-panel.active .cp-modal-detail {
    display: none;
    width: 100%;
    min-width: 0;
    max-width: none;
    min-height: 0;
    padding: 12px;
    background: transparent;
    border-radius: 0;
    box-shadow: none;
  }

  body.page-h5.page-products .cp-modal.is-open .cp-modal-panel.active.is-specs .cp-modal-gallery {
    display: none;
  }

  body.page-h5.page-products .cp-modal.is-open .cp-modal-panel.active.is-specs .cp-modal-detail {
    display: flex;
    flex-direction: column;
    flex: 0 0 auto;
    width: 100%;
    height: var(--cp-h5-modal-gallery-h);
    min-height: var(--cp-h5-modal-gallery-h);
    max-height: var(--cp-h5-modal-gallery-h);
    margin: 0;
    padding: 12px;
    overflow: hidden;
    -webkit-overflow-scrolling: touch;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.12);
    box-sizing: border-box;
    position: relative;
  }

  /* 大图区：宽度占满（左右 30px 由弹窗外层 padding 控制） */
  body.page-h5.page-products .cp-modal-main {
    position: relative;
    display: flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: var(--cp-h5-modal-main-h);
    min-height: var(--cp-h5-modal-main-h);
    max-height: var(--cp-h5-modal-main-h);
    margin: 0;
    background: #fff;
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.12);
    border-radius: 12px;
    box-sizing: border-box;
  }

  body.page-h5.page-products .cp-modal-main-img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
  }

  body.page-h5.page-products .cp-modal-thumbs {
    display: flex;
    flex-wrap: nowrap;
    flex: 0 0 auto;
    align-items: center;
    justify-content: flex-start;
    gap: 8px;
    width: 100%;
    max-width: 100%;
    height: var(--cp-h5-modal-thumb-row-h);
    min-height: var(--cp-h5-modal-thumb-row-h);
    max-height: var(--cp-h5-modal-thumb-row-h);
    min-width: 0;
    margin: 0;
    padding: 2px 0 4px;
    overflow-x: auto;
    overflow-y: hidden;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    box-sizing: border-box;
  }

  body.page-h5.page-products .cp-modal-thumbs::-webkit-scrollbar {
    display: none;
  }

  body.page-h5.page-products .cp-modal-thumb {
    flex: 0 0 auto;
    margin: 0;
    padding: 0;
  }

  body.page-h5.page-products .cp-modal-thumb button {
    width: 56px;
    height: 56px;
    padding: 3px;
    border: 2px solid transparent;
    border-radius: 6px;
    background: #fff;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    box-sizing: border-box;
  }

  body.page-h5.page-products .cp-modal-thumb.active button {
    border-color: #E10600;
  }

  body.page-h5.page-products .cp-modal-thumb img {
    width: 100%;
    height: 100%;
    object-fit: contain;
  }

  body.page-h5.page-products .cp-modal-head {
    gap: 10px;
    flex-wrap: wrap;
    flex-shrink: 0;
  }

  body.page-h5.page-products .cp-modal-title {
    font-size: 18px;
    line-height: 24px;
  }

  body.page-h5.page-products .cp-modal-subtitle {
    font-size: 14px;
    line-height: 20px;
  }

  body.page-h5.page-products .cp-modal-line {
    flex-shrink: 0;
  }

  body.page-h5.page-products .cp-modal-group-tabs {
    width: 100%;
    max-width: 170px;
    flex-shrink: 0;
  }

  body.page-h5.page-products .cp-modal-specs {
    flex: 1 1 auto;
    min-height: 0;
    overflow-x: hidden;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }

  body.page-h5.page-products .cp-modal-specs::-webkit-scrollbar {
    display: none;
  }

  body.page-h5.page-products .cp-modal-specs.cp-modal-specs--single {
    display: block;
  }

  body.page-h5.page-products .cp-modal-specs:not(.cp-modal-specs--single) {
    display: flex;
    flex-direction: row;
    gap: 12px;
  }

  body.page-h5.page-products .cp-modal-spec-col {
    display: block;
    flex: 1 1 0;
    min-width: 0;
    column-count: auto;
    column-gap: 0;
    width: auto;
    height: auto;
    margin: 0;
    padding-left: 14px;
    list-style: disc;
    list-style-position: outside;
  }

  body.page-h5.page-products .cp-modal-spec-col li {
    width: auto;
    max-width: none;
    box-sizing: border-box;
    margin-left: 0;
    padding: 0 8px 0 0;
    list-style-position: outside;
    font-size: 12px;
    line-height: 20px;
    break-inside: avoid;
  }

  /* H5 规格布局：
     - 单个 ul 且 ≤6 项：单列满宽
     - 单个 ul 且 7–15 项：定高 520px，先纵向排满左列再折到右列
     - 两个 ul：左右各一列（参数 >15 时 JS 拆分） */
  body.page-h5.page-products .cp-modal-specs.cp-modal-specs--h5-one-col > .cp-modal-spec-col:only-child {
    display: block;
    width: 100%;
    max-height: none;
    overflow: visible;
  }

  body.page-h5.page-products .cp-modal-specs.cp-modal-specs--h5-one-col > .cp-modal-spec-col:only-child li {
    flex: none;
    width: 100%;
    max-width: 100%;
  }

  body.page-h5.page-products .cp-modal-specs.cp-modal-specs--single:not(.cp-modal-specs--h5-one-col) > .cp-modal-spec-col:only-child {
    display: block;
    width: 100%;
    height: auto;
    max-height: none;
    gap: 0;
    overflow: visible;
  }

  body.page-h5.page-products .cp-modal-specs.cp-modal-specs--single:not(.cp-modal-specs--h5-one-col) > .cp-modal-spec-col:only-child li {
    flex: 0 0 auto;
    width: calc((100% - 12px) / 2);
    max-width: calc((100% - 12px) / 2);
  }

  body.page-h5.page-products .cp-modal-specs > .cp-modal-spec-col:not(:only-child) {
    flex: 1 1 0;
    min-width: 0;
    max-height: none;
    overflow: visible;
    column-count: 1;
  }

  body.page-h5.page-products .cp-modal-specs > .cp-modal-spec-col:not(:only-child) li {
    flex: none;
    width: auto;
    max-width: none;
  }

  /* 机柜弹窗：参数列表随 .cp-modal-specs 外层滚动 */
  body.page-h5.page-products .cp-modal-group .cp-modal-spec-col,
  body.page-h5.page-products .cp-modal-group .cp-modal-spec-col--tall {
    display: block;
    height: auto;
    max-height: none;
    overflow: visible;
    column-count: auto;
  }

  body.page-h5.page-products .cp-modal-group .cp-modal-spec-col--tall li {
    width: 100%;
    max-width: 100%;
  }

  body.page-h5.page-products .cp-modal-mode {
    display: flex;
    flex-shrink: 0;
    align-self: center;
    width: 100%;
    max-width: 280px;
    height: 40px;
    margin: auto 0 0;
    padding: 0;
    gap: 0;
    background: #fff;
    border-radius: 20px;
    box-sizing: border-box;
    overflow: hidden;
  }

  body.page-h5.page-products .cp-modal-mode-btn {
    flex: 1;
    min-width: 0;
    height: 100%;
    padding: 0 8px;
    border: 0;
    border-radius: 0;
    background: transparent;
    font-family: "Microsoft YaHei", sans-serif;
    font-size: 13px;
    font-weight: 400;
    line-height: 1;
    color: #8F8F8F;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
  }

  body.page-h5.page-products .cp-modal-mode-btn.active {
    background: linear-gradient(180deg, #F25458 12.02%, #C10014 69.23%);
    color: #fff;
  }
}
