:root{color-scheme:dark;--bg:#101b21;--panel:#17262d;--line:#2c3d43;--text:#e7ece7;--muted:#9aadb1;--gold:#e2bd7c;--accent:#ed7770;font-family:Inter,ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;font-size:16px}*{box-sizing:border-box}body{margin:0;background:var(--bg);color:var(--text)}button,input{font:inherit}button,a{-webkit-tap-highlight-color:transparent}button{cursor:pointer;color:inherit;border:1px solid var(--line);background:transparent;border-radius:6px;padding:11px 15px;transition:background .18s,border .18s}button:hover:not(:disabled){background:#ffffff0d;border-color:#84968c}button:focus-visible,a:focus-visible,input:focus-visible,summary:focus-visible{outline:2px solid var(--gold);outline-offset:4px}button:disabled{opacity:.4;cursor:default}header{height:98px;margin:0 3.4%;display:flex;align-items:center;justify-content:space-between;border-bottom:1px solid var(--line)}.brand{display:flex;align-items:center;gap:13px;text-decoration:none;color:var(--text);font-size:23px;letter-spacing:3px}.brand b{font-weight:400;color:var(--gold)}.brand small{display:block;font:10px ui-sans-serif,system-ui;letter-spacing:3.6px;color:var(--muted);margin-top:6px}.brand-icon{font-size:53px;color:var(--gold);line-height:1}.header-right{display:flex;align-items:center;gap:20px}.edition{font-size:11px;letter-spacing:2px;color:var(--muted)}.quiet{font-size:14px}.key{font-size:12px;border:1px solid #ffffff25;padding:1px 5px;border-radius:3px;margin-left:12px;color:inherit}main{display:grid;grid-template-columns:minmax(0,1fr) 290px;gap:30px;margin:30px 3.4% 0;max-width:1800px}.map-heading{display:flex;justify-content:space-between;align-items:center;margin-bottom:24px}.eyebrow{font-size:11px;letter-spacing:2.3px;color:var(--gold);font-weight:600}h1{font-family:Georgia,serif;font-size:31px;font-weight:400;margin:8px 0 0}h2{font-family:Georgia,serif;font-size:26px;font-weight:400}.map-id{text-align:right;font-size:10px;letter-spacing:1.8px;color:var(--muted)}.map-id strong{font-size:14px;color:var(--text);font-weight:400;margin-left:5px}.map-id>span{display:block;margin-top:8px;font-size:10px}.map-frame{border:1px solid #3d514f;border-radius:8px;overflow:hidden;background:#152a33;position:relative;box-shadow:0 16px 55px #0002}.map-top,.map-bottom{display:flex;justify-content:space-between;align-items:center;padding:14px 20px;font-size:12px;color:#c0cdc8;background:#14232c}.map-top{border-bottom:1px solid #ffffff0c}.map-top #phase{color:var(--gold)}#round{letter-spacing:2px}.map-scroll{overflow:auto;background:radial-gradient(ellipse at 40% 40%,#24404a,#142b34);scrollbar-color:#4c6267 #192c33}#map{display:block;width:100%;min-width:640px;max-height:650px;margin:auto;user-select:none}.map-bottom{padding:9px 16px;background:#14232cd9}.map-bottom>span span{margin-left:18px}.map-bottom button{padding:1px 10px;font-size:20px;border:none;color:var(--muted)}.tile{cursor:pointer;outline:none}.hex-face{stroke:#182e322b;stroke-width:.65;stroke-linejoin:round;transition:filter .15s}.sea .hex-face{stroke:#7096a51a;stroke-width:.5}.hex-bevel{fill:none;stroke:#f4ffdf33;stroke-width:.8;pointer-events:none}.coastline{stroke:#c8d6ae;stroke-width:2;stroke-linecap:round;opacity:.8;pointer-events:none}.frontier{stroke-width:1.6;stroke-linecap:round;opacity:.8;pointer-events:none}.tile:hover .hex-face,.tile:focus-visible .hex-face{filter:brightness(1.2);stroke:#f9e5b7;stroke-width:2}.destination-ring{fill:#ffeaad12;stroke:#ffe6a1;stroke-width:1.4;stroke-dasharray:3 3;pointer-events:none}.tile.selected .hex-face{stroke:#fff4bd;stroke-width:3;filter:brightness(1.16)}.map-piece .army-counter{fill:#142831;stroke-width:1.5;filter:drop-shadow(0 2px 2px #07151a80)}.map-piece .troop{font:700 17px ui-sans-serif,system-ui;fill:#fffbed}.map-piece .morale{font:11px ui-sans-serif,system-ui;fill:#ccded9}.map-piece .marker{font:18px Georgia,serif;fill:#fff0c9;paint-order:stroke;stroke:#213b36;stroke-width:2}.map-piece.spent .army-counter{fill:#2f4045}.map-piece.spent .troop{opacity:.65}.city-nameplate{fill:#122630f2;stroke-width:.8}.city-label{font:600 14px ui-sans-serif,system-ui;fill:#fff5db;letter-spacing:.2px}.labels-layer{pointer-events:none}.map-scroll{background:#193948}#map{min-width:1000px;max-height:none!important}.map-frame{border-color:#506761;box-shadow:0 18px 50px #0003}
.instruction{display:flex;align-items:center;gap:13px;min-height:66px;color:var(--muted)}.instruction-icon{font-size:27px;color:var(--gold)}.instruction p{font-size:14px;flex:1;line-height:1.5;margin:12px 0}.keyboard-note{font-size:9px;letter-spacing:1px;white-space:nowrap;color:#738c91}.bottom-grid{display:grid;grid-template-columns:1fr 1fr;gap:25px;padding-top:18px;border-top:1px solid var(--line)}.section-label{display:flex;justify-content:space-between;font-size:10px;letter-spacing:1.7px;color:var(--muted);margin-bottom:15px}.section-label span{font-size:9px;color:#6e888c}#balance-bar{height:5px;display:flex;gap:3px;border-radius:3px;overflow:hidden;margin-bottom:14px}#balance-bar span{transition:width .3s}#empire-legend{display:flex;flex-wrap:wrap;gap:12px;font-size:11px;color:var(--muted)}.color-dot{display:inline-block;width:7px;height:7px;border-radius:2px;margin-right:6px}.journal #log{height:66px;overflow:auto;font-size:12px;line-height:1.7;color:#b9c9c6}.log-row{display:flex;gap:10px}.log-row span{color:#6e888c;font-variant-numeric:tabular-nums}.command-panel,.selection-panel,.diplomacy{border:1px solid var(--line);background:linear-gradient(130deg,#1b2c33,#16262d);border-radius:8px;padding:22px;margin-bottom:16px}.commander-title{display:flex;align-items:center;gap:12px;margin-top:17px;margin-bottom:22px}.crest{display:grid;place-items:center;font-size:26px;width:47px;height:51px;clip-path:polygon(0 0,100% 0,100% 72%,50% 100%,0 72%);color:#fff;background:var(--accent)}.commander-title h2{margin:0;font-size:24px}.commander-title small{display:block;margin-top:4px;font-size:11px;color:var(--muted)}.stats{display:grid;grid-template-columns:repeat(3,1fr);gap:12px}.stat b{font-weight:400;font-size:24px;display:block;font-variant-numeric:tabular-nums}.stat span{font-size:11px;color:var(--muted)}.divider{border-top:1px solid var(--line);margin:22px 0}.orders-heading{display:flex;justify-content:space-between;font-size:13px}.orders-heading strong{color:var(--gold);font-weight:500}.orders{display:flex;gap:6px;margin:14px 0 18px}.orders span{height:5px;flex:1;border-radius:2px;background:#344449}.orders .available{background:var(--gold)}.primary{background:var(--gold);color:#17262c;border:1px solid var(--gold);font-size:14px;font-weight:650;padding:14px 16px;width:100%}.primary:hover:not(:disabled){background:#efd099;color:#15242a;border-color:#efd099}.reinforcement{font-size:11px;line-height:1.6;margin:13px 0 0;text-align:center;color:var(--muted)}.selection-panel{min-height:216px;background:transparent}.empty-icon{font-size:35px;color:#638084;margin-top:19px}.selection-panel h2{font-size:21px;margin:8px 0}.selection-panel p{font-size:13px;color:var(--muted);line-height:1.7;margin:9px 0}.unit-stats{display:flex;gap:35px;margin:17px 0 12px}.unit-stats strong{font-size:28px;font-weight:400;display:block}.unit-stats small{color:var(--muted);font-size:12px}.unit-meter{background:#2b3d44;height:4px;margin:8px 0}.unit-meter span{display:block;height:100%;background:var(--accent)}.diplomacy{padding:20px;background:transparent}.action{display:block;width:100%;padding:14px 0;text-align:left;border:0;border-radius:0;font-size:13px}.action small{display:block;font-size:9px;letter-spacing:1.5px;color:var(--muted);margin:7px 0 0 26px}.action+.action{border-top:1px solid var(--line);padding-bottom:0}.objective{font-size:12px;line-height:1.9;color:var(--muted);text-align:center;margin:22px 0}.objective span{display:block;font-size:9px;letter-spacing:2px;color:var(--gold);margin-bottom:6px}footer{display:flex;justify-content:space-between;gap:20px;margin:28px 3.4% 20px;font-size:11px;color:#6e888c}footer button{font-size:11px;border:0;padding:0;color:var(--muted)}dialog{background:#182930;color:var(--text);border:1px solid #4d625e;border-radius:12px;box-shadow:0 30px 150px #0009;padding:36px;max-width:570px;width:calc(100% - 32px);max-height:90dvh;overflow:auto}dialog::backdrop{background:#071419ad;backdrop-filter:blur(5px)}dialog h2{font-size:38px;margin:16px 0}dialog p{font-size:14px;line-height:1.7;color:var(--muted)}.nation-picker{display:grid;grid-template-columns:1fr 1fr;gap:10px;margin:25px 0}.nation{padding:16px;text-align:left;display:flex;align-items:center;gap:12px;border-color:#3b4d52}.nation.chosen{border-color:var(--nation);background:color-mix(in srgb,var(--nation) 12%,transparent)}.nation .color-dot{width:12px;height:20px;margin:0}.nation small{display:block;color:var(--muted);font-size:11px;margin-top:4px}.seed-row{display:flex;align-items:end;gap:16px;margin:20px 0 24px}.seed-row label{font-size:12px;color:var(--muted);flex:1}input{display:block;margin-top:8px;width:100%;border:1px solid #455b60;border-radius:5px;background:#10222a;color:var(--text);padding:10px 13px}dialog .close{position:absolute;right:15px;top:12px;font-size:24px;border:0}.rules p{margin-bottom:22px}.rules b{display:block;color:var(--text);margin-bottom:6px}.rules+details{border-top:1px solid var(--line);padding-top:20px;color:var(--muted);font-size:13px}details a{color:var(--gold)}summary{cursor:pointer}.pact-option{width:100%;margin-top:10px;text-align:left}#cancel-new,#view-map{width:100%;margin-top:12px;border:0}#result-title{color:var(--gold)}
@media(min-width:1600px){main{margin:35px auto 0;width:93.2%;grid-template-columns:minmax(0,1fr) 320px}#map{max-height:740px}}
@media(max-width:1100px){main{gap:20px;grid-template-columns:minmax(0,1fr) 260px}.keyboard-note,.edition{display:none}.command-panel,.selection-panel,.diplomacy{padding:18px}.bottom-grid{grid-template-columns:1fr}.journal{display:none}.header-right{gap:10px}h1{font-size:27px}}
@media(max-width:800px){header{height:80px}.brand{font-size:19px;letter-spacing:2px}.brand-icon{font-size:42px}.brand small{font-size:8px;letter-spacing:2px}.header-right{gap:5px}.header-right button{font-size:12px;padding:8px}.header-right .key{display:none}main{display:flex;flex-direction:column;margin-top:22px}.map-heading{margin-bottom:18px}h1{font-size:26px}.map-id{font-size:9px}.map-id>span{display:none}aside{display:grid;grid-template-columns:1fr 1fr;gap:15px}.command-panel{grid-row:span 2;margin:0}.selection-panel,.diplomacy{margin:0;min-height:0}.objective{display:none}.bottom-grid{padding-top:12px}.map-top,.map-bottom{font-size:11px;padding:12px}.instruction{min-height:56px}.instruction p{font-size:12px}.eyebrow{font-size:10px}footer{font-size:10px}}
@media(max-width:460px){.brand small{display:none}.header-right button{max-width:85px}aside{display:block}.command-panel,.selection-panel,.diplomacy{margin-bottom:14px}.selection-panel{min-height:0}.stats{gap:20px}.commander-title{margin-top:12px;margin-bottom:15px}.divider{margin:16px 0}.map-id{display:none}dialog{padding:27px}dialog h2{font-size:32px}.nation{padding:11px;font-size:14px}.seed-row{gap:8px}.map-bottom>span span{margin-left:10px}footer{align-items:start}}
@media(prefers-reduced-motion:reduce){*{transition:none!important;scroll-behavior:auto!important}}

/* Miniature landscapes: raster artwork, vector interaction and political borders. */
.hex-face{stroke:#18281866;stroke-width:.75}.sea .hex-face{stroke:#c3eff722;stroke-width:.5}
.biome-art{transition:filter .15s}.tile:hover .biome-art,.tile:focus-visible .biome-art{filter:brightness(1.18)}
.hex-bevel{stroke:#fff5c966;stroke-width:.9}.coastline{stroke-width:2.4;opacity:1;filter:drop-shadow(0 1px 1px #163637)}
.frontier{stroke-width:2.8;opacity:1;filter:drop-shadow(0 1px 1px #15282a)}
.destination-ring{fill:#fff3af22;stroke:#fff6c1;stroke-width:2;stroke-dasharray:none;filter:drop-shadow(0 0 2px #122c37)}
.tile.selected .hex-face{stroke:#fff6bd;stroke-width:3.5;filter:drop-shadow(0 0 3px #142d30)}
.map-piece .army-counter{fill:#10242df5;stroke-width:2}.map-piece .marker{font-size:14px;stroke:#142c32;stroke-width:3}
.city-nameplate{fill:#132c35f5;stroke-width:1.2}.city-label{fill:#fff6db}
.map-scroll{background:#1f5363}#map{background:#214f62}

/* Continuous landscape, isolated miniature objects, subtle tactical overlay. */
.landscape,.scenery-layer{pointer-events:none}
.scenery-object{filter:drop-shadow(2px 3px 1px #25362366)}
.hex-face{stroke:#344b3440;stroke-width:.65;fill:transparent}
.sea .hex-face{stroke:#b0e1e719;stroke-width:.55}
.coastline,.frontier{stroke-width:2.4;opacity:.95;filter:drop-shadow(0 1px 1px #10271c)}
.tile:hover .hex-face,.tile:focus-visible .hex-face{fill:#fff5c52b;stroke:#fff2af;stroke-width:2}
.tile.selected .hex-face{fill:#ffe6a440;stroke:#fff4c4;stroke-width:3}
.destination-ring{fill:#fff0b82b;stroke:#ffe8a2;stroke-width:2;stroke-dasharray:3 2}
.city-nameplate{fill:#102b31f5;stroke-width:1}.city-label{font-size:13px}
.map-piece .army-counter{fill:#102630f5}
#map{background:#17475f}.map-scroll{background:#17475f}

/* Real 3D board and projected, accessible tactical controls. */
.board-stage{position:relative;min-width:740px;width:100%;aspect-ratio:1065/640;overflow:hidden;background:radial-gradient(ellipse at 50% 40%,#183440,#0d202b 75%);touch-action:none}
#board-canvas,.board-stage #map{position:absolute;inset:0;width:100%;height:100%;min-width:0;background:transparent;margin:0;max-height:none}
.map-scroll{background:#0d202b}.board-stage .hex-face{stroke:#e1efb940;stroke-width:.55;fill:transparent;pointer-events:all}
.board-stage .sea .hex-face{stroke:#b1e5ec55;stroke-width:.6}
.board-stage .frontier{stroke-width:2.5;filter:drop-shadow(0 1px 1px #172719);pointer-events:none}
.board-stage .tile:hover .hex-face,.board-stage .tile:focus-visible .hex-face{fill:#fff8d422;stroke:#ffedb6;stroke-width:1.5}
.board-stage .tile.selected .hex-face{fill:#ffe8a62b;stroke:#ffe6a4;stroke-width:2.5}
.board-stage .destination-ring{fill:#ffe7a233;stroke:#ffe8a8;stroke-width:1.6;stroke-dasharray:3 2;pointer-events:none}
.board-stage .city-nameplate{fill:#eaddbbee;stroke:#534d38;stroke-width:1}
.board-stage .city-label{fill:#27312a;font:600 10px Georgia,serif;letter-spacing:0}
.board-stage .army-counter{fill:#182e33f5;stroke-width:1.8}.board-stage .troop{font-size:11px}
.board-stage .army-morale{font:600 9px ui-sans-serif,system-ui;fill:#e2bd7c}
.board-stage.dragging{cursor:grabbing}.board-stage.dragging .tile{cursor:grabbing}
.render-error{position:relative;margin:30px;color:#ffe6af;z-index:3}
@media(max-width:800px){.board-stage{min-width:640px}}

/* Private online games. */
.online-entry{border-top:1px solid var(--line);margin-top:24px;padding-top:20px}
.online-entry label,#join-form label,.invite-row label{display:block;font-size:12px;color:var(--muted)}
#online-create,#copy-invite{margin-top:12px;width:100%}
.online-error{color:#ffb4a8;min-height:0;margin:10px 0 0}.online-error:empty{display:none}
#join-form label{margin:20px 0 24px}#join-cancel,#lobby-leave{width:100%;margin-top:12px;border:0}
.invite-row{display:flex;align-items:end;gap:12px}.invite-row label{flex:1}.invite-row #copy-invite{width:auto;margin:0}
.lobby-note{font-size:12px!important;margin:8px 0 0}
.nation .commander{color:var(--text);font-size:12px}.nation .commander.offline{color:var(--muted)}
#lobby-nations .nation:disabled{opacity:.75}
#skip-absent{width:100%;margin-top:10px;font-size:12px}
/* Audio settings */
#sound.muted{color:var(--muted)}
.audio-settings{display:grid;gap:22px;margin-top:24px}
.audio-toggle{display:flex;align-items:center;gap:12px;font-size:14px;cursor:pointer}
.audio-toggle input{width:18px;height:18px;margin:0;padding:0;accent-color:var(--gold)}
.audio-slider{display:grid;grid-template-columns:1fr auto;gap:8px 12px;font-size:13px;color:var(--muted)}
.audio-slider output{color:var(--text);font-variant-numeric:tabular-nums}
.audio-slider input{grid-column:1/-1;margin:0;padding:0;border:0;background:none;accent-color:var(--gold);height:22px}
#audio-test{justify-self:start}
#audio-status{margin:0;font-size:12px}
