/* Full-screen WebGL visualizer (idle — coming soon) */
#viz-container {
  position: fixed;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  background: #08090f;
}

#viz-canvas {
  display: block;
  width: 100%;
  height: 100%;
}

.film-grain {
  position: fixed;
  inset: 0;
  z-index: 15;
  pointer-events: none;
  opacity: 0.22;
  mix-blend-mode: overlay;
}

.film-grain::after {
  content: "";
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 512 512' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.75' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='1'/%3E%3C/svg%3E");
  background-size: 180px 180px;
  animation: filmGrain 0.35s steps(6) infinite;
  will-change: transform;
}

@keyframes filmGrain {
  0% { transform: translate(0, 0); }
  16% { transform: translate(-3%, -4%); }
  33% { transform: translate(2%, -2%); }
  50% { transform: translate(-4%, 3%); }
  66% { transform: translate(3%, 2%); }
  83% { transform: translate(-2%, -3%); }
  100% { transform: translate(1%, 0); }
}

@media (prefers-reduced-motion: reduce) {
  .film-grain::after {
    animation: none;
  }
}
