/* Arcade: a 1970s/80s arcade cabinet. Black space with a faint starfield,
   white and arcade-green pixels, chunky upper-case headings; a laser
   cannon at the bottom of the window takes shots at a saucer flying
   across the top (pistar.js draws them). Meets 4.5:1 like every theme;
   the motion stops for reduced motion. */
:root[data-theme="arcade-dark"] {
  --ps-bg-primary: #000000;
  --ps-bg-secondary: #07070f;
  --ps-bg-tertiary: #11111f;
  --ps-border: #2f9a1a;
  --ps-text-primary: #f2f2f2;
  --ps-text-secondary: #b8b8c8;
  --ps-text-inverse: #000000;
  --ps-accent: #39ff14;
  --ps-accent-hover: #9dff8a;
  --ps-accent-subtle: #0b2a05;
  --ps-success: #39ff14;
  --ps-warning: #ffd23f;
  --ps-danger: #ff5c5c;
  --ps-info: #5ad1ff;
  --ps-nav-bg: #000000;
  --ps-nav-text: #f2f2f2;
  --ps-input-bg: #000000;
  --ps-input-border: #2f9a1a;
  --ps-table-header-bg: #11111f;
  /* The LCDs glow arcade green */
  --lcd-bg: #020a02;
  --lcd-ink: #39ff14;
  /* The accent and state colours as text, and the buttons: readable
     (4.5:1) on this theme */
  --ps-accent-text: #39ff14;
  --ps-info-text: #5ad1ff;
  --ps-success-text: #39ff14;
  --ps-warning-text: #ffd23f;
  --ps-danger-text: #ff5c5c;
  --ps-on-accent: #000000;
  --ps-accent-btn: #39ff14;
  --ps-accent-btn-hover: #9dff8a;
}

/* A faint, fixed starfield behind everything */
:root[data-theme="arcade-dark"] {
  background: #000000;
}
:root[data-theme="arcade-dark"] body {
  background-color: #000000;
  background-image:
    radial-gradient(1px 1px at 12% 18%, rgba(255, 255, 255, 0.55) 50%, transparent 51%),
    radial-gradient(1px 1px at 37% 64%, rgba(255, 255, 255, 0.4) 50%, transparent 51%),
    radial-gradient(1px 1px at 58% 27%, rgba(255, 255, 255, 0.5) 50%, transparent 51%),
    radial-gradient(1px 1px at 81% 72%, rgba(255, 255, 255, 0.45) 50%, transparent 51%),
    radial-gradient(1px 1px at 91% 12%, rgba(255, 255, 255, 0.35) 50%, transparent 51%),
    radial-gradient(1px 1px at 24% 88%, rgba(255, 255, 255, 0.35) 50%, transparent 51%),
    radial-gradient(1px 1px at 69% 91%, rgba(255, 255, 255, 0.3) 50%, transparent 51%),
    radial-gradient(1px 1px at 6% 47%, rgba(255, 255, 255, 0.3) 50%, transparent 51%);
  background-size: 420px 420px;
  background-attachment: fixed;
}

/* Monospace, like the score digits on a cabinet */
:root[data-theme="arcade-dark"] body,
:root[data-theme="arcade-dark"] input,
:root[data-theme="arcade-dark"] select,
:root[data-theme="arcade-dark"] textarea,
:root[data-theme="arcade-dark"] button {
  font-family: var(--ps-font-mono, "JetBrains Mono", monospace);
}

/* Chunky upper-case headings in arcade green */
:root[data-theme="arcade-dark"] h1,
:root[data-theme="arcade-dark"] h2,
:root[data-theme="arcade-dark"] h3 {
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--ps-accent-text);
}

/* Square, pixel-edged panels and controls */
:root[data-theme="arcade-dark"] .card,
:root[data-theme="arcade-dark"] .lcd-bezel,
:root[data-theme="arcade-dark"] .lcd-screen,
:root[data-theme="arcade-dark"] input,
:root[data-theme="arcade-dark"] select,
:root[data-theme="arcade-dark"] .btn,
:root[data-theme="arcade-dark"] button {
  border-radius: 0;
}
:root[data-theme="arcade-dark"] .card {
  border: 2px solid var(--ps-border);
  box-shadow: 4px 4px 0 #0b2a05;
}
:root[data-theme="arcade-dark"] .lcd-bezel {
  background: #050505;
  border: 2px solid var(--ps-border);
}

/* Buttons like a cabinet's: lit green, black lettering */
:root[data-theme="arcade-dark"] .btn {
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

/* The cannon and the saucer (pistar.js draws them): level with the top
   bar and after it on the page, so a score floating up is drawn over the
   bar; toasts and overlays stay above */
#ps-arcade {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 100;
}
