/*! 尾程运费行情问答悬浮窗（配套 assets/js/freight-ai.js）
 *  定位：右下角常驻按钮 + 弹出卡片，主题蓝系，移动端自适应。
 */
.faichat-launcher {
  position: fixed; right: 22px; bottom: 22px; z-index: 9998;
  display: inline-flex; align-items: center; gap: 8px;
  padding: 11px 18px 11px 14px; border: 0; border-radius: 999px;
  background: linear-gradient(135deg, var(--brand, #1A55C2), var(--brand-2, #2E6FD9));
  color: #fff; font: 600 14px/1 var(--f-body, inherit); letter-spacing: .02em;
  box-shadow: 0 10px 24px -8px rgba(26, 85, 194, .55), 0 2px 6px rgba(6, 23, 56, .12);
  cursor: pointer; transition: transform .18s ease, box-shadow .18s ease, opacity .18s ease;
}
.faichat-launcher:hover { transform: translateY(-2px); box-shadow: 0 14px 30px -8px rgba(26, 85, 194, .62); }
.faichat-launcher.is-hidden { opacity: 0; pointer-events: none; transform: scale(.9); }
.faichat-launcher-ico { display: inline-flex; }
.faichat-launcher-txt { white-space: nowrap; }

/* 10-02 放大：380×520 太窄，试算区被挤成竖排、渠道卡片只露 2.5 条、快捷问题被裁。
   现 560×660（接近常见大窗），仍保留 max-width/height 保护小屏。
   10-06 再加高 25%：660 → 825px。确认卡是长表单（目的地/总重/体积双tab/件数/品名/
   住宅/尾板/告警/按钮），660px 下要滚动才能看到确认按钮，客户容易漏看直接以为没反应。 */
.faichat {
  position: fixed; right: 22px; bottom: 22px; z-index: 2147483647;
  width: 560px; max-width: calc(100vw - 32px); height: 825px; max-height: calc(100vh - 84px);
  display: flex; flex-direction: column; overflow: hidden;
  background: var(--white, #fff); border: 1px solid var(--line, #D9E4F2);
  border-radius: var(--r-lg, 18px);
  box-shadow: 0 24px 60px -12px rgba(6, 23, 56, .32), 0 6px 16px rgba(6, 23, 56, .08);
  opacity: 0; transform: translateY(14px) scale(.97); pointer-events: none;
  transition: opacity .2s ease, transform .2s ease;
}
.faichat.is-open { opacity: 1; transform: none; pointer-events: auto; }

.faichat-head {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 14px 16px; color: #fff;
  background: linear-gradient(135deg, var(--ink, #061738), var(--ink-3, #12315F));
}
.faichat-head-l { display: flex; align-items: center; gap: 10px; }
.faichat-dot {
  width: 9px; height: 9px; border-radius: 50%; background: #34D399; flex: none;
  box-shadow: 0 0 0 4px rgba(52, 211, 153, .22);
}
.faichat-title { font: 700 15px/1.3 var(--f-display, inherit); }
.faichat-sub { font-size: 11.5px; color: var(--sky, #7FB2F5); margin-top: 2px; }
.faichat-close {
  border: 0; background: transparent; color: rgba(255, 255, 255, .75);
  font-size: 24px; line-height: 1; cursor: pointer; padding: 0 4px;
}
.faichat-close:hover { color: #fff; }

.faichat-body { flex: 1; min-height: 0; display: flex; flex-direction: column; }
/* 2026-10-06：消息区显式滚动条 + 底部渐隐（与报价弹窗同一套思路）。
   原来只有裸 overflow-y:auto，Windows 上细灰条几乎看不见 → 用户以为内容没出来。 */
.faichat-msgs {
  flex: 1; overflow-y: auto; padding: 14px;
  display: flex; flex-direction: column; gap: 10px;
  scrollbar-width: thin; scrollbar-color: #94A3B8 #F1F5F9;
}
.faichat-msgs::-webkit-scrollbar { width: 9px; }
.faichat-msgs::-webkit-scrollbar-track { background: #F1F5F9; border-radius: 9px; }
.faichat-msgs::-webkit-scrollbar-thumb {
  background: #94A3B8; border-radius: 9px; border: 2px solid #F1F5F9; background-clip: padding-box;
}
.faichat-msgs::-webkit-scrollbar-thumb:hover { background: #64748B; background-clip: padding-box; }
.faichat-msg { display: flex; }
.faichat-msg-me { justify-content: flex-end; }
/* 报价结果容器：摘要 / 说明 / 按钮 三块纵向堆叠。
   父级 .faichat-msg 是 display:flex（默认 row），不覆盖的话三块会被横着排成一行、互相挤压。 */
.faichat-msg-ai.faichat-res { flex-direction: column; align-items: stretch; gap: 0; }
.faichat-res > * { max-width: 100%; }
/* 气泡放宽：AI 回复要装试算标签 + 渠道卡片，86% 会让内容挤成窄条 */
.faichat-bubble {
  max-width: 96%; padding: 10px 13px; border-radius: 12px; font-size: 13.5px; line-height: 1.65;
  background: var(--mist, #F4F8FE); color: var(--t, #0B1A33); border: 1px solid var(--line, #D9E4F2);
  word-break: break-word; white-space: pre-wrap;
}
.faichat-msg-me .faichat-bubble { max-width: 82%; }
.faichat-msg-me .faichat-bubble {
  background: var(--brand, #1A55C2); color: #fff; border-color: transparent;
  border-bottom-right-radius: 4px;
}
.faichat-msg-ai .faichat-bubble { border-bottom-left-radius: 4px; }
.faichat-err { background: #FFF4E5; border-color: #FFD8A8; color: #8A4B00; }

/* 试算/行情标签：3 列自适应网格，每格内部「数值 + 说明」横排。
   原来靠 flex-wrap 自然换行，窄屏时一个标签独占整行、文字竖着排成一列。 */
.faichat-kvs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; margin-top: 9px; }
.faichat-kv {
  display: flex; align-items: baseline; gap: 5px; padding: 6px 9px; border-radius: 8px;
  background: var(--tint, #E7F0FC); border: 1px solid var(--line, #D9E4F2);
  font-size: 10.5px; color: var(--muted, #55688A); line-height: 1.2; min-width: 0;
}
.faichat-kv b { font: 700 14px/1.2 var(--f-num, inherit); color: var(--ink, #061738); flex: none; }
.faichat-kv > span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
/* 窄屏降为 2 列，避免格子太窄 */
@media (max-width: 520px) { .faichat-kvs { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.faichat-src { margin-top: 8px; font-size: 11px; color: var(--muted-2, #8B9CB8); }
.faichat-src a { color: var(--brand-2, #2E6FD9); text-decoration: none; }
.faichat-src a:hover { text-decoration: underline; }
.faichat-related { display: flex; flex-direction: column; gap: 5px; margin-top: 9px; }
.faichat-rel {
  text-align: left; border: 1px dashed var(--line-2, #BFCFE6); background: transparent;
  border-radius: 8px; padding: 6px 9px; font-size: 12px; color: var(--brand-2, #2E6FD9);
  cursor: pointer;
}
.faichat-rel:hover { background: var(--tint, #E7F0FC); }

/* 快捷问题：改换行铺满，不再横向滚动被裁（原来 380px 只能露出 2.5 个） */
.faichat-chips {
  display: flex; gap: 6px; flex-wrap: wrap; padding: 0 14px 10px; flex: none;
}
.faichat-chip {
  flex: none; border: 1px solid var(--line, #D9E4F2); background: var(--white, #fff);
  border-radius: 999px; padding: 6px 11px; font-size: 12px; color: var(--ink-3, #12315F);
  cursor: pointer; white-space: nowrap; transition: background .15s ease, border-color .15s ease;
}
.faichat-chip:hover { background: var(--tint, #E7F0FC); border-color: var(--brand-2, #2E6FD9); }

.faichat-form {
  flex: none; display: flex; gap: 8px; padding: 10px 14px 12px;
  border-top: 1px solid var(--line, #D9E4F2); background: var(--white, #fff);
}
.faichat-input {
  flex: 1; min-width: 0; padding: 9px 12px; border-radius: 10px;
  border: 1px solid var(--line-2, #BFCFE6); background: var(--mist, #F4F8FE);
  font: 400 13.5px/1.4 var(--f-body, inherit); color: var(--t, #0B1A33);
}
.faichat-input:focus { outline: none; border-color: var(--brand-2, #2E6FD9); background: #fff; }
.faichat-send {
  flex: none; border: 0; border-radius: 10px; padding: 0 15px; cursor: pointer;
  background: var(--brand, #1A55C2); color: #fff; font: 600 13.5px/1 var(--f-body, inherit);
}
.faichat-send:disabled { opacity: .55; cursor: default; }
.faichat-foot {
  flex: none; padding: 0 14px 11px; font-size: 11px; color: var(--muted-2, #8B9CB8); line-height: 1.5;
}

/* 报价卡片（AI 询价出价结果，2026-10-02） */
.faichat-quotes { display: flex; flex-direction: column; gap: 7px; margin-top: 9px; }
.faichat-quote {
  background: #fff; border: 1px solid var(--line, #DCE6F3); border-radius: 10px; padding: 9px 11px;
}
.faichat-quote.is-best { border-color: var(--brand-2, #2E6FD9); background: var(--tint, #E7F0FC); }
/* 头行允许换行：渠道名较长时（「OA美西直送特惠」）不再被省略号截断挤掉类型标签 */
.faichat-quote-h { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.faichat-quote-rank {
  flex: none; font: 700 10.5px/1.7 var(--f-body, inherit); padding: 0 6px; border-radius: 999px;
  background: var(--brand, #1A55C2); color: #fff;
}
.faichat-quote-name {
  flex: 1 1 auto; min-width: 0; font: 600 13px/1.4 var(--f-body, inherit); color: var(--ink, #061738);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.faichat-quote-type {
  flex: none; font-size: 10.5px; color: var(--muted-2, #8B9CB8);
  border: 1px solid var(--line, #DCE6F3); border-radius: 999px; padding: 0 6px; line-height: 1.7;
}
.faichat-quote-b { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; margin-top: 5px; }
.faichat-quote-price { font: 700 17px/1.2 var(--f-num, inherit); color: var(--brand, #1A55C2); }
.faichat-quote-meta { font-size: 11px; color: var(--muted-2, #8B9CB8); }
.faichat-note {
  margin-top: 8px; font-size: 11px; line-height: 1.55; color: var(--muted-2, #8B9CB8);
  background: #F4F7FC; border-radius: 8px; padding: 7px 9px;
}

.faichat-loading span { animation: faichat-blink 1.2s infinite; }
.faichat-loading span:nth-child(2) { animation-delay: .2s; }
.faichat-loading span:nth-child(3) { animation-delay: .4s; }

/* ==========================================================================
   思考过程（2026-10-02）：逐条真实进度 + 完整报价浮层
   ========================================================================== */
/* 思考步骤容器：左侧竖线串起，像一条流水 */
.faichat-think {
  margin: 0; padding: 10px 12px 2px; border: 1px solid var(--line, #D9E4F2);
  border-radius: 12px; background: #F8FBFF; position: relative;
}
/* 单行模式（2026-10-06）：始终只显示最后一条进度，行数恒为 1。
   底 padding 收到 10px（原先为多行预留的 2px 会在单行下显得头重脚轻）。 */
.faichat-think-single { padding: 10px 12px; }
.faichat-think-row {
  display: flex; align-items: flex-start; gap: 8px;
  padding: 4px 0; position: relative; font-size: 12.5px; line-height: 1.5;
}
/* 连接各步骤的竖线（仅多行模式需要；单行模式没有相邻行，自然不触发） */
.faichat-think-row + .faichat-think-row::before {
  content: ''; position: absolute; left: 6.5px; top: -6px; height: 12px;
  border-left: 1.5px solid #C7D8EC;
}
.faichat-think-dot {
  flex: none; width: 14px; height: 14px; border-radius: 50%; margin-top: 1px;
  background: #fff; border: 1.5px solid #C7D8EC; position: relative; z-index: 1;
}
.faichat-think-row.is-done .faichat-think-dot { background: #34D399; border-color: #34D399; }
.faichat-think-row.is-done .faichat-think-dot::after {
  content: ''; position: absolute; left: 3.5px; top: 1px; width: 4px; height: 8px;
  border: solid #fff; border-width: 0 1.8px 1.8px 0; transform: rotate(43deg);
}
.faichat-think-row.is-active .faichat-think-dot { border-color: var(--brand-2, #2E6FD9); }
/* 正在跑的那一格：呼吸光圈 */
.faichat-think-row.is-active .faichat-think-dot::before {
  content: ''; position: absolute; inset: -4px; border-radius: 50%;
  border: 1.5px solid var(--brand-2, #2E6FD9); opacity: .55;
  animation: faichat-pulse 1.1s ease-out infinite;
}
@keyframes faichat-pulse {
  0% { transform: scale(.7); opacity: .6; }
  100% { transform: scale(1.5); opacity: 0; }
}
.faichat-think-txt { flex: 1; min-width: 0; color: var(--muted, #55688A); }
.faichat-think-row.is-active .faichat-think-txt { color: var(--brand-2, #2E6FD9); font-weight: 500; }
.faichat-think-row.is-done .faichat-think-txt { color: var(--t, #0B1A33); }
.faichat-think-d { color: var(--muted-2, #8B9CB8); font-size: 11.5px; margin-top: 1px; }
.faichat-think-ms {
  flex: none; font: 500 10.5px/1.6 ui-monospace, SFMono-Regular, Consolas, monospace;
  color: var(--muted-2, #8B9CB8); padding-top: 1px;
}

/* 「查看完整报价」入口按钮
   🔴 2026-10-06 加吸底（sticky bottom）：渠道多时消息内容很长，
      按钮跟着内容走会被顶出可视区（实测下缘超出 35px 被裁，用户完全看不到）。
      position:sticky + bottom:0 让它永远贴在消息区可视底部 —— 无论内容多长都不用滚去找。 */
.faichat-cta {
  display: block; width: 100%; margin-top: 10px; padding: 11px 14px;
  border: 0; border-radius: 10px; cursor: pointer; text-align: left;
  background: linear-gradient(135deg, var(--brand, #1A55C2), #2E6FD9); color: #fff;
  font: 600 13.5px/1.4 var(--f-body, inherit);
  box-shadow: 0 6px 16px -6px rgba(26, 85, 194, .55);
  transition: transform .15s ease, box-shadow .15s ease;
  /* 吸底：父级 .faichat-msgs 是滚动容器，sticky 在其中生效 */
  position: sticky; bottom: 0; z-index: 2;
  /* 贴底时加一层同底色衬底，避免下缘内容从按钮下方透出 */
  box-shadow: 0 -6px 14px -4px rgba(255, 255, 255, .92), 0 6px 16px -6px rgba(26, 85, 194, .55);
}
.faichat-cta:hover { transform: translateY(-1px); box-shadow: 0 -6px 14px -4px rgba(255, 255, 255, .92), 0 10px 22px -8px rgba(26, 85, 194, .65); }
.faichat-cta small { display: block; font: 400 11px/1.5 var(--f-body, inherit); opacity: .86; margin-top: 2px; }

/* 确认卡（2026-10-03）：解析结果回给客户点「正确 / 错误」
   🔴 推断字段一律标黄 —— 城市名→代表邮编、判定住宅、判定不需要尾板，这三项都会改钱，
      客户扫一眼黄条就能发现不对，别指望他会逐行读。 */
.faichat-confirm {
  margin-top: 8px; border: 1px solid var(--line, #E2E8F2); border-radius: 10px;
  background: var(--surface-2, #F7F9FD); overflow: hidden;
}
.faichat-cf-row {
  display: flex; align-items: center; gap: 8px; padding: 8px 11px;
  font: 400 12.5px/1.5 var(--f-body, inherit);
  border-top: 1px solid var(--line, #E2E8F2);
}
.faichat-cf-row:first-child { border-top: 0; }
.faichat-cf-k { flex: 0 0 62px; color: var(--muted-2, #8B9CB8); }
.faichat-cf-v { flex: 1 1 auto; font-weight: 500; color: var(--ink, #16233D); word-break: break-word; }
.faichat-cf-tag {
  flex: none; padding: 1px 6px; border-radius: 999px;
  background: #FFF4E0; color: #8A5300; font: 500 10.5px/1.6 var(--f-body, inherit);
}
.faichat-cf-row.is-inferred { background: #FFFBEF; }
.faichat-cf-actions { display: flex; gap: 8px; margin-top: 10px; }
.faichat-cf-actions button {
  flex: 1 1 auto; padding: 9px 10px; border-radius: 9px; cursor: pointer;
  font: 500 13px/1.4 var(--f-body, inherit); transition: opacity .15s ease;
}
.faichat-cf-actions button:disabled { opacity: .5; cursor: default; }
.faichat-cf-ok {
  flex: 1.4 1 auto; border: 0; color: #fff;
  background: linear-gradient(135deg, var(--brand, #1A55C2), #2E6FD9);
}
.faichat-cf-no { border: 1px solid var(--brand, #1A55C2); background: #fff; color: var(--brand, #1A55C2); }
.faichat-cf-reset { border: 1px solid var(--line, #E2E8F2); background: #fff; color: var(--muted-2, #8B9CB8); }
@media (max-width: 400px) {
  .faichat-cf-actions { flex-wrap: wrap; }
  .faichat-cf-ok { flex: 1 1 100%; }
}

/* ============ 确认卡 · 可编辑表单版（2026-10-06） ============
   旧版（.faichat-confirm / .faichat-cf-row）是**静态文本行**，客户看错只能回输入框重打字。
   新版每项都是真 input / switch，点「确认无误，出价」把**修改后的值**回传服务端再算价。
   🔴 本卡是防价格事故的最后一道闸：78 倍重量事故就是绕过旧卡（needsConfirmOf 只拦推断字段）
      一路算到付款的。所以「总重（整票）」必须写明口径 + 密度异常红色告警。 */
.faichat-cf-form {
  margin-top: 8px; border: 1px solid var(--brand, #1A55C2); border-radius: 12px;
  background: var(--surface, #fff); overflow: hidden;
}
.faichat-cf-fhead {
  display: flex; align-items: center; gap: 7px;
  padding: 9px 13px; background: #EEF3FB; color: var(--brand, #1A55C2);
  font: 500 13px/1.5 var(--f-body, inherit);
}
.faichat-cf-fhead span { font-weight: 500; }
.faichat-cf-fhead em {
  margin-left: auto; font: 400 11px/1.5 var(--f-body, inherit);
  font-style: normal; color: var(--muted-2, #8B9CB8);
}
.faichat-cf-fbody { padding: 13px; display: flex; flex-direction: column; gap: 13px; }

/* 字段：标签在上、输入框在下 */
.faichat-cf-fld { display: flex; flex-direction: column; gap: 5px; min-width: 0; }
.faichat-cf-fld > label, .faichat-cf-lab {
  font: 400 12px/1.5 var(--f-body, inherit); color: var(--muted, #5A6B85);
}
.faichat-cf-fld > label i {
  font-style: normal; color: var(--muted-2, #8B9CB8); font-size: 11px; margin-left: 3px;
}
.faichat-cf-labrow { display: flex; align-items: center; gap: 6px; }
.faichat-cf-labrow > label { font: 400 12px/1.5 var(--f-body, inherit); color: var(--muted, #5A6B85); }
.faichat-cf-badge {
  padding: 0 5px; border-radius: 4px; background: #FFF4E0; color: #8A5300;
  font: 500 11px/1.6 var(--f-body, inherit);
}
.faichat-cf-hint { margin: 0; font: 400 11px/1.5 var(--f-body, inherit); color: var(--muted-2, #8B9CB8); }

/* 输入框 + 单位后缀 */
.faichat-cf-inwrap { display: flex; align-items: center; gap: 7px; }
.faichat-cf-inwrap input {
  flex: 1 1 auto; min-width: 0; width: 100%;
  padding: 8px 10px; border: 1px solid var(--line, #E2E8F2); border-radius: 8px;
  background: #fff; color: var(--ink, #16233D);
  font: 400 14px/1.4 var(--f-body, inherit);
  transition: border-color .15s ease;
}
.faichat-cf-inwrap input:focus {
  outline: none; border-color: var(--brand, #1A55C2);
  box-shadow: 0 0 0 3px rgba(26, 85, 194, .12);
}
.faichat-cf-unit { flex: none; font: 400 12px/1.5 var(--f-body, inherit); color: var(--muted-2, #8B9CB8); }

/* 体积：总体积 / 单件尺寸 二选一 */
.faichat-cf-tabs { display: flex; gap: 5px; }
.faichat-cf-tab {
  flex: 1 1 auto; padding: 6px 4px; cursor: pointer;
  border: 1px solid var(--line, #E2E8F2); border-radius: 8px; background: #fff;
  color: var(--muted-2, #8B9CB8); font: 400 12px/1.4 var(--f-body, inherit);
  transition: all .15s ease;
}
.faichat-cf-tab.is-on {
  border-color: var(--brand, #1A55C2); background: #EEF3FB; color: var(--brand, #1A55C2);
  font-weight: 500;
}
.faichat-cf-dims { display: flex; gap: 6px; }
.faichat-cf-dims input {
  width: 33%; min-width: 0; padding: 8px 6px; text-align: center;
  border: 1px solid var(--line, #E2E8F2); border-radius: 8px; background: #fff;
  color: var(--ink, #16233D); font: 400 14px/1.4 var(--f-body, inherit);
}
.faichat-cf-dims input:focus {
  outline: none; border-color: var(--brand, #1A55C2);
  box-shadow: 0 0 0 3px rgba(26, 85, 194, .12);
}
.faichat-cf-dims input::placeholder { color: var(--muted-2, #8B9CB8); font-size: 13px; }

/* 件数 + 品名 并排 */
.faichat-cf-frow { display: flex; gap: 9px; }
.faichat-cf-frow > .faichat-cf-fld { flex: 1 1 0; }
.faichat-cf-frow input {
  width: 100%; padding: 8px 10px; border: 1px solid var(--line, #E2E8F2); border-radius: 8px;
  background: #fff; color: var(--ink, #16233D); font: 400 14px/1.4 var(--f-body, inherit);
}
.faichat-cf-frow input:focus {
  outline: none; border-color: var(--brand, #1A55C2);
  box-shadow: 0 0 0 3px rgba(26, 85, 194, .12);
}

/* 住宅 / 尾板 开关 */
.faichat-cf-fopts {
  display: flex; flex-direction: column; gap: 11px;
  border-top: 1px solid var(--line, #E2E8F2); padding-top: 12px;
}
.faichat-cf-fopt { display: flex; align-items: center; gap: 10px; }
.faichat-cf-fopt-tx { flex: 1 1 auto; min-width: 0; }
.faichat-cf-fopt-tx p { margin: 0; font: 400 13px/1.5 var(--f-body, inherit); color: var(--ink, #16233D); }
.faichat-cf-sw {
  flex: none; position: relative; width: 40px; height: 24px; cursor: pointer;
  border: 1px solid var(--line, #E2E8F2); border-radius: 999px;
  background: #EDF1F7; transition: all .15s ease; padding: 0;
}
.faichat-cf-sw i {
  position: absolute; top: 3px; left: 2px; width: 18px; height: 18px; border-radius: 50%;
  background: #fff; transition: left .15s ease;
}
.faichat-cf-sw.is-on { background: #D6E4F8; border-color: rgba(26, 85, 194, .45); }
.faichat-cf-sw.is-on i { left: 20px; }

/* 重量口径异常告警（密度过高 / 平均每件过轻） */
.faichat-cf-warn {
  padding: 8px 11px; border-radius: 8px;
  background: #FDEEEE; color: #9A2B2B; font: 400 12px/1.55 var(--f-body, inherit);
}

/* 唯一主按钮 */
.faichat-cf-go {
  width: 100%; padding: 11px 0; cursor: pointer;
  border: 0; border-radius: 9px; color: #fff;
  background: linear-gradient(135deg, var(--brand, #1A55C2), #2E6FD9);
  font: 500 14px/1.4 var(--f-body, inherit);
  transition: opacity .15s ease;
}
.faichat-cf-go:disabled { opacity: .55; cursor: default; }

@media (max-width: 400px) {
  .faichat-cf-frow { flex-wrap: wrap; }
  .faichat-cf-frow > .faichat-cf-fld { flex: 1 1 100%; }
}

/* 完整报价浮层：层级取全站最高（同 .qdock-tail-modal 铁律） */
.faichat-full {
  position: fixed; inset: 0; z-index: 2147483647;
  display: flex; align-items: center; justify-content: center; padding: 20px;
}
.faichat-full-mask { position: absolute; inset: 0; background: rgba(15, 23, 42, .55); }
/* ⚠ 滚动方案直接照搬首页「立即报价结果」弹窗（source-design.css:1483）：
   滚动条挂在 box 上（overflow:auto），内层 qdock 一律 display:block + height:auto + overflow:visible。
   之前我反其道在内部造 flex 高度链 + overflow-y:auto，被 .qdock.qdock-inline 的既有规则压掉，滚动条不出现。 */
.faichat-full-box {
  position: relative;
  width: min(720px, 100%); max-height: min(90vh, 900px);
  overflow: auto; -webkit-overflow-scrolling: touch; overscroll-behavior: contain;
  background: #fff; border-radius: 16px;
  box-shadow: 0 28px 70px -14px rgba(0, 0, 0, .38);
  font-family: system-ui, -apple-system, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  color: #1f2937;
}
.faichat-full-hd {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 13px 16px; color: #fff; background: linear-gradient(135deg, #061738, #12315F);
}
/* 吸顶职责上移到 .faichat-full-top（10-02），标题栏自身不再 sticky，否则两层各吸一次会错位 */
.faichat-full-hd { position: static; }
.faichat-full-hd h3 { font: 700 15px/1.3 var(--f-display, inherit); }
.faichat-full-hd p { font-size: 11.5px; color: #7FB2F5; margin-top: 2px; }
/* 标题栏 + 尾程比价常驻入口 = 一个吸顶整体（10-02）
   ⚠ 千万别给 .faichat-full-tail 写死 top:57px —— 标题栏高度随副标题换行变化（浏览器实测 66px），
     写死就会在入口与标题栏之间露一条缝，内容从缝里穿过去。整块吸顶天然对齐，无需算高度。 */
.faichat-full-top {
  position: sticky; top: 0; z-index: 3;
}
/* 入口条本体样式不在这里写 —— 复用 quote-dock.css 的 .qdock-tail-bar / .qdock-tail-btn，
   保证与主页那条完全同款（同一份 tailBarHtml 生成的 HTML）。 */
.faichat-full-tail { margin: 0; border-radius: 0; }
@supports not (position: sticky) { .faichat-full-top { position: static; } }
.faichat-full-x {
  flex: none; border: 0; background: rgba(255, 255, 255, .16); color: #fff;
  width: 30px; height: 30px; border-radius: 50%; font-size: 20px; line-height: 1; cursor: pointer;
}
.faichat-full-x:hover { background: rgba(255, 255, 255, .28); }
/* 结果区：用 qdock 组件的类名以复用其全部样式。高度由内容决定，不做内层滚动。 */
.faichat-full-body { background: #f5f7fa; }
.faichat-full-foot {
  padding: 9px 16px; font-size: 11px; line-height: 1.5;
  color: var(--muted-2, #8B9CB8); background: #fff; border-top: 1px solid var(--line, #D9E4F2);
}
/* 照搬首页 :1492 的做法：弹窗内 qdock 完全放开，高度由内容决定 */
.faichat-full-body .qdock {
  position: static; transform: none; right: auto; bottom: auto;
  width: auto; height: auto; max-height: none; min-height: 0;
  display: block; overflow: visible;
  box-shadow: none; border-radius: 0; padding: 0; margin: 0;
  background: transparent;
}
.faichat-full-body .qdock.qdock-inline:not(.is-open) { display: none; }
.faichat-full-body .qdock.qdock-inline .qdock-scroll {
  padding: 0; background: transparent; overflow: visible; flex: none;
}
.faichat-full-body .qdock.qdock-inline .qdock-result-scroll { overflow: visible; }
.faichat-full-body .qdock .qdock-quote { transform: none; }
@media (max-width: 640px) { .faichat-full { padding: 0; } .faichat-full-box { max-height: 100vh; height: 100vh; border-radius: 0; } }
@keyframes faichat-blink { 0%, 60%, 100% { opacity: .25; } 30% { opacity: 1; } }

@media (max-width: 640px) {
  .faichat-launcher { right: 14px; bottom: 14px; padding: 10px 15px 10px 12px; }
  /* 窄屏：10-06 由 78vh 提到 88vh（与桌面 +25% 同向），少留底部空隙 */
  .faichat { right: 12px; left: 12px; bottom: 12px; width: auto; height: 88vh; }
  .faichat-launcher-txt { display: none; }
}

/* ---------- 2026-10-04：缺失要素醒目清单（问答路由 needDest/needGoods） ---------- */
.faichat-missing {
  margin-top: 9px; padding: 10px 12px;
  background: #FFFBEF; border: 1px solid #F0C36D; border-left: 4px solid #E8A200;
  border-radius: 8px;
}
.faichat-missing-t { font-size: 12.5px; font-weight: 700; color: #996800; margin-bottom: 6px; }
.faichat-missing ul { margin: 0; padding-left: 18px; }
.faichat-missing li { font-size: 12.5px; line-height: 1.75; color: #6B4E00; }
.faichat-missing li::marker { color: #E8A200; }
