/* Main Container */
.floating-container {
  position: fixed;
  bottom: 25px;
  right: 25px;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 20px;
  z-index: 9998; /* Base layer */
}

/* Contact Row */
.contact-buttons {
  display: flex;
  flex-direction: row;
  gap: 15px;
  z-index: 1; /* Lower than Back to Top */
}

/* Base Button Styling */
.float-btn {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  color: white;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
  transition: all 0.3s ease;
  cursor: pointer;
  flex-shrink: 0;
  position: relative; /* Essential for z-index to work */
}

.float-btn svg {
  width: 30px;
  height: 30px;
  transition: transform 0.3s ease;
}

/* Back to Top (Top Row) - HIGHEST Z-INDEX */
.back-to-top {
  background-color: #fff;
  z-index: 10; /* Higher than contact buttons */
}
.back-to-top:hover {
  background-color: #007bff;
  color: #fff;
  transform: translateY(-5px);
  box-shadow:
    0 0 15px #333,
    0 0 30px rgba(51, 51, 51, 0.6);
}

/* Phone (Bottom Row) */
.phone {
  background-color: #007bff;
  z-index: 5;
}
.phone:hover {
  background-color: #0056b3;
  transform: scale(1.1);
  box-shadow:
    0 0 15px #007bff,
    0 0 30px #007bff;
}

/* WhatsApp (Bottom Row) */
.whatsapp {
  background-color: #25d366;
  z-index: 5;
  animation: pulse-green 2s infinite;
}
.whatsapp:hover {
  background-color: #128c7e;
  transform: scale(1.1);
  box-shadow:
    0 0 15px #25d366,
    0 0 30px #25d366;
  animation: none;
}

@keyframes pulse-green {
  0% {
    box-shadow: 0 0 0 0 rgba(37, 211, 102, 0.7);
  }
  70% {
    box-shadow: 0 0 0 10px rgba(37, 211, 102, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(37, 211, 102, 0);
  }
}
