.catalog-heading{display:flex;align-items:flex-start;justify-content:space-between;gap:12px;padding:2px 0 8px}.catalog-heading h1{margin:0}.catalog-heading p{margin:3px 0 0;color:#4d4d4d}
.catalog-controls{display:flex;align-items:center;gap:8px;flex-wrap:wrap;margin:0 0 12px;padding:6px 8px;border:1px solid #aca899;background:#ece9d8;font:11px/1.4 var(--font-ui)}
.catalog-controls .result-count{margin-right:auto}.catalog-controls select{max-width:160px}.view-controls{display:flex;gap:3px}.view-controls .xp-button{min-width:28px;padding:4px 6px}
.notice{display:flex;align-items:center;gap:8px;padding:8px 10px;margin:0 0 12px;background:#ffffe1;border:1px solid #d5cba3;font:11px/1.5 var(--font-ui)}.notice p{margin:0;flex:1;min-width:150px}.notice>a{margin-left:auto;white-space:nowrap}
.game-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:16px 12px;align-items:stretch}
.game-card{min-width:0;display:flex;flex-direction:column;border-bottom:1px solid #c0c0c0;padding-bottom:8px}
.game-image{display:flex;align-items:center;justify-content:center;position:relative;aspect-ratio:1;width:100%;overflow:hidden;background:#fff;border:1px solid #7f9db9}
.game-image img{width:100%;height:100%;object-fit:contain;display:block;padding:3px}.game-image:hover{outline:1px solid #215dc6;outline-offset:1px}
.collection-image{background:linear-gradient(#fff 65%,#f6f5ee)}.collection-image img{width:58%;height:58%;padding:0;image-rendering:pixelated}
.game-card h2{margin:5px 0 3px;font:700 16px/1.15 var(--font-prose);overflow-wrap:anywhere}.game-card p{margin:5px 0 8px;line-height:1.25;overflow-wrap:anywhere}
.card-meta{font:11px/1.4 var(--font-ui);color:#4d4d4d}.card-bottom{display:flex;align-items:center;gap:6px;justify-content:space-between;margin-top:auto;padding-top:2px;font:11px/1.4 var(--font-ui)}.card-bottom .xp-button{min-width:32px;padding:4px 6px}
.game-grid.is-list{grid-template-columns:1fr;gap:0}.is-list .game-card{display:grid;grid-template-columns:72px minmax(0,1fr) auto;gap:0 12px;padding:10px 0;position:relative}.is-list .game-image{grid-column:1;grid-row:1/5;width:72px;align-self:center}.is-list h2,.is-list .card-meta,.is-list p{grid-column:2}.is-list h2{margin:0 0 4px}.is-list p{margin:2px 0}.is-list .card-bottom{grid-column:3;grid-row:1/5;align-self:center}
.empty-state{padding:40px 20px;text-align:center;border:1px solid #c8c7bd;background:#fafaf7}.empty-state>img{display:block;width:64px;height:64px;image-rendering:pixelated;margin:0 auto 16px}.empty-state h2{margin-bottom:8px}.empty-state p{max-width:52ch;margin:0 auto 16px}.empty-state .button-row{justify-content:center}
.button-row{display:flex;gap:8px;align-items:center;flex-wrap:wrap}.back-link{display:inline-flex;align-items:center;min-height:25px;margin-bottom:10px;font:11px/1.4 var(--font-ui)}
.help-page{max-width:780px}.help-page h2{font-size:18px;margin-top:24px;margin-bottom:8px}.help-page>p{max-width:66ch}.help-page ul{padding-left:20px}.help-page li{margin-bottom:6px}.help-page .notice{margin-top:16px}.help-page details{border-top:1px solid #c0c0c0;padding:12px 0}.help-page summary{font:700 16px/1.3 var(--font-prose);min-height:32px;cursor:var(--cursor-hand)}.help-page details p{margin:8px 0}.help-page .xp-button{margin-bottom:8px}
.help-table{width:100%;border-collapse:collapse;margin:12px 0 20px;font:11px/1.5 var(--font-ui)}.help-table th,.help-table td{padding:7px 8px;text-align:left;border:1px solid #aca899}.help-table th{background:#ece9d8}
.player-header{margin-bottom:12px}.player-header h1{margin-bottom:4px}.player-header p{max-width:70ch;margin-bottom:4px}
.player-window{border:1px solid #0831a8;border-radius:4px 4px 0 0;background:#ece9d8;overflow:hidden;min-width:0}.window-titlebar{color:#fff;font:700 11px/1.4 var(--font-ui);text-shadow:1px 1px 0 #0a1f7a}.window-titlebar .icon{margin-right:2px}.window-titlebar>span{flex:1}
.player-toolbar{display:flex;align-items:center;gap:6px;flex-wrap:wrap;padding:5px 6px;border-bottom:1px solid #aca899;font:11px/1.4 var(--font-ui)}.player-toolbar .player-fullscreen{margin-left:auto}.player-state{color:#333}
.player-stage{position:relative;display:flex;align-items:center;justify-content:center;min-width:0;width:100%;aspect-ratio:var(--game-ratio,4/3);max-height:72vh;background:#808080;border:2px solid;border-color:#716f64 #fff #fff #716f64;overflow:hidden}
.player-frame{border:0;width:100%;height:100%;display:block;background:#000}.player-overlay{max-width:480px;width:calc(100% - 32px);padding:24px 16px;text-align:center;border:1px solid;border-color:#fff #716f64 #716f64 #fff;background:#ece9d8;box-shadow:1px 1px 0 #3d3d3d}.player-overlay h2{font:700 22px/1.3 var(--font-ui);margin:0 0 12px}.player-overlay p{margin:0 auto 16px;max-width:40ch}.player-overlay .button-row{justify-content:center}.player-overlay>img{width:64px;height:64px;image-rendering:pixelated;object-fit:contain;margin-bottom:12px}
.player-info{display:grid;grid-template-columns:1fr 1fr;gap:16px;margin-top:16px}.player-info h2{font-size:17px;margin-bottom:8px}.player-info ul{padding-left:20px;margin:0}.player-info li{margin:4px 0}.player-info p{margin-bottom:8px}.player-info a{overflow-wrap:anywhere}
.player-window:fullscreen,.player-window.is-expanded{display:flex;flex-direction:column;width:100%;height:100%;max-width:none;border-radius:0;background:#808080}.player-window.is-expanded{position:fixed;inset:0;z-index:1000;width:100vw;height:100vh;height:100dvh}.player-window:fullscreen .player-stage,.player-window.is-expanded .player-stage{flex:1;min-height:0;max-height:none;aspect-ratio:auto}.player-window:fullscreen .player-frame,.player-window.is-expanded .player-frame{height:100%;max-width:100%}
.player-message{padding:8px 10px;margin:0;background:#ffffe1;border-top:1px solid #aca899;font:11px/1.4 var(--font-ui)}
.document-page{width:calc(100% - 24px);max-width:780px;margin:20px auto;padding:20px;border:1px solid #aca899;background:#fff}.document-page h1{margin-bottom:16px}.document-page h2{margin-top:20px;font-size:18px}
@media(max-width:1099px){.game-grid{grid-template-columns:repeat(3,minmax(0,1fr))}}
@media(max-width:749px){.game-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:14px 10px}.catalog-controls{gap:6px;padding:6px}.catalog-heading{padding-top:0}.notice{align-items:flex-start;flex-wrap:wrap}.notice>a{margin-left:24px}.catalog-controls select{min-height:36px}.view-controls .xp-button{min-width:40px}.player-stage{max-height:none;min-height:480px}.player-overlay{padding:16px 12px}.player-info{grid-template-columns:1fr}.player-toolbar .player-state{width:100%;order:4}.player-toolbar .xp-button{padding:4px 8px;min-width:0}.back-link{min-height:44px}.help-page summary{min-height:44px}.empty-state{padding:32px 12px}.is-list .game-card{grid-template-columns:64px minmax(0,1fr)}.is-list .game-image{width:64px}.is-list .card-bottom{grid-column:2;grid-row:auto;justify-content:flex-start;margin-top:8px}.status-strip{min-height:32px}}
