/* ===== 官网 AI 客服悬浮窗 ===== */
.ai-widget { position: fixed; right: 20px; bottom: 20px; z-index: 9999; font-family: "Microsoft YaHei","PingFang SC",sans-serif; }
.ai-toggle { width: 56px; height: 56px; border-radius: 50%; border: none; cursor: pointer; background: linear-gradient(135deg,#1a3a6b,#2a5298); color:#fff; box-shadow:0 4px 16px rgba(26,54,107,.4); display:flex; align-items:center; justify-content:center; transition:all .3s ease; }
.ai-toggle:hover { transform:translateY(-3px); box-shadow:0 6px 22px rgba(26,54,107,.55); }
.ai-toggle.active { width:200px; border-radius:28px; justify-content:flex-start; padding:0 16px 0 16px; }
.ai-toggle .ai-toggle-icon { font-size:20px; }
.ai-toggle .ai-toggle-text { margin-left:10px; font-size:15px; font-weight:600; white-space:nowrap; }
.ai-panel { position:absolute; right:0; bottom:72px; width:360px; max-width:92vw; height:520px; max-height:78vh; background:#fff; border-radius:16px; box-shadow:0 8px 40px rgba(0,0,0,.25); display:flex; flex-direction:column; overflow:hidden; transform:scale(.85); opacity:0; transform-origin:bottom right; transition:all .25s ease; pointer-events:none; }
.ai-panel.show { transform:scale(1); opacity:1; pointer-events:auto; }
.ai-panel-header { background:linear-gradient(135deg,#1a3a6b,#2a5298); color:#fff; padding:12px 14px; display:flex; align-items:center; gap:10px; }
.ai-avatar { width:38px; height:38px; border-radius:50%; background:rgba(255,255,255,.18); display:flex; align-items:center; justify-content:center; font-size:18px; flex-shrink:0; }
.ai-title h3 { font-size:14px; font-weight:600; line-height:1.2; }
.ai-status { font-size:11px; opacity:.85; display:flex; align-items:center; gap:4px; }
.ai-status::before { content:""; width:7px; height:7px; border-radius:50%; background:#4ade80; }
.ai-close { background:none; border:none; color:#fff; font-size:16px; cursor:pointer; margin-left:auto; opacity:.85; }
.ai-close:hover { opacity:1; }
.ai-messages { flex:1; overflow-y:auto; padding:14px 16px; background:#f7f9fc; }
.ai-msg { max-width:80%; padding:9px 13px; border-radius:14px; margin-bottom:10px; font-size:14px; line-height:1.55; word-wrap:break-word; }
.ai-msg.user { margin-left:auto; background:#1a3a6b; color:#fff; border-bottom-right-radius:4px; }
.ai-msg.bot { background:#fff; color:#1a202c; border:1px solid #e8ecf3; border-bottom-left-radius:4px; }
.ai-msg.bot .ai-link { color:#2a5298; text-decoration:underline; cursor:pointer; }
.ai-suggest { padding:8px 14px; background:#fff; border-top:1px solid #eef1f6; display:flex; flex-wrap:wrap; gap:6px; }
.ai-suggest button { font-size:12px; padding:5px 11px; border:1px solid #d4dbe8; background:#fff; color:#2a5298; border-radius:14px; cursor:pointer; transition:all .2s; }
.ai-suggest button:hover { background:#eef2fb; }
.ai-input-row { display:flex; padding:10px 12px; background:#fff; border-top:1px solid #e8ecf3; gap:8px; }
.ai-input-row input { flex:1; border:1px solid #d4dbe8; border-radius:20px; padding:9px 16px; font-size:14px; outline:none; }
.ai-input-row input:focus { border-color:#2a5298; }
.ai-input-row button { width:38px; height:38px; border:none; border-radius:50%; background:#1a3a6b; color:#fff; cursor:pointer; display:flex; align-items:center; justify-content:center; flex-shrink:0; }
.ai-input-row button:hover { background:#2a5298; }
.ai-typing { display:inline-flex; gap:4px; padding:4px 0; }
.ai-typing span { width:7px; height:7px; border-radius:50%; background:#9aa7bd; animation:ai-bounce 1.2s infinite ease-in-out; }
.ai-typing span:nth-child(2){ animation-delay:.2s; }
.ai-typing span:nth-child(3){ animation-delay:.4s; }
@keyframes ai-bounce { 0%,60%,100%{ transform:translateY(0); opacity:.5; } 30%{ transform:translateY(-6px); opacity:1; } }
.ai-footnote { font-size:11px; color:#9aa7bd; text-align:center; padding:5px; background:#f7f9fc; }
@media (max-width:480px){ .ai-panel { height:460px; } .ai-toggle.active { width:64px; } .ai-toggle-text { display:none; } }
