/* Cannon Crash — cannon physics game */
#game-stage { display: flex; flex-direction: column; align-items: center; width: 100%; }

.rs-toprow { width: 100%; max-width: 420px; display: flex; justify-content: flex-end; margin-bottom: 4px; }
.sound-btn { background: var(--panel); border: 1px solid var(--border); color: var(--text);
  border-radius: 10px; padding: 6px 10px; font-size: 16px; cursor: pointer; touch-action: manipulation; }

.rs-hud { width: 100%; max-width: 420px; display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 10px; margin-bottom: 10px; }
.rs-hud .lbl { color: var(--muted); font-size: 11px; text-transform: uppercase; letter-spacing: 1px; }
.rs-val { font-size: 26px; font-weight: 900; line-height: 1.1; font-variant-numeric: tabular-nums; }
.rs-rocks { font-size: 24px; letter-spacing: 2px; min-height: 30px; }
.rs-msg { font-size: 16px; color: var(--neon); min-height: 22px; text-align: center; }

.rs-stage-wrap { position: relative; width: 100%; max-width: 420px; aspect-ratio: 420/560; }
.rs-canvas { width: 100%; height: 100%; display: block; border: 1px solid var(--border);
  border-radius: 14px; touch-action: none; background: #060916; }

.rs-overlay { position: absolute; inset: 0; z-index: 5; display: flex; align-items: center; justify-content: center;
  background: rgba(5,6,15,.82); border-radius: 14px; backdrop-filter: blur(2px); text-align: center; }
.rs-overlay.rs-hidden { display: none; }
.rs-overlay-inner { padding: 20px; }
.rs-ov-title { font-size: 36px; font-weight: 900; color: var(--neon); text-shadow: 0 0 16px rgba(0,245,212,.5); margin: 0 0 6px; }
.rs-ov-title.lose { color: var(--neon2); text-shadow: 0 0 16px rgba(255,46,151,.5); }
.rs-ov-title.win { color: var(--neon4, #ffd23f); text-shadow: 0 0 16px rgba(255,210,63,.5); }
.rs-ov-sub { color: var(--muted); margin: 0 0 18px; font-size: 16px; }
.rs-overlay .gbtn { margin: 4px; }
.rs-hide { display: none !important; }

/* difficulty selector */
.rs-diff-row { display: inline-flex; background: var(--panel); border: 1px solid var(--border);
  border-radius: 12px; padding: 4px; gap: 4px; margin-bottom: 16px; }
.rs-seg-btn { background: none; border: none; color: var(--muted); font-family: inherit; font-size: 14px;
  font-weight: 600; padding: 8px 13px; border-radius: 9px; cursor: pointer; touch-action: manipulation; transition: background .12s, color .12s; }
.rs-seg-btn.active { background: var(--neon3); color: #fff; box-shadow: 0 0 14px rgba(123,92,255,.5); }

.ctrl-hint { color: var(--muted); font-size: 13px; text-align: center; margin: 12px 0 0; }
