/* Phosphor Metropolis '96 — Classic 1996 Beveled Workstation + Phosphor LCD UI */
:root {
  --bg-void: #071018;
  --win-bg: #c6cbd2;
  --win-dark: #8c949e;
  --win-darker: #4a525d;
  --win-light: #eef2f6;
  --title-a: #0a3560;
  --title-b: #166a88;
  --ark-a: #4f125e;
  --ark-b: #9a1b68;
  --lcd-bg: #081214;
  --phosphor-green: #4dff9b;
  --phosphor-cyan: #57e8ff;
  --phosphor-amber: #ffcb52;
  --phosphor-magenta: #ff6be6;
  --phosphor-red: #ff5d6c;
  --font-ui: "Tahoma", "Segoe UI", system-ui, sans-serif;
  --font-mono: "Consolas", "Lucida Console", "Courier New", monospace;
}

* { box-sizing: border-box; user-select: none; }
html, body {
  margin: 0; padding: 0;
  width: 100%; height: 100%;
  overflow: hidden;
  background: var(--bg-void);
  font-family: var(--font-ui);
  font-size: 12px;
  color: #111820;
}

#city-canvas {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100vh;
  display: block;
  cursor: crosshair;
}

.crt-overlay {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 4;
  opacity: 0;
  transition: opacity 0.2s;
  background:
    repeating-linear-gradient(
      to bottom,
      rgba(0, 0, 0, 0) 0px,
      rgba(0, 0, 0, 0) 2px,
      rgba(0, 0, 0, 0.12) 3px,
      rgba(0, 0, 0, 0.12) 4px
    ),
    radial-gradient(ellipse at center, transparent 62%, rgba(0, 8, 16, 0.42) 100%);
}
.crt-overlay.enabled { opacity: 1; }

/* 1996 3D Bevels */
.bevel-out {
  background: var(--win-bg);
  border-top: 2px solid var(--win-light);
  border-left: 2px solid var(--win-light);
  border-right: 2px solid var(--win-darker);
  border-bottom: 2px solid var(--win-darker);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.48);
}

.win-titlebar {
  background: linear-gradient(90deg, var(--title-a), var(--title-b));
  color: #f4fbff;
  font-weight: 700;
  font-size: 11px;
  letter-spacing: 0.4px;
  padding: 4px 7px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
}
.ark-titlebar {
  background: linear-gradient(90deg, var(--ark-a), var(--ark-b));
}
.mini-tag, .hotkey-hint {
  font-family: var(--font-mono);
  font-size: 10px;
  opacity: 0.9;
  background: rgba(0, 0, 0, 0.28);
  padding: 1px 5px;
  border-radius: 2px;
}

.win-btn {
  background: var(--win-bg);
  color: #111a24;
  border-top: 2px solid var(--win-light);
  border-left: 2px solid var(--win-light);
  border-right: 2px solid var(--win-darker);
  border-bottom: 2px solid var(--win-darker);
  padding: 4px 8px;
  font-family: var(--font-ui);
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
}
.win-btn:hover:not(:disabled) { background: #d6dbe2; }
.win-btn:active:not(:disabled), .win-btn.active {
  border-top: 2px solid var(--win-darker);
  border-left: 2px solid var(--win-darker);
  border-right: 2px solid var(--win-light);
  border-bottom: 2px solid var(--win-light);
  background: #aeb6c0;
}
.win-btn:disabled {
  opacity: 0.48;
  cursor: not-allowed;
}
.win-close {
  background: var(--win-bg);
  border: 1px solid #303944;
  font-weight: 900;
  font-size: 11px;
  width: 18px;
  height: 18px;
  line-height: 1;
  cursor: pointer;
  padding: 0;
}
.primary-btn {
  background: linear-gradient(180deg, #1b8c67, #126248);
  color: #f4fff9;
  border-top-color: #66e4b7;
  border-left-color: #66e4b7;
  border-right-color: #083324;
  border-bottom-color: #083324;
  padding: 8px 16px;
  font-size: 13px;
  letter-spacing: 0.5px;
}
.primary-btn:hover:not(:disabled) {
  background: linear-gradient(180deg, #21a47a, #177557);
}

/* TOP COMMAND BAR */
.top-bar {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 20;
  height: 44px;
  padding: 3px 8px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.brand-cluster {
  display: flex;
  align-items: center;
  gap: 7px;
  min-width: 0;
}
.brand-badge {
  background: #081926;
  color: var(--phosphor-green);
  font-family: var(--font-mono);
  font-weight: 800;
  font-size: 11px;
  padding: 4px 6px;
  border: 1px solid #2b647d;
  text-shadow: 0 0 6px rgba(77, 255, 155, 0.5);
}
.city-name-display {
  font-weight: 800;
  font-size: 13px;
  color: #0f253a;
  cursor: pointer;
  white-space: nowrap;
  max-width: 155px;
  overflow: hidden;
  text-overflow: ellipsis;
}
.city-name-display:hover { text-decoration: underline; }
.mode-pill {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: 2px;
  background: #4e155d;
  color: #ffd3f8;
  white-space: nowrap;
}
.mode-pill.sandbox {
  background: #144d3c;
  color: #b5ffdf;
}

.lcd-cluster {
  display: flex;
  align-items: center;
  gap: 4px;
  min-width: 0;
}
.lcd-box {
  background: var(--lcd-bg);
  border-top: 2px solid #444d56;
  border-left: 2px solid #444d56;
  border-right: 2px solid #e6ebf0;
  border-bottom: 2px solid #e6ebf0;
  padding: 2px 6px;
  min-width: 64px;
  display: flex;
  flex-direction: column;
  line-height: 1.15;
  white-space: nowrap;
}
#btn-budget-lcd, #hud-ark-box { cursor: pointer; }
#btn-budget-lcd:hover, #hud-ark-box:hover { filter: brightness(1.18); }
.lcd-label {
  font-family: var(--font-mono);
  font-size: 7.5px;
  color: #7d9ba6;
  letter-spacing: 0.4px;
  white-space: nowrap;
}
.lcd-val {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}
.lcd-val.green { color: var(--phosphor-green); text-shadow: 0 0 5px rgba(77,255,155,0.35); }
.lcd-val.cyan { color: var(--phosphor-cyan); }
.lcd-val.amber { color: var(--phosphor-amber); }
.lcd-val.magenta { color: var(--phosphor-magenta); }
.lcd-val.danger { color: var(--phosphor-red); animation: pulse-red 1s infinite; }
@keyframes pulse-red { 0%,100% { opacity: 1; } 50% { opacity: 0.55; } }
.lcd-supply { min-width: 144px; cursor: pointer; }
.lcd-supply-v4 { min-width: 174px; cursor: pointer; }
.supply-row { display: inline-flex; align-items: center; gap: 3px; font-size: 11.5px; }
.sup-irn { color: #b7d4ed; }
.sup-cop { color: #ff9c4a; }
.sup-stl { color: #ffcb52; }
.sup-sil { color: #fff49c; }
.sup-oil { color: #d878ff; }
.sup-chp { color: #57f2ff; }
.sup-cmp { color: #6effa8; }
.pwr-chart {
  background: #07141f;
  border: 2px inset #566675;
  padding: 7px 9px;
  margin-bottom: 10px;
  font-family: var(--font-mono);
  font-size: 10.5px;
  color: #cbeeff;
}
.pwr-row {
  display: grid;
  grid-template-columns: 145px 1fr 66px;
  align-items: center;
  gap: 8px;
  padding: 2px 0;
}
.pwr-bar-track { height: 9px; background: #142533; position: relative; }
.pwr-bar-gen { height: 100%; background: linear-gradient(90deg, #2be890, #57f2ff); }
.pwr-bar-use { height: 100%; background: linear-gradient(90deg, #ff9d3b, #ff5d6c); }
.sup-sep { color: #3c5666; }
.ark-tool-wide { grid-column: span 2; flex-direction: row; gap: 6px; padding: 4px 6px; }
.rd-warn {
  margin-top: 4px;
  font-family: var(--font-mono);
  font-size: 9px;
  line-height: 1.25;
  color: #ffd152;
  background: rgba(145, 78, 0, 0.32);
  padding: 2px 4px;
  border-left: 2px solid #ffcb52;
}
.gate-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  font-family: var(--font-mono);
  font-size: 9.5px;
  margin-bottom: 5px;
}
.gate-pill {
  padding: 1px 6px;
  background: #d9c0c4;
  color: #6b1520;
  border: 1px solid #a8646e;
  font-weight: 700;
}
.gate-pill.ok {
  background: #c7ebd6;
  color: #0d5e34;
  border-color: #4aa873;
}
.bottleneck-box {
  background: #2b1808;
  color: #ffd570;
  border: 1px solid #d48824;
  padding: 6px 8px;
  font-family: var(--font-mono);
  font-size: 10.5px;
  margin-bottom: 8px;
}
.supply-rate-strip {
  display: flex;
  justify-content: space-between;
  background: #0d1d2b;
  color: #b7ebff;
  border-top: 1px solid #6b7480;
  padding: 3px 7px;
  font-family: var(--font-mono);
  font-size: 9.5px;
  cursor: pointer;
}
.supply-rate-strip:hover { background: #142c40; }
.trade-desk {
  margin-top: 10px;
  background: #cdd4dc;
  border: 1px solid #808b97;
  padding: 8px;
}
.trade-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  padding: 4px 0;
  border-bottom: 1px dotted #9aa3ae;
  font-family: var(--font-mono);
  font-size: 11px;
}
.trade-row:last-child { border-bottom: none; }

.controls-cluster {
  display: flex;
  align-items: center;
  gap: 5px;
}
.btn-group { display: inline-flex; gap: 2px; }
.speed-btn.active {
  background: #0a3560;
  color: #57e8ff;
}

/* LEFT TOOL PALETTE */
.tool-palette {
  position: fixed;
  top: 52px;
  left: 8px;
  bottom: 34px;
  width: 176px;
  z-index: 15;
  display: flex;
  flex-direction: column;
  overflow-y: auto;
}
.tool-section {
  padding: 3px 5px 3px;
  border-bottom: 1px solid #9da5af;
}
.section-hdr {
  font-size: 8.5px;
  font-weight: 800;
  letter-spacing: 0.4px;
  color: #354150;
  margin-bottom: 2px;
  padding-left: 2px;
}
.ark-hdr { color: #6c1464; }
.tool-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3px;
}
.tool-btn {
  background: #d5dae0;
  border-top: 2px solid var(--win-light);
  border-left: 2px solid var(--win-light);
  border-right: 2px solid var(--win-darker);
  border-bottom: 2px solid var(--win-darker);
  padding: 2px 2px;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0px;
  line-height: 1.15;
  font-family: var(--font-ui);
  color: #101922;
}
.tool-btn:hover { background: #e1e6ec; }
.tool-btn.active {
  background: #0d2b45;
  color: #e9f9ff;
  border-top: 2px solid #04111c;
  border-left: 2px solid #04111c;
  border-right: 2px solid #57e8ff;
  border-bottom: 2px solid #57e8ff;
  box-shadow: inset 0 0 8px rgba(87, 232, 255, 0.35);
}
.tool-btn.active .t-cost { color: #ffcb52; }
.tool-btn.locked {
  opacity: 0.52;
  filter: grayscale(0.6);
}
.tool-btn.zone-r { border-left: 11px solid #2ab564; }
.tool-btn.zone-c { border-left: 11px solid #2b83e6; }
.tool-btn.zone-i { border-left: 11px solid #e0a61c; }
.t-ico { font-size: 13px; line-height: 1.05; }
.t-lbl { font-size: 9.5px; font-weight: 700; }
.t-cost { font-family: var(--font-mono); font-size: 8.5px; color: #404c5a; }

/* RIGHT DOCK */
.right-dock {
  position: fixed;
  top: 52px;
  right: 8px;
  width: 214px;
  z-index: 15;
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-height: calc(100vh - 88px);
  overflow-y: auto;
}
.hud-panel { width: 100%; }

.rci-panel {
  padding: 7px;
  display: flex;
  gap: 8px;
  align-items: stretch;
}
.rci-bars {
  display: flex;
  gap: 5px;
  background: #0c1720;
  padding: 6px 6px 4px;
  border: 2px inset #6b7480;
}
.rci-col {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
}
.rci-track {
  width: 14px;
  height: 76px;
  background: #172734;
  position: relative;
  overflow: hidden;
}
.rci-zero {
  position: absolute;
  top: 50%; left: 0; right: 0;
  height: 1px;
  background: rgba(255, 255, 255, 0.35);
}
.rci-fill {
  position: absolute;
  left: 1px; right: 1px;
  transition: top 0.25s, height 0.25s;
}
.rci-fill.res { background: #3ce67e; }
.rci-fill.com { background: #48a7ff; }
.rci-fill.ind { background: #ffbe3b; }
.rci-lbl { font-family: var(--font-mono); font-size: 10px; font-weight: 800; }
.rci-lbl.r { color: #3ce67e; }
.rci-lbl.c { color: #48a7ff; }
.rci-lbl.i { color: #ffbe3b; }

.telemetry-stats {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  font-size: 11px;
}
.stat-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px dotted #9aa3ae;
  padding: 1px 0;
}
.stat-row strong { font-family: var(--font-mono); font-size: 11px; color: #0f253a; }
.stat-row strong.ok { color: #0b6e3c; }
.stat-row strong.warn { color: #a15d00; }
.stat-row strong.bad { color: #b51f2d; }

/* Minimap + Wind */
.minimap-wrap {
  position: relative;
  padding: 6px 6px 4px;
  display: flex;
  justify-content: center;
}
#minimap-canvas {
  background: #081520;
  border: 2px inset #6b7480;
  cursor: pointer;
  display: block;
}
.wind-compass {
  position: absolute;
  right: 11px;
  bottom: 9px;
  background: rgba(7, 19, 29, 0.86);
  border: 1px solid #3d8ea8;
  color: #74f0ff;
  padding: 2px 5px;
  border-radius: 2px;
  display: flex;
  align-items: center;
  gap: 3px;
  font-family: var(--font-mono);
  font-size: 9px;
  pointer-events: auto;
}
.compass-arrow {
  display: inline-block;
  font-size: 12px;
  color: var(--phosphor-green);
  line-height: 1;
}

.heatmap-bar {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 2px;
  padding: 0 6px 6px;
}
.heatmap-bar-6 {
  grid-template-columns: repeat(6, 1fr);
}
.rd-mini {
  background: #0a1722;
  border-top: 1px solid #6b7480;
  padding: 5px 7px 6px;
  cursor: pointer;
}
.rd-mini:hover { background: #102436; }
.rd-mini-row {
  display: flex;
  justify-content: space-between;
  font-family: var(--font-mono);
  font-size: 9.5px;
  color: #79efff;
  margin-bottom: 3px;
}
.rd-mini-track {
  height: 7px;
  background: #172a3a;
  border: 1px solid #355770;
}
.rd-mini-fill {
  height: 100%;
  background: linear-gradient(90deg, #2ac7ff, #4dff9b);
  transition: width 0.25s;
}

/* Tech Tree Modal */
.tech-modal-win { max-width: 780px; }
.tech-tier-hdr {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 800;
  color: #163a59;
  margin: 8px 0 5px;
  border-bottom: 1px solid #8c96a2;
  padding-bottom: 2px;
}
.tech-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}
.tech-card {
  background: #d8dee5;
  border: 2px solid #7f8a96;
  padding: 8px;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.tech-card:hover:not(.locked):not(.done):not(.active) { background: #e8f5ff; border-color: #126d9c; }
.tech-card.active {
  background: #0c263b;
  color: #e8fbff;
  border-color: #57e8ff;
  box-shadow: 0 0 10px rgba(87, 232, 255, 0.35);
}
.tech-card.done {
  background: #d2f0de;
  border-color: #1c854e;
}
.tech-card.locked {
  opacity: 0.55;
  cursor: not-allowed;
}
.tech-card-top {
  display: flex;
  justify-content: space-between;
  font-weight: 800;
  font-size: 11.5px;
}
.tech-card-desc { font-size: 10.5px; line-height: 1.35; opacity: 0.9; }
.tech-cost-pill {
  font-family: var(--font-mono);
  font-size: 10px;
  padding: 1px 4px;
  background: rgba(0,0,0,0.16);
}

/* Production Monitor */
.stats-modal-win { max-width: 680px; }
.spark-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}
.spark-card {
  background: #08151f;
  border: 2px inset #5e6d7a;
  padding: 8px;
  color: #b7ebff;
}
.spark-hdr {
  display: flex;
  justify-content: space-between;
  font-family: var(--font-mono);
  font-size: 11px;
  margin-bottom: 5px;
}
.spark-canvas { width: 100%; height: 90px; display: block; }
.hm-btn {
  background: #d5dae0;
  border: 1px outset #eef2f6;
  font-family: var(--font-mono);
  font-size: 9px;
  font-weight: 700;
  padding: 3px 1px;
  cursor: pointer;
}
.hm-btn.active {
  background: #0b3453;
  color: #57e8ff;
  border: 1px inset #051624;
}

/* PROJECT ARK TRACKER */
.ark-body { padding: 7px; }
.ark-progress-bar {
  position: relative;
  height: 18px;
  background: #140b1d;
  border: 2px inset #5e4469;
  margin-bottom: 6px;
  overflow: hidden;
}
.ark-progress-fill {
  height: 100%;
  background: linear-gradient(90deg, #982491, #ff54d1, #57e8ff);
  transition: width 0.35s;
}
.ark-progress-txt {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-mono);
  font-size: 9px;
  font-weight: 800;
  color: #ffffff;
  text-shadow: 0 1px 2px #000;
}
.ark-checklist {
  list-style: none;
  margin: 0 0 7px;
  padding: 0;
  font-size: 10.5px;
  line-height: 1.45;
}
.ark-checklist li.done {
  color: #0d683b;
  font-weight: 700;
}
.launch-btn {
  width: 100%;
  padding: 6px;
  font-size: 11px;
  letter-spacing: 0.5px;
}
.launch-btn.ready {
  background: linear-gradient(90deg, #b81d7b, #ea4c89);
  color: #fff;
  animation: pulse-launch 1.3s infinite;
}
@keyframes pulse-launch {
  0%,100% { box-shadow: 0 0 6px #ff5de0; }
  50% { box-shadow: 0 0 16px #57e8ff; }
}

/* QUERY INSPECTOR */
.floating-win {
  position: fixed;
  left: 194px;
  bottom: 36px;
  width: 280px;
  z-index: 18;
}
.query-body {
  padding: 8px;
  font-size: 11.5px;
  line-height: 1.45;
}
.q-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 5px;
  padding-bottom: 4px;
  border-bottom: 1px solid #8f98a3;
}
.q-name { font-weight: 800; font-size: 13px; color: #0a2b4a; }
.q-badge {
  font-family: var(--font-mono);
  font-size: 10px;
  padding: 1px 5px;
  background: #0d2b45;
  color: #57e8ff;
}
.q-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3px 8px;
  margin-bottom: 6px;
  font-family: var(--font-mono);
  font-size: 10.5px;
}
.q-diag {
  background: #0a1722;
  color: #c8f3ff;
  padding: 5px 7px;
  border: 1px inset #5e6a77;
  font-family: var(--font-mono);
  font-size: 10.5px;
}
.q-diag.good { color: #5effa5; }
.q-diag.warn { color: #ffd15c; }

/* TICKER */
.ticker-bar {
  position: fixed;
  left: 0; right: 0; bottom: 0;
  height: 26px;
  z-index: 20;
  padding: 0 8px;
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 11px;
}
.ticker-badge {
  background: #10202e;
  color: var(--phosphor-amber);
  font-family: var(--font-mono);
  font-weight: 800;
  font-size: 10px;
  padding: 2px 6px;
  white-space: nowrap;
}
.ticker-text {
  flex: 1;
  font-family: var(--font-mono);
  font-size: 11px;
  color: #112233;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.ticker-controls-hint {
  font-family: var(--font-mono);
  font-size: 10px;
  color: #465363;
  white-space: nowrap;
}

/* CURSOR TOOLTIP */
.cursor-tooltip {
  position: fixed;
  z-index: 30;
  pointer-events: none;
  background: rgba(8, 20, 30, 0.92);
  color: #77f6ff;
  border: 1px solid #3ea8c4;
  padding: 3px 7px;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
  box-shadow: 0 2px 8px rgba(0,0,0,0.45);
}
.cursor-tooltip.bad { color: #ff7c88; border-color: #ff5d6c; }

/* MODALS */
.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 50;
  background: rgba(5, 13, 22, 0.72);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
}
.hidden { display: none !important; }
.modal-win {
  max-width: 720px;
  width: 100%;
  max-height: 92vh;
  overflow-y: auto;
}
.budget-modal-win { max-width: 480px; }
.finale-modal-win { max-width: 540px; }
.modal-body { padding: 14px; }

.hero-banner {
  background: linear-gradient(135deg, #071928, #102f46 60%, #2a1440);
  border: 2px inset #5c6a78;
  padding: 14px 16px;
  margin-bottom: 12px;
  text-align: center;
}
.hero-logo {
  font-family: var(--font-mono);
  font-size: 24px;
  font-weight: 900;
  letter-spacing: 2px;
  color: var(--phosphor-green);
  text-shadow: 0 0 12px rgba(77,255,155,0.45);
}
.hero-96 { color: var(--phosphor-amber); }
.hero-sub {
  font-family: var(--font-mono);
  font-size: 10px;
  color: #9de8ff;
  letter-spacing: 1px;
  margin-top: 4px;
}

.start-cols {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 14px;
}
.start-col h3 {
  margin: 0 0 8px;
  font-size: 11px;
  letter-spacing: 0.6px;
  color: #16334d;
  border-bottom: 1px solid #96a0ab;
  padding-bottom: 3px;
}
.mode-card {
  display: flex;
  gap: 8px;
  align-items: flex-start;
  background: #d8dde3;
  border: 2px solid #8a94a0;
  padding: 9px;
  margin-bottom: 8px;
  cursor: pointer;
}
.mode-card.selected {
  background: #e9f6ff;
  border-color: #0e639c;
  box-shadow: inset 0 0 0 1px #0e639c;
}
.mode-card strong { display: block; font-size: 12px; margin-bottom: 3px; color: #0c2338; }
.mode-card p { margin: 0; font-size: 11px; color: #2f3c4a; line-height: 1.4; }

.form-row {
  margin-bottom: 8px;
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.form-row label { font-weight: 700; font-size: 11px; color: #243242; }
.form-row input, .form-row select {
  padding: 5px 7px;
  border: 2px inset #8c959f;
  background: #fff;
  font-family: var(--font-mono);
  font-size: 12px;
}
.seed-row { display: flex; gap: 6px; }
.seed-row input { flex: 1; }
.start-actions { margin: 10px 0 12px; }
.start-actions .primary-btn { width: 100%; }

.save-box {
  background: #b9c0c8;
  border: 1px solid #7d8793;
  padding: 8px;
}
.save-box-hdr { font-weight: 800; font-size: 10px; margin-bottom: 6px; color: #1f2d3c; }
.save-btn-row { display: grid; grid-template-columns: 1fr 1fr; gap: 5px; margin-bottom: 6px; }
.save-status { font-family: var(--font-mono); font-size: 10px; color: #223446; }

/* Budget Table */
.budget-table {
  width: 100%;
  border-collapse: collapse;
  font-family: var(--font-mono);
  font-size: 12px;
  margin-bottom: 10px;
}
.budget-table td {
  padding: 4px 6px;
  border-bottom: 1px dotted #919aa5;
}
.budget-table td:last-child { text-align: right; font-weight: 700; }
.budget-total td {
  border-top: 2px solid #2b3847;
  border-bottom: none;
  font-weight: 800;
  font-size: 13px;
}
.tax-slider-box {
  background: #d5dce3;
  border: 1px solid #8a95a1;
  padding: 9px;
  margin-bottom: 10px;
}
.tax-slider-box input[type="range"] { width: 100%; }
.finale-grade {
  font-family: var(--font-mono);
  font-size: 46px;
  font-weight: 900;
  text-align: center;
  color: var(--phosphor-green);
  background: #081724;
  border: 2px inset #506172;
  padding: 12px;
  margin-bottom: 10px;
  text-shadow: 0 0 14px rgba(77,255,155,0.55);
}

@media (max-width: 1440px) {
  .mode-pill, .brand-badge { display: none; }
  .city-name-display { max-width: 105px; font-size: 11.5px; }
  .win-btn { padding: 3px 5px; font-size: 10.5px; }
  .top-bar { gap: 4px; padding: 3px 5px; }
}
@media (max-width: 1140px) {
  .ticker-controls-hint, .brand-cluster { display: none; }
  .lcd-box { min-width: 54px; padding: 2px 4px; }
  .lcd-val { font-size: 11px; }
  .tool-palette { width: 152px; }
  .right-dock { width: 196px; }
  .start-cols { grid-template-columns: 1fr; }
}
