/* ==========================================
   WHATSAPP FLOTANTE - CSS BASE
   ========================================== */
.wa-btn-container {
  position: fixed;
  z-index: 999999;
  bottom: 24px;
  left: 24px; /* ✅ Izquierda como solicitaste */
  padding-bottom: env(safe-area-inset-bottom, 0px);
}

.wa-btn-main {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background-color: #25D366;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 12px rgba(0,0,0,0.3);
  transition: all 0.3s ease;
}

.wa-btn-main:hover {
  background-color: #20bd5a;
  transform: scale(1.1);
}

.wa-btn-main::before {
  content: '';
  position: absolute;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  background-color: #25D366;
  animation: wa-pulse 2s infinite;
  z-index: -1;
}

@keyframes wa-pulse {
  0% { transform: scale(1); opacity: 0.5; }
  100% { transform: scale(1.6); opacity: 0; }
}

.wa-chat-box {
  position: absolute;
  bottom: 75px;
  left: 0; /* ✅ Alineado a la izquierda */
  right: auto;
  width: 320px;
  max-width: calc(100vw - 48px);
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 8px 30px rgba(0,0,0,0.2);
  overflow: hidden;
  opacity: 0;
  visibility: hidden;
  transform: translateY(20px) scale(0.9);
  transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

.wa-chat-box.wa-visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0) scale(1);
}

.wa-chat-header {
  background: linear-gradient(135deg, #075E54, #128C7E);
  padding: 14px 16px;
  display: flex;
  align-items: center;
  gap: 12px;
}

.wa-chat-avatar {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: rgba(255,255,255,0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.wa-chat-info { flex: 1; display: flex; flex-direction: column; }
.wa-chat-name { color: #fff; font-family: 'Segoe UI', Arial, sans-serif; font-size: 15px; font-weight: 600; }
.wa-chat-status { color: rgba(255,255,255,0.8); font-size: 12px; font-family: 'Segoe UI', Arial, sans-serif; }
.wa-chat-close {
  background: none; border: none; color: #fff; font-size: 18px;
  cursor: pointer; padding: 4px; border-radius: 50%;
}
.wa-chat-close:hover { background: rgba(255,255,255,0.2); }

.wa-chat-body {
  padding: 20px 16px;
  background-color: #ECE5DD;
  min-height: 80px;
}

.wa-chat-message {
  background: #fff;
  padding: 10px 14px;
  border-radius: 0 10px 10px 10px;
  font-family: 'Segoe UI', Arial, sans-serif;
  font-size: 14px;
  color: #333;
  max-width: 85%;
  box-shadow: 0 1px 2px rgba(0,0,0,0.1);
  position: relative;
}

.wa-chat-message::before {
  content: '';
  position: absolute;
  top: 0; left: -8px;
  width: 0; height: 0;
  border-style: solid;
  border-width: 0 8px 8px 0;
  border-color: transparent #fff transparent transparent;
}

.wa-chat-footer {
  display: flex; align-items: center; padding: 10px 12px;
  background: #f0f0f0; gap: 8px;
}

.wa-chat-input {
  flex: 1; border: none; border-radius: 24px;
  padding: 10px 16px; font-family: 'Segoe UI', Arial, sans-serif;
  font-size: 14px; outline: none; background: #fff;
}

.wa-chat-send {
  background: none; border: none; cursor: pointer;
  padding: 6px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
}
.wa-chat-send:hover { transform: scale(1.15); }

/* Responsive móvil */
@media (max-width: 480px) {
  .wa-btn-main { width: 54px; height: 54px; }
  .wa-chat-box { width: calc(100vw - 48px); }
}
