/* VOC World game layer. Same calm glass as the simulator bars. All ids start with g-. */
#g-play { color: #f3dfa6; border: 1px solid rgba(243, 223, 166, .35); padding: 6px 13px; margin-left: 4px; font-weight: 600; letter-spacing: .04em; }
body.game #g-play { background: rgba(243, 223, 166, .16); }
body.game #views { opacity: 1; }
#g-ov { position: fixed; inset: 0; width: 100vw; height: 100vh; pointer-events: none; cursor: default; }
#g-ui { display: none; } body.game #g-ui { display: block; }
#g-ui .gl { position: fixed; background: rgba(13, 18, 29, .64); backdrop-filter: blur(20px) saturate(1.5); -webkit-backdrop-filter: blur(20px) saturate(1.5);
  border: 1px solid rgba(255, 255, 255, .10); box-shadow: 0 8px 30px rgba(0, 0, 0, .35); border-radius: 14px; color: #dfe6f2; }
#g-ui button { padding: 6px 10px; border-radius: 9px; color: #dfe6f2; text-align: center; transition: background .15s; }
#g-ui button.pri { background: rgba(243, 223, 166, .16); color: #f3dfa6; border: 1px solid rgba(243, 223, 166, .30); }
#g-ui button.pri:hover { background: rgba(243, 223, 166, .28); }
#g-ui button.sec { border: 1px solid rgba(255, 255, 255, .14); }
#g-ui button.ae { color: #b8c7ff; border: 1px solid rgba(160, 180, 255, .35); background: rgba(140, 160, 255, .10); }
#g-ui button[disabled] { opacity: .38; cursor: default; pointer-events: none; }
#g-ui button.on { color: #f3dfa6; background: rgba(255, 255, 255, .10); }
#g-ui .mut { color: #93a1b8; } #g-ui .gold { color: #f3dfa6; } #g-ui .ae-t { color: #b8c7ff; } #g-ui .inf-t { color: #e7b6d8; } .g-chip.bloc { background: rgba(231, 182, 216, .14); color: #e7c3dc; } #g-ui .warn { color: #f0b58f; } #g-ui .ok { color: #a8dcb4; }
#g-ui .num { font-variant-numeric: tabular-nums; }
#g-ui h3 { margin: 0; font-size: 14px; font-weight: 600; color: #f1f4fa; letter-spacing: .01em; }
#g-ui h4 { margin: 14px 0 6px; font-size: 10.5px; font-weight: 600; letter-spacing: .09em; text-transform: uppercase; color: #93a1b8; }

#g-hud { right: 14px; top: 14px; display: flex; align-items: center; gap: 2px; padding: 5px; }
#g-hud .cur { padding: 3px 10px; line-height: 1.25; } #g-hud .cur b { font-size: 14px; font-weight: 600; display: block; } #g-hud .cur span { font-size: 10.5px; color: #93a1b8; }
#g-nav { left: 14px; top: 62px; display: flex; gap: 2px; padding: 5px; }
#g-nav button i, #g-tabs button i { font-style: normal; display: inline-block; min-width: 15px; padding: 0 4px; margin-left: 5px; border-radius: 8px; background: rgba(243, 223, 166, .22); color: #f3dfa6; font-size: 10.5px; }

.g-panel { width: 318px; max-height: calc(100vh - 176px); overflow-y: auto; padding: 14px; box-sizing: border-box; scrollbar-width: thin; scrollbar-color: rgba(255,255,255,.2) transparent; line-height: 1.4; }
#g-side { left: 14px; top: 112px; } #g-drawer { right: 14px; top: 76px; width: 348px; max-height: calc(100vh - 306px); }
.g-panel .x { position: absolute; right: 8px; top: 8px; padding: 4px 9px !important; color: #93a1b8 !important; font-size: 15px; }
.g-panel .sub { color: #93a1b8; margin-top: 2px; font-size: 12px; }
.g-facts { display: grid; grid-template-columns: auto 1fr; gap: 3px 12px; margin-top: 10px; font-size: 12px; } h4 + .g-facts { margin-top: 0; } .g-facts span:nth-child(odd) { color: #93a1b8; }
.g-row { display: flex; align-items: center; gap: 8px; padding: 7px 0; border-top: 1px solid rgba(255, 255, 255, .07); } .g-row:first-of-type { border-top: 0; }
.g-row .grow { flex: 1; min-width: 0; } .g-row small { display: block; color: #93a1b8; font-size: 11.5px; }
.g-row.wrap { flex-wrap: wrap; } .g-row.wrap .grow { flex-basis: 100%; }
.g-btns { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 10px; }
.g-chip { display: inline-block; padding: 1px 7px; border-radius: 8px; font-size: 10.5px; background: rgba(255, 255, 255, .09); color: #c6d0e0; margin-right: 4px; }
.g-tl { position: relative; display: flex; gap: 2px; margin: 8px 0 4px; } .g-tl > div { flex: 1; min-width: 0; padding: 5px 4px 6px; border-radius: 6px; background: rgba(255, 255, 255, .07); text-align: center; overflow: hidden; }
.g-tl b { display: block; font-size: 10px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: #c6d0e0; } .g-tl small { display: block; font-size: 9.5px; color: #93a1b8; }
.g-tl .past { background: rgba(240, 181, 143, .30); } .g-tl .now { background: rgba(240, 181, 143, .16); outline: 1px solid rgba(240, 181, 143, .55); } .g-tl .now b { color: #f3dfa6; }
.g-tl > i { position: absolute; top: -3px; bottom: -3px; width: 2px; margin-left: -1px; background: #fff; border-radius: 1px; box-shadow: 0 0 6px rgba(255, 255, 255, .7); }
.g-chip.risk-home { background: rgba(140, 200, 150, .22); color: #b6e0bf; } .g-chip.risk-open { background: rgba(240, 181, 143, .18); color: #f0c2a4; } .g-chip.risk-frontier { background: rgba(240, 140, 120, .22); color: #f3b3a3; }
body.game #play, body.game #speed { opacity: .35; pointer-events: none; }   /* the sky is locked to real time while the game is on */
.g-chip.known { background: rgba(140, 200, 150, .18); color: #b6e0bf; } .g-chip.voc { background: rgba(243, 223, 166, .16); color: #f3dfa6; }
.g-chip.unknown { background: rgba(150, 170, 220, .18); color: #b9c7ee; } .g-chip.ice { background: rgba(190, 225, 255, .18); color: #d2e8ff; }
.g-bar { height: 4px; border-radius: 3px; background: rgba(255, 255, 255, .10); overflow: hidden; margin-top: 5px; } .g-bar i { display: block; height: 100%; background: #f3dfa6; border-radius: 3px; transition: width .9s linear; }
.g-bar.c i { background: #9fd6b0; } .g-bar.c.low i { background: #f0a58f; }
.g-dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; margin-right: 6px; vertical-align: 0; }
.g-tabs2 { display: flex; gap: 2px; margin: 10px 0 4px; } .g-tabs2 button { flex: 1; padding: 5px 4px !important; font-size: 12px; }
.g-tier { margin-top: 12px; } .g-tier > b { font-size: 10.5px; letter-spacing: .09em; color: #93a1b8; font-weight: 600; }
.g-tech { padding: 8px 10px; margin-top: 6px; border-radius: 10px; border: 1px solid rgba(255, 255, 255, .09); } .g-tech.done { border-color: rgba(160, 220, 180, .28); } .g-tech.locked { opacity: .5; }
.g-tech.final { border-color: rgba(243, 223, 166, .35); background: linear-gradient(160deg, rgba(190, 96, 60, .16), rgba(20, 24, 40, .1)); opacity: 1; }
.g-tech.final em { display: block; margin: 6px 0; font-style: italic; color: #e9d9b4; }
#g-mini { right: 14px; bottom: 62px; padding: 6px; border-radius: 12px; line-height: 0; } #g-mini canvas { position: static; width: 168px; height: 141px; border-radius: 8px; cursor: pointer; display: block; }
#g-toast { left: 14px; bottom: 30px; max-width: min(460px, 42vw); padding: 8px 12px; font-size: 12px; border-radius: 11px; transition: opacity .5s; pointer-events: none; }
#g-coach { left: 50%; transform: translateX(-50%); bottom: 74px; width: min(440px, calc(100vw - 28px)); padding: 13px 15px; box-sizing: border-box; border-color: rgba(243, 223, 166, .28) !important; line-height: 1.4; }
#g-coach small, .g-coachin small { font-size: 11px; } #g-coach .g-row .grow small, .g-coachin .g-row .grow small { display: block; color: #93a1b8; }
#g-coach .st { font-size: 10.5px; letter-spacing: .09em; color: #f3dfa6; text-transform: uppercase; } #g-coach p { margin: 5px 0 0; }
#g-coach .skip { position: absolute; right: 8px; top: 7px; font-size: 11px; color: #93a1b8 !important; padding: 3px 8px !important; }
#g-spark { width: 100%; height: 64px; display: block; position: static; cursor: default; }
#g-tabs { display: none; }
#g-fab { display: none; } .g-coachin { display: none; }
/* ---- G3: the living world. World screen, bloc panel, house panel, event card cause. */
#g-ui .heat-t { color: #f0a58f; } #g-ui .up { color: #f0b58f; margin-left: 3px; font-size: 10px; } #g-ui .dn { color: #a8dcb4; margin-left: 3px; font-size: 10px; }
#g-ui [data-a] { cursor: pointer; } .g-tap:hover { background: rgba(255, 255, 255, .04); }
.g-idx { display: flex; flex-wrap: wrap; gap: 4px; margin: 8px 0 2px; } .g-idx span { padding: 3px 8px; border-radius: 8px; background: rgba(255, 255, 255, .07); font-size: 11.5px; color: #93a1b8; } .g-idx b { color: #f1f4fa; font-weight: 600; }
.g-blocs { display: grid; grid-template-columns: 1fr; gap: 3px; }
#g-ui button.g-bloc { display: flex; align-items: center; gap: 8px; width: 100%; padding: 5px 8px 5px 0; border-radius: 8px; background: rgba(255, 255, 255, .045); text-align: left; overflow: hidden; }
#g-ui button.g-bloc:hover { background: rgba(255, 255, 255, .10); } #g-ui button.g-bloc.mine { outline: 1px solid rgba(243, 223, 166, .35); }
.g-bloc > i { width: 5px; align-self: stretch; border-radius: 3px; flex: none; } .g-bloc .nm { flex: 1; min-width: 0; } .g-bloc .nm b { display: block; font-size: 12.5px; font-weight: 600; color: #f1f4fa; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.g-bloc .nm small { display: block; font-size: 10.5px; color: #93a1b8; white-space: nowrap; } .g-bloc em { font-style: normal; font-weight: 700; font-size: 13px; min-width: 40px; text-align: right; font-variant-numeric: tabular-nums; }
.g-sp { width: 30px; height: 14px; flex: none; opacity: .9; } .g-idx .nx { background: rgba(243, 223, 166, .12); } .g-mv b { font-weight: 600; } .g-mv { margin-bottom: 6px; } .g-sp polyline { fill: none; stroke-width: 1.4; } .g-sp line { stroke: rgba(255, 255, 255, .25); stroke-width: .6; stroke-dasharray: 2 2; }
.band-calm em, .g-chip.band-calm { color: #a8dcb4; } .band-unrest em, .g-chip.band-unrest { color: #f3dfa6; } .band-crisis em, .g-chip.band-crisis { color: #f0b58f; } .band-regime em, .g-chip.band-regime { color: #f08a78; }
.g-chip.rel-trade { background: rgba(243, 223, 166, .14); color: #f3dfa6; } .g-chip.rel-pact { background: rgba(140, 200, 150, .2); color: #b6e0bf; } .g-chip.rel-rivalry { background: rgba(240, 181, 143, .2); color: #f0c2a4; } .g-chip.rel-sanction { background: rgba(240, 110, 100, .25); color: #f6b3a6; }
.g-rel { padding: 4px 0; font-size: 12px; line-height: 1.5; } .g-rel b { font-weight: 600; color: #f1f4fa; } .g-rel .g-dot { margin-right: 3px; }
.g-news { padding: 6px 0; border-top: 1px solid rgba(255, 255, 255, .07); } .g-news b { font-weight: 600; font-size: 12.5px; color: #e8edf6; } .g-news small { display: block; color: #93a1b8; font-size: 11.5px; margin-top: 1px; }
.g-news.mine b { color: #f3dfa6; } .g-news .why, .g-why b { color: #c9b8e8; font-weight: 600; } .g-news .res { color: #a8c8dc; font-weight: 600; }
.g-why { margin: 6px 0 4px; padding: 6px 9px; border-radius: 9px; background: rgba(170, 150, 220, .12); border: 1px solid rgba(170, 150, 220, .25); font-size: 12px; line-height: 1.4; }
.g-stress { position: relative; height: 8px; border-radius: 4px; background: rgba(255, 255, 255, .10); overflow: hidden; margin: 2px 0 4px; } .g-stress i { display: block; height: 100%; border-radius: 4px; background: #a8dcb4; }
.g-stress i.band-unrest { background: #f3dfa6; } .g-stress i.band-crisis { background: #f0b58f; } .g-stress i.band-regime { background: #f08a78; } .g-stress u { position: absolute; top: 0; bottom: 0; width: 1.5px; background: rgba(10, 14, 22, .9); }
.g-meters { display: grid; grid-template-columns: repeat(5, 1fr); gap: 6px; margin-top: 8px; } .g-meters span { display: block; font-size: 9.5px; color: #93a1b8; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } .g-meters b { font-size: 14px; font-weight: 600; color: #f1f4fa; }
.g-bar.h i { background: #f0a58f; } .g-cur { display: flex; height: 8px; border-radius: 4px; overflow: hidden; margin: 2px 0 5px; } .g-cur i { display: block; height: 100%; } .g-cur .o, .g-chip.cur-o { background: rgba(120, 180, 240, .75); } .g-cur .w, .g-chip.cur-w { background: rgba(240, 181, 143, .8); } .g-cur .l, .g-chip.cur-l { background: rgba(168, 220, 180, .8); }
.g-chip.cur-o, .g-chip.cur-w, .g-chip.cur-l { color: #0d121d; font-weight: 600; }
#g-ui button.g-back { padding: 2px 8px 2px 0 !important; min-height: 0; color: #93a1b8; font-size: 11.5px; display: block; margin-bottom: 2px; }
.g-btns.tight { gap: 4px; margin-top: 4px; } .g-btns.tight button { padding: 4px 8px !important; font-size: 11.5px; }
.g-steps { display: flex; gap: 3px; margin: 4px 0; } .g-steps > div { flex: 1; padding: 6px 5px; border-radius: 8px; background: rgba(255, 255, 255, .06); text-align: center; } .g-steps b { display: block; font-size: 13px; color: #c6d0e0; } .g-steps small { display: block; font-size: 10px; color: #93a1b8; }
.g-steps .now { background: rgba(243, 223, 166, .14); outline: 1px solid rgba(243, 223, 166, .4); } .g-steps .now b { color: #f3dfa6; } .g-steps .off { opacity: .35; }
#g-coach { max-height: calc(100vh - 190px); overflow-y: auto; }
#labels { transition: opacity .35s; } body.game.g-far #labels { opacity: 0; }   /* strategic zoom: bloc plates and core cities replace the city names */
@media (min-width: 761px) { body.g-wide #g-drawer { width: 436px; max-height: calc(100vh - 150px); } body.g-wide #g-mini { display: none; } .g-blocs { grid-template-columns: 1fr 1fr; } }
/* Phone-first rules: one thumb. Targets are 44 px or more, panels are bottom sheets, main actions sit in the lower half. */
@media (max-width: 760px) {
  body.game #ctl, body.game #credit, body.game #fps { display: none; }   /* the simulator bar comes back when you leave the game */
  body.game #views { left: 8px; right: 8px; top: 8px; }
  #g-play { order: -1; margin: 0 4px 0 0; min-height: 44px; box-sizing: border-box; display: inline-flex; align-items: center; padding: 0 16px; }
  #g-ui button { min-height: 44px; min-width: 44px; box-sizing: border-box; display: inline-flex; align-items: center; justify-content: center; padding: 0 14px; font-size: 13.5px; }
  #g-hud { left: 8px; right: 8px; top: 74px; justify-content: flex-start; gap: 14px; min-height: 44px; } #g-hud .cur { padding: 2px 8px; } #g-hud button { display: none; }
  #g-nav, #g-mini { display: none; }
  #g-tabs { display: flex; left: 8px; right: 8px; bottom: calc(8px + env(safe-area-inset-bottom, 0px)); padding: 4px; gap: 0; justify-content: space-between; overflow-x: auto; }
  #g-tabs button { flex: 1 0 auto; min-height: 50px; min-width: 44px; padding: 0 1px; font-size: 11.5px; white-space: nowrap; } #g-tabs button i { margin-left: 2px; padding: 0 3px; min-width: 10px; font-size: 10px; }
  #g-fab { display: inline-flex; position: fixed; right: 8px; bottom: calc(74px + env(safe-area-inset-bottom, 0px)); min-height: 52px; padding: 0 20px; border-radius: 26px; font-weight: 600;
    color: #f3dfa6; border: 1px solid rgba(243, 223, 166, .4); background: rgba(40, 36, 22, .78); } #g-fab[hidden] { display: none; }
  .g-panel, #g-drawer, #g-side { left: 8px !important; right: 8px !important; top: auto !important; bottom: calc(70px + env(safe-area-inset-bottom, 0px)); width: auto !important; max-height: 54vh; border-radius: 18px; padding-top: 18px; overscroll-behavior: contain; -webkit-overflow-scrolling: touch; }
  .g-panel::before { content: ''; position: absolute; left: 50%; top: 7px; width: 36px; height: 4px; margin-left: -18px; border-radius: 2px; background: rgba(255, 255, 255, .22); }
  .g-panel .x { right: 4px; top: 6px; font-size: 20px; padding: 0 !important; }
  .g-panel h3 { padding-right: 44px; font-size: 16px; } .g-row { gap: 6px; padding: 8px 0; } .g-btns { gap: 8px; } .g-tabs2 button { padding: 0 4px !important; }
  .g-coachin { display: block; margin: 2px 40px 12px 0; padding: 9px 12px; border-radius: 12px; border: 1px solid rgba(243, 223, 166, .28); background: rgba(243, 223, 166, .07); }
  .g-coachin .st, .g-coachin .skip { display: none !important; } .g-coachin h3 { font-size: 13px; color: #f3dfa6; padding: 0; } .g-coachin p { margin: 2px 0 0; font-size: 12.5px; }
  #g-toast { left: 8px; right: 8px; bottom: calc(134px + env(safe-area-inset-bottom, 0px)); max-width: none; } body.game.sheet #g-toast { bottom: auto; top: 134px; }
  #g-coach { bottom: calc(70px + env(safe-area-inset-bottom, 0px)); padding: 14px 16px; }
  #g-hud { gap: 6px; } .g-blocs { grid-template-columns: 1fr 1fr; gap: 4px; } #g-ui button.g-bloc { min-height: 44px; padding: 0 6px 0 0; gap: 6px; justify-content: flex-start; } .g-bloc .g-sp { display: none; } .g-bloc em { min-width: 40px; }
  .g-row.g-tap { min-height: 44px; } .g-meters b { font-size: 15px; } .g-btns.tight button { min-height: 44px; min-width: 44px; padding: 0 8px !important; } #g-ui button.g-back { min-height: 44px; }
  .g-rel b[data-a], .g-mv b[data-a], .sub b[data-a], .g-chip[data-a] { position: relative; } .g-rel b[data-a]::after, .g-mv b[data-a]::after, .sub b[data-a]::after, .g-chip[data-a]::after { content: ''; position: absolute; left: -6px; right: -6px; top: -15px; bottom: -15px; min-width: 44px; min-height: 44px; }   /* inline links: a 44 px touch area */
  .g-rel { padding: 7px 0; } #g-coach { max-height: 62vh; } body.g-wide #g-drawer { max-height: 66vh; }
  .g-idx { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; margin: 6px 0 0; } .g-idx span { white-space: nowrap; flex: none; } #g-ui button.g-bloc { min-height: 44px; } .g-bloc .nm small { font-size: 10px; } #g-drawer h4 { margin-top: 11px; }
}
/* ---- G4: the estate level. The close view is drawn on the overlay canvas; the sheet holds the three actions. */
.g-est .g-row b { font-size: 13px; } .g-est .g-row small { line-height: 1.35; } .g-est button.pri { white-space: nowrap; }
@media (min-width: 761px) { body.g-estate #g-side { width: 326px; } body.g-estate #g-mini { display: none; } }
@media (max-width: 760px) { body.g-estate #g-side { max-height: 44vh; } body.g-estate #g-fab { display: none; } body.game.g-estate #g-toast { top: auto; bottom: calc(44vh + 78px + env(safe-area-inset-bottom, 0px)); } }
@media (max-width: 760px) {
  #g-hud .cur { min-height: 44px; min-width: 44px; display: flex; flex-direction: column; justify-content: center; box-sizing: border-box; }   /* the Lumen, influence and Heat chips open a tab: a full touch target */
  .g-bloc .nm b { font-size: 12px; letter-spacing: -.1px; } .g-acts { margin: 8px 0 2px; }
  .g-coachin p b { color: #f3dfa6; }
}
/* two clocks: the sky time and the real date in the top strip */
#g-hud .g-clk b { color: #dfe6f2; } @media (max-width: 760px) { #g-hud { overflow-x: auto; scrollbar-width: none; } #g-hud .cur { flex: none; } #g-hud .g-clk { margin-left: auto; } }
