:root {
  --ink: #171a1f;
  --muted: #68707d;
  --line: #e5e7eb;
  --paper: #f6f5f1;
  --panel: #ffffff;
  --accent: #ff5b36;
  --accent-dark: #db3f1f;
  --green: #168a60;
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", sans-serif;
  color: var(--ink);
  background: var(--paper);
}

* { box-sizing: border-box; }
body { margin: 0; min-width: 320px; background: var(--paper); }
button, input, textarea, select { font: inherit; }
button { cursor: pointer; }

.app-shell { min-height: 100vh; display: grid; grid-template-columns: 264px 1fr; }
.sidebar { position: sticky; top: 0; height: 100vh; display: flex; flex-direction: column; padding: 28px 18px 18px; background: #191c20; color: #fff; }
.brand { display: flex; align-items: center; gap: 13px; padding: 0 10px 30px; }
.brand-mark { width: 38px; height: 38px; display: grid; place-items: center; border: 1px solid #454a52; border-radius: 10px; color: #ff7656; font-size: 13px; font-weight: 800; letter-spacing: -.03em; }
.brand strong, .brand span { display: block; }
.brand strong { font-size: 15px; letter-spacing: .02em; }
.brand span { margin-top: 2px; color: #989da5; font-size: 12px; }
nav { display: grid; gap: 6px; }
.nav-item { width: 100%; display: grid; grid-template-columns: 26px 1fr auto; align-items: center; padding: 11px 12px; border: 0; border-radius: 10px; background: transparent; color: #aeb3bc; text-align: left; transition: .18s ease; }
.nav-item:hover, .nav-item.active { background: #292d33; color: #fff; }
.nav-item.active { box-shadow: inset 3px 0 var(--accent); }
.nav-icon { color: #ff7656; font-weight: 800; }
.version-badge { padding: 2px 5px; border: 1px solid #5a4139; border-radius: 5px; color: #ff8b70; font-size: 8px; font-weight: 800; }
.count { min-width: 22px; padding: 2px 6px; border-radius: 20px; background: var(--accent); color: white; font-size: 11px; text-align: center; }
.history { min-height: 0; display: flex; flex: 1; flex-direction: column; margin-top: 34px; }
.section-label { padding: 0 12px 10px; color: #6f747d; font-size: 10px; font-weight: 700; letter-spacing: .14em; }
.conversation-list { overflow-y: auto; display: grid; gap: 2px; }
.conversation-item { overflow: hidden; padding: 9px 12px; border: 0; border-radius: 8px; background: transparent; color: #9197a0; font-size: 13px; text-align: left; text-overflow: ellipsis; white-space: nowrap; }
.conversation-item:hover, .conversation-item.active { background: #24282d; color: white; }
.sidebar-footer { display: flex; align-items: center; gap: 8px; padding: 16px 6px 0; border-top: 1px solid #30343a; }
.user-card { min-width: 0; display: flex; flex: 1; align-items: center; gap: 10px; }
.avatar { width: 34px; height: 34px; flex: 0 0 auto; display: grid; place-items: center; border-radius: 50%; background: #f2c14f; color: #352a10; font-size: 12px; font-weight: 800; }
.user-copy { min-width: 0; }
.user-copy strong, .user-copy span { overflow: hidden; display: block; text-overflow: ellipsis; white-space: nowrap; }
.user-copy strong { font-size: 12px; }
.user-copy span { margin-top: 3px; color: #80858e; font-size: 10px; }
.logout { border: 0; background: transparent; color: #828790; font-size: 18px; }
.logout:hover { color: white; }

main { min-width: 0; display: flex; flex-direction: column; }
.topbar { height: 84px; display: flex; align-items: center; justify-content: space-between; padding: 0 38px; border-bottom: 1px solid var(--line); background: rgba(246,245,241,.88); backdrop-filter: blur(12px); }
.topbar h1 { margin: 0; font-size: 16px; }
.topbar p { margin: 5px 0 0; color: var(--muted); font-size: 11px; }
.status { display: flex; align-items: center; gap: 8px; color: var(--muted); font-size: 11px; }
.status > span:first-child { width: 7px; height: 7px; border-radius: 50%; background: #27ae7a; box-shadow: 0 0 0 4px #dcf6eb; }
.mobile-menu { display: none; border: 0; background: transparent; }
.view { min-height: 0; flex: 1; display: none; }
.view.active { display: block; }

.chat-stage { height: calc(100vh - 84px); display: grid; grid-template-rows: 1fr auto; }
.messages { overflow-y: auto; padding: 34px max(24px, calc((100% - 850px) / 2)); }
.welcome { max-width: 700px; margin: clamp(50px, 11vh, 120px) auto 0; text-align: center; }
.brain-mark { width: 58px; height: 58px; display: grid; place-items: center; margin: 0 auto 24px; border: 1px solid #dedbd3; border-radius: 18px; background: white; color: var(--accent); font-size: 25px; box-shadow: 0 12px 30px rgba(30,31,33,.08); }
.eyebrow, .kicker { color: var(--accent-dark); font-size: 10px; font-weight: 800; letter-spacing: .18em; }
.welcome h2 { margin: 10px 0 12px; font-family: Georgia, "Songti SC", serif; font-size: clamp(30px, 4vw, 46px); font-weight: 500; letter-spacing: -.03em; }
.welcome > p:not(.eyebrow) { max-width: 540px; margin: 0 auto; color: var(--muted); font-size: 14px; line-height: 1.8; }
.prompts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-top: 36px; }
.prompts button { min-height: 72px; padding: 13px; border: 1px solid #dedbd3; border-radius: 12px; background: rgba(255,255,255,.68); color: #50555d; font-size: 12px; line-height: 1.5; }
.prompts button:hover { border-color: #bbb5aa; background: white; color: var(--ink); transform: translateY(-1px); }
.message { max-width: 760px; margin: 0 auto 26px; animation: reveal .24s ease; }
.message.user { display: flex; justify-content: flex-end; }
.message.user .bubble { max-width: 78%; padding: 13px 17px; border-radius: 16px 16px 4px 16px; background: #25292e; color: white; }
.message.assistant { padding-left: 40px; position: relative; }
.message.assistant::before { content: "✦"; position: absolute; left: 0; top: -2px; color: var(--accent); font-size: 18px; }
.bubble { font-size: 14px; line-height: 1.75; white-space: pre-wrap; }
.citations { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 14px; }
.citation { padding: 6px 9px; border: 1px solid #ddd9d0; border-radius: 7px; color: #62676e; font-size: 10px; }
.action-request { margin-top: 14px; padding: 15px; border: 1px solid #ebc7ac; border-radius: 11px; background: #fff8f1; }
.action-request strong { color: #934f27; font-size: 11px; }
.action-request p { margin: 7px 0 12px; color: #5b514a; font-size: 11px; line-height: 1.6; }
.action-request div { display: flex; gap: 7px; }
.action-request button { padding: 7px 11px; border: 1px solid #ded6ce; border-radius: 7px; background: white; color: #555; font-size: 10px; }
.action-request .confirm-action { border-color: var(--accent); background: var(--accent); color: white; }
.composer { position: relative; width: min(850px, calc(100% - 48px)); margin: 0 auto 24px; padding: 12px 56px 25px 16px; border: 1px solid #d8d5cd; border-radius: 16px; background: white; box-shadow: 0 14px 35px rgba(26,26,26,.08); }
.composer textarea { width: 100%; max-height: 150px; resize: none; border: 0; outline: 0; color: var(--ink); line-height: 1.5; }
.composer button { position: absolute; right: 12px; top: 11px; width: 36px; height: 36px; border: 0; border-radius: 11px; background: var(--accent); color: white; font-size: 20px; }
.composer button:disabled { opacity: .45; cursor: wait; }
.composer-note { position: absolute; left: 16px; bottom: 7px; color: #a0a4aa; font-size: 9px; }

.content-view { overflow-y: auto; padding: 54px max(32px, calc((100% - 930px) / 2)) 70px; }
.content-view.active { display: block; }
.page-intro { margin-bottom: 30px; }
.project-intro, .interaction-intro { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; }
.meeting-intro { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; }
.page-intro h2 { margin: 8px 0 9px; font-family: Georgia, "Songti SC", serif; font-size: 34px; font-weight: 500; }
.page-intro p { margin: 0; color: var(--muted); font-size: 13px; }
.panel { padding: 28px; border: 1px solid var(--line); border-radius: 16px; background: white; }
.project-metrics { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-bottom: 22px; }
.project-metrics > div { padding: 18px 20px; border: 1px solid var(--line); border-radius: 12px; background: rgba(255,255,255,.7); }
.project-metrics span, .project-metrics strong { display: block; }
.project-metrics span { color: var(--muted); font-size: 10px; }
.project-metrics strong { margin-top: 8px; font-family: Georgia, serif; font-size: 28px; font-weight: 500; }
.project-create { margin-bottom: 28px; }
.create-columns { display: grid; grid-template-columns: .8fr 1.2fr; gap: 34px; }
.compact-form { display: grid; align-content: start; gap: 16px; }
.compact-form + .compact-form { padding-left: 34px; border-left: 1px solid var(--line); }
.form-heading { display: flex; align-items: center; gap: 11px; margin-bottom: 3px; }
.form-heading > span { width: 28px; height: 28px; display: grid; place-items: center; border-radius: 8px; background: #f3f0e9; color: var(--accent-dark); font-size: 10px; font-weight: 800; }
.form-heading strong, .form-heading small { display: block; }
.form-heading strong { font-size: 13px; }
.form-heading small { margin-top: 2px; color: var(--muted); font-size: 9px; }
.field small { color: #999da3; font-size: 9px; }
.secondary { padding: 10px 16px; border: 1px solid #d8d5cd; border-radius: 9px; background: white; color: #454a51; font-weight: 600; }
.project-toolbar { display: flex; align-items: center; justify-content: space-between; margin: 28px 0 14px; }
.project-toolbar h3 { margin: 0; font-size: 13px; }
.project-toolbar select { padding: 8px 30px 8px 10px; border: 1px solid #ddd9d1; border-radius: 8px; background: transparent; color: var(--muted); font-size: 10px; }
.customer-profile-toolbar { align-items: flex-end; }
.customer-profile-toolbar > div > span { display: block; margin-top: 5px; color: var(--muted); font-size: 9px; }
.customer-profile { display: grid; gap: 22px; padding: 22px; }
.profile-summary { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; padding-bottom: 20px; border-bottom: 1px solid var(--line); }
.profile-summary h3 { margin: 6px 0 0; font: 500 25px Georgia, "Songti SC", serif; }
.profile-summary p { margin: 6px 0 0; color: var(--muted); font-size: 10px; }
.profile-stats { display: flex; align-items: flex-end; gap: 24px; }
.profile-stats span { color: var(--muted); font-size: 8px; text-align: right; }
.profile-stats strong { display: block; margin-bottom: 4px; color: #30343a; font: 500 17px Georgia, serif; }
.profile-section { display: grid; gap: 10px; }
.profile-section-head { display: flex; align-items: center; justify-content: space-between; }
.profile-section-head h4 { margin: 0; font-size: 11px; }
.profile-section-head span { color: var(--muted); font-size: 9px; }
.profile-insights { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 9px; }
.profile-insight { padding: 14px; border: 1px solid var(--line); border-radius: 10px; background: #faf9f6; }
.profile-insight > strong { font-size: 10px; }
.profile-insight > p { margin: 7px 0 10px; color: #4c5158; font-size: 10px; line-height: 1.65; white-space: pre-wrap; }
.profile-insight > small { display: block; margin-top: 7px; color: #8a8e94; font-size: 8px; line-height: 1.5; }
.profile-citation { display: flex; flex-wrap: wrap; gap: 5px; }
.profile-citation span { padding: 3px 6px; border-radius: 20px; background: white; color: #777c83; font-size: 8px; }
.profile-empty { padding: 30px 20px; }
.project-list { display: grid; gap: 10px; }
.project-card { display: grid; grid-template-columns: minmax(220px, 1.5fr) minmax(150px, .8fr) minmax(150px, .8fr) auto; align-items: center; gap: 20px; padding: 18px 20px; border: 1px solid var(--line); border-radius: 12px; background: white; }
.project-name strong, .project-name span { display: block; }
.project-name strong { font-size: 14px; }
.project-name span { margin-top: 5px; color: var(--muted); font-size: 10px; }
.project-data span, .project-data strong { display: block; }
.project-data span { color: #9a9ea4; font-size: 9px; text-transform: uppercase; letter-spacing: .08em; }
.project-data strong { overflow: hidden; margin-top: 5px; color: #4a4f57; font-size: 11px; font-weight: 600; text-overflow: ellipsis; white-space: nowrap; }
.project-status { padding: 6px 9px; border-radius: 20px; background: #f3f1ec; color: #5e646c; font-size: 9px; white-space: nowrap; }
.project-status.ACTIVE { background: #eaf8f2; color: #117653; }
.project-status.COMPLETED { background: #eef3ff; color: #365fa8; }
.project-status-select { padding: 6px 8px; border: 1px solid #ddd9d1; border-radius: 20px; background: #f8f7f4; color: #555b63; font-size: 9px; }
.project-card-actions { display: grid; justify-items: end; gap: 7px; }
.task-button { padding: 5px 8px; border: 1px solid #ddd9d1; border-radius: 7px; background: white; color: #666b72; font-size: 9px; }
.task-list { display: grid; gap: 8px; }
.task-card { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 14px 15px; border: 1px solid var(--line); border-radius: 10px; background: white; }
.task-card strong { font-size: 11px; }
.task-card p { margin: 5px 0 0; color: var(--muted); font-size: 9px; }
.task-card select { padding: 6px; border: 1px solid #ddd9d1; border-radius: 7px; background: #faf9f6; font-size: 9px; }
.meeting-create { margin-bottom: 22px; }
.meeting-layout { min-height: 520px; display: grid; grid-template-columns: 260px 1fr; gap: 16px; }
.meeting-list-panel, .meeting-editor { overflow: hidden; border: 1px solid var(--line); border-radius: 14px; background: white; }
.meeting-list-head { display: flex; align-items: center; justify-content: space-between; padding: 16px; border-bottom: 1px solid var(--line); }
.meeting-list-head strong { font-size: 12px; }
.meeting-list-head select { padding: 6px; border: 1px solid #e0ddd6; border-radius: 7px; color: var(--muted); font-size: 9px; }
.meeting-list { max-height: 640px; overflow-y: auto; }
.meeting-list-item { width: 100%; display: block; padding: 15px 16px; border: 0; border-bottom: 1px solid #f0eee9; background: white; text-align: left; }
.meeting-list-item:hover, .meeting-list-item.active { background: #faf8f4; }
.meeting-list-item.active { box-shadow: inset 3px 0 var(--accent); }
.meeting-list-item strong, .meeting-list-item span { overflow: hidden; display: block; text-overflow: ellipsis; white-space: nowrap; }
.meeting-list-item strong { font-size: 11px; }
.meeting-list-item span { margin-top: 5px; color: var(--muted); font-size: 9px; }
.meeting-list-item .meeting-state { display: inline-block; margin-top: 8px; padding: 3px 6px; border-radius: 5px; background: #fff4e7; color: #a65b10; }
.meeting-list-item .meeting-state.confirmed { background: #eaf8f2; color: #117653; }
.meeting-editor { padding: 24px; }
.meeting-editor-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 18px; margin-bottom: 24px; }
.meeting-editor-head h3 { margin: 0; font-family: Georgia, "Songti SC", serif; font-size: 24px; font-weight: 500; }
.meeting-editor-head p { margin: 7px 0 0; color: var(--muted); font-size: 10px; }
.method-badge { padding: 5px 8px; border-radius: 6px; background: #f3f1ec; color: #6a6f76; font-size: 9px; }
.summary-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.summary-card { min-height: 150px; padding: 16px; border: 1px solid #e6e3dd; border-radius: 10px; background: #fcfbf8; }
.summary-card.wide { grid-column: 1 / -1; min-height: 100px; }
.summary-card label { display: block; margin-bottom: 9px; color: #555a61; font-size: 10px; font-weight: 800; letter-spacing: .08em; }
.summary-card textarea { width: 100%; min-height: 105px; resize: vertical; border: 0; outline: 0; background: transparent; color: #34383e; font-size: 12px; line-height: 1.65; }
.summary-card.wide textarea { min-height: 70px; }
.meeting-editor-actions { display: flex; align-items: center; justify-content: flex-end; gap: 10px; margin-top: 20px; padding-top: 18px; border-top: 1px solid var(--line); }
.meeting-confirmed { color: var(--green); font-size: 11px; }
.transcript-details { margin-top: 18px; border-top: 1px solid var(--line); }
.transcript-details summary { padding: 14px 0; color: var(--muted); cursor: pointer; font-size: 10px; }
.transcript-details pre { overflow: auto; max-height: 260px; margin: 0; padding: 16px; border-radius: 9px; background: #26292e; color: #d7dadf; font: 11px/1.7 ui-monospace, monospace; white-space: pre-wrap; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; }
.field { display: grid; gap: 8px; }
.field > span { color: #42474f; font-size: 11px; font-weight: 700; }
.field-wide { grid-column: 1 / -1; }
.field input, .field textarea, .field select { width: 100%; padding: 12px 13px; border: 1px solid #dedede; border-radius: 9px; outline: none; background: #fbfbfa; color: var(--ink); }
.field input:focus, .field textarea:focus, .field select:focus { border-color: #a3a7ad; background: white; box-shadow: 0 0 0 3px #f0efeb; }
.form-actions { display: flex; align-items: center; justify-content: space-between; color: var(--green); font-size: 12px; }
.wechat-ocr-panel { display: grid; grid-template-columns: minmax(230px, .72fr) minmax(360px, 1.28fr); gap: 22px; align-items: center; margin-bottom: 18px; }
.wechat-ocr-copy h3 { margin: 5px 0 6px; font-size: 17px; }
.wechat-ocr-copy p { margin: 0; color: var(--muted); font-size: 11px; line-height: 1.65; }
.wechat-paste-zone { min-height: 112px; display: grid; grid-template-columns: auto minmax(170px, 1fr) auto; align-items: center; gap: 14px; padding: 18px; border: 1.5px dashed #c9c5bd; border-radius: 13px; outline: none; background: #fbfaf7; transition: .18s ease; }
.wechat-paste-zone:hover, .wechat-paste-zone:focus-within, .wechat-paste-zone.dragging { border-color: var(--accent); background: #fff7f3; box-shadow: 0 0 0 4px rgba(255,91,54,.08); }
.paste-shortcut { width: 50px; height: 50px; display: grid; place-items: center; border-radius: 12px; background: #25292e; color: white; font-size: 15px; font-weight: 800; box-shadow: 0 7px 16px rgba(25,28,32,.14); }
.wechat-paste-zone strong, .wechat-paste-zone span { display: block; }
.wechat-paste-zone strong { font-size: 12px; }
.wechat-paste-zone span { margin-top: 5px; color: var(--muted); font-size: 9px; }
.wechat-paste-receiver { min-width: 0; padding: 8px; border-radius: 8px; outline: none; cursor: text; }
.wechat-paste-receiver:focus { background: rgba(255,255,255,.72); box-shadow: inset 0 0 0 1px rgba(255,91,54,.24); }
.wechat-paste-actions { display: flex; gap: 6px; }
.text-button { padding: 8px 10px; border: 0; border-radius: 8px; background: #eeeae3; color: #5f6268; font-size: 9px; }
.clipboard-button { background: #25292e; color: white; }
.wechat-paste-feedback { grid-column: 2 / -1; min-height: 13px; margin: -6px 0 0 !important; color: #8a8d92 !important; }
.wechat-paste-feedback.success { color: var(--green) !important; }
.wechat-paste-feedback.error { color: #a53e31 !important; }
.wechat-ocr-progress { grid-column: 2; display: grid; grid-template-columns: 54px 1fr; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 10px; background: #f4f7f5; }
.wechat-ocr-progress[hidden] { display: none; }
.wechat-ocr-progress img { width: 54px; height: 42px; object-fit: cover; border-radius: 6px; background: #ddd; }
.wechat-ocr-progress strong, .wechat-ocr-progress span { display: block; }
.wechat-ocr-progress strong { overflow: hidden; font-size: 10px; text-overflow: ellipsis; white-space: nowrap; }
.wechat-ocr-status { min-height: 14px; margin-top: 4px; color: var(--green); font-size: 9px; }
.wechat-ocr-panel.processing .wechat-paste-zone { opacity: .55; pointer-events: none; }
.wechat-intake-result { grid-column: 1 / -1; display: flex; align-items: center; justify-content: space-between; gap: 18px; padding: 16px 18px; border: 1px solid #bce6d5; border-radius: 11px; background: #f1faf6; }
.wechat-intake-result[hidden] { display: none; }
.wechat-intake-result span, .wechat-intake-result strong, .wechat-intake-result small { display: block; }
.wechat-intake-result span { color: var(--green); font-size: 9px; font-weight: 800; letter-spacing: .1em; }
.wechat-intake-result strong { margin-top: 4px; font-size: 13px; }
.wechat-intake-result p { margin: 6px 0; color: #505c56; font-size: 10px; line-height: 1.55; }
.wechat-intake-result small { color: #89918d; font-size: 8px; }
.manual-intro { margin: 44px 0 18px; padding-top: 32px; border-top: 1px solid var(--line); }
.manual-intro h2 { font-size: 25px; }
.interaction-metrics { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin-bottom: 20px; }
.interaction-metrics > div { padding: 17px 18px; border: 1px solid var(--line); border-radius: 11px; background: rgba(255,255,255,.74); }
.interaction-metrics span, .interaction-metrics strong { display: block; }
.interaction-metrics span { color: var(--muted); font-size: 9px; }
.interaction-metrics strong { margin-top: 7px; font: 500 26px Georgia, serif; }
.interaction-create { margin-bottom: 22px; }
.interaction-checkbox { display: flex; align-items: center; gap: 8px; color: #5d6269; font-size: 10px; }
.interaction-checkbox input { accent-color: var(--accent); }
.interaction-toolbar { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; margin: 26px 0 14px; }
.interaction-toolbar h3 { margin: 0; font-size: 13px; }
.interaction-toolbar > div > span { display: block; margin-top: 5px; color: var(--muted); font-size: 9px; }
.interaction-filters { display: flex; gap: 7px; }
.interaction-filters select { padding: 8px 28px 8px 10px; border: 1px solid #ddd9d1; border-radius: 8px; background: white; color: var(--muted); font-size: 9px; }
.interaction-timeline { position: relative; display: grid; gap: 10px; }
.interaction-card { position: relative; display: grid; grid-template-columns: 110px 1fr auto; gap: 18px; padding: 20px 21px; border: 1px solid var(--line); border-radius: 13px; background: white; }
.interaction-workflow-meta { display: flex; flex-wrap: wrap; gap: 7px 16px; margin-top: 12px; color: #6e737a; font-size: 9px; }
.interaction-state { display: flex; min-width: 112px; align-items: flex-end; flex-direction: column; gap: 8px; }
.interaction-state button { padding: 7px 9px; border: 1px solid #dedbd5; border-radius: 7px; background: #faf9f6; color: #555a61; font-size: 9px; }
.interaction-state small { color: var(--green); font-size: 8px; }
.handling-state { padding: 5px 8px; border-radius: 20px; background: #f2f1ee; color: #6b7076; font-size: 9px; }
.handling-state.FOLLOW_UP { background: #eef3ff; color: #365fa8; }
.handling-state.RESOLVED { background: #eaf8f2; color: #117653; }
.handling-state.IGNORED { background: #f0efec; color: #92959a; }
.resolution-note { display: block; margin-top: 8px; color: var(--green) !important; }
.workflow-context { padding: 13px 14px; border-radius: 9px; background: #f7f5f0; }
.workflow-context strong { font-size: 11px; }
.workflow-context p { max-height: 100px; overflow: auto; margin: 7px 0 0; color: #5f646b; font-size: 10px; line-height: 1.55; white-space: pre-wrap; }
.interaction-card::before { content: ""; position: absolute; left: -1px; top: 18px; bottom: 18px; width: 3px; border-radius: 0 3px 3px 0; background: #aeb3bb; }
.interaction-card.RISK::before { background: #dc4d45; }
.interaction-card.SCHEDULE::before { background: #d89027; }
.interaction-card.REQUIREMENT::before { background: #4d78c7; }
.interaction-card.FEEDBACK::before { background: #8b62bd; }
.interaction-card.DECISION::before { background: #1c8a65; }
.interaction-time { color: #878c94; font-size: 9px; line-height: 1.6; }
.interaction-time strong { display: block; color: #4f545b; font-size: 10px; }
.interaction-body { min-width: 0; }
.interaction-body header { display: flex; flex-wrap: wrap; align-items: center; gap: 7px; }
.interaction-type { padding: 4px 7px; border-radius: 6px; background: #f1f0ec; color: #575c63; font-size: 9px; font-weight: 700; }
.interaction-body header span:not(.interaction-type) { color: #898e96; font-size: 9px; }
.interaction-body p { margin: 10px 0 0; color: #484d54; font-size: 12px; line-height: 1.7; white-space: pre-wrap; }
.interaction-body small { display: block; margin-top: 9px; color: #989ca2; font-size: 8px; }
.interaction-state { align-self: center; color: var(--green); font-size: 9px; text-align: right; }
.interaction-state [data-interaction-promote] { border-color: #e0b98f; background: #fff8ee; color: #9a5b1c; }
.primary { padding: 11px 20px; border: 0; border-radius: 9px; background: var(--accent); color: white; font-weight: 700; }
.primary:hover { background: var(--accent-dark); }
.queue-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 14px; margin-bottom: 18px; }
.queue-filters, .batch-actions { display: flex; align-items: center; gap: 6px; }
.batch-actions { color: var(--muted); font-size: 10px; }
.batch-actions label { display: flex; align-items: center; gap: 4px; }
.batch-actions button { padding: 7px 10px; border: 1px solid #ddd9d1; border-radius: 7px; background: white; color: #555b63; font-size: 10px; }
.batch-actions .batch-approve { border-color: #bce6d5; background: #effaf5; color: #087956; }
.batch-actions button:disabled { opacity: .42; cursor: not-allowed; }
.filter { padding: 8px 13px; border: 1px solid #ddd9d1; border-radius: 20px; background: transparent; color: var(--muted); font-size: 11px; }
.filter.active { border-color: #2f3338; background: #2f3338; color: white; }
.review-list { display: grid; gap: 12px; }
.review-card { padding: 22px; border: 1px solid var(--line); border-radius: 13px; background: white; }
.review-head { display: flex; align-items: flex-start; gap: 12px; }
.review-title { min-width: 0; flex: 1; }
.memory-select { padding-top: 2px; }
.review-card h3 { margin: 0 0 7px; font-size: 15px; }
.review-card p { margin: 14px 0 0; color: #50555c; font-size: 13px; line-height: 1.7; white-space: pre-wrap; }
.meta { display: flex; flex-wrap: wrap; gap: 8px; color: #898e96; font-size: 10px; }
.badge { padding: 4px 7px; border-radius: 5px; background: #f3f1ec; color: #656a72; }
.review-actions { display: flex; gap: 8px; margin-top: 18px; padding-top: 16px; border-top: 1px solid #eee; }
.review-actions button { padding: 8px 13px; border: 1px solid #ddd; border-radius: 8px; background: white; font-size: 11px; }
.review-actions .approve { border-color: #bce6d5; background: #effaf5; color: #087956; }
.review-actions .archive { margin-left: auto; color: #a05243; }
.intake-intro { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; }
.intake-metrics { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin-bottom: 20px; }
.intake-metrics > div { padding: 17px 18px; border: 1px solid var(--line); border-radius: 11px; background: rgba(255,255,255,.74); }
.intake-metrics span, .intake-metrics strong { display: block; }
.intake-metrics span { color: var(--muted); font-size: 9px; }
.intake-metrics strong { margin-top: 7px; font: 500 26px Georgia, serif; }
.intake-safety-note { color: var(--green); font-size: 9px; }
.intake-filter-side { display: flex; align-items: center; gap: 12px; }
.intake-filter-side select { padding: 8px 28px 8px 10px; border: 1px solid #ddd9d1; border-radius: 8px; background: white; color: var(--muted); font-size: 9px; }
.intake-list { display: grid; gap: 14px; }
.intake-card { padding: 23px; border: 1px solid var(--line); border-radius: 14px; background: white; }
.intake-card.needs-attention { border-left: 3px solid #d89027; }
.intake-card.overdue { border-color: #e4aaa3; }
.intake-card-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 18px; }
.intake-card-head h3 { margin: 10px 0 0; font: 500 20px Georgia, "Songti SC", serif; }
.intake-card-head h3 i { color: #a9adb2; font-style: normal; }
.intake-confidence { margin-left: 7px; color: #8b9097; font-size: 9px; }
.intake-grouped { margin-left: 7px; padding: 3px 6px; border-radius: 5px; background: #eef3ff; color: #42639a; font-size: 8px; }
.intake-state-stack { display: grid; justify-items: end; gap: 6px; }
.intake-overdue { color: #b24c40; font-size: 8px; font-weight: 700; }
.attention-reasons { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 12px; }
.attention-reasons span { padding: 4px 7px; border-radius: 5px; background: #fff4df; color: #996422; font-size: 8px; }
.intake-state { padding: 5px 9px; border-radius: 20px; background: #f1f0ed; color: #6b7077; font-size: 9px; }
.intake-state.APPROVED { background: #eaf8f2; color: #117653; }
.intake-state.REJECTED { background: #f8eeee; color: #99483d; }
.intake-summary { margin: 16px 0; color: #444a51; font-size: 12px; line-height: 1.7; }
.intake-facts { display: grid; gap: 6px; }
.intake-fact { display: grid; grid-template-columns: 50px 1fr; gap: 10px; padding: 9px 11px; border-radius: 8px; background: #f7f6f2; font-size: 10px; line-height: 1.55; }
.intake-fact strong { color: var(--accent-dark); }
.intake-fact span { color: #575d64; }
.intake-knowledge { margin-top: 15px; padding: 15px; border-left: 3px solid #2f3338; background: #faf9f6; }
.intake-knowledge strong { font-size: 11px; }
.intake-knowledge p { margin: 8px 0 0; color: #555b62; font-size: 10px; line-height: 1.65; white-space: pre-wrap; }
.raw-chat { margin-top: 13px; border-top: 1px solid #efede8; }
.raw-chat summary { padding: 12px 0 0; color: #92969c; cursor: pointer; font-size: 9px; }
.raw-chat pre { overflow: auto; max-height: 220px; margin: 10px 0 0; padding: 14px; border-radius: 8px; background: #25292e; color: #d7dadf; font: 10px/1.65 ui-monospace, monospace; white-space: pre-wrap; }
.intake-review-note { padding: 12px 14px; border-radius: 9px; background: #eef7f3; color: #25664e; font-size: 10px; line-height: 1.6; }
.intake-suggestions { display: flex; gap: 9px; padding: 11px 13px; border-radius: 9px; background: #fff5e5; color: #71552c; font-size: 9px; line-height: 1.5; }
.review-due { margin-left: auto; align-self: center; color: #979ba1; font-size: 8px; }
.intake-modal-panel { width: min(780px, 100%); }
.muted { color: var(--muted); font-size: 10px; }
.source-reference { margin-top: 12px; color: #92969d; font-size: 10px; }
.wecom-config-panel { margin-top: 18px; }
.wecom-config-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; margin-bottom: 24px; padding-bottom: 18px; border-bottom: 1px solid var(--line); }
.wecom-config-heading h3 { margin: 6px 0; font-size: 15px; }
.wecom-config-heading p { margin: 0; color: var(--muted); font-size: 10px; }
.copy-field { display: grid; grid-template-columns: 1fr auto; }
.copy-field input { border-radius: 9px 0 0 9px; }
.copy-field button { padding: 0 14px; border: 1px solid #dedede; border-left: 0; border-radius: 0 9px 9px 0; background: #f0eee8; color: #555b62; font-size: 9px; }
.modal-open { overflow: hidden; }
.modal { position: fixed; z-index: 50; inset: 0; display: grid; place-items: center; padding: 24px; }
.modal[hidden] { display: none; }
.modal-backdrop { position: absolute; inset: 0; border: 0; background: rgba(23,25,28,.48); backdrop-filter: blur(4px); }
.modal-panel { position: relative; overflow: hidden; width: min(720px, 100%); max-height: min(820px, calc(100vh - 48px)); border: 1px solid #d8d4cc; border-radius: 17px; background: #f8f7f3; box-shadow: 0 30px 80px rgba(0,0,0,.25); }
.modal-panel > header { display: flex; align-items: flex-start; justify-content: space-between; padding: 24px 26px 19px; border-bottom: 1px solid var(--line); background: white; }
.modal-panel h2 { margin: 6px 0 0; font-family: Georgia, "Songti SC", serif; font-size: 25px; font-weight: 500; }
.modal-close { width: 32px; height: 32px; border: 0; border-radius: 8px; background: #f3f1ec; color: #6c7178; font-size: 22px; }
.modal-body { overflow-y: auto; max-height: calc(100vh - 160px); padding: 24px 26px 28px; }
.memory-edit-form { display: grid; gap: 18px; }
.modal-form-actions { display: flex; justify-content: flex-end; gap: 9px; padding-top: 4px; }
.version-list { display: grid; gap: 12px; }
.version-card { padding: 18px; border: 1px solid var(--line); border-radius: 11px; background: white; }
.version-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.version-head strong { font-size: 12px; }
.version-head span { color: var(--muted); font-size: 9px; }
.version-card .meta { margin-top: 9px; }
.version-card h3 { margin: 15px 0 7px; font-size: 14px; }
.version-card p { margin: 0; color: #555a61; font-size: 11px; line-height: 1.65; white-space: pre-wrap; }
.change-note { margin-top: 13px; padding: 9px 11px; border-radius: 7px; background: #f6f3ec; color: #777b82; font-size: 10px; }
.integration-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }
.integration-card { display: flex; align-items: center; gap: 12px; padding: 18px; border: 1px solid var(--line); border-radius: 12px; background: white; }
.integration-light { width: 9px; height: 9px; flex: 0 0 auto; border-radius: 50%; background: #c6c8ca; box-shadow: 0 0 0 4px #f0f0ee; }
.integration-light.active { background: #27ae7a; box-shadow: 0 0 0 4px #dcf6eb; }
.integration-card strong { font-size: 11px; }
.integration-card p { margin: 4px 0 0; color: var(--muted); font-size: 9px; }
.admin-toolbar { margin-top: 30px; }
.job-list { display: grid; gap: 8px; }
.job-card { display: flex; align-items: flex-start; justify-content: space-between; gap: 18px; padding: 16px 18px; border: 1px solid var(--line); border-radius: 11px; background: white; }
.job-card strong { font-size: 11px; }
.job-card p { margin: 5px 0 0; color: var(--muted); font-size: 9px; }
.job-card > div:last-child { display: grid; justify-items: end; gap: 7px; }
.job-card button { padding: 5px 8px; border: 1px solid #ddd9d1; border-radius: 6px; background: white; font-size: 9px; }
.job-state { padding: 5px 8px; border-radius: 20px; background: #f3f1ec; color: #696e75; font-size: 9px; }
.job-state.SUCCEEDED { background: #eaf8f2; color: #117653; }
.job-state.FAILED { background: #fff0ee; color: #a53e31; }
.job-state.RUNNING { background: #eef3ff; color: #365fa8; }
.job-error { max-width: 620px; margin-top: 8px; color: #a53e31; font-size: 9px; line-height: 1.5; }
.admin-toolbar > span { color: var(--muted); font-size: 9px; }
.user-admin-list { display: grid; gap: 8px; }
.user-admin-card { display: grid; grid-template-columns: auto minmax(180px, 1fr) 180px auto; align-items: center; gap: 12px; padding: 13px 16px; border: 1px solid var(--line); border-radius: 11px; background: white; }
.user-admin-name strong, .user-admin-name span { display: block; }
.user-admin-name strong { font-size: 11px; }
.user-admin-name span { margin-top: 4px; color: var(--muted); font-size: 9px; }
.user-admin-card select { padding: 7px; border: 1px solid #ddd9d1; border-radius: 7px; background: #faf9f6; font-size: 9px; }
.user-state { padding: 6px 9px; border: 0; border-radius: 20px; background: #fff0ee; color: #a53e31; font-size: 9px; }
.user-state.active { background: #eaf8f2; color: #117653; }
.api-settings-intro { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; }
.api-state { padding: 7px 11px; border-radius: 20px; background: #f0efec; color: #73777d; font-size: 10px; white-space: nowrap; }
.api-state.connected { background: #eaf8f2; color: #117653; }
.api-settings-layout { display: grid; grid-template-columns: minmax(0, 1fr) 260px; align-items: start; gap: 18px; }
.api-config-form { display: grid; gap: 25px; }
.api-form-heading { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 15px; padding-bottom: 22px; border-bottom: 1px solid var(--line); }
.api-provider-mark { width: 44px; height: 44px; display: grid; place-items: center; border-radius: 12px; background: #24282d; color: white; font-size: 12px; font-weight: 800; }
.api-form-heading strong { font-size: 14px; }
.api-form-heading p { margin: 5px 0 0; color: var(--muted); font-size: 10px; }
.switch-field { display: flex; align-items: center; gap: 8px; color: #545960; cursor: pointer; font-size: 10px; }
.switch-field input { position: absolute; opacity: 0; pointer-events: none; }
.switch-field span { position: relative; width: 38px; height: 22px; border-radius: 20px; background: #d5d6d7; transition: .18s ease; }
.switch-field span::after { content: ""; position: absolute; top: 3px; left: 3px; width: 16px; height: 16px; border-radius: 50%; background: white; box-shadow: 0 2px 6px rgba(0,0,0,.18); transition: .18s ease; }
.switch-field input:checked + span { background: var(--green); }
.switch-field input:checked + span::after { transform: translateX(16px); }
.switch-field em { font-style: normal; }
.api-field-grid { gap: 18px; }
.embedding-control { display: flex; align-items: flex-start; gap: 10px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 10px; background: #faf9f6; color: #53585f; cursor: pointer; }
.embedding-control input { margin-top: 2px; accent-color: var(--green); }
.embedding-control span, .embedding-control strong, .embedding-control small { display: block; }
.embedding-control strong { font-size: 10px; }
.embedding-control small { margin-top: 5px; color: var(--muted); font-size: 9px; line-height: 1.5; }
.field-muted { opacity: .55; }
.secret-input { display: grid; grid-template-columns: 1fr auto; }
.secret-input input { min-width: 0; border-radius: 9px 0 0 9px; }
.secret-input button { padding: 0 13px; border: 1px solid #dedede; border-left: 0; border-radius: 0 9px 9px 0; background: #f5f4f1; color: #62676e; font-size: 10px; }
.clear-secret { display: flex; align-items: center; gap: 7px; color: #a53e31; font-size: 10px; }
.api-form-actions { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding-top: 20px; border-top: 1px solid var(--line); }
.api-form-actions > div:last-child { display: flex; gap: 8px; }
.api-test-result { color: var(--muted); font-size: 10px; line-height: 1.5; }
.api-test-result.testing { color: #365fa8; }
.api-test-result.success { color: var(--green); }
.api-test-result.error { color: #a53e31; }
.api-help-panel { padding: 23px; }
.api-help-panel h3 { margin: 9px 0 15px; font: 500 22px Georgia, "Songti SC", serif; }
.api-help-panel ul { display: grid; gap: 11px; margin: 0; padding: 0 0 0 17px; color: #5a5f66; font-size: 10px; line-height: 1.6; }
.api-usage-note { margin-top: 22px; padding: 15px; border-radius: 10px; background: #f6f3ec; }
.api-usage-note strong { font-size: 10px; }
.api-usage-note p { margin: 7px 0 0; color: var(--muted); font-size: 9px; line-height: 1.6; }
.usage-intro { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; }
.usage-period { display: grid; gap: 6px; color: var(--muted); font-size: 9px; }
.usage-period select { padding: 8px 30px 8px 10px; border: 1px solid #ddd9d1; border-radius: 8px; background: white; color: #51565d; font-size: 10px; }
.usage-metrics { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-bottom: 18px; }
.usage-metrics article { padding: 20px; border: 1px solid var(--line); border-radius: 12px; background: white; }
.usage-metrics span, .usage-metrics strong { display: block; }
.usage-metrics span { color: var(--muted); font-size: 10px; }
.usage-metrics strong { margin-top: 10px; font: 500 27px Georgia, serif; }
.usage-panel { padding: 0; overflow: hidden; }
.usage-table-head { display: flex; align-items: center; justify-content: space-between; padding: 20px 22px; border-bottom: 1px solid var(--line); }
.usage-table-head strong { font-size: 12px; }
.usage-table-head span { color: var(--muted); font-size: 9px; }
.usage-table-wrap { overflow-x: auto; }
.usage-table { width: 100%; border-collapse: collapse; color: #4b5057; font-size: 10px; }
.usage-table th, .usage-table td { padding: 13px 18px; border-bottom: 1px solid #efede8; text-align: right; white-space: nowrap; }
.usage-table th { background: #faf9f6; color: #898d93; font-size: 9px; font-weight: 700; }
.usage-table th:first-child, .usage-table td:first-child { text-align: left; }
.usage-person { display: flex; align-items: center; gap: 10px; }
.usage-person .avatar { width: 30px; height: 30px; }
.usage-person strong, .usage-person small { display: block; }
.usage-person strong { color: var(--ink); font-size: 10px; }
.usage-person small { margin-top: 3px; color: var(--muted); font-size: 8px; }
.usage-footnote { margin: 0; padding: 12px 20px; background: #faf9f6; color: #94989e; font-size: 9px; }
.archive-admin-panel { margin-top: 18px; }
.archive-metrics { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin: 20px 0; }
.archive-metrics > div { padding: 15px; border: 1px solid var(--line); border-radius: 10px; background: #faf9f6; }
.archive-metrics span, .archive-metrics strong { display: block; }
.archive-metrics span { color: var(--muted); font-size: 9px; }
.archive-metrics strong { margin-top: 7px; font: 500 22px Georgia, serif; }
.archive-columns { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; }
.archive-columns > div { min-width: 0; }
.archive-columns h4 { margin: 0 0 14px; font-size: 12px; }
.archive-list { display: grid; gap: 8px; margin-top: 14px; }
.archive-list .empty { padding: 24px 16px; }
.archive-record { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 9px; background: white; }
.archive-record strong, .archive-record span, .archive-record small { display: block; }
.archive-record strong { font-size: 10px; }
.archive-record span { margin-top: 4px; color: #60656c; font-size: 9px; }
.archive-record small { margin-top: 4px; color: var(--muted); font-size: 8px; }
.archive-record button { padding: 6px 9px; border: 1px solid #ddd9d1; border-radius: 7px; background: #faf9f6; color: #5e636a; font-size: 9px; white-space: nowrap; }
.wechat-bridge-flow { display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: 9px; margin: 18px 0; padding: 14px; border-radius: 10px; background: #f6f3ee; color: #5e636a; font-size: 9px; }
.wechat-bridge-flow span { padding: 7px 10px; border: 1px solid #ded9d0; border-radius: 999px; background: white; }
.wechat-bridge-flow b { color: var(--accent); }
.wechat-group-record { align-items: center; }
.bridge-group-state { flex: 0 0 auto; padding: 6px 9px; border-radius: 999px; background: #fff2da; color: #9a680d; font-size: 8px; white-space: nowrap; }
.bridge-group-state.confirmed { background: #e5f6ef; color: #167559; }
.empty { padding: 54px 24px; border: 1px dashed #d7d3ca; border-radius: 14px; color: var(--muted); text-align: center; }
.toast { position: fixed; right: 24px; bottom: 24px; z-index: 20; opacity: 0; pointer-events: none; transform: translateY(10px); padding: 12px 16px; border-radius: 9px; background: #1e2227; color: white; font-size: 12px; transition: .2s ease; }
.toast.show { opacity: 1; transform: translateY(0); }
@keyframes reveal { from { opacity: 0; transform: translateY(5px); } }

@media (max-width: 760px) {
  .app-shell { grid-template-columns: 1fr; }
  .sidebar { position: fixed; z-index: 30; width: 264px; transform: translateX(-100%); transition: transform .22s ease; }
  .sidebar.open { transform: translateX(0); box-shadow: 20px 0 50px rgba(0,0,0,.25); }
  .mobile-menu { display: block; margin-right: 14px; }
  .topbar { justify-content: flex-start; padding: 0 20px; }
  .topbar .status { margin-left: auto; }
  .prompts { grid-template-columns: 1fr; }
  .welcome { margin-top: 38px; }
  .form-grid { grid-template-columns: 1fr; }
  .wechat-ocr-panel { grid-template-columns: 1fr; }
  .wechat-paste-zone { grid-template-columns: auto 1fr; }
  .wechat-paste-actions, .wechat-paste-feedback { grid-column: 1 / -1; }
  .wechat-paste-actions { justify-content: stretch; }
  .wechat-paste-actions .text-button { flex: 1; }
  .wechat-ocr-progress { grid-column: auto; }
  .create-columns, .project-metrics, .interaction-metrics, .intake-metrics, .integration-grid, .api-settings-layout, .usage-metrics, .archive-metrics, .archive-columns { grid-template-columns: 1fr; }
  .api-form-heading { grid-template-columns: auto 1fr; }
  .switch-field { grid-column: 1 / -1; }
  .api-form-actions { align-items: stretch; flex-direction: column; }
  .usage-intro { align-items: flex-start; flex-direction: column; }
  .compact-form + .compact-form { padding: 24px 0 0; border-top: 1px solid var(--line); border-left: 0; }
  .project-intro, .interaction-intro, .meeting-intro, .intake-intro { align-items: flex-start; flex-direction: column; }
  .interaction-toolbar { align-items: stretch; flex-direction: column; }
  .interaction-filters { display: grid; grid-template-columns: 1fr; }
  .interaction-card { grid-template-columns: 1fr; gap: 10px; }
  .interaction-state { text-align: left; }
  .profile-summary { align-items: flex-start; flex-direction: column; }
  .profile-stats { width: 100%; justify-content: space-between; }
  .profile-stats span { text-align: left; }
  .profile-insights { grid-template-columns: 1fr; }
  .project-card { grid-template-columns: 1fr 1fr; }
  .meeting-layout { grid-template-columns: 1fr; }
  .meeting-list-panel { max-height: 260px; }
  .summary-grid { grid-template-columns: 1fr; }
  .summary-card.wide { grid-column: auto; }
  .field-wide { grid-column: auto; }
  .content-view { padding: 36px 20px 60px; }
  .queue-toolbar { align-items: flex-start; flex-direction: column; }
  .intake-filter-side { align-items: flex-start; flex-direction: column; }
  .queue-filters { overflow-x: auto; width: 100%; padding-bottom: 3px; }
  .batch-actions { flex-wrap: wrap; }
  .modal { padding: 12px; }
  .modal-panel { max-height: calc(100vh - 24px); }
  .user-admin-card { grid-template-columns: auto 1fr; }
  .composer { width: calc(100% - 28px); margin-bottom: 14px; }
  .messages { padding: 24px 18px; }
}
