/* ========== 联系我们挂件（右下角，位于回到顶部按钮上方） ========== */
.contact-widget {
  position: fixed;
  right: 32px;
  bottom: 92px;
  z-index: 910;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 10px;
  opacity: 0.5;
  transition: opacity 0.25s ease;
}
.contact-widget:hover,
.contact-widget:focus-within {
  opacity: 1;
}
.contact-widget-panel {
  display: none;
  flex-direction: column;
  align-items: flex-end;
  gap: 8px;
  background: rgba(255, 255, 255, 0.3);
  padding: 10px;
  border-radius: 14px;
  box-sizing: border-box;
}
.contact-widget:hover .contact-widget-panel,
.contact-widget:focus-within .contact-widget-panel {
  display: flex;
}
.contact-item {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 220px;
  box-sizing: border-box;
  background: #fff;
  color: #333;
  border: 1px solid rgba(108, 92, 231, 0.15);
  border-radius: 22px;
  padding: 8px 14px;
  font-size: 14px;
  line-height: 1.4;
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.08);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  white-space: nowrap;
}
.contact-item i {
  color: #6C5CE7;
  font-size: 16px;
}
.contact-item:hover {
  background: linear-gradient(135deg, #6C5CE7, #00D2FF);
  color: #fff;
  border-color: transparent;
  transform: translateX(-4px);
}
.contact-item:hover i {
  color: #fff;
}
.contact-item-hotline {
  cursor: default;
  align-items: flex-start;
  white-space: normal;
}
.contact-item-hotline i {
  margin-top: 3px;
  color: #6C5CE7;
}
.contact-hotline-text {
  display: flex;
  flex-direction: column;
  text-align: left;
}
.contact-hotline-text strong {
  display: block;
  font-size: 13px;
  color: #555;
  font-weight: 500;
}
.contact-hotline-num {
  display: block;
  font-size: 16px;
  font-weight: 700;
  color: #4a3fb5;
  letter-spacing: 0.3px;
}
.contact-hotline-time {
  display: block;
  font-size: 12px;
  color: #888;
}
.contact-item-hotline:hover i,
.contact-item-hotline:hover .contact-hotline-text strong,
.contact-item-hotline:hover .contact-hotline-num,
.contact-item-hotline:hover .contact-hotline-time {
  color: #fff;
}
.contact-widget-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  border: none;
  border-radius: 50%;
  background: linear-gradient(135deg, #6C5CE7, #00D2FF);
  color: #fff;
  font-size: 1.1rem;
  cursor: pointer;
  box-shadow: 0 4px 20px rgba(108, 92, 231, 0.4);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}
.contact-widget:hover .contact-widget-toggle {
  box-shadow: 0 8px 24px rgba(108, 92, 231, 0.55);
}
.contact-widget-toggle-text {
  display: none;
}
.contact-qr-pop {
  position: absolute;
  right: calc(100% + 12px);
  bottom: 58px;
  display: flex;
  flex-direction: column;
  width: 190px;
  background: #fff;
  border-radius: 10px;
  padding: 12px 12px 0;
  box-sizing: border-box;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.18);
  text-align: center;
}
.contact-qr-pop[hidden] {
  display: none;
}
.contact-qr-pop img {
  order: 2;
  display: block;
  width: 160px;
  height: 160px;
  margin: 0 auto;
  border-radius: 6px;
}
.contact-qr-pop img[hidden] {
  display: none;
}
.contact-qr-caption {
  order: 1;
  margin: 0 0 8px 0;
  font-size: 12px;
  color: #666;
}
@media (max-width: 480px) {
  .contact-widget {
    right: 20px;
    bottom: 74px;
  }
  .contact-widget-toggle {
    width: 42px;
    height: 42px;
  }
  .contact-item {
    width: 180px;
    font-size: 13px;
    padding: 7px 12px;
  }
  .contact-qr-pop {
    position: fixed;
    left: 8px;
    right: 232px;
    top: auto;
    bottom: 126px;
    transform: none;
    width: auto;
    max-width: 190px;
    padding: 10px 10px 0;
    z-index: 10000;
  }
  .contact-qr-pop img {
    width: 100%;
    max-width: 160px;
    height: auto;
  }
}