html, body { margin: 0; height: 100%; background: #0B1120; overscroll-behavior: none; }
body { -webkit-tap-highlight-color: transparent; }
#app { position: fixed; inset: 0; display: flex; justify-content: center; }
#app > div { max-width: 560px; }
button { font-family: inherit; }
@keyframes rgPulse {
  0%, 100% { filter: drop-shadow(0 0 0 rgba(253, 230, 138, 0)); }
  50% { filter: drop-shadow(0 0 18px rgba(253, 230, 138, 0.95)); }
}
@keyframes leanPulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.3; }
}
@keyframes zeroIn {
  from { translate: var(--dx) var(--dy); opacity: 0.7; }
  to { translate: 0 0; opacity: 1; }
}
@keyframes readGlow {
  0%, 100% { color: inherit; text-shadow: 0 0 0 rgba(253, 230, 138, 0); }
  50% { color: #FDE68A; text-shadow: 0 0 8px rgba(253, 230, 138, 0.75); }
}
@keyframes trayPop {
  0% { scale: 0; opacity: 0; }
  60% { opacity: 1; }
  100% { scale: 1; opacity: 1; }
}
@keyframes winHop {
  0%, 100% { translate: 0 0; filter: drop-shadow(0 7px 12px rgba(0,0,0,0.4)); }
  30% { translate: 0 -22px; filter: drop-shadow(0 0 16px rgba(253,230,138,0.95)); }
  55% { translate: 0 0; }
  72% { translate: 0 -8px; filter: drop-shadow(0 0 10px rgba(253,230,138,0.7)); }
}
@keyframes winBox {
  0% { border-color: rgba(148,163,184,0.28); box-shadow: 0 0 0 rgba(242,179,61,0); }
  35% { border-color: #FDE68A; box-shadow: 0 0 28px rgba(253,230,138,0.55); }
  100% { border-color: #F2B33D; box-shadow: 0 0 12px rgba(242,179,61,0.3); }
}
@keyframes spark {
  0% { translate: 0 0; opacity: 0; scale: 0.4; }
  20% { opacity: 1; scale: 1; }
  100% { translate: var(--sx) var(--sy); opacity: 0; scale: 0.3; }
}
@keyframes popOut {
  0% { scale: 1; opacity: 1; }
  100% { scale: 0; opacity: 0; }
}
@keyframes boxIn {
  0% { scale: 0.85; opacity: 0; }
  100% { scale: 1; opacity: 1; }
}
@keyframes boxOut {
  0% { scale: 1; opacity: 1; }
  100% { scale: 0.85; opacity: 0; }
}
@keyframes trayUp {
  from { translate: 0 110%; opacity: 0.6; }
  to { translate: 0 0; opacity: 1; }
}
@keyframes trayDown {
  from { translate: 0 0; opacity: 1; }
  to { translate: 0 110%; opacity: 0.4; }
}
@property --glowA {
  syntax: '<angle>';
  initial-value: 0deg;
  inherits: false;
}
@keyframes glowSpin {
  to { --glowA: 360deg; }
}
@keyframes edgePulse {
  0%, 100% { stroke: #CBD5E1; stroke-width: 1.5; }
  50% { stroke: #F59E0B; stroke-width: 4; }
}
@keyframes nodePulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(245,158,11,0); scale: 1; }
  50% { box-shadow: 0 0 0 6px rgba(245,158,11,0.55); scale: 1.06; }
}
@keyframes edgeBreathe {
  0%, 100% { border-color: #CBD5E1; box-shadow: 0 0 0 0 rgba(148,163,184,0); }
  50% { border-color: #94A3B8; box-shadow: 0 0 0 3px rgba(148,163,184,0.28); }
}
/* boards swapping: tiles fall away into the distance and come in from it; the two readouts swing past each other */
@keyframes wsAway {
  from { scale: 1; opacity: 1; filter: blur(0); }
  to { scale: 0.02; opacity: 0; filter: blur(3px); }
}
@keyframes wsCome {
  from { scale: 0.02; opacity: 0; filter: blur(3px); }
  60% { opacity: 1; filter: blur(0); }
  to { scale: 1; opacity: 1; }
}
@keyframes wsFlyX {
  from { translate: var(--x0) 0; }
  to { translate: var(--x1) 0; }
}
@keyframes wsFlyUp {
  from { translate: 0 var(--y0); scale: 1; }
  50% { scale: 1.08; }
  to { translate: 0 var(--y1); scale: 0.9; }
}
@keyframes wsFlyDown {
  from { translate: 0 var(--y0); scale: 0.9; }
  50% { scale: 1.08; }
  to { translate: 0 var(--y1); scale: 1; }
}
