.chat-shell{--chat-bg:var(--bg,#f6f9fc);--chat-card:var(--card,#fff);--chat-line:var(--line,#e3e8ee);--chat-ink:var(--ink,#0a2540);--chat-muted:var(--muted,#697386);--chat-brand:var(--brand,#635bff);--chat-tick-read:#34a1eb;background:var(--chat-card);border:1px solid var(--chat-line);border-radius:16px;flex-direction:column;height:100%;min-height:0;display:flex;overflow:hidden}.chat-header{border-bottom:1px solid var(--chat-line);background:var(--chat-card);flex-shrink:0;justify-content:space-between;align-items:center;gap:12px;padding:14px 18px;display:flex}.chat-header-title{color:var(--chat-ink);font-size:15px;font-weight:600}.chat-header-sub{color:var(--chat-muted);font-size:12.5px}.chat-scroll{background:var(--chat-bg);flex-direction:column;flex:1;gap:4px;min-height:0;padding:18px 16px 8px;display:flex;overflow-y:auto}.chat-day-divider{color:var(--chat-muted);background:var(--chat-card);border:1px solid var(--chat-line);border-radius:999px;align-self:center;margin:10px 0;padding:3px 10px;font-size:11.5px}.chat-row{width:100%;margin:2px 0;display:flex}.chat-row--user{justify-content:flex-end}.chat-row--staff{justify-content:flex-start}.chat-bubble-wrap{flex-direction:column;max-width:78%;display:flex;position:relative}.chat-bubble{word-break:break-word;white-space:pre-wrap;border-radius:16px;padding:8px 12px;font-size:14px;line-height:1.45;position:relative;box-shadow:0 1px 1px #0a254008}.chat-row--user .chat-bubble{background:var(--chat-brand);color:#fff;border-bottom-right-radius:4px}.chat-row--staff .chat-bubble{background:var(--chat-card);color:var(--chat-ink);border:1px solid var(--chat-line);border-bottom-left-radius:4px}.chat-bubble-meta{opacity:.85;align-items:center;gap:4px;margin-top:3px;font-size:10.5px;display:flex}.chat-row--user .chat-bubble-meta{color:#ffffffd9;justify-content:flex-end;padding-right:2px}.chat-row--staff .chat-bubble-meta{color:var(--chat-muted);padding-left:2px}.chat-reply-quote{opacity:.9;background:#ffffff1f;border-left:3px solid #ffffff8c;border-radius:6px;margin-bottom:6px;padding:4px 8px;font-size:12.5px}.chat-row--staff .chat-reply-quote{border-left-color:var(--chat-brand);background:#635bff0f}.chat-reply-quote-name{margin-bottom:1px;font-weight:600;display:block}.chat-swipe-reply{color:var(--chat-muted);opacity:0;pointer-events:none;transition:opacity .12s;position:absolute;top:50%;transform:translateY(-50%)}.chat-row--user .chat-swipe-reply{left:-30px}.chat-row--staff .chat-swipe-reply{right:-30px}.chat-bubble-wrap:hover .chat-swipe-reply{opacity:.55}.chat-reply-trigger{background:var(--chat-card);border:1px solid var(--chat-line);width:26px;height:26px;color:var(--chat-muted);opacity:0;cursor:pointer;border-radius:999px;justify-content:center;align-items:center;transition:opacity .12s;display:flex;position:absolute;top:-8px}.chat-row--user .chat-reply-trigger{left:-32px}.chat-row--staff .chat-reply-trigger{right:-32px}.chat-bubble-wrap:hover .chat-reply-trigger{opacity:1}.chat-typing{color:var(--chat-muted);align-items:center;gap:5px;padding:8px 14px;font-size:12.5px;display:flex}.chat-typing-dots{gap:3px;display:inline-flex}.chat-typing-dots span{background:var(--chat-muted);border-radius:50%;width:5px;height:5px;animation:1.2s ease-in-out infinite chat-typing-bounce}.chat-typing-dots span:nth-child(2){animation-delay:.15s}.chat-typing-dots span:nth-child(3){animation-delay:.3s}@keyframes chat-typing-bounce{0%,60%,to{opacity:.5;transform:translateY(0)}30%{opacity:1;transform:translateY(-4px)}}.chat-composer{border-top:1px solid var(--chat-line);background:var(--chat-card);flex-shrink:0;padding:10px 12px}.chat-reply-preview{background:var(--chat-bg);border:1px solid var(--chat-line);border-radius:10px;justify-content:space-between;align-items:center;gap:8px;margin-bottom:8px;padding:6px 10px;font-size:12.5px;display:flex}.chat-reply-preview-text{color:var(--chat-muted);text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.chat-reply-preview-text b{color:var(--chat-ink)}.chat-reply-preview-close{color:var(--chat-muted);cursor:pointer;background:0 0;border:none;flex-shrink:0;padding:2px;display:flex}.chat-composer-row{align-items:flex-end;gap:8px;display:flex}.chat-icon-btn{border:1px solid var(--chat-line);background:var(--chat-card);width:38px;height:38px;color:var(--chat-muted);cursor:pointer;border-radius:10px;flex-shrink:0;justify-content:center;align-items:center;transition:background .15s,color .15s,border-color .15s;display:flex}.chat-icon-btn:hover{background:var(--chat-bg);color:var(--chat-ink)}.chat-icon-btn.is-primary{background:var(--chat-brand);border-color:var(--chat-brand);color:#fff}.chat-icon-btn.is-primary:hover{background:var(--brand-hover,#7a73ff)}.chat-icon-btn:disabled{opacity:.45;cursor:not-allowed}.chat-textarea{resize:none;border:1px solid var(--chat-line);min-height:38px;max-height:140px;color:var(--chat-ink);background:var(--chat-bg);border-radius:12px;flex:1;padding:9px 12px;font-family:inherit;font-size:14px;line-height:1.4}.chat-textarea:focus{border-color:var(--chat-brand);background:var(--chat-card);outline:none}.chat-empty{height:100%;color:var(--chat-muted);text-align:center;flex-direction:column;justify-content:center;align-items:center;gap:8px;padding:24px;display:flex}.chat-empty h3{color:var(--chat-ink);margin:0;font-size:15px}.chat-empty p{max-width:320px;margin:0;font-size:13px}.chat-list{flex-direction:column;height:100%;display:flex;overflow-y:auto}.chat-list-row{border-bottom:1px solid var(--chat-line,#e3e8ee);cursor:pointer;text-align:left;background:0 0;border-left:3px solid #0000;align-items:center;gap:12px;width:100%;padding:12px 14px;transition:background .12s;display:flex}.chat-list-row:hover{background:var(--chat-bg,#f6f9fc)}.chat-list-row.is-active{background:var(--brand-soft,#f1f0ff);border-left-color:var(--chat-brand,#635bff)}.chat-list-avatar{background:var(--brand-soft,#f1f0ff);width:42px;height:42px;color:var(--chat-brand,#635bff);border-radius:50%;flex-shrink:0;justify-content:center;align-items:center;font-size:15px;font-weight:700;display:flex}.chat-list-body{flex:1;min-width:0}.chat-list-top{justify-content:space-between;align-items:baseline;gap:8px;display:flex}.chat-list-email{color:var(--chat-ink,#0a2540);text-overflow:ellipsis;white-space:nowrap;font-size:13.5px;font-weight:600;overflow:hidden}.chat-list-time{color:var(--chat-muted,#697386);flex-shrink:0;font-size:11.5px}.chat-list-bottom{justify-content:space-between;align-items:center;gap:8px;margin-top:2px;display:flex}.chat-list-preview{color:var(--chat-muted,#697386);text-overflow:ellipsis;white-space:nowrap;font-size:12.5px;overflow:hidden}.chat-list-badge{background:var(--chat-brand,#635bff);color:#fff;border-radius:999px;flex-shrink:0;justify-content:center;align-items:center;min-width:19px;height:19px;padding:0 5px;font-size:11px;font-weight:700;display:flex}.chat-split{grid-template-columns:320px 1fr;gap:16px;height:calc(100dvh - 220px);min-height:480px;display:grid}@media (max-width:900px){.chat-split{grid-template-columns:1fr;height:calc(100dvh - 180px)}.chat-split[data-mobile-view=list] .chat-split-thread,.chat-split[data-mobile-view=thread] .chat-split-list{display:none}}.chat-split-list,.chat-split-thread{border:1px solid var(--chat-line,#e3e8ee);background:var(--chat-card,#fff);border-radius:16px;height:100%;min-height:0;overflow:hidden}.chat-back-btn{color:var(--chat-muted);cursor:pointer;background:0 0;border:none;align-items:center;gap:4px;padding:4px 2px;font-size:13px;display:none}@media (max-width:900px){.chat-back-btn{display:flex}}.dash-single-page{grid-template-columns:1.1fr 1fr;align-items:start;gap:24px;margin-top:20px;display:grid}@media (max-width:900px){.dash-single-page{grid-template-columns:1fr}}.dash-section{min-width:0}.dash-section-title{color:var(--ink,#0a2540);margin:0 0 12px;font-size:15px;font-weight:600}.dash-section--chat{position:sticky;top:16px}@media (max-width:900px){.dash-section--chat{position:static}}.dash-chat-frame{height:560px}@media (max-width:900px){.dash-chat-frame{height:70vh;min-height:420px}}.chat-toast-viewport{z-index:300;flex-direction:column;gap:10px;width:min(340px,100vw - 32px);display:flex;position:fixed;top:18px;right:18px}.chat-toast{background:var(--chat-card,#fff);border:1px solid var(--chat-line,#e3e8ee);cursor:pointer;border-radius:14px;align-items:flex-start;gap:10px;padding:12px 14px;animation:.18s ease-out chat-toast-in;display:flex;box-shadow:0 12px 30px #0a25401f}@keyframes chat-toast-in{0%{opacity:0;transform:translateY(-8px)}to{opacity:1;transform:translateY(0)}}.chat-toast-icon{background:var(--brand-soft,#f1f0ff);width:34px;height:34px;color:var(--chat-brand,#635bff);border-radius:50%;flex-shrink:0;justify-content:center;align-items:center;display:flex}.chat-toast-title{color:var(--chat-ink,#0a2540);font-size:13px;font-weight:600}.chat-toast-body{color:var(--chat-muted,#697386);text-overflow:ellipsis;-webkit-line-clamp:2;-webkit-box-orient:vertical;font-size:12.5px;display:-webkit-box;overflow:hidden}.chat-sidebar-badge{background:var(--red,#cd3d64);color:#fff;border-radius:999px;justify-content:center;align-items:center;min-width:18px;height:18px;margin-left:auto;padding:0 5px;font-size:10.5px;font-weight:700;display:flex}.chat-notify-viewport{z-index:500;flex-direction:column;gap:8px;max-width:340px;display:flex;position:fixed;top:16px;right:16px}.chat-notify-toast{color:#fff;text-align:left;background:#1a1f36;border-radius:12px;flex-direction:column;gap:2px;padding:12px 14px;animation:.2s cubic-bezier(.16,1,.3,1) chatNotifyIn;display:flex;box-shadow:0 16px 32px -12px #0a254080}.chat-notify-toast:hover{background:#232945}.chat-notify-toast-title{color:#a79bff;font-size:12px;font-weight:700}.chat-notify-toast-preview{color:#e4e7f1;text-overflow:ellipsis;-webkit-line-clamp:2;-webkit-box-orient:vertical;max-width:100%;font-size:13px;line-height:1.4;display:-webkit-box;overflow:hidden}@keyframes chatNotifyIn{0%{opacity:0;transform:translateY(-8px)}to{opacity:1;transform:translateY(0)}}@media (max-width:480px){.chat-notify-viewport{max-width:none;top:12px;left:12px;right:12px}}
