/* ── BOTÓN WHATSAPP (abajo a la derecha) ── */
#btn-whatsapp {
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  z-index: 900;
  width: 56px;
  height: 56px;
  background: #25d366;
  color: #fff;
  border: none;
  border-radius: 50%;
  font-size: 1.6rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 16px rgba(37,211,102,.45);
  text-decoration: none;
  transition: transform .3s, box-shadow .3s;
  animation: wa-pulse 2.5s infinite;
}
#btn-whatsapp:hover {
  transform: scale(1.12);
  box-shadow: 0 6px 24px rgba(37,211,102,.65);
}
@keyframes wa-pulse {
  0%,100% { box-shadow: 0 4px 16px rgba(37,211,102,.45); }
  50%      { box-shadow: 0 4px 28px rgba(37,211,102,.75); }
}

/* ── BOTÓN IR ARRIBA (encima del WhatsApp, mismo lado derecho) ── */
#btn-top {
  position: fixed;
  bottom: 5.5rem;   /* justo encima del whatsapp */
  right: 1.5rem;
  z-index: 900;
  width: 44px;
  height: 44px;
  background: var(--accent, #1e40af);
  color: #fff;
  border: none;
  border-radius: 50%;
  font-size: 1.1rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 12px rgba(0,0,0,.25);
  opacity: 0;
  pointer-events: none;
  transition: opacity .3s, transform .3s;
}
#btn-top.visible {
  opacity: 1;
  pointer-events: auto;
}
#btn-top:hover {
  transform: translateY(-3px);
  background: var(--primary-dark, #1a7fd4);
}

/* Dark mode */
.dark-mode #btn-top {
  background: var(--accent, #4c6ef5);
}
.dark-mode #btn-top:hover {
  background: var(--primary, #4dabf7);
}

/* Tooltip */
#btn-whatsapp::before,
#btn-top::before {
  content: attr(title);
  position: absolute;
  right: calc(100% + 10px);
  background: rgba(0,0,0,.75);
  color: #fff;
  font-size: .75rem;
  padding: .3rem .6rem;
  border-radius: 6px;
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  transition: opacity .2s;
}
#btn-whatsapp:hover::before,
#btn-top:hover::before {
  opacity: 1;
}
