.muye-consult {
  position: fixed;
  right: max(20px, env(safe-area-inset-right));
  bottom: max(20px, env(safe-area-inset-bottom));
  z-index: 160;
  color: #20251f;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
}

.muye-consult,
.muye-consult * {
  box-sizing: border-box;
}

.muye-consult a {
  text-decoration: none;
}

.muye-consult__trigger {
  min-height: 54px;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 8px 18px 8px 9px;
  border: 1px solid rgba(255, 255, 255, .22);
  border-radius: 999px;
  color: #fff;
  background: #26342a;
  box-shadow: 0 16px 38px rgba(17, 25, 19, .24);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .06em;
  transition: transform .2s ease, background .2s ease;
}

.muye-consult__trigger:hover {
  transform: translateY(-2px);
  background: #34483a;
}

.muye-consult__trigger:focus-visible,
.muye-consult__panel a:focus-visible {
  outline: 2px solid #b77c4d;
  outline-offset: 3px;
}

.muye-consult__trigger img {
  width: 36px;
  height: 36px;
  padding: 4px;
  object-fit: contain;
  border-radius: 50%;
  background: #fff;
}

.muye-consult__panel {
  position: absolute;
  right: 0;
  bottom: calc(100% + 14px);
  width: 292px;
  padding: 20px;
  border: 1px solid rgba(38, 52, 42, .12);
  border-radius: 18px;
  background: #fffdf8;
  box-shadow: 0 24px 70px rgba(17, 25, 19, .22);
  opacity: 0;
  pointer-events: none;
  transform: translateY(8px) scale(.98);
  transform-origin: right bottom;
  transition: opacity .2s ease, transform .2s ease;
}

.muye-consult:hover .muye-consult__panel,
.muye-consult:focus-within .muye-consult__panel {
  opacity: 1;
  pointer-events: auto;
  transform: none;
}

.muye-consult__head {
  display: grid;
  grid-template-columns: 46px 1fr;
  gap: 12px;
  align-items: center;
}

.muye-consult__head img {
  width: 46px;
  height: 46px;
  padding: 5px;
  object-fit: contain;
  border: 1px solid rgba(38, 52, 42, .12);
  border-radius: 12px;
  background: #fff;
}

.muye-consult__head strong {
  display: block;
  font-family: "Songti SC", "STSong", "SimSun", serif;
  font-size: 18px;
  line-height: 1.25;
}

.muye-consult__head span {
  display: block;
  margin-top: 3px;
  color: #6b7068;
  font-size: 11px;
}

.muye-consult__copy {
  margin: 15px 0;
  color: #656960;
  font-size: 13px;
  line-height: 1.75;
}

.muye-consult__qr {
  width: 100%;
  display: block;
  padding: 9px;
  border: 1px solid rgba(38, 52, 42, .1);
  border-radius: 12px;
  background: #fff;
}

.muye-consult__caption {
  margin: 10px 0 14px;
  color: #73776f;
  font-size: 11px;
  text-align: center;
}

.muye-consult__direct {
  min-height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 9px;
  color: #fff !important;
  background: #26342a;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .04em;
}

@media (max-width: 820px) {
  .muye-consult {
    right: max(14px, env(safe-area-inset-right));
    bottom: max(14px, env(safe-area-inset-bottom));
  }

  .muye-consult__panel {
    display: none;
  }

  .muye-consult__trigger {
    min-height: 50px;
    padding: 7px 16px 7px 8px;
    box-shadow: 0 12px 32px rgba(17, 25, 19, .28);
  }

  .muye-consult__trigger img {
    width: 34px;
    height: 34px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .muye-consult__trigger,
  .muye-consult__panel {
    transition: none;
  }
}
