/* 官网智能问答助手 · 2026-10-20
   兼容 360 兼容模式（ES5，无箭头函数 / 无模板字符串 / 无 flex gap 依赖） */

/* 竖条按钮 · 窗口里每次只露两个字 · 2026-10-20 四改：
   窗口 20px 只放一行（在线 / 咨询 轮流），每 2.4s 停一下、0.4s 滚一格；图标 14px，整体 46x56 */
#msbot-btn{position:fixed;right:22px;bottom:22px;width:46px;height:56px;padding:6px 0 5px;
  border-radius:13px;overflow:hidden;animation:msbotBreath 3s ease-in-out infinite;
  background:linear-gradient(160deg,rgba(52,206,127,.58) 0%,rgba(16,172,98,.66) 48%,rgba(6,122,72,.73) 100%);
  -webkit-backdrop-filter:blur(9px) saturate(1.55);backdrop-filter:blur(9px) saturate(1.55);
  color:#fff;border:1.5px solid rgba(255,255,255,.72);cursor:pointer;z-index:2147482000;
  box-shadow:0 8px 22px rgba(16,150,80,.34),inset 0 1px 0 rgba(255,255,255,.58),inset 0 0 16px rgba(255,255,255,.14);
  display:flex;flex-direction:column;align-items:center;justify-content:center;
  transition:transform .18s ease,box-shadow .18s ease,background .18s ease;
  font:700 13.5px/1 -apple-system,"PingFang SC","Microsoft YaHei",sans-serif;
  letter-spacing:.5px;text-indent:.5px;
  text-shadow:0 1px 2px rgba(4,58,30,.9),0 0 5px rgba(4,58,30,.55),0 0 12px rgba(4,58,30,.28)}
#msbot-btn:hover{animation-play-state:paused;
  background:linear-gradient(160deg,rgba(110,231,160,.82),rgba(34,197,94,.86) 48%,rgba(12,140,80,.9));
  border-color:#fff;
  box-shadow:0 12px 28px rgba(16,150,80,.46),0 0 22px rgba(74,222,128,.34),inset 0 1px 0 rgba(255,255,255,.55)}
/* 不支持毛玻璃的老内核（360 兼容/IE）：没有 blur 就不能再透，否则白字糊在浅绿上 —— 这里给实色兜底 */
@supports not ((backdrop-filter:blur(4px)) or (-webkit-backdrop-filter:blur(4px))){
  #msbot-btn{background:linear-gradient(160deg,#3ecf7c 0%,#20b45e 46%,#0d844c 100%)}
}
/* 单行窗口：只露 20px 一个字位，四行轨道每格滚一次，首尾同字，归零无跳帧 */
#msbot-btn .msbot-roll{display:block;width:100%;height:20px;overflow:hidden;text-align:center;position:relative}
#msbot-btn .msbot-track{display:block;width:100%;animation:msbotRoll 6s cubic-bezier(.55,.06,.44,.94) infinite}
#msbot-btn .msbot-track i{display:block;height:20px;line-height:20px;font-style:normal;
  white-space:nowrap;font-size:13.5px;font-weight:700}
#msbot-btn:hover .msbot-track{animation-play-state:paused}
@keyframes msbotRoll{
  0%,38%{transform:translateY(0)}        /* 在线 */
  44%,82%{transform:translateY(-20px)}   /* 咨询 */
  88%,100%{transform:translateY(-40px)}  /* 在线（与首行同字，回零无感） */
}
/* 在线小点：5px 收在右上角 */
#msbot-btn .msbot-dot{position:absolute;top:5px;right:5px;width:5px;height:5px;border-radius:50%;
  background:#ffffff;box-shadow:0 0 0 2px rgba(255,255,255,.26);animation:msbotDot 1.8s ease-in-out infinite}
@keyframes msbotDot{0%,100%{opacity:1}50%{opacity:.35}}
#msbot-btn svg{width:14px;height:14px;display:block;margin:0 0 4px;flex:0 0 auto}

/* 首次进入的引导气泡：不点按钮也能看见入口 */
#msbot-teaser{position:fixed;right:22px;bottom:88px;max-width:250px;background:#fff;color:#1a2332;
  border:1px solid #e3e8ef;border-radius:12px;padding:11px 34px 11px 13px;font:13.5px/1.55 -apple-system,"PingFang SC","Microsoft YaHei",sans-serif;
  box-shadow:0 10px 30px rgba(16,32,64,.16);z-index:2147481999;display:none}
#msbot-teaser.on{display:block;animation:msbIn .3s ease}
#msbot-teaser::after{content:"";position:absolute;right:26px;bottom:-6px;width:12px;height:12px;
  background:#fff;border-right:1px solid #e3e8ef;border-bottom:1px solid #e3e8ef;transform:rotate(45deg)}
#msbot-teaser b{display:block;font-weight:700;margin-bottom:2px;color:#1e3a5f}
#msbot-teaser .x{position:absolute;right:8px;top:6px;cursor:pointer;color:#9fb2c9;font-size:15px;line-height:1;
  padding:4px}
@keyframes msbIn{from{opacity:0;transform:translateY(8px)}to{opacity:1;transform:translateY(0)}}

#msbot{position:fixed;right:22px;bottom:92px;width:384px;max-width:calc(100vw - 32px);
  height:580px;max-height:calc(100vh - 120px);background:rgba(255,255,255,.96);
  -webkit-backdrop-filter:blur(14px) saturate(1.3);backdrop-filter:blur(14px) saturate(1.3);
  border-radius:18px;z-index:9999;
  box-shadow:0 20px 56px rgba(16,32,64,.26);display:none;overflow:hidden;flex-direction:column;
  font:15px/1.65 -apple-system,BlinkMacSystemFont,"PingFang SC","Microsoft YaHei",sans-serif;
  color:#1a2332;border:1.5px solid rgba(30,58,95,.14)}
#msbot.on{display:flex}

.msbot-head{flex:0 0 auto;background:linear-gradient(135deg,#1e3a5f,#2c5282);color:#fff;padding:14px 16px;
  display:flex;align-items:center;justify-content:space-between}
/* 小鸣头像（窗口标题栏）：cylinder-calc 站标裁成的圆标 */
.msbot-head .msbot-hava{width:34px;height:34px;border-radius:50%;background:#fff;
  border:1.5px solid rgba(255,255,255,.7);margin-right:10px;flex:0 0 auto}
.msbot-head .t{font-size:15px;font-weight:700;letter-spacing:.3px}
.msbot-head .s{font-size:12px;color:#b8cdf0;margin-top:2px;font-weight:400}
.msbot-hact{display:flex;align-items:center}
.msbot-head .newc{background:rgba(255,255,255,.14);border:0;color:#fff;width:28px;height:28px;
  border-radius:8px;cursor:pointer;font-size:17px;line-height:1;padding:0;margin-right:8px;
  font-family:inherit;transition:background .15s ease}
.msbot-head .newc:hover{background:rgba(255,255,255,.28)}
.msbot-head .x{background:rgba(255,255,255,.14);border:0;color:#fff;width:28px;height:28px;
  border-radius:6px;cursor:pointer;font-size:16px;line-height:1;padding:0}

.msbot-body{flex:1 1 auto;min-height:0;padding:14px 14px 8px;overflow-y:auto;background:#f4f6fa;
  -webkit-overflow-scrolling:touch}

.msbot-msg{margin-bottom:12px;display:flex;align-items:flex-start}
.msbot-msg.me{justify-content:flex-end}
/* 小鸣头像（消息行）：每条 AI 回答左侧的小圆标 */
.msbot-msg.bot .msbot-ava{width:26px;height:26px;border-radius:50%;background:#fff;
  border:1px solid #dbe3ee;margin-right:7px;flex:0 0 auto;margin-top:2px}
/* 在线用户统一取名「我」：气泡右侧小圆牌 */
.msbot-msg.me .msbot-uava{font-style:normal;flex:0 0 auto;width:26px;height:26px;line-height:26px;
  text-align:center;border-radius:50%;background:#1e3a5f;color:#fff;font-size:12px;
  margin-left:7px;margin-top:2px;font-family:inherit}
.msbot-bub{max-width:86%;padding:10px 13px;border-radius:12px;font-size:14.5px;line-height:1.65;
  word-wrap:break-word;overflow-wrap:anywhere;white-space:pre-wrap}
.msbot-msg.bot .msbot-bub{background:#fff;border:1px solid #e3e8ef;border-top-left-radius:4px;
  box-shadow:0 1px 3px rgba(20,40,80,.04)}
.msbot-msg.me .msbot-bub{background:#1e3a5f;color:#fff;border-top-right-radius:4px}

.msbot-src{margin-top:8px;padding-top:8px;border-top:1px dashed #e3e8ef;font-size:12.5px}
/* 导航链接做成按钮样式，比裸 URL 好点 */
.msbot-bub a.msbot-nav{display:inline-block;margin:6px 6px 0 0;padding:6px 12px;border-radius:16px;
  background:#eef4ff;color:#1e3a5f;font-size:13px;text-decoration:none;border:1px solid #b8cdf0}
.msbot-bub a.msbot-nav:hover{background:#1e3a5f;color:#fff;border-color:#1e3a5f}
/* 液压缸选型计算器：必须独占一行（JS 已在按钮前后强制换行，这里块级 + 通宽再兜一层） */
.msbot-bub a.msbot-calc{display:block;margin:8px 0 2px;padding:8px 12px;border-radius:10px;
  background:#ecfdf3;border:1px solid #abdfc0;color:#0d6b3d;font-weight:700;text-align:center;
  box-sizing:border-box}
.msbot-bub a.msbot-calc:hover{background:#0d6b3d;border-color:#0d6b3d;color:#fff}

.msbot-src a{display:block;color:#2c5282;text-decoration:none;padding:3px 0;overflow:hidden;
  text-overflow:ellipsis;white-space:nowrap}
.msbot-src a:hover{text-decoration:underline}
.msbot-src b{color:#6b7a90;font-weight:400;display:block;margin-bottom:2px}

.msbot-act{margin-top:8px;font-size:12px;color:#6b7a90}
.msbot-act b{cursor:pointer;font-weight:400;padding:2px 8px;border:1px solid #d3dae5;
  border-radius:10px;margin-right:6px;background:#fff;display:inline-block}
.msbot-act b:hover{border-color:#1e3a5f;color:#1e3a5f}

.msbot-quick{flex:0 0 auto;padding:0 14px 10px;background:#f4f6fa}
.msbot-quick b{display:inline-block;font-weight:400;font-size:12.5px;padding:6px 11px;
  background:#fff;border:1px solid #d3dae5;border-radius:14px;color:#3c4a5e;cursor:pointer;
  margin:0 6px 6px 0;transition:.15s}
.msbot-quick b:hover{background:#1e3a5f;color:#fff;border-color:#1e3a5f}

.msbot-input{flex:0 0 auto;border-top:1px solid #e3e8ef;padding:11px 12px 10px;display:flex;align-items:flex-end;
  background:rgba(255,255,255,.72)}
/* 输入框：2px 粗边 + 14px 方圆角 + 内浅底，聚焦时主色描边加光圈 */
.msbot-input textarea{flex:1 1 auto;min-width:0;box-sizing:border-box;
  border:2px solid #c6d3e2;border-radius:14px;outline:0;resize:none;
  font:14.5px/1.45 inherit;color:#1a2332;
  height:48px;max-height:96px;padding:8px 12px;background:#f7f9fc;
  /* 空/单行时不露滚动条（原来 3px 溢出就常驻一条，压在右边框上）；
     真的超 96px 由 JS 切成 auto，才出现细滚动条 */
  overflow-y:hidden;
  box-shadow:inset 0 1px 2px rgba(16,32,64,.05);
  transition:border-color .16s ease,box-shadow .16s ease,background .16s ease}
/* 细滚动条：4px、圆角、半透明，贴着右边框也不扎眼 */
.msbot-input textarea::-webkit-scrollbar{width:4px}
.msbot-input textarea::-webkit-scrollbar-thumb{background:#c6d3e2;border-radius:2px}
.msbot-input textarea::-webkit-scrollbar-thumb:hover{background:#9fb2c9}
.msbot-input textarea::-webkit-scrollbar-track{background:transparent}
.msbot-input textarea::placeholder{color:#93a5bb}
.msbot-input textarea:focus{border-color:#16a34a;background:#fff;
  box-shadow:0 0 0 3px rgba(22,163,74,.13),inset 0 1px 2px rgba(16,32,64,.04)}
/* 发送键：46px 方形圆角，和输入框等高 */
.msbot-input .send{width:46px;height:46px;box-sizing:border-box;border-radius:14px;
  border:2px solid rgba(255,255,255,.55);
  background:linear-gradient(135deg,#2fbf62,#14803c);color:#fff;
  cursor:pointer;font-size:16px;flex:0 0 auto;margin-left:9px;padding:0;line-height:1;
  box-shadow:inset 0 1px 0 rgba(255,255,255,.45),inset 0 -2px 4px rgba(10,70,32,.2);
  transition:background .16s ease,box-shadow .16s ease,transform .12s ease}
.msbot-input .send:hover{background:linear-gradient(135deg,#47d47a,#189c4a);
  box-shadow:inset 0 1px 0 rgba(255,255,255,.55),inset 0 -2px 5px rgba(10,70,32,.24)}
.msbot-input .send:active{transform:translateY(1px)}
.msbot-input .send:disabled{background:#c9d2df;border-color:rgba(255,255,255,.7);
  box-shadow:none;cursor:default;transform:none}
.msbot-tip{flex:0 0 auto;font-size:11px;color:#6b7f96;text-align:center;padding:0 0 8px;background:rgba(255,255,255,.72);letter-spacing:.2px}

.msbot-warn{display:none;flex:0 0 auto;margin:0 12px 8px;padding:7px 11px;border-radius:10px;
  background:#fef2f2;border:1px solid #fecaca;color:#b91c1c;font-size:12px;line-height:1.45;
  letter-spacing:.2px}
.msbot-warn.on{display:block}

/* 被拦下的那句话：浅红气泡 + 前置 ❗ + 末尾「未发出」 */
/* 注意：必须带上 .msbot-msg.me，否则被「我的气泡」深蓝底盖掉（优先级 0,4,0） */
.msbot-msg.me .msbot-bub.warn{background:#fef2f2;border:1.5px solid #fecaca;color:#7f1d1d;
  border-bottom-right-radius:4px;box-shadow:none}
.msbot-msg.me .msbot-bub.warn i.w{font-style:normal;font-weight:700;color:#dc2626;margin-right:6px;font-size:15px;
  vertical-align:-1px}
.msbot-msg.me .msbot-bub.warn .warn-tip{display:block;margin-top:7px;padding-top:6px;border-top:1px dashed #fca5a5;
  font-size:11.5px;color:#b91c1c;letter-spacing:.3px;line-height:1.3}

.msbot-loading span{display:inline-block;width:6px;height:6px;border-radius:50%;background:#9fb2c9;
  margin-right:4px;animation:msb 1s infinite}
.msbot-loading span:nth-child(2){animation-delay:.15s}
.msbot-loading span:nth-child(3){animation-delay:.3s}
@keyframes msb{0%,60%,100%{opacity:.3;transform:translateY(0)}30%{opacity:1;transform:translateY(-3px)}}

@media (max-width:720px){
  #msbot{right:0;bottom:0;width:100%;max-width:100%;height:100%;max-height:100%;border-radius:0;
    border:0}
  #msbot-btn{right:12px;bottom:14px;width:44px;height:52px;border-radius:12px;padding:5px 0 4px;
    background:linear-gradient(160deg,rgba(52,206,127,.60) 0%,rgba(16,172,98,.68) 48%,rgba(6,122,72,.75) 100%);
    font-size:12.5px}
  #msbot-btn svg{width:13px;height:13px;margin-bottom:3px}
  #msbot-btn .msbot-track i{font-size:12.5px}
  #msbot{border-radius:0;border:0}
  .msbot-input{padding:10px 10px 8px}
  .msbot-input textarea{height:46px;padding:7px 11px;border-radius:13px}
  .msbot-input .send{width:44px;height:44px;border-radius:13px;margin-left:8px}
  #msbot-teaser{right:12px;bottom:80px;max-width:220px}
  .msbot-body{padding-bottom:12px}
  .msbot-head{padding-top:16px}
  .msbot-head .msbot-hava{width:30px;height:30px}
  .msbot-msg.bot .msbot-ava{width:24px;height:24px}
  .msbot-msg.me .msbot-uava{width:24px;height:24px;line-height:24px;font-size:11px}
}

/* m 站菜单抽屉拉开时，咨询入口和引导气泡让位，别压着菜单项（2026-10-20） */
body.ms-drawer-open #msbot-btn,
body.ms-drawer-open #msbot-teaser{display:none !important}

/* 「回到顶部」让位（2026-10-20 实测）：竖条按钮占住右下角后，原 totop 被盖掉 95.5%
   两端都改成与按钮并排（按钮左侧），互不遮挡 */
.ms-totop{right:78px !important;bottom:22px !important}
@media (max-width:720px){
  .ms-totop{right:64px !important;bottom:14px !important}
}
