/* 真实应用的增量样式：把原型的「定高画布」改成铺满窗口的活界面 */

html, body { height: 100%; overflow: hidden; }
body { background: var(--bg); }

/* hidden 属性要压过 .inp / .mask 之类的 display 声明：
   页面的显隐一律用 hidden 属性控制，样式层不许把它顶掉 */
[hidden] { display: none !important; }

/* ---------- 外壳 ---------- */
.app { height: 100vh; }
.side { overflow-y: auto; }
.canvas { height: 100vh; }
.body { overflow: auto; }
.topbar { flex: 0 0 52px; }
.topbar h3 { overflow: hidden; text-overflow: ellipsis; }

/* 交互元素要有点击感（原型是静态图，写的是 cursor:default） */
.btn, .link, .tabs a, .menu a, .sp, .dict-it, .tnode { cursor: pointer; }
.btn { transition: background .14s, border-color .14s, color .14s; }
.btn:hover { border-color: #C6D1C3; background: #F7F8EF; }
.btn.p:hover { background: #1F4C3C; border-color: #1F4C3C; }
.btn.danger:hover { background: #FDF4F3; }
/* 需要一眼看见的红色动作（如合同终止）：实心红，不是描边 */
.btn.danger.solid { background: var(--dan); border-color: var(--dan); color: #fff; font-weight: 500; }
.btn.danger.solid:hover { background: #8E2F2F; border-color: #8E2F2F; color: #fff; }
/* .btn 自带 display:inline-flex，会盖掉 [hidden]；页面用 hidden 开关按钮时必须补这条 */
.btn[hidden] { display: none; }
.link:hover { text-decoration: underline; }
tbody tr:hover { background: #FAFAF3; }
tbody tr.on { background: #F8F9F7; }

/* ---------- 真表单 ---------- */
input.inp, select.inp, textarea.inp {
  width: 100%;
  font-family: inherit;
  outline: none;
  transition: border-color .14s, box-shadow .14s;
}
input.inp:focus, select.inp:focus, textarea.inp:focus {
  border-color: #A5C2AA;
  box-shadow: 0 0 0 3px rgba(42, 95, 73, .10);
}
select.inp { padding-right: 6px; appearance: auto; }
textarea.inp { line-height: 1.7; }
/* 弹层/表单里的多行输入：高度跟着内容长，允许纵向拉伸 */
.dlg .field textarea.inp, .card-b .field textarea.inp {
  height: auto; padding: 8px 10px; resize: vertical; min-height: 74px;
}
input[type="date"].inp, input[type="datetime-local"].inp { padding: 0 8px; }

/* ---------- 日期控件：统一显示 yyyy/mm/dd ----------
   datefield.js 把每个 type=date 换成一个「文本框 + 日历图标」，
   原生 date 只留 1px 透明壳当值容器与系统日历入口，所以这里不做任何显隐开关 */
.dfield { position: relative; display: block; width: 100%; }
.dfield > .df-inp { width: 100%; padding-right: 26px; letter-spacing: .2px; }
.dfield > .df-cal {
  position: absolute; right: 5px; top: 50%; transform: translateY(-50%);
  width: 18px; height: 18px; display: flex; align-items: center; justify-content: center;
  color: #9EADA4; cursor: pointer;
}
.dfield > .df-cal:hover { color: #1F4C3C; }
.dfield > .df-cal svg {
  width: 15px; height: 15px; fill: none; stroke: currentColor;
  stroke-width: 1.6; stroke-linecap: round;
}
.dfield > .df-native {
  position: absolute; left: 0; bottom: 0; width: 1px; height: 1px;
  padding: 0; border: 0; opacity: 0; pointer-events: none;
}
.field .box.editable { padding: 0; border: none; min-height: 0; }
.field .box.editable input,
.field .box.editable select,
.field .box.editable textarea { width: 100%; }
/* 字段标签里的补充说明（原来写在 HTML 的 style 上，现在统一成类） */
.field label .label-hint { font-weight: 400; color: #9EADA4; }
/* 标签框：徽章 + 回车新增输入框 */
.box[data-tags] { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; padding: 6px 8px; min-height: 32px; }
.box [data-tag-add] { width: 110px; height: 24px; min-width: 0; font-size: 11.5px; }
.box [data-tag-del] { cursor: pointer; }

.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 0 12px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0 12px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0 12px; }

/* 只读态：字段右侧留一点呼吸 */
.f .v { font-size: 13px; color: var(--ink); line-height: 1.6; }
.f .v.muted { color: #A1B1A8; }

/* ---------- 弹层：统一版式 ---------- */
.dlg {
  max-height: 90vh; display: flex; flex-direction: column;
  border: 1px solid #E7EBE7; border-radius: 10px;
  box-shadow: 0 18px 48px rgba(11, 36, 31, .26);
}
.dlg-hd {
  flex: 0 0 auto; padding: 10px 20px 9px;
  border-bottom: 1px solid #EEF2ED; background: #FAFAF3;
}
.dlg-hd h4 {
  margin: 10px 0px 5px 0;
  font-size: 13.5px; font-weight: 600; color: #1B3A32;
  line-height: 1.4; letter-spacing: .1px;
}
.dlg-hd .sub { margin-top: 3px; font-size: 11.5px; color: #626D64; line-height: 1.7; }
.dlg-code {
  margin-left: 5px; font-size: 11.5px; font-weight: 400;
  color: #A1B1A8; letter-spacing: .2px;
}
.dlg-bd {
  flex: 1 1 auto; min-height: 0; overflow: auto;
  padding: 14px 20px; font-size: 12.5px; color: #33524A; line-height: 1.78;
}
.dlg-bd > * + * { margin-top: 10px; }
.dlg-ft {
  flex: 0 0 auto; padding: 11px 20px 15px;
  display: flex; gap: 9px; justify-content: flex-end; align-items: center;
}
/* 弹层内的错误行：提交失败时就地贴在底部，弹层不关、填过的值不动 */
.dlg-err {
  margin-top: 10px; padding: 7px 10px; border-radius: 6px;
  background: #F7EDEA; border: 1px solid #E7C9C4;
  color: #A63A3A; font-size: 12px; line-height: 1.75;
}

/* ---------- 空态 ---------- */
.empty-state {
  padding: 40px 20px; text-align: center; color: #A1B1A8; font-size: 12.5px; line-height: 2;
}
.empty-state b { display: block; color: #626D64; font-size: 13px; margin-bottom: 4px; }
/* 表格里的空态 / 加载态单元格 */
.td-empty { padding: 26px 0; text-align: center; color: #A1B1A8; font-size: 12px; }

/* ---------- 徽章列表（性格标签等） ---------- */
.chips-inline { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; padding: 6px 8px; min-height: 34px; }
.chips-inline .badge { cursor: default; }

/* ---------- 时间线（客户时间线 / 跟进记录） ---------- */
.tnode { cursor: pointer; }
.tnode .tt { display: flex; align-items: center; gap: 6px; }
.tnode .tt b { font-size: 12px; }
.tnode .tx { font-size: 12px; color: #33524A; line-height: 1.7; margin-top: 3px; word-break: break-word; }
.tnode .nx { font-size: 11px; color: #3A6553; margin-top: 3px; }
.tnode .by { font-size: 10.5px; color: #A1B1A8; margin-top: 5px; display: flex; align-items: center; gap: 5px; }
.tnode .by i {
  font-style: normal; width: 16px; height: 16px; border-radius: 50%;
  background: #EDF1EC; color: #3A6553; display: grid; place-items: center; font-size: 9.5px;
}

/* 右栏「沟通跟进」卡：整卡封顶 800px，只有中间的记录区滚动，卡头固定在上边
   —— 记录一多不封顶，右栏会把整页越顶越长，左边两块反而跟着空白（2026-10-29） */
.card.tl-card { max-height: 800px; display: flex; flex-direction: column; }
.card.tl-card > .card-h { flex: 0 0 auto; }
.card.tl-card > .card-b { flex: 1 1 auto; min-height: 0; overflow-y: auto; overscroll-behavior: contain; }
/* 右栏只有 320px，系统默认滚动条要吃掉 12px，这里收窄到 6px（只作用于这张卡） */
.card.tl-card > .card-b { scrollbar-width: thin; scrollbar-color: #C9D3C5 transparent; }
.card.tl-card > .card-b::-webkit-scrollbar { width: 6px; }
.card.tl-card > .card-b::-webkit-scrollbar-thumb { background: #C9D3C5; border-radius: 3px; }
.card.tl-card > .card-b::-webkit-scrollbar-thumb:hover { background: #B5C6BC; }
.card.tl-card > .card-b::-webkit-scrollbar-track { background: transparent; }

/* ---------- 登录页 ---------- */
.login-wrap { height: 100vh; display: grid; grid-template-columns: 1fr 1fr; background: #fff; }
.login-left {
  background: linear-gradient(150deg, #14352C 0%, #173E34 62%, #2A5F49 100%);
  color: #fff; padding: 64px 56px; display: flex; flex-direction: column; justify-content: space-between;
}
.login-right { display: grid; place-items: center; background: #FBFAF4; padding: 20px; }
.login-box { width: 330px; }
@media (max-width: 900px) {
  .login-wrap { grid-template-columns: 1fr; }
  .login-left { display: none; }
}

/* ---------- 报告预览 ---------- */
.report-doc { background: #fff; padding: 26px 30px; font-size: 12.8px; line-height: 1.95; color: #29443C; }
.report-doc h2 { font-size: 17px; margin: 0 0 4px; }
.report-doc h3 { font-size: 13.5px; margin: 20px 0 6px; color: #173E34; }
.report-doc .meta { font-size: 11.5px; color: #92A098; }

/* 改字不在弹层里做（2026-11-02）：测试报告的正文改走独立整页 P14，
   原来是 .edit-sec 那一摞小卡片，随 #dlg-edit 一起撤了。 */

/* ---------- 表格内的多行信息 ---------- */
.td-stack > div + div { margin-top: 1px; }
/* 已终止线索整行压暗：JS 只挂 class，颜色写在这里 */
tr.is-term { background: #FDFDFC; }
tr.is-term .nm { color: #626D64; }
.row-line { display: flex; align-items: center; gap: 6px; }
.row-line .k { color: #92A098; font-size: 11px; }

/* M02 分享链接：链接正文（2026-11-04）
   整条 URL 有 60 多个字符，表格里放不下 —— 单行省略号截断，全文在 title 里，
   点一下复制。等宽字体是为了让 token 那截数字与字母好认，不是装饰。 */
.sh-url { display: flex; align-items: center; gap: 4px; min-width: 0; }
.sh-url-t {
  /* max-width 是给表格看的：没有它，auto 布局会按 60 多个字符的完整宽度排这一列，
     把「操作」那一列挤出卡片（.card 是 overflow:hidden，挤出去就没了） */
  flex: 0 1 auto; min-width: 0; max-width: 360px; overflow: hidden; text-overflow: ellipsis;
  white-space: nowrap; cursor: pointer;
  font-family: ui-monospace, Menlo, Consolas, monospace;
  font-size: 11.5px; color: #33524A;
}
.sh-url-t:hover { color: #173E34; text-decoration: underline; }
.sh-url .ico-act { flex: 0 0 auto; width: 20px; height: 20px; }

/* 让 body 里的卡片间距一致 */
.body > * + * { margin-top: 14px; }
.body > .row { margin-top: 0; }

/* ---------- 表格行内图标操作按钮 + 悬停气泡（字典表与工作台共用） ---------- */
.dict-act, .ico-act {
  display: inline-flex; align-items: center; justify-content: center;
  width: 24px; height: 24px; border-radius: 5px;
  color: #33524A; cursor: pointer; position: relative;
  transition: background .12s, color .12s;
}
.dict-act:hover, .ico-act:hover { background: #E9EFE3; color: #173E34; }
/* .ico-act 是 inline-flex，UA 的 [hidden]{display:none} 压不住它，得自己补一条
   （与 .ico-tip[hidden] 同一个坑；待办列表「跟进详情」按有没有关联来显隐，靠它） */
.dict-act[hidden], .ico-act[hidden] { display: none; }
.dict-act.dan:hover { background: #FDF4F3; color: #A63A3A; }
/* 行内删除（待办列表 / 工作台待办提醒）：hover 走红，别跟旁边的「完成 / 改期」混在一起 */
.ico-act.dan:hover { background: #FDF4F3; color: #A63A3A; }
.dict-act.ok { color: #2F7A5C; }
.dict-act.ok:hover { background: #EFF7F2; color: #2F7A5C; }
.dict-act svg, .ico-act svg {
  width: 14px; height: 14px; display: block; fill: none;
  stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round;
}
.dict-act[data-tip]::after, .ico-act[data-tip]::after, .ico-tip[data-tip]::after {
  content: attr(data-tip); position: absolute; bottom: calc(100% + 5px); left: 50%;
  transform: translateX(-50%); padding: 4px 7px; border-radius: 4px;
  background: #1B3A32; color: #fff; font-size: 11px; line-height: 1.2;
  white-space: nowrap; opacity: 0; pointer-events: none;
  transition: opacity .12s; z-index: 30;
}
.dict-act[data-tip]:hover::after, .ico-act[data-tip]:hover::after, .ico-tip[data-tip]:hover::after { opacity: 1; }

/* 待办类别图标（待补资料 / 行动项 / 家长可见）：彩色，不跟 currentColor */
.ico-tip {
  display: inline-flex; align-items: center; justify-content: center;
  position: relative; flex: 0 0 auto;
}
.ico-tip > svg { width: 15px; height: 15px; display: block; }
/* .ico-tip 是 inline-flex，UA 的 [hidden]{display:none} 压不住它，得自己补一条 */
.ico-tip[hidden] { display: none; }
/* 实心图标（1024 视口的人像+箭头）：颜色交给 .ico-act 的 currentColor，不写字面色值 */
.ico-act svg.ico-fill {
  width: 15px; height: 15px;
  fill: currentColor; stroke: none;
}

/* ---------- 签约弹层：标准价 × 折扣 ＝ 合同金额 ---------- */
.calc-row { display: flex; align-items: flex-end; gap: 7px; margin-bottom: 13px; }
.calc-row .grow { flex: 1 1 0; min-width: 0; }
.calc-op { flex: none; padding-bottom: 9px; font-size: 15px; line-height: 1; color: #96A99E; }
.field .box.ro { background: #F8F9F7; border-color: #E4E5D9; color: #4A5B4F; }
.disc-eq { font-size: 11px; font-weight: 400; color: #92A098; margin-left: 4px; }
.sg-divider { height: 1px; background: #E4E7DA; margin: 3px 0 13px; }
/* 分割线已经画了，档位区不再自带顶边 */
.tier-box.sg-tiers { border-top: 0; padding-top: 0; margin-top: 0; }

/* ---------- 员工管理 P12：角色卡片 / 密码显隐 ---------- */
.role-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.role-opt {
  border: 1px solid #E4E5D9; border-radius: 7px; padding: 9px 10px 10px;
  cursor: pointer; transition: border-color .12s, background .12s, box-shadow .12s;
}
.role-opt:hover { border-color: #C6D1C3; background: #FAFAF3; }
.role-opt.on {
  border-color: #2A5F49; background: #F7F8F6;
  box-shadow: 0 0 0 2px rgba(42, 95, 73, .08);
}
.role-opt b { display: block; font-size: 12.5px; color: #1B3A32; font-weight: 600; }
.role-opt span { display: block; font-size: 10.5px; color: #92A098; margin-top: 3px; line-height: 1.55; }
.role-opt.on span { color: #506E60; }
.role-opt.lock { cursor: not-allowed; }
.role-opt.lock:not(.on) { opacity: .5; }
.role-opt.lock:hover { border-color: #E4E5D9; background: #fff; }
.role-opt.lock.on:hover { border-color: #2A5F49; background: #F7F8F6; }

/* 预约颜色（2026-11-04）：员工列表「可预约」徽章里那颗点，与台账胶囊上同一颗。
   十色都是深色系（shared/staff-colors.js），浅色在白底上根本看不见。
   6px 是因为它塞在徽章里（18px 高的圆角块），再大就把徽章撑变形 */
.st-dot {
  display: inline-block; width: 6px; height: 6px; border-radius: 50%;
  margin-right: 4px; vertical-align: 1px;
}
.st-colors { display: flex; flex-wrap: wrap; gap: 8px; }
.st-swatch {
  width: 24px; height: 24px; border-radius: 50%; cursor: pointer;
  border: 2px solid #fff; box-shadow: 0 0 0 1px #E7ECE6; transition: box-shadow .12s, transform .12s;
}
.st-swatch:hover { transform: scale(1.08); }
/* 选中的那枚：外面再套一圈深灰，比只加粗白边看得清（白底上白边等于没边） */
.st-swatch.on { box-shadow: 0 0 0 2px #4A5B4F; }
.st-swatch.on::after {
  content: '✓'; display: block; color: #fff; font-size: 12px; line-height: 20px;
  text-align: center; font-weight: 700;
}

.pwd-wrap { position: relative; }.pwd-wrap .inp { padding-right: 44px; }
.pwd-eye {
  position: absolute; right: 11px; top: 50%; transform: translateY(-50%);
  font-size: 11px; color: #2A5F49; cursor: pointer; user-select: none;
}
.pwd-eye:hover { text-decoration: underline; }

/* ---------- 详情侧栏与弹层里的键值行 ---------- */
.kv-row { display: flex; justify-content: space-between; }
.kv-line {
  display: flex; gap: 10px; font-size: 12px; padding: 6px 0;
  border-bottom: 1px dashed #E8E9DF;
}
.kv-line > .muted { flex: 0 0 78px; }
.kv-line > span:last-child { flex: 1 1 0; color: #1B3A32; line-height: 1.7; }
/* 跟进详情正文框 */
.fi-body {
  min-height: 104px; max-height: 230px; overflow: auto; padding: 9px 11px;
  line-height: 1.9; font-size: 12px; color: #33524A;
  background: #F7F6EE; white-space: pre-wrap;
}

/* ---------- 弹层：记一次联系/咨询 的说明段 ---------- */
.fd-note {
  font-size: 11.5px; color: #626D64; line-height: 1.9;
  margin: -4px 0 14px; padding-right: 4px;
}
.fd-note b { color: #33524A; font-weight: 600; }
.dlg .field label { font-size: 11.5px; }
/* AI 回填时"同时写画像"的勾选项 */
.ai-hint label { display: flex; align-items: center; gap: 6px; margin-top: 7px; cursor: pointer; }

/* ---------- 按钮内联图标：线性描边跟随文字色，实心图走 .ico-fill ---------- */
.btn svg {
  flex: 0 0 13px; width: 13px; height: 13px; display: block;
  fill: none; stroke: currentColor; stroke-width: 2;
  stroke-linecap: round; stroke-linejoin: round;
}
.btn svg.ico-fill { fill: currentColor; stroke: none; }
.btn.sm svg { width: 12px; height: 12px; flex-basis: 12px; }

/* ---------- 卡片头：标题后的说明文字 + 右侧深色按钮 ---------- */
.card-h .hint { font-size: 11.5px; color: #92A098; }
.card-h .btn { margin-left: auto; }

/* ---------- 工作台：线索漏斗饼图 ---------- */
.pie-wrap { display: flex; align-items: center; gap: 10px; }
.pie-c { position: relative; width: 132px; height: 132px; flex: 0 0 132px; }
.pie-c svg { display: block; }
.pie-mid {
  position: absolute; inset: 0; display: flex; flex-direction: column;
  align-items: center; justify-content: center; pointer-events: none;
}
.pie-mid b { font-size: 17px; color: #102F29; line-height: 1.1; font-variant-numeric: tabular-nums; }
.pie-mid span { font-size: 10px; color: #9DADA4; margin-top: 1px; }
.pie-legend { flex: 1 1 auto; min-width: 0; font-size: 11.5px; }
.pie-li { display: flex; align-items: center; gap: 6px; padding: 2.5px 0; }
.pie-dot { width: 8px; height: 8px; border-radius: 2px; flex: 0 0 8px; }
.pie-li .n {
  color: #4A5C50; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.pie-li .v {
  margin-left: auto; color: #102F29; font-weight: 600;
  font-variant-numeric: tabular-nums; padding-left: 6px;
}
.pie-li .p {
  color: #9DADA4; width: 36px; text-align: right;
  font-variant-numeric: tabular-nums; flex: 0 0 36px;
}
/* 竖排：类目多、名字长（问题库 9 类）时用 —— 饼居中在上，图例通栏在下，
   右栏 340px 里并排放不下「类别名 + 条数 + 百分比」三样 */
.pie-wrap.v { flex-direction: column; align-items: stretch; gap: 6px; }
.pie-wrap.v .pie-c { align-self: center; }
.pie-wrap.v .pie-li { padding: 3px 0; }

/* ---------- 服务包：退款档位编辑 ---------- */
.tier-box { margin-top: 4px; border-top: 1px solid #E8E9DF; padding-top: 13px; }
.tier-hd { display: flex; align-items: baseline; gap: 8px; margin-bottom: 9px; }
.tier-hd b { font-size: 12.5px; color: #1B3A32; }
.tier-hd .mini { font-size: 11px; color: #92A098; }
.tier-row { display: flex; align-items: center; gap: 6px; margin-bottom: 7px; }
.tier-row .lbl { font-size: 11.5px; color: #7F978E; white-space: nowrap; }
.tier-row input.inp { width: 92px; min-width: 0; }
.tier-add { display: inline-flex; align-items: center; font-size: 11.5px; color: #2A5F49; cursor: pointer; padding: 2px 0 0; }
.tier-add:hover { text-decoration: underline; }
.tier-note { margin-top: 9px; font-size: 10.5px; color: #9DADA4; line-height: 1.8; }
.tier-msg { margin-top: 6px; font-size: 11px; color: #3A6553; line-height: 1.8; }
.tier-msg.bad { color: #A63A3A; }
.tier-link { color: #2A5F49; cursor: pointer; }
.tier-link:hover { text-decoration: underline; }
.pkg-form .field { margin-bottom: 12px; }

/* 窗口太窄时表格在卡片内横向滚动，不要溢出卡片外 */
.dict-wrap { overflow-x: auto; }
.dict-wrap > table { min-width: 660px; }

/* 工作台两张跟进表：窗口窄时在卡片内横向滚动，不撑破卡片；操作列钉在右侧 */
.tbl-scroll { overflow-x: auto; }
.tbl-scroll > table th:last-child,
.tbl-scroll > table td:last-child {
  position: sticky; right: 0; z-index: 2;
  background: #fff;
  box-shadow: -8px 0 10px -10px rgba(11, 36, 31, .45);
}
.tbl-scroll > table th:last-child { background: #FAFAF3; }
.tbl-scroll > table tbody tr:hover td:last-child { background: #FAFAF3; }

/* 表格最后一列里的悬停提示改成「右对齐、只往左长」。
   默认那条 .ico-act[data-tip]::after 是 left:50% + translateX(-50%)，以 24px 图标为中心
   向两侧伸；最后一列紧挨表格右边界，
     · 落在 .tbl-scroll（overflow-x:auto）里 → 右边那半截计入 table 的 layout overflow，
       凭空多出一条几十 px 的横向滚动条（工作台待办 48px、预约台账 35px，差在提示文案长短）；
     · 落在普通 .card-b 里 → 被卡片的 overflow:hidden 裁掉半截，hover 时看不全。
   改成 right:0 之后提示框只向左侧铺开，两头都不犯。
   注意选择器不绑 .tbl-scroll：报告页那种不滚动的表同样在最后一列放图标按钮。 */
table td:last-child [data-tip]::after {
  left: auto; right: 0; transform: none;
}

/* ---------- 侧栏：brand 横图 ---------- */
.brand { padding: 14px 16px 13px; }
.brand img { display: block; width: 158px; height: 44px; }

/* ---------- 侧栏：菜单图标 ---------- */
.menu a { gap: 9px; }
.menu a .mi {
  flex: 0 0 15px; width: 15px; height: 15px;
  display: inline-flex; align-items: center; justify-content: center;
  color: #93AE99; transition: color .12s;
}
.menu a:hover .mi { color: #BED4C2; }
.menu a.on .mi { color: #BCD2C3; }
.menu a .mi svg {
  width: 14px; height: 14px; display: block;
  fill: none; stroke: currentColor; stroke-width: 1.75;
  stroke-linecap: round; stroke-linejoin: round;
}

/* ---------- 顶栏：标题前小图标 ---------- */
.topbar .tb-ico {
  flex: 0 0 25px; width: 25px; height: 25px; border-radius: 7px;
  background: #F2F5F2; color: #2A5F49; margin-right: -5px;
  display: inline-flex; align-items: center; justify-content: center;
}
.topbar .tb-ico svg {
  width: 14px; height: 14px; display: block;
  fill: none; stroke: currentColor; stroke-width: 1.8;
  stroke-linecap: round; stroke-linejoin: round;
}

/* ---------- AI 生成（P03C）与咨询弹层里的 AI 面板 ---------- */
.ai-empty {
  border: 1px dashed #DDE0D3; border-radius: 8px; background: #FBFAF4;
  padding: 26px 16px; text-align: center; font-size: 12px; color: #92A098; line-height: 1.9;
}
.ai-note { font-size: 11px; color: #92A098; line-height: 1.8; }
.ai-note b, .ai-note strong { color: #6B4FA8; font-weight: 600; }
.ai-note code { background: #F1EEF8; color: #6B4FA8; border-radius: 3px; padding: 0 4px; font-size: 10.5px; }

.ai-prompt-hd { display: flex; align-items: center; gap: 8px; font-size: 11px; color: #626D64; margin-bottom: 7px; }
.ai-prompt {
  margin: 0; background: #F7F6EE; border: 1px solid #E4E7DA; border-radius: 8px;
  padding: 10px 12px; font-family: ui-monospace, Menlo, Consolas, "Courier New", monospace;
  font-size: 11px; line-height: 1.85; color: #33524A; white-space: pre-wrap; word-break: break-word;
  max-height: 322px; overflow: auto;
}
.ai-prompt .sec { color: #173E34; font-weight: 700; }

.ai-prog { height: 6px; border-radius: 3px; background: #E8E9DF; overflow: hidden; margin: 9px 0 7px; }
.ai-prog i { display: block; height: 100%; background: #6B4FA8; transition: width .3s; }

.ai-row { display: flex; gap: 9px; padding: 9px 12px; border-bottom: 1px solid #E8E9DF; align-items: flex-start; }
.ai-row:last-child { border-bottom: 0; }
.ai-row .lb { flex: 0 0 92px; font-size: 11.5px; color: #626D64; padding-top: 6px; }
.ai-row .vl { flex: 1 1 auto; min-width: 0; }

/* 咨询过程 + AI 生成左右分栏（弹层内） */
.fd-ai { display: flex; gap: 10px; align-items: stretch; }
.fd-ai .fd-ai-main { flex: 1 1 auto; min-width: 0; }
.fd-ai-side {
  flex: 0 0 116px; display: flex; flex-direction: column; gap: 8px;
  align-items: center; justify-content: center; text-align: center; padding: 8px 6px;
  border: 1px dashed #DCD3EE; border-radius: 8px; background: #FAF8FE;
}
.fd-ai-side .mini { font-size: 10.5px; line-height: 1.65; color: #6B4FA8; }
.ai-hint {
  margin-bottom: 12px; padding: 8px 11px; border-radius: 7px;
  background: #F4EFF9; border: 1px solid #DCD3EE;
  font-size: 11.5px; color: #5C4B7D; line-height: 1.75;
}
.ai-hint .ai-tag { margin-right: 4px; }

/* ---------- P03C 聊天记录上传（只传文件，页面只显示地址） ---------- */
.up-zone {
  border: 1px dashed #C9D3C5; border-radius: 10px; background: #FBFAF4;
  padding: 22px 16px; text-align: center; cursor: pointer; transition: border-color .15s, background .15s;
}
.up-zone:hover, .up-zone.over { border-color: #6B4FA8; background: #FAF8FE; }
.up-zone .up-ico {
  width: 22px; height: 22px; color: #9EB0A5; margin-bottom: 6px;
  fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round;
}
.up-zone:hover .up-ico, .up-zone.over .up-ico { color: #6B4FA8; }
.up-tip { font-size: 12px; color: #5B6B5F; line-height: 1.9; }
.up-zone .mini { margin-top: 2px; color: #9EB0A5; }
.up-state { margin-top: 5px; font-size: 11px; color: #6B4FA8; min-height: 14px; }
.up-dot {
  display: inline-block; width: 6px; height: 6px; border-radius: 50%;
  background: #6B4FA8; margin-right: 4px; animation: up-pulse .9s infinite ease-in-out;
}
@keyframes up-pulse { 0%, 100% { opacity: .25; } 50% { opacity: 1; } }

.file-card { border: 1px solid #DDDFD2; border-radius: 9px; background: #FEFEFE; overflow: hidden; }
.fc-hd { display: flex; align-items: center; gap: 7px; padding: 9px 11px 7px; font-size: 12px; color: #2B443C; }
.fc-hd b { font-weight: 600; max-width: 200px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.fc-hd .fc-ico {
  width: 14px; height: 14px; color: #6B4FA8; flex: 0 0 14px;
  fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round;
}
.fc-url {
  margin: 0 11px; padding: 6px 8px; border-radius: 6px;
  background: #F7F8F6; border: 1px solid #ECEFEB;
  font-family: ui-monospace, Menlo, Consolas, "Courier New", monospace;
  font-size: 10.5px; line-height: 1.7; color: #44685A; word-break: break-all;
}
.fc-ops { display: flex; align-items: center; gap: 12px; padding: 7px 11px 9px; }
.fc-ops .link, .fc-ops .mini { font-size: 11px; }

/* ---------- P11 其他设置 · AI 接口设置 ---------- */
.ai-cfg-note {
  margin-bottom: 14px; padding: 9px 12px; border-radius: 7px;
  background: #F4EFF9; border: 1px solid #DCD3EE;
  font-size: 11.5px; color: #5C4B7D; line-height: 1.8;
}
.ai-cfg-note strong { color: #4A3A6B; }
.ai-cfg-ops { display: flex; align-items: center; gap: 10px; margin-top: 16px; }
.ai-cfg-result {
  display: none; margin-top: 12px; padding: 9px 12px; border-radius: 7px;
  font-size: 11.5px; line-height: 1.8; border: 1px solid transparent;
}
.ai-cfg-result.ok { display: block; background: #EAF3DE; border-color: #C0DD97; color: #27500A; }
.ai-cfg-result.bad { display: block; background: #FCEBEB; border-color: #F7C1C1; color: #791F1F; }
.ai-cfg-result:not(:empty) { display: block; }
.ai-cfg-scope { font-size: 12px; color: #4C5C50; line-height: 2.1; }
.ai-cfg-scope b { color: #173E34; font-weight: 600; }

/* P03C 顶部的接口状态条 */
.ai-cfg-on, .ai-cfg-off {
  margin-bottom: 11px; padding: 8px 11px; border-radius: 7px;
  font-size: 11.5px; line-height: 1.8; border: 1px solid transparent;
}
.ai-cfg-on { background: #EAF3DE; border-color: #C0DD97; color: #27500A; }
.ai-cfg-on code { background: #DCEBC4; color: #27500A; border-radius: 3px; padding: 0 4px; font-size: 10.5px; }
.ai-cfg-off { background: #FAEEDA; border-color: #FAC775; color: #633806; }
.ai-cfg-on .ai-tag, .ai-cfg-off .ai-tag {
  display: inline-block; margin-right: 5px; padding: 1px 6px; border-radius: 4px;
  font-size: 10px; font-weight: 600; letter-spacing: .2px;
}
.ai-cfg-on .ai-tag { background: #639922; color: #fff; }
.ai-cfg-off .ai-tag { background: #BA7517; color: #fff; }
.ai-cfg-off .link { color: #854F0B; text-decoration: underline; }

/* ============================================================
   页面改造后新增的通用件（结构写在 views/*.html，这里只管样子）
   ============================================================ */

/* 列表里的「下次跟进」：正常蓝粗、逾期红细 */
.next-at { color: #173E34; font-weight: 600; }
.next-at.late { color: #A63A3A; font-weight: 400; }

/* 通用小列表项（待核实、历史版本、合同列表） */
.li-row { padding: 9px 14px; border-bottom: 1px dashed #E8E9DF; font-size: 12px; }
.li-row:last-child { border-bottom: 0; }

/* P05C 附件列表行 */
.att-row { display: flex; align-items: center; gap: 10px; padding: 8px 0; border-bottom: 1px dashed #E8E9DF; }
.att-row:last-child { border-bottom: 0; }
.att-main { flex: 1 1 auto; min-width: 0; }
.att-name {
  font-size: 12.5px; color: #102F29;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
/* 来源与时间那行：徽标跟文字同一条基线，别被 .badge 的行高顶到上面去 */
.att-meta { margin-top: 2px; display: flex; align-items: center; gap: 6px; min-width: 0; }
.att-meta > [data-k="meta"] { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.att-acts { flex: 0 0 auto; display: flex; align-items: center; gap: 1px; }
/* 可见/不可见是彩色实心图标（自带 fill），不能套 .ico-act svg 那套描边。
   这两枚 viewBox 是横长的（1537×1024／1297×1024），同宽下比线框图标矮，所以放到 16px */
.ico-act.vis svg { width: 16px; height: 16px; stroke: none; }

/* AI 参与的分块（规划类附件）单独一套色 */
.card.is-ai { border-color: #D6C8E6; }
.card.is-ai .card-h { background: #FAF7FD; }
.card.is-ai .card-h h4 { color: #4A3D63; }

/* P05G「＋ 新增报告」下拉菜单 */
.menu-pop {
  position: fixed; width: 250px; background: #fff; border: 1px solid var(--line);
  border-radius: 9px; box-shadow: 0 14px 34px rgba(16, 47, 41, .16);
  z-index: 80; overflow: hidden; font-size: 12px;
}
.menu-pop .mh { padding: 8px 12px; color: #92A098; border-bottom: 1px solid #E8E9DF; }
.menu-pop .mh.top { border-top: 1px solid #E8E9DF; }
.menu-pop .mi { padding: 8px 12px; cursor: pointer; }
.menu-pop .mi:hover { background: #F8F8F7; }
.menu-pop .mi b { font-weight: 600; }

/* 左栏分类项选中态（原来是内联背景色，改成类；hover 写在前面，选中色才盖得住） */
.dict-it:hover { background: #F8F9F7; }
.dict-it.on { background: #E9EFE3; }

/* ============================================================
   P05F 跟进详情三栏：半宽卡片里的列表改成上下两行，别再塞表格
   ============================================================ */
.p05f-li { padding: 9px 0; border-bottom: 1px dashed #E8E9DF; }
.p05f-li:first-child { padding-top: 3px; }
.p05f-li:last-child { padding-bottom: 3px; border-bottom: 0; }

/* 待办事项行：三列（事项 / 日期 / 操作）。
   用 grid 而不是 flex：日期与操作要各自成列，两行的日期才会在同一竖线上 */
.todo-row { display: grid; grid-template-columns: minmax(0, 1fr) 74px 76px; gap: 8px; align-items: start; }
/* 第一列内部不换行：图标要跟标题同一行。标题给 flex:1 1 0（basis=0），
   它会自己折行而不会把整块挤到下一行 —— 写 auto 的话长标题一撑就换行了 */
.todo-c-main { display: flex; flex-wrap: nowrap; align-items: flex-start; gap: 5px; min-width: 0; }
.todo-c-main .p05f-title { flex: 1 1 0; min-width: 0; }
.todo-c-due { padding-top: 2px; color: #80968E; white-space: nowrap; }
.todo-c-ops { display: flex; align-items: center; justify-content: flex-end; gap: 1px; }
.p05f-title { flex: 1; min-width: 0; font-size: 12.5px; line-height: 1.65; color: #102F29; }
.p05f-del {
  flex: 0 0 auto; color: #CAD5CE; font-size: 14px; line-height: 1.3;
  cursor: pointer; padding: 0 3px;
}
.p05f-del:hover { color: #A63A3A; }
.p05f-check {
  display: flex; align-items: flex-start; gap: 6px;
  flex: 1; min-width: 0; font-size: 12px; color: #102F29; cursor: pointer;
}
.p05f-check input { margin-top: 2px; flex: 0 0 auto; }

/* 沟通音频：未上传＝虚线投放区，已上传＝文件行 + 播放器 */
.audio-drop {
  display: flex; flex-direction: column; align-items: center; gap: 3px;
  padding: 15px 10px; border: 1px dashed #C9D3C5; border-radius: 8px;
  background: #FAFAF3; cursor: pointer;
}
.audio-drop:hover { border-color: #A2BBA8; background: #F9F9F8; }
.audio-drop .ad-ico {
  width: 30px; height: 30px; border-radius: 8px; background: #E9EFE3; color: #173E34;
  display: grid; place-items: center; font-size: 14px;
}
.audio-drop .ad-t { font-size: 12px; color: #173E34; margin-top: 2px; }
.audio-row { display: flex; align-items: center; gap: 9px; }
.audio-row .ar-ico {
  flex: 0 0 auto; width: 28px; height: 28px; border-radius: 7px;
  background: #E9EFE3; color: #173E34; display: grid; place-items: center; font-size: 13px;
}
.audio-name {
  font-size: 12px; color: #102F29;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}


/* ---------- P03A：已签约线索被直接打开时的引导遮罩 ---------- */
.sign-tip-l1 { font-size: 13px; color: var(--ink); line-height: 1.9; }
.sign-tip-l1 b { color: var(--primary); font-weight: 600; }
.sign-tip-l2 { margin-top: 5px; font-size: 12px; color: var(--muted); line-height: 1.85; }

/* ---------- 列表分页条（六张列表共用，结构在 index.html 的 #tpl-pager） ---------- */
.pager {
  display: flex; align-items: center; justify-content: space-between; gap: 14px;
  padding: 9px 14px; border-top: 1px solid var(--line2); background: #FDFDFD;
  flex-wrap: wrap;
}
.pg-info { display: flex; align-items: center; gap: 14px; font-size: 11.5px; color: var(--muted); }
.pg-size { display: inline-flex; align-items: center; gap: 5px; white-space: nowrap; }
.pg-sel {
  height: 24px; padding: 0 4px; font-size: 11.5px; color: var(--ink2);
  border: 1px solid var(--line); border-radius: 5px; background: #fff; cursor: pointer;
  font-family: inherit;
}
.pg-sel:focus { outline: none; border-color: var(--primary2); }
.pg-nav { display: flex; align-items: center; gap: 5px; }
.pg-nums { display: inline-flex; align-items: center; gap: 5px; }
.pg-btn, .pg-num {
  font-family: inherit; font-size: 11.5px; color: var(--ink2);
  background: #fff; border: 1px solid var(--line); border-radius: 6px;
  cursor: pointer; padding: 0 8px; height: 26px; line-height: 24px;
  transition: background .12s, border-color .12s, color .12s;
}
.pg-num { min-width: 28px; padding: 0 6px; font-variant-numeric: tabular-nums; }
.pg-btn:hover:not(:disabled), .pg-num:hover:not(.on) { background: #F8F9F7; border-color: #D1E0D6; }
.pg-num.on {
  background: var(--primary); border-color: var(--primary); color: #fff; font-weight: 600;
  cursor: default;
}
.pg-btn:disabled { color: #B9C7BF; cursor: not-allowed; background: #FAFAF3; }
.pg-gap { color: var(--muted); font-size: 11.5px; padding: 0 1px; }

/* ---------- AI 任务弹层（通用三步，结构见 views/_ai-popup.html） ----------
   .ai-btn 是浅紫描边（卡片头那个入口按钮），.ai-solid 是这一层里的实心紫主操作 */
.btn.ai-solid { background: var(--ai); border-color: var(--ai); color: #fff; font-weight: 500; }
.btn.ai-solid:hover { background: #5B4192; border-color: #5B4192; color: #fff; }

/* 禁用态（2026-11-03）：三步弹层的【完成】在拿到回调结果之前一直是 disabled，
   而全站只有 .pg-btn / .dp-cell 写过 :disabled 样式，实心紫按钮看着跟能点一样。
   这里补一条通用的，并把 .ai-solid / .p 的悬停色压掉（:hover 是无条件生效的）。 */
.btn:disabled,
.btn:disabled:hover {
  background: #F4F3EA; border-color: #E7EBE6; color: #B9C7BF;
  font-weight: 400; cursor: not-allowed; box-shadow: none;
}
.btn.ai-solid:disabled,
.btn.ai-solid:disabled:hover { background: #E6EAE5; border-color: #E6EAE5; color: #B6C4BC; }
.btn.p:disabled,
.btn.p:disabled:hover { background: #DCDFD2; border-color: #DCDFD2; color: #AFBEB5; }

/* 第 1 步的选项：整行可点，勾上的整行变浅紫（选项由页面配置渲染） */
.ai-pick {
  display: flex; align-items: flex-start; gap: 10px;
  padding: 10px 12px; margin: 7px;
  border: 1px solid var(--line); border-radius: 8px; background: #fff;
  cursor: pointer; transition: border-color .14s, background .14s;
}
.ai-pick:hover { border-color: #C9D3C5; background: #FBFAF4; }
.ai-pick.on { border-color: var(--ai-line); background: var(--ai-soft); }
.ai-pick > input[type="checkbox"] {
  flex: 0 0 14px; width: 14px; height: 14px; margin: 3px 0 0;
  accent-color: var(--ai); cursor: pointer;
}
.ai-pick .ai-t { font-size: 12.5px; font-weight: 600; color: var(--ink); line-height: 1.6; }
.ai-pick .ai-t .badge { font-weight: 400; margin-left: 4px; vertical-align: 1px; }
.ai-pick .ai-d { margin-top: 2px; font-size: 11px; color: #80968E; line-height: 1.75; }

.ai-meta { display: flex; align-items: center; gap: 8px; }
/* 提示词框：够高能一眼看出结构，允许纵向拉伸；行高比普通输入宽，读长篇不挤 */
textarea.ai-prompt {
  display: block; width: 100%; height: min(46vh, 400px); padding: 10px 12px;
  resize: vertical; font-size: 12px; line-height: 1.9; font-family: inherit;
}

/* ---------- 总结及摘要：Markdown 展示态（2026-10-30） ----------
   textarea 与渲染区互斥显示，高度对齐（366px ≈ 原 6 行 + 200px），切换时不跳高 */
.md-view {
  min-height: 366px; padding: 9px 12px;
  border: 1px solid var(--line); border-radius: 6px; background: #fff;
  font-size: 12.5px; line-height: 1.95; color: var(--ink);
  overflow: auto; word-break: break-word; max-height: 540px;
}
.md-view > :first-child { margin-top: 0; }
.md-view > :last-child { margin-bottom: 0; }
.md-view p { margin: 0 0 8px; }
.md-view h1, .md-view h2, .md-view h3,
.md-view h4, .md-view h5, .md-view h6 { margin: 12px 0 6px; line-height: 1.5; font-weight: 600; }
.md-view h1 { font-size: 15px; }
.md-view h2 { font-size: 14px; }
.md-view h3, .md-view h4, .md-view h5, .md-view h6 { font-size: 13px; }
.md-view ul, .md-view ol { margin: 4px 0 8px; padding-left: 20px; }
.md-view li { margin: 2px 0; }
.md-view blockquote {
  margin: 6px 0; padding: 4px 10px; border-left: 3px solid #DCD3EE;
  background: #FAF8FE; color: #5A6A5E; border-radius: 0 4px 4px 0;
}
.md-view code {
  padding: 1px 5px; border-radius: 4px; background: #F4F3EA;
  font-family: Consolas, Menlo, monospace; font-size: 11.5px; color: #29443C;
}
.md-view pre {
  margin: 6px 0 10px; padding: 9px 11px; background: #F7F6EE;
  border: 1px solid var(--line); border-radius: 6px; overflow: auto;
}
.md-view pre code { padding: 0; background: none; font-size: 11.5px; line-height: 1.7; }
.md-view hr { margin: 12px 0; border: 0; border-top: 1px dashed #E7EBE6; }
.md-view a { color: var(--primary); text-decoration: none; }
.md-view a:hover { text-decoration: underline; }
.md-view strong { font-weight: 600; }

/* ---------- 学生画像：当前版只读展示 ---------- */
.pc-snap-hd { display: flex; align-items: center; gap: 8px; padding: 6px 0 5px; }
#pc-snap-body { padding-bottom: 4px; }
.pc-snap-row {
  font-size: 12.3px; line-height: 1.85; color: #29443C;
  padding: 3px 0; border-bottom: 1px dashed #F3F5F3;
}
.pc-snap-row:last-child { border-bottom: 0; }
.pc-snap-row .mini { color: #92A098; margin-right: 2px; }
#pc-snap:not([hidden]) + #pc-rows { border-top: 1px solid #E8E9DF; margin-top: 4px; }

/* ---------- 第 3 步：调用中 / 逐项写回状态 ---------- */
.ai-run {
  display: flex; align-items: center; gap: 11px;
  padding: 11px 13px; margin-bottom: 10px;
  background: var(--ai-soft); border: 1px solid var(--ai-line); border-radius: 8px;
}
.ai-run-t { font-size: 12.5px; font-weight: 600; color: var(--ink); }
.ai-spin {
  flex: 0 0 16px; width: 16px; height: 16px; border-radius: 50%;
  border: 2px solid var(--ai-line); border-top-color: var(--ai);
  animation: aispin .8s linear infinite;
}
@keyframes aispin { to { transform: rotate(360deg); } }

.ai-step {
  display: flex; align-items: flex-start; gap: 10px;
  padding: 9px 12px; margin-bottom: 7px;
  border: 1px solid var(--line); border-radius: 8px; background: #fff;
}
.ai-step .ai-dot {
  position: relative; flex: 0 0 16px; width: 16px; height: 16px; margin-top: 1px;
  border-radius: 50%; border: 2px solid #DDE0D3; box-sizing: border-box;
}
.ai-step .ai-step-t { font-size: 12.5px; font-weight: 600; color: var(--ink); line-height: 1.6; }
.ai-step.run .ai-dot { border-color: var(--ai); border-right-color: transparent; animation: aispin .8s linear infinite; }
.ai-step.ok { border-color: #C3E0D3; background: #F2F9F5; }
.ai-step.ok .ai-dot { background: #2E7D5B; border-color: #2E7D5B; }
.ai-step.ok .ai-dot::after {
  content: '✓'; position: absolute; inset: 0; color: #fff;
  font-size: 10px; line-height: 12px; text-align: center; font-weight: 700;
}
.ai-step.fail { border-color: #E7C9C9; background: #FBF3F3; }
.ai-step.fail .ai-dot { background: #A63A3A; border-color: #A63A3A; }
.ai-step.fail .ai-dot::after {
  content: '!'; position: absolute; inset: 0; color: #fff;
  font-size: 10px; line-height: 12px; text-align: center; font-weight: 700;
}
.ai-step.skip { background: #FAFAF3; }
.ai-step.skip .ai-step-t { color: #92A098; font-weight: 400; }

/* ---------- 第 2 步脚注：一枚【下一步】，点开选跑法（模型直跑 / 手动执行 Agent） ---------- */
.ai-go { margin-left: auto; display: flex; align-items: center; gap: 9px; }
.ai-go > .btn svg { width: 12px; height: 12px; flex-basis: 12px; }

/* 下拉菜单：复用 .menu-pop（position:fixed，坐标由 JS 按按钮位置算），往上开。
   两项各带一枚 26px 图标（web/assets/接口.svg、机器人.svg），所以菜单留 5px 内边距、
   行改成 flex，鼠标悬停整行一块浅紫底 —— 比原来"两行字贴在一起"更好点中。 */
.ai-menu { width: 316px; padding: 5px; }
.ai-menu .mi {
  display: flex; align-items: flex-start; gap: 10px;
  padding: 9px 10px; border-radius: 8px; line-height: 1.55;
}
.ai-menu .mi + .mi { margin-top: 2px; }
.ai-menu .mi:hover { background: #F5F2FB; }        /* 跟 AI 紫同系，别用页面那套蓝 */
.ai-menu .mi-ico {
  flex: 0 0 26px; width: 26px; height: 26px; display: block;
  margin-top: 1px;
}
.ai-menu .mi-tx { min-width: 0; }
.ai-menu .mi b { display: block; font-size: 12.5px; color: #243E36; }
.ai-menu .mi span {
  display: block; margin-top: 3px; color: #92A098; font-size: 11.3px; line-height: 1.55;
  text-wrap: balance;      /* 两行平分，别出现「跑／完自己回传」这种孤字断行 */
}

/* ---------- 第三步：等待 Agent 回调（倒计时 chip + 回调地址） ---------- */
.ai-cd {
  flex: 0 0 auto; padding: 3px 8px; border-radius: 6px;
  border: 1px solid var(--ai-line); background: #fff;
  font-family: Consolas, Menlo, monospace; font-size: 12px; color: #4A3D63;
}
.ai-cd b { font-weight: 600; letter-spacing: .5px; }
.ai-cd.warn { border-color: #E7C9C9; background: #FBF3F3; color: #A63A3A; }

.ai-wait {
  margin-top: 10px; padding: 9px 12px 10px;
  border: 1px solid var(--line); border-radius: 8px; background: #FAFAF3;
}
.ai-wait-hd { display: flex; align-items: center; gap: 10px; margin-bottom: 5px; }
.ai-wait-hd .link { margin-left: auto; font-size: 11.5px; }
.ai-wait-hd .link + .link { margin-left: 0; }   /* 两枚并排靠右：复制提示词 / 复制地址 */

/* 第 1 步顶部那条「上次那单还没收尾」—— 关掉第三步不会取消这一单，
   再打开弹层就能从这里接着等（记录存在 sessionStorage，见 ai-popup.js） */
.ai-resume {
  display: flex; align-items: center; gap: 10px;
  margin: 0 0 10px; padding: 9px 12px;
  border: 1px solid #D9C9F0; border-radius: 8px; background: #F8F4FD;
}
.ai-resume .mini { color: #5B4192; }
.ai-resume .link { margin-left: auto; flex: 0 0 auto; font-size: 12px; color: var(--ai); font-weight: 500; }
.ai-url {
  padding: 6px 8px; border: 1px solid var(--line); border-radius: 6px; background: #fff;
  font-family: Consolas, Menlo, monospace; font-size: 11.5px; line-height: 1.7;
  color: #29443C; word-break: break-all; user-select: all;
}

/* ============================================================
   P05F 沟通报告：右栏卡片里的问题清单 + 家长端手机竖屏预览（弹层 dlg-rep-phone）
   手机宽 390px 是 P05F 的口径（与 h5.html 的 .h5-wrap max-width:520 排版同源，
   这里按 iPhone 竖屏收窄一档），报告正文用纯文本 pre-wrap，不用 markdown。
   ============================================================ */
/* .btn 是 inline-flex，会盖掉 [hidden] 的 UA 样式；base.css 只补了 .card-h，
   这里这张卡在 .card-b 里，单独补一条（没有报告时不该露出【预览 / 修改】） */
#rep-card .btn[hidden] { display: none; }

.rep-q { display: flex; gap: 6px; align-items: flex-start; padding: 7px 0; border-top: 1px dashed #E8E9DF; }
.rep-q:first-child { border-top: none; padding-top: 4px; }
.rep-q > .badge { flex: 0 0 auto; margin-top: 1px; }
.rep-q-b { flex: 1; min-width: 0; font-size: 11.5px; line-height: 1.7; color: #29443C; }
/* 建议回答只露两行：卡片在 320px 右栏里，全铺开会把页面拉得很长 */
.rep-q-b .mini {
  margin-top: 2px; display: -webkit-box; -webkit-line-clamp: 2;
  -webkit-box-orient: vertical; overflow: hidden;
}

#dlg-rep-phone .phone-shell {
  width: 390px; margin: 0 auto; border: 1px solid #D8DBCF; border-radius: 16px;
  height: min(620px, calc(100vh - 220px)); min-height: 380px;
  box-shadow: 0 10px 28px rgba(16, 47, 41, .12);
}
#dlg-rep-phone .h5 { overflow: auto; overscroll-behavior: contain; }

/* 报告正文：结构与 h5.html 的家长端保持同一套视觉（渐变头 + 白卡 + 段标题） */
.rp-doc { background: #F4F3EA; min-height: 100%; padding-bottom: 6px; }
.rp-doc .rp-hd {
  background: linear-gradient(135deg, #173E34 0%, #2A5F49 100%);
  color: #fff; padding: 18px 16px 16px; border-radius: 0 0 16px 16px;
}
.rp-doc .rp-brand { font-size: 9.5px; letter-spacing: 1.2px; opacity: .78; }
.rp-doc .rp-hd h1 { font-size: 15px; margin: 6px 0 0; font-weight: 600; line-height: 1.5; }
.rp-doc .rp-meta { font-size: 11px; opacity: .86; margin-top: 7px; line-height: 1.7; }
.rp-doc .rp-card {
  background: #fff; margin: -10px 10px 0; border: 1px solid #DCDED4;
  border-radius: 12px; padding: 14px 13px 12px;
}
.rp-doc h3 {
  font-size: 12.5px; margin: 15px 0 7px; padding-left: 8px;
  border-left: 3px solid #2A5F49; line-height: 1.35; color: #173E34;
}
.rp-doc .rp-sec:first-child h3 { margin-top: 0; }
.rp-doc .rp-body {
  font-size: 12.5px; line-height: 1.95; color: #29443C;
  white-space: pre-wrap; word-break: break-word;
}
.rp-doc .rp-sec + .rp-sec { border-top: 1px dashed #DCDED4; margin-top: 14px; padding-top: 2px; }
.rp-doc .rp-foot {
  text-align: center; font-size: 10px; color: #92A098;
  line-height: 1.9; padding: 14px 18px 18px;
}
.rp-doc .rp-empty { font-size: 12px; color: #92A098; line-height: 1.9; padding: 6px 0; }

/* 编辑态：文本框按内容自适应高度，长得跟 pre-wrap 的正文一样，切回预览不会"跳一下" */
.rp-doc .rp-ta {
  width: 100%; display: block; box-sizing: border-box; resize: none; overflow: hidden;
  border: 1px dashed #BCCFC1; border-radius: 6px; padding: 7px 9px;
  font-family: inherit; font-size: 12.5px; line-height: 1.95; color: #29443C;
  background: #FEFEFD; transition: border-color .12s, background .12s;
}
.rp-doc .rp-ta:focus { outline: none; border-color: #2A5F49; background: #fff; }

/* 编辑态标题（2026-11-04）：默认「2026-11-04 沟通总结」，点【编辑】后直接在原位改。
   深底渐变上不能再套白底输入框 —— 只加一圈虚线，跟下面正文的 .rp-ta 是一套语感 */
.rp-doc .rp-hd h1.rp-title-edit {
  cursor: text; border-bottom: 1px dashed rgba(255, 255, 255, .55);
  padding-bottom: 2px; outline: none;
}
.rp-doc .rp-hd h1.rp-title-edit:focus { border-bottom-color: #fff; background: rgba(255, 255, 255, .10); }

/* ============================================================
   P13 问题库：类别聚合 chip + 列表里的问题/建议截断
   一排 chip 既是「按类别聚合」的统计，也是筛选器 —— 点一下按这类筛，再点一次取消。
   数字必须与点进去看到的条数一致（后端聚合套的是同一套筛选条件）。
   ============================================================ */
.qcats {
  display: flex; flex-wrap: wrap; gap: 8px;
  margin-top: 12px; padding-top: 12px; border-top: 1px dashed #E6E7DB;
}
.qcat {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 4px 11px; border-radius: 999px; border: 1px solid #DDE0D3;
  background: #fff; font-size: 12px; color: #4A5C50;
  cursor: pointer; user-select: none;
  transition: border-color .12s, background .12s, color .12s;
}
.qcat > b { font-weight: 600; color: #1B3A32; font-variant-numeric: tabular-nums; }
.qcat:hover { border-color: #BCCFC1; background: #F7F8EF; }
.qcat.on { background: #173E34; border-color: #173E34; color: #fff; }
.qcat.on > b { color: #fff; }
/* 0 条的类别留在原位但压暗：看得出「这一类还没人问过」，而不是整个类目消失 */
.qcat.zero { color: #ACB9B1; background: #FAFAF3; }
.qcat.zero > b { color: #ACB9B1; }

/* 问题与建议各露两行：一行塞不下整段，全铺开会把表格拉成一片字海 */
.q-txt {
  display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2;
  overflow: hidden; word-break: break-word;
  font-size: 12.5px; line-height: 1.75; color: #29443C;
}
/* 「来源沟通」不再是文字列，压成一枚图标（.ico-act + #ico-follow），这里只留问题正文两行 */

/* ============================================================
   P05H 背景提升（2026-11-01）：弹层里的点选组、凭证附件行、附件库选择器
   级别/类型都是单选，用全站同一套 .sp 标签；附件行要能一眼看出「挂的是哪个文件」，
   所以文件名给满格宽度、操作链接靠右收窄。
   ============================================================ */
.picks { display: flex; flex-wrap: wrap; gap: 7px; }

.act-att { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.act-att-ico {
  width: 22px; height: 22px; border-radius: 5px; flex: 0 0 auto;
  background: #E9EFE3; color: #173E34;
  display: inline-flex; align-items: center; justify-content: center;
}
.act-att-ico svg, .act-pick-ico svg, .act-file svg {
  width: 13px; height: 13px; display: block; fill: none;
  stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round;
}
.act-att-name {
  font-size: 12.5px; color: #29443C; max-width: 300px;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.act-link { font-size: 11.5px; color: #2A5F49; cursor: pointer; user-select: none; }
.act-link:hover { text-decoration: underline; }
.act-link.dan { color: #A63A3A; }

/* 列表里的凭证：回形针 + 文件名，点一下预览。
   列只有 130px，文件名必须自己截断 —— 否则「CTB 创新大赛证书.png」会被折成两行，
   把行高撑起来，跟其它列对不齐。 */
.act-file {
  display: inline-flex; align-items: center; gap: 4px; position: relative;
  color: #2A5F49; cursor: pointer; max-width: 100%; overflow: hidden;
}
.act-file > span:last-child {
  min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.act-file:hover { text-decoration: underline; }

/* 附件库选择：卡片太高就自己滚，别把弹层顶出屏幕 */
.act-pick {
  max-height: min(46vh, 380px); overflow: auto;
  border: 1px solid #DCDED4; border-radius: 8px; padding: 4px;
}
.act-pick-row {
  display: flex; align-items: center; gap: 9px;
  padding: 8px 9px; border-radius: 6px; cursor: pointer;
  transition: background .12s;
}
.act-pick-row:hover { background: #F8F9F7; }
.act-pick-row + .act-pick-row { border-top: 1px dashed #E8E9DF; }
.act-pick-ico {
  flex: 0 0 auto; width: 24px; height: 24px; border-radius: 6px;
  background: #E9EFE3; color: #173E34;
  display: inline-flex; align-items: center; justify-content: center;
}
.act-pick-mid { flex: 1; min-width: 0; }
.act-pick-name {
  font-size: 12.5px; color: #29443C;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}

/* ============================================================
   P14 测试报告编辑（2026-11-02）：左编辑块 + 右手机竖屏实时预览
   右栏那台"手机"内部直接复用 .rp-doc（P05F 手机预览、h5.html 家长端同一套），
   所以预览里看到的排版就是家长手机上看到的排版，不是"长得像"。
   右栏 sticky：左栏逐段改字改到第五段时，手机那一屏仍然在视线里。
   ============================================================ */
.re-wrap { display: flex; align-items: flex-start; gap: 16px; }
/* .body > * + * 会给第二个子元素塞 14px 上边距，而这一页 view 里第一个子元素是
   <template>（display:none 但仍参与 * + * 判定），于是 .re-wrap 白白多出 14px ——
   高度封顶时这点差值正好把 .body 顶出一条滚动条。这里是页面唯一内容，抹掉。 */
.body > .re-wrap { margin-top: 0; }
.re-edit { flex: 1 1 auto; min-width: 0; }        /* min-width:0 让长段落能折行，别把右栏挤出去 */

/* 左卡封顶在窗口内（顶栏 52 + .body 上下 padding 36 = 88，再留 4px 缓冲）：
   段落一多只有 card-b 自己滚，卡头和【保存】那几个按钮始终在。
   不封顶的话整页会往下长，右栏 sticky 的手机相对被推走，改到第五段就看不见预览了。 */
.re-edit > .card { display: flex; flex-direction: column; max-height: calc(100vh - 92px); }
.re-edit > .card > .card-h { flex: 0 0 auto; }
.re-edit > .card > .card-b {
  flex: 1 1 auto; min-height: 0; overflow-y: auto; overscroll-behavior: contain;
  scrollbar-width: thin; scrollbar-color: #C9D3C5 transparent;
}
.re-edit > .card > .card-b::-webkit-scrollbar { width: 6px; }
.re-edit > .card > .card-b::-webkit-scrollbar-thumb { background: #C9D3C5; border-radius: 3px; }
.re-edit > .card > .card-b::-webkit-scrollbar-thumb:hover { background: #B5C6BC; }
.re-edit > .card > .card-b::-webkit-scrollbar-track { background: transparent; }

.re-side { flex: 0 0 390px; position: sticky; top: 0; display: flex; flex-direction: column; gap: 10px; }

/* 手机外框：宽度与 P05F 的手机预览同一个口径（iPhone 竖屏 390）
   高度留 300px 给顶栏 + 下方「分享链接」块：加了块之后整栏还是要在视口里，
   sticky 才不会把底部裁掉 */
.re-phone {
  width: 390px; border: 1px solid #D8DBCF; border-radius: 16px;
  height: min(620px, calc(100vh - 300px)); min-height: 360px;
  box-shadow: 0 10px 28px rgba(16, 47, 41, .12);
  overflow: hidden; background: #F4F3EA;
}
.re-phone-scr { height: 100%; overflow: auto; overscroll-behavior: contain; }
.re-phone-scr .rp-doc { min-height: 100%; }
/* 手机里那 390px 经不起 Windows 原生 17px 的滚动条，收成 4px 细条，颜色压淡 */
.re-phone-scr::-webkit-scrollbar { width: 4px; }
.re-phone-scr::-webkit-scrollbar-track { background: transparent; }
.re-phone-scr::-webkit-scrollbar-thumb { background: #C9D3C5; border-radius: 2px; }
.re-phone-scr::-webkit-scrollbar-thumb:hover { background: #B6C5B7; }
.re-tip { text-align: center; margin-top: 10px; }

/* 分段编辑块 */
.re-sec + .re-sec { margin-top: 14px; padding-top: 14px; border-top: 1px dashed #E6E7DB; }
.re-sec-hd { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; }
.re-sec-hd .inp { flex: 1; min-width: 0; font-weight: 600; }
.re-no {
  flex: 0 0 auto; width: 22px; height: 22px; border-radius: 6px;
  background: #E9EFE3; color: #173E34;
  font-size: 11px; font-weight: 600; font-variant-numeric: tabular-nums;
  display: inline-flex; align-items: center; justify-content: center;
}
.re-cnt {
  flex: 0 0 auto; font-size: 11px; color: #92A098;
  font-variant-numeric: tabular-nums;
}
/* 段头右侧三个动作：上移 / 下移 / 删除。贴着小标题不抢视线，
   但鼠标划过去要立刻看得出能点（浅底 + 描边），删除单独走红。 */
.re-acts { flex: 0 0 auto; display: inline-flex; gap: 2px; margin-left: 2px; }
.re-ico {
  width: 24px; height: 24px; border-radius: 6px; box-sizing: border-box;
  display: inline-flex; align-items: center; justify-content: center;
  border: 1px solid transparent; color: #92A098; cursor: pointer;
  transition: background .14s, color .14s, border-color .14s;
}
.re-ico:hover { background: #F6F7F5; border-color: #E4EAE3; color: #173E34; }
.re-ico.danger:hover { background: #FDF1F0; border-color: #F0D3D0; color: #B23B32; }
.re-ico svg {
  width: 14px; height: 14px; fill: none; stroke: currentColor;
  stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round;
}
/* 第一段没有「上移」、最后一段没有「下移」：留着位置（不然图标会左右跳），压淡且不响应 */
.re-ico[aria-disabled="true"] { opacity: .28; cursor: default; pointer-events: none; }
.re-sec textarea.inp {
  resize: none; overflow: hidden;          /* 高度由 autosize() 撑，不留手工拖拽的把手 */
  line-height: 1.85; min-height: 96px;
}

.re-add { margin-top: 12px; }
.re-empty {
  margin-top: 12px; padding: 14px 16px;
  border: 1px dashed #DDE0D3; border-radius: 8px; background: #FBFAF4;
  font-size: 12.5px; color: #33524A; line-height: 1.8;
}
.re-hint {
  margin-top: 12px; padding-top: 10px; border-top: 1px dashed #E6E7DB;
  font-size: 11.5px; color: #92A098; line-height: 1.85;
}

/* ---------- 分享链接块（预览下方，常驻；没链接时给一行空态） ----------
   链接是 token 长串，必须 word-break 折行，否则 390px 栏会被撑破。
   链接本身就是复制入口（悬停提示「点击复制此链接」），不再单独摆一枚图标；
   整段话术在右边那个【复制&分享】上。 */
.re-share {
  border: 1px solid #D8DBCF; border-radius: 10px;
  background: #fff; padding: 10px 12px 11px;
}
.re-share-hd {
  display: flex; align-items: center; justify-content: space-between;
  gap: 8px; margin-bottom: 8px;
}
.re-share-tt { font-size: 12px; font-weight: 600; color: #173E34; }
.re-share-acts { display: flex; align-items: center; gap: 6px; flex: 0 0 auto; }
.re-share-row { display: flex; align-items: flex-start; gap: 6px; }
.re-share-url {
  flex: 1 1 auto; min-width: 0; position: relative; cursor: pointer;
  font-family: ui-monospace, Consolas, monospace; font-size: 10.5px; line-height: 1.55;
  color: #33524A; word-break: break-all;
  background: #F7F6EE; border: 1px solid #DCDED4; border-radius: 6px;
  padding: 6px 8px;
}
.re-share-url:hover { border-color: #BCCEC0; background: #F8F9F7; color: #173E34; }
/* 悬停提示：向下弹（上面紧挨着块头，往上弹会盖住「分享链接」和按钮） */
.re-share-url[data-tip]::after {
  content: attr(data-tip); position: absolute; top: calc(100% + 5px); left: 50%;
  transform: translateX(-50%); padding: 4px 7px; border-radius: 4px;
  background: #1B3A32; color: #fff; font-size: 11px; line-height: 1.2;
  white-space: nowrap; opacity: 0; pointer-events: none;
  transition: opacity .12s; z-index: 30;
}
.re-share-url[data-tip]:hover::after { opacity: 1; }
.re-share-empty { font-size: 11.5px; color: #92A098; line-height: 1.7; }
.re-share-foot {
  display: flex; align-items: baseline; justify-content: space-between;
  gap: 8px; margin-top: 7px; font-size: 11px; color: #92A098;
}
/* 左边可能是「已设密码（这条链接创建得早，口令没留档）」这种长句，让它折行、别把到期日挤没 */
.re-share-foot > [data-k="pwd"] { flex: 1 1 auto; min-width: 0; line-height: 1.6; }
.re-share-foot > [data-k="exp"] { flex: 0 0 auto; white-space: nowrap; }
.re-share-foot b {
  color: #173E34; font-weight: 600; letter-spacing: .4px;
  font-variant-numeric: tabular-nums;
}
/* 分享弹层里那句「原来那条立即失效」：是提醒、不是报错，用暖黄色别用红。
   弹层是 _share-dlg.html 那一份（P05G 与 P14 共用），所以类名是通用的 dlg-warn */
.dlg-warn {
  background: #FEF9EF; border: 1px solid #F0DFC0; border-left: 3px solid #D9A24A;
  border-radius: 6px; padding: 9px 11px; margin-bottom: 12px;
  font-size: 12px; line-height: 1.8; color: #7C5F2C;
}
.dlg-warn b { color: #A06418; }

/* 测试记录列表里的「分享链接」格：链接是一长串 token，只显示头一段，点一下复制完整的。
   省略号必须落在内层：overflow:hidden 会把 ::after 那个气泡一起裁掉，
   所以外层只负责定位与气泡，裁字的是 .t-share-tx */
.t-share {
  position: relative; display: inline-block; vertical-align: bottom;
  max-width: 150px; cursor: pointer;
}
.t-share-tx {
  display: block; max-width: 150px; overflow: hidden; text-overflow: ellipsis;
  white-space: nowrap;
  font-family: ui-monospace, Consolas, monospace; font-size: 10.5px; color: #33524A;
}
.t-share:hover .t-share-tx { color: #173E34; text-decoration: underline; }
.t-share[hidden] { display: none; }
/* 悬停出「点击复制此链接」：向上弹 —— 向下会被卡片的 overflow:hidden 裁掉 */
.t-share[data-tip]::after {
  content: attr(data-tip); position: absolute; bottom: calc(100% + 4px); left: 0;
  padding: 4px 7px; border-radius: 4px; background: #1B3A32; color: #fff;
  font-family: inherit; font-size: 11px; line-height: 1.2; white-space: nowrap;
  opacity: 0; pointer-events: none; transition: opacity .12s; z-index: 30;
}
.t-share[data-tip]:hover::after { opacity: 1; }

/* 有效期：快到期的标一下颜色，别让家长在不该失效的时候点不开 */
.t-exp { font-variant-numeric: tabular-nums; white-space: nowrap; }
.t-exp.warn { color: #A65C1E; }

/* ============================================================
   P15 预约台账（2026-11-02）
   左边是「行=日期、列=时段」的排期表，右边是付费咨询客户卡片。
   一格一人，所以格子里的胶囊要能截断（名字长也不能把表格撑变形）
   ============================================================ */
/* 卡片头上的日期筛选（2026-11-04）：只看这一天（含）往后的档期，默认今天。
   靠右（margin-left:auto）—— 左边留给标题与统计提示。
   宽度写在 input 的行内样式上（datefield 会把它挪到外壳），这里只压高度对齐 card-h */
.bk-since { display: inline-flex; align-items: center; gap: 6px; margin-left: auto; flex: 0 0 auto; }
.bk-since > .mini { color: #626D64; }
.bk-since .df-inp { height: 26px; font-size: 11.5px; }
.bk-since #bk-today { font-size: 11.5px; color: var(--primary); white-space: nowrap; }

.bk-tbl th {
  font-size: 11px; color: #718272; font-weight: 500;
  padding: 9px 8px; border-bottom: 1px solid #E7E8DC; text-align: left;
}
.bk-tbl th.bk-th-slot {
  text-align: center; font-size: 10.5px; letter-spacing: .2px; white-space: nowrap;
}
.bk-tbl td {
  border-bottom: 1px solid #F5F6F4; padding: 6px 8px; vertical-align: middle;
}
.bk-tbl tr:last-child td { border-bottom: none; }

.bk-day b { display: block; font-size: 12.5px; color: #1B3A32; font-weight: 600; }
.bk-day .mini { display: block; font-size: 10.5px; line-height: 1.5; }
.bk-note { color: #A5804A; }

.bk-cell {
  text-align: center;
  border-left: 1px dashed #F5F6F4; padding: 5px 4px;
}
/* 一格可以排多位老师（028）：胶囊竖着堆，多了这一格自己撑高 */
.bk-pills { display: grid; flex-direction: column; gap: 3px; align-items: center; }
/* 胶囊：谢妈妈 · 王老师 */
.bk-pill {
  display: inline-block; max-width: 100%; padding: 4px 9px;
  border-radius: 999px; background: #e0f9f3; border: 1px solid #CFDDD0;
  color: #173E34; font-size: 11.5px; line-height: 1.4;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  cursor: pointer;
}
.bk-pill:hover { background: #bbe3cf; }
/* 已经转过线索的：浅蓝实底（2026-11-02 辉哥指定），比默认的白底蓝字更「已处理」 */
.bk-pill.done { background: #CFE3D2; border-color: #ADC9B2; color: #173E34; }
.bk-pill.done:hover { background: #C2DCC6; }
/* 顾问颜色的小圆点（2026-11-04）：只在「客户指定了顾问」的胶囊上出现，颜色由员工档案决定。
   7px 是能塞进 11.5px 字号又不撑高胶囊的尺寸；vertical-align 让点跟字的中线齐平 */
.bk-dot {
  display: inline-block; width: 7px; height: 7px; border-radius: 50%;
  margin-right: 5px; vertical-align: 1px; flex: none;
}

/* 停用的档期：日期加删除线 + 变灰（只有「上面还挂着预约」时才出现在台账上） */
.bk-tbl tr.is-off .bk-day b { color: #A1B1A8; text-decoration: line-through; }
.bk-tbl tr.is-off .bk-day .mini { color: #B9C7BF; }
.bk-tbl tr.is-off .bk-pill { opacity: .72; }
.bk-off { color: #B9C7BF; }

/* 当天没开放的时段（029）：淡斜纹 + 一行「不开放」，连＋都不露；
   已经约进来的胶囊照旧显示 —— 关掉时段不等于把那笔预约作废 */
.bk-cell.is-closed {
  background: repeating-linear-gradient(45deg, #FCFCFC, #FCFCFC 5px, #F6F7F5 5px, #F6F7F5 10px);
}
.bk-closed {
  display: inline-block; font-size: 10px; color: #B4C2BA; letter-spacing: .3px;
}

/* 编辑当天开放时段的勾选列表 */
.ck-list { display: flex; flex-direction: column; gap: 7px; }
.ck-row {
  display: flex; align-items: center; gap: 9px; cursor: pointer;
  font-size: 12.5px; color: #33524A;
  border: 1px solid #E7E8DC; border-radius: 7px; padding: 8px 11px;
  font-variant-numeric: tabular-nums;
}
.ck-row:hover { border-color: #D1E0D6; background: #FBFBFB; }
.ck-row input { width: 14px; height: 14px; accent-color: var(--primary); cursor: pointer; margin: 0; }

/* 空格子：平时只有一个很淡的＋，鼠标移到格子上才显出来 */
.bk-free {
  display: inline-flex; align-items: center; justify-content: center;
  width: 24px; height: 24px; border-radius: 7px;
  color: #C6D0C3; font-size: 13px; cursor: pointer;
  border: 1px dashed transparent;
  margin: 3px;
}
.bk-cell:hover .bk-free { border-color: #D9DDD0; background: #F7F8EF; color: #859E8F; }
.bk-act { text-align: center; width: 64px; white-space: nowrap; }

/* 说明文字里嵌一个胶囊形状的示意，别让「点胶囊」三个字落空 */
.bk-inline {
  padding: 1px 7px; margin: 0 3px; border-radius: 999px;
  background: #EAF0E4; border: 1px solid #CFDDD0; color: #173E34; font-size: 11px;
}

/* ---------- 新增档期：今天起 4 周 × 7 天的多选小日历 ---------- */
.dp-head {
  display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px;
  font-size: 11px; color: #92A098; text-align: center; margin-bottom: 5px;
}
.dp-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; }
.dp-cell {
  height: 32px; border: 1px solid var(--line); border-radius: 6px; background: #fff;
  color: #33524A; font-size: 12px; font-family: inherit; cursor: pointer;
  font-variant-numeric: tabular-nums; transition: background .12s, border-color .12s;
}
.dp-cell:hover:not(:disabled) { filter: brightness(0.7); }
.dp-cell.on { background: var(--primary); border-color: var(--primary); color: #fff; font-weight: 600; }
.dp-cell:disabled { color: #C9D4CD; background: #FAFAF3; cursor: not-allowed; }
/* 已经有档期的日期：斜纹底，一眼看出别再勾 */
.dp-cell.has:disabled {
  color: #AFBEB5;
  background: repeating-linear-gradient(45deg, #F7F7F6, #F7F7F6 4px, #EEF1ED 4px, #EEF1ED 8px);
}

/* 右栏付费客户卡片 */
.pa-card {
  border: 1px solid #E7E8DC; border-radius: 8px;
  padding: 10px 11px; margin-bottom: 9px; background: #fff;
}
.pa-card:last-child { margin-bottom: 0; }
.pa-hd { display: flex; align-items: center; gap: 6px; margin-bottom: 3px; }
.pa-hd b { font-size: 12.5px; color: #1B3A32; }
.pa-q {
  margin-top: 5px; line-height: 1.65; color: #5A6A5E;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
  border-bottom: 1px dashed #E6E7DB; padding-bottom: 8px;
}
.pa-ft { margin-top: 7px; display: flex; align-items: center; justify-content: space-between; }
