/* ============================================================
 * WHATSAPP FLOATING BUTTON — 2026-05-20
 * Botao fixed mobile-first pra reduzir friccao de contato.
 * Posicao: bottom-right desktop, bottom-center mobile.
 * Estilo: mint (nao verde-WA clichê), pill com label.
 * ============================================================ */

.wa-fab {
  position: fixed;
  bottom: 20px;
  right: 20px;
  z-index: 9999;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 22px 14px 16px;
  border-radius: 999px;
  text-decoration: none;
  /* PALETA ALINHADA AO SITE: ember (laranja-vermelho) — distingue do "Empezar" lime
     e transmite urgencia/calor, ideal pra contato direto */
  background: linear-gradient(135deg, #ff5b2e 0%, #d44216 100%);
  color: #ffffff;
  font-weight: 700;
  font-size: 15px;
  letter-spacing: -0.01em;
  box-shadow:
    0 12px 32px -8px rgba(255, 91, 46, 0.5),
    0 4px 12px rgba(0, 0, 0, 0.4),
    inset 0 1px 0 rgba(255, 255, 255, 0.18);
  transition: transform 180ms cubic-bezier(0.2, 0.7, 0.3, 1),
              box-shadow 180ms ease,
              opacity 180ms ease;
  cursor: pointer;
  white-space: nowrap;
  border: none;
  font-family: inherit;
}

.wa-fab:hover,
.wa-fab:focus-visible {
  transform: translateY(-2px) scale(1.02);
  box-shadow:
    0 18px 40px -8px rgba(255, 91, 46, 0.65),
    0 6px 16px rgba(0, 0, 0, 0.45),
    inset 0 1px 0 rgba(255, 255, 255, 0.22);
  outline: none;
}

.wa-fab:active {
  transform: translateY(0) scale(0.98);
}

.wa-fab__icon {
  width: 22px;
  height: 22px;
  flex-shrink: 0;
  fill: currentColor;
}

.wa-fab__label {
  display: inline-block;
}

/* Pulse subtle on idle */
.wa-fab::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 999px;
  background: rgba(255, 91, 46, 0.45);
  z-index: -1;
  animation: wa-fab-pulse 2.4s ease-out infinite;
}

@keyframes wa-fab-pulse {
  0%   { transform: scale(1);    opacity: 0.7; }
  70%  { transform: scale(1.18); opacity: 0;   }
  100% { transform: scale(1.18); opacity: 0;   }
}

/* Mobile: shrink + bottom-right ainda */
@media (max-width: 640px) {
  .wa-fab {
    bottom: 16px;
    right: 16px;
    padding: 12px 18px 12px 14px;
    font-size: 14px;
  }
  .wa-fab__icon {
    width: 20px;
    height: 20px;
  }
}

/* Bem pequeno: vira so icone redondo */
@media (max-width: 380px) {
  .wa-fab {
    padding: 14px;
  }
  .wa-fab__label {
    display: none;
  }
}

/* Respeita user preference de menos animacao */
@media (prefers-reduced-motion: reduce) {
  .wa-fab::before {
    animation: none;
  }
  .wa-fab {
    transition: none;
  }
}

/* Esconde quando builder em foco fullscreen (opcional via JS class) */
.wa-fab.is-hidden {
  opacity: 0;
  pointer-events: none;
  transform: translateY(20px);
}

/* ============================================================
 * HELP MODE — quando user trava no builder ou da exit_intent
 * Pulse mais agressivo, fundo mais saturado, label maior
 * ============================================================ */
.wa-fab--help {
  padding: 16px 24px 16px 18px;
  font-size: 16px;
  background: linear-gradient(135deg, #ff5b2e 0%, #ff2e8a 100%);
  box-shadow:
    0 16px 40px -8px rgba(255, 91, 46, 0.7),
    0 6px 16px rgba(0, 0, 0, 0.5),
    inset 0 1px 0 rgba(255, 255, 255, 0.25);
}

.wa-fab--help::before {
  background: rgba(255, 91, 46, 0.6);
  animation: wa-fab-pulse 1.4s ease-out infinite;
}

@media (max-width: 380px) {
  .wa-fab--help .wa-fab__label {
    display: inline-block; /* em help mode SEMPRE mostra label */
    font-size: 13px;
  }
  .wa-fab--help {
    padding: 14px 18px 14px 14px;
  }
}
