/* Right-middle floating contact cluster (MOKE brand) */

.moke-float-contact {
  position: fixed;
  right: 20px;
  top: 50%;
  bottom: auto;
  transform: translateY(-50%);
  z-index: 10040;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  pointer-events: none;
}

.moke-float-stack {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  pointer-events: auto;
}

.moke-float-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 58px;
  height: 58px;
  border-radius: 50%;
  background: #0938d3;
  color: #fff;
  box-shadow: 0 4px 16px rgba(9, 56, 211, 0.35);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
  text-decoration: none;
  border: none;
  cursor: pointer;
  position: relative;
  overflow: visible;
}

.moke-float-btn svg {
  width: 26px;
  height: 26px;
  fill: currentColor;
  flex-shrink: 0;
}

.moke-float-btn:hover {
  transform: translateY(-3px) scale(1.05);
  box-shadow: 0 8px 24px rgba(9, 56, 211, 0.45);
}

/* Main WhatsApp button — larger, green, pulsing */
.moke-float-btn.moke-float-whatsapp {
  width: 70px;
  height: 70px;
  background: #25d366;
  box-shadow: 0 6px 20px rgba(37, 211, 102, 0.45);
}

.moke-float-btn.moke-float-whatsapp svg {
  width: 34px;
  height: 34px;
}

.moke-float-btn.moke-float-whatsapp:hover {
  background: #20bd5a;
  box-shadow: 0 10px 28px rgba(37, 211, 102, 0.55);
}

.moke-float-btn.moke-float-whatsapp::before,
.moke-float-btn.moke-float-whatsapp::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: rgba(37, 211, 102, 0.45);
  z-index: -1;
  animation: mokeFloatPulse 2s ease-out infinite;
  pointer-events: none;
}

.moke-float-btn.moke-float-whatsapp::after {
  animation-delay: 1s;
}

@keyframes mokeFloatPulse {
  0% { transform: scale(1); opacity: 0.6; }
  70% { transform: scale(1.7); opacity: 0; }
  100% { transform: scale(1.7); opacity: 0; }
}

/* Inquiry / chat opens form */
.moke-float-btn.moke-float-inquiry {
  background: #0938d3;
}

/* Back to top — independent bottom-right; shows after scroll */
.moke-float-top {
  position: fixed;
  right: 20px;
  bottom: 24px;
  z-index: 10041;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 52px;
  height: 52px;
  border-radius: 8px;
  background: #3a3f51;
  color: #fff;
  border: none;
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.2);
  transition: transform 0.2s, background 0.2s, opacity 0.3s, visibility 0.3s;
  pointer-events: none;
  opacity: 0;
  visibility: hidden;
  transform: translateY(8px);
}

.moke-float-top.visible {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateY(0);
}

.moke-float-top:hover {
  background: #0938d3;
  transform: translateY(-2px);
}

.moke-float-top svg {
  width: 24px;
  height: 24px;
  fill: currentColor;
}

/* Hide default scroll-top when float widget is active */
body.moke-float-active .scroll-top {
  display: none !important;
}

/* Avoid duplicate contact UI: floating widget replaces desktop sidebar */
body.moke-float-active .desktop-sidebar,
body.moke-float-active .desktop-sidebar.row,
html body.moke-float-active .desktop-sidebar {
  display: none !important;
  visibility: hidden !important;
  pointer-events: none !important;
}

@media (min-width: 769px) {
  .moke-float-contact {
    right: 28px;
  }

  .moke-float-top {
    right: 28px;
    bottom: 28px;
  }
}

@media (max-width: 768px) {
  .moke-float-contact {
    right: 14px;
  }

  .moke-float-btn {
    width: 52px;
    height: 52px;
  }

  .moke-float-btn svg {
    width: 24px;
    height: 24px;
  }

  .moke-float-btn.moke-float-whatsapp {
    width: 62px;
    height: 62px;
  }

  .moke-float-btn.moke-float-whatsapp svg {
    width: 30px;
    height: 30px;
  }

  .moke-float-top {
    right: 14px;
    bottom: 20px;
    width: 48px;
    height: 48px;
  }
}

/* QHD / ultrawide: slightly larger so they don't feel tiny */
@media (min-width: 2560px) {
  .moke-float-contact {
    right: 32px;
    gap: 14px;
  }

  .moke-float-stack {
    gap: 14px;
  }

  .moke-float-btn {
    width: 68px;
    height: 68px;
  }

  .moke-float-btn svg {
    width: 30px;
    height: 30px;
  }

  .moke-float-btn.moke-float-whatsapp {
    width: 82px;
    height: 82px;
  }

  .moke-float-btn.moke-float-whatsapp svg {
    width: 40px;
    height: 40px;
  }

  .moke-float-top {
    right: 32px;
    bottom: 32px;
    width: 60px;
    height: 60px;
  }

  .moke-float-top svg {
    width: 28px;
    height: 28px;
  }
}

/* 3840×2160 @ 100%：再放大一档，比例接近 1920 上的观感 */
@media (min-width: 3600px) {
  .moke-float-contact {
    right: 40px;
    gap: 16px;
  }

  .moke-float-stack {
    gap: 16px;
  }

  .moke-float-btn {
    width: 88px;
    height: 88px;
  }

  .moke-float-btn svg {
    width: 40px;
    height: 40px;
  }

  .moke-float-btn.moke-float-whatsapp {
    width: 106px;
    height: 106px;
  }

  .moke-float-btn.moke-float-whatsapp svg {
    width: 52px;
    height: 52px;
  }

  .moke-float-top {
    right: 40px;
    bottom: 40px;
    width: 76px;
    height: 76px;
    border-radius: 10px;
  }

  .moke-float-top svg {
    width: 34px;
    height: 34px;
  }
}
