.ai-support-root {
  --ai-support-ink: #152849;
  --ai-support-muted: #66768d;
  --ai-support-blue: #2467e8;
  position: relative;
  z-index: 120;
  color: var(--ai-support-ink);
  font: 14px/1.65 "Microsoft YaHei", "PingFang SC", sans-serif;
  text-align: left;
}
.ai-support-root *, .ai-support-root *::before, .ai-support-root *::after { box-sizing: border-box; }
.ai-support-root [hidden] { display: none !important; }
.ai-support-root button, .ai-support-root textarea, .ai-support-root select { font: inherit; }
.ai-support-root button, .ai-support-root a, .ai-support-root summary, .ai-support-root select { -webkit-tap-highlight-color: transparent; }
.ai-support-root button { cursor: pointer; }
.ai-support-root button:disabled { cursor: not-allowed; }
.ai-support-root :is(button, a, textarea, select, summary):focus-visible { outline: 3px solid #2b9cdb; outline-offset: 3px; }
.ai-support-root svg { display: block; width: 20px; height: 20px; flex-shrink: 0; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.ai-support-launcher { position: fixed; right: 24px; bottom: max(24px, env(safe-area-inset-bottom)); display: flex; align-items: center; gap: 11px; height: 56px; padding: 0 21px 0 12px; border: 1px solid #80c9ff66; border-radius: 18px; background: linear-gradient(120deg, #123466, #1455a2); color: white; box-shadow: 0 7px 26px #0d376b45, inset 0 1px 0 #ffffff21; transition: transform .2s, box-shadow .2s; font-weight: 700 !important; letter-spacing: .04em; }
.ai-support-launcher:hover { transform: translateY(-3px); box-shadow: 0 10px 32px #0d376b55; }
.ai-support-launcher-icon { display: grid; place-items: center; width: 34px; height: 34px; color: #86eaff; background: #ffffff12; border-radius: 11px; }
.ai-support-unread { position: absolute; top: -4px; right: -4px; border: 3px solid white; border-radius: 50%; width: 13px; height: 13px; background: #f08049; }
.ai-support-panel { position: fixed; right: 24px; bottom: 94px; width: 408px; height: min(736px, calc(100dvh - 118px)); min-height: 300px; display: flex; flex-direction: column; overflow: hidden; border: 1px solid #dce6f2; border-radius: 22px; background: #f7f9fd; box-shadow: 0 24px 80px #061c4933, 0 3px 12px #061c4912; animation: ai-support-appear .22s ease-out; }
.ai-support-header { flex-shrink: 0; display: flex; align-items: center; gap: 11px; padding: 19px 16px 18px 21px; color: #fff; background: radial-gradient(ellipse at 95% 0, #215a89 0, transparent 67%), #102c54; }
.ai-support-avatar { display: grid; place-items: center; flex-shrink: 0; width: 42px; height: 42px; border: 1px solid #7dd9fb42; border-radius: 13px; background: linear-gradient(135deg, #349fe633, #44dfea19); color: #94edff; }
.ai-support-avatar svg { width: 25px; height: 25px; }
.ai-support-heading { flex: 1; min-width: 0; }
.ai-support-title-row { display: flex; align-items: center; gap: 8px; }
.ai-support-title { margin: 0; font-size: 17px; font-weight: 700; letter-spacing: .03em; line-height: 1.5; }
.ai-support-badge { padding: 0 5px; border: 1px solid #85e4ff4a; border-radius: 4px; font-size: 9px; letter-spacing: .08em; color: #a2e7fc; line-height: 17px; }
.ai-support-subtitle { margin: 2px 0 0; font-size: 11px; color: #c1d4e7; white-space: nowrap; }
.ai-support-icon-button { display: grid; place-items: center; flex-shrink: 0; width: 44px; height: 44px; padding: 0; border: 0; border-radius: 10px; color: inherit; background: transparent; }
.ai-support-header .ai-support-icon-button { width: 38px; min-height: 44px; }
.ai-support-icon-button:hover { background: #ffffff16; }
.ai-support-icon-button:disabled { opacity: .4; }
.ai-support-context { flex-shrink: 0; display: flex; align-items: center; gap: 7px; padding: 10px 21px; color: #60728e; border-bottom: 1px solid #e7edf6; background: #fff; font-size: 11px; }
.ai-support-context svg { width: 14px; height: 14px; color: #7688a4; }
.ai-support-context strong { color: #355375; font-weight: 500; }
.ai-support-context span:last-child { margin-left: auto; color: #55708d; }
.ai-support-scroll { flex: 1; min-height: 0; padding: 24px 21px 18px; overflow: auto; overscroll-behavior: contain; scrollbar-width: thin; scrollbar-color: #c9d7e8 transparent; }
.ai-support-welcome-mark { float: right; display: grid; place-items: center; width: 40px; height: 40px; margin: 0 0 8px 8px; border: 1px solid #c5ddff; border-radius: 13px; color: #3171e1; background: linear-gradient(135deg, #fff, #e5efff); box-shadow: 0 4px 10px #376bc909; }
.ai-support-welcome-mark svg { width: 26px; height: 26px; }
.ai-support-welcome h3 { font-size: 22px; letter-spacing: -.04em; line-height: 1.5; margin: 0 0 7px; font-weight: 700; }
.ai-support-welcome h3 span { color: #286de0; }
.ai-support-welcome p { color: #677991; font-size: 14px; line-height: 1.85; margin: 0; }
.ai-support-capabilities { display: flex; gap: 15px; margin: 16px 0 25px; color: #5f7490; font-size: 11px; }
.ai-support-capabilities span { display: flex; align-items: center; gap: 5px; }
.ai-support-capabilities svg { width: 13px; height: 13px; color: #4879bb; }
.ai-support-suggestion-label { display: flex; align-items: center; gap: 7px; margin-bottom: 11px; font-size: 11px; color: #78879e; }
.ai-support-suggestion-label::after { content: ""; height: 1px; flex: 1; background: #e2e9f3; margin-left: 4px; }
.ai-support-questions { display: grid; gap: 8px; }
.ai-support-question { width: 100%; display: flex; align-items: center; gap: 10px; padding: 11px 13px; min-height: 46px; border: 1px solid #e1e8f2; border-radius: 10px; text-align: left; font-size: 13px !important; background: white; color: #334c70; transition: border-color .18s, background .18s; }
.ai-support-question:hover { border-color: #a2c4f8; background: #f1f7ff; }
.ai-support-question > span:first-child { font-size: 10px; color: #8ba2c3; font-weight: 700; font-family: Consolas, monospace; }
.ai-support-question svg { width: 16px; height: 16px; margin-left: auto; color: #92a6c1; }
.ai-support-welcome-foot { margin-top: 16px !important; color: #8190a5 !important; font-size: 10px !important; text-align: center; }
.ai-support-message { margin: 22px 0; min-width: 0; overflow-wrap: anywhere; }
.ai-support-message:first-child { margin-top: 0; }
.ai-support-message-label { display: flex; align-items: center; gap: 6px; margin-bottom: 7px; font-size: 11px; color: #7c8ba1; }
.ai-support-message-label svg { width: 15px; height: 15px; color: #467ee1; }
.ai-support-message-user .ai-support-message-label { justify-content: flex-end; }
.ai-support-bubble { width: fit-content; max-width: 100%; padding: 13px 15px; border: 1px solid #e4eaf3; border-radius: 3px 14px 14px; background: white; font-size: 14px; line-height: 1.85; overflow-wrap: anywhere; }
.ai-support-message-user .ai-support-bubble { margin-left: auto; color: #fff; border-color: transparent; border-radius: 14px 3px 14px 14px; background: #2869d9; white-space: pre-wrap; }
.ai-support-bubble p { margin: 0 0 9px; }
.ai-support-bubble p:last-child { margin-bottom: 0; }
.ai-support-bubble ul, .ai-support-bubble ol { margin: 8px 0; padding-left: 20px; }
.ai-support-bubble li { margin: 5px 0; }
.ai-support-match { display: flex; align-items: center; gap: 6px; margin: 0 0 10px; color: #23765e; font-size: 11px; font-weight: 600; }
.ai-support-match::before { content: ""; width: 6px; height: 6px; flex-shrink: 0; border-radius: 50%; background: currentColor; }
.ai-support-match[data-match="CLARIFY"] { color: #356fb3; }
.ai-support-match[data-match="NO_MATCH"] { color: #95692b; }
.ai-support-candidates, .ai-support-no-match { margin-top: 13px; padding-top: 12px; border-top: 1px solid #e4ebf5; }
.ai-support-candidate-label { color: #4b6488; font-size: 12px; font-weight: 600; }
.ai-support-candidate { display: flex; align-items: center; gap: 10px; width: 100%; min-height: 44px; margin: 7px 0; padding: 9px 11px; border: 1px solid #d5e4f8; border-radius: 9px; background: #f3f7ff; color: #285da3; text-align: left; font-size: 13px !important; line-height: 1.65; overflow-wrap: anywhere; }
.ai-support-candidate span { flex: 1; min-width: 0; }
.ai-support-candidate svg { width: 15px; height: 15px; }
.ai-support-candidate:hover:not(:disabled) { border-color: #9bbdeb; background: #eaf2ff; }
.ai-support-candidate:disabled { color: #71839a; background: #f4f6fa; }
.ai-support-candidate-hint { margin: 9px 0 0 !important; color: #75839a; font-size: 11px; }
.ai-support-no-match p { color: #6c7e97; font-size: 12px; }
.ai-support-refine { min-height: 44px; padding: 0 12px; border: 1px solid #d5e4f8; border-radius: 8px; background: #f3f7ff; color: #285da3; font-size: 12px !important; }
.ai-support-refine:hover { border-color: #9bbdeb; background: #eaf2ff; }
.ai-support-message-status { margin-top: 6px; color: #76869e; font-size: 11px; }
.ai-support-message-user .ai-support-message-status { text-align: right; }
.ai-support-message-status[data-state="stopped"], .ai-support-message-status[data-state="interrupted"], .ai-support-message-status[data-state="failed"], .ai-support-message-status[data-state="unknown"] { color: #8d611d; }
.ai-support-thinking { display: flex; align-items: center; gap: 8px; color: #7485a0; font-size: 12px; }
.ai-support-thinking::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: #5c94ed; animation: ai-support-pulse 1.3s ease-in-out infinite; }
.ai-support-sources { margin-top: 13px; padding-top: 11px; border-top: 1px solid #e9eef6; font-size: 12px; }
.ai-support-sources > p { margin: 0 0 6px; font-size: 10px; color: #8190a5; }
.ai-support-sources details { margin: 4px 0; }
.ai-support-sources summary { cursor: pointer; padding: 8px 0; color: #4f6e96; }
.ai-support-sources details p { padding: 8px 10px; margin: 0 0 4px; color: #6d7d94; background: #f5f8fc; border-radius: 6px; }
.ai-support-sources a { display: inline-flex; align-items: center; min-height: 44px; color: #2564c4; }
.ai-support-product { display: grid; grid-template-columns: 34px 1fr; gap: 10px; padding: 13px; margin-top: 11px; border: 1px solid #dce7f7; border-radius: 10px; background: linear-gradient(115deg, #f1f6ff, #fbfdff); }
.ai-support-product-icon { display: grid; place-items: center; width: 33px; height: 33px; border: 1px solid #d3e3fb; border-radius: 9px; color: #5685ce; background: #fff; }
.ai-support-product h4 { margin: 0; font-size: 13px; font-weight: 700; }
.ai-support-product p { margin: 4px 0 0; font-size: 12px; color: #6f8099; }
.ai-support-product a { display: inline-flex; align-items: center; gap: 7px; min-height: 44px; margin-bottom: -7px; font-size: 12px; font-weight: 700; color: #2564c4; }
.ai-support-product a svg { width: 14px; height: 14px; }
.ai-support-copy { display: flex; align-items: center; gap: 5px; min-height: 44px; padding: 0 2px; margin: 3px 0 -12px; color: #718198; border: 0; background: transparent; font-size: 11px !important; }
.ai-support-copy:hover { color: #2467e8; }
.ai-support-copy svg { width: 13px; height: 13px; }
.ai-support-bottom { position: absolute; right: 50%; bottom: 191px; transform: translateX(50%); min-height: 36px; padding: 6px 14px; border: 1px solid #d5e1f2; border-radius: 20px; background: white; color: #3e6baa; box-shadow: 0 3px 15px #26477515; font-size: 12px !important; }
.ai-support-notice { flex-shrink: 0; padding: 8px 17px; border-top: 1px solid #efe2c8; background: #fff8ed; color: #876027; font-size: 11px; line-height: 1.65; }
.ai-support-notice button { display: inline; min-height: 32px; margin-left: 7px; padding: 0 3px; border: 0; color: #345e9b; font-weight: 700; background: transparent; font-size: 11px; }
.ai-support-composer { flex-shrink: 0; padding: 12px 16px 10px; border-top: 1px solid #e2eaf5; background: #fff; }
.ai-support-input-shell { padding: 11px 11px 9px; border: 1px solid #dce4ef; border-radius: 12px; background: #fff; transition: border-color .2s, box-shadow .2s; }
.ai-support-input-shell:focus-within { border-color: #8bb5f4; box-shadow: 0 0 0 3px #296fe80a; }
.ai-support-input { display: block; resize: none; width: 100%; min-height: 41px; max-height: 100px; margin: 0; padding: 0 2px; border: 0; outline: none !important; background: transparent; color: #243d5f; font-size: 14px !important; line-height: 1.65; }
.ai-support-input::placeholder { color: #8797ad; }
.ai-support-input-tools { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: 6px; }
.ai-support-count { color: #8796aa; font-size: 10px; }
.ai-support-count[data-invalid="true"] { color: #b33c33; }
.ai-support-send { min-height: 36px; min-width: 74px; padding: 6px 13px; display: flex; align-items: center; justify-content: center; gap: 7px; border: 0; border-radius: 8px; background: #2869df; color: white; font-size: 12px !important; transition: background .2s; }
.ai-support-send:disabled { color: #718bad; background: #e7eef9; }
.ai-support-send:not(:disabled):hover { background: #1456c8; }
.ai-support-send svg { width: 14px; height: 14px; }
.ai-support-send[data-stop="true"] { color: #3f6089; background: #edf2fa; }
.ai-support-composer-meta { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: 8px; color: #8895a9; font-size: 9px; }
.ai-support-composer-meta span:first-child { display: flex; align-items: center; gap: 4px; }
.ai-support-composer-meta svg { width: 11px; height: 11px; }
.ai-support-demo { flex-shrink: 0; padding: 6px 17px; border-top: 1px dashed #cbd9ec; background: #f2f6fc; color: #60799b; font-size: 10px; }
.ai-support-demo summary { cursor: pointer; min-height: 22px; }
.ai-support-demo label { display: flex; align-items: center; gap: 8px; margin: 7px 0; }
.ai-support-demo select { min-width: 0; flex: 1; min-height: 35px; border: 1px solid #c8d8ee; border-radius: 6px; background: #fff; color: #45648a; font-size: 11px; }
.ai-support-load-more { display: block; min-height: 44px; margin: -8px auto 14px; border: 0; background: transparent; color: #4f76ac; font-size: 12px !important; }
.ai-support-sr { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.ai-support-root[data-open="false"] .ai-support-thinking::before { animation: none; }
/* The existing site toast is deliberately moved to the opposite corner. */
body.ai-support-equipped > .toast { left: 24px; right: auto; bottom: 24px; max-width: calc(100vw - 48px); min-width: 0; }
@keyframes ai-support-appear { from { opacity: 0; transform: translateY(9px); } to { opacity: 1; transform: translateY(0); } }
@keyframes ai-support-pulse { 50% { opacity: .35; transform: scale(.8); } }
@media (max-width: 760px) {
  .ai-support-launcher { right: 16px; bottom: max(16px, env(safe-area-inset-bottom)); height: 52px; border-radius: 16px; }
  .ai-support-root[data-open="true"] .ai-support-launcher { visibility: hidden; }
  .ai-support-panel { inset: var(--ai-support-top, 0px) 0 auto; height: var(--ai-support-height, 100dvh); width: 100%; min-height: 0; max-height: none; border: 0; border-radius: 0; }
  .ai-support-header { padding-top: max(16px, env(safe-area-inset-top)); }
  .ai-support-header .ai-support-icon-button { width: 44px; }
  .ai-support-scroll { padding: 22px 20px; }
  .ai-support-composer { padding-bottom: max(12px, env(safe-area-inset-bottom)); }
  .ai-support-input { font-size: 16px !important; }
  .ai-support-send { min-height: 44px; }
  .ai-support-shortcut { display: none; }
  .ai-support-question { min-height: 48px; }
  .ai-support-demo summary { min-height: 28px; }
  body.ai-support-equipped > .toast { left: 16px; bottom: 85px; max-width: calc(100vw - 32px); }
}
@media (max-height: 510px) and (max-width: 760px) {
  .ai-support-header { padding-top: 6px; padding-bottom: 6px; }
  .ai-support-context, .ai-support-composer-meta, .ai-support-demo { display: none; }
  .ai-support-composer { padding-top: 7px; }
  .ai-support-input { min-height: 28px; max-height: 54px; }
}
@media (prefers-reduced-motion: reduce) {
  .ai-support-root *, .ai-support-root *::before, .ai-support-root *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}
