:root{color-scheme:dark;--bg:#080d19;--panel:#111a2b;--panel2:#162238;--line:#26344d;--text:#eef4ff;--muted:#91a2bd;--cyan:#56e6d2;--blue:#739bff;--red:#ff6d83;--radius:18px;font-family:Inter,ui-sans-serif,system-ui,-apple-system,"Segoe UI",sans-serif}*{box-sizing:border-box}body{margin:0;background:radial-gradient(ellipse at 75% -10%,#18345a 0,transparent 38%),var(--bg);color:var(--text);min-height:100vh}button,input,textarea,select{font:inherit}button{border:0;cursor:pointer;transition:.18s transform,.18s opacity,.18s background}button:hover{transform:translateY(-1px)}button:disabled{opacity:.45;cursor:not-allowed;transform:none}.topbar{position:sticky;top:0;z-index:20;display:flex;align-items:center;justify-content:space-between;gap:22px;padding:14px clamp(16px,4vw,54px);background:#0b1220eF;border-bottom:1px solid #26334b;backdrop-filter:blur(16px)}.brand{display:flex;align-items:center;gap:11px;color:var(--text);text-decoration:none;min-width:190px}.brand-mark{width:42px;height:42px;border-radius:13px;display:grid;place-items:center;font-weight:900;color:#07131e;background:linear-gradient(135deg,var(--cyan),var(--blue));box-shadow:0 8px 30px #56e6d233}.brand b{display:block;letter-spacing:.08em;font-size:13px}.brand small{display:block;color:var(--muted);font-size:10px;margin-top:3px}.main-nav{display:flex;gap:6px;flex-wrap:wrap;justify-content:center}.nav-btn,.admin-tab{background:transparent;color:var(--muted);padding:10px 13px;border-radius:11px;font-weight:700;font-size:13px}.nav-btn.active,.admin-tab.active{background:#20334e;color:var(--cyan)}.auth-area{min-width:175px;text-align:right}.primary,.secondary,.danger{border-radius:11px;padding:11px 16px;font-weight:800}.primary{background:linear-gradient(135deg,var(--cyan),#80b8ff);color:#07131e}.secondary{background:#23334d;color:#e8f0ff;border:1px solid #344763}.danger{background:#642a3b;color:#ffeaf0;border:1px solid #8b3d51}.link-button{text-decoration:none;display:inline-flex;align-items:center}.page-shell{max-width:1250px;margin:auto;padding:32px 24px 70px}.hero{min-height:260px;border:1px solid #263e5e;border-radius:28px;background:linear-gradient(110deg,#152b48,#111b30 62%,#1b3652);padding:36px 44px;display:flex;align-items:center;justify-content:space-between;overflow:hidden;position:relative}.hero:after{content:"";position:absolute;width:340px;height:340px;border-radius:50%;right:5%;top:-130px;background:#61e6d21a;filter:blur(2px)}.hero h1{font-size:clamp(34px,5vw,56px);line-height:1.03;margin:12px 0}.hero h1 span{color:var(--cyan)}.hero p{color:#b0bfd4;max-width:500px}.eyebrow{font-size:10px;letter-spacing:.18em;font-weight:900;color:var(--cyan)}.hero-orb{font-size:100px;z-index:1;filter:drop-shadow(0 18px 30px #0008);padding-right:6%}.section-head{display:flex;align-items:end;justify-content:space-between;gap:20px;margin:38px 0 18px}.section-head h2,.section-head h3{margin:5px 0 0}.section-head h2{font-size:27px}.section-head.compact{margin:0 0 14px}.search-input,.stack-form input,.stack-form textarea,.stack-form select,.comment-form input,.comment-form textarea,.chat-form input{background:#0b1424;border:1px solid var(--line);color:var(--text);padding:12px 14px;border-radius:11px;outline:none;width:100%}.search-input{width:min(280px,45vw)}input:focus,textarea:focus,select:focus,.rich-editor:focus{border-color:var(--cyan);box-shadow:0 0 0 3px #56e6d21a}.content-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(235px,1fr));gap:17px}.content-card{background:linear-gradient(160deg,#17243a,#101a2a);border:1px solid var(--line);border-radius:18px;padding:18px;min-height:190px;display:flex;flex-direction:column;gap:10px;box-shadow:0 10px 35px #0002}.content-card h3{margin:0;font-size:18px}.content-card p{color:var(--muted);font-size:13px;line-height:1.5;margin:0;white-space:pre-wrap}.card-icon{width:42px;height:42px;border-radius:13px;display:grid;place-items:center;background:#263a56;font-size:22px}.card-meta{color:#8295b4;font-size:11px}.content-card .card-action{margin-top:auto;align-self:flex-start}.post-card{grid-column:span 1}.post-body{font-size:14px;line-height:1.65;color:#d6e0f0;overflow-wrap:anywhere}.post-images{display:grid;grid-template-columns:repeat(2,1fr);gap:8px}.post-images img{width:100%;height:130px;object-fit:cover;border-radius:10px}.center-row{text-align:center;margin:24px}.hidden{display:none!important}.empty-state{grid-column:1/-1;text-align:center;color:var(--muted);padding:40px;border:1px dashed var(--line);border-radius:16px}.player-panel{margin-top:35px;background:#101a2b;border:1px solid var(--line);border-radius:20px;padding:18px}.player-heading{display:flex;align-items:center;justify-content:space-between;gap:14px;margin-bottom:15px}.player-heading h2{margin:5px 0}.player-actions{display:flex;gap:8px}.game-stage{background:#000;border-radius:13px;overflow:hidden;min-height:400px}.game-stage iframe{width:100%;height:min(78vh,760px);display:block;border:0;background:#fff}.game-stage:fullscreen{width:100vw;height:100vh;border-radius:0}.game-stage:fullscreen iframe{height:100vh}.comments-panel{padding-top:22px}.comment-list{display:grid;gap:10px;margin-bottom:14px}.comment-item{background:#162238;border:1px solid #293951;border-radius:12px;padding:12px 14px}.comment-item p{margin:7px 0 0;white-space:pre-wrap;overflow-wrap:anywhere}.comment-meta{display:flex;justify-content:space-between;color:var(--muted);font-size:11px}.comment-form{display:grid;grid-template-columns:220px 1fr auto;gap:9px}.comment-form textarea{min-height:44px;resize:vertical}.chat-widget{position:fixed;right:20px;top:90px;width:320px;z-index:30;background:#111c2e;border:1px solid #354660;border-radius:16px;box-shadow:0 20px 60px #0008;overflow:hidden}.chat-toggle{width:100%;display:flex;justify-content:space-between;padding:13px 15px;background:#1a2b44;color:var(--text);font-weight:800}.chat-body{padding:11px}.chat-note{font-size:10px;color:#90a1ba;margin-bottom:8px}.chat-messages{height:270px;overflow:auto;display:flex;flex-direction:column;gap:8px;padding:3px}.chat-message{background:#1b2a41;border-radius:10px;padding:8px 10px;font-size:12px;overflow-wrap:anywhere}.chat-message .who{font-weight:800;color:var(--cyan);display:flex;justify-content:space-between;gap:6px}.chat-message p{margin:5px 0 0;white-space:pre-wrap}.chat-message small{color:#8192ac;font-size:9px}.chat-form{display:flex;gap:6px;margin-top:9px}.chat-form input{min-width:0;padding:10px;font-size:12px}.chat-form button{padding:9px 12px}.admin1-tools{margin-top:9px}.tiny{padding:5px 8px;font-size:10px}.chat-widget.collapsed .chat-body{display:none}.chat-widget.collapsed{width:210px}.chat-widget.chat-hidden{display:none}.modal-backdrop{position:fixed;inset:0;z-index:60;background:#030711c9;display:grid;place-items:center;padding:18px}.modal-card{position:relative;background:#142139;border:1px solid #3a4c68;border-radius:20px;padding:25px;width:min(520px,100%);max-height:90vh;overflow:auto;box-shadow:0 30px 90px #000b}.modal-close{position:absolute;right:12px;top:8px;background:transparent;color:#b9c9df;font-size:28px}.profile-row{display:flex;align-items:center;gap:15px}.avatar{width:58px;height:58px;border-radius:50%;object-fit:cover;background:#2a3c58}.stack-form{display:grid;gap:12px;margin-top:16px}.stack-form label{display:grid;gap:7px;color:#b6c6dc;font-size:13px}.stack-form textarea{resize:vertical}.site-footer{text-align:center;color:#61738e;font-size:11px;padding:25px}.toast{position:fixed;left:50%;bottom:22px;transform:translate(-50%,20px);opacity:0;pointer-events:none;z-index:100;background:#1c304a;border:1px solid #48617f;color:#f2f7ff;padding:11px 16px;border-radius:12px;box-shadow:0 12px 35px #0007;transition:.2s}.toast.show{opacity:1;transform:translate(-50%,0)}.muted{color:var(--muted)}.error-text{color:#ff8a9d}.admin-shell{max-width:1100px;margin:35px auto;padding:0 20px 70px}.login-card{max-width:440px;margin:60px auto;background:var(--panel);border:1px solid var(--line);border-radius:22px;padding:30px}.login-card h1{margin:9px 0}.admin-title{display:flex;justify-content:space-between;align-items:center;gap:20px;margin-bottom:25px}.admin-title h1{margin:5px 0}.admin-title p{color:var(--muted)}.admin-tabs{display:flex;gap:5px;flex-wrap:wrap;border-bottom:1px solid var(--line);padding-bottom:12px}.admin-section{margin-top:22px;background:var(--panel);border:1px solid var(--line);border-radius:18px;padding:23px}.admin-section h2{margin:0 0 17px}.form-grid{display:grid;grid-template-columns:1fr 1fr;gap:12px}.editor-toolbar{display:flex;gap:6px}.editor-toolbar button{background:#263a56;color:#fff;padding:8px 12px;border-radius:7px}.rich-editor{min-height:180px;padding:14px;background:#0b1424;border:1px solid var(--line);border-radius:12px;outline:none;line-height:1.6}.rich-editor:empty:before{content:attr(data-placeholder);color:#687b98}.file-drop{display:block!important;border:1px dashed #4b6688;border-radius:12px;padding:17px!important;background:#101d31}.file-drop input{border:0;padding:6px 0;background:transparent}.file-list{color:var(--muted);font-size:12px}.progress-wrap{display:flex;align-items:center;gap:10px}.progress-track{height:9px;background:#27364d;border-radius:20px;overflow:hidden;flex:1}.progress-track div{height:100%;width:0;background:linear-gradient(90deg,var(--cyan),var(--blue))}.manage-list{display:grid;gap:10px}.manage-row{display:flex;justify-content:space-between;align-items:center;gap:14px;padding:13px;background:#17243a;border:1px solid #2c3d57;border-radius:12px}.manage-row p{margin:4px 0 0;color:var(--muted);font-size:12px}.manage-actions{display:flex;gap:6px;flex-wrap:wrap}.manage-actions button{font-size:11px;padding:8px 10px}.version-list{display:grid;gap:8px;margin-top:12px}.version-row{display:flex;justify-content:space-between;align-items:center;background:#0d1728;padding:10px;border-radius:10px}.admin-page .topbar{position:static}
@media(max-width:900px){.topbar{flex-wrap:wrap}.main-nav{order:3;width:100%;justify-content:flex-start;overflow:auto}.auth-area{margin-left:auto}.chat-widget{top:auto;bottom:12px;right:12px;width:min(320px,calc(100vw - 24px))}.chat-messages{height:190px}.hero{padding:28px}.comment-form{grid-template-columns:1fr}.section-head{align-items:start;flex-direction:column}.search-input{width:100%}}
@media(max-width:560px){.page-shell{padding:18px 13px 55px}.topbar{padding:12px}.brand{min-width:0}.brand b{font-size:11px}.auth-area{min-width:0}.auth-area button{font-size:11px;padding:9px}.nav-btn{font-size:11px;padding:9px}.hero{min-height:220px;padding:22px}.hero-orb{font-size:60px;padding:0}.hero p{font-size:13px}.player-heading,.admin-title{align-items:flex-start;flex-direction:column}.player-actions{width:100%}.player-actions button{flex:1}.game-stage iframe{height:65vh}.form-grid{grid-template-columns:1fr}.admin-section{padding:15px}.manage-row{align-items:flex-start;flex-direction:column}.login-card{margin:25px auto;padding:22px}}
.post-author{display:flex;align-items:center;justify-content:space-between;gap:8px}.author-profile{display:flex;align-items:center;gap:8px;background:transparent;color:var(--text);padding:0;font-weight:700}.author-profile .avatar{width:30px;height:30px}.mini-avatar{width:22px;height:22px;object-fit:cover;border-radius:50%;vertical-align:middle;margin-right:6px}.profile-chip{display:inline-flex;align-items:center;gap:5px;padding:8px 10px;margin-right:6px}
.file-drop.dragging{border-color:var(--cyan);background:#18364a}.file-drop{transition:.15s border-color,.15s background}audio,video{width:100%;max-width:100%;border-radius:10px;margin-top:8px}video{background:#000;min-height:130px}

/* Minh Du Game identity refresh: Cyber Shield / Energy Core */
:root{--bg:#071426;--panel:#0d1d33;--panel2:#122947;--line:#203d60;--text:#edf8ff;--muted:#91acc9;--cyan:#00cfff;--blue:#087bff;--red:#ff647e}
body{background:radial-gradient(ellipse at 78% -12%,#0d3c70 0,transparent 38%),radial-gradient(ellipse at 0% 70%,#071d36 0,transparent 35%),var(--bg)}
.topbar{background:#071426ed;border-color:#17385c}.brand-mark{background:linear-gradient(145deg,#0b2c55,#071426);border:1px solid #00cfff;box-shadow:0 0 20px #00cfff35,inset 0 0 18px #087bff30;color:#8beaff}.brand-mark svg{width:100%;height:100%;padding:2px}.nav-btn.active,.admin-tab.active{background:linear-gradient(135deg,#0d3158,#102744);color:#8beaff;box-shadow:inset 0 0 0 1px #087bff55}.nav-symbol{display:inline-grid;place-items:center;width:19px;height:19px;margin-right:4px;border-radius:6px;background:#0d3761;color:#8beaff;font-weight:900}.primary{background:linear-gradient(135deg,#087bff,#00cfff);color:#031326;box-shadow:0 7px 22px #087bff25}.hero{background:linear-gradient(115deg,#0b2c55,#0b1c32 62%,#0a3154);border-color:#1763a0;box-shadow:inset 0 0 45px #087bff12}.hero h1 span{color:#00cfff}.hero-orb{width:150px;height:150px;padding:0;display:grid;place-items:center}.hero-orb svg{width:100%;filter:drop-shadow(0 0 25px #00cfff55)}
.social-dock{position:fixed;z-index:32;right:20px;top:50%;transform:translateY(-50%);display:grid;gap:8px;padding:9px;background:#091a2ddd;border:1px solid #1b5682;border-radius:18px;box-shadow:0 15px 45px #0008;backdrop-filter:blur(14px)}.social-dock button{position:relative;width:42px;height:42px;border-radius:12px;background:#102c4b;color:#8beaff;font-size:20px;font-weight:800}.social-dock button:hover{background:#0b4a7d;box-shadow:0 0 18px #00cfff40}.notification-count{position:absolute;right:-5px;top:-5px;min-width:18px;height:18px;padding:0 4px;border-radius:20px;background:#ff476b;color:white;font-size:10px;display:grid;place-items:center;border:2px solid #071426}
.ext-panel{position:fixed;z-index:70;inset:0;background:#020914d9;display:grid;place-items:center;padding:16px}.ext-card{width:min(760px,100%);max-height:90vh;overflow:auto;background:linear-gradient(155deg,#102744,#09182b);border:1px solid #1763a0;border-radius:22px;padding:22px;box-shadow:0 30px 100px #000b}.ext-head{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:15px}.ext-head h2{margin:0;color:#e9f8ff}.ext-close{background:#17395c;color:#bfefff;border-radius:10px;width:36px;height:36px;font-size:22px}.ext-tabs{display:flex;flex-wrap:wrap;gap:7px;margin:10px 0 17px}.ext-tabs button{background:#102b49;border:1px solid #1d4a70;color:#b7d7ee;border-radius:10px;padding:8px 11px}.ext-tabs button.active{background:#07549b;color:white;border-color:#00cfff}.ext-list{display:grid;gap:9px}.ext-item{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:12px;background:#0b1d32;border:1px solid #1b3e60;border-radius:13px}.ext-item p{margin:4px 0 0;color:#9bb4cf;font-size:12px;white-space:pre-wrap;overflow-wrap:anywhere}.ext-item .manage-actions{flex-shrink:0}.ext-form{display:grid;gap:10px;margin:12px 0}.ext-form input,.ext-form textarea,.ext-form select{width:100%;padding:11px 13px;background:#07182a;border:1px solid #234666;border-radius:10px;color:#eff9ff}.ext-form textarea{min-height:90px;resize:vertical}.ext-muted{font-size:12px;color:#91acc9}.ext-chat-log{height:300px;overflow:auto;display:flex;flex-direction:column;gap:8px;padding:10px;background:#061426;border:1px solid #1c3d5c;border-radius:12px}.ext-message{background:#102844;padding:9px 11px;border-radius:10px;max-width:90%;align-self:flex-start;overflow-wrap:anywhere}.ext-message.mine{align-self:flex-end;background:#064a7b}.ext-message small{display:block;color:#8eabc6;font-size:10px;margin-bottom:3px}.ext-stars{color:#ffd66b;letter-spacing:2px}.review-summary{color:#b7d7ee;margin-bottom:10px}.user-post-compose{margin:28px 0;padding:20px;border:1px solid #1a5683;border-radius:18px;background:linear-gradient(140deg,#0c2541,#0a1a2e)}.user-post-compose .rich-editor{min-height:110px}.game-review-item{padding:11px 13px;margin:8px 0;background:#0b1d32;border:1px solid #1b3e60;border-radius:12px}.game-review-item p{white-space:pre-wrap;margin:6px 0 0}.favorite-button{margin-top:8px}.admin-tabs{gap:7px}.admin-tab{border:1px solid transparent}.admin-tab.active{border-color:#1267a5}
@media(max-width:900px){.social-dock{top:auto;bottom:12px;right:12px;transform:none;display:flex;gap:5px;padding:6px;border-radius:15px}.social-dock button{width:39px;height:39px}.chat-widget{bottom:65px}.ext-card{max-height:86vh}}
@media(max-width:560px){.brand-mark{width:38px;height:38px}.hero-orb{width:85px;height:85px}.social-dock{left:50%;right:auto;transform:translateX(-50%);bottom:8px}.social-dock button{width:36px;height:36px;font-size:17px}.chat-widget{bottom:58px}.ext-panel{padding:7px}.ext-card{padding:15px;border-radius:16px;max-height:90vh}.ext-item{align-items:flex-start;flex-direction:column}.ext-item .manage-actions{width:100%}.user-post-compose{padding:14px}.game-review-panel .comment-form{grid-template-columns:1fr}}
.global-search-results{position:absolute;top:calc(100% + 8px);right:0;z-index:45;width:min(420px,90vw);max-height:55vh;overflow:auto;padding:8px;background:#091b30;border:1px solid #1763a0;border-radius:13px;box-shadow:0 18px 50px #000a}.global-search-row{display:flex;width:100%;gap:10px;align-items:center;text-align:left;padding:10px;border-radius:9px;background:transparent;color:#eaf8ff}.global-search-row:hover{background:#12385a}.global-search-row small{min-width:65px;color:#00cfff}.global-search-row b{font-size:13px}
.game-stage{position:relative}.mobile-game-controls{position:absolute;inset:auto 14px 14px;display:flex;justify-content:space-between;align-items:end;pointer-events:none;z-index:8}.virtual-pad,.virtual-actions{pointer-events:auto;display:grid;gap:6px}.virtual-pad button,.virtual-actions button{width:48px;height:48px;border-radius:15px;background:#071426b8;border:1px solid #00cfff9c;color:#baf4ff;font-weight:900;font-size:18px;backdrop-filter:blur(8px);touch-action:none;user-select:none}.virtual-pad>button{margin:auto}.virtual-pad>div{display:flex;gap:6px}.virtual-actions{grid-template-columns:repeat(2,48px)}.virtual-actions button{background:#07549bbd}.virtual-actions #control-settings{font-size:16px}.mobile-game-controls button:active{background:#087bff;box-shadow:0 0 18px #00cfff88}
.admin-name{color:#ff5576!important;font-weight:900}.admin-name svg{width:13px;height:13px;vertical-align:-2px;margin-right:4px;color:#ff5576}
.top-profile{width:36px;height:36px;padding:2px;border-radius:50%;background:#0a2948;border:1px solid #00cfff;box-shadow:0 0 14px #00cfff35;flex-shrink:0}.top-profile img{width:100%;height:100%;border-radius:50%;object-fit:cover;display:block}
.section-actions{display:flex;align-items:center;gap:9px}.search-notification{position:relative;width:42px;height:42px;flex-shrink:0;border-radius:12px;background:#0d2d4e;border:1px solid #1763a0;color:#8beaff;display:grid;place-items:center}.search-notification svg{width:21px;height:21px}.search-notification .notification-count{right:-5px;top:-5px}

/* Dedicated game route: keep only the game, notification control, back navigation and community chat. */
#game-back{white-space:nowrap;margin-right:8px}
body.game-route-mode .brand,body.game-route-mode .main-nav,body.game-route-mode .hero,body.game-route-mode .section-head,body.game-route-mode #content-grid,body.game-route-mode #load-more,body.game-route-mode #social-dock,body.game-route-mode .site-footer,body.game-route-mode #auth-area,body.game-route-mode #top-profile-shortcut{display:none!important}
body.game-route-mode .page-shell{padding-top:14px}
body.game-route-mode #game-player{display:block!important;margin:0 auto;max-width:1500px}
body.game-route-mode #game-stage{min-height:70vh}
body.game-route-mode .topbar{justify-content:flex-end;gap:10px}
@media(max-width:700px){body.game-route-mode #game-stage{min-height:58vh}body.game-route-mode .page-shell{padding:8px}}

body.game-route-mode #game-player .comments-panel{display:none!important}

/* Visual polish: consistent depth, focus states and smoother card interactions. */
:root{--mdg-glow:rgba(0,207,255,.16)}
.content-card,.player-panel,.comments-panel,.chat-widget,.modal-card,.ext-card{box-shadow:0 16px 42px rgba(0,0,0,.18)}
.content-card{transition:transform .18s ease,border-color .18s ease,box-shadow .18s ease}
.content-card:hover{transform:translateY(-3px);border-color:rgba(0,207,255,.48);box-shadow:0 18px 44px rgba(0,0,0,.26),0 0 0 1px var(--mdg-glow)}
button,input,textarea,select{transition:border-color .16s ease,box-shadow .16s ease,transform .16s ease}
button:focus-visible,input:focus-visible,textarea:focus-visible,select:focus-visible{outline:2px solid #00cfff;outline-offset:2px;box-shadow:0 0 0 4px var(--mdg-glow)}
button:not(:disabled):active{transform:translateY(1px)}
.topbar{backdrop-filter:blur(14px)}


/* Community Wiki and creator contribution surfaces */
.community-compose{margin-top:18px;padding:16px;border:1px solid var(--line,#24344f);border-radius:14px;background:rgba(18,30,52,.55)}
.community-compose summary{cursor:pointer;font-weight:700;color:var(--accent,#7ddfff)}
.wiki-content{line-height:1.75;overflow-wrap:anywhere;padding:12px 0;color:var(--text,#eaf3ff)}
.wiki-content h2,.wiki-content h3{margin:18px 0 8px}
.wiki-content pre,.wiki-content code{white-space:pre-wrap;background:rgba(0,0,0,.22);padding:3px 6px;border-radius:5px}
.ext-panel .cf-turnstile{margin:10px 0}
#tab-contributions .admin-tabs{display:flex;gap:8px;margin:14px 0}
#tab-cosmetics label{display:flex;align-items:center;gap:8px}

/* Home discovery controls and accessible theme preferences */
.home-quick-actions{display:flex;flex-wrap:wrap;gap:8px;margin-top:18px;position:relative;z-index:2}.home-quick-actions button{font-size:12px;padding:9px 12px}.sort-select{background:#0b1424;border:1px solid var(--line);color:var(--text);padding:11px 12px;border-radius:11px;min-width:130px}.section-actions{flex-wrap:wrap}.home-quick-actions button:focus-visible,.sort-select:focus-visible{outline:2px solid var(--cyan);outline-offset:2px}
:root[data-theme="light"]{color-scheme:light;--bg:#edf4fb;--panel:#fff;--panel2:#e5eef8;--line:#c4d3e4;--text:#14243a;--muted:#526984;--cyan:#087ca5;--blue:#2466c7;--red:#c63e58}
:root[data-theme="light"] body{background:radial-gradient(ellipse at 78% -12%,#d5e9fa 0,transparent 38%),var(--bg);color:var(--text)}
:root[data-theme="light"] .topbar{background:#f5f9fced;border-color:#c4d3e4}:root[data-theme="light"] .content-card,:root[data-theme="light"] .player-panel,:root[data-theme="light"] .chat-widget,:root[data-theme="light"] .modal-card{background:#fff;color:#14243a;border-color:#c4d3e4}:root[data-theme="light"] .content-card p,:root[data-theme="light"] .post-body{color:#40556e}:root[data-theme="light"] .search-input,:root[data-theme="light"] .sort-select,:root[data-theme="light"] .comment-form input,:root[data-theme="light"] .comment-form textarea{background:#fff;color:#14243a;border-color:#c4d3e4}:root[data-theme="light"] .secondary{background:#e1ebf6;color:#193653;border-color:#c1d3e6}:root[data-theme="light"] .chat-toggle{background:#e4edf7;color:#193653}:root[data-theme="light"] .chat-message{background:#edf3fa;color:#193653}:root[data-theme="light"] .chat-message p{color:#263e58}:root[data-theme="light"] .ext-card{background:#f5f9fd;color:#14243a;border-color:#c4d3e4}:root[data-theme="light"] .ext-item,:root[data-theme="light"] .game-review-item{background:#eaf1f8;border-color:#c4d3e4;color:#14243a}:root[data-theme="light"] .ext-form input,:root[data-theme="light"] .ext-form textarea,:root[data-theme="light"] .ext-form select{background:#fff;color:#14243a;border-color:#c4d3e4}:root[data-theme="light"] .global-search-results{background:#fff;border-color:#c4d3e4}:root[data-theme="light"] .global-search-row{color:#14243a}:root[data-theme="light"] .global-search-row:hover{background:#e8f1fa}
@media(max-width:700px){.home-quick-actions button{flex:1 1 calc(50% - 8px)}.sort-select{width:100%}}

/* Dynamic featured-game hero (roadmap item 1). */
.hero{gap:28px;min-height:310px;padding:clamp(24px,4vw,44px)}
.hero-copy{position:relative;z-index:2;min-width:0;flex:1}
.hero-copy h1{max-width:760px;overflow-wrap:anywhere}
.hero-copy p{max-width:620px;line-height:1.65}
.hero-actions{display:flex;align-items:center;flex-wrap:wrap;gap:12px;margin-top:20px}
.hero-actions #hero-play{white-space:nowrap;min-width:132px}
.hero-actions .home-quick-actions{margin-top:0}
.hero-visual{position:relative;z-index:1;flex:0 0 min(34%,360px);height:220px;display:grid;place-items:center;overflow:hidden;border-radius:22px;background:linear-gradient(145deg,#0c2440,#102d4a 55%,#07182b);border:1px solid #39709a;box-shadow:0 18px 48px #0005}
.hero-visual:empty{display:none}
.hero-cover{width:100%;height:100%;position:absolute;inset:0;display:block;object-fit:cover}
.hero-visual:has(.hero-cover:not(.hidden)) .hero-orb{display:none}
.hero-visual:has(.hero-cover:not(.hidden)):after{content:"";position:absolute;inset:45% 0 0;background:linear-gradient(transparent,#06101dcc);pointer-events:none}
.hero-orb{display:grid;place-items:center;padding:0;width:170px;height:170px}
.hero-orb svg{width:100%;height:100%;filter:drop-shadow(0 12px 24px #0008)}
:root[data-theme="light"] .hero{background:linear-gradient(110deg,#e2f1fb,#f2f7fc 62%,#d8eafa);border-color:#b7d1e8}
:root[data-theme="light"] .hero-copy p{color:#405a75}
:root[data-theme="light"] .hero-visual{background:linear-gradient(145deg,#d4e8f7,#b9d7ef);border-color:#a6c7e3}
@media(max-width:760px){.hero{align-items:stretch;flex-direction:column-reverse;gap:18px}.hero-visual{flex-basis:auto;width:100%;height:clamp(150px,38vw,230px)}.hero-copy h1{font-size:clamp(30px,8vw,46px)}.hero-actions{align-items:stretch;flex-direction:column}.hero-actions #hero-play{width:100%}.hero-actions .home-quick-actions{width:100%}}

/* Hero banner event controls in Admin. */
.stack-form label.inline-check{display:flex;align-items:center;gap:10px}.stack-form label.inline-check input{width:auto}

/* Roadmap item 2: Continue playing */
.continue-section{margin:26px 0 30px;padding:20px;border:1px solid var(--line);border-radius:18px;background:linear-gradient(120deg,rgba(10,38,67,.72),rgba(13,25,43,.72))}.continue-section .section-head{margin:0 0 14px}.continue-section .section-head h2{margin:4px 0}.continue-section .section-head p{margin:5px 0 0;font-size:12px}.continue-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(190px,1fr));gap:12px}.continue-card{min-width:0;overflow:hidden;border:1px solid var(--line);border-radius:13px;background:var(--panel);display:flex;flex-direction:column}.continue-cover{width:100%;height:112px;object-fit:cover;background:linear-gradient(135deg,#0b2c55,#102d4a)}.continue-card-body{padding:11px;display:grid;gap:7px;flex:1}.continue-card h3{font-size:14px;margin:0;overflow-wrap:anywhere}.continue-card p{font-size:11px;color:var(--muted);margin:0;line-height:1.45;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}.continue-card button{width:100%;margin-top:auto}.continue-empty{grid-column:1/-1;padding:14px;border:1px dashed var(--line);border-radius:12px;color:var(--muted);font-size:13px}.continue-section .section-head{align-items:center;flex-direction:row}@media(max-width:560px){.continue-section{padding:14px}.continue-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.continue-cover{height:90px}.continue-section .section-head{align-items:flex-start}}

.continue-cover-placeholder{background:radial-gradient(circle at 70% 25%,#00cfff55,transparent 35%),linear-gradient(135deg,#0b2c55,#102d4a 60%,#071426)}

.trending-periods{display:flex;gap:6px;flex-wrap:wrap}.trending-periods button{font-size:11px;padding:8px 11px}.trending-periods button.active{border-color:var(--cyan);color:var(--cyan);box-shadow:inset 0 0 0 1px var(--cyan)}.continue-card .trending-plays{font-size:10px;color:var(--cyan);font-weight:700}
@media(max-width:560px){.trending-periods{width:100%}.trending-periods button{flex:1}}

.recommendation-reason{font-size:10px;color:var(--cyan);font-weight:700;line-height:1.35}.continue-card-body small.muted{font-size:10px;line-height:1.35}

/* v3.4.6 — Main menu refresh: clearer hierarchy, calmer spacing and responsive navigation. */
.topbar{
  gap:clamp(10px,1.7vw,22px);
  padding:12px clamp(14px,3.2vw,48px);
  background:linear-gradient(105deg,rgba(5,15,30,.97),rgba(8,25,46,.94) 58%,rgba(7,18,34,.97));
  border-bottom:1px solid rgba(86,230,210,.16);
  box-shadow:0 10px 32px rgba(0,0,0,.18);
}
.brand{gap:12px;min-width:205px}
.brand-mark{width:45px;height:45px;border-radius:14px;transition:transform .2s ease,box-shadow .2s ease}
.brand:hover .brand-mark{transform:rotate(-5deg) scale(1.04);box-shadow:0 0 24px rgba(0,207,255,.28)}
.brand b{font-size:13px;letter-spacing:.12em}
.brand small{font-size:10px;letter-spacing:.035em}
.main-nav{
  flex:1;min-width:0;gap:5px;padding:5px;
  border:1px solid rgba(113,157,205,.16);border-radius:15px;
  background:rgba(4,13,27,.48);justify-content:center;
}
.nav-btn{
  position:relative;display:inline-flex;align-items:center;justify-content:center;gap:7px;
  min-height:39px;padding:9px clamp(10px,1.35vw,17px);border-radius:10px;
  color:#a9bad1;font-size:12px;letter-spacing:.015em;white-space:nowrap;
}
.nav-btn:hover{color:#f0fbff;background:rgba(58,105,151,.2)}
.nav-btn.active{
  color:#dffaff;background:linear-gradient(135deg,rgba(13,76,119,.72),rgba(15,49,83,.92));
  box-shadow:inset 0 0 0 1px rgba(0,207,255,.28),0 5px 15px rgba(0,0,0,.16);
}
.nav-btn.active:after{content:"";position:absolute;left:25%;right:25%;bottom:3px;height:2px;border-radius:5px;background:linear-gradient(90deg,#087bff,#00d7e8);opacity:.9}
.nav-symbol{width:21px;height:21px;margin:0;border-radius:7px;font-size:13px;flex:0 0 21px}
.auth-area{min-width:120px;display:flex;justify-content:flex-end;align-items:center;gap:8px}
.auth-area .primary{min-height:41px;padding:10px 17px;border-radius:12px;font-size:12px;box-shadow:0 7px 20px rgba(0,151,255,.2)}
.search-notification{width:40px;height:40px;border-radius:12px;background:rgba(12,48,78,.78);border-color:rgba(0,207,255,.28)}
.top-profile{width:40px;height:40px}
.page-shell{max-width:1320px;padding-top:30px}
.hero{
  border-radius:26px;padding:clamp(25px,4vw,48px);
  background:radial-gradient(ellipse at 82% 15%,rgba(0,207,255,.13),transparent 32%),linear-gradient(115deg,#0b2c55 0%,#0b1c32 58%,#0a2946 100%);
  box-shadow:0 22px 60px rgba(0,0,0,.2),inset 0 1px 0 rgba(255,255,255,.06);
}
.hero:before{content:"";position:absolute;inset:12px;border:1px solid rgba(132,205,255,.08);border-radius:19px;pointer-events:none}
.hero-copy .eyebrow{display:inline-flex;align-items:center;gap:8px;padding:7px 10px;border:1px solid rgba(0,207,255,.2);border-radius:999px;background:rgba(0,17,36,.28)}
.hero h1{letter-spacing:-.035em;text-wrap:balance}
.hero-copy p{font-size:15px;max-width:590px}
.home-quick-actions{gap:9px}
.home-quick-actions button{min-height:39px;border-radius:11px;padding:10px 14px;font-size:11px}
.home-quick-actions #random-game{box-shadow:0 7px 20px rgba(0,151,255,.2)}
.home-quick-actions .secondary{background:rgba(16,39,66,.78);border-color:rgba(135,176,219,.24)}
.hero-visual{border-radius:20px}
.section-head:not(.compact){padding-bottom:12px;border-bottom:1px solid rgba(113,157,205,.16)}
.section-head h2{letter-spacing:-.025em}
.section-actions{gap:8px}
.sort-select,.search-input{min-height:43px;border-radius:12px}
.search-input{width:min(330px,45vw)}
.content-grid{gap:18px}
.content-card{border-radius:17px;background:linear-gradient(155deg,rgba(24,41,65,.98),rgba(13,24,41,.98));}

:root[data-theme="light"] .topbar{background:linear-gradient(105deg,rgba(246,250,255,.98),rgba(232,243,252,.97));border-bottom-color:#c5d9e9;box-shadow:0 8px 26px rgba(34,71,105,.09)}
:root[data-theme="light"] .main-nav{background:rgba(219,233,246,.72);border-color:#c8d9e9}
:root[data-theme="light"] .nav-btn{color:#526984}
:root[data-theme="light"] .nav-btn:hover{color:#123c60;background:#dceaf6}
:root[data-theme="light"] .nav-btn.active{color:#075b83;background:linear-gradient(135deg,#d5effb,#e4f0ff);box-shadow:inset 0 0 0 1px #9ccde4}
:root[data-theme="light"] .hero{background:radial-gradient(ellipse at 82% 15%,rgba(0,145,190,.12),transparent 32%),linear-gradient(115deg,#e2f1fb,#f2f7fc 58%,#d8eafa)}
:root[data-theme="light"] .hero-copy .eyebrow{background:rgba(255,255,255,.55);border-color:#b7d7e9}
:root[data-theme="light"] .home-quick-actions .secondary{background:#e6f0f8;border-color:#c2d7e8}
:root[data-theme="light"] .content-card{background:linear-gradient(155deg,#fff,#f4f8fc)}

@media(max-width:900px){
  .topbar{gap:10px;padding:11px 16px}
  .brand{min-width:0;flex:1}
  .main-nav{order:5;flex:0 0 100%;width:100%;justify-content:flex-start;overflow-x:auto;overflow-y:hidden;scrollbar-width:thin;scrollbar-color:#28618a transparent}
  .main-nav::-webkit-scrollbar{height:4px}.main-nav::-webkit-scrollbar-thumb{background:#28618a;border-radius:8px}
  .nav-btn{flex:0 0 auto}
  .auth-area{min-width:auto;margin-left:0}
}
@media(max-width:560px){
  .topbar{padding:10px 12px;gap:8px}
  .brand{gap:8px}
  .brand-mark{width:38px;height:38px;border-radius:12px}
  .brand b{font-size:11px;letter-spacing:.08em}
  .brand small{font-size:9px}
  .auth-area .primary{padding:9px 11px;min-height:37px;font-size:11px}
  .search-notification,.top-profile{width:36px;height:36px}
  .main-nav{order:5;gap:4px;padding:4px;border-radius:12px}
  .nav-btn{min-height:36px;padding:8px 11px;font-size:11px}
  .page-shell{padding-top:18px}
  .hero{border-radius:20px;padding:20px}
  .hero:before{inset:8px;border-radius:14px}
  .hero-copy p{font-size:13px}
  .home-quick-actions{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:7px}
  .home-quick-actions button{width:100%;min-width:0;padding:9px 7px;font-size:10px}
  .section-head:not(.compact){gap:12px}
  .section-head h2{font-size:23px}
  .section-actions{width:100%;display:grid;grid-template-columns:1fr}
  .search-input,.sort-select{width:100%;max-width:none}
  .content-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}
  .content-card{padding:13px;min-height:175px}
  .content-card h3{font-size:15px}
}
@media(prefers-reduced-motion:reduce){
  *,*:before,*:after{scroll-behavior:auto!important;animation-duration:.01ms!important;animation-iteration-count:1!important;transition-duration:.01ms!important}
}

/* v3.4.7 — cohesive community panels and usable multiplayer room discovery. */
.ext-panel{padding:clamp(8px,2vw,22px);background:rgba(2,8,18,.82);backdrop-filter:blur(12px)}
.ext-card{width:min(920px,100%);max-height:min(92vh,980px);padding:clamp(16px,2.4vw,28px);border-color:rgba(70,174,226,.38);background:radial-gradient(ellipse at 92% 0,rgba(0,207,255,.09),transparent 35%),linear-gradient(155deg,#102744,#09182b);scrollbar-width:thin;scrollbar-color:#28618a transparent}
.ext-head{position:sticky;top:-1px;z-index:3;padding:4px 0 13px;background:linear-gradient(#102744 82%,transparent);backdrop-filter:blur(8px)}
.ext-head h2{font-size:clamp(20px,3vw,27px);letter-spacing:-.025em}
.ext-tabs{display:flex;flex-wrap:nowrap;overflow-x:auto;overscroll-behavior-inline:contain;padding:2px 0 9px;scrollbar-width:thin;scrollbar-color:#28618a transparent}
.ext-tabs button{flex:0 0 auto;min-height:38px;font-weight:750;white-space:nowrap}
.ext-tabs button:focus-visible,.ext-close:focus-visible,.ext-card button:focus-visible,.social-dock button:focus-visible{outline:2px solid var(--cyan);outline-offset:2px}
.ext-item{min-width:0;align-items:center;padding:14px;background:linear-gradient(120deg,rgba(13,37,62,.96),rgba(8,25,44,.96));border-color:rgba(89,147,190,.2);transition:border-color .18s ease,transform .18s ease,background .18s ease}
.ext-item:hover{border-color:rgba(0,207,255,.4);background:linear-gradient(120deg,rgba(15,47,77,.98),rgba(9,29,50,.98))}
.ext-item>div:first-child{min-width:0;flex:1}
.ext-item b{overflow-wrap:anywhere}
.ext-form{gap:12px}
.ext-form label{display:grid;gap:7px;color:#b9cde2;font-size:12px;font-weight:700}
.ext-form input,.ext-form textarea,.ext-form select{min-height:42px;border-radius:11px}
.ext-form textarea{min-height:110px;line-height:1.55}
.ext-form button,.ext-item button{min-height:36px}
.room-create-card{padding:18px;margin:4px 0 24px;border:1px solid rgba(0,207,255,.23);border-radius:17px;background:radial-gradient(ellipse at 90% 0,rgba(0,207,255,.12),transparent 42%),linear-gradient(135deg,#102e4d,#0b1b30)}
.room-section{margin:22px 0}
.room-section-title{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:12px}
.room-section-title h3{margin:4px 0 0;font-size:18px}
.room-capacity-pill,.room-count{display:inline-flex;align-items:center;gap:6px;padding:7px 10px;border:1px solid rgba(0,207,255,.24);border-radius:999px;background:rgba(0,207,255,.08);color:#9cecff;font-size:10px;font-weight:800;white-space:nowrap}
.room-create-grid{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:12px;margin-top:14px}
.room-create-grid label{display:grid;gap:7px;color:#b9cde2;font-size:12px;font-weight:750}
.room-create-grid input,.room-create-grid select,.room-filter-row input,.room-filter-row select{width:100%;min-width:0;min-height:42px;padding:10px 12px;border:1px solid #234666;border-radius:11px;background:#07182a;color:#eff9ff}
.room-primary-actions{margin-top:14px}
.room-primary-actions button{min-height:42px}
.room-filter-row{display:grid;grid-template-columns:minmax(0,1fr) minmax(150px,220px);gap:9px;margin:0 0 12px}
.room-card{align-items:center}
.room-card-main{min-width:0;flex:1}
.room-card-main>p{margin:5px 0 8px}
.room-card-main code{font-size:10px;color:#9cecff;overflow-wrap:anywhere}
.room-progress{height:5px;max-width:300px;margin:8px 0;border-radius:20px;overflow:hidden;background:#1a2e45}
.room-progress span{display:block;height:100%;border-radius:20px;background:linear-gradient(90deg,#00b8d9,#70b7ff)}
#room-live-status{padding:12px 14px;margin:14px 0;border:1px solid rgba(0,207,255,.2);border-radius:12px;background:rgba(0,207,255,.06);color:#a9d9ee;line-height:1.5}
.continue-empty{padding:15px;border:1px dashed rgba(125,165,200,.28);border-radius:12px;color:var(--muted);font-size:12px}
.community-compose{padding:13px;border:1px solid rgba(89,147,190,.24);border-radius:13px;background:rgba(9,28,48,.65)}
.community-compose summary{cursor:pointer;font-weight:800;color:#bcecff}
.wiki-content{line-height:1.75;overflow-wrap:anywhere}
.wiki-content img{max-width:100%;height:auto}
#community-chat{max-width:calc(100vw - 24px)}
:root[data-theme="light"] .room-create-card{background:radial-gradient(ellipse at 90% 0,rgba(0,145,190,.1),transparent 42%),linear-gradient(135deg,#e9f6ff,#f6faff);border-color:#b8d7e9}
:root[data-theme="light"] .room-capacity-pill,:root[data-theme="light"] .room-count{color:#075b83;background:#e0f5ff;border-color:#b3dced}
:root[data-theme="light"] .room-create-grid label,:root[data-theme="light"] .ext-form label{color:#405a75}
:root[data-theme="light"] .room-create-grid input,:root[data-theme="light"] .room-create-grid select,:root[data-theme="light"] .room-filter-row input,:root[data-theme="light"] .room-filter-row select{background:#fff;color:#14243a;border-color:#c4d8e8}
:root[data-theme="light"] .ext-item{background:linear-gradient(120deg,#f7fbff,#edf5fc);border-color:#d1e0ed}
:root[data-theme="light"] .ext-item p,:root[data-theme="light"] .ext-muted{color:#526a83}
:root[data-theme="light"] .ext-tabs button{background:#e7f0f8;color:#31516d;border-color:#cbddea}
:root[data-theme="light"] .ext-tabs button.active{background:#0876b5;color:white;border-color:#0876b5}
:root[data-theme="light"] .ext-head{background:linear-gradient(#f5f9fd 82%,transparent)}
:root[data-theme="light"] .community-compose{background:#f0f6fc;border-color:#cbddea}
@media(max-width:640px){
  .room-create-grid,.room-filter-row{grid-template-columns:1fr}
  .room-section-title{align-items:flex-start}
  .room-card{align-items:stretch}
  .room-card .manage-actions{width:100%}
  .room-card .manage-actions button{flex:1 1 calc(50% - 6px)}
  .room-primary-actions{display:grid;grid-template-columns:1fr 1fr}
  .room-primary-actions #room-match-stop{grid-column:1/-1}
  .room-capacity-pill{font-size:9px;padding:6px 8px}
  .ext-card{max-height:94vh}
  .ext-item{gap:10px}
}
@media(prefers-reduced-motion:reduce){.ext-item,.ext-tabs button,.ext-close,.social-dock button{transition:none!important}button:hover{transform:none}}

/* Community feed cards and contribution surfaces. */
.post-card{gap:13px;min-height:0;padding:18px;position:relative;overflow:hidden}
.post-card:before{content:"";position:absolute;left:0;top:0;bottom:0;width:3px;background:linear-gradient(#00cfff,#739bff);opacity:.65}
.post-author{display:flex;align-items:center;justify-content:space-between;gap:10px;min-width:0}
.author-profile{display:inline-flex;align-items:center;gap:9px;min-width:0;padding:0;background:transparent;color:var(--text);font-weight:800;text-align:left}
.author-profile .avatar{width:34px;height:34px;flex:0 0 34px;border:1px solid rgba(0,207,255,.25)}
.author-profile span{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.post-card h3{font-size:17px;line-height:1.35;overflow-wrap:anywhere}
.post-body{line-height:1.7;overflow-wrap:anywhere}
.post-body a{color:#7bdfff;text-decoration:underline;text-underline-offset:3px}
.post-card .manage-actions{padding-top:10px;border-top:1px solid rgba(113,157,205,.13)}
.post-card .manage-actions button{min-height:35px;border-radius:10px}
.post-comments{width:100%;padding-top:10px}
.post-comment-form{display:grid;grid-template-columns:minmax(0,1fr);gap:8px;margin-top:12px}
.user-post-compose{box-shadow:0 16px 40px rgba(0,0,0,.12)}
.user-post-compose .section-head{margin:0 0 12px}
.user-post-compose .rich-editor{border-radius:13px;line-height:1.65}
:root[data-theme="light"] .post-card{background:linear-gradient(160deg,#fff,#f2f7fc)}
:root[data-theme="light"] .author-profile{color:#173653}
:root[data-theme="light"] .post-body a{color:#086ba5}
@media(max-width:560px){.post-card{padding:14px}.post-author{align-items:flex-start}.post-card .manage-actions{width:100%}.post-card .manage-actions button{flex:1}}
