/**
 * 云枢求职 · 官网「AI 简历」页样式
 *
 * 2026-10-10：按用户要求把这一页做成**功能页**（对齐客户端那版设计）——
 * 标题行（AI 简历 + 简历模板 / 我的简历 / 导入简历）+ 左模板栏 + 中间画布 + 底部输入条；
 * 页面上不放介绍段、卖点卡、风险清单这类营销文字。
 * 简历纸面（.rd-* 一套）在 /resume-paper.css。
 */

[hidden] { display: none !important; }

/* ---------- 整页：占满视口，只有模板栏 / 我的简历栏内部滚动 ---------- */
body.ar-page { background: var(--bg); }
body.ar-page .page-scroll {
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
.ar-wrap { display: flex; flex-direction: column; min-height: 0; flex: 1 1 auto; }

/* ---------- 标题行 ---------- */
.ar-head {
  flex: 0 0 auto;
  /* 2026-10-11 用户要求：岗位选择放工具条正中间 —— grid 三列：中列放岗位 chip，右列放导入简历 */
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 12px;
  /* 固定 40px（全局 box-sizing:border-box，含下面那条 1px 分割线），与下方纸面区分开 */
  height: 40px;
  padding: 0 18px;
  border-bottom: 1px solid var(--line);
}
/* 岗位搜索（2026-10-11 用户重做）：搜索框 + 搜索按钮 + 结果下拉（按行业/类型分组） */
.ar-jobsearch {
  grid-column: 2;
  justify-self: center;
  position: relative;
  display: flex;
  align-items: center;
  gap: 6px;
}
.ar-jobq {
  width: 230px;
  padding: 5px 12px;
  border-radius: var(--r-pill);
  border: 1px solid var(--line-2);
  background: var(--surface-2);
  color: var(--text);
  font: inherit;
  font-size: 13px;
}
.ar-jobq::placeholder { color: var(--muted); }
.ar-jobq:focus { outline: none; border-color: var(--accent-line); }
.ar-jobdrop {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  width: 460px;
  max-height: 420px;
  overflow-y: auto;
  z-index: 30;
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 8px;
  background: var(--surface);
  border: 1px solid var(--line-2);
  border-radius: 12px;
  box-shadow: var(--shadow-2);
}
.ar-jobdrop[hidden] { display: none; }
.ar-jobdrop-group { padding: 6px 8px 2px; font-size: 12px; color: var(--muted); }
.ar-jobdrop-item {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 7px 9px;
  border-radius: 8px;
  border: 1px solid transparent;
  background: transparent;
  color: var(--text-2);
  font: inherit;
  text-align: left;
  cursor: pointer;
}
.ar-jobdrop-item:hover { border-color: var(--accent-line); background: var(--accent-soft); color: var(--text); }
.ar-jobdrop-item b { color: var(--text); font-size: 13px; font-weight: 600; }
.ar-jobdrop-item span { font-size: 12px; color: var(--muted); }
.ar-jobdrop-note { padding: 6px 8px; font-size: 12.5px; color: var(--muted); }
.ar-jobdrop-more {
  margin-top: 6px;
  padding: 7px 9px;
  border-radius: 8px;
  border: 1px dashed var(--line-2);
  background: transparent;
  color: var(--text-2);
  font: inherit;
  font-size: 12.5px;
  text-align: left;
  cursor: pointer;
}
.ar-jobdrop-more:hover { border-color: var(--accent-line); color: var(--text); }
.ar-head-actions { grid-column: 3; justify-self: end; display: flex; gap: 8px; flex-wrap: wrap; }
.ar-chipbtn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 13px;
  border-radius: var(--r-pill);
  border: 1px solid var(--line-2);
  background: var(--surface);
  color: var(--text-2);
  font: inherit;
  font-size: 13px;
  line-height: 1.3;
  cursor: pointer;
  white-space: nowrap;
}
.ar-chipbtn:hover { border-color: var(--accent-line); color: var(--text); }
.ar-chipbtn.on { border-color: var(--accent-line); background: var(--accent-soft); color: var(--accent-text); }
.ar-ico { font-size: 12px; opacity: .85; }

/* ---------- 三栏 ---------- */
.ar-work {
  flex: 1 1 auto;
  min-height: 0;
  display: grid;
  grid-template-columns: 300px minmax(0, 1fr);
  /* 2026-10-11 用户：「底部就是一个整体，不要划分开」——原来这条 1px 顶部分割线会从
     标题行三颗按钮的左右两侧露出来，把那一行切成两段；删掉它，标题行与三栏连成一块。 */
  margin-right: 76px;
}
.ar-work.with-rail-off { grid-template-columns: minmax(0, 1fr); }
.ar-work.with-mine { grid-template-columns: 300px minmax(0, 1fr) 300px; }
.ar-work.with-rail-off.with-mine { grid-template-columns: minmax(0, 1fr) 300px; }

/* 左模板栏 / 右我的简历：同一套骨架 */
.ar-rail,
.ar-mine {
  display: flex;
  flex-direction: column;
  min-height: 0;
  background: color-mix(in srgb, var(--surface) 72%, var(--bg));
  border-right: 1px solid var(--line);
}
.ar-mine { border-right: 0; border-left: 1px solid var(--line); }
.ar-rail-head {
  flex: 0 0 auto;
  display: flex;
  /* 2026-10-11 用户要求：这一条上下各留 20px，内容在中线竖向居中 */
  align-items: center;
  gap: 7px;
  padding: 20px 12px;
  font-size: 14px;
  color: var(--text);
}
.ar-rail-head .ar-note { font-size: 12px; }
.ar-iconbtn {
  margin-left: auto;
  width: 26px;
  height: 26px;
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--r-sm);
  border: 1px solid var(--line);
  background: var(--surface-2);
  color: var(--text-2);
  font: inherit;
  font-size: 12px;
  cursor: pointer;
}
.ar-iconbtn:hover { border-color: var(--line-2); color: var(--text); }
/* 一排图标按钮只在第一个前留 auto 间距，后面的紧挨（2026-10-11 栏头加了第二个图标按钮） */
.ar-rail-head .ar-iconbtn + .ar-iconbtn { margin-left: 0; }
.ar-rail-body {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  padding: 0 12px 12px;
  display: flex;
  flex-direction: column;
  gap: 9px;
}
.ar-note { margin: 0; font-size: 12px; color: var(--muted); line-height: 1.55; }

/* 搜索框 / 范围 chips */
.ar-search {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: var(--r-input);
  background: var(--surface-2);
  color: var(--text);
  padding: 8px 10px;
  font: inherit;
  font-size: 13px;
}
.ar-search::placeholder { color: var(--muted); }
.ar-search:focus { outline: none; border-color: var(--accent-line); }
.ar-scope { display: flex; flex-wrap: wrap; gap: 4px; }
.ar-scope button {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  border: 1px solid var(--line);
  background: var(--surface-2);
  color: var(--text-2);
  border-radius: var(--r-pill);
  padding: 3px 7px;
  font: inherit;
  font-size: 12px;
  cursor: pointer;
}
.ar-scope button i { font-style: normal; color: var(--muted); font-variant-numeric: tabular-nums; }
.ar-scope button:hover { border-color: var(--line-2); color: var(--text); }
.ar-scope button.on { border-color: var(--accent-line); background: var(--accent-soft); color: var(--accent-text); }
.ar-scope button.on i { color: var(--accent-text); }

/* 模板分组 + 两列缩略图 */
.ar-group-head {
  display: flex;
  align-items: center;
  gap: 6px;
  margin: 6px 0 2px;
  font-size: 12.5px;
  color: var(--text-2);
  cursor: pointer;
  user-select: none;
}
.ar-group-head i { font-style: normal; color: var(--muted); }
.ar-group-head .ar-grow { flex: 1 1 auto; }
.ar-tpl-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; }
.ar-tpl-card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 5px;
  padding: 0 0 6px;
  border: 1px solid transparent;
  border-radius: var(--r-card);
  background: transparent;
  color: var(--text-2);
  font: inherit;
  text-align: center;
  cursor: pointer;
}
.ar-tpl-card:hover { border-color: var(--line-2); }
.ar-tpl-card.on { border-color: var(--accent-line); background: var(--accent-soft); }
.ar-tpl-card b { font-size: 13px; font-weight: 600; color: var(--text); }
.ar-tpl-card .ar-note { white-space: normal; text-align: left; font-style: normal; }
.ar-fav {
  position: absolute;
  right: 4px;
  top: 4px;
  width: 22px;
  height: 22px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: rgba(8, 11, 19, .7);
  color: var(--muted);
  font-size: 13px;
  cursor: pointer;
}
.ar-fav.on { color: var(--warn); }
.ar-thumb {
  position: relative;
  overflow: hidden;
  width: 100%;
  aspect-ratio: 210 / 297;
  background: #fff;
  border-radius: var(--r-sm);
  border: 1px solid rgba(255, 255, 255, .16);
}
.ar-thumb-inner {
  position: absolute;
  left: 0;
  top: 0;
  width: 794px;
  height: 1123px;
  transform-origin: top left;
  pointer-events: none;
}
.ar-thumb-inner .rd-paper { min-height: 1123px; border-radius: 0; box-shadow: none; }
.ar-empty-tip { margin: 4px 0; font-size: 12.5px; color: var(--muted); }

/* ---------- 中间画布 ---------- */
.ar-canvas {
  position: relative;
  min-width: 0;
  min-height: 0;
  display: flex;
  flex-direction: column;
  /* 2026-10-11 用户：「这一部分也是和左右两侧一样显示」——
     这页画布是 <section>，会吃全站 section { padding: 48px 0 }，上下各缩 48px、
     看着比左右两栏短一截；这里归零，让画布底边和左右栏对齐（顶边让出标题行的高度，见 .ar-stage）。 */
  padding: 0;
  /* 2026-10-11 用户：「按之前的大小，多余的可以下滑显示，就跟 wps 文件编辑一样」——
     画布（A4 等比）比可视区高时，由这一列滚动查看，底部输入条吸附在可视区底部 */
  overflow-y: auto;
  overflow-x: hidden;
}
.ar-stage {
  position: relative;
  /* 2026-10-11 用户要求：画布按 A4 纸等比例（210:297），但**按之前的大小**——
     宽度保持"中间列 − 左右各 18px"，高度 = 宽度 × 297/210 往下延伸；超出可视区的部分滚动看（WPS 式），
     不再像上一版那样缩到可视高度内 */
  flex: 0 0 auto;
  aspect-ratio: 210 / 297;
  width: calc(100% - 36px);
  margin: 10px auto 0; /* 与独立出来的工具条之间留 10px，视觉上真正"分开" */
  border: 1px dashed var(--line-2);
  border-radius: 12px;
  background:
    radial-gradient(1200px 320px at 50% -20%, rgba(76, 141, 255, .08), transparent 70%),
    var(--surface);
  /* 长稿要能滚：底部给浮在上面的输入条留出高度 */
  overflow-x: hidden;
  overflow-y: auto;
}
.ar-stage-spacer { height: 250px; }
/* 工具条已独立到画布框外（R35），纸面回到画布框内顶部附近 */
.ar-hold { position: absolute; left: 50%; top: 14px; transform: translateX(-50%); }
#ar-scaler { position: absolute; left: 0; top: 0; transform-origin: top left; }
#ar-scaler .rd-paper { width: 794px; min-height: 1123px; }
body.ar-paper-letter #ar-scaler .rd-paper { width: 816px; min-height: 1056px; }

.ar-empty {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  /* 画布变成"一张很长的 A4"后，空态内容改靠上放（否则会落在第一屏之外） */
  justify-content: flex-start;
  gap: 12px;
  text-align: center;
  padding: 22% 24px 200px;
  color: var(--muted);
}
.ar-empty-icon {
  width: 44px;
  height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  border: 1px solid var(--accent-line);
  background: var(--accent-soft);
  color: var(--accent-text);
  font-size: 18px;
}
.ar-empty b { color: var(--text); font-size: 16px; font-weight: 600; }
.ar-empty > span:last-child { font-size: 13.5px; line-height: 1.9; }

/* ---------- 底部输入条 ---------- */
.ar-composer {
  /* WPS 式：画布这一列滚动时，输入条吸附在可视区底部（sticky） */
  position: sticky;
  bottom: 14px;
  /* 2026-10-11 用户要求：这一条比画布「小一点点」并居中于画布——
     画布宽 = 列宽 − 36px；输入条宽 = 列宽 − 68px（比画布每边再内缩 16px），auto 左右边距居中 */
  width: calc(100% - 68px);
  margin: 10px auto 14px;
  z-index: 8;
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 12px 14px 10px;
  border: 1px solid var(--line-2);
  border-radius: var(--r-card);
  background: color-mix(in srgb, var(--surface) 94%, var(--bg));
  box-shadow: var(--shadow-2);
}
.ar-composer:focus-within { border-color: var(--accent-line); }
.ar-docbar { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.ar-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 9px;
  border-radius: var(--r-pill);
  border: 1px solid transparent;
  background: transparent;
  color: var(--text-2);
  font: inherit;
  font-size: 12.5px;
  cursor: pointer;
  white-space: nowrap;
}
.ar-pill:hover { border-color: var(--line-2); color: var(--text); }
.ar-pill.strong { border-color: var(--line); background: var(--surface-2); color: var(--text); }
.ar-pill.icon { padding: 4px 8px; color: var(--muted); }
.ar-pill.warn { color: var(--warn); border-color: color-mix(in srgb, var(--warn) 40%, var(--line)); }
.ar-state { font-size: 12.5px; color: var(--muted); }
.ar-pages {
  font-size: 12.5px;
  color: var(--text-2);
  padding: 3px 8px;
  border-radius: var(--r-pill);
  background: var(--surface-2);
  border: 1px solid var(--line);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.ar-pages.warn { color: var(--warn); border-color: color-mix(in srgb, var(--warn) 45%, var(--line)); }
.ar-grow { flex: 1 1 auto; }

.ar-input {
  width: 100%;
  /* 2026-10-11 用户要求：输入框参照微信聊天框——独立的圆角输入区（有底色/描边，聚焦高亮） */
  min-height: 64px;
  max-height: 180px;
  resize: none;
  border: 1px solid var(--line-2);
  border-radius: 12px;
  outline: none;
  background: color-mix(in srgb, var(--surface-2) 72%, transparent);
  padding: 10px 12px;
  color: var(--text);
  font: inherit;
  font-size: 14px;
  line-height: 1.7;
}
.ar-input:focus { border-color: var(--accent-line); background: var(--surface-2); }
.ar-input::placeholder { color: var(--muted); }
.ar-foot { display: flex; align-items: center; gap: 9px; padding-top: 0; }
.ar-plus {
  width: 28px;
  height: 28px;
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  border: 1px solid var(--line-2);
  background: var(--surface-2);
  color: var(--text-2);
  font: inherit;
  font-size: 14px;
  cursor: pointer;
}
.ar-plus:hover { border-color: var(--accent-line); color: var(--text); }
.ar-scope { font-size: 12.5px; color: var(--muted); white-space: nowrap; }
.ar-model { font-size: 12px; color: var(--muted); white-space: nowrap; }
.ar-send {
  width: 32px;
  height: 32px;
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  border: 0;
  background: linear-gradient(135deg, var(--cta-from), var(--cta-to));
  color: var(--cta-text);
  font: inherit;
  font-size: 15px;
  cursor: pointer;
}
.ar-send:hover { filter: brightness(1.08); }
.ar-send:disabled { opacity: .6; cursor: default; }

.ar-source {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  font-size: 12.5px;
  color: var(--text-2);
  border: 1px dashed var(--line-2);
  border-radius: var(--r-btn);
  padding: 5px 8px;
}
.ar-login {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  border: 1px solid var(--accent-line);
  background: var(--accent-soft);
  border-radius: var(--r-btn);
  padding: 6px 8px;
  font-size: 12.5px;
  color: var(--text-2);
}
.ar-login input {
  flex: 1 1 120px;
  min-width: 0;
  border: 1px solid var(--line-2);
  border-radius: var(--r-input);
  background: var(--surface);
  color: var(--text);
  padding: 6px 9px;
  font: inherit;
  font-size: 13px;
}
.ar-save-row { display: flex; gap: 6px; align-items: center; }
.ar-save-row input {
  flex: 1 1 auto;
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: var(--r-input);
  background: var(--surface-2);
  color: var(--text);
  padding: 7px 10px;
  font: inherit;
  font-size: 13px;
}

/* 导出菜单（贴在输入条上方） */
.ar-menu {
  position: absolute;
  right: 4px;
  bottom: 44px;
  z-index: 30;
  min-width: 250px;
  display: flex;
  flex-direction: column;
  padding: 6px;
  border-radius: var(--r-card);
  border: 1px solid var(--line-2);
  background: var(--surface);
  box-shadow: var(--shadow-2);
}
.ar-menu button {
  text-align: left;
  border: 0;
  background: transparent;
  color: var(--text-2);
  padding: 9px 10px;
  border-radius: var(--r-sm);
  font: inherit;
  font-size: 13px;
  cursor: pointer;
}
.ar-menu button:hover { background: var(--surface-2); color: var(--text); }
.ar-menu small { color: var(--muted); font-size: 11.5px; }

/* ---------- ATS 弹层 ---------- */
.ar-ats-pop {
  position: absolute;
  left: 18px;
  right: 18px;
  bottom: 150px;
  z-index: 9;
  max-height: 56%;
  overflow-y: auto;
  border: 1px solid var(--line-2);
  border-radius: var(--r-card);
  background: color-mix(in srgb, var(--surface) 96%, var(--bg));
  box-shadow: var(--shadow-2);
  padding: 12px 14px;
  display: flex;
  flex-direction: column;
  gap: 9px;
}
.ar-ats-head { display: flex; align-items: center; gap: 8px; font-size: 13.5px; color: var(--text); }
.ar-ats-score { display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; }
.ar-ats-score b { font-size: 20px; color: var(--text); font-variant-numeric: tabular-nums; }
.ar-ats-score span { font-size: 12.5px; color: var(--muted); }
.ar-jd textarea {
  width: 100%;
  min-height: 76px;
  resize: vertical;
  border: 1px solid var(--line);
  border-radius: var(--r-input);
  background: var(--surface-2);
  color: var(--text);
  font: inherit;
  font-size: 13px;
  padding: 8px 10px;
}
.ar-ats-chips { display: flex; flex-wrap: wrap; align-items: center; gap: 5px; }
.ar-chip-label { font-size: 12px; color: var(--muted); }
.ar-ats-chips .ar-chip {
  font-size: 12px;
  padding: 3px 9px;
  border-radius: var(--r-pill);
  border: 1px solid var(--line);
  background: var(--surface-2);
  color: var(--text-2);
}
.ar-ats-chips .ar-chip.ok { color: var(--ok); border-color: color-mix(in srgb, var(--ok) 34%, var(--line)); }
.ar-ats-chips .ar-chip.miss { color: var(--warn); border-color: color-mix(in srgb, var(--warn) 34%, var(--line)); }
.ar-risks { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 4px; }
.ar-risks li { display: flex; align-items: flex-start; gap: 6px; font-size: 12.5px; color: var(--text-2); line-height: 1.55; }
.ar-risks li .ar-dot { flex: 0 0 auto; width: 6px; height: 6px; border-radius: 50%; margin-top: 6px; background: var(--warn); }
.ar-risks li.ok .ar-dot { background: var(--ok); }
.ar-risks li.ok { color: var(--muted); }
.ar-risks.preflight li { align-items: center; }
.ar-preflight-head { font-size: 13px; color: var(--text-2); }
.ar-mini {
  border: 1px solid var(--line-2);
  background: var(--surface);
  color: var(--text-2);
  border-radius: var(--r-sm);
  padding: 3px 8px;
  font: inherit;
  font-size: 12px;
  cursor: pointer;
  white-space: nowrap;
}
.ar-mini:hover { border-color: var(--accent-line); color: var(--text); }
.ar-risks.preflight li .ar-mini { margin-left: auto; }
.ar-mini.danger:hover { border-color: color-mix(in srgb, var(--bad) 55%, var(--line)); color: var(--bad); }

/* ---------- 我的简历列表 ---------- */
.ar-mine-item {
  display: flex;
  align-items: stretch;
  gap: 6px;
  border: 1px solid var(--line);
  border-radius: var(--r-card);
  background: var(--surface-2);
  padding: 8px;
  margin-bottom: 8px;
}
.ar-mine-open {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  gap: 2px;
  text-align: left;
  border: 0;
  background: transparent;
  color: var(--text-2);
  font: inherit;
  cursor: pointer;
  min-width: 0;
}
.ar-mine-open b { color: var(--text); font-size: 13.5px; }
.ar-mine-sub { font-size: 12px; color: var(--text-2); }
.ar-mine-sub.dim { color: var(--muted); }
.ar-mine-ops { display: flex; flex-direction: column; gap: 4px; }

/* ---------- 弹窗 / 遮罩 / toast ---------- */
.ar-mask { position: fixed; inset: 0; z-index: 50; background: rgba(4, 6, 12, .62); backdrop-filter: blur(2px); }
.ar-modal {
  position: fixed;
  z-index: 80;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  width: min(640px, 94vw);
  max-height: 88vh;
  overflow-y: auto;
  border-radius: var(--r-card);
  border: 1px solid var(--line-2);
  background: var(--surface);
  box-shadow: var(--shadow-2);
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.ar-modal.wide { width: min(1040px, 96vw); }
.ar-modal-head { display: flex; align-items: center; gap: 8px; font-size: 14px; color: var(--text); }
.ar-modal textarea {
  width: 100%;
  min-height: 190px;
  resize: vertical;
  border: 1px solid var(--line);
  border-radius: var(--r-input);
  background: var(--surface-2);
  color: var(--text);
  font: inherit;
  font-size: 13px;
  padding: 10px;
}
.ar-modal-row { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.ar-check { display: inline-flex; align-items: center; gap: 5px; font-size: 12.5px; color: var(--text-2); }
.ar-check input { accent-color: var(--accent); }
.ar-import-state { border-left: 2px solid var(--accent-line); padding-left: 8px; color: var(--text-2); }
.ar-import-state.bad { border-left-color: color-mix(in srgb, var(--bad) 60%, var(--line)); color: var(--bad); }
.ar-dialog-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 12px; }

/* ---------- R1：目标岗位 / 我的资料 ---------- */
.ar-job-list { display: flex; flex-direction: column; gap: 6px; max-height: 240px; overflow-y: auto; }
.ar-job-row {
  display: flex;
  align-items: center;
  gap: 8px;
  text-align: left;
  border: 1px solid var(--line);
  border-radius: var(--r-btn);
  background: var(--surface-2);
  color: var(--text-2);
  padding: 7px 9px;
  font: inherit;
  font-size: 13px;
  cursor: pointer;
}
.ar-job-row:hover { border-color: var(--line-2); color: var(--text); }
.ar-job-row.on { border-color: var(--accent-line); background: var(--accent-soft); color: var(--text); }
.ar-job-row b { font-size: 13px; color: var(--text); }
.ar-job-row span { font-size: 12px; color: var(--muted); }
.ar-job-row .ar-grow { flex: 1 1 auto; }
.ar-form-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 8px; }
.ar-form-grid label { display: flex; flex-direction: column; gap: 4px; font-size: 12px; color: var(--muted); }
.ar-form-grid input,
.ar-profile-body input,
.ar-profile-body textarea,
.ar-jd-input {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: var(--r-input);
  background: var(--surface-2);
  color: var(--text);
  padding: 7px 9px;
  font: inherit;
  font-size: 13px;
}
.ar-jd-input { min-height: 120px; resize: vertical; }
.ar-profile-body { display: flex; flex-direction: column; gap: 12px; }
.ar-prof-sec { border: 1px solid var(--line); border-radius: var(--r-card); padding: 10px; display: flex; flex-direction: column; gap: 8px; }
.ar-prof-sec > b { font-size: 13px; color: var(--text); }
.ar-prof-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 8px; }
.ar-prof-row label { display: flex; flex-direction: column; gap: 4px; font-size: 12px; color: var(--muted); }
.ar-prof-item { border: 1px dashed var(--line-2); border-radius: var(--r-btn); padding: 8px; display: flex; flex-direction: column; gap: 8px; }
.ar-prof-item-head { display: flex; align-items: center; gap: 6px; font-size: 12px; color: var(--muted); }
.ar-prof-item-head .ar-grow { flex: 1 1 auto; }
.ar-profile-body textarea { min-height: 68px; resize: vertical; }
.ar-prof-sec > .ar-mini { align-self: flex-start; }

/* ============================================================================
   复位：site.css 有一条超长 `:not(...)` 链的全局按钮规则（特异度约 0,19,1），
   会把"没带它那串排除类"的 button 一律刷成**主 CTA 蓝渐变 + 光晕**。
   这一页的 chip / 小按钮 / 卡片要有自己的中性底（对齐客户端那版设计），
   所以用 ID 锚点（1,0,1 起，稳赢）统一复位，再按需贴回强调态。
   ============================================================================ */
#ar-head button,
#ar-composer button,
#ar-rail button,
#ar-mine-pane button,
#ar-ats-pop button,
#ar-tpl-dialog button,
#ar-import button,
#ar-job-modal button,
#ar-profile-modal button {
  background-image: none;
  box-shadow: none;
  color: var(--text-2);
  border-color: var(--line);
}
/* 贴合"选中 / 强调"的语义色（这些态在客户端那版里也是淡蓝底 + 蓝描边） */
#ar-head-actions button.on,
#ar-head button.ar-pill.strong,
#ar-composer button.ar-pill.strong,
#ar-composer button.ar-pill.on,
#ar-rail button.on,
#ar-tpl-dialog button.on,
#ar-job-modal button.ar-chipbtn.on,
#ar-import button.ar-chipbtn.on,
#ar-profile-modal button.ar-chipbtn.on,
#ar-rail button.ar-tpl-card.on,
#ar-tpl-dialog button.ar-tpl-card.on,
#ar-job-modal button.ar-job-row.on {
  color: var(--text);
  border-color: var(--accent-line);
  background-color: var(--accent-soft);
}
#ar-head button.ar-pill.warn,
#ar-composer button.ar-pill.warn { color: var(--warn); border-color: color-mix(in srgb, var(--warn) 40%, var(--line)); }
#ar-composer button.ar-pill.icon { color: var(--muted); }
#ar-rail button.ar-fav.on,
#ar-tpl-dialog button.ar-fav.on { color: var(--warn); border-color: var(--line); }
#ar-mine-pane button.ar-mini.danger,
#ar-profile-modal button.ar-mini.danger,
#ar-composer button.ar-mini.danger { color: var(--bad); border-color: color-mix(in srgb, var(--bad) 45%, var(--line)); }
/* 发送键是这一页唯一的主行动：保留蓝渐变 */
#ar-composer button.ar-send {
  color: var(--cta-text);
  border-color: transparent;
  background-image: linear-gradient(135deg, var(--cta-from), var(--cta-to));
}

/* ---------- R2：岗位要求 ↔ 我的材料 ---------- */
.ar-req { display: flex; flex-direction: column; gap: 6px; }
.ar-req-head { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--text-2); }
.ar-req-head .ar-grow { flex: 1 1 auto; }
.ar-req-row {
  display: flex;
  align-items: flex-start;
  gap: 7px;
  border: 1px solid var(--line);
  border-radius: var(--r-btn);
  background: var(--surface-2);
  padding: 7px 9px;
  font-size: 12.5px;
  color: var(--text-2);
  line-height: 1.55;
}
.ar-req-row .ar-req-tag {
  flex: 0 0 auto;
  padding: 1px 7px;
  border-radius: var(--r-pill);
  border: 1px solid var(--line);
  font-size: 11.5px;
  color: var(--muted);
  white-space: nowrap;
}
.ar-req-row.ok .ar-req-tag { color: var(--ok); border-color: color-mix(in srgb, var(--ok) 34%, var(--line)); }
.ar-req-row.partial .ar-req-tag { color: var(--warn); border-color: color-mix(in srgb, var(--warn) 34%, var(--line)); }
.ar-req-row.miss .ar-req-tag { color: var(--bad); border-color: color-mix(in srgb, var(--bad) 34%, var(--line)); }
.ar-req-row b { color: var(--text); font-weight: 600; }
.ar-req-row .ar-req-hit { color: var(--muted); font-size: 12px; }

/* 追问弹窗 */
.ar-ask-list { display: flex; flex-direction: column; gap: 10px; }
.ar-ask-item { border: 1px solid var(--line); border-radius: var(--r-card); padding: 10px; display: flex; flex-direction: column; gap: 6px; }
.ar-ask-item b { font-size: 13px; color: var(--text); }
.ar-ask-item > span { font-size: 12.5px; color: var(--text-2); }
.ar-ask-item textarea {
  min-height: 62px;
  resize: vertical;
  border: 1px solid var(--line);
  border-radius: var(--r-input);
  background: var(--surface-2);
  color: var(--text);
  font: inherit;
  font-size: 13px;
  padding: 7px 9px;
}

/* R3：分项评分 + 硬性/加分标签 */
.ar-score-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 8px; }
.ar-score-cell {
  display: flex;
  flex-direction: column;
  gap: 2px;
  border: 1px solid var(--line);
  border-radius: var(--r-btn);
  background: var(--surface-2);
  padding: 8px 10px;
}
.ar-score-cell span { font-size: 12px; color: var(--muted); }
.ar-score-cell b { font-size: 20px; color: var(--text); font-variant-numeric: tabular-nums; }
.ar-score-cell i { font-style: normal; font-size: 11.5px; color: var(--muted); }
.ar-score-cell.ok b { color: var(--ok); }
.ar-score-cell.mid b { color: var(--warn); }
.ar-score-cell.low b { color: var(--bad); }
.ar-req-kind {
  flex: 0 0 auto;
  padding: 1px 6px;
  border-radius: var(--r-pill);
  border: 1px dashed var(--line-2);
  font-size: 11px;
  color: var(--muted);
  white-space: nowrap;
}
.ar-req-kind.hard { color: var(--accent-text); border-color: var(--accent-line); }
.ar-req-row { cursor: pointer; }
.ar-req-row.ok { cursor: default; }
#ar-gap-list .ar-req-row { cursor: default; }
.ar-req-row.can-write { background: color-mix(in srgb, var(--accent) 8%, var(--surface-2)); }

/* R5：多岗位对比 */
.ar-queue { display: flex; flex-direction: column; gap: 6px; }
.ar-queue .ar-job-row { cursor: default; }
.ar-cmp-pick { display: flex; flex-wrap: wrap; gap: 6px; }
.ar-cmp-chip {
  border: 1px solid var(--line);
  background: var(--surface-2);
  color: var(--text-2);
  border-radius: var(--r-pill);
  padding: 5px 11px;
  font: inherit;
  font-size: 12.5px;
  cursor: pointer;
}
.ar-cmp-chip.on { border-color: var(--accent-line); background: var(--accent-soft); color: var(--text); }
.ar-cmp-table { width: 100%; border-collapse: collapse; font-size: 12.5px; }
.ar-cmp-table th,
.ar-cmp-table td { border: 1px solid var(--line); padding: 7px 9px; text-align: left; color: var(--text-2); }
.ar-cmp-table th { color: var(--muted); font-weight: 600; background: var(--surface-2); }
.ar-cmp-table td:first-child { color: var(--text); }
.ar-cmp-png { width: 100%; border: 1px solid var(--line); border-radius: var(--r-btn); margin-top: 4px; }

/* R15：并排 diff */
.ar-diff-table { width: 100%; border-collapse: collapse; font-size: 12px; table-layout: fixed; }
.ar-diff-table td { border-bottom: 1px solid var(--line); padding: 4px 6px; vertical-align: top; word-break: break-word; color: var(--text-2); }
.ar-diff-table td.ar-diff-mark { width: 26px; text-align: center; color: var(--muted); }
.ar-diff-table .ar-diff-removed td:nth-child(2) { background: color-mix(in srgb, var(--bad) 12%, transparent); }
.ar-diff-table .ar-diff-added td:nth-child(3) { background: color-mix(in srgb, var(--ok) 12%, transparent); }
.ar-diff-table .ar-diff-changed td:nth-child(2),
.ar-diff-table .ar-diff-changed td:nth-child(3) { background: color-mix(in srgb, var(--warn) 12%, transparent); }
.ar-diff-table .ar-diff-same td { color: var(--muted); }

/* R4：纸面上"被选中要改的那一段" */
#ar-scaler .rd-sec,
#ar-scaler .rd-li,
#ar-scaler .rd-p,
#ar-scaler .rd-entry { cursor: pointer; }
#ar-scaler .rd-sec:hover,
#ar-scaler .rd-li:hover,
#ar-scaler .rd-p:hover,
#ar-scaler .rd-entry:hover { outline: 1px dashed var(--accent-line); outline-offset: 2px; border-radius: 3px; }
#ar-scaler .rd-pick,
#ar-scaler .rd-pick:hover {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
  border-radius: 3px;
  background: color-mix(in srgb, var(--accent) 10%, transparent);
}

.ar-toast {
  position: fixed;
  z-index: 90;
  left: 50%;
  bottom: 34px;
  transform: translate(-50%, 20px);
  opacity: 0;
  pointer-events: none;
  transition: opacity .2s var(--ease), transform .2s var(--ease);
  background: var(--surface-3, #1a202c);
  border: 1px solid var(--line-2);
  color: var(--text);
  border-radius: var(--r-pill);
  padding: 9px 16px;
  font-size: 13px;
  box-shadow: var(--shadow-2);
  max-width: min(720px, 92vw);
}
.ar-toast.on { opacity: 1; transform: translate(-50%, 0); }

/* ---------- 窄屏：允许整页滚动，三栏改成上下堆叠 ---------- */
@media (max-width: 1080px) {
  body.ar-page .page-scroll { overflow-y: auto; }
  .ar-work { margin-right: 0; }
  .ar-work,
  .ar-work.with-mine,
  .ar-work.with-rail-off.with-mine { display: flex; flex-direction: column; }
  .ar-rail, .ar-mine { border: 0; border-bottom: 1px solid var(--line); max-height: 420px; }
  .ar-stage { width: calc(100% - 24px); height: auto; min-height: 0; aspect-ratio: 210 / 297; margin: 12px auto 0; }
  /* 窄屏是整页滚动（page-scroll），这一列不再自己滚，避免双重滚动条 */
  .ar-canvas { overflow: visible; }
  .ar-jobq { width: 148px; }
  .ar-jobdrop { width: min(92vw, 460px); }
  .ar-composer { position: static; width: auto; margin: 12px; }
  .ar-ats-pop { position: static; margin: 12px; max-height: none; }
  .ar-menu { bottom: auto; top: 44px; right: 8px; }
}

/* ---------- 打印 / 另存为 PDF：只留纸面 ---------- */
@media print {
  @page { margin: 0; }
  body.ar-page.ar-printing nav,
  body.ar-page.ar-printing .fx,
  body.ar-page.ar-printing .ar-head,
  body.ar-page.ar-printing .ar-rail,
  body.ar-page.ar-printing .ar-mine,
  body.ar-page.ar-printing .ar-composer,
  body.ar-page.ar-printing .ar-empty,
  body.ar-page.ar-printing .ar-ats-pop,
  body.ar-page.ar-printing .ar-modal,
  body.ar-page.ar-printing .ar-mask,
  body.ar-page.ar-printing .ar-toast,
  body.ar-page.ar-printing .site-rail,
  body.ar-page.ar-printing footer { display: none !important; }
  body.ar-page.ar-printing,
  body.ar-page.ar-printing .page-scroll,
  body.ar-page.ar-printing .ar-work,
  body.ar-page.ar-printing .ar-canvas,
  body.ar-page.ar-printing .ar-stage { background: #fff !important; overflow: visible !important; border: 0 !important; }
  body.ar-page.ar-printing .page-scroll { display: block !important; height: auto !important; }
  body.ar-page.ar-printing .ar-work { display: block !important; }
  body.ar-page.ar-printing .ar-stage { margin: 0 !important; padding: 0 !important; min-height: 0 !important; border-radius: 0 !important; display: block !important; }
  body.ar-page.ar-printing .ar-stage { aspect-ratio: auto !important; max-width: none !important; width: auto !important; }
  body.ar-page.ar-printing .ar-hold { position: static !important; transform: none !important; width: auto !important; height: auto !important; }
  body.ar-page.ar-printing #ar-scaler { position: static !important; transform: none !important; }
  body.ar-page.ar-printing #ar-scaler .rd-paper {
    width: 210mm !important;
    min-height: 0 !important;
    box-shadow: none !important;
    border-radius: 0 !important;
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }
  body.ar-page.ar-printing.ar-paper-letter #ar-scaler .rd-paper { width: 215.9mm !important; }
}
@page ar-a4 { size: A4; margin: 0; }
@page ar-letter { size: Letter; margin: 0; }
@media print {
  body.ar-page.ar-printing { page: ar-a4; }
  body.ar-page.ar-printing.ar-paper-letter { page: ar-letter; }
}
