/* ============================================================
   工程计算库 · 内页语汇层 v2（Technical Drawing）
   由全部内页引入：standards / calculators / tables / solutions /
   articles / news / search / content 及各类详情页。

   职责：只做一件事——把 style.css 里的 legacy 组件
   （圆角卡片 / 彩色图标块 / 投影 / 上浮悬停 / 多彩分类标签）
   映射到主页已建立的「技术图纸」语汇：
   零圆角 / 零投影 / 1px 墨线分隔 / 单一工程橙 / 等宽数字。

   与 theme-v2.css 的分工：
   - theme-v2.css → Design Token + 基础层 + Header + Footer（全站）
   - home-v2.css   → 首页专属区块
   - inner-v2.css  → 内页组件（本文件）

   注意：本文件必须晚于 style.css 加载。对 style.css 中
   使用 :nth-child(n) 等权重较高的规则，这里用同等权重的
   :nth-child(n) 覆盖，靠加载顺序取胜。
   ============================================================ */

/* ------------------------------------------------------------
   1. 页面骨架：容器宽度与左边缘对齐主页
   旧版主页内容区 1152px（1200 容器 - 24 × 2），内页 1160px
   （1200 主容器 - 20 × 2），两页切换时正文左边缘错位 4px。
   ------------------------------------------------------------ */
.main-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 32px 24px 72px;
}

/* 内页第一个板块的顶部间距收紧（页头已占位） */
.breadcrumb {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 18px;
    font-size: 12px;
    line-height: 18px;
    color: var(--v2-ink-500);
}

.breadcrumb a {
    color: var(--v2-ink-500);
    transition: color 0.15s;
}

.breadcrumb a:hover {
    color: var(--v2-accent-ink);
}

/* 分隔符与当前页统一走 ink-500（5.78:1）。
   不要把分隔符压到 --v2-line —— #dce1e6 只有 1.18:1，无法辨认。 */
.breadcrumb span {
    color: var(--v2-ink-500);
}

.breadcrumb span:last-child {
    color: var(--v2-ink-700);
}

/* 详情页返回入口：改为纯文字箭头，与面包屑同语汇 */
.back-to-parent {
    margin: 0 0 18px;
}

.back-to-parent a {
    display: inline-flex;
    align-items: center;
    min-height: 32px;
    padding: 0;
    border: 0;
    border-radius: 0;
    background: none;
    font-size: 13px;
    color: var(--v2-ink-500);
    transition: color 0.15s;
}

.back-to-parent a:hover {
    border: 0;
    background: none;
    color: var(--v2-accent-ink);
}

/* ------------------------------------------------------------
   2. 块级与标题：统一到 v2 字阶
   Display 54 / H1 40 / H2 28 / H3 20 / H4 16 / Body 15 / Small 13 / Meta 12
   ------------------------------------------------------------ */
.section {
    margin-bottom: 0;
}

.section-header {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 16px 20px;
    flex-wrap: wrap;
    padding-bottom: 14px;
    margin-bottom: 24px;
    border-bottom: 1px solid var(--v2-line);
}

.section-header h1 {
    font-size: 40px;
    line-height: 52px;
    font-weight: 700;
    letter-spacing: -0.4px;
    color: var(--v2-ink-900);
}

.section-header h2 {
    position: relative;
    padding-left: 14px;
    font-size: 28px;
    line-height: 38px;
    font-weight: 700;
    letter-spacing: -0.3px;
    color: var(--v2-ink-900);
}

/* legacy 的竖条改为 v2 信号条（等长 4px，与主页编号行一致） */
.section-header h2::before {
    content: "";
    position: absolute;
    left: 0;
    top: 8px;
    bottom: 8px;
    width: 4px;
    border-radius: 0;
    background: var(--v2-accent);
}

.section-header > span {
    font-size: 13px !important;
    line-height: 22px;
    color: var(--v2-ink-500) !important;
}

.section-header a {
    font-size: 13px;
    font-weight: 500;
    color: var(--v2-accent-ink);
}

.section-note {
    margin: 6px 0 0;
    font-size: 13px;
    line-height: 22px;
    color: var(--v2-ink-500);
}

/* 页头独占整行时的收束（standards / calculators 用独立 .section 包 h1） */
.section > .section-header:first-child {
    margin-bottom: 20px;
}

/* ------------------------------------------------------------
   3. 卡片网格与工具卡
   去圆角、去投影、去 44px 彩色图标块、去上浮悬停
   ------------------------------------------------------------ */
.card-grid {
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 12px;
}

.tool-card {
    padding: 20px;
    border: 1px solid var(--v2-line);
    border-radius: 0;
    background: var(--v2-surface);
    box-shadow: none;
    transition: border-color 0.15s, background 0.15s;
}

.tool-card:hover {
    border-color: var(--v2-ink-500);
    background: var(--v2-surface);
    box-shadow: none;
    transform: none;
}

/* 彩色图标块 → 改为零背景线性图标（24px 墨线描边）
   旧版是 44x44 圆角彩色底 + 希腊字母字符（Σ/Τ/Υ/Φ…），既不成体系也不表意 */
.tool-card .card-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    margin-bottom: 12px;
    border-radius: 0;
    background: none;
    font-size: 0;
    line-height: 0;
}

.tool-card .card-icon svg {
    display: block;
    width: 24px;
    height: 24px;
}

/* legacy 首页分类卡的彩色图标块直接移除 */
.category-card .cat-icon {
    display: none;
}

.tool-card h3 {
    font-size: 16px;
    line-height: 24px;
    font-weight: 600;
    color: var(--v2-ink-900);
}

.tool-card p {
    font-size: 13px;
    line-height: 22px;
    color: var(--v2-ink-500);
}

.tool-card .card-tag,
.tool-card .calc-card-tag {
    margin-top: 12px;
    font-family: var(--font-mono);
    font-size: 11px;
    line-height: 18px;
    color: var(--v2-ink-500);
}

/* 计算器分组标题（JS 注入） */
.calc-group-section {
    margin-bottom: 36px;
}

.calc-group-title {
    display: flex;
    align-items: center;
    gap: 10px;
    padding-bottom: 12px;
    margin-bottom: 16px;
    border-bottom: 1px solid var(--v2-line);
    font-size: 20px;
    line-height: 28px;
    font-weight: 600;
    color: var(--v2-ink-900);
}

.calc-group-title::before {
    content: "";
    flex: none;
    width: 4px;
    height: 18px;
    background: var(--v2-accent);
}

.calc-group-count {
    font-family: var(--font-mono);
    font-size: 12px;
    font-weight: 400;
    color: var(--v2-ink-500);
}

/* ------------------------------------------------------------
   4. 搜索与筛选条
   ------------------------------------------------------------ */
.calc-search-bar,
.standards-search-bar {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
    padding: 0 0 20px;
    margin-bottom: 24px;
    border-bottom: 1px solid var(--v2-line);
}

.calc-search-bar input,
.standards-search-bar input {
    flex: 1 1 320px;
    min-width: 0;
    height: 40px;
    padding: 0 14px;
    border: 1px solid var(--v2-line);
    border-radius: 0;
    background: var(--v2-canvas);
    font-size: 14px;
    color: var(--v2-ink-900);
}

.calc-search-bar input:focus,
.standards-search-bar input:focus {
    outline: none;
    border-color: var(--v2-ink-500);
    background: var(--v2-surface);
}

.calc-search-bar input::placeholder,
.standards-search-bar input::placeholder {
    color: var(--v2-ink-500);
}

.calc-count-badge,
.calc-search-bar .calc-count-badge,
.standards-search-bar .calc-count-badge {
    flex: none;
    padding: 0;
    border: 0;
    border-radius: 0;
    background: none;
    font-family: var(--font-mono);
    font-size: 12px;
    font-weight: 400;
    color: var(--v2-ink-500);
}

/* 公式区：去浅底块，参考依据文字保证可读（原 #9ca3af 在 #f8f9fa 上仅 2.41:1） */
.calc-formula {
    margin-top: 20px;
    padding: 16px 18px;
    border: 1px solid var(--v2-line);
    border-radius: 0;
    background: var(--v2-surface);
    font-size: 13px;
    line-height: 22px;
    color: var(--v2-ink-700);
}

.calc-formula .formula-title {
    margin-bottom: 6px;
    font-weight: 600;
    color: var(--v2-ink-900);
}

.calc-formula small,
.calc-formula .formula-ref {
    font-size: 12px;
    line-height: 18px;
    color: var(--v2-ink-500);
}

.calc-formula code {
    padding: 2px 6px;
    border-radius: 0;
    background: var(--v2-canvas);
    font-family: var(--font-mono);
    font-size: 12px;
    color: var(--v2-ink-900);
}

/* 内页正文链接统一强调色：--primary(#c05621) 在灰底仅 4.11:1，
   accent-ink(#8c3d14) 为 7.52:1 */
.calc-panel a,
.calc-sidebar a,
.content-body a,
.article-content a,
.standard-content a,
.section-note a,
.main-content p a,
.main-content li a,
.main-content td a,
.main-content dd a {
    color: var(--v2-accent-ink);
}

.calc-panel a:hover,
.calc-sidebar a:hover,
.main-content p a:hover,
.main-content li a:hover {
    color: var(--v2-accent);
}

/* 站名：由 --primary 橙改为墨黑，与主页保持同一品牌处理 */
.site-header .logo-text {
    font-size: 20px;
    font-weight: 700;
    letter-spacing: 0;
    color: var(--v2-ink-900);
}

/* 侧栏导航：去彩色底块，当前项用 accent-soft + accent-ink（6.61:1）+ 左信号条 */
.calc-nav-item {
    padding: 10px 12px;
    border-radius: 0;
    font-size: 14px;
    color: var(--v2-ink-700);
    transition: background 0.15s, color 0.15s;
}

.calc-nav-item:hover {
    background: var(--v2-canvas);
    color: var(--v2-ink-900);
}

.calc-nav-item.active {
    background: var(--v2-accent-soft);
    color: var(--v2-accent-ink);
    font-weight: 500;
    box-shadow: inset 2px 0 0 var(--v2-accent);
}

.calc-nav-group-title {
    padding: 12px 12px 6px;
    font-size: 11px;
    line-height: 18px;
    letter-spacing: 0.5px;
    color: var(--v2-ink-500);
}

.btn-primary,
.btn-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 40px;
    padding: 0 24px;
    border-radius: 0;
    font-size: 14px;
    font-weight: 500;
    transition: background 0.15s, border-color 0.15s, color 0.15s;
}

.btn-primary {
    border: 1px solid var(--v2-accent);
    background: var(--v2-accent);
    color: #ffffff;
}

.btn-primary:hover {
    border-color: var(--v2-accent-ink);
    background: var(--v2-accent-ink);
}

.btn-secondary {
    border: 1px solid #cbd2d9;
    background: var(--v2-surface);
    color: var(--v2-ink-700);
}

.btn-secondary:hover {
    border-color: var(--v2-ink-500);
    background: var(--v2-surface);
    color: var(--v2-ink-900);
}

/* 筛选标签：去圆角、去彩色，选中态走 accent-soft + accent-ink（6.61:1） */
.filter-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    min-height: 32px;
    padding: 0 12px;
    border: 1px solid var(--v2-line);
    border-radius: 0;
    background: var(--v2-surface);
    font-size: 13px;
    color: var(--v2-ink-700);
    cursor: pointer;
    transition: border-color 0.15s, background 0.15s, color 0.15s;
}

.filter-chip:hover {
    border-color: var(--v2-ink-500);
}

.filter-chip:has(input:checked) {
    border-color: var(--v2-accent-ink);
    background: var(--v2-accent-soft);
    color: var(--v2-accent-ink);
}

.filter-chip input {
    accent-color: var(--v2-accent-ink);
    margin: 0;
}

/* 规范页筛选栏与结果区 */
.standards-content {
    display: grid;
    grid-template-columns: 240px minmax(0, 1fr);
    gap: 32px;
    align-items: start;
}

.standards-filter-bar {
    display: flex;
    flex-direction: column;
    gap: 20px;
    padding: 20px;
    border: 1px solid var(--v2-line);
    border-radius: 0;
    background: var(--v2-surface);
}

.standards-filter-heading {
    padding-bottom: 14px;
    border-bottom: 1px solid var(--v2-line);
    font-size: 16px;
    line-height: 24px;
    font-weight: 600;
    color: var(--v2-ink-900);
}

.standards-filter-section {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.standards-filter-label {
    flex: 0 0 100%;
    font-size: 12px;
    line-height: 18px;
    color: var(--v2-ink-500);
}

.standards-results-header h2 {
    padding-left: 0;
    font-size: 20px;
    line-height: 28px;
}

.standards-results-header h2::before {
    display: none;
}

/* ------------------------------------------------------------
   5. 规范列表（standard-item / clause）
   ------------------------------------------------------------ */
.standards-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.standard-item,
.standard-card {
    display: block;
    padding: 20px 24px;
    border: 1px solid var(--v2-line);
    border-radius: 0;
    background: var(--v2-surface);
    box-shadow: none;
    transition: border-color 0.15s;
}

.standard-item:hover {
    border-color: var(--v2-ink-500);
    box-shadow: none;
    transform: none;
}

.standard-header {
    display: flex;
    align-items: flex-start;
    gap: 16px;
}

.standard-code {
    flex: none;
    padding: 0;
    border: 0;
    border-radius: 0;
    background: none;
    font-family: var(--font-mono);
    font-size: 13px;
    font-weight: 500;
    color: var(--v2-accent-ink);
    white-space: nowrap;
}

.standard-title {
    flex: 1;
    min-width: 0;
}

.standard-title h3 {
    font-size: 16px;
    line-height: 24px;
    font-weight: 600;
    color: var(--v2-ink-900);
}

.standard-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 6px 16px;
    margin-top: 8px;
}

.standard-meta span {
    font-size: 12px;
    line-height: 18px;
    color: var(--v2-ink-500);
}

/* 条文目录：长页面锚点导航。服务端渲染，同时向爬虫暴露页面结构 */
.standard-detail-page .standard-clause-toc {
    padding: 18px 0;
    border-top: 1px solid var(--v2-line);
}

.standard-detail-page .standard-clause-toc h2 {
    margin: 0 0 12px;
    font-size: 16px;
    line-height: 24px;
    font-weight: 600;
    color: var(--v2-ink-900);
}

.standard-detail-page .standard-clause-toc ol {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 0 24px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.standard-detail-page .standard-clause-toc li { margin: 0; }

.standard-detail-page .standard-clause-toc a {
    display: flex;
    gap: 10px;
    padding: 7px 0;
    border-bottom: 1px solid var(--v2-line);
    font-size: 13px;
    line-height: 20px;
    color: var(--v2-ink-700);
}

.standard-detail-page .standard-clause-toc a:hover { color: var(--v2-accent-ink); }

.standard-detail-page .standard-clause-toc b {
    flex: none;
    min-width: 46px;
    font-family: var(--font-mono);
    font-size: 11px;
    line-height: 20px;
    font-weight: 500;
    color: var(--v2-accent-ink);
}

@media (max-width: 700px) {
    .standard-detail-page .standard-clause-toc ol { grid-template-columns: 1fr; }
}

/* 条文块：等宽条号 + 1px 墨线左边界 */
.clause {
    padding: 12px 0 12px 14px;
    margin-top: 12px;
    border-left: 1px solid var(--v2-line);
}

.clause-num {
    font-family: var(--font-mono);
    font-size: 11px;
    line-height: 18px;
    color: var(--v2-accent-ink);
}

.clause-text {
    margin-top: 6px;
    font-size: 13px;
    line-height: 22px;
    color: var(--v2-ink-700);
}

.clause-text mark,
mark {
    padding: 0 2px;
    background: var(--v2-accent-soft);
    color: var(--v2-accent-ink);
}

/* 规范分类卡（JS 注入 .standard-category-card） */
.standards-category-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 12px;
    margin-bottom: 32px;
}

.standard-category-card {
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 16px 18px;
    border: 1px solid var(--v2-line);
    border-radius: 0;
    background: var(--v2-surface);
    box-shadow: none;
    transition: border-color 0.15s;
}

.standard-category-card:hover {
    border-color: var(--v2-ink-500);
    box-shadow: none;
    transform: none;
}

.standard-category-card.active {
    border-color: var(--v2-accent-ink);
    background: var(--v2-accent-soft);
}

.standard-category-card strong {
    font-size: 15px;
    line-height: 22px;
    font-weight: 600;
    color: var(--v2-ink-900);
}

.standard-category-card.active strong {
    color: var(--v2-accent-ink);
}

.standard-category-card span {
    font-family: var(--font-mono);
    font-size: 11px;
    line-height: 18px;
    color: var(--v2-ink-500);
}

.standard-category-card em {
    display: none;
}

/* ------------------------------------------------------------
   6. 内容卡（方案 / 文章 / 资讯）
   旧版为 3 色 nth-child 上色 + 彩色分类标签 + 3px 顶边
   ------------------------------------------------------------ */
.content-page-hero {
    padding: 0 0 24px;
    border: 0;
    border-bottom: 1px solid var(--v2-line);
    border-radius: 0;
    background: none;
    margin-bottom: 24px;
}

.content-page-hero h1 {
    margin: 0;
    font-size: 40px;
    line-height: 52px;
    font-weight: 700;
    letter-spacing: -0.4px;
    color: var(--v2-ink-900);
}

.content-page-hero .page-subtitle {
    max-width: 860px;
    margin: 12px 0 0;
    font-size: 15px;
    line-height: 26px;
    color: var(--v2-ink-500);
}

.content-secondary-nav {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
    margin: 0 0 32px;
}

.content-secondary-nav a {
    gap: 6px;
    padding: 16px 18px;
    border: 1px solid var(--v2-line);
    border-radius: 0;
    background: var(--v2-surface);
    transition: border-color 0.15s, background 0.15s;
}

.content-secondary-nav a:hover {
    border-color: var(--v2-ink-500);
    background: var(--v2-surface);
    box-shadow: none;
    transform: none;
}

.content-secondary-nav a.active {
    border-color: var(--v2-accent-ink);
    background: var(--v2-accent-soft);
}

.content-secondary-nav strong {
    font-size: 15px;
    line-height: 22px;
    font-weight: 600;
    color: var(--v2-ink-900);
}

.content-secondary-nav a.active strong {
    color: var(--v2-accent-ink);
}

.content-secondary-nav span {
    font-size: 12px;
    line-height: 18px;
    color: var(--v2-ink-500);
}

.article-grid {
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 12px;
    margin-top: 0;
}

/* 清掉 legacy 的三色顶边与顺序上色 */
.article-card,
.article-grid > a:nth-child(1),
.article-grid > a:nth-child(2),
.article-grid > a:nth-child(3) {
    border-top: 1px solid var(--v2-line);
    border-top-color: var(--v2-line);
}

.article-card {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 20px;
    border: 1px solid var(--v2-line);
    border-radius: 0;
    background: var(--v2-surface);
    box-shadow: none;
    transition: border-color 0.15s;
}

.article-card:hover {
    border-color: var(--v2-ink-500);
    box-shadow: none;
    transform: none;
}

/* 分类标签：统一 accent-soft + accent-ink，不再按位置变色 */
.article-card .article-cat,
.article-grid > a:nth-child(1) .article-cat,
.article-grid > a:nth-child(2) .article-cat,
.article-grid > a:nth-child(3) .article-cat {
    align-self: flex-start;
    padding: 4px 10px;
    border-radius: 0;
    background: var(--v2-accent-soft);
    color: var(--v2-accent-ink);
    font-size: 11px;
    line-height: 16px;
    font-weight: 500;
}

.article-card h3 {
    font-size: 16px;
    line-height: 24px;
    font-weight: 600;
    color: var(--v2-ink-900);
}

.article-card p {
    font-size: 13px;
    line-height: 22px;
    color: var(--v2-ink-500);
}

.article-card .article-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 6px 16px;
    margin-top: auto;
    padding-top: 12px;
    border-top: 1px solid var(--v2-line-soft);
    font-family: var(--font-mono);
    font-size: 11px;
    line-height: 18px;
    color: var(--v2-ink-500);
}

.article-card .article-meta span {
    color: var(--v2-ink-500);
}

.content-related {
    margin-top: 32px;
    padding: 20px 22px;
    border: 1px solid var(--v2-line);
    border-radius: 0;
    background: var(--v2-surface);
}

/* ------------------------------------------------------------
   7. 分类卡（首页 legacy 用，兼容保留；内页若出现一并收敛）
   旧版 6 组硬编码色按 nth-child 分配，颜色不表达含义
   ------------------------------------------------------------ */
.category-card,
.category-card:nth-child(1),
.category-card:nth-child(2),
.category-card:nth-child(3),
.category-card:nth-child(4),
.category-card:nth-child(5),
.category-card:nth-child(6) {
    padding: 20px;
    border: 1px solid var(--v2-line);
    border-top: 1px solid var(--v2-line);
    border-radius: 0;
    background: var(--v2-surface);
}

.category-card:hover {
    border-color: var(--v2-ink-500);
    background: var(--v2-surface);
    box-shadow: none;
    transform: none;
}

.category-card .cat-name {
    font-size: 16px;
    line-height: 24px;
    font-weight: 600;
    color: var(--v2-ink-900);
}

.category-card .cat-count {
    font-family: var(--font-mono);
    font-size: 11px;
    line-height: 18px;
    color: var(--v2-ink-500);
}

/* 首页 hero 内的彩色标签条：收敛为单色 */
.hero-tags a,
.hero-tags a:nth-child(1),
.hero-tags a:nth-child(2),
.hero-tags a:nth-child(3),
.hero-tags a:nth-child(4),
.hero-tags a:nth-child(5) {
    padding: 6px 12px;
    border: 1px solid var(--v2-line);
    background: var(--v2-surface);
    color: var(--v2-ink-700);
    font-size: 12px;
}

.hero-tags a:hover,
.hero-tags a:nth-child(1):hover,
.hero-tags a:nth-child(2):hover,
.hero-tags a:nth-child(3):hover,
.hero-tags a:nth-child(4):hover,
.hero-tags a:nth-child(5):hover {
    border-color: var(--v2-accent-ink);
    background: var(--v2-accent-soft);
    color: var(--v2-accent-ink);
}

/* 统计卡 */
.stat-card {
    padding: 24px;
    border: 1px solid var(--v2-line);
    border-radius: 0;
    background: var(--v2-surface);
    box-shadow: none;
}

.stat-card .stat-num {
    font-family: var(--font-mono);
    font-size: 36px;
    line-height: 42px;
    font-weight: 700;
    color: var(--v2-ink-900);
    font-variant-numeric: tabular-nums;
}

.stat-card .stat-label {
    margin-top: 10px;
    font-size: 13px;
    line-height: 20px;
    color: var(--v2-ink-500);
}

/* ------------------------------------------------------------
   8. 计算器详情页：侧栏 + 面板
   ------------------------------------------------------------ */
.calc-layout {
    display: grid;
    grid-template-columns: 240px minmax(0, 1fr);
    gap: 32px;
    align-items: start;
}

.calc-sidebar {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.calc-sidebar-card,
.calc-sidebar .sidebar-card {
    padding: 20px;
    border: 1px solid var(--v2-line);
    border-radius: 0;
    background: var(--v2-surface);
}

.calc-sidebar-search input {
    width: 100%;
    height: 38px;
    padding: 0 14px;
    border: 1px solid var(--v2-line);
    border-radius: 0;
    background: var(--v2-canvas);
    font-size: 13px;
    color: var(--v2-ink-900);
}

.calc-sidebar-search input:focus {
    outline: none;
    border-color: var(--v2-ink-500);
    background: var(--v2-surface);
}

.calc-panel {
    padding: 0;
    border: 0;
    border-radius: 0;
    background: none;
}

.calc-panel-title {
    padding-bottom: 16px;
    margin-bottom: 24px;
    border-bottom: 1px solid var(--v2-line);
    font-size: 20px;
    line-height: 28px;
    font-weight: 600;
    color: var(--v2-ink-900);
}

.calc-panel-desc {
    margin: -12px 0 24px;
    font-size: 13px;
    line-height: 22px;
    color: var(--v2-ink-500);
}

/* 表单控件：零圆角 + 墨线 + 等宽数值 */
.calc-panel input[type="text"],
.calc-panel input[type="number"],
.calc-panel select {
    height: 40px;
    padding: 0 14px;
    border: 1px solid var(--v2-line);
    border-radius: 0;
    background: var(--v2-canvas);
    font-size: 14px;
    color: var(--v2-ink-900);
}

.calc-panel input:focus,
.calc-panel select:focus {
    outline: none;
    border-color: var(--v2-ink-500);
    background: var(--v2-surface);
}

.calc-panel label {
    font-size: 13px;
    line-height: 20px;
    color: var(--v2-ink-700);
}

/* 结果区：深色块，数字等宽大号 */
.calc-result,
.calc-result-box {
    padding: 24px;
    border: 0;
    border-radius: 0;
    background: var(--v2-dark);
}

.calc-result .result-value,
.calc-result-box .result-value,
.calc-result strong {
    font-family: var(--font-mono);
    font-size: 36px;
    line-height: 44px;
    font-weight: 700;
    color: #ffffff;
    font-variant-numeric: tabular-nums;
}

.calc-result .result-label,
.calc-result-box .result-label {
    font-size: 13px;
    line-height: 20px;
    color: var(--v2-dark-muted);
}

/* 结果详情区：深色块上的文字统一用浅色，避免深色文字叠深色背景 */
.calc-result .result-value .result-unit,
.calc-result-box .result-value .result-unit {
    color: var(--v2-dark-muted);
}

.calc-result .result-detail,
.calc-result-box .result-detail {
    margin-top: 14px;
    padding-top: 14px;
    border-top: 1px solid var(--v2-dark-3);
    color: var(--v2-dark-text);
}

.calc-result .result-detail .detail-row,
.calc-result-box .result-detail .detail-row {
    color: var(--v2-dark-text);
}

.calc-result .result-detail .detail-row span:first-child,
.calc-result-box .result-detail .detail-row span:first-child {
    color: var(--v2-dark-muted);
}

.calc-result .calc-result-actions {
    border-top-color: var(--v2-dark-3) !important;
}

.calc-result .calc-result-actions .btn-secondary {
    border-color: var(--v2-dark-3);
    background: var(--v2-dark-2);
    color: var(--v2-dark-text);
}

.calc-result .calc-result-actions .btn-secondary:hover {
    border-color: var(--v2-dark-muted);
    background: var(--v2-dark-3);
    color: #ffffff;
}

/* 结果表（多行输出） */
.calc-result-table th {
    padding: 12px 16px;
    border-bottom: 1px solid var(--v2-line);
    background: #f7f8fa;
    font-family: var(--font-mono);
    font-size: 11px;
    font-weight: 500;
    color: var(--v2-ink-500);
    text-align: left;
}

.calc-result-table td {
    padding: 13px 16px;
    border-bottom: 1px solid var(--v2-line-soft);
    font-family: var(--font-mono);
    font-size: 13px;
    color: var(--v2-ink-900);
}

/* ------------------------------------------------------------
   9. 通用内容页（详情、表格页）
   ------------------------------------------------------------ */
.content-body,
.article-content,
.standard-content {
    font-size: 15px;
    line-height: 26px;
    color: var(--v2-ink-700);
}

.content-body h2,
.article-content h2,
.standard-content h2 {
    margin: 36px 0 14px;
    font-size: 20px;
    line-height: 28px;
    font-weight: 600;
    color: var(--v2-ink-900);
}

.content-body h3,
.article-content h3,
.standard-content h3 {
    margin: 28px 0 10px;
    font-size: 16px;
    line-height: 24px;
    font-weight: 600;
    color: var(--v2-ink-900);
}

.content-body a,
.article-content a,
.standard-content a {
    color: var(--v2-accent-ink);
}

/* 页面内表格统一 v2 语汇 */
.content-body table,
.article-content table,
.standard-content table {
    width: 100%;
    border-collapse: collapse;
    border: 1px solid var(--v2-line);
    background: var(--v2-surface);
}

.content-body th,
.article-content th,
.standard-content th {
    padding: 12px 16px;
    border: 1px solid var(--v2-line);
    background: #f7f8fa;
    font-size: 12px;
    font-weight: 500;
    color: var(--v2-ink-500);
    text-align: left;
}

.content-body td,
.article-content td,
.standard-content td {
    padding: 13px 16px;
    border: 1px solid var(--v2-line-soft);
    font-family: var(--font-mono);
    font-size: 13px;
    color: var(--v2-ink-900);
}

.empty-state {
    padding: 40px 0;
    font-size: 13px;
    line-height: 22px;
    color: var(--v2-ink-500);
    text-align: left;
}

.empty-state .empty-icon {
    display: none;
}

/* ------------------------------------------------------------
   10. 覆盖 style.css 中按位置分配的多色规则
   style.css 3186-3310 用硬编码色 + :nth-child 给卡片上色，
   位置不表达含义（同一分类换个位置就换色），且共 8-18 种色相。
   这里用同等权重的 :nth-child(n) 覆盖，靠加载顺序生效。
   ------------------------------------------------------------ */
.tool-card .card-icon.blue,
.tool-card .card-icon.green,
.tool-card .card-icon.amber,
.tool-card .card-icon.purple,
.tool-card .card-icon.teal,
.tool-card .card-icon.pink,
.tool-card .card-icon.rose,
.tool-card .card-icon.indigo,
.tool-card .card-icon.orange {
    width: 24px;
    height: 24px;
    border-radius: 0;
    background: none;
    box-shadow: none;
    color: var(--v2-ink-700);
}

/* 分类标签：统一为 accent-soft + accent-ink（6.61:1），不再随位置变色 */
.tool-card .card-tag,
.tool-card:nth-child(1) .card-tag,
.tool-card:nth-child(2) .card-tag,
.tool-card:nth-child(3) .card-tag,
.tool-card:nth-child(4) .card-tag,
.tool-card:nth-child(5) .card-tag,
.tool-card:nth-child(6) .card-tag,
.tool-card:nth-child(7) .card-tag,
.tool-card:nth-child(8) .card-tag {
    padding: 2px 8px;
    border-radius: 0;
    background: var(--v2-accent-soft);
    color: var(--v2-accent-ink);
    font-family: var(--font-mono);
    font-size: 11px;
    line-height: 18px;
}

/* 卡片顶边：全部回到 1px 墨线 */
.tool-card:nth-child(1),
.tool-card:nth-child(2),
.tool-card:nth-child(3),
.tool-card:nth-child(4),
.tool-card:nth-child(5),
.tool-card:nth-child(6),
.tool-card:nth-child(7),
.tool-card:nth-child(8) {
    border-top-color: var(--v2-line);
    border-top-width: 1px;
}

/* 首页规范速览注入卡（#homeStandards） */
#homeStandards .tool-card:nth-child(1) .card-icon,
#homeStandards .tool-card:nth-child(2) .card-icon,
#homeStandards .tool-card:nth-child(3) .card-icon,
#homeStandards .tool-card:nth-child(4) .card-icon {
    width: 24px;
    height: 24px;
    border-radius: 0;
    background: none;
    box-shadow: none;
}

#homeStandards .tool-card:nth-child(1) .card-tag,
#homeStandards .tool-card:nth-child(2) .card-tag,
#homeStandards .tool-card:nth-child(3) .card-tag,
#homeStandards .tool-card:nth-child(4) .card-tag {
    padding: 2px 8px;
    border-radius: 0;
    background: var(--v2-accent-soft);
    color: var(--v2-accent-ink);
    font-family: var(--font-mono);
    font-size: 11px;
    line-height: 18px;
}

#homeStandards .tool-card:nth-child(1),
#homeStandards .tool-card:nth-child(2),
#homeStandards .tool-card:nth-child(3),
#homeStandards .tool-card:nth-child(4) {
    border-top-color: var(--v2-line);
    border-top-width: 1px;
}

/* 首页统计卡：去掉四色顶边与渐变底 */
.home-stats .stat-card,
.home-stats .stat-card:nth-child(1),
.home-stats .stat-card:nth-child(2),
.home-stats .stat-card:nth-child(3),
.home-stats .stat-card:nth-child(4) {
    border: 1px solid var(--v2-line);
    border-top: 1px solid var(--v2-line);
    background: var(--v2-surface);
}

.home-stats .stat-card:nth-child(1) .stat-num,
.home-stats .stat-card:nth-child(2) .stat-num,
.home-stats .stat-card:nth-child(3) .stat-num,
.home-stats .stat-card:nth-child(4) .stat-num {
    color: var(--v2-ink-900);
}

/* 首页 hero 旧渐变底（style.css 3086） */
.hero::before {
    background: none;
}

/* ------------------------------------------------------------
   10b. GEO 常见问题区块（FAQPage 结构化数据配套可见内容）
   设计要求：零圆角、零投影、1px 墨线分隔，与站内语汇一致
   ------------------------------------------------------------ */
.geo-faq {
    margin-top: 40px;
    padding-top: 28px;
    border-top: 1px solid var(--v2-line, #dce1e6);
}

.geo-faq > h2 {
    font-size: 20px;
    font-weight: 500;
    line-height: 1.5;
    color: var(--v2-ink-900, #14181c);
    margin: 0 0 20px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--v2-line, #dce1e6);
}

.geo-faq__item {
    padding: 16px 0;
    border-bottom: 1px solid var(--v2-line, #dce1e6);
}

.geo-faq__item:last-of-type {
    border-bottom: none;
}

.geo-faq__q {
    font-size: 15px;
    font-weight: 500;
    line-height: 1.6;
    color: var(--v2-ink-900, #14181c);
    margin: 0 0 8px;
}

.geo-faq__a {
    font-size: 14px;
    line-height: 1.75;
    color: var(--v2-ink-700, #3a444e);
    margin: 0;
}

.geo-faq__note {
    margin-top: 16px;
    font-size: 12px;
    line-height: 1.6;
    color: var(--v2-ink-500, #5c6771);
}

/* ------------------------------------------------------------
   11. 窄屏适配
   ------------------------------------------------------------ */
@media (max-width: 1000px) {
    .standards-content,
    .calc-layout {
        grid-template-columns: minmax(0, 1fr);
        gap: 24px;
    }
}

@media (max-width: 820px) {
    .main-content {
        padding: 24px 18px 56px;
    }

    .section-header h1,
    .content-page-hero h1 {
        font-size: 30px;
        line-height: 40px;
    }

    .section-header h2 {
        font-size: 22px;
        line-height: 30px;
    }

    .section-header {
        margin-bottom: 20px;
    }

    .content-secondary-nav {
        grid-template-columns: minmax(0, 1fr);
        gap: 8px;
    }

    .standards-category-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 8px;
    }

    /* 搜索栏在小屏改为纵向（style.css 768px 已设 flex-direction: column）。
       纵向时 flex-basis 作用于高度，必须改用 width + min-height，
       否则输入框会被压到 18px 高。 */
    .calc-search-bar,
    .standards-search-bar {
        flex-direction: column;
        align-items: stretch;
        gap: 10px;
    }

    .calc-search-bar input,
    .standards-search-bar input {
        flex: none;
        width: 100%;
        max-width: none;
        min-height: 44px;
    }

    /* 移动端触控目标下限 */
    .breadcrumb a,
    .back-to-parent a {
        display: inline-flex;
        align-items: center;
        min-height: 40px;
    }

    .filter-chip {
        min-height: 40px;
        padding: 0 14px;
    }

    .btn-primary,
    .btn-secondary {
        min-height: 44px;
    }

    .calc-sidebar-search input {
        min-height: 44px;
    }

    .calc-panel input[type="text"],
    .calc-panel input[type="number"],
    .calc-panel select {
        height: 44px;
    }

    /* 页脚次级导航：线间收紧但加大可点高度 */
    .v2-footer__col a {
        display: flex;
        align-items: center;
        min-height: 36px;
        margin-bottom: 0;
    }

    .v2-footer__col h3 {
        margin-bottom: 8px;
    }
}

@media (max-width: 560px) {
    .section-header h1,
    .content-page-hero h1 {
        font-size: 26px;
        line-height: 36px;
    }

    .article-grid {
        grid-template-columns: minmax(0, 1fr);
    }

    .card-grid {
        grid-template-columns: minmax(0, 1fr);
    }

    .standard-header {
        flex-direction: column;
        gap: 8px;
    }
}
