/* ── Display finish: mild contrast + optional scan raster (no animated phosphor stack).
 * Remote CDNs on this page: Google Fonts + jsDelivr (html2canvas).
 */

:root {
  --crt-f-idle: brightness(1) contrast(1.08) saturate(1.08);
}

@media (prefers-reduced-motion: reduce) {
  body {
    animation: none !important;
    filter: var(--crt-f-idle) !important;
  }

  body::before,
  body::after {
    animation: none !important;
  }

  body::before {
    opacity: 0.62 !important;
  }

  body::after {
    opacity: 1 !important;
  }
}

body {
  /* Stable tube grade — SNES menus read flat; flicker disabled for calmer motion */
  filter: var(--crt-f-idle);
  animation: none;
}

body::before,
body::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
}

/* Light scan raster: tiled SVG (no CSS color-gradient stack) */
body::before {
  z-index: 9999;
  mix-blend-mode: multiply;
  opacity: 0.42;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='4' height='4'%3E%3Crect width='4' height='1' fill='%23000' fill-opacity='0.14'/%3E%3C/svg%3E");
  background-size: 4px 4px;
  animation: none;
}

/* Bezel darken + slight purple tube cast (GCN startup memory) */
body::after {
  z-index: 9998;
  mix-blend-mode: normal;
  background: transparent;
  box-shadow:
    inset 0 0 min(180px, 28vw) rgba(0, 0, 0, 0.55),
    inset 0 0 min(100px, 18vw) rgba(45, 27, 105, 0.18);
  animation: none;
}
