/**
 * CRT Visual Effects
 * Desktop-only, respects prefers-reduced-motion
 * Scanlines and glow are in terminal-shell component
 * This file adds global flicker effect (optional) and additional enhancements
 */

/* Subtle screen flicker - Claude's discretion choice: YES, very subtle */
@keyframes crt-flicker {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.98; }
}

/* Apply flicker to terminal-shell on desktop */
@media (min-width: 768px) and (prefers-reduced-motion: no-preference) {
  terminal-shell {
    animation: crt-flicker 0.15s infinite;
  }
}

/* Disable flicker for reduced motion */
@media (prefers-reduced-motion: reduce) {
  terminal-shell {
    animation: none !important;
  }
}

/* Disable on mobile completely */
@media (max-width: 767px) {
  terminal-shell {
    animation: none !important;
  }
}

/**
 * Additional CRT enhancement: subtle vignette
 * Creates darker edges like old CRT monitors
 */
@media (min-width: 768px) {
  terminal-shell::after {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(
      ellipse at center,
      transparent 60%,
      rgba(0, 0, 0, 0.3) 100%
    );
    pointer-events: none;
    z-index: 3;
  }
}

@media (max-width: 767px) {
  terminal-shell::after {
    display: none;
  }
}

/* High contrast mode: disable all visual effects */
@media (prefers-contrast: high) {
  terminal-shell {
    animation: none !important;
  }
  terminal-shell::after {
    display: none;
  }
}
