/* ===== 智考元 · 角色数字员工浮动助手 (DigiTeam Agent) ===== */
.de-launcher {
  position: fixed;
  right: 22px;
  bottom: 22px;
  width: 58px;
  height: 58px;
  border-radius: 50%;
  background: linear-gradient(135deg, #534AB7 0%, #7C74E0 100%);
  box-shadow: 0 8px 24px rgba(83,74,183,.45);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 26px;
  color: #fff;
  cursor: pointer;
  z-index: 99990;
  transition: transform .18s ease, box-shadow .18s ease;
  border: none;
}
.de-launcher:hover { transform: scale(1.08); box-shadow: 0 12px 30px rgba(83,74,183,.55); }
.de-launcher .de-badge {
  position: absolute; top: -4px; right: -4px;
  min-width: 20px; height: 20px; padding: 0 5px;
  background: #f5a623; color: #1b1b2f; font-size: 11px; font-weight: 800;
  border-radius: 10px; display: flex; align-items: center; justify-content: center;
  border: 2px solid #fff;
}

.de-panel {
  position: fixed;
  right: 22px;
  bottom: 92px;
  width: 380px;
  max-width: calc(100vw - 44px);
  height: 540px;
  max-height: calc(100vh - 130px);
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 18px 50px rgba(20,20,50,.28);
  display: none;
  flex-direction: column;
  overflow: hidden;
  z-index: 99991;
  font-family: -apple-system, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  color: #1b1b2f;
}
.de-panel.open { display: flex; }

.de-panel-hd {
  background: linear-gradient(135deg, #534AB7 0%, #6a61d6 100%);
  color: #fff;
  padding: 14px 16px;
  display: flex;
  align-items: center;
  gap: 10px;
}
.de-panel-hd .de-logo {
  width: 34px; height: 34px; border-radius: 9px;
  background: rgba(255,255,255,.18);
  display: flex; align-items: center; justify-content: center; font-size: 18px;
}
.de-panel-hd .de-hd-txt { flex: 1; line-height: 1.3; }
.de-panel-hd .de-hd-txt b { font-size: 14px; }
.de-panel-hd .de-hd-txt span { font-size: 11px; opacity: .8; }
.de-panel-hd .de-close {
  background: rgba(255,255,255,.18); border: none; color: #fff;
  width: 28px; height: 28px; border-radius: 8px; cursor: pointer; font-size: 16px;
}
.de-panel-hd .de-close:hover { background: rgba(255,255,255,.3); }

.de-body { flex: 1; overflow-y: auto; padding: 14px; background: #f6f6fb; }
.de-body::-webkit-scrollbar { width: 6px; }
.de-body::-webkit-scrollbar-thumb { background: #cfcfe6; border-radius: 3px; }

.de-emp {
  background: #fff; border: 1px solid #ececf5; border-radius: 12px;
  padding: 12px; margin-bottom: 12px; cursor: pointer;
  transition: border-color .15s ease, box-shadow .15s ease;
}
.de-emp:hover { border-color: #534AB7; box-shadow: 0 4px 14px rgba(83,74,183,.12); }
.de-emp-top { display: flex; align-items: center; gap: 11px; }
.de-emp-avatar {
  width: 46px; height: 46px; border-radius: 12px; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center; font-size: 24px; color: #fff;
}
.de-emp-info { flex: 1; min-width: 0; }
.de-emp-name { font-size: 14px; font-weight: 700; display: flex; align-items: center; gap: 6px; }
.de-emp-dot { width: 7px; height: 7px; border-radius: 50%; background: #2ecc71; flex-shrink: 0; }
.de-emp-dot.off { background: #bdbdc9; }
.de-emp-title { font-size: 12px; color: #534AB7; font-weight: 600; margin: 2px 0; }
.de-emp-desc { font-size: 12px; color: #6b6b80; line-height: 1.5; }
.de-emp-tags { display: flex; gap: 5px; flex-wrap: wrap; margin-top: 8px; }
.de-emp-tags span {
  font-size: 10px; padding: 2px 7px; border-radius: 6px;
  background: #eef0fb; color: #534AB7; font-weight: 600;
}
.de-emp-go {
  margin-top: 10px; width: 100%; border: 1px solid #534AB7; background: #fff; color: #534AB7;
  border-radius: 8px; padding: 7px; font-size: 12px; font-weight: 700; cursor: pointer;
}
.de-emp-go:hover { background: #534AB7; color: #fff; }

/* chat */
.de-chat { display: none; flex-direction: column; height: 100%; }
.de-chat.active { display: flex; }
.de-chat-hd {
  padding: 10px 14px; border-bottom: 1px solid #ececf5; display: flex; align-items: center; gap: 8px;
  background: #fff;
}
.de-chat-hd .de-back {
  border: none; background: #f0f0f8; border-radius: 7px; width: 28px; height: 28px; cursor: pointer; font-size: 14px;
}
.de-chat-hd .de-av { width: 30px; height: 30px; border-radius: 8px; display: flex; align-items: center; justify-content: center; font-size: 16px; color: #fff; }
.de-chat-hd b { font-size: 13px; }
.de-chat-hd small { display: block; font-size: 10px; color: #9a9ab0; }
.de-chat-body { flex: 1; overflow-y: auto; padding: 14px; background: #f6f6fb; }
.de-chat-body::-webkit-scrollbar { width: 6px; }
.de-chat-body::-webkit-scrollbar-thumb { background: #cfcfe6; border-radius: 3px; }

.de-msg { max-width: 86%; margin-bottom: 10px; padding: 9px 12px; border-radius: 12px; font-size: 12.5px; line-height: 1.6; word-break: break-word; }
.de-msg.sys { background: #eef0fb; color: #3a3a52; border-bottom-left-radius: 4px; }
.de-msg.warn { background: #fff3e0; color: #9a5b00; border-bottom-left-radius: 4px; }
.de-msg.ask { background: #534AB7; color: #fff; margin-left: auto; border-bottom-right-radius: 4px; }
.de-msg.ans { background: #fff; color: #1b1b2f; border: 1px solid #ececf5; border-bottom-left-radius: 4px; }
.de-quick { display: flex; flex-wrap: wrap; gap: 6px; padding: 10px 12px; background: #fff; border-top: 1px solid #ececf5; }
.de-quick button {
  border: 1px solid #d8d8ea; background: #fafaff; color: #534AB7; border-radius: 14px;
  padding: 5px 11px; font-size: 11.5px; cursor: pointer; font-weight: 600;
}
.de-quick button:hover { background: #534AB7; color: #fff; border-color: #534AB7; }
.de-input-row { display: flex; gap: 8px; padding: 10px 12px; background: #fff; border-top: 1px solid #ececf5; }
.de-input-row input {
  flex: 1; height: 38px; border: 1px solid #d8d8ea; border-radius: 9px; padding: 0 12px; font-size: 13px; outline: none;
}
.de-input-row input:focus { border-color: #534AB7; }
.de-input-row button {
  border: none; background: #534AB7; color: #fff; border-radius: 9px; padding: 0 16px; font-size: 13px; font-weight: 700; cursor: pointer;
}
.de-input-row button:hover { background: #433aa0; }
.de-foot { text-align: center; font-size: 10px; color: #b0b0c4; padding: 6px; background: #fff; }

@media (max-width: 480px) {
  .de-panel { right: 10px; left: 10px; width: auto; bottom: 80px; }
  .de-launcher { right: 14px; bottom: 14px; }
}
