/*
 * 综合分析报告的 A4 版式。
 *
 * 尺寸是这一份样式表的核心约束：.rs-page 就是一张 210×297mm 的纸，
 * 屏幕上按 96dpi 折算成 794×1123px 显示，打印时切回 mm。所有内边距、
 * 字号都用 mm/pt 写，避免屏幕上排得下、打印出来溢出到下一页。
 *
 * 打印时隐藏一切交互件（.screen-only），页眉页脚由每一页自己带 ——
 * 不用 @page 的 running header，因为封面不要页眉，混着写更麻烦。
 */

:root {
  --rs-page-w: 210mm;
  --rs-page-h: 297mm;
  --rs-pad: 16mm;
  --rs-ink: #17233d;
  --rs-soft: #808695;
  --rs-line: #dcdee2;
  --rs-brand: #2d8cf0;
  --rs-accent: #ff9900;
}

body {
  margin: 0;
  background: #eef1f6;
  color: var(--rs-ink);
  font-family: -apple-system, BlinkMacSystemFont, 'PingFang SC', 'Microsoft YaHei', sans-serif;
  -webkit-print-color-adjust: exact;
  print-color-adjust: exact;
}

/* ---------------- 屏幕工具条 ---------------- */

.rs-bar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 10px 20px;
  background: #fff;
  border-bottom: 1px solid var(--rs-line);
  box-shadow: 0 1px 6px rgba(0, 0, 0, .05);
}

.rs-bar-left,
.rs-bar-right {
  display: flex;
  align-items: center;
  gap: 12px;
}

.rs-bar-title {
  font-size: 15px;
  font-weight: 600;
}

.rs-bar .plain-action {
  border: 0;
  background: none;
  cursor: pointer;
  color: var(--rs-soft);
  font-size: 13px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.rs-bar .plain-action:hover {
  color: var(--rs-brand);
}

.rs-warn {
  max-width: var(--rs-page-w);
  margin: 16px auto -4px;
  padding: 10px 14px;
  border-radius: 4px;
  background: #fff7e6;
  border: 1px solid #ffd591;
  color: #874d00;
  font-size: 13px;
  display: flex;
  gap: 8px;
  align-items: flex-start;
}

/* ---------------- 纸 ---------------- */

.rs-doc {
  padding: 24px 0 60px;
}

.rs-page {
  position: relative;
  width: var(--rs-page-w);
  min-height: var(--rs-page-h);
  margin: 0 auto 20px;
  padding: var(--rs-pad);
  box-sizing: border-box;
  background: #fff;
  box-shadow: 0 2px 14px rgba(0, 0, 0, .1);
  display: flex;
  flex-direction: column;
  font-size: 10.5pt;
  line-height: 1.75;
}

.rs-page.cover {
  padding: 0;
  overflow: hidden;
}

.rs-main {
  flex: 1;
  min-width: 0;
}

/* 页眉页脚：细线分隔，字压到最小，别抢正文 */
.rs-head,
.rs-foot {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font-size: 8pt;
  color: var(--rs-soft);
}

.rs-head {
  padding-bottom: 4mm;
  margin-bottom: 6mm;
  border-bottom: 1px solid var(--rs-line);
}

.rs-foot {
  padding-top: 4mm;
  margin-top: 6mm;
  border-top: 1px solid var(--rs-line);
}

.rs-foot span:nth-child(2) {
  color: var(--rs-ink);
}

/* ---------------- 封面 ---------------- */

.rs-cover {
  position: relative;
  height: var(--rs-page-h);
  display: flex;
  align-items: center;
}

.cv-art {
  position: absolute;
  inset: 0;
  overflow: hidden;
}

/* 参考版式的那团渐变色块。纯 CSS 拟形，不放位图 */
.cv-blob {
  position: absolute;
  top: -60mm;
  left: -40mm;
  width: 170mm;
  height: 150mm;
  background: linear-gradient(135deg, #5ecfd4, #2d8cf0);
  border-radius: 0 0 62% 46%;
  opacity: .92;
}

.cv-wave {
  position: absolute;
  right: -30mm;
  bottom: -40mm;
  width: 140mm;
  height: 140mm;
  border-radius: 50%;
  background:
    repeating-radial-gradient(circle at 50% 50%,
      rgba(45, 140, 240, .12) 0 1.4mm,
      transparent 1.4mm 3.2mm);
}

.cv-body {
  position: relative;
  padding: 0 20mm;
  width: 100%;
  box-sizing: border-box;
}

.cv-org {
  margin: 0 0 6mm;
  font-size: 12pt;
  color: #0d6ab8;
  letter-spacing: .12em;
}

.cv-body h1 {
  margin: 0 0 8mm;
  font-size: 30pt;
  line-height: 1.35;
  font-weight: 700;
  letter-spacing: .04em;
}

.cv-sub {
  margin: 0 0 14mm;
  font-size: 13pt;
  color: #3a4a5e;
  padding-left: 4mm;
  border-left: 3px solid var(--rs-accent);
}

.cv-meta {
  margin: 0 0 20mm;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 6mm 10mm;
  max-width: 140mm;
}

.cv-meta div {
  border-top: 1px solid var(--rs-line);
  padding-top: 3mm;
}

.cv-meta dt {
  font-size: 9pt;
  color: var(--rs-soft);
  margin-bottom: 1mm;
}

.cv-meta dd {
  margin: 0;
  font-size: 13pt;
  font-weight: 600;
}

.cv-foot {
  margin: 0;
  font-size: 9pt;
  color: var(--rs-soft);
  line-height: 1.9;
}

/* ---------------- 目录 ---------------- */

.rs-toc {
  margin-top: 8mm;
}

.rs-toc a {
  display: flex;
  align-items: baseline;
  gap: 3mm;
  padding: 2.4mm 0;
  color: var(--rs-ink);
  text-decoration: none;
  font-size: 11pt;
}

.rs-toc a:hover .tc-text {
  color: var(--rs-brand);
}

.rs-toc .lv2 {
  padding-left: 10mm;
  font-size: 10pt;
  color: #3a4a5e;
}

.rs-toc .tc-no {
  min-width: 12mm;
  color: var(--rs-brand);
  font-weight: 600;
}

.rs-toc .lv2 .tc-no {
  min-width: 14mm;
  font-weight: 500;
}

.rs-toc .tc-dots {
  flex: 1;
  border-bottom: 1px dotted #c5c8ce;
  transform: translateY(-1mm);
}

.rs-toc .tc-page {
  color: var(--rs-soft);
  font-variant-numeric: tabular-nums;
}

/* ---------------- 标题层级 ---------------- */

/* 一级：居中，上下双线。参考版式是居中带图标，这里用线更克制 */
.rs-h1 {
  margin: 0 0 7mm;
  padding: 3mm 0;
  text-align: center;
  font-size: 16pt;
  font-weight: 700;
  letter-spacing: .06em;
  border-top: 2px solid var(--rs-ink);
  border-bottom: 1px solid var(--rs-line);
}

.rs-h1-no {
  margin-right: 2mm;
}

.rs-h1.no-no {
  letter-spacing: .3em;
}

/* 二级：蓝橙双色竖条，取自参考版式 */
.rs-h2 {
  margin: 8mm 0 4mm;
  padding-left: 4mm;
  font-size: 12.5pt;
  font-weight: 700;
  position: relative;
  line-height: 1.5;
}

.rs-h2::before {
  content: '';
  position: absolute;
  left: 0;
  top: 1mm;
  bottom: 1mm;
  width: 1.4mm;
  background: linear-gradient(var(--rs-brand) 50%, var(--rs-accent) 50%);
  border-radius: 1px;
}

.rs-h2:first-child {
  margin-top: 0;
}

.rs-h2-no {
  margin-right: 2mm;
  color: var(--rs-brand);
}

.rs-h3 {
  margin: 6mm 0 3mm;
  font-size: 11pt;
  font-weight: 600;
}

/* 小节题头：黄色角标，参考版式的三级标题 */
.rs-sub-cap {
  margin: 6mm 0 3mm;
  padding-left: 5mm;
  font-size: 10.5pt;
  font-weight: 600;
  position: relative;
}

.rs-sub-cap::before {
  content: '';
  position: absolute;
  left: 0;
  top: 1.2mm;
  width: 3mm;
  height: 3mm;
  border-left: 1.6mm solid var(--rs-accent);
  border-top: 1.6mm solid var(--rs-accent);
}

/* ---------------- 正文 ---------------- */

.rs-p {
  margin: 0 0 3mm;
  text-indent: 2em;
  text-align: justify;
}

.rs-p b {
  color: #0d6ab8;
  font-weight: 600;
  padding: 0 .15em;
}

/* 结论句。左侧点 + 浅底，扫版面时一眼能挑出来 */
.rs-note {
  margin: 3mm 0;
  padding: 2.6mm 3.5mm 2.6mm 8mm;
  position: relative;
  background: #f6f9fe;
  border-left: 2px solid var(--rs-brand);
  border-radius: 0 2px 2px 0;
  font-size: 10pt;
  line-height: 1.85;
  text-align: justify;
}

.rs-note.rank {
  background: #fffaf2;
  border-left-color: var(--rs-accent);
}

.rs-note.mute {
  background: #f8f8f9;
  border-left-color: #c5c8ce;
  color: var(--rs-soft);
}

.rk-dot {
  position: absolute;
  left: 3.2mm;
  top: 4.6mm;
  width: 1.8mm;
  height: 1.8mm;
  border-radius: 50%;
  background: var(--rs-brand);
}

.rs-note.rank .rk-dot {
  background: var(--rs-accent);
}

.rs-note.mute .rk-dot {
  background: #c5c8ce;
}

.rs-note b {
  color: #0d6ab8;
  padding: 0 .12em;
}

.rs-note em {
  font-style: normal;
  font-weight: 600;
  padding: 0 .12em;
}

.rs-note em.wait {
  color: #d48806;
}

.rs-note em.bad {
  color: #cf1322;
}

.rs-note em.ok {
  color: #0f8a4d;
}

.rk-skip {
  display: block;
  margin-top: 1mm;
  color: var(--rs-soft);
  font-size: 9pt;
}

/* 口径说明。比结论低一档，灰、无底 */
.rs-hint {
  margin: 2.5mm 0 0;
  font-size: 8.8pt;
  color: var(--rs-soft);
  line-height: 1.8;
  text-align: justify;
}

.rs-hint.tight {
  margin-top: 3mm;
}

.rs-rules {
  margin: 4mm 0 0;
  padding-left: 6mm;
  font-size: 9.6pt;
  line-height: 1.9;
}

.rs-rules li {
  margin-bottom: 2mm;
  text-align: justify;
}

.rs-rules b {
  color: #0d6ab8;
}

/* ---------------- 表格 ---------------- */

.rs-table-wrap {
  margin: 4mm 0;
}

.rs-table-cap {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 6mm;
  margin-bottom: 2mm;
  font-size: 10pt;
}

.rs-table-cap span {
  font-size: 8.6pt;
  color: var(--rs-soft);
}

.rs-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 9.2pt;
  table-layout: fixed;
}

.rs-table th,
.rs-table td {
  border: 1px solid #d9dee6;
  padding: 1.8mm 2mm;
  text-align: center;
  word-break: break-all;
}

.rs-table thead th {
  background: #eef3fb;
  color: #1c4e80;
  font-weight: 600;
  font-size: 9pt;
}

.rs-table tbody th {
  background: #fafbfc;
  font-weight: 500;
  text-align: center;
}

.rs-table td.num {
  font-variant-numeric: tabular-nums;
}

.rs-table td.num.rate {
  font-weight: 600;
  color: #0d6ab8;
}

.rs-table td.soft,
.rs-table th.soft {
  color: var(--rs-soft);
  text-align: left;
  font-size: 8.8pt;
}

.rs-table tr.hl td {
  background: #f3f9ff;
  font-weight: 600;
}

.rs-table.plain td:first-child,
.rs-table.plain th:first-child {
  text-align: left;
}

.rs-table.tight th,
.rs-table.tight td {
  padding: .9mm 1.8mm;
  font-size: 8.6pt;
}

.void-row {
  color: var(--rs-soft);
  padding: 6mm 0 !important;
}

/* 判定档表头着色：列头颜色即档位，格子里就不用再重复档名 */
.rs-table thead th.ok {
  background: #eaf8f0;
  color: #0f7a45;
}

.rs-table thead th.done {
  background: #eef3fb;
  color: #1c4e80;
}

.rs-table thead th.wait {
  background: #fff6e6;
  color: #a05c00;
}

.rs-table thead th.bad {
  background: #fdeeee;
  color: #a8121a;
}

.rs-table thead th.mute {
  background: #f5f6f8;
  color: #6b7280;
}

.rs-table thead th.key {
  background: #17233d;
  color: #fff;
}

/* 「人数 / 占比」双值格。数在上、比在下，列窄也放得下 */
.rs-table td.nc {
  line-height: 1.35;
  padding: 1.4mm 1mm;
}

.rs-table td.nc b {
  display: block;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}

.rs-table td.nc i {
  display: block;
  font-style: normal;
  font-size: 7.8pt;
  color: var(--rs-soft);
}

.rs-table td.nc.key {
  background: #fbfcfe;
}

.rs-table td.nc.key b {
  color: #a8121a;
}

.nc-zero {
  font-style: normal;
  color: #c5c8ce;
}

/*
 * 下钻表的紧凑格：占比和人数同一行。一页 A4 的正文只有 843px，
 * 双值格（一格两行）十几行下来要 570px，加上两个表头和结论就装不下了。
 */
.rs-table.rows-tight th,
.rs-table.rows-tight td {
  padding: 1mm 1.5mm;
}

.rs-table td.nc.tiny {
  line-height: 1.4;
  padding: 1mm 1mm;
  white-space: nowrap;
}

.rs-table td.nc.tiny b {
  display: inline;
  font-weight: 600;
}

.rs-table td.nc.tiny i {
  display: inline;
  margin-left: .8mm;
  font-size: 7.2pt;
}

.rs-table-wrap.tight {
  margin: 3mm 0;
}

/* 样本不足的行压暗并挂标签：数据照列，但别让人拿它下结论 */
.rs-table tr.thin td,
.rs-table tr.thin th {
  background: #fffdf6;
}

.row-flag {
  display: inline-block;
  margin-left: 1.5mm;
  padding: 0 1mm;
  font-style: normal;
  font-size: 7.4pt;
  color: #a05c00;
  background: #fff3d9;
  border-radius: 2px;
  vertical-align: 1px;
}

.rs-table tr.void td,
.rs-table tr.void th {
  color: #c5c8ce;
  background: #fcfcfd;
}

.rs-table tr.void td.nc.key b {
  color: #c5c8ce;
}

.it-dot {
  display: inline-block;
  width: 2mm;
  height: 2mm;
  border-radius: 50%;
  margin-right: 2mm;
  vertical-align: 0;
}

/* ---------------- 图形 ---------------- */

.rs-two {
  display: flex;
  align-items: center;
  gap: 8mm;
  margin: 4mm 0;
}

.rs-two-side {
  flex: 1;
  min-width: 0;
}

.rs-two.tight {
  margin: 2mm 0;
  gap: 6mm;
  align-items: center;
}

.rs-donut {
  position: relative;
  width: 42mm;
  height: 42mm;
  flex: none;
}

/* 分项概况页用的小号：那一页环形图下面还有两张表要放 */
.rs-donut.sm {
  width: 26mm;
  height: 26mm;
}

.rs-donut.sm .dn-mid b {
  font-size: 11pt;
}

.rs-donut.sm .dn-mid span {
  font-size: 6.6pt;
}

.rs-donut svg {
  width: 100%;
  height: 100%;
  transform: rotate(-90deg);
}

.rs-donut circle {
  fill: none;
  stroke-width: 14;
}

.dn-bg {
  stroke: #f0f2f5;
}

.dn-seg.ok {
  stroke: #19be6b;
}

.dn-seg.done {
  stroke: #2d8cf0;
}

.dn-seg.wait {
  stroke: #ff9900;
}

.dn-seg.bad {
  stroke: #ed4014;
}

.dn-seg.mute {
  stroke: #c5c8ce;
}

.dn-mid {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.dn-mid b {
  font-size: 15pt;
  line-height: 1.2;
}

.dn-mid span {
  font-size: 8pt;
  color: var(--rs-soft);
}

.rs-legend {
  list-style: none;
  margin: 3mm 0 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 1.5mm 5mm;
  font-size: 9pt;
}

.rs-legend li {
  display: flex;
  align-items: baseline;
  gap: 1.5mm;
}

.rs-legend i {
  width: 2.4mm;
  height: 2.4mm;
  border-radius: 1px;
  flex: none;
  transform: translateY(-.3mm);
}

.rs-legend i.ok {
  background: #19be6b;
}

.rs-legend i.done {
  background: #2d8cf0;
}

.rs-legend i.wait {
  background: #ff9900;
}

.rs-legend i.bad {
  background: #ed4014;
}

.rs-legend i.mute {
  background: #c5c8ce;
}

/*
 * 竖排图例。贴在小环形图右边，吃的是横向空白，所以整块高度由环形图定，
 * 图例本身不再往下顶。名称固定宽度让右边的人次与占比成列对齐。
 */
.rs-legend.col {
  flex-direction: column;
  flex-wrap: nowrap;
  gap: .9mm;
  margin-top: 0;
  font-size: 8.6pt;
}

.rs-legend.col li {
  width: 100%;
  max-width: 62mm;
}

.rs-legend.col .lg-nm {
  width: 17mm;
  flex: none;
}

.rs-legend.col b {
  width: 12mm;
  text-align: right;
}

.rs-legend b {
  font-variant-numeric: tabular-nums;
}

.rs-legend em {
  font-style: normal;
  color: var(--rs-soft);
  font-size: 8.4pt;
}

/* 一项都没出判定时顶替环形图的占位（空环会被读成「全部正常」） */
.rs-comp-empty {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 7mm;
  border-radius: 2px;
  color: var(--rs-soft);
  font-size: 9pt;
  background: #f8f8f9;
}

/* 横向条形图 */
.rs-bars {
  margin: 3mm 0;
}

.rs-bar {
  display: flex;
  align-items: center;
  gap: 3mm;
  padding: 1.2mm 0;
}

.rb-label {
  width: 24mm;
  flex: none;
  font-size: 9pt;
  text-align: right;
  color: #3a4a5e;
}

.rb-track {
  flex: 1;
  height: 5mm;
  background: #f2f4f7;
  border-radius: 1px;
  overflow: hidden;
}

.rb-track i {
  display: block;
  height: 100%;
  border-radius: 1px;
}

.rb-value {
  width: 26mm;
  flex: none;
  font-size: 9pt;
  font-variant-numeric: tabular-nums;
  font-weight: 600;
}

.rb-value em {
  font-style: normal;
  font-weight: 400;
  color: var(--rs-soft);
  margin-left: 1.5mm;
  font-size: 8.4pt;
}

/*
 * 五项需跟进率雷达图。和个人报告那张同形状、反读法，刻度必须看得见。
 *
 * 宽度 68mm 是为了让这一页装得下矩阵和跟进清单（一页 A4 的正文只有 887px，
 * 雷达每宽 1mm 就高 0.9mm）。图缩小之后 SVG 里的字会跟着缩，所以下面几个
 * font-size 是按这个宽度调过的 —— 改宽度记得一起改，不然标签会小到读不出。
 */
.rs-radar {
  width: 68mm;
  flex: none;
}

.rs-rd-grid {
  fill: none;
  stroke: #e3e6eb;
  stroke-width: 1;
}

.rs-rd-grid.out {
  stroke: #c5c8ce;
}

.rs-rd-axis {
  stroke: #dcdee2;
  stroke-width: 1;
}

.rs-rd-axis.off {
  stroke-dasharray: 3 3;
}

.rs-rd-area {
  fill: rgba(255, 153, 0, .16);
  stroke: #ff9900;
  stroke-width: 1.6;
}

.rs-rd-dot {
  stroke: #fff;
  stroke-width: 1.4;
}

/* 样本不足的顶点空心：位置照画，但别让人拿它当结论 */
.rs-rd-dot.thin {
  fill: #fff !important;
  stroke: #ff9900;
}

.rs-rd-scale {
  font-size: 10.5px;
  fill: var(--rs-soft);
  paint-order: stroke;
  stroke: #fff;
  stroke-width: 2.6;
  stroke-linejoin: round;
}

.rs-rd-label {
  font-size: 13px;
  font-weight: 600;
  fill: var(--rs-ink);
}

.rs-rd-val {
  font-size: 12px;
  font-weight: 700;
  fill: #d48806;
}

.rs-rd-val.off {
  font-weight: 400;
  fill: var(--rs-soft);
}

.rs-rd-title {
  font-size: 9.6pt;
  font-weight: 700;
  margin-bottom: 2mm;
}

.rs-rd-say {
  margin: 0 0 2mm;
  font-size: 9pt;
  line-height: 1.7;
}

.rs-rd-say b {
  color: #a05c00;
}

.rs-rd-say.mute {
  color: var(--rs-soft);
  font-size: 8.6pt;
}

.rs-rd-say.mute b {
  color: var(--rs-soft);
}

/* 项目 × 分组 需跟进率矩阵 */
.rs-heat th,
.rs-heat td {
  padding: 1.4mm 1mm;
  text-align: center;
}

.rs-heat tbody th {
  text-align: left;
  white-space: nowrap;
  font-size: 8.6pt;
}

.rs-heat thead th {
  font-size: 8.4pt;
  white-space: nowrap;
}

.rs-heat td.hc {
  font-variant-numeric: tabular-nums;
  line-height: 1.25;
}

.rs-heat td.hc b {
  display: block;
  font-size: 9pt;
}

.rs-heat td.hc i {
  display: block;
  font-style: normal;
  font-size: 7pt;
  color: #6b7280;
}

.rs-heat td.hc.h0 {
  background: #f2faf5;
}

.rs-heat td.hc.h1 {
  background: #fff7e6;
}

.rs-heat td.hc.h2 {
  background: #ffe7ba;
}

.rs-heat td.hc.h3 {
  background: #ffc978;
}

.rs-heat td.hc.h4 {
  background: #ff9d8f;
}

.rs-heat td.hc.h4 b {
  color: #8c1a10;
}

/* 样本不足的格：底色照给（否则色阶断层），但打上斜纹提示别当结论 */
.rs-heat td.hc.thin {
  background-image: repeating-linear-gradient(45deg,
      rgba(255, 255, 255, .75) 0 1.2px, transparent 1.2px 3.4px);
}

.rs-heat td.hc.void {
  background: #f8f8f9;
  color: #c5c8ce;
}

.rs-legend.heat {
  gap: 1.5mm 3.6mm;
  font-size: 8.4pt;
  margin-top: 2mm;
}

.rs-legend.heat li.cap {
  color: var(--rs-soft);
}

.rs-legend.heat i {
  width: 4mm;
  height: 2.6mm;
  border: 1px solid rgba(0, 0, 0, .06);
}

.rs-legend.heat i.h0 {
  background: #f2faf5;
}

.rs-legend.heat i.h1 {
  background: #fff7e6;
}

.rs-legend.heat i.h2 {
  background: #ffe7ba;
}

.rs-legend.heat i.h3 {
  background: #ffc978;
}

.rs-legend.heat i.h4 {
  background: #ff9d8f;
}

.rs-legend.heat i.void {
  background: #f8f8f9;
}

/* 矩阵读出来的「先管谁」清单 */
.rs-tops-cap {
  margin: 2.5mm 0 1mm;
  font-size: 8.8pt;
  font-weight: 700;
  color: #a05c00;
}

.rs-tops-cap span {
  font-weight: 400;
  color: var(--rs-soft);
  margin-left: 2mm;
}

.rs-tops {
  list-style: none;
  margin: 0;
  padding: 0;
  font-size: 9pt;
}

.rs-tops li {
  display: flex;
  align-items: center;
  gap: 3mm;
  padding: 1mm 3mm;
  border-left: 2px solid var(--rs-accent);
  background: #fffaf0;
}

.rs-tops li + li {
  margin-top: 1mm;
}

.tp-no {
  width: 4mm;
  flex: none;
  font-weight: 700;
  color: #a05c00;
}

.tp-who {
  flex: 1;
  min-width: 0;
}

.tp-who .it-dot {
  margin: 0 1.5mm 0 3mm;
}

.tp-rate {
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  color: #d48806;
}

.tp-n {
  width: 22mm;
  flex: none;
  text-align: right;
  color: var(--rs-soft);
  font-size: 8.4pt;
  font-variant-numeric: tabular-nums;
}

/* 比率排名条（校际对比）。虚线是全部学校的合计水平 */
.rs-rates {
  margin: 3mm 0;
}

.rs-rate {
  display: flex;
  align-items: center;
  gap: 3mm;
  padding: 1.2mm 0;
}

.rt-label {
  width: 34mm;
  flex: none;
  font-size: 9pt;
  text-align: right;
  color: #3a4a5e;
}

.rt-track {
  position: relative;
  flex: 1;
  height: 5mm;
  background: #f2f4f7;
  border-radius: 1px;
}

.rt-track > i {
  display: block;
  height: 100%;
  border-radius: 1px;
  background: linear-gradient(90deg, #ffc069, #ff9900);
}

.rt-base {
  position: absolute;
  top: -1mm;
  bottom: -1mm;
  width: 0;
  border-left: 1px dashed #515a6e;
}

.rt-base[data-tip]::after {
  content: attr(data-tip);
  position: absolute;
  left: 1mm;
  top: -3.6mm;
  font-size: 7.6pt;
  color: #515a6e;
  white-space: nowrap;
}

.rs-rate.thin .rt-track > i {
  background: repeating-linear-gradient(45deg, #ffd591 0 2px, #fff3e0 2px 4px);
}

.rt-value {
  width: 24mm;
  flex: none;
  font-size: 9pt;
  font-variant-numeric: tabular-nums;
  line-height: 1.2;
}

.rt-value b {
  font-weight: 700;
}

.rt-value i {
  font-style: normal;
  color: var(--rs-soft);
  font-size: 7.6pt;
  margin-left: 1mm;
}

.rs-rate.thin .rt-value b {
  color: var(--rs-soft);
  font-weight: 400;
}

/*
 * 下钻表「需跟进」列的格内条。垫在背景层上，行高一点没变 ——
 * 分页是按行数排的（ROW_BUDGET），这里长高一点后面所有页码都要挪。
 */
.rs-table td.nc.key.bar {
  position: relative;
  overflow: hidden;
}

.nc-bar {
  position: absolute;
  left: 0;
  bottom: 0;
  height: 1.2mm;
  background: #ffc069;
  border-radius: 0 1px 0 0;
}

.rs-table tr.thin .nc-bar {
  background: #ffe7ba;
}

/* ---------------- 分项页头 ---------------- */

.rs-item-head {
  display: flex;
  align-items: center;
  gap: 4mm;
  padding: 3mm 4mm;
  margin: 4mm 0;
  border-radius: 3px;
  background: #fafbfd;
  border: 1px solid #e8ecf2;
  border-left: 2mm solid var(--it, var(--rs-brand));
}

.rs-item-head > .ivu-icon {
  font-size: 22pt;
  color: var(--it, var(--rs-brand));
  flex: none;
}

.rs-kpi {
  flex: 1;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 3mm;
  min-width: 0;
}

.rs-kpi div {
  text-align: center;
}

.rs-kpi b {
  display: block;
  font-size: 13pt;
  line-height: 1.3;
  font-variant-numeric: tabular-nums;
}

.rs-kpi span {
  font-size: 8.2pt;
  color: var(--rs-soft);
}

.rs-kpi div.wait b {
  color: #d48806;
}

.rs-kpi div.bad b {
  color: #cf1322;
}

/* ---------------- 判定标准 ---------------- */

.std-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3mm 5mm;
  margin: 3mm 0 0;
}

.std-block h5 {
  margin: 0 0 1.5mm;
  font-size: 10pt;
  font-weight: 600;
}

/* 公式卡：参考版式里是居中灰底框，照搬 */
.rs-formula {
  margin: 4mm 0;
  display: flex;
  flex-direction: column;
  gap: 3mm;
}

.fm {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 3mm;
  padding: 3mm 4mm;
  background: #f7f8fa;
  border: 1px solid #eaedf1;
  border-radius: 3px;
  font-size: 9.6pt;
}

.fm-name {
  font-weight: 600;
}

.fm-name::after {
  content: ' =';
  color: var(--rs-soft);
}

.fm-frac {
  display: inline-flex;
  flex-direction: column;
  text-align: center;
}

.fm-frac i {
  font-style: normal;
  padding: 0 2mm 1mm;
  border-bottom: 1px solid var(--rs-ink);
}

.fm-frac b {
  font-weight: 400;
  padding-top: 1mm;
}

.fm-x {
  color: var(--rs-soft);
}

/* ---------------- 排版兜底提示（只在屏幕上） ---------------- */

.rs-page.rs-overflow {
  outline: 2px solid #ed4014;
  outline-offset: -1px;
}

.rs-of-flag {
  position: absolute;
  right: 0;
  bottom: 0;
  padding: 2px 8px;
  background: #ed4014;
  color: #fff;
  font-size: 11px;
  border-radius: 2px 0 0 0;
}

/* ---------------- 空态 ---------------- */

.rs-empty {
  padding: 40mm 10mm;
  text-align: center;
  color: var(--rs-soft);
}

.rs-empty .ivu-icon {
  font-size: 40pt;
  color: #c5c8ce;
}

.rs-empty h3 {
  margin: 4mm 0 2mm;
  font-size: 14pt;
  color: var(--rs-ink);
}

.rs-empty p {
  margin: 0;
  font-size: 10pt;
}

/* ---------------- 打印 ---------------- */

@media print {
  @page {
    size: A4;
    margin: 0;
  }

  body {
    background: #fff;
  }

  .screen-only,
  .rs-bar,
  .toast {
    display: none !important;
  }

  .rs-doc {
    padding: 0;
  }

  .rs-page {
    margin: 0;
    box-shadow: none;
    /* 每一页都是独立纸张。break-after 比旧的 page-break-after 更准 */
    break-after: page;
    page-break-after: always;
    /*
     * 颜色照原样印。浏览器默认为省墨会丢掉背景色，但这份报告里的颜色是
     * **有含义的**：红色代表建议转诊、橙色代表建议复检，图表的分档色条更是
     * 全靠颜色区分。丢了颜色，雷达图和标尺就只剩一片灰。
     */
    print-color-adjust: exact;
    -webkit-print-color-adjust: exact;
  }

  .rs-page:last-child {
    break-after: auto;
    page-break-after: auto;
  }

  /* 表格跨页时表头要跟着走，否则后半张表看不出列是什么 */
  .rs-table thead {
    display: table-header-group;
  }

  .rs-table tr,
  .rs-note,
  .rs-item-head,
  .std-block {
    break-inside: avoid;
    page-break-inside: avoid;
  }
}

/* 窄屏（在手机上打开链接看）时让纸自适应，不横向滚 */
@media screen and (max-width: 840px) {
  .rs-page {
    width: 100%;
    min-height: 0;
    padding: 16px;
    border-radius: 0;
  }

  .rs-cover {
    height: auto;
    padding: 40px 0;
  }

  .cv-body {
    padding: 0 16px;
  }

  .cv-meta,
  .std-grid,
  .rs-kpi {
    grid-template-columns: 1fr 1fr;
  }

  .rs-two {
    flex-direction: column;
    align-items: stretch;
  }

  .rs-donut {
    align-self: center;
  }
}
