/* ============================================================
   钣面表面处理中台 · style.css
   商业科技风 / 工业质感 / 无模板痕迹
   断点约定：≤1024 两列/单列收敛，≤640 单列、TOC 隐藏
   ============================================================ */
:root {
  --ink: #14273D;
  --ink-2: #3D5570;
  --ink-3: #71839B;
  --primary: #14508C;
  --primary-deep: #0E3A69;
  --accent: #E8590C;
  --accent-deep: #C24A08;
  --bg: #F5F7FA;
  --card: #FFFFFF;
  --line: #E2E8F0;
  --line-dark: #CBD5E1;
  --ok: #1D7A46;
  --steel: #33475E;
  --radius: 10px;
  --shadow: 0 1px 3px rgba(20, 39, 61, .06), 0 6px 24px rgba(20, 39, 61, .05);
  --font: "PingFang SC", "Microsoft YaHei", "Source Han Sans SC", "Noto Sans SC", system-ui, -apple-system, sans-serif;
  --mono: "JetBrains Mono", "SFMono-Regular", Consolas, "Courier New", monospace;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font);
  color: var(--ink);
  background: var(--bg);
  font-size: 16px;
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3, h4, p, li, td, th { overflow-wrap: anywhere; word-break: break-word; }
a { color: var(--primary); text-decoration: none; }
a:hover { color: var(--accent-deep); }
img { max-width: 100%; display: block; }
.container { max-width: 1200px; margin: 0 auto; padding: 0 24px; }

/* ---------- header ---------- */
.site-header {
  background: #0D1F35;
  color: #E8EEF5;
  position: sticky; top: 0; z-index: 100;
  border-bottom: 1px solid rgba(255,255,255,.08);
}
.site-header .container { display: flex; align-items: center; height: 64px; gap: 32px; }
.brand { display: flex; align-items: center; gap: 12px; color: #fff; }
.brand-mark {
  width: 34px; height: 34px; border-radius: 8px; flex: none;
  background: linear-gradient(135deg, var(--primary) 0%, #1E6BB8 60%, var(--accent) 130%);
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: 17px; color: #fff; letter-spacing: 0;
}
.brand-name { font-size: 17px; font-weight: 700; letter-spacing: .5px; }
.brand-sub { font-size: 11px; color: #8FA6BF; letter-spacing: 1px; display: block; line-height: 1.2; }
.main-nav { margin-left: auto; display: flex; gap: 4px; }
.main-nav a {
  color: #C4D2E2; font-size: 15px; padding: 8px 14px; border-radius: 6px;
  transition: background .15s, color .15s;
}
.main-nav a:hover { color: #fff; background: rgba(255,255,255,.08); }
.main-nav a.active { color: #fff; background: rgba(30,107,184,.35); }

/* ---------- hero ---------- */
.hero { background: linear-gradient(160deg, #0D1F35 0%, #10304F 55%, #14405F 100%); color: #E8EEF5; position: relative; overflow: hidden; }
.hero::after {
  content: ""; position: absolute; right: -140px; top: -140px; width: 480px; height: 480px;
  background: radial-gradient(circle, rgba(232,89,12,.16) 0%, transparent 65%);
  pointer-events: none;
}
.hero-inner { display: grid; grid-template-columns: 1.15fr .85fr; gap: 48px; padding: 72px 0 64px; position: relative; z-index: 1; }
.hero-kicker { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; color: #F0A878; border: 1px solid rgba(232,89,12,.45); padding: 4px 12px; border-radius: 999px; margin-bottom: 20px; letter-spacing: 1px; }
.hero h1 { font-size: 40px; line-height: 1.3; font-weight: 700; color: #fff; margin-bottom: 18px; }
.hero h1 em { font-style: normal; color: #F59E5B; }
.hero-lede { font-size: 16.5px; color: #B9C8DA; max-width: 560px; margin-bottom: 28px; }
.hero-stats { display: flex; gap: 36px; margin-top: 34px; flex-wrap: wrap; }
.hero-stat b { display: block; font-size: 26px; color: #fff; font-weight: 700; font-family: var(--mono); }
.hero-stat span { font-size: 13px; color: #8FA6BF; }
.hero-axis { background: rgba(255,255,255,.05); border: 1px solid rgba(255,255,255,.12); border-radius: var(--radius); padding: 24px; backdrop-filter: blur(2px); }
.hero-axis h3 { font-size: 15px; color: #9FB4CC; font-weight: 600; margin-bottom: 14px; letter-spacing: 1px; }
.axis-row { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 16px; align-items: center; }
.axis-row:last-child { margin-bottom: 0; }
.axis-label { font-size: 13px; color: #7E96B1; width: 52px; flex: none; }
.axis-chip {
  font-size: 13px; color: #D7E2EE; border: 1px solid rgba(255,255,255,.18);
  padding: 4px 12px; border-radius: 999px; transition: all .15s;
}
.axis-chip:hover { border-color: var(--accent); color: #F59E5B; }

/* ---------- sections ---------- */
.section { padding: 64px 0; }
.section-alt { background: #EDF1F6; }
.section-head { margin-bottom: 36px; }
.section-head .eyebrow { font-size: 13px; color: var(--accent-deep); letter-spacing: 2px; font-weight: 600; display: block; margin-bottom: 8px; }
.section-head h2 { font-size: 28px; color: var(--ink); font-weight: 700; }
.section-head p { color: var(--ink-3); margin-top: 8px; max-width: 720px; }

/* 工艺矩阵表 */
.cap-table-wrap { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); overflow-x: auto; }
table.data { width: 100%; border-collapse: collapse; font-size: 14.5px; min-width: 640px; }
table.data th {
  background: #102A45; color: #DCE6F2; text-align: left; padding: 13px 16px;
  font-weight: 600; white-space: nowrap; font-size: 13.5px; letter-spacing: .5px;
}
table.data td { padding: 13px 16px; border-top: 1px solid var(--line); vertical-align: top; }
table.data tr:nth-child(even) td { background: #F8FAFC; }
table.data td b { color: var(--ink); }
.num { font-family: var(--mono); font-size: 13.5px; }

/* 流程带 */
.flow-strip { display: grid; grid-template-columns: repeat(6, 1fr); gap: 0; background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; }
.flow-step { padding: 24px 18px; border-right: 1px solid var(--line); position: relative; }
.flow-step:last-child { border-right: none; }
.flow-step i { font-style: normal; font-family: var(--mono); font-size: 12px; color: var(--accent-deep); display: block; margin-bottom: 8px; }
.flow-step b { font-size: 15.5px; display: block; margin-bottom: 6px; }
.flow-step span { font-size: 13px; color: var(--ink-3); line-height: 1.6; display: block; }

/* 工艺库卡片（仅首页/列表右侧内容区使用；分类侧栏一律垂直列表） */
.craft-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.craft-card { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); padding: 26px; border-top: 3px solid var(--primary); display: flex; flex-direction: column; }
.craft-card:nth-child(2n) { border-top-color: var(--accent); }
.craft-card h3 { font-size: 18px; margin-bottom: 10px; }
.craft-card h3 a { color: var(--ink); }
.craft-card h3 a:hover { color: var(--accent-deep); }
.craft-card p { font-size: 14px; color: var(--ink-3); flex: 1; }
.craft-meta { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 16px; }
.craft-meta span { font-size: 12px; background: #EEF3F9; color: var(--primary-deep); border-radius: 4px; padding: 2px 8px; font-family: var(--mono); }

/* 文章列表（首页最新区） */
.post-list { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; }
.post-item { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); padding: 24px 26px; display: flex; flex-direction: column; }
.post-tag { font-size: 12px; color: var(--accent-deep); letter-spacing: 1px; font-weight: 600; margin-bottom: 10px; }
.post-item h3 { font-size: 17.5px; line-height: 1.5; margin-bottom: 10px; }
.post-item h3 a { color: var(--ink); }
.post-item h3 a:hover { color: var(--accent-deep); }
.post-item p { font-size: 14px; color: var(--ink-3); flex: 1; }
.post-more { font-size: 13.5px; color: var(--primary); margin-top: 14px; display: inline-block; }

/* 三轴选型台 */
.triax { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.triax-card { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); padding: 28px; }
.triax-card .no { font-family: var(--mono); font-size: 13px; color: var(--accent-deep); display: block; margin-bottom: 12px; }
.triax-card h3 { font-size: 19px; margin-bottom: 12px; }
.triax-card p { font-size: 14px; color: var(--ink-3); margin-bottom: 16px; }
.triax-card ul { list-style: none; }
.triax-card li { font-size: 14px; padding: 7px 0; border-top: 1px dashed var(--line); }
.triax-card li a { color: var(--ink-2); }
.triax-card li a:hover { color: var(--accent-deep); }

/* ---------- 列表页（分类左侧垂直列表 [M1']） ---------- */
.list-layout { display: grid; grid-template-columns: 240px 1fr; gap: 40px; padding: 48px 0 72px; }
.cat-side { align-self: start; position: sticky; top: 88px; }
.cat-side h2 { font-size: 16px; color: var(--ink-3); font-weight: 600; margin-bottom: 12px; letter-spacing: 1px; }
ul.category-list { list-style: none; border: 1px solid var(--line); border-radius: var(--radius); background: var(--card); overflow: hidden; }
ul.category-list li { border-bottom: 1px solid var(--line); }
ul.category-list li:last-child { border-bottom: none; }
ul.category-list a {
  display: block; padding: 11px 18px; font-size: 14.5px; color: var(--ink-2);
  border-left: 3px solid transparent; transition: all .15s;
}
ul.category-list a:hover { background: #F2F6FB; color: var(--primary); }
ul.category-list a.active { background: #EEF3F9; color: var(--primary-deep); border-left-color: var(--accent); font-weight: 600; }
.cat-content .page-title { font-size: 28px; margin-bottom: 8px; }
.cat-desc { color: var(--ink-3); font-size: 14.5px; margin-bottom: 28px; max-width: 720px; }
.rows { display: flex; flex-direction: column; gap: 14px; }
.row-item { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); padding: 22px 26px; }
.row-item h3 { font-size: 17px; margin-bottom: 8px; }
.row-item h3 a { color: var(--ink); }
.row-item h3 a:hover { color: var(--accent-deep); }
.row-item p { font-size: 14px; color: var(--ink-3); }
.row-meta { margin-top: 10px; display: flex; gap: 8px; flex-wrap: wrap; }
.row-meta span { font-size: 12px; background: #EEF3F9; color: var(--primary-deep); border-radius: 4px; padding: 2px 8px; font-family: var(--mono); }
.pager { display: flex; gap: 8px; margin-top: 28px; }
.pager a, .pager span { font-size: 14px; padding: 7px 14px; background: var(--card); border: 1px solid var(--line); border-radius: 6px; color: var(--ink-2); }
.pager .cur { background: var(--primary); border-color: var(--primary); color: #fff; }

/* ---------- 详情页（正文 760 + 右侧 TOC 240 [M1'']） ---------- */
.detail-layout { display: grid; grid-template-columns: 1fr 240px; gap: 40px; padding: 48px 0 72px; max-width: 1100px; margin: 0 auto; }
.article-main { max-width: 760px; min-width: 0; }
.article-title { font-size: 34px; line-height: 1.35; font-weight: 700; color: var(--ink); margin-bottom: 14px; }
.article-meta { display: flex; align-items: center; gap: 16px; font-size: 13.5px; color: var(--ink-3); margin-bottom: 26px; flex-wrap: wrap; }
.article-meta time { font-family: var(--mono); }
.tag-text { display: inline-block; font-size: 12.5px; background: #EEF3F9; color: var(--primary-deep); border-radius: 4px; padding: 2px 10px; }
.lead-block {
  background: linear-gradient(135deg, #102A45, #16406B); color: #DCE6F2;
  border-radius: var(--radius); padding: 22px 26px; margin-bottom: 26px; font-size: 15px; line-height: 1.85;
}
.lead-block b { color: #F59E5B; }
.kw-line { font-size: 13.5px; color: var(--ink-3); margin-bottom: 26px; }
.kw-line b { color: var(--ink-2); font-weight: 600; }

.article-body h2 { font-size: 23px; margin: 40px 0 16px; padding-left: 12px; border-left: 4px solid var(--accent); line-height: 1.4; }
.article-body h3 { font-size: 18px; margin: 28px 0 12px; color: var(--primary-deep); }
.article-body p { margin-bottom: 14px; color: #2B3E55; }
.article-body ul, .article-body ol { margin: 0 0 14px 22px; }
.article-body li { margin-bottom: 6px; color: #2B3E55; }
.article-body strong { color: var(--ink); }
.table-wrap { overflow-x: auto; margin: 18px 0 22px; border-radius: 8px; box-shadow: var(--shadow); background: var(--card); }
.article-body table.data { min-width: 560px; }
.callout {
  background: #FFF7F0; border: 1px solid #F5C9A8; border-left: 4px solid var(--accent);
  border-radius: 8px; padding: 16px 20px; margin: 24px 0; font-size: 14.5px; color: #6B4A2F;
}
.callout b { color: var(--accent-deep); }
.conclusion { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px 24px; margin: 26px 0; }
.conclusion h4 { font-size: 15px; color: var(--ok); margin-bottom: 10px; letter-spacing: 1px; }
.conclusion ol { margin-left: 20px; }
.conclusion li { font-size: 14.5px; margin-bottom: 6px; }

/* FAQ：裸 <details>（faq_dom: bare_details） */
details { background: var(--card); border: 1px solid var(--line); border-radius: 8px; margin-bottom: 10px; }
details summary {
  cursor: pointer; padding: 14px 18px; font-size: 15px; font-weight: 600; color: var(--ink);
  list-style: none; position: relative; padding-right: 40px;
}
details summary::-webkit-details-marker { display: none; }
details summary::after {
  content: "+"; position: absolute; right: 18px; top: 50%; transform: translateY(-50%);
  font-family: var(--mono); color: var(--accent-deep); font-size: 18px;
}
details[open] summary::after { content: "−"; }
details .faq-a { padding: 0 18px 14px; font-size: 14.5px; color: var(--ink-2); }

/* 相关阅读 */
.related { margin-top: 36px; border-top: 1px solid var(--line); padding-top: 24px; }
.related h3 { font-size: 18px; margin-bottom: 14px; }
.related ul { list-style: none; }
.related li { padding: 10px 0; border-bottom: 1px dashed var(--line); font-size: 15px; }
.related li span { display: block; font-size: 13px; color: var(--ink-3); margin-top: 3px; }

/* TOC */
.toc-aside { position: sticky; top: 88px; max-height: calc(100vh - 110px); overflow-y: auto; }
.toc-aside .toc-box { border: 1px solid var(--line); border-radius: var(--radius); background: var(--card); padding: 18px 20px; }
.toc-aside .toc-title { font-size: 13px; letter-spacing: 2px; color: var(--ink-3); font-weight: 600; margin-bottom: 10px; }
#toc { list-style: none; }
#toc li { margin-bottom: 2px; }
#toc a { display: block; font-size: 13.5px; color: var(--ink-2); padding: 5px 10px; border-left: 2px solid var(--line); transition: all .15s; }
#toc a:hover { color: var(--accent-deep); border-left-color: var(--accent); background: #F7FAFD; }

/* ---------- 面包屑 ---------- */
nav.breadcrumb { font-size: 13px; color: var(--ink-3); margin-bottom: 18px; }
nav.breadcrumb a { color: var(--ink-3); }
nav.breadcrumb a:hover { color: var(--accent-deep); }
nav.breadcrumb .sep { margin: 0 8px; color: var(--line-dark); }

/* ---------- 左侧中部胶囊（企微名片 + 回到顶部） ---------- */
.float-capsule {
  position: fixed; left: 14px; top: 50%; transform: translateY(-50%);
  display: flex; flex-direction: column; gap: 10px; z-index: 900;
}
.capsule-btn {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  width: 56px; min-height: 56px; padding: 8px 4px; border-radius: 28px;
  background: var(--card); box-shadow: 0 2px 10px rgba(20,39,61,.18);
  border: 1px solid var(--line); cursor: pointer; user-select: none;
  transition: transform .15s, box-shadow .15s; font-family: var(--font);
}
.capsule-btn:hover { transform: translateY(-2px); box-shadow: 0 6px 18px rgba(20,39,61,.25); }
.capsule-btn svg { width: 22px; height: 22px; margin-bottom: 3px; }
.capsule-btn em { font-style: normal; font-size: 10.5px; color: var(--ink-2); letter-spacing: .5px; white-space: nowrap; }
.capsule-btn.wx svg { color: #07C160; }
.capsule-btn.top svg { color: var(--primary); }
.capsule-btn.top.show { display: flex; }
.capsule-btn.top.hide { display: none; }

/* 企微名片弹层 */
.wechat-modal { display: none; position: fixed; inset: 0; z-index: 1000; }
.wechat-modal.open { display: flex; align-items: center; justify-content: center; }
.wechat-modal .mask { position: absolute; inset: 0; background: rgba(10, 22, 38, .72); }
.wechat-modal .card {
  position: relative; z-index: 1; background: transparent; border-radius: 12px;
  box-shadow: 0 24px 64px rgba(0,0,0,.45); overflow: hidden;
}
.wechat-modal .card img { width: 300px; height: 500px; object-fit: contain; background: #06203A; }
.wechat-modal .close {
  position: absolute; top: 8px; right: 10px; width: 32px; height: 32px; border-radius: 50%;
  background: rgba(0,0,0,.4); color: #fff; border: none; font-size: 18px; cursor: pointer; line-height: 1;
}
.wechat-modal .tip { text-align: center; color: #CFE0F2; font-size: 13px; margin-top: 12px; }

/* ---------- footer ---------- */
.site-footer { background: #0D1F35; color: #8FA6BF; padding: 48px 0 32px; margin-top: 40px; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 40px; padding-bottom: 32px; border-bottom: 1px solid rgba(255,255,255,.08); }
.footer-grid h4 { color: #DCE6F2; font-size: 14.5px; margin-bottom: 14px; letter-spacing: 1px; }
.footer-grid ul { list-style: none; }
.footer-grid li { margin-bottom: 8px; font-size: 13.5px; }
.footer-grid a { color: #8FA6BF; }
.footer-grid a:hover { color: #F59E5B; }
.footer-desc { font-size: 13.5px; line-height: 1.8; max-width: 380px; }
.footer-bottom { padding-top: 22px; font-size: 12.5px; display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px; }

/* ---------- 叶子页 ---------- */
.leaf-wrap { max-width: 860px; margin: 0 auto; padding: 48px 24px 72px; }
.leaf-wrap h1 { font-size: 30px; margin-bottom: 8px; }
.leaf-sub { color: var(--ink-3); font-size: 14.5px; margin-bottom: 32px; }
.leaf-body h2 { font-size: 21px; margin: 32px 0 12px; padding-left: 12px; border-left: 4px solid var(--primary); }
.leaf-body p { margin-bottom: 12px; color: #2B3E55; }
.leaf-body ul { margin: 0 0 14px 22px; }
.contact-cards { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; margin: 24px 0; }
.contact-card { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); padding: 22px 24px; }
.contact-card b { display: block; font-size: 15px; margin-bottom: 8px; }
.contact-card p { font-size: 13.5px; color: var(--ink-3); margin: 0; }
.contact-card .wx-link { color: var(--accent-deep); font-weight: 600; cursor: pointer; }

/* 404 */
.nf-wrap { text-align: center; padding: 96px 24px; }
.nf-wrap b { font-size: 64px; font-family: var(--mono); color: var(--primary); display: block; }
.nf-wrap p { color: var(--ink-3); margin: 12px 0 24px; }

/* ============================================================
   响应式
   ============================================================ */
@media (max-width: 1024px) {
  .hero-inner { grid-template-columns: 1fr; padding: 56px 0 48px; }
  .craft-grid { grid-template-columns: repeat(2, 1fr); }
  .triax { grid-template-columns: 1fr; }
  .flow-strip { grid-template-columns: repeat(3, 1fr); }
  .flow-step:nth-child(3) { border-right: none; }
  .flow-step { border-bottom: 1px solid var(--line); }
  .list-layout { grid-template-columns: 1fr; }
  .cat-side { position: static; }
  .detail-layout { grid-template-columns: 1fr; }
  .toc-aside { position: static; max-height: none; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 640px) {
  .site-header .container { height: auto; padding: 10px 16px; flex-wrap: wrap; gap: 8px; }
  .main-nav { margin-left: 0; width: 100%; overflow-x: auto; }
  .main-nav a { white-space: nowrap; padding: 6px 10px; }
  .hero h1 { font-size: 26px; }
  .article-title { font-size: 22px; }
  .leaf-wrap h1 { font-size: 24px; }
  .section { padding: 44px 0; }
  .section-head h2 { font-size: 22px; }
  .craft-grid, .post-list, .contact-cards { grid-template-columns: 1fr; }
  .flow-strip { grid-template-columns: repeat(2, 1fr); }
  .flow-step:nth-child(2n) { border-right: none; }
  .hero-stats { gap: 20px; }
  .hero-stat b { font-size: 20px; }
  .sidebar, .toc-aside { display: none; }
  .float-capsule { left: 8px; }
  .capsule-btn { width: 50px; min-height: 50px; }
  .footer-grid { grid-template-columns: 1fr; }
  .article-main { max-width: 100%; }
}
