/* 广告墙游客客服浮层 */
.kefu-fab {
  position: fixed;
  right: 16px;
  bottom: 24px;
  z-index: 9990;
  width: 54px;
  height: 54px;
  border: 0;
  border-radius: 50%;
  background: #1677ff;
  color: #fff;
  box-shadow: 0 8px 20px rgba(22, 119, 255, 0.35);
  cursor: pointer;
  font-size: 13px;
  font-weight: 600;
}
.kefu-fab__badge {
  position: absolute;
  top: -4px;
  right: -4px;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 9px;
  background: #ff4d4f;
  color: #fff;
  font-size: 11px;
  line-height: 18px;
  text-align: center;
  display: none;
}
.kefu-panel {
  position: fixed;
  right: 12px;
  bottom: 90px;
  z-index: 9991;
  width: min(380px, calc(100vw - 24px));
  height: min(560px, calc(100vh - 120px));
  background: #fff;
  border-radius: 14px;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.18);
  display: none;
  flex-direction: column;
  overflow: hidden;
}
.kefu-panel.is-open { display: flex; }
.kefu-panel__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 14px;
  background: linear-gradient(135deg, #1677ff, #3f9bff);
  color: #fff;
}
.kefu-panel__head h3 { margin: 0; font-size: 16px; font-weight: 600; }
.kefu-panel__head button {
  border: 0;
  background: transparent;
  color: #fff;
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
}
.kefu-panel__status { font-size: 12px; opacity: .9; margin-top: 2px; }
.kefu-panel__msgs {
  flex: 1;
  overflow-y: auto;
  padding: 12px;
  background: #f5f7fa;
}
.kefu-msg { margin-bottom: 10px; max-width: 82%; clear: both; }
.kefu-msg--user { float: right; }
.kefu-msg--admin { float: left; }
.kefu-msg__body {
  padding: 8px 10px;
  border-radius: 10px;
  background: #fff;
  box-shadow: 0 1px 2px rgba(0,0,0,.05);
  word-break: break-word;
  line-height: 1.45;
  font-size: 14px;
}
.kefu-msg--user .kefu-msg__body { background: #1677ff; color: #fff; }
.kefu-msg__body img,
.kefu-msg__body video { max-width: 200px; display: block; border-radius: 6px; }
.kefu-panel__foot {
  border-top: 1px solid #eee;
  background: #fff;
  padding: 8px 10px;
}
.kefu-panel__tools { display: flex; gap: 8px; margin-bottom: 6px; }
.kefu-panel__tools label,
.kefu-panel__tools button {
  border: 1px solid #e5e5e5;
  background: #fafafa;
  border-radius: 6px;
  padding: 4px 8px;
  font-size: 12px;
  cursor: pointer;
}
.kefu-panel__input {
  display: flex;
  gap: 8px;
}
.kefu-panel__input textarea {
  flex: 1;
  resize: none;
  border: 1px solid #e5e5e5;
  border-radius: 8px;
  padding: 8px;
  font-size: 14px;
  min-height: 40px;
  max-height: 90px;
}
.kefu-panel__input button {
  border: 0;
  border-radius: 8px;
  background: #1677ff;
  color: #fff;
  padding: 0 14px;
  font-weight: 600;
  cursor: pointer;
}
