/* ==========================================================================
   Best Parts — 设计令牌层（主题无关）
   用途：把字体 / 字号 / 字重 / 颜色 / 间距收敛成一套变量与元素规则。
        在 Induscity、Blocksy 或任何主题下输出完全一致的计算样式。
   原则：只覆盖「排版属性」，不动 margin / padding / 布局，
        因此不会改变现有页面的间距结构和版式。
   说明：标题与正文属性使用 !important，因为主题会用
        `.mf-section-title h2`（0,1,1）之类的规则压过元素选择器。
        这是重置层（reset layer）的标准做法，只涉及排版属性。
   ========================================================================== */

:root {
	/* 字体 */
	--bp-font: "Hind", "Helvetica Neue", Helvetica, Arial, sans-serif;

	/* 颜色 */
	--bp-color-text: #6b7178;
	--bp-color-heading: #393939;
	--bp-color-muted: #939aa1;
	--bp-color-primary: #00baff;
	--bp-color-primary-dark: #0091c7;
	--bp-color-line: #e6eaee;
	--bp-color-bg-soft: #f5f8fa;
	--bp-color-dark: #262c31;

	/* 字号阶梯 */
	--bp-fs-body: 17px;
	--bp-fs-sm: 14px;
	--bp-fs-xs: 12.5px;
	--bp-fs-h1: 44px;
	--bp-fs-h2: 36px;
	--bp-fs-h3: 22px;
	--bp-fs-h4: 18px;

	/* ---------- display 层：首屏 / 页眉 / 页脚共享 ----------
	   这些是「组件级」字号，不属于正文阶梯。组件里通过重定义
	   --bp-fs-h1 / --bp-fs-body / --bp-fs-h4 来引用它们，
	   从而绕开下方的 !important 规则（变量会解析成新值）。
	   改这里一处，首屏 / 页眉 / 页脚同时变。 */
	--bp-fs-display-1: clamp(30px, 3.4vw, 50px); /* 首屏 H1 */
	--bp-lh-display-1: 1.16;
	--bp-fs-display-2: 28px; /* 区块大标题（预留） */
	--bp-fs-eyebrow: 11.5px; /* 眉标 / 小标 */
	--bp-ls-eyebrow: 0.2em;
	--bp-fs-lead: 15px; /* 导语 */
	--bp-lh-lead: 1.7;
	--bp-fs-nav: 12.5px; /* 导航项 / 页脚列标题 */
	--bp-ls-nav: 0.09em;
	--bp-fs-topbar: 12.5px; /* 页眉顶栏 / 页脚底栏 */
	--bp-fs-btn: 12.5px; /* 按钮文字 */
	--bp-fs-caption: 13.5px; /* 页脚条目 / 品牌文 / 二级菜单 */
	--bp-lh-caption: 1.6;
	--bp-ls-wide: 0.11em; /* 宽字距（列标题等） */

	/* 字重（站上原声明 300，但 Google Fonts 从未加载 300，实际一直显示 400） */
	--bp-weight-body: 400;
	--bp-weight-heading: 600;
	--bp-weight-strong: 700;

	/* 行高 */
	--bp-lh-body: 1.65;
	--bp-lh-heading: 1.2;

	/* 间距（新区块使用；老页面不动） */
	--bp-space-1: 8px;
	--bp-space-2: 12px;
	--bp-space-3: 16px;
	--bp-space-4: 24px;
	--bp-space-5: 32px;
	--bp-space-6: 48px;
	--bp-space-7: 64px;
	--bp-space-8: 96px;

	/* 其他 */
	--bp-container: 1320px;
	--bp-gutter: 24px;
	--bp-radius: 3px;
}

/* ---------- 正文 ---------- */
html body {
	font-family: var(--bp-font) !important;
	font-size: var(--bp-fs-body) !important;
	font-weight: var(--bp-weight-body) !important;
	line-height: var(--bp-lh-body) !important;
	color: var(--bp-color-text) !important;
	-webkit-font-smoothing: antialiased;
}

html body p:not(.gspb_text),
html body li,
html body td,
html body th,
html body dd,
html body dt,
html body blockquote,
html body .entry-content p:not(.gspb_text),
html body .entry-content li {
	font-family: var(--bp-font) !important;
	font-size: var(--bp-fs-body) !important;
	font-weight: var(--bp-weight-body) !important;
	line-height: var(--bp-lh-body) !important;
	color: var(--bp-color-text) !important;
}

/* ---------- 标题 ----------
   同时覆盖主题的组件选择器（.mf-section-title h2 等），避免被压回 400 */
html body h1:not(.gspb_heading),
html body h2:not(.gspb_heading),
html body h3:not(.gspb_heading),
html body h4:not(.gspb_heading),
html body h5:not(.gspb_heading),
html body h5:not(.gspb_heading),
html body .h1,
html body .h2,
html body .h3,
html body .h4,
html body .entry-content h1:not(.gspb_heading),
html body .entry-content h2:not(.gspb_heading),
html body .entry-content h3:not(.gspb_heading),
html body .entry-content h4:not(.gspb_heading),
html body .mf-section-title h2,
html body .mf-section-title .h2,
html body .wp-block-heading {
	font-family: var(--bp-font) !important;
	font-weight: var(--bp-weight-heading) !important;
	line-height: var(--bp-lh-heading) !important;
	color: var(--bp-color-heading) !important;
	letter-spacing: 0 !important;
	text-transform: none !important;
}

133 html body h1:not(.gspb_heading) { font-size: var(--bp-fs-h1) !important; }
134 html body h2:not(.gspb_heading) { font-size: var(--bp-fs-h2) !important; }
135 html body h3:not(.gspb_heading) { font-size: var(--bp-fs-h3) !important; }
136 html body h4:not(.gspb_heading) { font-size: var(--bp-fs-h4) !important; }
137 html body h5:not(.gspb_heading) { font-size: var(--bp-fs-body) !important; }
138 html body h6:not(.gspb_heading) { font-size: var(--bp-fs-sm) !important; }


html body strong,
html body b {
	font-weight: var(--bp-weight-heading) !important;
	color: var(--bp-color-heading);
}

/* 正文链接：与主色一致（不动下划线与布局） */
html body .entry-content a:not(.bpk-btn):not(.wp-block-button__link) {
	color: var(--bp-color-primary-dark);
}

/* ---------- Blocksy 变量对齐（该主题存在时才生效） ---------- */
:root {
	--theme-palette-color-1: #00baff;
	--theme-palette-color-2: #0091c7;
	--theme-palette-color-3: #393939;
	--theme-palette-color-4: #262c31;
	--theme-palette-color-5: #6b7178;
	--theme-palette-color-6: #939aa1;
	--theme-palette-color-7: #f5f8fa;
	--theme-palette-color-8: #ffffff;
	--theme-text-color: #6b7178;
	--theme-heading-color: #393939;
	--theme-content-width: 1320px;
	--theme-normal-container-width: 1320px;
}

/* ---------- 容器宽度对齐 ----------
   横向轴 = max-width 1240 + 左右 24 → 1500 视口下内容左边缘 154，
   与页眉 .bp-wrap、页脚 .bp-fwrap 完全一致。
   注意：只对齐 bp 自有容器（.bpk-*），**不动主题的 .container**
   （那是老页面版式，改它会改变 29 个页面的行宽，属 P3 重构范围）。 */
.bpk-wrap,
.bpk-container {
	width: 100%;
	max-width: var(--bp-container);
	margin-left: auto;
	margin-right: auto;
	padding-left: var(--bp-gutter);
	padding-right: var(--bp-gutter);
	box-sizing: border-box;
}

@media (max-width: 600px) {
	.bpk-wrap,
	.bpk-container {
		padding-left: 16px;
		padding-right: 16px;
	}
}

/* ==========================================================================
   深色区块反白（作者意图保护）
   --------------------------------------------------------------------------
   问题：上面的标题/正文规则带 !important，会压掉两类「深底浅字」的原始声明，
        导致深色底上出现深灰字（实测首页 4 个区块失效）：
     ① 主题语义类  .mf-section-title.light h2{color:#fff}      → 蓝 CTA 条、Testimonials
     ② WPBakery 内联  <h2 style="color:#ffffff">               → 黑底 Partner 区块
   修法：不改 !important，只在这些容器/元素上重定义颜色变量。!important 规则
        解析 var() 时会取到新值，因此不必与 !important 硬碰。
   安全性：
     · .light 只出现在 .mf-section-title 上（2026-10-26 实测：首页 3 处，
       /about-us/ /services/ /service/cnc-machining/ /resources/case-studies/
       /contact/ 均为 0 处），全部位于深底。
     · ⚠ 不要把 .light-version（.mf-testimonial/.mf-portfolio 的列表容器）
       写进来：那些卡片本身是白底，变量一变白就会「白卡白字」，人名字会消失。
   ========================================================================== */

html body .mf-section-title.light,
html body [style*="color: #ffffff"],
html body [style*="color:#ffffff"],
html body [style*="color: #fff"],
html body [style*="color:#fff"],
html body [style*="color: rgb(255, 255, 255)"] {
	--bp-color-heading: #ffffff;
	--bp-color-text: rgba(255, 255, 255, 0.86);
}

/* WPBakery 纯黑行里的裸正文（这些行没有 .light 语义类，只能按行定位）。
   两行均实测为 background-color:#000000!important：
     vc_custom_1663898346144 = 黑底「Shenzhen Best Parts Co., Ltd.」公司介绍行
     vc_custom_1670290218398 = 黑底「We're Your Partner…」行
   ⚠ 这是 P3 重构前的临时补丁，重构后请删除本块。 */
html body .vc_custom_1663898346144,
html body .vc_custom_1670290218398 {
	--bp-color-heading: #ffffff;
	--bp-color-text: rgba(255, 255, 255, 0.86);
}
