/* CRT Shader & Screen Overlays */
.crt-overlay {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 10;
  transition: opacity 0.4s ease;
}

.crt-overlay.hidden {
  opacity: 0;
}

.crt-scanlines {
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(
    0deg,
    rgba(0, 0, 0, 0) 0px,
    rgba(0, 0, 0, 0) 1px,
    rgba(0, 0, 0, 0.18) 2px,
    rgba(0, 0, 0, 0.18) 3px
  );
  mix-blend-mode: multiply;
}

.crt-vignette {
  position: absolute;
  inset: 0;
  background: radial-gradient(
    ellipse at center,
    transparent 35%,
    rgba(0, 0, 0, 0.35) 85%,
    rgba(0, 0, 0, 0.7) 100%
  );
}

.crt-scanbeam {
  position: absolute;
  left: 0;
  right: 0;
  height: 80px;
  background: linear-gradient(
    to bottom,
    transparent 0%,
    rgba(126, 231, 135, 0.05) 50%,
    transparent 100%
  );
  animation: scanbeam 9s linear infinite;
}

@keyframes scanbeam {
  0% {
    top: -80px;
  }
  100% {
    top: 100%;
  }
}

.crt-flicker {
  position: absolute;
  inset: 0;
  background: rgba(126, 231, 135, 0.015);
  animation: flicker 0.18s steps(2) infinite;
  mix-blend-mode: overlay;
}

@keyframes flicker {
  0% {
    opacity: 0.95;
  }
  100% {
    opacity: 1;
  }
}
