/*
 * Agrialemana — WhatsApp floating button
 */

.ag-whatsapp-fab {
  position: fixed;
  right: 24px;
  bottom: 24px;
  width: 60px;
  height: 60px;
  background-color: #25D366;
  color: #ffffff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
  z-index: 9999;
  text-decoration: none;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  animation: ag-whatsapp-pulse 2s ease-out infinite;
}

.ag-whatsapp-fab:hover {
  transform: scale(1.08);
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.3);
  background-color: #1ebe57;
  text-decoration: none;
  color: #ffffff;
}

.ag-whatsapp-fab:focus {
  outline: 3px solid var(--ag-color-accent, #D4A017);
  outline-offset: 2px;
}

.ag-whatsapp-fab svg {
  width: 32px;
  height: 32px;
  display: block;
}

.ag-whatsapp-fab.is-hidden {
  display: none;
}

/* Animación de pulso */
@keyframes ag-whatsapp-pulse {
  0%   { box-shadow: 0 4px 12px rgba(37, 211, 102, 0.5), 0 0 0 0 rgba(37, 211, 102, 0.6); }
  70%  { box-shadow: 0 4px 12px rgba(37, 211, 102, 0.5), 0 0 0 18px rgba(37, 211, 102, 0); }
  100% { box-shadow: 0 4px 12px rgba(37, 211, 102, 0.5), 0 0 0 0 rgba(37, 211, 102, 0); }
}

/* Ocultar en impresión */
@media print {
  .ag-whatsapp-fab { display: none !important; }
}

/* En pantallas muy pequeñas: ajustar margen */
@media (max-width: 480px) {
  .ag-whatsapp-fab {
    right: 16px;
    bottom: 16px;
    width: 56px;
    height: 56px;
  }
  .ag-whatsapp-fab svg {
    width: 28px;
    height: 28px;
  }
}
