#stash-toggle { position: fixed; top: 20px; right: 20px; z-index: 31; width: 44px; height: 44px; border-radius: 50%; background: #111c; color: white; border: 1px solid #ffffff50; font-size: 20px; cursor: pointer; }
#stash-dialog { margin: auto; width: min(92vw, 480px); max-height: 88dvh; overflow: auto; padding: 32px 24px; border: 1px solid #00c3ff80; border-radius: 18px; background: #101218; color: #fff; box-shadow: 0 0 70px #00c3ff20; cursor: auto; }
#stash-dialog::backdrop { background: #000c; backdrop-filter: blur(10px); }
#stash-dialog [hidden] { display: none !important; }
#stash-dialog button { color: white; background: #ffffff0c; border: 1px solid #ffffff30; border-radius: 10px; padding: 12px; cursor: pointer; }
#stash-dialog button:hover { background: #00c3ff25; border-color: #00c3ff; }
#stash-dialog button:focus-visible, #stash-code:focus-visible, #stash-toggle:focus-visible { outline: 2px solid #00c3ff; outline-offset: 3px; }
#stash-dialog button:disabled { cursor: default; opacity: .7; }
#stash-dialog .stash-close { position: absolute; right: 10px; top: 8px; padding: 2px 10px; font-size: 24px; border: 0; }
#stash-dialog h2 { margin: 12px 0; font-size: 26px; }
.stash-eyebrow { color: #00c3ff; font-size: 11px; letter-spacing: 3px; }
.stash-muted { color: #a5aab8; font-size: 13px; line-height: 1.6; margin-bottom: 22px; }
#stash-form label { display: block; font-size: 12px; margin-bottom: 8px; }
#stash-code { width: 100%; padding: 14px; text-align: center; letter-spacing: 12px; font-size: 26px; color: white; background: #0006; border: 1px solid #ffffff40; border-radius: 10px; }
.stash-key-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 9px; margin-top: 14px; }
#stash-message { min-height: 20px; margin-top: 12px; color: #ffb4b4; font-size: 13px; }
.stash-games { display: grid; gap: 12px; margin-bottom: 22px; }
.stash-games button { text-align: left; }
.stash-games strong, .stash-games span { display: block; }
.stash-games span { margin-top: 8px; color: #a5aab8; font-size: 12px; }
#stash-game-status { min-height: 40px; margin: 16px 0; line-height: 1.5; }
#stash-board { display: grid; gap: 8px; margin-bottom: 20px; }
#stash-board.ttt { grid-template-columns: repeat(3, 1fr); }
#stash-board.ttt button { height: 85px; font-size: 32px; }
#stash-board.memory { grid-template-columns: repeat(4, 1fr); }
#stash-board.memory button { height: 65px; font-size: 24px; }
#stash-board .reaction-pad { min-height: 160px; font-size: 20px; }
#stash-board .reaction-ready { background: #16683f; }
#stash-search { width: 100%; margin: 10px 0; padding: 12px; border-radius: 10px; border: 1px solid #ffffff40; background: #0006; color: white; font-size: 16px; }
#stash-dialog:has(#stash-library:not([hidden])) { width: min(94vw, 960px); }
#stash-dialog .stash-games { grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); }
#stash-dialog .stash-games button { min-height: 65px; overflow-wrap: anywhere; }
#stash-dialog.stash-playing { width: min(96vw, 1280px); max-height: 96dvh; padding: 32px 16px 16px; }
.stash-player-actions { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; margin-bottom: 12px; }
#stash-open-tab { color: #8bdeff; padding: 10px; }
#stash-frame-container { height: min(65dvh, 760px); min-height: 240px; background: black; margin-bottom: 12px; }
#stash-frame-container iframe { width: 100%; height: 100%; border: 0; display: block; background: black; }
#stash-frame-container:fullscreen { width: 100vw; height: 100dvh; margin: 0; }
#stash-player #stash-game-status { font-size: 12px; min-height: 20px; margin: 10px 0; }
