/* ============================================================
   右侧客服悬浮窗（迁移自现有官网，尺寸与配色按线上实测还原）
   自包含样式，不依赖任何外部样式表
   ============================================================ */

.contact-dock {
  position: fixed;
  right: 18px;
  bottom: clamp(74px, 12vh, 112px);
  z-index: 80;
  width: 56px;
  color: #1d2129;
  font-family: var(--site-font-family, "PingFang SC", "Microsoft YaHei", sans-serif);
  font-size: 14px;
  line-height: 1.5;
}

.contact-dock button {
  border: 0;
  font-family: inherit;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

/* ---------- 右侧竖条 ---------- */
.dock-rail {
  display: flex;
  flex-direction: column;
  gap: 9px;
  width: 56px;
}

.dock-main {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.dock-mascot {
  width: 56px;
  height: 64px;
  padding: 0;
  background: transparent;
}

.dock-mascot img {
  display: block;
  width: 56px;
  height: 64px;
  object-fit: contain;
  transition: transform .25s ease;
}

.dock-mascot:hover img {
  transform: translateY(-3px);
}

.dock-promo {
  display: flex;
  width: 56px;
  height: 116px;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: 28px;
  background: linear-gradient(180deg, #2d7df4, #7562f2);
  box-shadow: 0 9px 24px rgba(54, 95, 220, .3);
  color: #fff;
  transition: transform .2s ease, box-shadow .2s ease;
}

.dock-promo:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 28px rgba(54, 95, 220, .38);
}

.dock-promo-icon {
  width: 20px;
  height: 20px;
}

.dock-promo span {
  font-size: 12px;
  letter-spacing: .22em;
  writing-mode: vertical-rl;
  text-orientation: upright;
}

.dock-round {
  display: grid;
  width: 56px;
  height: 56px;
  place-items: center;
  border: 1px solid #edf2f7;
  border-radius: 50%;
  background: #fff;
  color: #1f2937;
  box-shadow: 0 7px 20px rgba(15, 23, 42, .1);
  transition: color .2s ease, transform .2s ease, opacity .25s ease, visibility .25s ease;
}

.dock-round svg {
  width: 22px;
  height: 22px;
}

.dock-round:hover {
  color: #165dff;
  transform: translateY(-2px);
}

.dock-round[data-scroll-top] {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateX(20px);
}

.dock-round[data-scroll-top].is-visible {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: none;
}

/* ---------- 展开面板 ---------- */
.dock-panel {
  position: fixed;
  right: 88px;
  bottom: clamp(74px, 12vh, 112px);
  z-index: 79;
  width: 546px;
  max-width: calc(100vw - 120px);
  max-height: calc(100vh - 150px);
  overflow: auto;
  border: 1px solid #eaeef5;
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 18px 48px rgba(23, 40, 74, .18);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateX(14px);
  transition: opacity .22s ease, transform .26s ease, visibility 0s linear .26s;
}

.dock-panel.is-open {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: none;
  transition: opacity .22s ease, transform .26s ease, visibility 0s;
}

.dock-panel::after {
  content: "";
  position: absolute;
  top: 50%;
  right: -6px;
  width: 10px;
  height: 10px;
  border-top: 1px solid #eaeef5;
  border-right: 1px solid #eaeef5;
  background: #fff;
  transform: translateY(-50%) rotate(45deg);
}

.dock-close {
  position: absolute;
  top: 12px;
  right: 14px;
  display: grid;
  width: 26px;
  height: 26px;
  place-items: center;
  border-radius: 50%;
  background: transparent;
  color: #9aa6b8;
  font-size: 20px;
  line-height: 1;
  transition: background .18s ease, color .18s ease;
}

.dock-close:hover {
  background: #f2f5fa;
  color: #46536b;
}

/* 面板头部 */
.scc-head {
  padding: 22px 26px 12px;
}

.scc-eyebrow {
  color: #165dff;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .12em;
}

.scc-title {
  margin: 4px 0 6px;
  color: #1f2b3d;
  font-size: 17px;
  font-weight: 700;
  line-height: 1.4;
}

.scc-sub {
  margin: 0;
  color: #8b97a8;
  font-size: 12px;
  line-height: 1.6;
}

/* 面板主体 */
.scc-body {
  padding: 2px 26px 22px;
}

.scc-group {
  padding-top: 16px;
}

.scc-group + .scc-group {
  margin-top: 6px;
  border-top: 1px solid #f0f3f8;
}

.scc-group-title {
  margin-bottom: 10px;
  color: #1f2b3d;
  font-size: 13.5px;
  font-weight: 600;
}

.scc-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px 10px;
}

.scc-item {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  padding: 8px 13px;
  border: 1px solid #eef2f8;
  border-radius: 9px;
  background: #fff;
  color: #2c3b53;
  font-size: 13px;
  text-align: left;
  transition: border-color .18s ease, box-shadow .18s ease, transform .18s ease;
}

.scc-item:hover {
  border-color: #cfdcf5;
  box-shadow: 0 6px 16px rgba(23, 40, 74, .08);
  transform: translateY(-1px);
}

.scc-avatar {
  display: grid;
  width: 24px;
  height: 24px;
  flex: none;
  place-items: center;
  overflow: hidden;
  border-radius: 50%;
  background: #f2f5fa;
}

.scc-av-img {
  width: 24px;
  height: 24px;
  object-fit: cover;
}

.scc-name {
  flex: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.scc-arrow {
  flex: none;
  color: #b7c2d2;
}

.scc-arrow svg {
  width: 13px;
  height: 13px;
}

.scc-lines {
  margin-top: 12px;
}

.scc-line {
  color: #7a879a;
  font-size: 12px;
  line-height: 1.9;
}

.scc-line-label {
  color: #9aa6b8;
}

.scc-line a {
  color: #165dff;
  text-decoration: none;
}

.scc-line a:hover {
  text-decoration: underline;
}

/* ---------- 响应式 ---------- */
@media (max-width: 760px) {
  .contact-dock {
    right: 12px;
    bottom: 84px;
  }

  .dock-mascot,
  .dock-mascot img {
    display: none;
  }

  .dock-promo {
    height: 96px;
  }

  .dock-panel {
    right: 12px;
    left: 12px;
    width: auto;
    max-width: none;
    bottom: 150px;
    max-height: calc(100vh - 210px);
  }

  .dock-panel::after {
    display: none;
  }

  .scc-list {
    grid-template-columns: 1fr;
  }
}
