/* Dark theme — deep midnight blues with vibrant accents */
[data-theme="dark"] {
  --color-bg: #1a1a2e;
  --color-app-bg: #0f0f1a;
  --color-cell-hidden: #1e2745;
  --color-cell-hidden-hover: #263052;
  --color-cell-hidden-gradient: linear-gradient(145deg, #243050, #1a2540);
  --color-cell-revealed: #0d1b3a;
  --color-cell-border-light: #2a3a5e;
  --color-cell-border-dark: #0a0a1a;
  --color-mine: #e94560;
  --color-mine-hit: #ff1744;
  --color-flag: #e94560;
  --color-text: #e8e8f0;
  --color-text-secondary: #8899bb;

  --color-num-1: #6baed6;
  --color-num-2: #66bb6a;
  --color-num-3: #ff6b6b;
  --color-num-4: #ce93d8;
  --color-num-5: #f48fb1;
  --color-num-6: #26c6da;
  --color-num-7: #bdbdbd;
  --color-num-8: #90a4ae;
  --color-num-9: #ff8a50;
  --color-num-10: #4dd0e1;
  --color-num-11: #ce93d8;
  --color-num-12: #dce775;
  --color-num-13: #ff7043;
  --color-num-14: #4db6ac;
  --color-num-15: #b39ddb;
  --color-num-16: #ffab91;
  --color-num-17: #7986cb;
  --color-num-18: #f48fb1;

  --color-header-bg: #16213e;
  --color-header-gradient: linear-gradient(180deg, #1e2d50, #162040);
  --color-lcd-bg: #060612;
  --color-lcd-text: #e94560;
  --color-modal-bg: #1a1a2e;
  --color-modal-overlay: rgba(0, 0, 0, 0.75);
  --color-btn-bg: #1e2745;
  --color-btn-hover: #263052;
  --color-btn-gradient: linear-gradient(180deg, #263052, #1e2745);
  --color-border: #2a3a5e;
  --color-fog: rgba(0, 0, 0, 0.92);
  --color-scan-highlight: rgba(255, 215, 0, 0.2);
  --color-golden: #ffc107;
  --color-accent: #e94560;
  --color-accent-hover: #d63851;
  --color-accent-glow: rgba(233, 69, 96, 0.3);
  --color-wall: #7a93af;
  --color-surface: rgba(255, 255, 255, 0.04);

  --shadow-app: 0 8px 40px rgba(0, 0, 0, 0.5), inset 0 1px 0 rgba(255,255,255,0.03);
  --bg-modal-close-hover: rgba(255,255,255,0.08);

  /* Hushed-night motion: slower than classic, always settling. */
  --anim-reveal-dur: 0.32s;
  --anim-reveal-ease: ease-out;
  --anim-flag-dur: 0.26s;
  --anim-flag-ease: ease-out;
}

/* Flag moment: a marker set down quietly — drifts a hair downward into
   place and dims to rest. No bounce; nothing in this world bounces. */
[data-theme="dark"] .cell.flag-pop {
  animation-name: darkFlagSet;
}
@keyframes darkFlagSet {
  0%   { opacity: 0; transform: translateY(-3px) scale(1.08); filter: brightness(1.4); }
  70%  { opacity: 1; transform: translateY(0) scale(1); filter: brightness(1.1); }
  100% { opacity: 1; transform: translateY(0) scale(1); filter: brightness(1); }
}

/* Reveal moment: moonlight reaching a tile — it surfaces from the dark
   with a soft cool halo that brightens past rest, then settles. Quiet,
   like the rest of this world. */
[data-theme="dark"] .cell.num-pop,
[data-theme="dark"] .cell.revealing {
  animation-name: darkMoonrise;
}
@keyframes darkMoonrise {
  0%   { opacity: 0; transform: scale(0.94); filter: brightness(0.4); box-shadow: 0 0 0 rgba(180,200,255,0); }
  45%  { opacity: 1; filter: brightness(1.3); box-shadow: 0 0 12px rgba(180,200,255,0.22); }
  75%  { filter: brightness(1.05); box-shadow: 0 0 5px rgba(180,200,255,0.1); }
  100% { opacity: 1; transform: scale(1); filter: brightness(1); box-shadow: 0 0 0 rgba(180,200,255,0); }
}
