.knowledge-chat[hidden],#companion .companion-profile[hidden],.chat-start[hidden]{display:none!important}
#companion.conversation-open{width:min(1000px,94vw);max-height:92dvh;padding:clamp(18px,3vw,34px);background:#f3fbfe}
.knowledge-chat{color:#174957;font-family:Inter,"Microsoft YaHei",sans-serif}
.chat-heading,.chat-controls{display:flex;align-items:center;gap:12px;flex-wrap:wrap;justify-content:space-between}
.chat-heading strong{font-size:22px}.chat-privacy,.chat-reading{font-size:14px;color:#477181;line-height:1.6}
.chat-controls{justify-content:flex-start}.chat-controls label{display:flex;align-items:center;gap:8px;font-size:14px}
.chat-history{max-width:300px;border:1px solid #b9dce8;border-radius:14px;background:#fff;padding:10px;color:#174957}
.chat-transcript{max-height:43dvh;min-height:120px;overflow:auto;overscroll-behavior:contain;margin:16px 0;padding:4px 8px 4px 0}
.chat-bubble{max-width:92%;padding:15px 19px;border-radius:20px;background:#fff;border:1px solid #d1e9ef;margin-bottom:14px}
.chat-bubble p{white-space:pre-wrap;overflow-wrap:anywhere;line-height:1.8;margin:0;font-size:16px}
.chat-bubble.reader{margin-left:auto;background:#dcf3f9}.chat-bubble.chat-error{background:#edf5f8;color:#4b6672}
.chat-basis{border-top:1px solid #d2e9ef;padding-top:10px;margin-top:12px;font-size:14px;color:#356876}
.chat-basis summary{cursor:pointer;font-weight:700;color:#087e9a;list-style-position:inside}.chat-basis>small{font-weight:700}
.chat-basis-verified summary{color:#08785f}.chat-basis-collecting>small,.chat-basis-collecting summary{color:#8a6500}.chat-basis-insufficient>small,.chat-basis-insufficient summary{color:#8a4d20}.chat-basis-general>small,.chat-basis-general summary{color:#6a7d84}
.chat-source-entry{display:grid;gap:6px;margin-top:10px;padding:10px 12px;border-radius:12px;background:#f5fbfd}.chat-source-entry strong{font-size:14px;color:#174957}.chat-source-entry p{font-size:13px;line-height:1.65;margin:0;color:#365b67}.chat-source-entry a{color:#087e9a;text-decoration:underline;width:max-content}.chat-source-entry small{font-size:12px;color:#637a82}
.chat-notice{min-height:22px;font-size:14px;line-height:1.5}
.chat-form{display:flex;align-items:flex-end;gap:12px}.chat-form textarea{width:100%;min-width:0;flex:1 1 auto;resize:vertical;min-height:85px;max-height:160px;border:1px solid #a9d4e2;border-radius:18px;padding:15px;background:#fff;color:#174957;font:inherit}
.chat-form button{flex-shrink:0}.chat-form button:disabled{opacity:.55;cursor:wait}
.chat-form .chat-speech{min-width:3.2rem;padding:12px 10px}.chat-form .chat-speech[aria-pressed="true"]{background:#b9322a;color:#fff;border-color:#8f211c}
.chat-interest-option{display:flex;align-items:center;gap:8px;font-size:13px;margin:12px 0}.chat-interest-option input{width:auto;min-width:unset;flex:none}
.chat-recovery{display:flex;align-items:center;gap:8px;flex-wrap:wrap;font-size:13px;margin:0 0 8px}.chat-recovery[hidden]{display:none!important}.chat-recovery .quiet-button{padding:7px 10px;min-height:36px;font-size:13px}.chat-elapsed{font-variant-numeric:tabular-nums;white-space:nowrap;margin-right:auto;color:#477181}
.advisor-welcome{position:fixed;z-index:2600;display:flex;align-items:flex-start;gap:6px;padding:10px;border:1px solid #8fc8d1;border-radius:16px;background:#f2fbfd;box-shadow:0 14px 38px #17495730;color:#174957;visibility:hidden;opacity:0;transform:translateY(-4px);transition:opacity .16s ease,transform .16s ease}.advisor-welcome.is-visible{visibility:visible;opacity:1;transform:none}.advisor-welcome-prompt{flex:1;border:0;background:transparent;color:inherit;text-align:left;font:700 14px/1.65 "Microsoft YaHei",sans-serif;cursor:pointer}.advisor-welcome-close{width:30px;height:30px;flex:0 0 30px;border:0;border-radius:50%;background:#dceff3;color:#174957;font-size:20px;line-height:1;cursor:pointer}
@media(max-width:620px){#companion.conversation-open{width:96vw;max-height:96dvh;padding:16px}.chat-heading strong{font-size:19px}.chat-controls .quiet-button{padding:8px 12px}.chat-history{max-width:180px}.chat-transcript{max-height:40dvh}.chat-bubble{max-width:100%;padding:12px}.chat-form{gap:8px}.chat-form button{padding:12px 18px;min-width:unset}.chat-form textarea{padding:10px;font-size:16px}.chat-privacy{font-size:12px}}
