/* jcpt-typography-polish-20260704.css — 整站排版深度美化
 * 原则：只动视觉不动布局功能；统一字阶/间距/圆角/组件风格；给嵌套卡"降噪"。
 * 作用域尽量落在既有 class 上，低特异性可被后续源码样式覆盖。 */

:root{
  --jtp-ink:#12312c;          /* 主文字 */
  --jtp-ink-2:#40605a;        /* 次文字 */
  --jtp-ink-3:#71908a;        /* 辅助文字 */
  --jtp-brand:#0f5f54;
  --jtp-line:#dbe7e4;
  --jtp-radius:12px;
  --jtp-radius-s:9px;
}

/* ===== 1. 全站文字基调：行高与渲染 ===== */
.portal-unified-page, .jcpt-route-fallback, .portal-footer{
  -webkit-font-smoothing:antialiased;
  text-rendering:optimizeLegibility;
}
.portal-unified-page p, .portal-unified-page li{line-height:1.7}

/* ===== 2. 页头轻量化：导航胶囊瘦身、标题字距 ===== */
.portal-brand-stage h1, .portal-brand-stage .portal-brand-title{letter-spacing:.5px}
.portal-nav a, .portal-nav button, .portal-nav .portal-nav-item{
  padding:8px 15px !important;
  border-radius:10px !important;
  font-size:14px !important;
  border-width:1px !important;
  transition:background .15s,transform .12s;
}
.portal-nav a:hover, .portal-nav button:hover{transform:translateY(-1px)}

/* ===== 3. 嵌套卡降噪：中间层大壳扁平化(去"套娃") ===== */
.market-search-hero-strong > .market-search-panel-strong{
  box-shadow:none !important;
}
.policy-news-shell, .forum-shell{
  background:transparent !important;
  border:none !important;
  box-shadow:none !important;
  padding-left:0 !important;
  padding-right:0 !important;
}
/* 资源页主板卡(ecosystem-card 作页面唯一容器时)扁平化：外已有 glass-panel 大卡，中间层不再套框 */
.market-search-panel-strong > .ecosystem-card,
.policy-news-shell > .ecosystem-card,
.forum-shell > .ecosystem-card{
  background:transparent !important;
  border:none !important;
  box-shadow:none !important;
  padding-left:2px !important;
  padding-right:2px !important;
}
/* 大壳与页面边缘的双重圆角留白收敛 */
.page-wrap.portal-unified-page > .market-shell.glass-panel{
  padding-top:22px;
  padding-bottom:26px;
}
/* 页面标题区：主色锚点条，建立层级 */
.resource-center-head strong,
.resource-center-head h1, .resource-center-head h2{
  position:relative;
  padding-left:14px;
}
.resource-center-head strong::before,
.resource-center-head h1::before, .resource-center-head h2::before{
  content:"";
  position:absolute;left:0;top:50%;transform:translateY(-50%);
  width:5px;height:1.05em;border-radius:4px;
  background:linear-gradient(180deg,#0f5f54,#2b9d8a);
}
/* 列表项：分隔与悬停呼吸 */
.policy-news-item, .training-item, .procurement-item{
  border:1px solid #e2ecea !important;
  border-radius:12px !important;
  transition:border-color .15s, box-shadow .15s;
  margin-bottom:12px;
}
.policy-news-item:hover, .training-item:hover, .procurement-item:hover{
  border-color:#bcd8d2 !important;
  box-shadow:0 6px 20px rgba(15,80,70,.08);
}
/* 新闻封面占位块：降饱和缩字，减少"色块怼脸" */
.policy-news-item [class*="cover"]{
  opacity:.92;
  border-radius:10px !important;
}
.policy-news-item [class*="cover"] *{
  font-size:20px !important;
  letter-spacing:6px;
  opacity:.85;
}

/* ===== 4. 字阶层级：页面标题/卡片标题/正文/辅助 ===== */
.portal-unified-page h1{font-size:26px;font-weight:800;letter-spacing:.3px;color:var(--jtp-ink)}
.portal-unified-page h2{font-size:21px;font-weight:700;color:var(--jtp-ink)}
.portal-unified-page h3{font-size:16.5px;font-weight:700;color:var(--jtp-ink)}
.portal-unified-page h1 + p, .portal-unified-page h2 + p{color:var(--jtp-ink-2)}
/* 页面主标题与下方留白节奏 */
.portal-unified-page h1{margin-bottom:6px}

/* ===== 5. 按钮统一：圆角/内距/字重三态 ===== */
.portal-unified-page button:not(.jdo-bt):not(.jdo-dtab):not(.jdo-chip):not([class*="jdo-"]),
.jcpt-route-fallback button{
  border-radius:var(--jtp-radius-s);
  font-weight:600;
}
.portal-unified-page .pill-button{border-radius:11px}
/* 主行动按钮悬停一致反馈 */
.portal-unified-page .cta-button:hover,
.portal-unified-page button[class*="primary"]:hover{filter:brightness(1.06)}

/* ===== 6. 标签/徽章统一：高度/圆角/字号 ===== */
.merchant-meta-row span, .merchant-meta-row-shop span,
.portal-unified-page [class*="tag"]:not(input):not(textarea),
.portal-unified-page [class*="chip"]:not(input),
.market-category-chip{
  border-radius:7px;
  font-size:12.5px;
  line-height:1.5;
}
.jcpt-qual-badge{font-weight:600}

/* ===== 7. 实验室卡片可读性：名称/说明/标签节奏 ===== */
article.merchant-card .merchant-card-head h3{font-size:16.5px;line-height:1.45}
article.merchant-card p{
  color:var(--jtp-ink-2);
  line-height:1.7;
  margin:6px 0;
}
article.merchant-card{transition:box-shadow .15s,transform .12s}
article.merchant-card:hover{box-shadow:0 8px 26px rgba(15,80,70,.10)}

/* ===== 8. 政策新闻卡：占位图优化 + 摘要行距 ===== */
.portal-unified-page [class*="policy"] img,
.portal-unified-page [class*="news-cover"]{border-radius:10px}
/* 呆板的大字占位块 → 柔化 */
.portal-unified-page [class*="cover"] , .portal-unified-page [class*="thumb"]{
  border-radius:10px;
  overflow:hidden;
}

/* ===== 9. 表单控件统一 ===== */
.portal-unified-page input[type="text"], .portal-unified-page input:not([type]),
.portal-unified-page textarea, .portal-unified-page select,
.jcpt-route-fallback input{
  border-radius:var(--jtp-radius-s);
  font-size:14.5px;
}
.portal-unified-page input:focus, .portal-unified-page textarea:focus, .portal-unified-page select:focus{
  outline:none;
  border-color:var(--jtp-brand) !important;
  box-shadow:0 0 0 3px rgba(15,95,84,.13) !important;
}

/* ===== 10. 论坛统计卡：数字层级化(真实类 forum-metric-card) ===== */
.forum-metric-card{
  border-radius:12px !important;
  transition:box-shadow .15s;
}
.forum-metric-card:hover{box-shadow:0 6px 18px rgba(15,80,70,.08)}
.forum-metric-card strong, .forum-metric-card b,
.forum-metric-card [class*="value"], .forum-metric-card [class*="num"]{
  font-size:28px !important;font-weight:800 !important;color:var(--jtp-brand) !important;line-height:1.2;
}
/* 卡内数字兜底：最后一个纯数字文本节点难选，直接放大卡内非标题文本 */
.forum-metric-card{font-size:15px}
.forum-metric-card > *:last-child{font-size:26px;font-weight:800;color:var(--jtp-brand)}

/* ===== 10b. 详情页信任闭环步骤条：步骤感强化 ===== */
.trust-timeline{position:relative}
.trust-step-card{
  border:1px solid #e2ecea !important;
  border-radius:11px !important;
  transition:border-color .15s;
  position:relative;
}
.trust-step-card:hover{border-color:#bcd8d2 !important}
.trust-step-card [class*="index"], .trust-step-card [class*="step-no"]{
  color:var(--jtp-brand);font-weight:800;
}

/* ===== 11. 滚动条精致化(WebKit) ===== */
.portal-unified-page ::-webkit-scrollbar, .jdo-drawer::-webkit-scrollbar, .jdo-btbl-wrap::-webkit-scrollbar{width:8px;height:8px}
.portal-unified-page ::-webkit-scrollbar-thumb, .jdo-drawer::-webkit-scrollbar-thumb, .jdo-btbl-wrap::-webkit-scrollbar-thumb{
  background:#b9cfc9;border-radius:8px;
}
.portal-unified-page ::-webkit-scrollbar-thumb:hover{background:#93b3ac}
.portal-unified-page ::-webkit-scrollbar-track{background:transparent}

/* ===== 12. 页脚呼吸感 ===== */
.portal-footer{padding-top:18px;padding-bottom:calc(14px + env(safe-area-inset-bottom,0px))}
.portal-footer, .portal-footer a{font-size:12.5px;color:#6d8781}
.portal-footer a:hover{color:var(--jtp-brand)}

/* ===== 13. /labs fallback 页排版对齐主站 ===== */
.jcpt-route-fallback__hero{margin-bottom:16px}
.jcpt-route-fallback__chip{border-radius:9px;font-size:13px}
.jcpt-route-fallback__panel{border-radius:var(--jtp-radius)}

/* ===== 14. 焦点可达性：键盘 focus 环全站统一 ===== */
.portal-unified-page a:focus-visible,
.portal-unified-page button:focus-visible{
  outline:2px solid var(--jtp-brand);
  outline-offset:2px;
  border-radius:6px;
}

/* ===== 14b. 云审补充项(R1 采纳) ===== */
/* 字阶微调：h2/h3 拉开层级 */
.portal-unified-page h2{font-size:20px}
.portal-unified-page h3{font-size:17px;font-weight:600}
/* 标准号 chips 超长截断 */
.jdo-chip{max-width:190px;overflow:hidden;text-overflow:ellipsis;vertical-align:bottom}
/* 通用表格样式(详情页能力表等) */
.portal-unified-page table{border-collapse:collapse}
.portal-unified-page th{background:#f3f7f6;font-weight:600;color:var(--jtp-ink)}
.portal-unified-page th, .portal-unified-page td{
  border:none;border-bottom:1px solid #e8f0ee;padding:10px 12px;text-align:left;
}
.portal-unified-page tbody tr:hover td{background:#f7fbfa}
/* 新闻封面：固定比例防图文高度错位 */
.policy-news-item [class*="cover"]{aspect-ratio:16/10;object-fit:cover}
/* 新闻标题两行截断 */
.policy-news-item h3, .policy-news-item [class*="title"]{
  display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;
}
/* 移动端触摸反馈(hover 无效设备) */
@media (hover:none){
  article.merchant-card:active, .policy-news-item:active, .training-item:active, .procurement-item:active{
    background:#f4f9f8 !important;
  }
}
/* 文本选中品牌色 */
.portal-unified-page ::selection{background:rgba(15,95,84,.18);color:#0c3f38}
/* 页脚层级：链接与版权区分 */
.portal-footer a{color:#5d7d77;font-weight:500}
.portal-footer .portal-beian-main{color:#8aa39d}
/* 圆角阶梯：外壳 16 视觉更稳 */
.page-wrap.portal-unified-page > .market-shell.glass-panel{border-radius:16px}
/* 移动端导航：强制换行显示全部栏目(含"环保治理供应"最后一栏),不横向滚动藏栏 */
@media (max-width:760px){
  .portal-header .portal-nav{
    flex-wrap:wrap !important;
    overflow-x:visible !important;
    row-gap:6px;
  }
}

/* ===== 14c. 本地VL模型看图审意见(R1) ===== */
/* 1) 筛选类型 chips 间距拥挤 → 拉开呼吸 */
.procurement-kind-row{gap:10px !important;margin:10px 0 !important}
.procurement-kind-chip{padding:6px 14px !important}
/* 2) 类型标签(通知/解读/政策)语义色统一：同一形制,色相区分 */
.policy-news-item [class*="kind"], .policy-news-item [class*="type-tag"],
.policy-news-item > div:first-child > span:first-child{
  border-radius:7px;font-size:12.5px;font-weight:600;
}
/* 3) 来源/适用对象 pill 长短不齐 → 顶对齐+允许换行 */
.policy-news-item [class*="meta"], .policy-news-item [class*="source-row"]{
  display:flex;flex-wrap:wrap;gap:8px;align-items:flex-start;
}
.policy-news-item [class*="meta"] span{white-space:normal;line-height:1.55}

/* ===== 14d. VL 终审弱意见吸收 ===== */
/* 时间戳胶囊：字号收敛,不与标题争视觉 */
.policy-news-item [class*="date"], .policy-news-item time{font-size:12.5px;color:#71908a}
/* 过滤区与列表之间留白节奏 */
.policy-news-filter-row{margin-bottom:12px}
.policy-news-toolbar{margin-bottom:10px}

/* ===== 14e. 全面审终轮(VL-32B 云端看图)微调 ===== */
/* 账号入口区说明文字与输入框标签对齐 */
.portal-account-panel-header p, [class*="account"] [class*="hint"]{text-align:left}
/* 搜索框与"加急优先"按钮间距,防误触 */
.market-search-hero-strong [class*="urgent"], .market-search-panel-strong [class*="urgent"]{margin-left:12px}
/* 热门搜索长标签截断防溢出 */
[class*="hot"] a, [class*="hotword"] button, .market-hotword-row > *{
  max-width:260px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;
}

/* ===== 16. 详情页证书有效期状态徽章(MiMo审) ===== */
.jdo-cert-badge{
  display:flex;align-items:flex-start;gap:10px;
  border:1px solid #d5e5e2;border-radius:12px;padding:12px 16px;margin:12px 0;
  font-size:14px;line-height:1.6;color:#23514b;background:#f6fbfa;
}
.jdo-cert-badge b{color:#0f3f39}
.jdo-cert-dot{flex:0 0 auto;width:10px;height:10px;border-radius:50%;margin-top:6px}
.jdo-cert-state{font-weight:700}
.jdo-cert-org{color:#5f7f7a}
.jdo-cert-ok{background:#f0f9f4;border-color:#bfe5cd}
.jdo-cert-ok .jdo-cert-dot{background:#1a8f4c;box-shadow:0 0 0 3px rgba(26,143,76,.18)}
.jdo-cert-ok .jdo-cert-state{color:#156a3f}
.jdo-cert-soon{background:#fdf7ec;border-color:#eeddb5}
.jdo-cert-soon .jdo-cert-dot{background:#c88a12;box-shadow:0 0 0 3px rgba(200,138,18,.18)}
.jdo-cert-soon .jdo-cert-state{color:#8a5510}
.jdo-cert-exp{background:#fceceb;border-color:#efc5c0}
.jdo-cert-exp .jdo-cert-dot{background:#c0392b;box-shadow:0 0 0 3px rgba(192,57,43,.18)}
.jdo-cert-exp .jdo-cert-state{color:#a5281c}

/* ===== 17. 移动端触控/防缩放/防横向溢出加固(MiMo审) ===== */
@media (max-width:760px){
  /* iOS Safari 输入框字号<16px会触发自动放大 → 统一≥16px */
  .portal-unified-page input, .portal-unified-page textarea, .portal-unified-page select,
  .jdo-drawer-inp, .jdo-bta, .market-search-input-strong{font-size:16px !important}
  /* 触控热区≥44px */
  .portal-nav a, .portal-nav button, .market-category-chip,
  .procurement-kind-chip, .jdo-bt, .jdo-dtab{min-height:40px}
  /* 防整页横向溢出 */
  html, body{overflow-x:hidden;max-width:100%}
  .portal-unified-page, .jcpt-route-fallback{overflow-x:hidden}
  /* 长内容/表格自适应,不撑破 */
  .portal-unified-page table, .jdo-btbl-wrap{display:block;overflow-x:auto;-webkit-overflow-scrolling:touch}
  .portal-unified-page td, .portal-unified-page th{white-space:normal;word-break:break-word}
  .jdo-cert-badge{font-size:13px;padding:10px 12px}
}

/* ===== 18. 证书来源验证条 + 搜索历史(MiMo审 第1波) ===== */
.jdo-cert-src{font-size:12.5px;color:#5f7f7a;margin:2px 0 10px;line-height:1.6}
.jdo-cert-src a{color:#0f5f54;text-decoration:none;font-weight:600}
.jdo-cert-src a:hover{text-decoration:underline}
.jdo-cert-sync{color:#8aa39d}
.jdo-hist{background:#fff;border:1px solid #c9dbd8;border-radius:10px;box-shadow:0 10px 28px rgba(15,60,54,.14);overflow:hidden;max-height:320px;overflow-y:auto}
.jdo-hist-head{display:flex;justify-content:space-between;align-items:center;padding:8px 14px;font-size:12px;color:#7d948f;border-bottom:1px solid #eef4f3}
.jdo-hist-clear{border:none;background:none;color:#0f5f54;font-size:12px;cursor:pointer}
.jdo-hist-item{display:flex;align-items:center;gap:8px;padding:9px 14px;cursor:pointer;font-size:14px;color:#23514b}
.jdo-hist-item:hover{background:#eef6f4}
.jdo-hist-ic{opacity:.6;font-size:12px}

/* ===== 19. 打印样式 + 长文本省略(MiMo审) ===== */
@media print{
  .portal-header, .portal-footer, .portal-nav, .jcpt-one-lib-entry-rail,
  .jdo-drawer-mask, .market-search-hero, .jdo-ac, .jdo-hist,
  button, .pill-button, [class*="cta"]{display:none !important}
  .glass-panel, .detail-card, .content-section{box-shadow:none !important;border:1px solid #ccc !important}
  body{background:#fff !important}
  .jdo-cert-badge{border:1px solid #999 !important}
  a[href]::after{content:"" !important}
}

/* ===== 20. 性能/状态/过渡(MiMo审 第2波) ===== */
/* 大列表容器隔离,减少重排重绘范围 */
.market-layout, .policy-news-list, .jdo-fullres-list, .jdo-btbl-wrap{contain:layout style paint}
/* 服务状态色点 */
article.merchant-card [class*="status-pill"]::before, .merchant-card-state-group .status-pill::before{
  content:"";display:inline-block;width:7px;height:7px;border-radius:50%;margin-right:5px;vertical-align:middle;background:#9aa7a3
}
article.merchant-card .status-pill[class*="active"]::before, article.merchant-card .status-pill[class*="ACTIVE"]::before{background:#1a8f4c}
/* 卡片/结果轻入场过渡(仅非减动效用户) */
@media (prefers-reduced-motion:no-preference){
  article.merchant-card, .jdo-fr-card, .policy-news-item{animation:jdoFadeUp .28s ease both}
}
@keyframes jdoFadeUp{from{opacity:0;transform:translateY(6px)}to{opacity:1;transform:none}}
/* 数字等宽,千分位对齐更整齐 */
.jdo-snap b, .forum-metric-card strong, .jdo-cert-badge b{font-variant-numeric:tabular-nums}

/* ===== 21. 页脚合规免责声明(MiMo审 第3波) ===== */
.jdo-disclaimer{
  font-size:12px;line-height:1.7;color:#8aa39d;
  border-top:1px solid rgba(255,255,255,.08);padding:12px 4px 4px;margin-bottom:8px;
  max-width:1000px;margin-left:auto;margin-right:auto;
}

/* ===== 15. 移动端排版节奏 ===== */
@media (max-width:760px){
  .portal-unified-page h1{font-size:22px}
  .portal-unified-page h2{font-size:18.5px}
  .page-wrap.portal-unified-page > .market-shell.glass-panel{padding-left:14px;padding-right:14px}
  article.merchant-card p{font-size:13.5px}
  .portal-nav a, .portal-nav button{padding:7px 12px !important;font-size:13.5px !important}
}
