/* 技术参数表格视觉补丁
   ------------------------------------------------------------------
   只作用于后台富文本（qf_goods.param）粘进来的 .ne-param-table。
   外层容器 .article-section4 / .section-desc / .table-wrap / .params-table
   以及全站版式、字体、动画全部沿用 szccm 原版 CSS，本文件不改原版任何规则。
   目的：Excel 粘贴表默认无边框、列宽写死、长中英文标题挤成折行，
        这里补边框、表头、斑马纹、内边距与窄屏横向滚动。                  */

.article-section4 .params-table {
  border: 1px solid #dbe3ec;
}

.article-section4 .params-table .ne-param-table {
  width: 100% !important;
  min-width: 640px;
  max-width: none !important;
  height: auto !important;
  border-collapse: collapse !important;
  background: #fff;
  table-layout: auto !important;
}

.article-section4 .params-table .ne-param-table tr {
  height: auto !important;
}

.article-section4 .params-table .ne-param-table th,
.article-section4 .params-table .ne-param-table td {
  border: 1px solid #dbe3ec !important;
  padding: 9px 14px !important;
  height: auto !important;
  width: auto !important;
  font-size: 14px;
  line-height: 1.65;
  color: #3c4655;
  vertical-align: middle;
  white-space: normal;
  overflow-wrap: break-word;
  background-clip: padding-box;
}

.article-section4 .params-table .ne-param-table thead th,
.article-section4 .params-table .ne-param-table:not(.ne-has-thead) tbody tr:first-child td,
.article-section4 .params-table .ne-param-table:not(.ne-has-thead) tbody tr:first-child th {
  background: #0f4c8a !important;
  border-color: #0f4c8a !important;
  color: #fff !important;
  font-weight: 600;
  text-align: center;
}

/* Word/Excel 粘贴带来的内联字色不能盖住表头白字 */
.article-section4 .params-table .ne-param-table:not(.ne-has-thead) tbody tr:first-child td span,
.article-section4 .params-table .ne-param-table:not(.ne-has-thead) tbody tr:first-child th span,
.article-section4 .params-table .ne-param-table thead th span {
  color: #fff !important;
}

.article-section4 .params-table .ne-param-table td:first-child {
  min-width: 250px;
  text-align: left;
  color: #22303f;
  font-weight: 500;
}

.article-section4 .params-table .ne-param-table td:not(:first-child) {
  text-align: center;
}

.article-section4 .params-table .ne-param-table tbody tr:nth-child(even) td {
  background: #f6f9fd;
}

.article-section4 .params-table .ne-param-table tbody tr:hover td {
  background: #e9f2ff;
}

.article-section4 .params-table .ne-param-table td > br:only-child {
  display: none;
}

.article-section4 .params-table .ne-param-table p {
  margin: 0;
}

.article-section4 .params-table .ne-param-table img {
  max-width: 100%;
  height: auto;
}

/* 后台富文本里若只写了段落列表（新机型机械参数），也保持整齐 */
.article-section4 .params-table > p {
  margin: 0 0 6px;
  font-size: 14px;
  line-height: 1.8;
}

/* 追加的「技术解说与对比」文档：小节标题 + 解说段落，位于两张表格之间。
   左右留 20px、上下与两张表格拉开距离，避免文字顶边、贴着表格。 */
.article-section4 .params-table > h3 {
  margin: 34px 20px 16px;
  padding-left: 12px;
  font-size: 18px;
  font-weight: 600;
  line-height: 1.5;
  color: #0f4c8a;
  border-left: 4px solid #0f4c8a;
}
.article-section4 .params-table > p {
  margin: 0 20px 14px;
  color: #3c4655;
  text-align: justify;
}
/* 解说段落之后紧跟对比表：给表格顶部留出与最后一段的距离 */
.article-section4 .params-table > p + table {
  margin-top: 28px !important;
}
/* 对比表「导轨防护」行内的两列对比图：按列宽自适应、居中 */
.article-section4 .params-table .ne-param-table td p {
  margin: 0;
}
.article-section4 .params-table .ne-param-table td img {
  display: block;
  max-width: 100%;
  width: auto;
  height: auto;
  margin: 6px auto;
}

/* 表格后追加的图片已拆到独立区块：与表格换行、居中、逐张留白，不再被表格边框包住 */
.article-section4 .section-desc .ne-param-extra {
  margin-top: 24px;
}
.article-section4 .section-desc .ne-param-extra p {
  margin: 0 0 12px;
  text-align: center;
  line-height: 1.6;
}
.article-section4 .section-desc .ne-param-extra p img,
.article-section4 .section-desc .ne-param-extra img {
  display: block;
  max-width: 100%;
  height: auto;
  margin: 0 auto 12px;
}

@media (max-width: 900px) {
  .article-section4 .params-table .ne-param-table {
    min-width: 620px;
    font-size: 13px;
  }
  .article-section4 .params-table .ne-param-table th,
  .article-section4 .params-table .ne-param-table td {
    padding: 7px 9px !important;
  }
  .article-section4 .params-table .ne-param-table td:first-child {
    min-width: 210px;
  }
}

/* ------------------------------------------------------------------
   Detail hero 产品要点列表：把原「产品详情」纯文字要点移到 banner 副标题下方。
   只作用于本模板新增的 .ne-hero-text / .text-features，
   原版 .text-title / .text-desc / 版式一律不动。
   右侧留给合成的产品图（约 45%），列表限宽避免盖住产品。
   ------------------------------------------------------------------ */
.ne-hero-text {
  --featureMax: 620px;
}
.ne-hero-text .text-features {
  box-sizing: border-box;
  margin-top: 14px;
  width: 52%;
  max-width: var(--featureMax);
  color: #1d2733;
}
.ne-hero-text .text-features ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: block;
}
.ne-hero-text .text-features li {
  position: relative;
  padding-left: 13px;
  font-size: 14px;
  font-weight: 400;
  line-height: 1.5;
  letter-spacing: .2px;
  text-shadow: 0 1px 2px rgba(255, 255, 255, .7);
  overflow-wrap: break-word;
}
.ne-hero-text .text-features li + li {
  margin-top: 4px;
}
.ne-hero-text .text-features li::before {
  content: "";
  position: absolute;
  left: 0;
  top: .62em;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #1d2733;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, .55);
}
@media (max-width: 1200px) {
  .ne-hero-text .text-features li { font-size: 13px; }
}
@media (max-width: 992px) {
  .ne-hero-text .text-features { margin-top: 10px; }
  .ne-hero-text .text-features li { font-size: 12px; line-height: 1.4; padding-left: 11px; }
  .ne-hero-text .text-features li::before { width: 4px; height: 4px; }
}
@media (max-width: 576px) {
  /* 横幅按 2048x1024 等比缩小，手机高度有限：要点压紧并整体上移，避免最后几行被裁切 */
  .common-detail-banner .ne-hero-text { top: 14%; }
  .ne-hero-text .text-features { margin-top: 8px; max-width: none; width: 42%; }
  .ne-hero-text .text-features li { font-size: 10px; line-height: 1.35; padding-left: 9px; }
  .ne-hero-text .text-features li::before { width: 3px; height: 3px; top: .55em; }
}

/* ------------------------------------------------------------------
   Excel 原表整表（代码/名称/项目/单位 + 多型号列）紧凑显示 + 横向滚动。
   仅命中「表头有第 10 列」的宽表，三列/两列表格完全不受影响。
   ------------------------------------------------------------------ */
/* 2026-11-26：宽表不再横向滚动/拖动，改为一页内自动换行完整显示 */
@supports selector(:has(*)) {
  .article-section4 .params-table:has(.ne-param-table thead th:nth-child(10)),
  .article-section4 .params-table .table-wrap:has(.ne-param-table thead th:nth-child(10)) {
    overflow: visible !important;
    -webkit-overflow-scrolling: auto;
  }
  .article-section4 .params-table .ne-param-table:has(thead th:nth-child(10)) {
    min-width: 0 !important;
    max-width: 100% !important;
    width: 100% !important;
    table-layout: fixed !important;
    font-size: 11px !important;
  }
  .article-section4 .params-table .ne-param-table:has(thead th:nth-child(10)) th,
  .article-section4 .params-table .ne-param-table:has(thead th:nth-child(10)) td {
    padding: 5px 4px !important;
    font-size: 11px !important;
    line-height: 1.4 !important;
    white-space: normal !important;
    overflow-wrap: anywhere !important;
    word-break: break-word !important;
    text-align: center !important;
  }
  .article-section4 .params-table .ne-param-table:has(thead th:nth-child(10)) td:first-child {
    min-width: 0 !important;
  }
}

/* ===== 参数区双选项卡：技术参数 / 加工中心全系列参数表 ===== */
/* 风格复用 about 页栏目 tab（蓝底白字 / 斜切圆角），去掉 .about-page 前缀 */
.ne-param-tabs-section .ne-param-tabbar {
  display: flex;
  justify-content: flex-start;
  flex-wrap: wrap;
  gap: 8px 12px;
  margin: 10px 0 28px;
  padding-left: 7px;
}
.ne-param-tabs-section .ne-param-tab {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  min-width: 150px;
  padding: 16px 28px;
  font-family: inherit;
  line-height: 1;
  font-weight: bold;
  font-size: var(--font20, 18px);
  color: #000000;
  background: #ffffff;
  border: 1px solid #d9d9d9;
  border-radius: 20px 0 20px 0;
  cursor: pointer;
  position: relative;
  z-index: 1;
  box-sizing: border-box;
  flex-shrink: 0;
  transform: skew(-5deg);
  transition: color .3s, border-color .3s;
  -webkit-appearance: none;
  appearance: none;
}
.ne-param-tabs-section .ne-param-tab::after {
  content: "";
  position: absolute;
  right: 0;
  top: 0;
  width: 0;
  height: 100%;
  background-color: #135f9d;
  z-index: -1;
  transition: width .3s;
}
.ne-param-tabs-section .ne-param-tab.active,
.ne-param-tabs-section .ne-param-tab:hover {
  color: #ffffff;
  border-color: #135f9d;
}
.ne-param-tabs-section .ne-param-tab.active::after,
.ne-param-tabs-section .ne-param-tab:hover::after {
  width: 100%;
  left: 0;
  right: auto;
}
/* 面板切换：默认全部隐藏，仅 .active 显示 */
.ne-param-tabs-section .ne-param-tabpanes .ne-param-tabpane { display: none; }
.ne-param-tabs-section .ne-param-tabpanes .ne-param-tabpane.active { display: block; }
@media (max-width: 768px) {
  .ne-param-tabs-section .ne-param-tabbar { gap: 8px; margin-bottom: 20px; padding-left: 0; }
  .ne-param-tabs-section .ne-param-tab {
    min-width: 0;
    flex: 1 1 auto;
    padding: 13px 8px;
    font-size: 14px;
  }
}

/* 缩小「产品详情」正文与参数选项卡之间的空白（只作用于带选项卡的产品页） */
.product-detail-main .product-article .article-section1:has(+ .article-section4.ne-param-tabs-section) {
  margin-bottom: 12px !important;
}
.ne-param-tabs-section .section-desc {
  padding-top: 8px !important;
}

/* 「技术解说 + 技术对比」块：解说段落是 14px/1.8，原版 common.css 却把
   对比表 tbody td 抬到 --font18(16px)，造成上下字号/行距不一致。
   只统一 h3 解说标题之后的对比表，其余产品的参数表不受影响。 */
.product-detail-main .product-article .article-section4 .params-table h3 ~ .table-wrap table.ne-param-table th,
.product-detail-main .product-article .article-section4 .params-table h3 ~ .table-wrap table.ne-param-table td {
  font-size: 14px !important;
  line-height: 1.8 !important;
}

/* ===== 2026-11-26：全部单元格居中；表格容器不再产生横向滚动 =====
   原版 .table-wrap 为 overflow-x:auto，宽表会拖动；这里统一放开，
   配合上面宽表的 fixed 布局 + 自动换行，保证一页内完整显示。 */
.product-detail-main .product-article .article-section4 .params-table,
.product-detail-main .product-article .article-section4 .table-wrap {
  overflow: visible !important;
  max-width: 100%;
}
.article-section4 .params-table .ne-param-table th,
.article-section4 .params-table .ne-param-table td {
  text-align: center !important;
}

/* ===== 2026-11-30：移动端参数表恢复左右拖动；PC 端仍保持一页完整显示 =====
   上面为了 PC 一页显示，把 .table-wrap / .params-table 的 overflow 统一放开了。
   这里只在 <=768px 恢复原版的横向滚动容器，并让表格按真实列宽展开，
   手指左右拖动即可看完整参数；宽屏（>768px）完全不进入本段，样式不变。 */
@media (max-width: 768px) {
  .product-detail-main .product-article .article-section4 .params-table,
  .product-detail-main .product-article .article-section4 .table-wrap {
    overflow-x: auto !important;
    overflow-y: hidden !important;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior-x: contain;
    max-width: 100% !important;
  }
  /* 宽表容器被上面的 :has 规则设成 visible（特异性更高），这里用同款选择器覆盖 */
  .product-detail-main .product-article .article-section4 .params-table:has(.ne-param-table thead th:nth-child(10)),
  .product-detail-main .product-article .article-section4 .params-table .table-wrap:has(.ne-param-table thead th:nth-child(10)) {
    overflow: auto !important;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior-x: contain;
  }

  .product-detail-main .product-article .article-section4 .params-table .ne-param-table,
  .product-detail-main .product-article .article-section4 .params-table .ne-param-table:has(thead th:nth-child(10)) {
    width: max-content !important;
    min-width: 640px !important;
    max-width: none !important;
    table-layout: auto !important;
    font-size: 13px !important;
  }
  /* 10 列宽表按真实列宽展开，不再压缩成一页 */
  .product-detail-main .product-article .article-section4 .params-table .ne-param-table:has(thead th:nth-child(10)) {
    min-width: 1100px !important;
    font-size: 12px !important;
  }

  .product-detail-main .product-article .article-section4 .params-table .ne-param-table th,
  .product-detail-main .product-article .article-section4 .params-table .ne-param-table td,
  .product-detail-main .product-article .article-section4 .params-table .ne-param-table:has(thead th:nth-child(10)) th,
  .product-detail-main .product-article .article-section4 .params-table .ne-param-table:has(thead th:nth-child(10)) td {
    padding: 7px 9px !important;
    font-size: 13px !important;
    line-height: 1.5 !important;
    white-space: nowrap !important;
    overflow-wrap: normal !important;
    word-break: normal !important;
  }
  .product-detail-main .product-article .article-section4 .params-table .ne-param-table:has(thead th:nth-child(10)) th,
  .product-detail-main .product-article .article-section4 .params-table .ne-param-table:has(thead th:nth-child(10)) td {
    padding: 6px 8px !important;
    font-size: 12px !important;
  }
  .product-detail-main .product-article .article-section4 .params-table .ne-param-table td:first-child,
  .product-detail-main .product-article .article-section4 .params-table .ne-param-table:has(thead th:nth-child(10)) td:first-child {
    min-width: 160px !important;
  }
  /* 表格内图片限宽，避免 max-content 布局下被原图撑得过宽 */
  .product-detail-main .product-article .article-section4 .params-table .ne-param-table td img {
    max-width: 220px !important;
  }
  /* 「技术解说 + 对比表」字号补丁的特异性更高，移动端需同款覆盖 */
  .product-detail-main .product-article .article-section4 .params-table h3 ~ .table-wrap table.ne-param-table th,
  .product-detail-main .product-article .article-section4 .params-table h3 ~ .table-wrap table.ne-param-table td {
    font-size: 13px !important;
    line-height: 1.5 !important;
    white-space: nowrap !important;
    overflow-wrap: normal !important;
  }
}
