/* ===== 智学研途 · 计划对话面板 =====
   蓝白教育科技风，沿用全站的 --blue / --line。
   只在「备考计划」子页里出现，宽度跟着面板走，不另设容器宽度。 */

.pc-panel {
  margin: 0 0 14px;
  border: 1px solid var(--line, #e3eaf3);
  border-radius: 12px;
  background: #fff;
  overflow: hidden;
}

.pc-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  padding: 13px 16px;
  background: linear-gradient(180deg, #f6fbff, #fff);
  border-bottom: 1px solid #eef3f9;
}
.pc-head-main h4 {
  margin: 0 0 3px;
  font-size: 14px;
  color: #16273d;
  font-weight: 700;
}
.pc-sub {
  margin: 0;
  font-size: 11.5px;
  color: #7d8ca1;
  line-height: 1.6;
}
.pc-sub b { color: #2f6fd0; font-weight: 600; }
.pc-badge {
  flex: 0 0 auto;
  font-size: 10.5px;
  color: #2f6fd0;
  background: #eaf3ff;
  border: 1px solid #d5e6fb;
  border-radius: 20px;
  padding: 2px 9px;
  white-space: nowrap;
}

/* ---- 消息流 ---- */

.pc-log {
  max-height: 600px;
  overflow-y: auto;
  padding: 14px 16px 6px;
  background: #fbfdff;
}
.pc-msg { display: flex; gap: 8px; margin-bottom: 12px; }
.pc-me { justify-content: flex-end; }
.pc-ai { align-items: flex-start; }

.pc-dot {
  flex: 0 0 auto;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: #eaf3ff;
  color: #2f6fd0;
  font-size: 10px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 2px;
}
.pc-body { min-width: 0; max-width: 84%; }

.pc-bubble {
  padding: 9px 12px;
  border-radius: 12px;
  font-size: 13px;
  line-height: 1.7;
  white-space: pre-wrap;
  word-break: break-word;
}
.pc-me .pc-bubble {
  background: var(--blue, #2563eb);
  color: #fff;
  border-bottom-right-radius: 4px;
  max-width: 78%;
}
.pc-ai .pc-bubble {
  background: #fff;
  border: 1px solid #e3eaf3;
  color: #23384f;
  border-bottom-left-radius: 4px;
}

/* ---- 空状态 ---- */

.pc-empty { padding: 6px 2px 10px; font-size: 12.5px; color: #6b7b90; }
.pc-empty p { margin: 0 0 6px; }
.pc-empty ul { margin: 0 0 8px; padding-left: 18px; }
.pc-empty li { margin-bottom: 3px; line-height: 1.6; }
.pc-empty-note { font-size: 11.5px; color: #93a1b4; line-height: 1.6; }

/* ---- 结果卡 ---- */

.pc-card {
  margin-top: 8px;
  border: 1px solid #dfeaf6;
  border-radius: 10px;
  background: #fff;
  padding: 10px 12px;
  font-size: 12.5px;
  color: #2b3d52;
}
.pc-card-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  margin-bottom: 4px;
}
.pc-card-head strong { font-size: 12.5px; color: #16273d; }
.pc-card-tag {
  flex: 0 0 auto;
  font-size: 10px;
  color: #fff;
  background: #2f6fd0;
  border-radius: 20px;
  padding: 1px 8px;
}
.pc-card.is-error { border-color: #f0c9c9; background: #fffafa; }
.pc-card.is-error .pc-card-tag { background: #cf4b4b; }
.pc-card.is-info { border-color: #f0dfb8; background: #fffdf6; }
.pc-card.is-info .pc-card-tag { background: #b8892a; }

.pc-card-msg { margin: 4px 0 6px; line-height: 1.65; color: #4a5c72; }

.pc-changes { margin: 4px 0 6px; padding-left: 18px; }
.pc-changes li { line-height: 1.65; margin-bottom: 2px; }

.pc-touched { margin: 4px 0 6px; font-size: 12px; }
.pc-touched summary {
  cursor: pointer;
  color: #2f6fd0;
  list-style: none;
  outline: none;
}
.pc-touched summary::-webkit-details-marker { display: none; }
.pc-touched summary span { color: #93a1b4; font-size: 11px; }
.pc-touched ul { margin: 5px 0 0; padding-left: 18px; color: #5b6b80; }
.pc-touched li { line-height: 1.6; }

/* 差异表：改没改一眼能看出来，改动的行右侧加蓝 */
.pc-diff { margin: 6px 0; overflow-x: auto; }
.pc-diff table { width: 100%; border-collapse: collapse; font-size: 12px; }
.pc-diff th,
.pc-diff td {
  padding: 4px 6px;
  border-bottom: 1px dashed #eef3f9;
  text-align: left;
  white-space: nowrap;
}
.pc-diff thead th { color: #93a1b4; font-weight: 500; font-size: 11px; }
.pc-diff tbody th { color: #6b7b90; font-weight: 400; }
.pc-diff tr.is-changed td:last-child { color: #1f6feb; font-weight: 700; }
.pc-diff tr.is-changed td:nth-child(2) { color: #93a1b4; }

.pc-notes {
  margin: 6px 0 0;
  padding-left: 18px;
  color: #8a6d3b;
  background: #fffdf6;
  border-radius: 6px;
  padding-top: 6px;
  padding-bottom: 6px;
  font-size: 11.5px;
}
.pc-notes li { line-height: 1.6; }

.pc-synced { margin: 6px 0 0; font-size: 11px; color: #93a1b4; }

.pc-card-foot {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 8px;
  padding-top: 8px;
  border-top: 1px dashed #eef3f9;
}
.pc-mini {
  font-size: 11.5px;
  color: #2f6fd0;
  background: #f4f9ff;
  border: 1px solid #d9e8fa;
  border-radius: 6px;
  padding: 4px 10px;
  cursor: pointer;
}
.pc-mini:hover { background: #eaf3ff; }

/* ---- 快捷话术 ---- */

.pc-quick {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  padding: 0 16px 8px;
  background: #fbfdff;
}
.pc-chip {
  font-size: 11.5px;
  color: #4a6b96;
  background: #fff;
  border: 1px solid #dfe9f6;
  border-radius: 20px;
  padding: 4px 11px;
  cursor: pointer;
}
.pc-chip:hover { border-color: #b9d4f5; background: #f6fbff; color: #2f6fd0; }

/* ---- 输入 ---- */

.pc-form {
  display: flex;
  gap: 8px;
  align-items: flex-end;
  padding: 10px 16px 4px;
  border-top: 1px solid #eef3f9;
  background: #fff;
}
.pc-form textarea {
  flex: 1 1 auto;
  min-height: 46px;
  max-height: 120px;
  resize: vertical;
  border: 1px solid #dfe9f6;
  border-radius: 8px;
  padding: 8px 10px;
  font-size: 13px;
  line-height: 1.6;
  color: #23384f;
  font-family: inherit;
  outline: none;
}
.pc-form textarea:focus { border-color: #9cc4f0; box-shadow: 0 0 0 3px rgba(47, 111, 208, .08); }
.pc-form textarea:disabled { background: #f6f9fc; color: #9aa8bd; }
.pc-send { flex: 0 0 auto; height: 38px; padding: 0 18px; }
.pc-send:disabled { opacity: .6; cursor: default; }

.pc-note {
  padding: 4px 16px 12px;
  font-size: 11px;
  color: #9aa8bd;
  line-height: 1.6;
  background: #fff;
}

.pc-fatal {
  margin: 12px 0;
  padding: 10px 12px;
  border: 1px solid #f0dfb8;
  background: #fffdf6;
  border-radius: 8px;
  font-size: 12.5px;
  color: #8a6d3b;
  line-height: 1.65;
}

/* ---- 窄屏 ---- */

@media (max-width: 640px) {
  .pc-head { flex-direction: column; gap: 6px; padding: 11px 12px; }
  .pc-log { padding: 12px 12px 4px; max-height: 440px; }
  .pc-body { max-width: 100%; }
  .pc-me .pc-bubble { max-width: 88%; }
  .pc-quick { padding: 0 12px 8px; }
  .pc-form { padding: 8px 12px 4px; flex-direction: column; align-items: stretch; }
  .pc-send { width: 100%; }
  .pc-note { padding: 4px 12px 10px; }
  .pc-diff table { font-size: 11px; }
  .pc-diff th,
  .pc-diff td { padding: 3px 4px; }
  .pc-card-foot { gap: 6px; }
  .pc-mini { flex: 1 1 auto; text-align: center; }
}
