@import url('fonts.css');
:root{--paper:#f7f6f2;--white:#fff;--ink:#292b2b;--muted:#666963;--line:#dedfd9;--accent:#a5262c;--soft:#f6e9e8;color-scheme:light;font-family:'DM Sans',Arial,sans-serif;color:var(--ink);background:var(--paper)}
*{box-sizing:border-box}body{margin:0;font-size:14px;line-height:1.55}body[data-system=gb]{--accent:#713556;--soft:#f1e8ed}body[data-system=snes]{--accent:#5b468c;--soft:#eeeaf6}button,input,select{font:inherit}button,a,label{touch-action:manipulation}button{color:inherit;cursor:pointer;border:1px solid var(--line);background:transparent;min-height:42px;border-radius:5px;padding:8px 12px}button:hover:not(:disabled),.file-button:hover{background:var(--soft);border-color:var(--accent)}button:active:not(:disabled){transform:translateY(1px)}button:disabled{opacity:.4;cursor:not-allowed}a{color:var(--accent);text-underline-offset:4px}button:focus-visible,a:focus-visible,input:focus-visible,label:focus-within,summary:focus-visible{outline:3px solid var(--accent);outline-offset:3px}::selection{background:var(--accent);color:#fff}input{caret-color:var(--accent)}::-webkit-scrollbar{width:7px}::-webkit-scrollbar-thumb{background:#bfc0b9;border-radius:6px}svg{width:20px;height:20px;fill:none;stroke:currentColor;stroke-width:1.6;flex-shrink:0}h1,h2,h3,p{margin:0}h2{font-size:22px;letter-spacing:-.035em;line-height:1.25}h3{font-size:14px;margin-bottom:9px}p{color:var(--muted)}[hidden]{display:none!important}.skip{position:absolute;top:-100px;z-index:20;background:white;padding:12px}.skip:focus{top:0}
header{height:74px;display:flex;align-items:center;gap:28px;padding:0 28px;background:var(--white);border-bottom:1px solid var(--line)}.brand{display:flex;align-items:center;gap:11px;font-weight:700;font-size:20px;letter-spacing:-.04em;text-decoration:none;color:var(--ink);white-space:nowrap}.brand svg{width:35px;height:25px;color:var(--accent);stroke-width:2}nav{display:flex;align-self:stretch;gap:14px}nav button{border:0;border-radius:0;position:relative;padding:0 13px;white-space:nowrap;color:var(--muted)}nav button[aria-pressed=true]{color:var(--accent);font-weight:600}nav button[aria-pressed=true]:after{content:'';height:3px;background:var(--accent);position:absolute;bottom:0;left:8px;right:8px}.reference{margin-left:auto;color:var(--muted);font-size:12px;text-decoration:none}.quiet{border:0;font-size:12px}
main{display:grid;grid-template-columns:290px minmax(420px,1fr) 285px;max-width:1800px;margin:auto;min-height:calc(100dvh - 74px)}.library{border-right:1px solid var(--line);background:#fbfbf8;display:flex;flex-direction:column;height:calc(100dvh - 74px);position:sticky;top:0}.library-head{padding:25px 20px 0}.library-head>p{font-size:11px;margin:7px 0 19px}.search{display:flex;align-items:center;gap:8px;border:1px solid #cdcec7;border-radius:4px;padding:0 10px;background:white}.search svg{width:17px;color:var(--muted)}.search input{width:100%;min-width:0;height:42px;border:0;background:transparent;outline:none}.search input::placeholder{color:#73756f}.filters{display:flex;margin-top:16px;gap:3px;border-bottom:1px solid var(--line)}.filters button{font-size:12px;padding:10px 9px;border:0;border-bottom:2px solid transparent;border-radius:0;white-space:nowrap}.filters button[aria-pressed=true]{border-bottom-color:var(--accent);color:var(--accent)}.filters button:last-child{margin-left:auto}.filters svg{width:17px;height:17px;vertical-align:middle}.count{font-size:11px;padding:12px 0;margin:0!important}.game-list{overflow-y:auto;flex:1}.game-row{display:flex;position:relative;border-top:1px solid var(--line);background:transparent}.game-row.selected{background:var(--soft)}.game-select{border:0;border-radius:0;width:100%;display:flex;text-align:left;align-items:center;gap:13px;padding:15px 17px;min-height:104px}.game-text{min-width:0;flex:1}.game-text strong{font-size:13px;display:block;font-weight:600;line-height:1.35}.game-text small{font-size:11px;display:block;color:var(--muted);margin-top:5px}.game-text em{font-size:11px;display:block;font-style:normal;color:var(--accent);margin-top:3px}.cartridge{flex-shrink:0;width:44px;height:62px;border:1px solid #9b9e97;border-radius:3px 3px 1px 1px;background:linear-gradient(90deg,#b8bcb5 7%,#d3d5cf 8%,#d3d5cf 91%,#b3b6af 92%);box-shadow:1px 3px 4px #292b2b14;position:relative;padding:8px 5px 13px}.cartridge:after{content:'';position:absolute;bottom:5px;left:9px;right:9px;border-top:2px solid #a8aca4;border-bottom:2px solid #a8aca4;height:3px}.cartridge span{background:var(--cover,#a5262c);color:#fff;display:flex;align-items:center;text-align:center;height:37px;font:600 9px/1.15 'Barlow Condensed',sans-serif;overflow:hidden;word-break:normal;padding:3px;border:1px solid #fff9}.game-row .fav-marker{position:absolute;right:9px;top:8px;color:var(--accent);width:10px;height:10px}.game-list .empty{padding:24px 20px}.library-foot{font-size:11px;display:flex;align-items:center;gap:6px;padding:14px 14px;border-top:1px solid var(--line);background:var(--paper)}.library-foot a{margin-left:auto;font-size:11px}.led{display:inline-block;width:6px;height:6px;background:#607a51;border-radius:50%;flex-shrink:0}
.play-area{padding:20px 32px 30px;background:#fff;min-width:0}.screen-toolbar{display:flex;justify-content:space-between;align-items:center;gap:10px;font-size:11px;margin:0 0 30px}.screen-toolbar #status{display:flex;align-items:center;gap:7px;letter-spacing:.05em}.screen-toolbar i{height:6px;width:6px;border-radius:50%;background:#788b67}.screen-toolbar button{border:0;font-size:11px;min-height:36px;padding:5px 8px}.hardware{max-width:650px;margin:auto}.tv{background:linear-gradient(140deg,#c1c2b8,#edeee4 10%,#d7d9ce 72%,#b1b5a9);border:1px solid #8d9384;border-radius:24px 24px 14px 14px;padding:28px 29px 0;box-shadow:0 13px 17px -13px #34382b88,inset 2px 3px 2px #ffffffe0,inset -3px -5px 5px #626b5566;position:relative}.screen{position:relative;background:#191f20;border:10px solid #393e39;border-radius:26px 26px 30px 30px;box-shadow:0 0 0 3px #9b9e91,inset 0 3px 14px #000;aspect-ratio:4/3;overflow:hidden;isolation:isolate}.screen:after{content:'';position:absolute;inset:0;border-radius:18px;box-shadow:inset 0 0 24px #0006;pointer-events:none;z-index:3}#idle-screen{height:100%;display:flex;flex-direction:column;align-items:center;justify-content:center;text-align:center;padding:22px;color:#edf0de;background:radial-gradient(ellipse at center,#283b38,#172523);gap:10px}#idle-screen>p:first-of-type{font-size:8px;letter-spacing:.13em;color:#aebfb5}#idle-screen h1{font:600 clamp(22px,2.7vw,39px)/1.08 'Barlow Condensed',sans-serif;max-width:95%;text-wrap:balance}#screen-message{color:#bdc9be;font-size:11px;max-width:30ch}#screen-play{background:#d6ded1;color:#21392c;font-size:11px;border-color:#d6ded1;min-height:34px;padding:5px 19px;margin-top:6px}.screen-controller{width:58px;height:35px;color:#b4c5b4;margin-bottom:9px}.screen iframe{width:100%;height:100%;border:0;display:block;background:#000}.screen:fullscreen{width:100vw;height:100dvh;border:0;border-radius:0;aspect-ratio:auto}.tv-bottom{height:45px;display:flex;align-items:center;gap:20px}.tv-bottom>span:first-child{font:600 10px 'Barlow Condensed',sans-serif;letter-spacing:.08em;color:#343e2e}.speaker{margin-left:auto;width:52px;height:14px;background:repeating-linear-gradient(0deg,transparent 0 2px,#8b9385 2px 3px)}.tv-led{width:5px;height:5px;border-radius:50%;background:#a5262c;box-shadow:0 1px 1px #0004}.console{width:64%;margin:25px auto 0;box-shadow:0 10px 10px -10px #313528aa;border-radius:5px;border:1px solid #a2a79d;overflow:hidden}.console-top{background:linear-gradient(#e0e2da,#c8ccc3);height:62px;padding:13px 14px;display:flex;justify-content:space-between;color:#8f262b;font-size:11px;line-height:1.2}.console-top b{font-size:6px;font-weight:600;letter-spacing:.07em}.vent{width:25%;height:60px;margin:-13px -2px 0 0;background:repeating-linear-gradient(0deg,#b3b8ae 0 2px,#6e7668 2px 4px)}.console-bottom{height:25px;background:#a0a79b;display:flex;align-items:center;gap:4px;padding:0 10px;border-top:1px solid #a1a799}.console-power{height:3px;width:3px;background:#bd2b2f;margin-right:3px}.power-key{height:10px;width:17px;border:1px solid #7f8979;border-radius:1px;background:#bbc1b5}.cartridge-slot{height:4px;width:26%;margin-left:auto;margin-right:8px;background:#4a5444;border-bottom:1px solid #ced4c8}
.controller{position:relative;margin:34px auto 0;width:330px;max-width:100%;height:137px;background:linear-gradient(#d9dcd3,#bec3b8);border:1px solid #969f8d;border-radius:7px;box-shadow:inset 0 2px 1px #fff,0 10px 12px -12px #343b2e;display:flex;align-items:center;justify-content:space-between;padding:15px 17px;gap:12px;touch-action:none}.controller:before{content:'';position:absolute;inset:11px 8px;background:#343b37;border-radius:3px;z-index:0}.controller>*{position:relative;z-index:1}.controller button{touch-action:none;min-height:0;user-select:none;-webkit-user-select:none}.dpad{display:grid;grid-template-columns:25px 25px 25px;grid-template-rows:25px 25px 25px;filter:drop-shadow(1px 3px 1px #0005)}.dpad button,.dpad span{background:#1c231f;border:1px solid #899282;border-radius:2px;padding:0}.dpad button:nth-child(1){grid-column:2;grid-row:1;border-bottom:0}.dpad button:nth-child(2){grid-column:1;grid-row:2;border-right:0}.dpad span{grid-column:2;grid-row:2;border:0}.dpad button:nth-child(4){grid-column:3;grid-row:2;border-left:0}.dpad button:nth-child(5){grid-column:2;grid-row:3;border-top:0}.dpad button:hover{background:#5b6557!important}.controller button.pressed,.controller button:active{filter:brightness(1.6);transform:translateY(2px)}.middle-buttons{width:85px;align-self:stretch;display:flex;flex-direction:column;justify-content:space-between;padding:5px 0;color:#ffb3b6}.middle-buttons>span{font-size:13px;font-weight:700;letter-spacing:-.05em}.middle-buttons>div{display:flex;gap:8px;background:#a5aea1;border-radius:3px;padding:10px 5px 5px;margin-bottom:2px}.middle-buttons label{font-size:6px;letter-spacing:.03em;display:flex;flex-direction:column;gap:5px;align-items:center;color:#242f27}.middle-buttons button{width:27px;height:8px;padding:0;border:0;border-radius:6px;background:#303b31;box-shadow:0 2px 2px #0005}.action-buttons{display:flex;gap:9px;align-self:flex-end;margin-bottom:5px}.action-buttons label{display:flex;flex-direction:column;align-items:flex-end;gap:3px;font:600 9px Arial;color:#ffb3b6}.action-buttons button{width:35px;height:35px;border:2px solid #7b191f;background:#bf2a32;border-radius:50%;box-shadow:0 3px 2px #0005;padding:0;font-size:0}.action-buttons .extra,.shoulders{display:none}.keyboard-hint{font-size:11px;text-align:center;margin:23px auto 0;max-width:48ch;line-height:1.9}kbd{font:inherit;border:1px solid var(--line);border-radius:3px;padding:1px 4px} .local-note{font-size:11px;text-align:center;margin:10px auto 0;max-width:50ch}
.session{background:#fbfbf8;border-left:1px solid var(--line);padding:28px 23px}.selected-heading{display:flex;align-items:flex-start;gap:8px;margin-bottom:10px}.selected-heading h2{font-size:26px;flex:1}.selected-heading button{border:0;padding:2px;min-height:30px;flex-shrink:0}.selected-heading button[aria-pressed=true] svg{fill:var(--accent);color:var(--accent)}#selected-meta{font-size:11px} .description{font-size:12px;margin:21px 0 15px;line-height:1.75}.edition{font-size:11px;display:flex;align-items:center;gap:7px;margin:20px 0 12px}.primary{background:var(--accent);color:#fff;width:100%;border-color:var(--accent);font-weight:600}.primary:hover:not(:disabled){background:var(--accent);filter:brightness(.9);color:white}.file-button{border:1px solid var(--line);display:block;text-align:center;min-height:42px;border-radius:5px;padding:9px;cursor:pointer;margin:8px 0;font-size:12px}input[type=file]{position:absolute;width:1px;height:1px;overflow:hidden;opacity:0}.message{font-size:11px;margin:10px 0;min-height:17px;overflow-wrap:anywhere}.message.error{color:#9c222b}.save-section{padding:24px 0 22px;border-top:1px solid var(--line);margin-top:24px}.save-section p{font-size:11px;min-height:36px}.save-actions{display:flex;gap:8px;margin-top:13px}.save-actions button{font-size:11px;flex:1}.text-button{display:inline-block;border:0;padding:9px 0;font-size:11px;min-height:32px;color:var(--accent);text-decoration:underline;text-underline-offset:3px}.save-import{margin-left:13px;cursor:pointer}details{border-top:1px solid var(--line);padding:16px 0;font-size:11px}summary{cursor:pointer;font-weight:600;min-height:28px;display:flex;align-items:center;gap:8px}summary:before{content:'+';font-size:18px;color:var(--accent)}details[open] summary:before{content:'−'}details p{margin:10px 0;line-height:1.8}.source-link{display:block;font-size:11px;margin-top:17px}
body[data-system=gb] .hardware{max-width:350px}body[data-system=gb] .tv{padding:30px 25px 0;border-radius:15px 15px 55px 15px;background:linear-gradient(125deg,#deded0,#c3c4b6)}body[data-system=gb] .screen{aspect-ratio:10/9;border-width:15px;border-color:#777a83;border-radius:8px 8px 25px 8px}body[data-system=gb] #idle-screen{background:#879b54;color:#162c23}body[data-system=gb] #idle-screen p,body[data-system=gb] .screen-controller{color:#253c25}body[data-system=gb] #screen-play{background:#283e27;color:#d3deb0;border-color:#283e27}body[data-system=gb] .console{display:none}body[data-system=gb] .tv-bottom{height:62px}body[data-system=gb] .tv-bottom>span:first-child{font-style:italic;color:#343c67;font-size:17px}body[data-system=gb] .controller{margin-top:25px;border-radius:7px 7px 35px 7px}body[data-system=gb] .controller:before{background:transparent}body[data-system=gb] .middle-buttons>span{color:#344270}body[data-system=gb] .action-buttons button{background:#87304d;border-color:#61233c}body[data-system=gb] .action-buttons label{color:#344270}
body[data-system=snes] .controller{width:350px;height:150px;border-radius:75px;background:linear-gradient(#d9d9e3,#acacbc);padding:25px 26px}body[data-system=snes] .controller:before{inset:14px;border-radius:70px;background:#bbbcc9}body[data-system=snes] .middle-buttons{width:75px;justify-content:center;gap:20px}body[data-system=snes] .middle-buttons>span{color:#59477c;font-size:11px}body[data-system=snes] .middle-buttons>div{background:transparent;padding:0}body[data-system=snes] .middle-buttons label{color:#403852}body[data-system=snes] .action-buttons{display:grid;grid-template-columns:30px 30px;gap:5px;transform:rotate(-35deg);margin:10px 0;align-self:center}body[data-system=snes] .action-buttons .extra{display:block}body[data-system=snes] .action-buttons label{display:block}body[data-system=snes] .action-buttons label span{display:none}body[data-system=snes] .action-buttons button{width:30px;height:30px;font-size:11px;font-weight:600;color:white;transform:rotate(35deg);background:#6b5290;border-color:#53416e}body[data-system=snes] .action-buttons .extra button{background:#9382ad;border-color:#75658f}body[data-system=snes] .shoulders{display:flex;position:absolute;top:-4px;left:36px;right:36px;justify-content:space-between;z-index:0}body[data-system=snes] .shoulders button{height:19px;width:55px;background:#aaa9bc;color:#454053;padding:0;font-size:11px}body[data-system=snes] .console-top{color:#5b468c}body[data-system=snes] .console{border-radius:16px 16px 5px 5px;width:58%}body[data-system=snes] .vent{height:46px;background:repeating-linear-gradient(0deg,#aaaaba 0 2px,#797a8b 2px 4px)}
@media(min-width:1500px){main{grid-template-columns:310px 1fr 320px}.play-area{padding:25px 60px}.screen-toolbar{margin-bottom:40px}}@media(max-width:1120px){header{padding:0 18px;gap:18px}.reference{display:none}main{grid-template-columns:250px minmax(370px,1fr)}.session{grid-column:2;border-top:1px solid var(--line);border-left:0;display:grid;grid-template-columns:1fr 1fr;gap:0 24px}.session>.selected-heading,.session>#selected-meta,.session>.description,.session>.edition,.session>#message{grid-column:1/-1}.session .save-section{grid-column:1/-1}.session details{grid-column:1/-1}.library{grid-row:1/3}.play-area{padding:17px 24px 24px}.library-head{padding-left:15px;padding-right:15px}.game-select{padding:13px}.quiet{margin-left:auto}.selected-heading h2{font-size:24px}}@media(max-width:680px){header{height:auto;min-height:100px;flex-wrap:wrap;gap:0;padding:14px 18px 0}.brand{font-size:19px;flex:1}.brand svg{width:30px}.quiet{font-size:11px}nav{order:3;width:100%;height:46px;margin-top:8px;gap:12px}nav button{flex:1;padding:5px}.play-area{grid-row:1;grid-column:1;padding:13px 20px 28px}.screen-toolbar{margin-bottom:20px}main{display:grid;grid-template-columns:1fr}.library{grid-row:3;grid-column:1;position:static;height:auto;max-height:650px;border-top:1px solid var(--line);border-right:0}.session{grid-column:1;grid-row:2;padding:23px 22px}.tv{padding:20px 20px 0}.screen{border-width:8px}.tv-bottom{height:35px}.console{margin-top:19px}.console-top{height:50px;padding:10px}.vent{height:48px;margin-top:-10px}.controller{margin-top:27px;height:128px}.screen-toolbar #status{font-size:11px}.library-head{padding:23px 20px 0}.game-list{max-height:480px}.game-row{min-height:95px}.game-select{min-height:95px;padding:13px 20px}.game-text strong{font-size:14px}.game-text small,.game-text em{font-size:11px}.cartridge{width:42px;height:60px}.keyboard-hint{display:none}.local-note{margin-top:22px}.description{margin-top:10px}.session .primary,.session .file-button{margin-top:0}#idle-screen{padding:12px;gap:7px}#idle-screen h1{font-size:27px}.screen-controller{width:40px;height:25px;margin-bottom:3px}#idle-screen>p:first-of-type{font-size:6px}#screen-message{font-size:11px}#screen-play{min-height:30px}body[data-system=gb] .hardware{max-width:300px}body[data-system=gb] .tv{padding:24px 22px 0}body[data-system=snes] .controller{width:320px}.library-foot{font-size:11px}.library-foot a{font-size:11px}}
@media(prefers-reduced-motion:reduce){*{scroll-behavior:auto!important;transition:none!important}}

@media(max-width:360px){header .brand{font-size:16px;gap:8px}header .brand svg{width:26px}.quiet{padding:5px}}

.browse-mobile{display:none;font-size:11px;margin-right:6px}@media(max-width:680px){.browse-mobile{display:inline-block}}

/* Keep the molded controller, with thumb-sized controls rather than scale-model hit areas. */
.controller{width:380px;height:180px;padding:16px 10px;gap:8px;flex-shrink:0}
.controller button{min-width:44px;min-height:44px;-webkit-touch-callout:none}
.controller .dpad{grid-template-columns:repeat(3,44px);grid-template-rows:repeat(3,44px);flex-shrink:0;touch-action:none}
.controller .middle-buttons{width:56px;flex-shrink:0;padding:0;justify-content:center;gap:4px}
.controller .middle-buttons>span{font-size:10px;text-align:center}
.controller .middle-buttons>div{flex-direction:column;gap:2px;background:transparent;padding:0;margin:0}
.controller .middle-buttons label{font-size:10px;gap:0;color:#edf0de}
.controller .middle-buttons button{width:44px;height:44px;border-radius:7px;background:#a5aea1;box-shadow:none;position:relative}
.controller .middle-buttons button:after{content:'';position:absolute;inset:18px 8px;border-radius:5px;background:#303b31;box-shadow:0 2px 2px #0005}
.controller .action-buttons{gap:8px;align-self:center;margin:0;flex-shrink:0}
.controller .action-buttons label{font-size:11px;align-items:center}
.controller .action-buttons button{width:48px;height:48px;background:#bf2a32}
body[data-system=gb] .controller{height:180px}
body[data-system=gb] .middle-buttons label{color:#242f27}
body[data-system=gb] .action-buttons button{background:#87304d}
body[data-system=snes] .controller{width:420px;height:200px;min-height:200px;padding:48px 8px 8px;border-radius:42px;gap:6px}
body[data-system=snes] .controller:before{inset:8px;border-radius:34px}
body[data-system=snes] .controller .middle-buttons{width:44px;gap:0}
body[data-system=snes] .middle-buttons>span{font-size:8px}
body[data-system=snes] .middle-buttons button{background:transparent;transform:none}
body[data-system=snes] .middle-buttons button:after{transform:rotate(-15deg)}
body[data-system=snes] .middle-buttons label{font-size:10px}
body[data-system=snes] .controller .action-buttons{display:grid;grid-template-columns:repeat(3,44px);grid-template-rows:repeat(3,44px);gap:0;transform:none;width:132px;height:132px;margin:0}
body[data-system=snes] .action-buttons label:nth-child(1){grid-column:1;grid-row:2}
body[data-system=snes] .action-buttons label:nth-child(2){grid-column:2;grid-row:1}
body[data-system=snes] .action-buttons label:nth-child(3){grid-column:2;grid-row:3}
body[data-system=snes] .action-buttons label:nth-child(4){grid-column:3;grid-row:2}
body[data-system=snes] .controller .action-buttons button{width:44px;height:44px;transform:none;font-size:12px;background:#6b5290}
body[data-system=snes] .controller .action-buttons .extra button{background:#9382ad}
body[data-system=snes] .controller .shoulders{z-index:2;top:1px;left:22px;right:22px}
body[data-system=snes] .controller .shoulders button{width:64px;height:44px;border-radius:18px 18px 5px 5px}
.screen:focus-visible{outline:3px solid var(--accent);outline-offset:4px}
.screen-toolbar button,.screen-toolbar .browse-mobile{min-height:44px;display:inline-flex;align-items:center}
.screen-toolbar .browse-mobile{display:none}
.screen-toolbar>div{display:flex;align-items:center;gap:4px}
body.playing .console{display:none}
body.playing .screen-toolbar{margin-bottom:12px}
body.playing .controller{margin-top:16px}
body.playing .tv{padding:14px 16px 0}
body.playing .tv-bottom{height:28px}
body.playing .keyboard-hint{margin-top:10px}
body.playing .local-note{display:none}

body.play-expanded{overflow:hidden}
.play-area.expanded{position:fixed;inset:0;z-index:100;width:100%;height:100dvh;max-width:none;overflow:hidden}
.play-area.play-focused{display:grid;grid-template-columns:minmax(0,1fr);grid-template-rows:44px minmax(0,1fr) auto;gap:12px;padding:max(8px,env(safe-area-inset-top)) max(12px,env(safe-area-inset-right)) max(8px,env(safe-area-inset-bottom)) max(12px,env(safe-area-inset-left));background:var(--paper);min-height:0}
.play-focused .screen-toolbar{grid-column:1/-1;grid-row:1;margin:0}
.play-area.play-focused .hardware{grid-row:2;width:100%;height:100%;min-height:0;max-width:none;margin:0}
.play-area.play-focused .tv{width:100%;height:100%;padding:0!important;border:0;border-radius:8px;background:#111;box-shadow:none}
.play-focused .screen{width:100%;height:100%;aspect-ratio:auto!important;border:0!important;border-radius:8px!important;box-shadow:none}
.play-focused .tv-bottom,.play-focused .console,.play-focused .keyboard-hint,.play-focused .local-note,.play-focused .browse-mobile{display:none!important}
.play-area.play-focused .controller{grid-row:3;margin:0 auto}
.play-focused .screen:after{display:none}
@media(min-width:681px){
  .play-area.play-focused{grid-template-columns:minmax(0,1fr) minmax(310px,380px);grid-template-rows:44px minmax(0,1fr)}
  .play-area.play-focused .hardware{grid-column:1;grid-row:2}
  .play-area.play-focused .controller{grid-column:2;grid-row:2;align-self:center;width:100%;max-width:380px}
}
@media(max-height:760px) and (min-width:681px),(max-height:600px) and (orientation:landscape){
  body.compact-play header{height:54px;min-height:54px;flex-wrap:nowrap;padding:0 12px;gap:8px}
  body.compact-play .brand{font-size:14px;flex:0 0 auto}
  body.compact-play .brand svg{width:24px}
  body.compact-play nav{order:0;width:auto;height:54px;margin:0;gap:0;flex:1}
  body.compact-play nav button{padding:0 8px}
  body.compact-play .reference{display:none}
  body.compact-play main{grid-template-columns:minmax(0,1fr)}
  body.compact-play .play-area{grid-column:1;grid-row:1;height:calc(100dvh - 54px);grid-template-columns:minmax(0,1fr) minmax(310px,360px);grid-template-rows:44px minmax(0,1fr);gap:8px}
  body.compact-play .play-area.expanded{height:100dvh}
  body.compact-play .play-area .hardware{grid-column:1;grid-row:2}
  body.compact-play .play-area .controller{grid-column:2;grid-row:2;align-self:center;width:100%;margin:0}
  body.compact-play[data-system=snes] .play-area .controller{height:192px;min-height:192px}
  body.compact-play .session{grid-column:1;grid-row:2}
  body.compact-play .library{grid-column:1;grid-row:3;position:static;height:600px;border-top:1px solid var(--line)}
  body.compact-play .play-area:not(.expanded) .browse-mobile{display:inline-flex!important}
}
@media(max-width:680px){
  .controller{margin-top:18px;max-width:100%}
  body[data-system=snes] .controller{width:100%;padding-left:4px;padding-right:4px;gap:4px}
  .screen-toolbar .browse-mobile{display:inline-flex}
  .play-area{padding-left:12px;padding-right:12px}
  body.playing .tv{padding:12px 12px 0}
}
@media(max-width:360px){
  body.playing header{height:54px;min-height:54px;padding-top:0}
  body.playing header .brand,body.playing header .quiet{display:none}
  body.playing header nav{height:44px;margin-top:0}
  .controller,body[data-system=gb] .controller{display:grid;grid-template-columns:132px 104px;justify-content:space-around;height:auto;gap:8px 0}
  .controller .middle-buttons{grid-row:2;grid-column:1/-1;width:100%;flex-direction:row;align-items:center;gap:12px}
  .controller .middle-buttons>div{flex-direction:row;gap:12px}
  .controller .middle-buttons>span{display:none}
  .controller .action-buttons{grid-column:2;grid-row:1}
  body[data-system=snes] .controller{display:grid;grid-template-columns:132px 132px;justify-content:space-around;padding-top:48px;height:auto;gap:8px 0}
  body[data-system=snes] .controller .middle-buttons{grid-row:2;grid-column:1/-1;width:100%;flex-direction:row;align-items:center;gap:12px}
  body[data-system=snes] .middle-buttons>div{flex-direction:row;gap:12px}
  body[data-system=snes] .middle-buttons>span{display:none}
  body[data-system=snes] .controller .action-buttons{grid-column:2;grid-row:1}
}
