.wechat-float {
  position: fixed;
  right: 18px;
  top: 50%;
  bottom: auto;
  transform: translateY(-50%);
  z-index: 1200;
  display: grid;
  justify-items: end;
  gap: 10px;
}

.wechat-float-toggle {
  list-style: none;
  border: 1px solid #b7e6c4;
  border-radius: 14px;
  background: linear-gradient(180deg, #ffffff 0%, #f5fff7 100%);
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.12);
  color: #15803d;
  padding: 10px 14px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  font-weight: 700;
  font-size: 14px;
  user-select: none;
}

.wechat-float-toggle::-webkit-details-marker {
  display: none;
}

.wechat-float-toggle::marker {
  content: "";
}

.wechat-float[open] .wechat-float-toggle {
  border-color: #86efac;
  box-shadow: 0 14px 30px rgba(34, 197, 94, 0.2);
}

.wechat-float-toggle-icon {
  width: 26px;
  height: 26px;
  border-radius: 999px;
  background: #16a34a;
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  line-height: 1;
}

.wechat-float-panel {
  order: -1;
  position: relative;
  width: 220px;
  border: 1px solid #d7e6db;
  border-radius: 16px;
  background: #fff;
  box-shadow: 0 16px 30px rgba(15, 23, 42, 0.18);
  padding: 12px;
  display: grid;
  gap: 8px;
}

.wechat-float-panel::after {
  content: "";
  position: absolute;
  right: 26px;
  bottom: -8px;
  width: 12px;
  height: 12px;
  background: #fff;
  border-right: 1px solid #d7e6db;
  border-bottom: 1px solid #d7e6db;
  transform: rotate(45deg);
}

.wechat-float:not([open]) .wechat-float-panel {
  display: none;
}

.wechat-float-panel-title {
  font-size: 13px;
  color: #334155;
  text-align: center;
}

.wechat-float-image {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: contain;
  border-radius: 10px;
  border: 1px solid #e2e8f0;
  background: #fff;
}

.wechat-float-panel-hint {
  font-size: 12px;
  color: #64748b;
  text-align: center;
  line-height: 1.4;
}

@media (max-width: 900px) {
  .wechat-float {
    right: 12px;
    top: 50%;
    bottom: auto;
    transform: translateY(-50%);
  }

  .wechat-float-panel {
    width: 172px;
    padding: 8px;
  }

  .wechat-float-toggle {
    padding: 8px 10px;
    font-size: 13px;
  }

  .wechat-float-toggle-icon {
    width: 22px;
    height: 22px;
    font-size: 12px;
  }
}
