/* Dense, native-like GameDex hierarchy and completion controls. */
#gamedexControls{padding:0 14px 3px}
#gamedexControls[hidden]{display:none}
.gamedex-tabs{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:3px;padding:4px;background:#0f1225;border:1px solid #292d4a}
.gamedex-tabs button{cursor:pointer;color:#9095ba;background:transparent;font-family:inherit;font-weight:700;font-size:10px;line-height:1.2;min-height:39px;border:1px solid transparent;padding:7px 2px}
.gamedex-tabs button.active{color:#f8eeff;border-color:#984dff;box-shadow:inset 0 0 12px #7126d12b,0 0 8px #7638f440;background:#261440}
.gamedex-progress{padding:11px 0}
.dex-head{display:grid;gap:5px;color:#adb0cf;font-size:11px}
.dex-head strong{display:block;font-size:16px;line-height:1.25;color:#f6f1ff}
.dex-head>span{font-size:10px}
.dex-meter{height:5px;background:#1b2040;overflow:hidden;margin:4px 0}
.dex-meter i{display:block;height:100%;background:linear-gradient(90deg,#aa4cff,#55cfff)}
.dex-account{display:flex;align-items:center;justify-content:space-between;gap:8px;margin-top:7px;color:#a7a6c5;font-size:10px}
.dex-account button,#dexReturn{border:1px solid #4c3f78;background:#1a1731;color:#d9c5ff;padding:9px 10px;cursor:pointer;font-weight:700;font-size:10px}
.dex-account button:first-child:last-child{width:100%;text-align:center}
.dex-connected{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.gamedex-return{display:block;width:100%;text-align:left;margin:7px 0}
.gamedex-return[hidden],.gamedex-related[hidden]{display:none}
.gamedex-related{margin:6px 0 12px}
.gamedex-related>b{color:#a69bd0;font-size:9px;letter-spacing:.12em}
.dex-related-list{display:flex;overflow:auto;gap:7px;margin-top:8px;padding-bottom:4px}
.dex-related-list button{flex:0 0 auto;max-width:220px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;background:#171b35;border:1px solid #413768;color:#e1cfff;font-size:11px;padding:9px;cursor:pointer}
.dex-owned .collection-count b{color:#68e8b5}
.dex-wish .collection-count b{color:#debdff}
.dex-missing .collection-count b{color:#5c648a}
.dex-game-card .collection-symbol{border-radius:2px}
.dex-game-card .collection-symbol img{width:100%;height:100%;object-fit:cover}
.dex-group-card .collection-symbol{border-radius:3px}
.dex-login-overlay{position:fixed;inset:0;z-index:1050;display:flex;align-items:center;justify-content:center;padding:20px;background:#030311e8}
.dex-login-overlay[hidden]{display:none}
.dex-login-panel{display:grid;gap:14px;width:100%;max-width:380px;background:#0e1025;border:1px solid #8535ee;padding:20px;box-shadow:0 0 32px #5b22af35}
.dex-login-heading{display:flex;justify-content:space-between;align-items:center;gap:12px;font-size:20px}
.dex-login-heading button{background:none;color:#fff;border:0;font-size:25px}
.dex-login-panel p{color:#aeb1ce;font-size:12px;line-height:1.5}
.dex-login-panel label,.dex-own-controls label{display:grid;gap:6px;color:#a8a9ce;font-size:11px;font-weight:600}
.dex-login-panel input,.dex-own-controls select{width:100%;min-height:43px;padding:9px 11px;border:1px solid #413967;background:#14162c;color:#fafafa;font-size:13px;border-radius:0}
.dex-login-submit{border:1px solid #ad5df6;background:#54219a;color:white;font-weight:700;min-height:43px;padding:10px;cursor:pointer}
#dexSignInError{color:#ff9da7;font-size:11px}
.dex-own-controls{display:grid;grid-template-columns:1fr 1fr;gap:10px;margin:20px 0 14px}
.dex-own-buttons{display:flex;grid-column:1/-1;gap:6px}
.dex-own-buttons button{flex:1;min-height:43px;background:#191934;border:1px solid #6b4d93;color:#e5d7ff;font-size:11px;font-weight:700;cursor:pointer;padding:5px}
.dex-own-note{grid-column:1/-1;font-size:10px;color:#8d93ae;line-height:1.5}
.dex-cover{max-width:100%;max-height:100%;object-fit:cover}
@media(min-width:700px){#gamedexControls{padding:0 28px}.gamedex-tabs button{font-size:12px}}
@media(max-width:370px){.gamedex-tabs button{font-size:9px}.dex-own-buttons button{font-size:10px}}

.dex-memberships{margin:14px 0;padding:11px 0;border-top:1px solid #292d4b;border-bottom:1px solid #292d4b}
.dex-memberships>b,.dex-source-facts>b{color:#a48cff;font-size:9px;letter-spacing:.12em}
.dex-membership-links{display:flex;flex-wrap:wrap;gap:7px;margin-top:9px}
.dex-membership-links button{border:1px solid #45336f;background:#181632;color:#e3ceff;font-size:10px;padding:8px 9px;cursor:pointer}
.dex-source-meta{margin-top:14px;font-size:11px;color:#bbc0df}
.dex-source-facts{display:grid;gap:8px}
.dex-source-facts p{margin:0;line-height:1.5;font-size:11px}
.dex-source-facts p strong{color:#d3c9f1}
.dex-releases-head{display:flex;justify-content:space-between;align-items:start;gap:8px;margin-top:8px;color:#ebe1ff}
.dex-releases-head span{color:#828aaa;font-size:9px}
.dex-release-list{display:grid;gap:0;max-height:400px;overflow:auto;border-top:1px solid #27294a}
.dex-release-line{display:grid;grid-template-columns:minmax(0,1fr) 82px;gap:3px 7px;border-bottom:1px solid #242844;padding:7px 2px;font-size:10px}
.dex-release-line b{font-weight:600;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.dex-release-line span{text-align:right;color:#c4b8f5}
.dex-release-line small{grid-column:1/-1;color:#7e89aa}
.dex-provenance{font-size:9px;color:#8f99b8;line-height:1.5}
.dex-provenance a{color:#c0a4ff;text-decoration:underline}

.dex-own-controls input,.dex-own-controls textarea{background:#14162c;color:#fafafa;border:1px solid #413967;min-height:40px;padding:9px;font:inherit;width:100%;border-radius:0}
.dex-own-notes{grid-column:1/-1}
.dex-own-notes textarea{min-height:60px;resize:vertical}
