/**
 * Violator atmosphere — fondo negro absoluto (sin niebla crimson).
 */
.vx-atmosphere {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
  background: #000000;
}

/* Sin pulso rojo: capa vacía / transparente */
.vx-atmosphere__pulse {
  display: none;
}

.vx-atmosphere__veil {
  position: absolute;
  inset: 0;
  background: #000000;
}

.vx-atmosphere__grain {
  position: absolute;
  inset: -10%;
  width: 120%;
  height: 120%;
  opacity: 0.028;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  background-size: 160px 160px;
  animation: vxGrainDrift 0.45s steps(2) infinite;
  will-change: transform, background-position;
}

.vx-atmosphere__grain-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0.028;
  mix-blend-mode: overlay;
  pointer-events: none;
  display: none;
}

.vx-atmosphere__grain-canvas.is-on {
  display: block;
}

.vx-atmosphere.has-canvas-grain .vx-atmosphere__grain {
  opacity: 0.01;
}

.vx-atmosphere__scanlines {
  position: absolute;
  inset: 0;
  opacity: 0.015;
  background: repeating-linear-gradient(
    to bottom,
    rgba(255, 255, 255, 0.85) 0,
    rgba(255, 255, 255, 0.85) 1px,
    transparent 1px,
    transparent 4px
  );
  mix-blend-mode: soft-light;
  pointer-events: none;
}

@keyframes vxGrainDrift {
  0% { transform: translate(0, 0); background-position: 0 0; }
  50% { transform: translate(-1.5%, 1%); background-position: 40px -28px; }
  100% { transform: translate(1%, -0.5%); background-position: -24px 36px; }
}

@media (prefers-reduced-motion: reduce) {
  .vx-atmosphere__grain {
    animation: none;
  }
  .vx-atmosphere__grain-canvas {
    display: none !important;
  }
}
