/* Neon Checkbox - Adaptado a Select Your Vet (#1B5D63) */
.neon-checkbox {
  --primary: #1B5D63;
  --primary-dark: #144a4f;
  --primary-light: #5a8d92;
  --size: 28px;
  position: relative;
  width: var(--size);
  height: var(--size);
  cursor: pointer;
  flex-shrink: 0;
  -webkit-tap-highlight-color: transparent;
  overflow: hidden;
}

.neon-checkbox input,
.neon-checkbox input[type="checkbox"] {
  display: none !important;
  opacity: 0 !important;
  position: absolute !important;
  pointer-events: none !important;
  width: 0 !important;
  height: 0 !important;
}

.neon-checkbox__frame {
  position: relative;
  width: 100%;
  height: 100%;
}

.neon-checkbox__box {
  position: absolute;
  inset: 0;
  background: rgba(255, 255, 255, 0.95);
  border-radius: 4px;
  border: 2px solid var(--primary-dark);
  transition: all 0.4s ease;
}

.neon-checkbox__check-container {
  position: absolute;
  inset: 2px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.neon-checkbox__check {
  width: 80%;
  height: 80%;
  fill: none;
  stroke: var(--primary);
  stroke-width: 3;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-dasharray: 40;
  stroke-dashoffset: 40;
  transform-origin: center;
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.neon-checkbox__glow {
  position: absolute;
  inset: -2px;
  border-radius: 6px;
  background: var(--primary);
  opacity: 0;
  filter: blur(8px);
  transform: scale(1.2);
  transition: all 0.4s ease;
}

.neon-checkbox__borders {
  position: absolute;
  inset: 0;
  border-radius: 4px;
  overflow: hidden;
}

.neon-checkbox__borders span {
  position: absolute;
  width: 40px;
  height: 1px;
  background: var(--primary);
  opacity: 0;
  transition: opacity 0.4s ease;
}

.neon-checkbox__borders span:nth-child(1) {
  top: 0;
  left: -100%;
  animation: neonBorderFlow1 2s linear infinite;
}

.neon-checkbox__borders span:nth-child(2) {
  top: -100%;
  right: 0;
  width: 1px;
  height: 40px;
  animation: neonBorderFlow2 2s linear infinite;
}

.neon-checkbox__borders span:nth-child(3) {
  bottom: 0;
  right: -100%;
  animation: neonBorderFlow3 2s linear infinite;
}

.neon-checkbox__borders span:nth-child(4) {
  bottom: -100%;
  left: 0;
  width: 1px;
  height: 40px;
  animation: neonBorderFlow4 2s linear infinite;
}

.neon-checkbox__particles span {
  position: absolute;
  width: 4px;
  height: 4px;
  background: var(--primary);
  border-radius: 50%;
  opacity: 0;
  pointer-events: none;
  top: 50%;
  left: 50%;
  box-shadow: 0 0 6px var(--primary);
}

.neon-checkbox__rings {
  position: absolute;
  inset: -20px;
  pointer-events: none;
}

.neon-checkbox__rings .ring {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 1px solid var(--primary);
  opacity: 0;
  transform: scale(0);
}

.neon-checkbox__sparks span {
  position: absolute;
  width: 20px;
  height: 1px;
  background: linear-gradient(90deg, var(--primary), transparent);
  opacity: 0;
}

.neon-checkbox:hover .neon-checkbox__box {
  border-color: var(--primary);
  transform: scale(1.05);
}

.neon-checkbox input:checked ~ .neon-checkbox__frame .neon-checkbox__box {
  border-color: var(--primary);
  background: rgba(27, 93, 99, 0.12);
}

.neon-checkbox input:checked ~ .neon-checkbox__frame .neon-checkbox__check {
  stroke-dashoffset: 0;
  transform: scale(1.1);
}

.neon-checkbox input:checked ~ .neon-checkbox__frame .neon-checkbox__glow {
  opacity: 0.2;
}

.neon-checkbox input:checked ~ .neon-checkbox__frame .neon-checkbox__borders span {
  opacity: 1;
}

.neon-checkbox input:checked ~ .neon-checkbox__frame .neon-checkbox__particles span {
  animation: neonParticleExplosion 0.6s ease-out forwards;
}

.neon-checkbox input:checked ~ .neon-checkbox__frame .neon-checkbox__rings .ring {
  animation: neonRingPulse 0.6s ease-out forwards;
}

.neon-checkbox input:checked ~ .neon-checkbox__frame .neon-checkbox__sparks span {
  animation: neonSparkFlash 0.6s ease-out forwards;
}

@keyframes neonBorderFlow1 {
  0% { transform: translateX(0); }
  100% { transform: translateX(200%); }
}

@keyframes neonBorderFlow2 {
  0% { transform: translateY(0); }
  100% { transform: translateY(200%); }
}

@keyframes neonBorderFlow3 {
  0% { transform: translateX(0); }
  100% { transform: translateX(-200%); }
}

@keyframes neonBorderFlow4 {
  0% { transform: translateY(0); }
  100% { transform: translateY(-200%); }
}

@keyframes neonParticleExplosion {
  0% { transform: translate(-50%, -50%) scale(1); opacity: 0; }
  20% { opacity: 1; }
  100% {
    transform: translate(calc(-50% + var(--x, 20px)), calc(-50% + var(--y, 20px))) scale(0);
    opacity: 0;
  }
}

@keyframes neonRingPulse {
  0% { transform: scale(0); opacity: 1; }
  100% { transform: scale(2); opacity: 0; }
}

@keyframes neonSparkFlash {
  0% { transform: rotate(var(--r, 0deg)) translateX(0) scale(1); opacity: 1; }
  100% { transform: rotate(var(--r, 0deg)) translateX(30px) scale(0); opacity: 0; }
}

.neon-checkbox__particles span:nth-child(1) { --x: 25px; --y: -25px; }
.neon-checkbox__particles span:nth-child(2) { --x: -25px; --y: -25px; }
.neon-checkbox__particles span:nth-child(3) { --x: 25px; --y: 25px; }
.neon-checkbox__particles span:nth-child(4) { --x: -25px; --y: 25px; }
.neon-checkbox__particles span:nth-child(5) { --x: 35px; --y: 0; }
.neon-checkbox__particles span:nth-child(6) { --x: -35px; --y: 0; }
.neon-checkbox__particles span:nth-child(7) { --x: 0; --y: 35px; }
.neon-checkbox__particles span:nth-child(8) { --x: 0; --y: -35px; }
.neon-checkbox__particles span:nth-child(9) { --x: 20px; --y: -30px; }
.neon-checkbox__particles span:nth-child(10) { --x: -20px; --y: 30px; }
.neon-checkbox__particles span:nth-child(11) { --x: 30px; --y: 20px; }
.neon-checkbox__particles span:nth-child(12) { --x: -30px; --y: -20px; }

.neon-checkbox__sparks span:nth-child(1) { --r: 0deg; top: 50%; left: 50%; }
.neon-checkbox__sparks span:nth-child(2) { --r: 90deg; top: 50%; left: 50%; }
.neon-checkbox__sparks span:nth-child(3) { --r: 180deg; top: 50%; left: 50%; }
.neon-checkbox__sparks span:nth-child(4) { --r: 270deg; top: 50%; left: 50%; }

.neon-checkbox__rings .ring:nth-child(1) { animation-delay: 0s; }
.neon-checkbox__rings .ring:nth-child(2) { animation-delay: 0.1s; }
.neon-checkbox__rings .ring:nth-child(3) { animation-delay: 0.2s; }

/* Wrapper para label + texto */
.neon-checkbox-wrap {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  font-size: 1rem;
}

.neon-checkbox-wrap .neon-checkbox {
  flex-shrink: 0;
}

/* Layout checkboxes en fila (listeo, type-check, etc.) */
.type-checkboxes .neon-checkbox-wrap,
.referral-checkboxes .neon-checkbox-wrap,
.checkboxes.in-row .neon-checkbox-wrap,
.special-services .neon-checkbox-wrap {
  margin-right: 16px;
  margin-bottom: 8px;
  padding-left: 0 !important;
}

.checkboxes.in-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 16px;
  align-items: center;
}

/* En registro y listados: no mostrar el ::before del tema (caja/borde que se veía como línea verde) */
.checkboxes .neon-checkbox-wrap::before {
  display: none !important;
}
