:root {
  --accent-neon: #39ff14;
  --accent-neon-rgb: 57,255,20;
  --glass-bg: rgba(255,255,255,0.05);
  --glass-blur: 10px;
  --btn-size: 60px;
  --btn-size-sm: 48px;
  --btn-transition: 0.3s ease-in-out;
}

.float-button {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  width: var(--btn-size);
  height: var(--btn-size);
  background: var(--glass-bg);
  backdrop-filter: blur(var(--glass-blur));
  -webkit-backdrop-filter: blur(var(--glass-blur));
  border: 1px solid var(--accent-neon);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent-neon);
  font-size: 1.5rem;
  cursor: pointer;
  box-shadow: 0 0 8px rgba(var(--accent-neon-rgb),0.7), 0 0 16px rgba(var(--accent-neon-rgb),0.4);
  transition: transform var(--btn-transition), box-shadow var(--btn-transition), background var(--btn-transition);
  z-index: 1000;
  text-decoration: none;
  /* Permanent will-change removed for performance */
}

.float-button:hover {
  transform: scale(1.1);
  background: rgba(255,255,255,0.1);
  box-shadow: 0 0 12px rgba(var(--accent-neon-rgb),0.9), 0 0 24px rgba(var(--accent-neon-rgb),0.6);
  will-change: transform, box-shadow;
}

.float-button:active {
  transform: scale(0.95);
  box-shadow: 0 0 4px rgba(var(--accent-neon-rgb),0.5);
}

.float-button:focus-visible {
  outline: 2px solid var(--accent-neon);
  outline-offset: 4px;
  box-shadow: 0 0 12px rgba(var(--accent-neon-rgb),0.9), 0 0 24px rgba(var(--accent-neon-rgb),0.6);
  will-change: box-shadow;
}

/* Pulse effect using pseudo-element with transform and opacity animation */
@keyframes pulseRing {
  0% {
    transform: translate(-50%, -50%) scale(1);
    opacity: 0.4;
  }
  50% {
    transform: translate(-50%, -50%) scale(1.5);
    opacity: 0.1;
  }
  100% {
    transform: translate(-50%, -50%) scale(1);
    opacity: 0.4;
  }
}

.float-button.pulse::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  background: var(--accent-neon);
  opacity: 0.4;
  transform: translate(-50%, -50%) scale(1);
  pointer-events: none;
  z-index: -1;
  animation: pulseRing 2.5s ease-in-out infinite;
  will-change: transform, opacity;
}

@media (max-width: 768px) {
  .float-button {
    bottom: 1.5rem;
    right: 1.5rem;
    width: var(--btn-size-sm);
    height: var(--btn-size-sm);
    font-size: 1.2rem;
  }
}