/* Commie vs Zombies — base theme (Soviet constructivist). Shared file: agents must NOT edit. */
:root {
  --red: #c02020;
  --red-dark: #7a1010;
  --gold: #e8b83a;
  --ink: #111111;
  --paper: #e8e0d0;
  --grey: #4a4a48;
  --cb-enemy: #2a7fff;   /* colorblind: blue instead of red */
  --cb-safe: #e8d23a;

  /* ---- PHASE 19(B): ONE TYPE SCALE -------------------------------------
     The menus had FIFTEEN distinct font sizes between 11 and 46 px, chosen a
     surface at a time. These are the seven steps they collapse onto. Sizes are
     the only thing that changed; every weight, colour and letter-spacing in the
     constructivist treatment is untouched, because the player asked for the art
     direction to stay and the legibility to improve. */
  --fs-xs: 12px;    /* legal/footnote — was 11, 12 */
  --fs-sm: 14px;    /* body, list rows — was 13, 14 */
  --fs-md: 16px;    /* emphasis, sub-heads — was 15, 16, 17 */
  --fs-lg: 20px;    /* section heads — was 19, 20 */
  --fs-xl: 24px;    /* panel heads — was 22, 26 */
  --fs-2xl: 34px;   /* screen heads — was 30, 34, 36 */
  --fs-3xl: 46px;   /* the title */

  /* ---- ONE SPACING SCALE ------------------------------------------------
     A 4 px base, so a gap is always a multiple of the same unit rather than
     whatever looked right on that panel. */
  --sp-1: 4px;
  --sp-2: 8px;
  --sp-3: 12px;
  --sp-4: 18px;
  --sp-5: 26px;
  --sp-6: 38px;

  /* ---- ONE FOCUS TREATMENT ---------------------------------------------
     Controller and keyboard focus is a GOLD RING, everywhere, and it is never
     the mouse hover style: 15.5(b) needs focus to be visible on a control the
     pointer is nowhere near. */
  --focus: 0 0 0 2px var(--gold), 0 0 0 4px rgba(0, 0, 0, 0.75);
  --font: 'Arial Narrow', 'Helvetica Neue', Impact, sans-serif;
}
* { margin: 0; padding: 0; box-sizing: border-box; border-radius: 0 !important; }
html, body { width: 100%; height: 100%; overflow: hidden; background: #000; }
body { font-family: var(--font); color: var(--paper); text-transform: uppercase; letter-spacing: 0.06em; }
#game { position: fixed; inset: 0; width: 100%; height: 100%; display: block; }
#ui { position: fixed; inset: 0; pointer-events: none; z-index: 10; }
#ui > * { pointer-events: none; }
#ui .clickable, #ui button, #ui .slot { pointer-events: auto; }

/* CRT / retro overlays */
#scanlines { position: fixed; inset: 0; pointer-events: none; z-index: 40; opacity: 0.07;
  background: repeating-linear-gradient(0deg, #000 0 1px, transparent 1px 3px); }
#vignette { position: fixed; inset: 0; pointer-events: none; z-index: 39;
  background: radial-gradient(ellipse at center, transparent 55%, rgba(0,0,0,0.55) 100%); }
#grain { position: fixed; inset: -100px; pointer-events: none; z-index: 38; opacity: 0; transition: opacity 1s;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2'/%3E%3C/filter%3E%3Crect width='120' height='120' filter='url(%23n)' opacity='0.5'/%3E%3C/svg%3E");
  animation: grain 0.4s steps(4) infinite; }
body.zone-b #grain { opacity: 0.08; }
body.zone-c #grain { opacity: 0.16; }
@keyframes grain { 0%{transform:translate(0,0)} 25%{transform:translate(-30px,20px)} 50%{transform:translate(20px,-25px)} 75%{transform:translate(-15px,-10px)} 100%{transform:translate(0,0)} }

/* Shared UI primitives */
.soviet-panel { background: rgba(12,10,8,0.92); border: 3px solid var(--red); box-shadow: 6px 6px 0 rgba(0,0,0,0.6); }
.soviet-btn { display: block; width: 100%; padding: 12px 28px; background: var(--ink); color: var(--paper);
  border: 2px solid var(--red); font-family: var(--font); font-size: 20px; font-weight: bold;
  text-transform: uppercase; letter-spacing: 0.15em; cursor: pointer; text-align: left; }
.soviet-btn:hover { background: var(--red); color: #fff; }
.soviet-btn:disabled { opacity: 0.35; cursor: default; background: var(--ink); }
.star::before { content: "★ "; color: var(--gold); }
.hidden { display: none !important; }

/* Gamepad UI focus highlight */
.gp-focus { outline: 3px solid var(--gold) !important; outline-offset: 2px; background: var(--red) !important; color: #fff !important; }
.opt-status { color: var(--gold); font-size: 14px; letter-spacing: 0.12em; padding: 2px 0 8px 4px; }
