/* =============================================================
   pages.css · 首页 / 工具页 / 信息页 的版式
   ============================================================= */

/* ---------- 通用：进入视口 ---------- */
[data-reveal] {
  opacity: 0;
  transform: translateY(14px);
  transition: opacity .55s var(--ease), transform .55s var(--ease);
}
[data-reveal].is-in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  [data-reveal] { opacity: 1; transform: none; transition: none; }
  html { scroll-behavior: auto; }
}

/* ---------- 页面标题区 ---------- */
.page-head { padding: 46px 0 26px; }
.page-head h1 { font-size: clamp(26px, 3.4vw, 36px); }
.page-head .lead {
  margin-top: 12px;
  max-width: 640px;
  color: var(--text-soft);
  font-size: 15.5px;
  line-height: 1.75;
}
.crumbs {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 16px;
  font-size: 13px;
  color: var(--text-muted);
}
.crumbs a:hover { color: var(--primary-strong); }
.crumbs svg { opacity: .55; }

/* ---------- 首页 Hero ---------- */
.hero { padding: 56px 0 60px; overflow: hidden; }
.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(0, .92fr);
  gap: 52px;
  align-items: center;
}
.hero h1 {
  font-size: clamp(30px, 4.1vw, 46px);
  line-height: 1.22;
  letter-spacing: -.028em;
  font-weight: 680;
}
.hero h1 .hl { color: var(--primary); }
[data-theme="dark"] .hero h1 .hl { color: color-mix(in srgb, var(--primary) 58%, #ffffff); }
.hero-lead {
  margin-top: 18px;
  max-width: 33em;
  color: var(--text-soft);
  font-size: 16px;
  line-height: 1.8;
}
.hero-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 26px; }
.hero-trust {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 18px;
  margin-top: 26px;
  padding-top: 22px;
  border-top: 1px solid var(--border);
  font-size: 13px;
  color: var(--text-muted);
}
.hero-trust span { display: inline-flex; align-items: center; gap: 6px; }
.hero-trust svg { color: var(--accent); }

/* Hero 右侧：服务概览卡 */
.hero-card {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 18px;
  box-shadow: var(--shadow-md);
  padding: 18px;
  background-image: radial-gradient(circle, var(--border) 1px, transparent 1px);
  background-size: 16px 16px;
  background-position: 0 0;
}
.hero-card-in {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
}
.hc-head {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 14px;
  border-bottom: 1px solid var(--border);
  font-size: 12.5px;
  font-weight: 600;
  color: var(--text-soft);
}
.hc-head .live {
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 18%, transparent);
}
.hc-head .hc-id { margin-left: auto; font-weight: 500; color: var(--text-muted); font-family: var(--mono); font-size: 11px; }

.hc-metrics {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1px;
  background: var(--border);
}
.hc-metric { background: var(--surface); padding: 13px 14px; }
.hc-metric b {
  display: block;
  font-size: 21px;
  font-weight: 680;
  letter-spacing: -.02em;
  font-variant-numeric: tabular-nums;
  line-height: 1.25;
}
.hc-metric b em {
  font-style: normal;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-muted);
  margin-left: 1px;
}
.hc-metric span { font-size: 11.5px; color: var(--text-muted); }

.hc-topo { padding: 14px; border-top: 1px solid var(--border); }
.hc-topo svg { width: 100%; height: auto; display: block; }
.hc-legend {
  display: flex;
  gap: 14px;
  padding: 0 14px 14px;
  font-size: 11px;
  color: var(--text-muted);
}
.hc-legend i { display: inline-block; width: 6px; height: 6px; border-radius: 50%; margin-right: 5px; }

/* ---------- 业务卡片 ---------- */
.svc-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}
.svc {
  position: relative;
  display: flex;
  flex-direction: column;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r);
  padding: 24px;
  box-shadow: var(--shadow-sm);
  transition: transform .22s var(--ease), box-shadow .22s var(--ease), border-color .22s var(--ease);
}
.svc:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); border-color: var(--primary-line); }
.svc-top { display: flex; align-items: flex-start; gap: 14px; }
.svc-icon {
  width: 44px; height: 44px;
  flex: none;
  border-radius: 12px;
  display: grid;
  place-items: center;
  background: var(--primary-soft);
  color: var(--primary-strong);
}
.svc h3 { font-size: 17.5px; margin-bottom: 4px; }
.svc .svc-en { font-size: 11.5px; letter-spacing: .08em; text-transform: uppercase; color: var(--text-muted); }
.svc p.svc-desc { margin-top: 16px; color: var(--text-soft); font-size: 14px; line-height: 1.75; }
.svc ul { list-style: none; margin: 16px 0 0; padding: 0; display: grid; gap: 8px; }
.svc li { display: flex; gap: 8px; font-size: 13.5px; color: var(--text-soft); line-height: 1.6; }
.svc li svg { color: var(--primary); margin-top: 3px; }
.svc-link { margin-top: auto; padding-top: 16px; border-top: 1px dashed var(--border); }
.svc ul { margin-bottom: 18px; }

/* ---------- 数据带 ---------- */
.stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0;
  border: 1px solid var(--border);
  border-radius: var(--r);
  background: var(--surface);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}
.stat { padding: 24px 22px; border-left: 1px solid var(--border); }
.stat:first-child { border-left: 0; }
.stat b {
  display: block;
  font-size: 27px;
  font-weight: 700;
  letter-spacing: -.03em;
  font-variant-numeric: tabular-nums;
  line-height: 1.2;
}
.stat b em { font-style: normal; font-size: 15px; font-weight: 600; color: var(--text-muted); margin-left: 2px; }
.stat span { display: block; margin-top: 4px; font-size: 13px; color: var(--text-muted); }

/* ---------- 流程 ---------- */
.flow { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px; counter-reset: step; }
.flow-item { position: relative; padding-top: 40px; }
.flow-item::before {
  counter-increment: step;
  content: "0" counter(step);
  position: absolute;
  top: 0; left: 0;
  width: 30px; height: 30px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--surface);
  border: 1px solid var(--primary-line);
  color: var(--primary-strong);
  font-size: 12px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  z-index: 1;
}
.flow-item::after {
  content: "";
  position: absolute;
  top: 14px; left: 40px; right: -18px;
  border-top: 1px dashed color-mix(in srgb, var(--text-muted) 38%, transparent);
}
.flow-item:last-child::after { display: none; }
.flow-item h3 { font-size: 15.5px; margin-bottom: 6px; }
.flow-item p { font-size: 13.5px; color: var(--text-muted); line-height: 1.7; }

/* ---------- 品牌 ---------- */
.brands {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}
.brand-chip {
  display: inline-flex;
  align-items: center;
  height: 38px;
  padding: 0 16px;
  border-radius: var(--r-pill);
  border: 1px solid var(--border);
  background: var(--surface);
  font-size: 13.5px;
  font-weight: 560;
  color: var(--text-soft);
  letter-spacing: .01em;
}

/* ---------- 最新资讯 ---------- */
.post-cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.post-card {
  display: flex;
  flex-direction: column;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r);
  padding: 22px;
  box-shadow: var(--shadow-sm);
  transition: transform .22s var(--ease), box-shadow .22s var(--ease), border-color .22s var(--ease);
}
.post-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); border-color: var(--primary-line); }
.pc-meta { display: flex; align-items: center; gap: 10px; font-size: 12px; color: var(--text-muted); margin-bottom: 12px; }
.pc-tag {
  display: inline-flex;
  align-items: center;
  height: 22px;
  padding: 0 9px;
  border-radius: var(--r-pill);
  background: var(--primary-soft);
  color: var(--primary-strong);
  font-size: 11.5px;
  font-weight: 600;
}
.post-card h3 { font-size: 16.5px; line-height: 1.5; }
.post-card p { margin-top: 10px; font-size: 13.5px; color: var(--text-muted); line-height: 1.7; flex: 1 0 auto; }
.post-card .pc-more { margin-top: 16px; }

/* ---------- 工具页 ---------- */
.toolbar-line {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  margin: 22px 0 26px;
}
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 32px;
  padding: 0 13px;
  border-radius: var(--r-pill);
  border: 1px solid var(--border);
  background: var(--surface);
  font-size: 13px;
  color: var(--text-soft);
  transition: background .15s var(--ease), color .15s var(--ease), border-color .15s var(--ease);
}
.chip:hover { background: var(--surface-2); color: var(--text); }
.chip.is-active { background: var(--primary); border-color: var(--primary); color: #fff; font-weight: 600; }
.chip .cnt { font-size: 11px; opacity: .7; font-variant-numeric: tabular-nums; }


/* 瀑布流：CSS 多列，卡片高度自然错落 */
.masonry { column-count: 3; column-gap: 18px; }
.tool-card {
  break-inside: avoid;
  display: block;
  margin: 0 0 18px;
  padding: 20px;
  border-radius: var(--r);
  background: var(--surface);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  transition: transform .2s var(--ease), box-shadow .2s var(--ease), border-color .2s var(--ease);
}
.tool-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); border-color: var(--primary-line); }
.tc-top { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; }
.tc-icon {
  width: 38px; height: 38px;
  flex: none;
  border-radius: 11px;
  display: grid;
  place-items: center;
  background: var(--primary-soft);
  color: var(--primary-strong);
}
.tc-badges { margin-left: auto; display: flex; gap: 6px; align-items: center; }
.tc-badge {
  height: 21px;
  padding: 0 8px;
  display: inline-flex;
  align-items: center;
  border-radius: var(--r-pill);
  font-size: 11px;
  font-weight: 600;
  background: var(--primary-soft);
  color: var(--primary-strong);
}
.tc-kind { font-size: 11px; color: var(--text-muted); display: inline-flex; align-items: center; gap: 4px; }
.tool-card h3 { font-size: 15.5px; line-height: 1.45; }
.tool-card p { margin-top: 8px; font-size: 13.5px; line-height: 1.7; color: var(--text-muted); }
.tc-foot {
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px dashed var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 12.5px;
  color: var(--primary-strong);
  font-weight: 600;
}
.tc-foot .host { font-weight: 500; color: var(--text-muted); font-size: 11.5px; font-family: var(--mono); }
.tool-card.is-hidden { display: none; }

  .masonry-empty {
  column-span: all;
  padding: 60px 20px;
  text-align: center;
  color: var(--text-muted);
  font-size: 14px;
  border: 1px dashed var(--border-2);
  border-radius: var(--r);
  background: var(--surface);
}

/* ---------- 信息中心列表 ---------- */
.info-layout { display: grid; grid-template-columns: minmax(0, 1fr) 260px; gap: 32px; align-items: start; }
.post-list { display: grid; gap: 14px; }
.post-item {
  display: grid;
  grid-template-columns: 96px minmax(0, 1fr);
  gap: 20px;
  padding: 22px 24px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r);
  box-shadow: var(--shadow-sm);
  transition: transform .2s var(--ease), box-shadow .2s var(--ease), border-color .2s var(--ease);
}
.post-item:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); border-color: var(--primary-line); }
.pi-date { font-size: 12.5px; color: var(--text-muted); line-height: 1.6; padding-top: 2px; }
.pi-date b { display: block; font-size: 22px; color: var(--text); font-weight: 680; letter-spacing: -.02em; line-height: 1.2; }
.post-item h3 { font-size: 17px; line-height: 1.5; }
.post-item p { margin-top: 8px; font-size: 13.5px; color: var(--text-muted); line-height: 1.7; }
.pi-tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 12px; }
.tag {
  font-size: 11.5px;
  color: var(--text-soft);
  background: var(--surface-2);
  border-radius: 6px;
  padding: 2px 8px;
}

/* 侧栏整体吸顶：只让 <aside> 吸顶，卡片本身不要各自 sticky。
   两张卡都设 sticky + 同一个 top，滚动时会叠在同一位置
   （「遇到具体问题？」盖住「分类」）——第一版就是这个 bug。 */
.info-layout > aside {
  position: sticky;
  top: calc(var(--appbar-h) + 18px);
}
.side-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r);
  padding: 18px;
  box-shadow: var(--shadow-sm);
}
.side-card + .side-card { margin-top: 14px; }
.side-card h4 { font-size: 13px; letter-spacing: .04em; color: var(--text-muted); margin-bottom: 12px; font-weight: 600; }
.side-nav { display: grid; gap: 2px; }
.side-nav button {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  padding: 8px 10px;
  border-radius: 8px;
  font-size: 13.5px;
  color: var(--text-soft);
  text-align: left;
  transition: background .15s var(--ease), color .15s var(--ease);
}
.side-nav button:hover { background: var(--surface-2); color: var(--text); }
.side-nav button.is-active { background: var(--primary-soft); color: var(--primary-strong); font-weight: 600; }
.side-nav .cnt { margin-left: auto; font-size: 11.5px; color: var(--text-muted); font-variant-numeric: tabular-nums; }

/* ---------- 文章页 ---------- */
/* 只加上下内边距：写 padding: 40px 0 60px 会把 .wrap 的左右 20px 一起覆盖掉，
   文章页内容就会比导航栏宽出 20px（logo/页脚品牌对不齐）。 */
.article-wrap { padding-top: 40px; padding-bottom: 60px; }
.article { max-width: none; margin: 0; }
.article-head { margin-bottom: 30px; padding-bottom: 24px; border-bottom: 1px solid var(--border); }
.article-head h1 { font-size: clamp(25px, 3.2vw, 34px); line-height: 1.35; letter-spacing: -.022em; }
.article-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 14px;
  margin-top: 16px;
  font-size: 13px;
  color: var(--text-muted);
}
.article-meta .sep { opacity: .4; }

.prose { font-size: 16px; line-height: 1.9; color: var(--text-soft); }
.prose > * + * { margin-top: 18px; }
.prose h2 {
  margin-top: 40px;
  font-size: 22px;
  color: var(--text);
  letter-spacing: -.02em;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--border);
}
.prose h3 { margin-top: 30px; font-size: 18px; color: var(--text); }
.prose h4 { margin-top: 24px; font-size: 16px; color: var(--text); }
.prose p { color: var(--text-soft); }
.prose strong { color: var(--text); font-weight: 640; }
.prose a { color: var(--primary-strong); border-bottom: 1px solid var(--primary-line); }
.prose a:hover { border-bottom-color: var(--primary); }
.prose ul, .prose ol { padding-left: 1.35em; }
.prose li + li { margin-top: 7px; }
.prose li::marker { color: var(--text-muted); }
.prose blockquote {
  margin-left: 0; margin-right: 0;
  padding: 14px 18px;
  border-left: 3px solid var(--primary);
  background: var(--primary-soft);
  border-radius: 0 10px 10px 0;
  color: var(--text-soft);
  font-size: 15px;
}
.prose blockquote p { margin: 0; }
.prose code {
  font-family: var(--mono);
  font-size: .88em;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 5px;
  padding: 2px 6px;
  color: var(--text);
}
.prose pre {
  background: var(--surface-head);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 16px 18px;
  overflow-x: auto;
  font-size: 13.5px;
  line-height: 1.7;
}
.prose pre code { background: none; border: 0; padding: 0; font-size: inherit; }
.prose img { border-radius: 12px; border: 1px solid var(--border); }
.prose hr { border: 0; border-top: 1px solid var(--border); margin: 34px 0; }
.prose table { width: 100%; border-collapse: collapse; font-size: 14px; }
.prose th, .prose td { border: 1px solid var(--border); padding: 9px 12px; text-align: left; }
.prose th { background: var(--surface-head); color: var(--text); font-weight: 600; }

.article-foot {
  max-width: none;
  margin: 40px 0 0;
  padding-top: 22px;
  border-top: 1px solid var(--border);
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  justify-content: space-between;
}
.pager { display: flex; gap: 10px; flex-wrap: wrap; }
.pager a {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 12px 16px;
  border: 1px solid var(--border);
  border-radius: var(--r-sm);
  background: var(--surface);
  font-size: 13.5px;
  max-width: 260px;
  transition: border-color .15s var(--ease), background .15s var(--ease);
}
.pager a:hover { border-color: var(--primary-line); background: var(--surface-2); }
.pager a span { font-size: 11.5px; color: var(--text-muted); }

.notice {
  max-width: none;
  margin: 0;
  padding: 18px 20px;
  border-radius: var(--r-sm);
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text-soft);
  font-size: 14px;
}

/* ---------- 响应式 ---------- */
@media (max-width: 1000px) {
  .hero-grid { grid-template-columns: 1fr; gap: 36px; }
  .hero-card { max-width: 520px; }
  .svc-grid { grid-template-columns: 1fr; }
  .stats { grid-template-columns: 1fr 1fr; }
  .stat:nth-child(3) { border-left: 0; }
  .stat:nth-child(n+3) { border-top: 1px solid var(--border); }
  .flow { grid-template-columns: 1fr 1fr; gap: 26px 18px; }
  .flow-item:nth-child(2)::after { display: none; }
  .post-cards { grid-template-columns: 1fr; }
  .masonry { column-count: 2; }
  .info-layout { grid-template-columns: 1fr; }
  .info-layout > aside { position: static; }
}
@media (max-width: 720px) {
  .hero { padding: 34px 0 40px; }
  .hero-lead { font-size: 15px; }
  .hero-actions .btn { flex: 1 1 auto; }
  .masonry { column-count: 1; }
  .page-head { padding: 30px 0 20px; }
  .post-item { grid-template-columns: 1fr; gap: 10px; padding: 18px; }
  .pi-date { display: flex; align-items: baseline; gap: 8px; }
  .pi-date b { font-size: 15px; }
  .flow { grid-template-columns: 1fr; }
  .flow-item::after { display: none; }
  .article { padding: 0; }
  .prose { font-size: 15.5px; }
}

/* ---------- 资质页（zizhi.html） ---------- */
.cert-section { margin: 34px 0 46px; }
.cert-h2 { font-size: 20px; letter-spacing: -.01em; }
.cert-note {
  margin-top: 8px;
  font-size: 13.5px;
  color: var(--text-muted);
  line-height: 1.75;
  max-width: 62em;
}
.cert-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  margin-top: 18px;
}
.cert {
  margin: 0;
  display: flex;
  flex-direction: column;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: border-color .2s ease, transform .2s ease;
}
.cert:hover { border-color: var(--primary-line); transform: translateY(-2px); }
.cert-media {
  aspect-ratio: 4 / 3;
  display: grid;
  place-items: center;
  background: var(--surface-2);
  border-bottom: 1px solid var(--border);
}
.cert-media img { width: 100%; height: 100%; object-fit: contain; padding: 10px; }
/* 图片还没上传时（img 加载失败会被移除），显示占位文字 */
.cert-media:empty::after {
  content: "证照图片待上传";
  font-size: 12px;
  letter-spacing: .04em;
  color: var(--text-muted);
}
.cert figcaption { padding: 14px 16px 16px; }
.cert h3 { font-size: 15.5px; }
.cert figcaption p { margin-top: 5px; font-size: 12.8px; color: var(--text-muted); line-height: 1.65; }

.cert-list {
  margin-top: 16px;
  border: 1px solid var(--border);
  border-radius: 16px;
  background: var(--surface);
  overflow: hidden;
}
.cert-row {
  display: grid;
  grid-template-columns: 22px 132px minmax(0, 1fr);
  align-items: center;
  gap: 10px;
  padding: 13px 16px;
  font-size: 13.5px;
  color: var(--text-soft);
}
.cert-row + .cert-row { border-top: 1px solid var(--border); }
.cert-row b { color: var(--text); font-weight: 600; }
.cert-row svg { color: var(--primary); }

@media (max-width: 1000px) {
  .cert-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 720px) {
  .cert-grid { grid-template-columns: 1fr; }
  .cert-row { grid-template-columns: 20px 1fr; }
  .cert-row span:last-child { grid-column: 1 / -1; }
}
