/* 甄拔企服 · 在线咨询对话框 */
.zbc-btn {
  position: fixed; right: 22px; bottom: 96px; z-index: 9990;
  width: 56px; height: 56px; border: none; border-radius: 50%;
  background: linear-gradient(160deg, #0B3C72, #12559B); color: #fff;
  box-shadow: 0 6px 20px rgba(11,60,114,.35); cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: transform .2s ease, box-shadow .2s ease;
}
.zbc-btn:hover { transform: translateY(-2px); box-shadow: 0 10px 26px rgba(11,60,114,.42); }
.zbc-btn svg { width: 26px; height: 26px; }
.zbc-badge {
  position: absolute; top: -4px; right: -4px; min-width: 20px; height: 20px;
  border-radius: 10px; background: #E5484D; color: #fff; font-size: 12px;
  line-height: 20px; text-align: center; padding: 0 5px; display: none; font-weight: 600;
}
.zbc-btn.has-unread .zbc-badge { display: block; }

.zbc-panel {
  position: fixed; left: 50%; top: 50%; transform: translate(-50%, -50%);
  z-index: 9991;
  width: 380px; max-width: calc(100vw - 32px); height: 500px; max-height: calc(100vh - 80px);
  background: #fff; border-radius: 14px; overflow: hidden;
  box-shadow: 0 12px 40px rgba(10,47,87,.22);
  display: none; flex-direction: column;
  font-family: inherit;
}
.zbc-panel.is-open { display: flex; }

.zbc-head {
  background: linear-gradient(160deg, #0B3C72, #12559B); color: #fff;
  padding: 14px 16px; display: flex; align-items: center; justify-content: space-between;
  cursor: move; user-select: none; touch-action: none;
}
.zbc-head-t strong { display: block; font-size: 15px; }
.zbc-head-t span { font-size: 12px; opacity: .85; }
.zbc-head-t i { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: #52D273; margin-right: 5px; }
.zbc-close {
  background: none; border: none; color: #fff; font-size: 26px; cursor: pointer;
  line-height: 1; padding: 4px 10px; margin-right: -8px; border-radius: 8px;
}
.zbc-close:hover { background: rgba(255,255,255,.18); }

.zbc-local-tip {
  background: #FFF7E6; color: #8A6116; font-size: 12px;
  padding: 7px 12px; border-bottom: 1px solid #F3E3BC; text-align: center;
}

.zbc-msgs { flex: 1; overflow-y: auto; padding: 14px 12px; background: #F4F7FA; display: flex; flex-direction: column; gap: 10px; }
.zbc-row { display: flex; gap: 8px; align-items: flex-end; }
.zbc-row.me { flex-direction: row-reverse; }
.zbc-bubble {
  max-width: 78%; padding: 9px 12px; border-radius: 12px; font-size: 14px; line-height: 1.6;
  background: #fff; color: #1A2B3C; border: 1px solid #E3EAF1; white-space: pre-wrap; word-break: break-word;
  box-shadow: 0 1px 3px rgba(10,47,87,.06);
}
.zbc-row.me .zbc-bubble { background: #12559B; color: #fff; border-color: #12559B; }
.zbc-row .zbc-who { font-size: 11px; color: #8AA0B4; margin-bottom: 3px; }
.zbc-sys { text-align: center; font-size: 12px; color: #8AA0B4; }

.zbc-contact {
  display: flex; gap: 6px; padding: 8px 10px 0; background: #fff;
}
.zbc-contact input {
  flex: 1; min-width: 0; border: 1px solid #D6E1EC; border-radius: 8px;
  padding: 6px 9px; font-size: 12.5px; outline: none; background: #F8FAFC;
}
.zbc-contact input:focus { border-color: #12559B; background: #fff; }

.zbc-input { display: flex; gap: 8px; padding: 10px; background: #fff; border-top: 1px solid #E9EFF5; }
.zbc-input textarea {
  flex: 1; min-width: 0; height: 42px; resize: none; border: 1px solid #D6E1EC; border-radius: 10px;
  padding: 10px 11px; font-size: 14px; font-family: inherit; outline: none; line-height: 1.5;
}
.zbc-input textarea:focus { border-color: #12559B; }
.zbc-send {
  border: none; border-radius: 10px; background: #12559B; color: #fff;
  padding: 0 16px; font-size: 14px; cursor: pointer; font-weight: 600;
}
.zbc-send:hover { background: #0B3C72; }
.zbc-foot { font-size: 11.5px; color: #8AA0B4; text-align: center; padding: 0 10px 8px; background: #fff; }
.zbc-foot a { color: #12559B; text-decoration: none; }

@media (max-width: 560px) {
  .zbc-btn { right: 16px; bottom: 84px; width: 52px; height: 52px; }
  .zbc-panel {
    right: 0; bottom: 0; left: 0; top: 0; width: 100%; height: 100%; max-height: none;
    transform: none; border-radius: 0;
  }
}
