*,:after,:before{box-sizing:border-box}body,html{margin:0;padding:0;height:100%;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,sans-serif;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;background:#f5f5f5}::-webkit-scrollbar{width:6px}::-webkit-scrollbar-track{background:transparent}::-webkit-scrollbar-thumb{background:#d9d9d9;border-radius:3px}::-webkit-scrollbar-thumb:hover{background:#bfbfbf}.agent-layout{display:flex;height:100vh;overflow:hidden}.agent-sidebar{width:360px;min-width:360px;background:#fff;border-right:1px solid #f0f0f0;display:flex;flex-direction:column;height:100%}.agent-sidebar-header{min-height:60px;padding:10px 12px;border-bottom:1px solid #f0f0f0;display:flex;align-items:center;gap:8px}.agent-conn-dot{width:8px;height:8px;border-radius:50%;background:#52c41a;box-shadow:0 0 0 3px rgba(82,196,26,.18);flex-shrink:0;margin-left:4px}.agent-conn-dot[data-connected="0"]{background:#ff4d4f;box-shadow:0 0 0 3px rgba(255,77,79,.18);animation:agent-conn-blink 1.2s ease-in-out infinite}@keyframes agent-conn-blink{50%{opacity:.35}}.project-switcher-trigger{flex:1 1;min-width:0;display:flex;align-items:center;gap:10px;padding:6px 10px 6px 8px;border:0;border-radius:12px;background:transparent;cursor:pointer;text-align:left;font:inherit;color:inherit;transition:background .15s}.project-switcher-trigger.open,.project-switcher-trigger:hover{background:#f5f5f5}.project-switcher-trigger:disabled{cursor:default;opacity:.7}.project-switcher-name{flex:1 1;min-width:0;font-size:16px;font-weight:700;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;letter-spacing:-.01em}.project-switcher-caret{font-size:11px;color:#8c8c8c;transition:transform .15s}.project-switcher-trigger.open .project-switcher-caret{transform:rotate(180deg)}.project-switcher-menu .ant-dropdown-menu{min-width:280px;padding:6px;border-radius:14px}.project-switcher-menu .ant-dropdown-menu-item{border-radius:10px;padding:8px 10px}.project-switcher-menu .ant-dropdown-menu-item.project-switcher-current{color:inherit!important;cursor:default;background:#f0f5ff}.project-switcher-item{display:flex;align-items:center;gap:10px;min-width:0}.project-switcher-item-name{flex:1 1;min-width:0;font-size:14px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.agent-detail,.agent-sidebar{position:relative}.panel-resize-handle{position:absolute;top:0;bottom:0;width:8px;cursor:col-resize;z-index:5;-webkit-app-region:no-drag;touch-action:none}.panel-resize-handle.right{right:-4px}.panel-resize-handle.left{left:-4px}.panel-resize-handle:after{content:"";position:absolute;top:0;bottom:0;left:3px;width:2px;background:#1677ff;opacity:0;transition:opacity .15s}.panel-resize-handle.active:after,.panel-resize-handle:hover:after{opacity:1}body.is-resizing,body.is-resizing *{cursor:col-resize!important;-webkit-user-select:none!important;-moz-user-select:none!important;user-select:none!important}.agent-chat-toolbar{flex-shrink:0;padding-right:8px;margin-right:4px;border-right:1px solid #f0f0f0}.agent-chat-toolbar,.desktop-navbar{display:flex;align-items:center;gap:2px}.desktop-navbar .ant-btn{color:#595959}.desktop-navbar .ant-btn:disabled{color:#d9d9d9}body.is-desktop .agent-sidebar-header{-webkit-app-region:drag;-webkit-user-select:none;-moz-user-select:none;user-select:none}body.is-desktop .agent-sidebar-header [role=button],body.is-desktop .agent-sidebar-header a,body.is-desktop .agent-sidebar-header button{-webkit-app-region:no-drag}body.is-desktop-mac .agent-sidebar-header{padding-left:84px}body.is-desktop .agent-chat-header,body.is-desktop .agent-detail-header{-webkit-app-region:drag;-webkit-user-select:none;-moz-user-select:none;user-select:none}body.is-desktop .agent-chat-header .agent-translation-ctrl,body.is-desktop .agent-chat-header .ant-avatar,body.is-desktop .agent-chat-header .ant-tag,body.is-desktop .agent-chat-header a,body.is-desktop .agent-chat-header button,body.is-desktop .agent-detail-header button{-webkit-app-region:no-drag}.agent-translation-ctrl{display:inline-flex;align-items:center;gap:2px;margin-left:8px;padding:2px 4px 2px 10px;border:1px solid #f0f0f0;border-radius:16px;background:#fafafa;white-space:nowrap}.agent-translation-toggle{display:inline-flex;align-items:center;gap:6px}.agent-main{flex:1 1;min-width:0;background:#fafafa}.agent-detail,.agent-main{display:flex;flex-direction:column;height:100%}.agent-detail{width:360px;min-width:360px;background:#fff;border-left:1px solid #f0f0f0;overflow:hidden}.agent-detail-header{padding:0 12px 0 16px;min-height:60px;align-items:center;justify-content:space-between;font-weight:600}.agent-detail-header,.agent-detail-section{border-bottom:1px solid #f0f0f0;display:flex}.agent-detail-section{flex-direction:column}.agent-detail-section:last-child{border-bottom:none}.agent-detail-section-title{padding:10px 16px;font-size:13px;font-weight:600;color:#595959;background:#fafafa;display:flex;align-items:center;justify-content:space-between;min-height:40px}.agent-detail-scroll{flex:1 1;min-height:0;overflow-y:auto;padding:12px 16px}.agent-detail-tabs .ant-tabs-nav{margin-bottom:0}.agent-detail-tabs .ant-tabs-nav:before{border-bottom:none}.agent-detail-tabs .ant-tabs-tab{padding:10px 0;font-size:13px;font-weight:600}.agent-detail-tabs .ant-tabs-tab+.ant-tabs-tab{margin-left:20px}.agent-detail-grid{display:grid;grid-template-columns:1fr 1fr;grid-gap:10px 12px;gap:10px 12px;padding:12px 16px}.agent-detail-row{display:flex;flex-direction:column;gap:2px;min-width:0}.agent-detail-editable .agent-detail-edit-btn{opacity:0;transition:opacity .15s}.agent-detail-editable .agent-detail-edit-btn:focus-visible,.agent-detail-editable:hover .agent-detail-edit-btn{opacity:1}.agent-legacy-chat-item{text-align:left;border:1px solid #f0f0f0;background:#fff;border-radius:10px;padding:10px 12px;cursor:pointer;width:100%}.agent-legacy-chat-item:hover{border-color:#91caff;background:#f5faff}@media (max-width:1280px){.agent-detail{width:320px;min-width:320px}}.chat-messages{flex:1 1;overflow-y:auto;padding:16px 24px;display:flex;flex-direction:column;gap:4px}.chat-bubble-wrap{display:flex;margin-bottom:2px}.chat-bubble-wrap.customer{justify-content:flex-start}.chat-bubble-wrap.agent{justify-content:flex-end}.chat-bubble-wrap.system{justify-content:center}.chat-bubble{max-width:100%;width:-moz-fit-content;width:fit-content;padding:10px 14px;border-radius:16px;font-size:14px;line-height:1.5;word-break:keep-all;overflow-wrap:anywhere;white-space:pre-wrap}.chat-bubble.customer{background:#fff;border:1px solid #f0f0f0;border-bottom-left-radius:4px;color:#262626}.chat-bubble.agent{background:#1677ff;color:#fff;border-bottom-right-radius:4px}.chat-bubble.system{background:transparent;color:#8c8c8c;font-size:12px;padding:6px 12px}.chat-bubble-meta{font-size:11px;color:#8c8c8c;margin-top:2px;display:flex;align-items:center;gap:4px}.chat-bubble-wrap.agent .chat-bubble-meta{justify-content:flex-end}.chat-bubble-sender{font-size:12px;font-weight:500;margin-bottom:4px;color:#595959}.chat-attachment-image .ant-image{display:block}.chat-attachment-image .ant-image img{cursor:zoom-in}.chat-image-toolbar{padding:8px 20px;color:#fff;font-size:18px;background:rgba(0,0,0,.45);border-radius:100px;-webkit-backdrop-filter:blur(4px);backdrop-filter:blur(4px)}.chat-image-toolbar .anticon{padding:8px;border-radius:50%;cursor:pointer;transition:background .15s}.chat-image-toolbar .anticon:hover{background:hsla(0,0%,100%,.2)}.chat-input-area{padding:12px 24px;background:#fff;border-top:1px solid #f0f0f0;display:flex;flex-direction:column;gap:8px;transition:background .15s}.chat-input-area.drag-over{background:#e6f4ff;box-shadow:inset 0 0 0 2px #91caff}.chat-input-row{display:flex;align-items:flex-end;gap:8px}.chat-input-attachments{display:flex;flex-wrap:wrap;gap:8px}.chat-input-attachment{position:relative;border:1px solid #e5e7eb;border-radius:8px;background:#fafafa;overflow:hidden}.chat-input-attachment.image{width:72px;height:72px}.chat-input-attachment.image img{width:100%;height:100%;object-fit:cover;display:block}.chat-input-attachment.file{height:72px;max-width:240px;padding:8px 26px 20px 10px;display:flex;align-items:center}.chat-input-attachment-file{display:flex;align-items:center;gap:8px;min-width:0}.chat-input-attachment-name{font-size:12px;color:#333;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;max-width:160px}.chat-input-attachment-size{position:absolute;left:0;right:0;bottom:0;font-size:10px;line-height:16px;text-align:center;color:#fff;background:rgba(0,0,0,.45)}.chat-input-attachment-remove{position:absolute;top:2px;right:2px;width:18px;height:18px;padding:0;border:0;border-radius:50%;background:#fff;color:#ff4d4f;cursor:pointer;display:flex;align-items:center;justify-content:center;font-size:16px;line-height:1}.chat-input-attachment-remove:hover{color:#cf1322}.chat-input-area textarea{flex:1 1;border:1px solid #d9d9d9;border-radius:8px;padding:8px 12px;font-size:14px;resize:none;outline:none;font-family:inherit;line-height:1.5;max-height:120px;transition:border-color .2s}.chat-input-area textarea:focus{border-color:#1677ff}.widget-page{height:100vh;max-height:100vh}.widget-container,.widget-page{display:flex;flex-direction:column}.widget-container{flex:1 1;min-height:0;background:#fff}@media (min-width:520px) and (min-height:480px){.widget-page{align-items:center;justify-content:center;padding:32px 16px;background-color:#eef1f5}.widget-page .widget-container{flex:none;width:100%;max-width:420px;height:100%;max-height:720px;border-radius:20px;overflow:hidden;box-shadow:0 12px 40px rgba(15,23,42,.14),0 2px 8px rgba(15,23,42,.08)}.widget-page.embedded{padding:0;background:#fff;align-items:stretch;justify-content:flex-start}.widget-page.embedded .widget-container{flex:1 1;max-width:none;max-height:none;border-radius:0;box-shadow:none}}@media (max-width:599px){.widget-page{height:100dvh;max-height:100dvh}.widget-container{padding-bottom:env(safe-area-inset-bottom,0)}}.widget-header{background:linear-gradient(180deg,#eff6ff,#f8fafc);padding:16px 20px;color:#0f172a;border-bottom:1px solid #e2e8f0}.widget-header h3{margin:0;font-size:16px;font-weight:600;color:#0f172a}.widget-header p{margin:4px 0 0;font-size:12px;color:#64748b}.widget-messages{flex:1 1;overflow-y:auto;padding:16px;display:flex;flex-direction:column;gap:4px;background:#fafafa}.widget-input-area{padding:12px 16px;background:#fff;border-top:1px solid #f0f0f0;display:flex;align-items:flex-end;gap:8px}.widget-input-area textarea{flex:1 1;border:1px solid #d9d9d9;border-radius:20px;padding:8px 16px;font-size:14px;resize:none;outline:none;font-family:inherit;line-height:1.5;max-height:100px;overflow-y:auto;scrollbar-width:none;-ms-overflow-style:none}.widget-input-area textarea::-webkit-scrollbar{width:0;height:0;display:none}.widget-input-area textarea:focus{border-color:#1677ff}.widget-footer{text-align:center;padding:6px;font-size:11px;color:#bfbfbf;background:#fff;border-top:1px solid #f5f5f5}.widget-footer-link{color:inherit;text-decoration:none;cursor:pointer}.widget-footer-link:focus,.widget-footer-link:hover{color:#1677ff;text-decoration:underline}.ai-suggestion{margin:0 24px 8px;border:1px solid #bfdbfe;background:#eff6ff;border-radius:12px;padding:10px 12px;display:flex;flex-direction:column;gap:8px;flex-shrink:0;max-height:40vh}.ai-suggestion-header{display:flex;align-items:center;justify-content:space-between;gap:8px}.ai-suggestion-title{display:flex;align-items:center;gap:6px;color:#2563eb;font-weight:600;font-size:13px;min-width:0}.ai-suggestion-sub{color:#94a3b8;font-weight:400;font-size:11px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.ai-suggestion-body{background:#fff;border:1px solid #dbeafe;border-radius:10px;padding:10px 12px;font-size:14px;line-height:1.55;color:#0f172a;cursor:pointer;overflow-y:auto;min-height:0;word-break:break-word;transition:border-color .15s,box-shadow .15s}.ai-suggestion-body:focus-visible,.ai-suggestion-body:hover{border-color:#60a5fa;box-shadow:0 0 0 2px rgba(96,165,250,.25);outline:none}.ai-suggestion-body.pending{display:flex;align-items:center;gap:8px;color:#64748b;cursor:default;font-size:13px}.ai-suggestion-actions{display:flex;justify-content:flex-end;gap:8px}body.is-desktop .agent-detail-header .ant-segmented{-webkit-app-region:no-drag}.ai-assistant{flex:1 1;min-height:0;display:flex;flex-direction:column}.ai-assistant-tabs{flex-shrink:0;padding:8px 8px 0}.ai-assistant-tabs .ant-tabs-nav{margin-bottom:0}.ai-assistant-tab-label{display:inline-block;max-width:110px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;vertical-align:bottom}.ai-assistant-context{display:flex;align-items:center;justify-content:space-between;gap:8px;padding:8px 12px;border-bottom:1px solid #f0f0f0;font-size:11px;color:#94a3b8}.ai-assistant-messages{flex:1 1;min-height:0;overflow-y:auto;padding:12px;display:flex;flex-direction:column;gap:10px;background:#fafafa}.ai-assistant-hint{margin:auto 0;text-align:center;font-size:12px;color:#94a3b8;line-height:1.6}.ai-assistant-msg{display:flex;flex-direction:column;max-width:92%}.ai-assistant-msg.user{align-self:flex-end;align-items:flex-end}.ai-assistant-msg.model{align-self:flex-start}.ai-assistant-msg .bubble{padding:8px 12px;border-radius:12px;font-size:13px;line-height:1.55;word-break:break-word;white-space:pre-wrap}.ai-assistant-msg.user .bubble{background:#1677ff;color:#fff}.ai-assistant-msg.model .bubble{background:#eff6ff;border:1px solid #dbeafe;color:#0f172a;white-space:normal}.ai-assistant-msg.model.error .bubble{background:#fff1f0;border-color:#ffccc7;color:#cf1322}.ai-assistant-msg .actions{display:flex;gap:2px;margin-top:2px}.ai-assistant-msg .actions .ant-btn{font-size:11px;color:#64748b}.ai-assistant-input{flex-shrink:0;display:flex;align-items:flex-end;gap:8px;padding:10px 12px;border-top:1px solid #f0f0f0;background:#fff}.typing-indicator{display:flex;align-items:center;gap:4px;padding:8px 14px;color:#8c8c8c;font-size:13px}.typing-dots{display:flex;gap:3px}.typing-dots span{width:6px;height:6px;background:#bfbfbf;border-radius:50%;animation:typing-bounce 1.4s ease-in-out infinite both}.typing-dots span:first-child{animation-delay:-.32s}.typing-dots span:nth-child(2){animation-delay:-.16s}@keyframes typing-bounce{0%,80%,to{transform:scale(.6);opacity:.4}40%{transform:scale(1);opacity:1}}.room-item{display:flex;align-items:center;padding:12px 16px;cursor:pointer;transition:background .15s;border-bottom:1px solid #fafafa}.room-item:hover{background:#f5f5ff}.room-item.active{background:#e6f4ff}.room-item.checked{background:#eef4ff}.room-item.unread .room-item-name{font-weight:700;color:#111827}.room-item.unread .room-item-preview{color:#434343}.room-item-unread-dot{display:inline-block;width:9px;height:9px;border-radius:50%;background:#1677ff;box-shadow:0 0 0 2px #fff}.room-bulk-bar{display:flex;align-items:center;justify-content:space-between;gap:8px;padding:8px 16px;background:#f8fafc;border-top:1px solid #f0f0f0;border-bottom:1px solid #f0f0f0}.room-bulk-bar .ant-checkbox-wrapper{flex-shrink:0}.room-bulk-count{font-size:12px;color:#595959;white-space:nowrap}.room-bulk-actions{display:flex;align-items:center;gap:6px;flex-wrap:wrap;justify-content:flex-end}.room-bulk-actions .ant-btn{font-size:12px}.room-item-content{flex:1 1;min-width:0;margin-left:12px}.room-item-name{font-weight:500;font-size:14px;color:#262626}.room-item-preview{font-size:13px;color:#8c8c8c;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;margin-top:2px;max-width:100%;display:block}.room-item-preview-sender{color:#595959;font-weight:500}.room-item-meta{display:flex;flex-direction:column;align-items:flex-end;gap:4px;margin-left:8px;flex-shrink:0}.room-item-time{font-size:11px;color:#bfbfbf;white-space:nowrap}.widget-back-btn{flex-shrink:0;margin-left:-6px}.widget-chat-list{flex:1 1;min-height:0;display:flex;flex-direction:column;background:#fafafa}.widget-chat-list>.ant-spin-nested-loading{flex:1 1;min-height:0;overflow-y:auto}.widget-chat-list-empty{flex:1 1;display:flex;align-items:center;justify-content:center;padding:24px}.widget-chat-items{display:flex;flex-direction:column;gap:8px;padding:12px}.widget-chat-item{display:flex;align-items:center;gap:10px;width:100%;padding:12px 14px;border:1px solid #edf0f3;border-radius:12px;background:#fff;text-align:left;cursor:pointer;font:inherit;color:inherit;transition:border-color .15s,box-shadow .15s}.widget-chat-item:hover{border-color:#bcd4ff;box-shadow:0 2px 8px rgba(22,119,255,.08)}.widget-chat-item.current{border-color:#91caff}.widget-chat-item-main{flex:1 1;min-width:0}.widget-chat-item-bottom,.widget-chat-item-top{display:flex;align-items:center;justify-content:space-between;gap:8px}.widget-chat-item-bottom{margin-top:6px}.widget-chat-status{font-size:11px;font-weight:600;padding:1px 8px;border-radius:10px}.widget-chat-status.open{color:#1677ff;background:#e6f0ff}.widget-chat-status.closed{color:#8c8c8c;background:#f2f3f5}.widget-chat-time{font-size:11px;color:#a0a7b1;white-space:nowrap}.widget-chat-preview{flex:1 1;min-width:0;font-size:13px;color:#434a54;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.widget-chat-unread{flex-shrink:0;min-width:18px;height:18px;padding:0 5px;border-radius:9px;background:#ff4d4f;color:#fff;font-size:11px;font-weight:600;line-height:18px;text-align:center}.widget-chat-item .widget-chat-item-arrow{flex-shrink:0;font-size:11px;color:#c0c6cf}.widget-chat-list-footer,.widget-history-footer{padding:12px 16px;background:#fff;border-top:1px solid #f0f0f0}.widget-history-footer{display:flex;flex-direction:column;align-items:center;gap:8px;text-align:center}.prechat-form{flex:1 1;display:flex;flex-direction:column;justify-content:center;padding:24px}.prechat-form h3{text-align:center;margin-bottom:24px;font-size:18px;color:#262626}.empty-chat{flex:1 1;display:flex;flex-direction:column;align-items:center;justify-content:center;color:#bfbfbf;gap:12px}.empty-chat .anticon{font-size:48px}