/* 智能问数 · 叠在 Homory 设计语言上 */
:root, .m-app, .chat-stage {
  --hoso-bg: #ffffff;
  --hoso-text: #0b0f19;
  --hoso-text-muted: #64748b;
  --hoso-surface: #ffffff;
  --hoso-surface-subtle: #f1f5f9;
  --hoso-card-border: rgba(15, 23, 42, 0.08);
  --hoso-link: #2563eb;
}

.layout-app { height: 100vh; overflow: hidden; }
.page-content--fill { flex: 1; min-height: 0; display: flex; flex-direction: column; padding: 0; }
.page-fill-inner { flex: 1; min-height: 0; display: flex; flex-direction: column; }

.icon-img {
  width: 18px;
  height: 18px;
  display: block;
  flex-shrink: 0;
  object-fit: contain;
}
.nav-item {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  border: 0;
  background: transparent;
  font: inherit;
  text-align: left;
  cursor: pointer;
}
.nav-item .icon-img { opacity: .9; }
.nav-item.active .icon-img { filter: none; }

.ws-topbar-tools {
  display: flex;
  align-items: center;
  gap: 10px;
}
.mode-dd {
  position: relative;
  flex-shrink: 0;
}
.mode-dd-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 36px;
  padding: 0 10px 0 8px;
  border: 0;
  border-radius: 999px;
  background: #eef0f3;
  color: var(--td-text-color-primary);
  font: inherit;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  white-space: nowrap;
}
.mode-dd-btn:hover,
.mode-dd.open .mode-dd-btn { background: #e4e6ea; }
.mode-dd-icon,
.mode-dd-chevron {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #4e5969;
}
.mode-dd-icon svg,
.mode-dd-item svg { display: block; }
.mode-dd-chevron { transition: transform .15s ease; }
.mode-dd.open .mode-dd-chevron { transform: rotate(180deg); }
.mode-dd-menu {
  display: none;
  position: absolute;
  left: 0;
  bottom: calc(100% + 8px);
  min-width: 168px;
  padding: 4px;
  background: #fff;
  border: 1px solid var(--td-border-color);
  border-radius: 12px;
  box-shadow: 0 10px 28px rgba(15, 23, 42, .12);
  z-index: 40;
}
.mode-dd.open .mode-dd-menu { display: block; }
.mode-dd-item {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  border: 0;
  background: transparent;
  padding: 8px 10px;
  border-radius: 8px;
  font: inherit;
  font-size: 13px;
  color: var(--td-text-color-primary);
  cursor: pointer;
  text-align: left;
}
.mode-dd-item:hover { background: #f5f6f8; }
.mode-dd-item.on { background: #f2f3f5; }
.mode-dd-item .mode-dd-check {
  margin-left: auto;
  opacity: 0;
  color: var(--td-text-color-primary);
}
.mode-dd-item.on .mode-dd-check { opacity: 1; }

.chat-stage {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  background: var(--td-bg-color-page);
}
.chat-list {
  flex: 1;
  overflow-y: auto;
  padding: 20px 8% 16px;
}
.chat-list .msg,
.m-list .msg {
  max-width: 720px;
  margin: 8px auto 0;
}
.msg.user + .msg.assistant { margin-top: 6px; }
.msg:first-child { margin-top: 0; }
.msg.assistant {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 6px;
}
.msg.assistant .bubble {
  padding: 0;
  background: transparent;
  box-shadow: none;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.msg.assistant .msg-text { font-size: 14px; line-height: 1.65; }
.msg-actions {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-top: 2px;
}
.msg-act {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  height: 28px;
  padding: 0 8px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--td-text-color-placeholder);
  font: inherit;
  font-size: 12px;
  cursor: pointer;
}
.msg-act:hover { background: #eef0f3; color: var(--td-text-color-secondary); }
.msg-act.on { color: #e34d59; background: #fdecee; }
.msg-act svg { display: block; width: 16px; height: 16px; }

.fb-modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: none;
  align-items: flex-end;
  justify-content: center;
  background: rgba(15, 23, 42, .4);
  padding: 12px 12px calc(12px + env(safe-area-inset-bottom));
}
.fb-modal-backdrop.open { display: flex; }
.fb-modal {
  width: 100%;
  max-width: 480px;
  max-height: min(86vh, 640px);
  overflow: auto;
  background: #fff;
  border-radius: 16px 16px 12px 12px;
  box-shadow: 0 16px 40px rgba(15, 23, 42, .18);
}
.fb-modal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 16px 10px;
  border-bottom: 1px solid var(--td-border-color);
}
.fb-modal-head h3 { margin: 0; font-size: 16px; }
.fb-close {
  border: 0;
  background: transparent;
  font-size: 22px;
  line-height: 1;
  color: var(--td-text-color-placeholder);
  cursor: pointer;
  padding: 0 4px;
}
.fb-modal-body { padding: 12px 16px 8px; }
.fb-block { margin-bottom: 12px; }
.fb-k {
  font-size: 12px;
  color: var(--td-text-color-placeholder);
  margin-bottom: 4px;
}
.fb-v {
  font-size: 13px;
  line-height: 1.55;
  color: var(--td-text-color-primary);
  background: #f7f8fa;
  border-radius: 8px;
  padding: 8px 10px;
  white-space: pre-wrap;
  word-break: break-word;
}
.fb-comment {
  width: 100%;
  border: 1px solid var(--td-border-color);
  border-radius: 8px;
  padding: 8px 10px;
  font: inherit;
  font-size: 13px;
  resize: vertical;
  min-height: 72px;
}
.fb-comment:focus {
  outline: none;
  border-color: var(--td-brand-color);
  box-shadow: 0 0 0 2px rgba(0, 82, 217, .12);
}
.fb-modal-foot {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  padding: 10px 16px 14px;
}
@media (min-width: 768px) {
  .fb-modal-backdrop { align-items: center; }
  .fb-modal { border-radius: 12px; }
}

.composer-dock {
  padding: 8px 8% 20px;
  background: linear-gradient(180deg, rgba(245,247,250,0), var(--td-bg-color-page) 28%);
  overflow: visible;
}
.hoso-search-bar.ws-bar {
  max-width: 720px;
  margin: 0 auto;
  padding-left: 8px;
  overflow: visible;
}
.hoso-search-bar .mode-dd-btn {
  height: 32px;
  background: #f2f3f5;
}

/* 消息动效 */
.msg-enter {
  animation: msg-in .28s ease;
}
@keyframes msg-in {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: none; }
}
.msg.assistant .bubble { color: var(--td-text-color-primary); }
.msg.user { display: flex; justify-content: flex-end; }
.msg.user .bubble {
  background: var(--td-brand-color);
  color: #fff;
  border-radius: 16px 16px 4px 16px;
  padding: 10px 14px;
  font-size: 14px;
  line-height: 1.55;
  box-shadow: 0 6px 16px rgba(0,82,217,.18);
}

.steps {
  width: 100%;
  align-self: flex-start;
  background: #fff;
  border: 1px solid var(--td-border-color);
  border-radius: 10px;
  padding: 6px 12px;
  margin: 0;
  font-size: 12px;
  color: var(--td-text-color-secondary);
  transition: width .2s ease;
}
.steps.is-collapsed,
.steps:not(:has(details[open])) {
  width: 50%;
  max-width: 50%;
}
.steps summary {
  cursor: pointer;
  color: var(--td-text-color-placeholder);
  list-style: none;
  display: flex;
  align-items: center;
  gap: 6px;
  line-height: 1.4;
  white-space: nowrap;
}
.steps summary::-webkit-details-marker { display: none; }
.steps summary::before {
  content: '';
  width: 0;
  height: 0;
  border-left: 4px solid transparent;
  border-right: 4px solid transparent;
  border-top: 5px solid currentColor;
  transform: rotate(-90deg);
  transition: transform .15s ease;
}
.steps details[open] > summary::before { transform: none; }
.steps details div { margin-top: 6px; }

.widget {
  background: #fff;
  border: 1px solid var(--td-border-color);
  border-radius: 12px;
  padding: 14px 16px;
  margin: 0;
  box-shadow: var(--td-shadow-1);
  animation: msg-in .32s ease;
}
.widget h4 { margin: 0 0 6px; font-size: 15px; }
.widget p { margin: 0 0 10px; font-size: 13px; color: var(--td-text-color-secondary); line-height: 1.55; }
.widget.permission { background: #fdecee; border-color: #f9d7d9; }
.widget.permission h4 { color: #e34d59; }

.admin-page {
  flex: 1;
  min-height: 0;
  overflow: hidden;
  padding: 0;
  display: flex;
  flex-direction: column;
}
.admin-static { padding: 24px 28px 40px; overflow: auto; flex: 1; }
.admin-static h3 { margin: 0 0 6px; font-size: 20px; }
.admin-page .page-desc { margin: 6px 0 0; color: var(--td-text-color-secondary); font-size: 13px; line-height: 1.55; max-width: 720px; }
.admin-static .page-desc { margin-bottom: 20px; }
.api-bind .form-row { max-width: 560px; }
.list-page-head-actions .btn { display: inline-flex; align-items: center; gap: 6px; }
.page-title-tip { width: 16px; height: 16px; opacity: .4; }
button.lx-segment-item {
  border: 0;
  background: transparent;
  font: inherit;
  cursor: pointer;
  line-height: 1.4;
}
.row-actions { display: flex; gap: 8px; white-space: nowrap; }
button.list-page-btn,
button.list-page-num,
button.list-page-size {
  border: 0;
  font: inherit;
  cursor: pointer;
  background: transparent;
}
.list-page-btn .icon,
.list-page-btn .icon-sm {
  width: 16px;
  height: 16px;
  display: block;
}
.modal { max-height: calc(100vh - 48px); overflow: auto; }
#crudModal .textarea { min-height: 88px; }
.bind-banner {
  background: #fff;
  border: 1px solid var(--td-border-color);
  border-radius: var(--radius-default);
  padding: 14px 16px;
  margin-bottom: 12px;
  flex-shrink: 0;
}
.bind-banner-title { font-weight: 600; margin-bottom: 4px; }
.job-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 12px;
  flex-shrink: 0;
}
.job-stat {
  background: #fff;
  border: 1px solid var(--td-border-color);
  border-radius: var(--radius-default);
  padding: 12px 14px;
}
.job-stat-label { font-size: 12px; color: var(--td-text-color-secondary); margin-bottom: 4px; }
.job-stat-value { font-size: 20px; font-weight: 600; }
.job-stat-span { font-size: 14px; font-weight: 600; line-height: 1.4; }
.job-name { font-weight: 600; }
.job-run { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.job-run .input { width: auto; height: 32px; min-width: 0; }
.job-run .job-days { width: 64px; }
.job-check { display: inline-flex; align-items: center; gap: 4px; font-size: 12px; color: var(--td-text-color-secondary); white-space: nowrap; }
.job-cron-hint { margin: 12px 0 8px; max-width: none; }
.job-cron-hint code, .list-table code { font-size: 12px; }
.job-log-title { font-size: 15px; font-weight: 600; margin: 16px 0 8px; flex-shrink: 0; }
.job-page { overflow: auto; }
.job-page .list-panel { flex: 0 0 auto; }
@media (max-width: 900px) {
  .job-stats { grid-template-columns: 1fr 1fr; }
}
.bind-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 4px 16px; }
.protocol-cards { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.protocol-card {
  display: flex; flex-direction: column; gap: 4px;
  border: 1px solid var(--td-border-color);
  border-radius: 10px; padding: 12px 14px; cursor: pointer;
}
.protocol-card b { font-size: 14px; }
.protocol-card span { font-size: 12px; color: var(--td-text-color-secondary); }
.protocol-card.is-on { border-color: var(--td-brand-color); background: var(--td-brand-color-light); }
.protocol-card input { accent-color: var(--td-brand-color); }
.prod-check { margin: 8px 0 0; align-items: flex-start; }
.prod-check span { line-height: 1.5; }
.widget-studio {
  flex: 1; min-height: 0;
  display: grid; grid-template-columns: 240px 1fr;
  overflow: hidden;
}
.widget-nav {
  border-right: 1px solid var(--td-border-color);
  overflow: auto; padding: 12px;
  background: #fff;
}
.widget-nav-item {
  display: flex; flex-direction: column; align-items: flex-start; gap: 2px;
  width: 100%; border: 0; background: transparent;
  text-align: left; padding: 10px 12px; border-radius: 8px;
  cursor: pointer; font: inherit; margin-bottom: 4px;
}
.widget-nav-item code { font-size: 11px; color: var(--td-brand-color); }
.widget-nav-item span { font-size: 12px; color: var(--td-text-color-secondary); }
.widget-nav-item:hover { background: #f5f7fb; }
.widget-nav-item.is-on { background: var(--td-brand-color-light); }
.widget-main { overflow: auto; padding: 20px 28px 40px; }
.widget-preview-head {
  margin: 16px 0 8px; font-size: 12px; color: var(--td-text-color-secondary);
}
.widget-preview-stage {
  max-width: 560px; background: var(--td-bg-color-page);
  border: 1px dashed var(--td-border-color);
  border-radius: 12px; padding: 16px;
}
.widget-json {
  max-width: 720px; background: #1e1e1e; color: #d4d4d4;
  padding: 14px; border-radius: 8px; overflow: auto; font-size: 12px;
}
.widget-sql-wrap { margin-top: 10px; }
.widget-sql-wrap summary {
  cursor: pointer; font-size: 12px; color: var(--td-text-color-secondary, #666);
  margin-bottom: 6px;
}
.widget-sql {
  margin: 0; padding: 10px 12px; border-radius: 8px;
  background: #1e1e1e; color: #d4d4d4; font-size: 11px;
  overflow: auto; white-space: pre-wrap; word-break: break-word;
}
.progress-bar {
  height: 6px; border-radius: 99px; background: #eee; overflow: hidden; margin-top: 8px;
}
.progress-fill {
  display: block; height: 100%; width: 42%;
  background: var(--td-brand-color);
  animation: progress-slide 1.2s ease infinite;
}
@keyframes progress-slide {
  0% { transform: translateX(-80%); }
  100% { transform: translateX(220%); }
}
.hidden { display: none !important; }

/* 移动端 */
.m-app {
  max-width: 430px;
  margin: 0 auto;
  height: 100vh;
  height: 100dvh;
  background: var(--td-bg-color-page);
  display: flex;
  flex-direction: column;
  position: relative;
  overflow: hidden;
}
.m-watermark {
  position: absolute;
  inset: -20% -30%;
  z-index: 0;
  pointer-events: none;
  display: flex;
  flex-wrap: wrap;
  align-content: flex-start;
  gap: 132px 108px;
  padding: 72px 36px;
  transform: rotate(-24deg);
  opacity: .035;
  color: #1d2129;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: .04em;
  overflow: hidden;
  user-select: none;
  white-space: nowrap;
}
.m-watermark span { flex: none; }
.m-top {
  position: relative;
  z-index: 11;
  flex: none;
  background: rgba(255,255,255,.86);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--td-border-color);
  padding: 8px 12px 10px;
}
.m-top-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.m-brand {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 1;
  min-width: 0;
}
.m-brand-logo {
  width: 28px;
  height: 28px;
  flex-shrink: 0;
  display: block;
}
.m-top h1 { font-size: 16px; margin: 0; letter-spacing: -.02em; min-width: 0; }
.m-role {
  border: 1px solid var(--td-border-color);
  background: #fff;
  border-radius: 999px;
  height: 28px;
  padding: 0 8px;
  font-size: 11px;
  color: var(--td-text-color-secondary);
  max-width: 28vw;
  flex-shrink: 1;
}
.m-top-row .res-btn { flex-shrink: 0; }
.m-hint { font-size: 11px; color: var(--td-text-color-placeholder); margin-top: 6px; }

.m-landing {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 12px 24px calc(168px + env(safe-area-inset-bottom));
  position: relative;
  z-index: 1;
  text-align: center;
}
.m-hello-logo {
  width: min(196px, 56vw);
  height: auto;
  display: block;
  margin: 0 auto 16px;
}
.m-hello-text {
  margin: 0;
  max-width: 280px;
}
.m-hello-name {
  margin: 0 0 6px;
  color: #1d2129;
  font-size: 17px;
  font-weight: 600;
  line-height: 1.4;
}
.m-hello-sub {
  margin: 0;
  color: #4e5969;
  font-size: 14px;
  line-height: 1.7;
}
.m-card {
  position: relative;
  border-radius: 20px;
  overflow: hidden;
  border: 1px solid rgba(15, 23, 42, 0.06);
  background: #e9edfc;
  padding: 36px 18px 28px;
  text-align: center;
}
.m-card-shader {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(180deg, rgba(255,255,255,.55) 0%, rgba(255,255,255,0) 42%),
    radial-gradient(ellipse 70% 55% at 20% 100%, rgba(147,197,253,.75) 0%, transparent 70%),
    radial-gradient(ellipse 65% 50% at 80% 105%, rgba(96,165,250,.55) 0%, transparent 68%);
}
.m-card-shader::before,
.m-card-shader::after {
  content: '';
  position: absolute;
  border-radius: 50%;
  filter: blur(40px);
  opacity: .5;
  animation: hoso-shimmer 10s ease-in-out infinite alternate;
}
.m-card-shader::before {
  width: 55%; height: 45%; left: -8%; bottom: -18%;
  background: radial-gradient(circle, rgba(0,64,240,.28) 0%, transparent 70%);
}
.m-card-shader::after {
  width: 50%; height: 42%; right: -6%; bottom: -15%;
  background: radial-gradient(circle, rgba(99,141,255,.35) 0%, transparent 68%);
  animation-delay: -5s;
}
.m-card-inner { position: relative; z-index: 1; }
.m-card h2 {
  margin: 0 0 8px;
  font-size: 26px;
  font-weight: 500;
  letter-spacing: -.03em;
}
.m-card p { margin: 0; color: #64748b; font-size: 13px; line-height: 1.6; }

.m-list {
  flex: 1;
  overflow-y: auto;
  padding: 12px 14px calc(148px + env(safe-area-inset-bottom));
  position: relative;
  z-index: 1;
}
.m-list .msg { max-width: 100%; }

.m-dock {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 12;
  flex: none;
  padding: 36px 12px calc(10px + env(safe-area-inset-bottom));
  background: linear-gradient(180deg, rgba(245,247,250,0) 0%, rgba(245,247,250,.2) 48%, rgba(245,247,250,.55) 100%);
  border-top: 0;
  pointer-events: none;
  overflow: visible;
}
.m-composer {
  pointer-events: auto;
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 12px 12px 10px;
  background: rgba(255, 255, 255, 0.55);
  -webkit-backdrop-filter: blur(20px) saturate(1.6);
  backdrop-filter: blur(20px) saturate(1.6);
  border: 1px solid rgba(255, 255, 255, 0.62);
  border-radius: 24px;
  box-shadow:
    0 10px 32px rgba(15, 23, 42, 0.12),
    0 1px 2px rgba(15, 23, 42, 0.04);
  isolation: isolate;
  transform: translateZ(0);
}
.m-composer-row {
  display: flex;
  align-items: center;
  gap: 8px;
}
.m-composer-input {
  flex: 1;
  min-width: 0;
  border: 0;
  outline: none;
  background: transparent;
  font: inherit;
  font-size: 16px;
  line-height: 1.5;
  padding: 8px 4px;
  color: var(--td-text-color-primary);
}
.m-composer-input::placeholder {
  color: #94a3b8;
}
.m-skills {
  pointer-events: auto;
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding: 0 4px 10px;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}
.m-skills::-webkit-scrollbar { display: none; }
.is-chatting .m-skills { display: none; }
.m-skill {
  flex: none;
  height: 32px;
  padding: 0 12px;
  border: 1px solid rgba(15, 23, 42, 0.12);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.92);
  color: #4e5969;
  font: inherit;
  font-size: 13px;
  cursor: pointer;
  white-space: nowrap;
}
.m-skill:active { background: #f2f3f5; }
.m-app .mode-dd-btn {
  height: 32px;
  padding: 0 8px 0 6px;
  background: rgba(242, 244, 247, 0.9);
}
.m-composer-mic,
.m-composer .hoso-search-submit {
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  display: none;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}
.m-composer-mic {
  background: transparent;
  color: #1d2129;
  touch-action: none;
  -webkit-user-select: none;
  user-select: none;
}
.m-composer:not(.has-text) .m-composer-mic,
.m-composer.is-listening .m-composer-mic { display: inline-flex; }
.m-composer.has-text:not(.is-listening) .hoso-search-submit { display: inline-flex; }
.m-composer.is-listening .m-composer-mic { color: var(--td-brand-color); }
.m-composer-mic .mic-icon { display: inline-flex; line-height: 0; }
.m-composer-mic .spin { display: none; animation: hoso-spin .8s linear infinite; }
body.is-busy .m-composer-mic {
  display: inline-flex;
  color: var(--td-brand-color);
}
body.is-busy .m-composer-mic .mic-icon { display: none; }
body.is-busy .m-composer-mic .spin { display: block; }
body.is-busy .m-composer .hoso-search-submit { display: none; }
.m-composer .hoso-search-submit {
  background: var(--hoso-link);
  color: #fff;
}
.m-newchat {
  flex-shrink: 0;
  width: 32px;
  height: 32px;
  padding: 0;
  border-radius: 50%;
  border: 1px solid rgba(15, 23, 42, 0.12);
  background: #fff;
  color: #1d2129;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.m-dock .hoso-search-bar { box-shadow: none; }

.drawer-mask {
  display: none;
  position: absolute;
  inset: 0;
  background: rgba(15,23,42,.35);
  z-index: 20;
}
.drawer-mask.show { display: block; }
.drawer {
  position: absolute;
  top: 0; right: 0;
  width: 82%;
  height: 100%;
  background: #fff;
  z-index: 21;
  transform: translateX(100%);
  transition: transform .22s ease;
  padding: 18px 16px;
  overflow: auto;
}
.drawer.open { transform: none; }
.res-btn {
  border: 0;
  background: transparent;
  padding: 4px;
  border-radius: 8px;
  cursor: pointer;
  line-height: 0;
}
.res-btn:hover { background: var(--td-bg-color-secondarycontainer); }

body.is-busy .hoso-search-submit .arrow { display: none; }
body.is-busy .hoso-search-submit .spin { display: block; }
.hoso-search-submit .spin { display: none; animation: hoso-spin .8s linear infinite; }

.drawer.drawer-left {
  right: auto;
  left: 0;
  transform: translateX(-100%);
}
.drawer.drawer-left.open { transform: none; }
.hist-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}
.hist-head h3 { margin: 0 0 4px; font-size: 16px; }
.hist-user { margin: 0; font-size: 12px; color: var(--td-text-color-placeholder); }
.hist-list { display: flex; flex-direction: column; gap: 6px; }
.hist-item {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
  width: 100%;
  border: 1px solid var(--td-border-color);
  background: #fff;
  border-radius: 10px;
  padding: 10px 12px;
  text-align: left;
  cursor: pointer;
  font: inherit;
}
.hist-item:hover { border-color: var(--td-brand-color); }
.hist-item.is-on { border-color: var(--td-brand-color); background: var(--td-brand-color-light); }
.hist-title {
  font-size: 13px;
  font-weight: 500;
  color: var(--td-text-color-primary);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 100%;
}
.hist-meta { font-size: 11px; color: var(--td-text-color-placeholder); }
.record-chat {
  max-height: calc(100vh - 220px);
  overflow: auto;
}
.rec-raw {
  margin: 0 0 12px;
  max-height: 360px;
}
.list-page-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 0 12px;
  align-items: center;
}
.list-page-toolbar .input { flex: 1; min-width: 160px; }

.sidebar-footer .res-btn { color: var(--td-text-color-secondary); }

.is-chatting .m-landing { display: none; }
.is-chatting .m-list { display: block; }
.m-app:not(.is-chatting) .m-list { display: none; }
