/* Approved frontend v0.2 palette and layout. Shared by menu entrypoints; game/editor workspaces are unchanged. */
.frontend{--bg:#0b141b;--panel:#121f28;--text:#edf2ed;--muted:#9aadb6;--gold:#ddc38a;--line:#263640;background:radial-gradient(ellipse at 80% 0,#18313c55,transparent 50%),var(--bg);color:var(--text)}
.frontend [hidden]{display:none!important}.frontend .top{min-height:78px;padding:14px 28px;position:relative;background:var(--bg);gap:18px}.frontend .top .brand{margin-right:auto}.frontend .top>.button{flex:none}.frontend .frontend-shell{display:grid;grid-template-columns:224px minmax(0,1fr);max-width:none;margin:0;padding:0;min-height:calc(100dvh - 78px)}
.frontend-side{padding:26px 14px;border-right:1px solid var(--line);display:flex;flex-direction:column;gap:5px;background:var(--bg)}.frontend-side>a,.frontend-side>button,.frontend-side .side-bottom>button{display:flex;gap:12px;align-items:center;border:1px solid transparent;background:transparent;border-radius:5px;text-align:left;padding:12px;color:var(--text);font:inherit;text-decoration:none;min-height:46px;cursor:pointer}.frontend-side [aria-current=page]{background:#2c3b39;color:var(--gold);border-color:#6a705d;box-shadow:inset 2px 0 var(--gold)}.frontend-side .nav-heading{font-size:10px;letter-spacing:1.7px;color:var(--muted);padding:12px}.frontend-side .side-bottom{margin-top:auto;padding-top:48px;display:grid;gap:5px}.frontend-side .side-bottom p{color:var(--muted);padding:12px;font-size:12px;line-height:1.7}
.frontend-content{padding:24px 36px 40px;min-width:0;width:100%;max-width:1432px;margin:0 auto}.frontend .connection-state{font-size:11px;color:var(--muted);margin-bottom:22px;display:flex;align-items:center;gap:8px;flex-wrap:wrap}.frontend .connection-state a{color:var(--gold)}.frontend .frontend-pagehead{display:flex;justify-content:space-between;align-items:center;gap:20px;margin-bottom:26px}.frontend .frontend-pagehead h1{font-size:32px;line-height:1.15;margin:0;letter-spacing:-1px}.frontend .frontend-pagehead p:not(.eyebrow){margin:9px 0 0;color:var(--muted);font-size:14px}.frontend .frontend-pagehead .eyebrow{margin:0 0 10px}.frontend .frontend-hero{min-height:220px;padding:28px 30px;margin-bottom:28px;background:linear-gradient(110deg,#12252e,#16343d);border:1px solid #314852;border-radius:8px}.frontend .frontend-hero h2{font-size:28px;margin:0 0 10px}.frontend .frontend-hero p{color:var(--muted);max-width:650px;line-height:1.65}.frontend .hero-actions{display:flex;gap:12px;flex-wrap:wrap;margin-top:20px}.frontend-dashboard-grid{display:grid;grid-template-columns:minmax(0,2fr) minmax(260px,1fr);gap:24px}.frontend .section-heading{display:flex;gap:12px;justify-content:space-between;align-items:center;margin:0 0 16px}.frontend .section-heading h2{font-size:20px;margin:0}.frontend-panel{padding:22px;border:1px solid #314852;border-radius:8px;background:var(--panel);min-width:0}.frontend-panel+.frontend-panel{margin-top:16px}.frontend-panel h2,.frontend-panel h3{margin:0 0 12px}.frontend-panel h2{font-size:20px}.frontend-panel p{color:var(--muted);font-size:13px;line-height:1.65}.frontend .recent-games{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px}.recent-game{border:1px solid #314852;background:linear-gradient(150deg,#192c35,#11212b);border-radius:8px;overflow:hidden;min-width:0}.recent-game>div:last-child{padding:18px}.recent-game h3{margin:12px 0 8px;font-size:17px}.recent-game p,.recent-game small{color:var(--muted)}.recent-game .button{display:flex;margin-top:16px}.online-task{padding:16px 0;border-bottom:1px solid var(--line)}.online-task:last-child{border:0}.frontend .dashboard-stats{display:flex;flex-wrap:wrap;margin-top:22px;background:#12252e;border:1px solid var(--line);border-radius:8px;gap:0}.frontend .dashboard-stats>span{flex:1;padding:17px 16px;color:var(--muted);font-size:12px}.frontend .dashboard-stats b{color:var(--gold);font-size:21px;margin-right:8px}.frontend .hub-grid{grid-template-columns:repeat(3,minmax(0,1fr));gap:16px}.frontend .campaign-card{padding:0;background:linear-gradient(150deg,#192c35,#11212b);border:1px solid #314852;border-radius:8px;overflow:hidden;position:relative}.frontend .campaign-card>.map-preview,.frontend .recent-game>.map-preview{height:94px;display:flex;gap:12px;align-items:center;padding:12px 50px 12px 12px;background:#0b202b;border-bottom:1px solid var(--line)}.frontend .campaign-card>.map-preview img,.frontend .recent-game>.map-preview img{width:120px;height:68px;object-fit:contain;border:1px solid #36505b;border-radius:4px;flex:none;position:static}.frontend .campaign-card>.map-preview span,.frontend .recent-game>.map-preview span{position:static;background:none;padding:0;font-size:12px;line-height:1.5;overflow-wrap:anywhere;color:var(--text)}.frontend .map-preview-custom{min-width:56px;color:var(--gold)}.frontend .hub-card-body{padding:18px}.frontend .hub-card-body h3{font-size:17px}.frontend .hub-favorite{top:14px;right:10px;min-height:36px;min-width:32px}.frontend .hub-dashboard-tools{margin:0 0 18px}.frontend .hub-tabs{flex-wrap:wrap}.frontend .hub-tabs button[aria-pressed=true]{background:#2c3b39;color:var(--gold);border-color:#6a705d}.frontend input,.frontend select{background:#0a1923;border-color:#3e5661;color:#edf2ed;min-height:42px}.frontend .button{min-height:42px;border-radius:5px}.frontend .button.primary{background:var(--gold);color:#18242a;border-color:var(--gold)}.frontend :is(button,a,input,select):focus-visible{outline:2px solid var(--gold);outline-offset:3px}.frontend .lobby-filters{display:grid;grid-template-columns:minmax(180px,2fr) repeat(3,minmax(110px,1fr));padding:18px;border:1px solid #314852;border-radius:8px;background:#12232c;gap:12px}.frontend .lobby-filters label{min-width:0;font-size:12px;color:var(--muted)}.frontend .lobby-filters input,.frontend .lobby-filters select{width:100%}.frontend .hub-toolbar{display:flex;align-items:center;gap:10px;flex-wrap:wrap;margin:16px 0 20px}.frontend .hub-toolbar>span{font-size:12px;color:var(--muted)}
.frontend-browser-layout{display:grid;grid-template-columns:minmax(0,1fr) 292px;gap:20px;align-items:start}.frontend-tablebox{border:1px solid #314852;border-radius:8px;overflow:hidden;min-width:0}.frontend-server-table{width:100%;border-collapse:collapse;text-align:left;font-size:13px}.frontend-server-table th{padding:12px;color:var(--muted);font-size:11px;font-weight:500;background:#152731;border-bottom:1px solid #314852}.frontend-server-table td{padding:17px 12px;border-bottom:1px solid var(--line);vertical-align:middle}.frontend-server-table tr:last-child td{border:0}.frontend-server-table tr.selected{background:#263c46}.frontend-server-table tbody tr:hover{background:#1b323c}.frontend-server-table td strong{font-size:14px;display:block;line-height:1.5;overflow-wrap:anywhere}.frontend-server-table small{display:block;color:var(--muted);margin-top:5px}.frontend-server-table button{font-size:12px;white-space:nowrap;padding:8px;min-height:40px}.frontend-map-cell{display:flex;align-items:center;gap:12px}.frontend-map-cell .map-preview{flex:none;width:84px;height:48px;border:1px solid #36505b;border-radius:4px;margin:0;overflow:hidden}.frontend-map-cell .map-preview img{width:100%;height:100%;object-fit:contain}.frontend-map-cell .map-preview span{display:none}.frontend-server-detail{position:sticky;top:22px}.frontend-server-detail .map-preview{height:140px}.frontend-server-detail .button{width:100%;margin-top:14px}.frontend-details{display:grid;grid-template-columns:1fr 1fr;gap:12px 8px;font-size:12px;margin:20px 0}.frontend-details dt{color:var(--muted)}.frontend-details dd{text-align:right;margin:0}.frontend-invitation{margin:22px 0;padding:16px;border:1px solid var(--line);border-radius:8px}.frontend-invitation summary{cursor:pointer;color:var(--gold);min-height:30px}.frontend-lobby-head{padding:25px;background:#12252e;border:1px solid #314852;border-radius:8px;margin:18px 0 24px;display:flex;align-items:center;gap:24px}.frontend-lobby-head h1{font-size:27px;margin:9px 0}.frontend-lobby-head p{font-size:13px;color:var(--muted)}.frontend-lobby-head>.map-preview{width:200px;height:114px;flex:none}.frontend-lobby-grid{display:grid;grid-template-columns:minmax(0,1fr) 300px;gap:24px}.frontend-seats{border:1px solid #314852;background:var(--panel);border-radius:8px;overflow:hidden}.frontend-seat{padding:17px 18px;display:flex;justify-content:space-between;gap:16px;align-items:center;border-bottom:1px solid var(--line)}.frontend-seat:last-child{border:0}.frontend-seat.own-seat{background:#263c46}.frontend-seat small{display:block;margin-top:6px;color:var(--muted)}.frontend-seat .hub-tag{white-space:nowrap}.frontend-readybar{margin-top:20px;padding:18px 22px;border:1px solid #6a705d;background:#2c3b39;border-radius:8px;display:flex;justify-content:space-between;align-items:center;gap:18px}.frontend-readybar p{font-size:13px;color:#cfdbc7;margin:6px 0 0}.frontend-lobby-actions{display:flex;gap:10px;flex-wrap:wrap;margin-top:18px}.frontend .hub-empty{grid-column:1/-1;padding:28px;color:var(--muted)}.frontend footer{margin-top:32px;border-top:1px solid var(--line);padding-top:17px;display:flex;gap:12px;justify-content:space-between;align-items:center;color:var(--muted);font-size:11px}.frontend #browser-status:empty,.frontend #lobby-status:empty{display:none}
@media(max-width:1280px){.frontend .frontend-shell{grid-template-columns:190px minmax(0,1fr)}.frontend-content{padding:24px}.frontend .hub-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.frontend-browser-layout{grid-template-columns:1fr}.frontend-server-detail{position:static}.frontend-lobby-grid{grid-template-columns:minmax(0,1fr) 270px}}
@media(max-width:1020px){.frontend .frontend-shell{grid-template-columns:176px minmax(0,1fr)}.frontend-dashboard-grid,.frontend-lobby-grid{grid-template-columns:1fr}.frontend .top{padding:14px 18px}.frontend .brand{font-size:16px}}
@media(max-width:760px){.frontend .frontend-shell{display:block}.frontend .top{min-height:70px;padding:12px 15px;gap:8px}.frontend .top .account #account-label{display:none}.frontend .top>#center-feedback{font-size:11px;padding:8px}.frontend-side{padding:8px 12px;position:sticky;top:0;z-index:20;flex-direction:row;overflow-x:auto;border-right:0;border-bottom:1px solid #314852;gap:4px}.frontend-side>a,.frontend-side>button{flex:none;min-height:44px;font-size:12px;padding:9px 10px;white-space:nowrap;gap:6px}.frontend-side .nav-heading,.frontend-side .side-bottom{display:none}.frontend-content{padding:22px 16px 32px}.frontend .frontend-pagehead{align-items:flex-start;gap:10px;margin-bottom:20px;flex-wrap:wrap}.frontend .frontend-pagehead h1{font-size:27px}.frontend .frontend-hero{padding:24px 22px;min-height:234px}.frontend .frontend-hero h2{font-size:26px}.frontend .hero-actions>*{width:100%}.frontend .hub-grid,.frontend .recent-games{grid-template-columns:1fr}.frontend .hub-dashboard-tools{display:block}.frontend .hub-search{margin-top:12px}.frontend .dashboard-stats>span{padding:14px 10px;font-size:11px}.frontend .dashboard-stats b{display:block;font-size:20px;margin-bottom:4px}.frontend .lobby-filters{grid-template-columns:1fr 1fr;padding:15px;gap:13px 10px}.frontend .lobby-filters .hub-search{grid-column:1/-1;margin:0}.frontend-server-table thead{display:none}.frontend-server-table,.frontend-server-table tbody{display:block}.frontend-server-table tbody tr{display:grid;grid-template-columns:1fr 1fr;padding:14px 16px;border-bottom:1px solid #314852}.frontend-server-table td{border:0;padding:6px 0}.frontend-server-table td:first-child{grid-column:1/-1}.frontend-server-table td[data-label]::before{content:attr(data-label);display:block;font-size:10px;color:var(--muted);margin-bottom:5px}.frontend-server-table td:last-child{text-align:right;align-self:end}.frontend-server-table td:last-child button{width:100%}.frontend-lobby-head{display:block;padding:22px}.frontend-lobby-head>.map-preview{width:100%;height:140px}.frontend-readybar{flex-direction:column;align-items:stretch}.frontend-seat{flex-wrap:wrap}.frontend .button,.frontend button{min-height:44px}.frontend footer{flex-wrap:wrap}.frontend .brand-icon{display:none}}
.frontend .frontend-server-detail .hub-favorite{position:static;width:auto;margin-top:12px}.frontend .map-preview.large img{object-fit:contain}.frontend .hub-card-body,.frontend .frontend-seat>div{min-width:0;overflow-wrap:anywhere}
@media(max-width:760px){.frontend .top{height:auto;flex-wrap:wrap}.frontend .top>[data-panel=admin]{order:5}.frontend .top .brand{max-width:100%;white-space:normal}.frontend .top .brand span:last-child{min-width:0}}
/* Shared menu frame: these selectors are used by every menu entrypoint. */
.frontend .frontend-header{height:84px;min-height:84px;flex-wrap:nowrap;padding:12px 28px;gap:18px}.frontend .frontend-header .brand{display:block;width:250px;flex:0 1 250px;margin-right:auto;min-width:130px}.frontend .frontend-header .brand img{display:block;width:100%;height:auto;max-height:62px;object-fit:contain;object-position:left center}.frontend-version{font-size:11px;color:var(--muted);white-space:nowrap}.frontend .frontend-header .account{flex:none;color:var(--text);text-decoration:none;min-height:44px}.frontend .frontend-shell{min-height:calc(100dvh - 84px)}.frontend .frontend-shell:has(>[data-frontend-nav][hidden]){grid-template-columns:minmax(0,1fr)}.frontend .frontend-side .frontend-nav-link{display:flex;gap:12px;align-items:center;border:1px solid transparent;background:transparent;border-radius:5px;text-align:left;padding:12px;color:var(--text);font:inherit;font-size:14px;text-decoration:none;min-height:46px;cursor:pointer}.frontend .frontend-side .frontend-nav-link[aria-current=page]{background:#2c3b39;color:var(--gold);border-color:#6a705d;box-shadow:inset 2px 0 var(--gold)}.frontend .nav-icon{width:20px;text-align:center}.frontend .frontend-content .entry-card,.frontend .frontend-content .slot-row,.frontend .editor-home-card,.frontend .editor-home-draft{border:1px solid #314852;background:var(--panel);border-radius:8px;color:var(--text)}.frontend .entry-card p,.frontend .editor-home p,.frontend .editor-home-draft small{color:var(--muted)}.frontend .editor-home{max-width:1432px;margin:0 auto}.frontend .editor-home-intro{max-width:none;margin:0 0 26px}.frontend .editor-home h1{font-size:32px;line-height:1.15;margin:0;letter-spacing:-1px}.frontend .editor-home-intro p{margin:9px 0 0;font-size:14px}.frontend .editor-home h2{font-size:20px}.frontend .editor-home-card{padding:22px;min-height:0;gap:10px}.frontend .editor-home-card h4{font-size:17px;margin:0}.frontend .editor-home-card p{margin:0 0 12px}.frontend .editor-home-card strong{color:var(--gold)}.frontend .editor-home-import{display:grid;gap:10px;margin:22px 0}.frontend .editor-home-import input{padding:10px;border:1px solid #3e5661;border-radius:5px;max-width:100%}.frontend .entry-grid{grid-template-columns:repeat(auto-fit,minmax(min(100%,280px),1fr))}.frontend .entry-card.map-choice{text-align:left;overflow:hidden}.frontend .entry-form{max-width:800px}.frontend .frontend-content .entry-back{margin-bottom:22px}.frontend .slot-row{gap:16px}.frontend .admin-main{max-width:none;width:100%;padding:0;margin:24px 0 0;min-width:0}.frontend .admin-main>h2{margin:0 0 20px;font-size:24px}.frontend .admin-nav{display:flex;flex-direction:row;flex-wrap:wrap;position:static;height:auto;overflow:visible;border:1px solid #314852;border-radius:8px;background:var(--panel);padding:10px;gap:6px}.frontend .admin-nav button{border:1px solid transparent;border-radius:5px;background:transparent;color:var(--muted);font-size:12px;padding:10px 12px;min-height:42px}.frontend .admin-nav button[aria-current=page]{background:#2c3b39;color:var(--gold);border-color:#6a705d;box-shadow:none}.frontend .admin-main p{color:var(--muted)}.frontend :is(.admin-record-card,.admin-edit-form,.admin-detail-banner,.admin-filterbar){background:var(--panel);border-color:#314852;border-radius:8px}.frontend .admin-main input[type=checkbox]{min-height:0}.frontend .form-grid input[type=checkbox]{min-height:0}.frontend .frontend-content input:not([type=checkbox]):not([type=radio]),.frontend .frontend-content select,.frontend .frontend-content textarea{font:inherit}.frontend .frontend-content [role=status]{color:var(--muted);line-height:1.6}
@media(max-width:1020px){.frontend .frontend-header{padding:12px 18px}.frontend .frontend-header .brand{width:220px;flex-basis:220px}.frontend .frontend-content{padding:24px}}
@media(max-width:760px){.frontend .frontend-header{height:72px;min-height:72px;gap:8px;padding:10px 15px}.frontend .frontend-header .brand{width:190px;flex-basis:190px}.frontend .frontend-header .brand img{max-height:48px}.frontend-version{display:none}.frontend .frontend-header .account #account-label{display:none}.frontend .frontend-header #center-feedback{font-size:11px;padding:8px}.frontend .frontend-shell{min-height:calc(100dvh - 72px)}.frontend .frontend-side .frontend-nav-link{flex:none;font-size:12px;min-height:44px;padding:9px 10px;white-space:nowrap;gap:6px}.frontend .frontend-side .side-bottom{display:flex;flex:none;margin:0;padding:0;gap:4px}.frontend .frontend-side .side-bottom p{display:none}.frontend .frontend-content{padding:22px 16px 32px}.frontend .editor-home h1{font-size:27px}.frontend .admin-nav{flex-wrap:nowrap;overflow-x:auto}.frontend .admin-nav button{flex:none;white-space:nowrap;min-height:44px}.frontend .slot-row{flex-wrap:wrap}.frontend .slot-row .form-actions{width:100%;flex-wrap:wrap}.frontend .admin-main{margin-top:22px}}
/* Grid items and map images must shrink with their containing panel. */
.frontend-browser-layout>*{min-width:0}
.frontend .frontend-server-detail .map-preview{width:100%;max-width:100%;overflow:hidden}
.frontend .frontend-server-detail .map-preview img{display:block;width:100%;max-width:100%;height:100%;object-fit:contain}
.frontend .frontend-server-detail h2,.frontend .frontend-details dd{overflow-wrap:anywhere;min-width:0}
.frontend .frontend-map-cell>div{min-width:0}
/* Shared game overview and explicit country choice. */
.game-overview{width:min(880px,calc(100vw - 32px));max-height:90dvh;overflow:auto;border:1px solid var(--line,#40505c);border-radius:18px;background:#15222e;color:#e4ebed;padding:24px}
.game-overview::backdrop{background:#050c15c9}.game-overview header{display:flex;gap:16px;justify-content:space-between;align-items:start}.game-overview .map-preview{max-width:100%;overflow:hidden}.game-overview img{width:100%;height:auto;object-fit:contain}.overview-seats{display:grid;grid-template-columns:repeat(auto-fit,minmax(180px,1fr));gap:10px}.overview-seats article{display:grid;padding:12px;background:#ffffff08;border-radius:10px;gap:5px}.frontend-server-table tr[data-card-id]{cursor:pointer}.frontend-server-table tr[data-card-id]:focus-visible{outline:2px solid #d9bd76;outline-offset:-2px}.lobby-geography svg{display:block;width:100%;height:auto;max-height:400px;border-radius:12px}.frontend-seat button[aria-pressed=true]{background:#dfb765;color:#172531}.frontend-panel input{max-width:100%;min-width:0}.frontend-panel form{display:grid;gap:12px;margin:18px 0}.game-overview h2,.frontend-seat strong{overflow-wrap:anywhere}
@media(max-width:600px){.game-overview{width:100vw;height:100dvh;max-height:100dvh;border-radius:0;border:0;padding:18px;margin:0}.game-overview header{position:sticky;top:-18px;background:#15222e;padding-top:10px;z-index:1}.overview-seats{grid-template-columns:1fr 1fr}}
.lobby-waitbar{position:sticky;bottom:10px;z-index:20;max-width:1100px;margin:16px auto 0;background:#1b3039;border:1px solid #a68b52;border-radius:12px;box-shadow:0 6px 24px #0005;padding:10px 16px}.lobby-waitbar[hidden]{display:none}.lobby-waitbar>div{display:flex;align-items:center;gap:14px;flex-wrap:wrap}.lobby-waitbar span{flex:1;color:#c5d4d6;font-size:.85rem}.lobby-waitbar strong{overflow-wrap:anywhere}.lobby-waitbar p{margin:6px 0}
.news-banner{display:flex;align-items:center;gap:18px;padding:20px;background:linear-gradient(110deg,#263c44,#1a2936);border:1px solid #647057;border-radius:14px;margin-bottom:18px}.news-banner>div{flex:1;min-width:0}.news-banner h2{margin:0;font-size:1.25rem}.news-banner p{white-space:pre-line;overflow-wrap:anywhere;margin:8px 0}.news-banner img{width:140px;height:90px;object-fit:cover;border-radius:8px}.news-banner.secondary{padding:12px 20px}.news-banner.secondary img{display:none}@media(max-width:600px){.news-banner{flex-wrap:wrap;padding:14px}.news-banner img{display:none}.news-banner h2{font-size:1.1rem}.news-banner p{font-size:.85rem}.news-banner .eyebrow{display:none}}
.lobby-waitbar{grid-column:1/-1;width:calc(100% - 32px)}.country-dot{display:inline-block;width:12px;height:12px;border:1px solid #fff8;border-radius:50%;margin-right:8px}

#library-preferences{margin-bottom:20px;min-width:0}#library-preferences summary{cursor:pointer;min-height:44px;align-content:center;color:var(--gold)}#library-preferences .library-preference-comparison{max-width:100%;overflow-x:auto}#library-preferences .library-preference-table{width:100%;table-layout:fixed;border-collapse:collapse;font-size:13px;margin:16px 0;text-align:left}#library-preferences .library-preference-table th,#library-preferences .library-preference-table td{padding:10px 8px;vertical-align:top;overflow-wrap:anywhere;border-bottom:1px solid var(--line)}#library-preferences .library-preference-table caption{text-align:left;padding:8px;font-weight:700}#library-preferences li{overflow-wrap:anywhere}

.friends-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px}#friends-content .frontend-panel{margin-bottom:16px;min-width:0}#friends-content label{display:block;margin:12px 0}#friends-content input:not([type=checkbox]),#friends-content select{max-width:100%;width:100%}.friend-card{padding:16px 0;border-bottom:1px solid var(--line);overflow-wrap:anywhere}#friends-content summary{cursor:pointer;min-height:44px;align-content:center}.friends-confirm{max-width:min(520px,90vw);background:#152731;color:var(--text,#e8eef1);border:1px solid #465b68;border-radius:12px;padding:24px}.friends-confirm::backdrop{background:#0009}[data-friend-count]{color:var(--gold);font-size:12px}@media(max-width:760px){.friends-grid{grid-template-columns:minmax(0,1fr)}}
