#hud { position: fixed; top: 0; left: 0; pointer-events: none; z-index: 10; padding: 8px; font-size: 11px; display: flex; flex-direction: column; gap: 2px; max-width: 500px; }
#hud span { color: #0c0; text-shadow: 0 0 4px #0f0; }
#hud .sel { color: #0ff; }
#hud .dbg { color: #080; font-size: 10px; }
#minimap {
  position: fixed; bottom: 10px; right: 10px; z-index: 10;
  border: 1px solid #0a0; background: rgba(0,0,0,0.6); border-radius: 4px;
}
#minimap-canvas { display: block; }
#panel {
  position: fixed; top: 50px; right: 10px; z-index: 10;
  background: rgba(0,10,0,0.8); border: 1px solid #0a0;
  padding: 10px; width: 250px; font-size: 11px; border-radius: 4px;
  pointer-events: auto;
}
#panel.hidden { display: none; }
#panel h3 { color: #0f0; margin-bottom: 6px; font-size: 13px; }
#panel p { color: #0a0; margin: 2px 0; }
.label-3d {
  font-family: 'Courier New', monospace;
  font-size: 11px;
  text-shadow: 0 0 4px currentColor, 0 0 8px rgba(0,0,0,0.8);
  white-space: nowrap;
  pointer-events: none;
  text-align: center;
}
.label-npc {
  font-size: 10px;
  color: #0f0;
  line-height: 1.3;
  text-shadow: 0 0 4px #0f0, 0 0 8px rgba(0,0,0,0.9);
}
.label-asteroid {
  font-size: 10px;
  line-height: 1.4;
  text-shadow: 0 0 4px #aa9966, 0 0 8px rgba(0,0,0,0.9);
  background: rgba(0,0,0,0.5);
  padding: 3px 6px;
  border: 1px solid rgba(170,153,102,0.3);
  border-radius: 3px;
}
.label-nebula {
  font-size: 13px;
  font-style: italic;
  opacity: 0.7;
}

/* ─── COMBAT HUD (Elite-style) ────────────────────── */
#combat-hud {
  position: fixed; bottom: 10px; left: 10px; z-index: 10;
  background: rgba(0,5,0,0.85); border: 1px solid #0a0;
  padding: 8px; width: 260px; font-size: 11px;
  border-radius: 4px; pointer-events: none;
  font-family: 'Courier New', monospace;
}
#combat-hud .ship-name { color: #0f0; font-size: 12px; font-weight: bold; margin-bottom: 4px; text-align: center; }
#combat-hud .bar-row { display: flex; align-items: center; gap: 4px; margin: 2px 0; color: #0a0; }
#combat-hud .bar-label { width: 18px; font-size: 10px; color: #0a0; text-align: right; }
#combat-hud .hbar { flex: 1; height: 8px; background: #111; border: 1px solid #040; }
#combat-hud .hbar-fill { height: 100%; transition: width 0.2s; }
#combat-hud .energy-row { display: flex; gap: 2px; margin: 3px 0; height: 30px; }
#combat-hud .ebank { flex: 1; }
#combat-hud .vbar { width: 100%; height: 100%; background: #111; border: 1px solid #040; display: flex; flex-direction: column-reverse; }
#combat-hud .vbar-fill { width: 100%; transition: height 0.2s; }
#combat-hud .info-row { color: #0a0; font-size: 10px; margin: 1px 0; }
#combat-hud .target { color: #f44; }
#combat-hud .docked { color: #0ff; }
#combat-hud .dock-range { color: #0ff; }
#combat-hud .dock-ready { background: rgba(0,255,255,0.15); border: 1px solid #0ff; padding: 0 4px; border-radius: 2px; animation: dock-blink 1.5s infinite; }
#combat-hud .dock-key { color: #0ff; font-weight: bold; }
#combat-hud .dock-approach { color: #086; font-size: 10px; }
#combat-hud .fa-on { color: #0a0; font-size: 10px; }
#combat-hud .fa-off { color: #f80; font-size: 10px; font-weight: bold; }
#combat-hud .autopilot { color: #0ff; font-size: 10px; font-weight: bold; animation: dock-blink 2s infinite; }
@keyframes dock-blink { 0%,100% { opacity: 1; } 50% { opacity: 0.5; } }

/* ─── TARGET PANEL (bottom center) ────────────── */
#target-panel {
  position: fixed; bottom: 10px; left: 50%; transform: translateX(-50%);
  z-index: 15; pointer-events: auto;
  background: rgba(0,5,0,0.85); border: 1px solid #0a0; border-radius: 4px;
  padding: 6px 10px; min-width: 320px; max-width: 500px;
  font-family: 'Courier New', monospace; font-size: 11px;
}
#target-panel:empty { display: none; }
.tp-row {
  display: flex; align-items: center; gap: 6px;
  padding: 3px 4px; border-bottom: 1px solid #020;
}
.tp-row:last-child { border-bottom: none; }
.tp-row.tp-active { background: rgba(0,255,255,0.08); border-color: #046; }
.tp-row.tp-selected { background: rgba(0,255,0,0.05); }
.tp-type {
  font-size: 9px; font-weight: bold; padding: 1px 4px;
  border: 1px solid; border-radius: 2px; min-width: 28px; text-align: center;
}
.tp-station { color: #0ff; border-color: #0aa; }
.tp-mine { color: #0ff; border-color: #0ff; background: rgba(0,255,255,0.15); }
.tp-row-mine { background: rgba(0,255,255,0.06); border-left: 2px solid #0ff; }
.tp-planet { color: #4d4; border-color: #282; }
.tp-star { color: #ff0; border-color: #aa0; }
.tp-other { color: #0a8; border-color: #064; }
.tp-name { color: #0c0; flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tp-dist { color: #086; min-width: 45px; text-align: right; font-size: 10px; }
.tp-btn {
  padding: 2px 8px; font-size: 10px; font-family: inherit; cursor: pointer;
  border-radius: 2px; border: 1px solid; background: transparent;
}
.tp-btn-ap { color: #0ff; border-color: #088; }
.tp-btn-ap:hover { background: rgba(0,255,255,0.15); border-color: #0ff; }
.tp-btn-dock { color: #0f0; border-color: #0a0; }
.tp-btn-dock:hover { background: rgba(0,255,0,0.15); border-color: #0f0; }
.tp-btn-goto { color: #fa0; border-color: #a80; }
.tp-btn-goto:hover { background: rgba(255,170,0,0.15); border-color: #fa0; }
.tp-btn-cancel { color: #f80; border-color: #a60; }
.tp-btn-cancel:hover { background: rgba(255,136,0,0.15); border-color: #f80; }
.tp-active .tp-name { color: #0ff; font-weight: bold; }
#combat-hud .credits { color: #ff0; }
#combat-hud .legal-offender { color: #ff8800; }
#combat-hud .legal-fugitive { color: #ff0000; }
#combat-hud .controls-hint { color: #040; font-size: 9px; margin-top: 6px; text-align: center; border-top: 1px solid #020; padding-top: 4px; }
#combat-hud .dev-btn { display: block; margin: 6px auto 0; padding: 4px 12px; background: rgba(255,0,255,0.15); border: 1px solid #f0f; color: #f0f; font-family: inherit; font-size: 10px; cursor: pointer; pointer-events: auto; }
#combat-hud .dev-btn:hover { background: rgba(255,0,255,0.3); }
#combat-hud .dim { color: #040; }
#combat-hud .cargo-gain { color: #0fa; font-weight: bold; text-shadow: 0 0 6px #0fa; animation: cargo-flash 0.6s ease-out; }
@keyframes cargo-flash { 0% { color: #fff; text-shadow: 0 0 12px #fff; } 100% { color: #0fa; text-shadow: 0 0 6px #0fa; } }
#hud .cmsg { color: #ff0; font-size: 12px; font-weight: bold; text-shadow: 0 0 8px #ff0; }

/* Gravity warnings */
.gravity-warning { font-size: 10px; padding: 2px 6px; margin: 2px 0; border-radius: 2px; font-weight: bold; text-align: center; }
.grav-detected { color: #ff0; border: 1px solid #660; background: rgba(60,60,0,0.3); }
.grav-strain { color: #f80; border: 1px solid #a60; background: rgba(80,40,0,0.3); animation: grav-pulse 2s infinite; }
.grav-critical { color: #f00; border: 1px solid #a00; background: rgba(80,0,0,0.4); animation: grav-pulse 0.5s infinite; }
.grav-impact { color: #fff; border: 1px solid #f00; background: rgba(150,0,0,0.5); animation: grav-pulse 0.2s infinite; }
@keyframes grav-pulse { 0%,100% { opacity: 1; } 50% { opacity: 0.6; } }

/* ─── STATION DASHBOARD ────────────────────────────── */
#station-dashboard {
  position: fixed; top: 0; left: 0; right: 0; bottom: 0; z-index: 20;
  background: rgba(0,5,0,0.95);
  font-family: 'Courier New', monospace;
  overflow-y: auto;
  display: none;
  padding: 20px;
}
#station-dashboard.active { display: block; }
#station-dashboard h1 { color: #0f0; font-size: 18px; text-align: center; margin-bottom: 10px; text-shadow: 0 0 8px #0f0; }
#station-dashboard h2 { color: #0c0; font-size: 14px; margin: 12px 0 6px; border-bottom: 1px solid #040; padding-bottom: 3px; }
#station-dashboard .grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; max-width: 1000px; margin: 0 auto; }
#station-dashboard .panel { background: rgba(0,10,0,0.8); border: 1px solid #0a0; padding: 10px; border-radius: 4px; }
#station-dashboard .panel-full { grid-column: 1 / -1; }
#station-dashboard table { width: 100%; border-collapse: collapse; font-size: 11px; }
#station-dashboard th { color: #0f0; text-align: left; padding: 3px 6px; border-bottom: 1px solid #040; }
#station-dashboard td { color: #0a0; padding: 3px 6px; }
#station-dashboard tr:hover td { background: rgba(0,40,0,0.3); }
#station-dashboard .val { color: #0f0; }
#station-dashboard .dim { color: #060; }
#station-dashboard .ceo { color: #0ff; }
#station-dashboard .bio { color: #0a8; font-style: italic; font-size: 10px; }
#station-dashboard .need-filled { color: #060; }
#station-dashboard .need-open { color: #0f0; font-weight: bold; }
#station-dashboard .money { color: #ff0; }
#station-dashboard .btn {
  display: inline-block; padding: 6px 16px; margin: 8px 4px;
  background: rgba(0,40,0,0.6); border: 1px solid #0a0; color: #0f0;
  cursor: pointer; font-family: inherit; font-size: 12px; border-radius: 3px;
  pointer-events: auto;
}
#station-dashboard .btn:hover { background: rgba(0,80,0,0.6); border-color: #0f0; }
#station-dashboard .btn-undock { border-color: #f80; color: #f80; }
#station-dashboard .btn-undock:hover { background: rgba(80,40,0,0.4); }
#station-dashboard .stat-row { display: flex; justify-content: space-between; margin: 2px 0; }
#station-dashboard .stat-label { color: #080; }
#station-dashboard .faction-card { margin: 6px 0; padding: 6px; background: rgba(0,15,0,0.5); border: 1px solid #040; border-radius: 3px; }
#station-dashboard .faction-name { color: #0ff; font-weight: bold; }
#station-dashboard .faction-type { color: #0a0; font-size: 10px; }
#station-dashboard .notes { color: #f80; font-size: 10px; margin: 2px 0; padding: 2px 4px; border-left: 2px solid #f80; background: rgba(255,136,0,0.05); }
/* header */
#station-dashboard .dash-header { text-align: center; margin-bottom: 16px; }
#station-dashboard .dash-subtitle { margin: 4px 0 8px; }
#station-dashboard h3 { color: #0a0; font-size: 11px; margin: 10px 0 4px; border-bottom: 1px solid #030; padding-bottom: 2px; }

/* bars */
#station-dashboard .bar-thin { height: 4px; background: #111; border-radius: 2px; overflow: hidden; margin: 2px 0 4px; }
#station-dashboard .bar-fill-green { height: 100%; background: #0a0; border-radius: 2px; transition: width 0.3s; }
#station-dashboard .bar-fill-cyan { height: 100%; background: #0af; border-radius: 2px; transition: width 0.3s; }

/* fitting level dots */
#station-dashboard .fit-lvl { font-family: monospace; color: #0f0; letter-spacing: 1px; }

/* work orders */
#station-dashboard .wo-card { margin: 8px 0; padding: 10px; background: rgba(0,15,30,0.5); border: 1px solid #08a; border-radius: 3px; }
#station-dashboard .wo-card.in_progress { border-color: #0af; box-shadow: 0 0 6px rgba(0,170,255,0.15); }
#station-dashboard .wo-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 4px; }
#station-dashboard .wo-title { color: #0af; font-weight: bold; font-size: 12px; }
#station-dashboard .wo-status { font-size: 10px; padding: 1px 6px; border-radius: 2px; }
#station-dashboard .wo-status.open { color: #ff0; border: 1px solid #ff0; }
#station-dashboard .wo-status.in_progress { color: #0af; border: 1px solid #0af; }
#station-dashboard .wo-reqs { margin-top: 6px; }
#station-dashboard .wo-req { display: flex; align-items: center; gap: 6px; font-size: 10px; margin: 2px 0; }
#station-dashboard .wo-done { color: #0f0; text-decoration: line-through; }
#station-dashboard .wo-bar { flex: 1; height: 6px; background: #030; border-radius: 2px; overflow: hidden; min-width: 40px; }
#station-dashboard .wo-bar-fill { height: 100%; border-radius: 2px; transition: width 0.3s; }

/* upgrade catalog */
#station-dashboard .up-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 10px; }
#station-dashboard .up-card { padding: 10px; background: rgba(20,10,0,0.5); border: 1px solid #a60; border-radius: 3px; }
#station-dashboard .up-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 4px; }
#station-dashboard .up-title { color: #fa0; font-weight: bold; font-size: 12px; }
#station-dashboard .up-cost { color: #ff0; font-weight: bold; font-size: 12px; }
#station-dashboard .up-meta { margin: 4px 0; font-size: 10px; display: flex; justify-content: space-between; }
#station-dashboard .up-reqs { margin-top: 6px; font-size: 10px; }
#station-dashboard .up-req-header { display: flex; gap: 6px; color: #080; border-bottom: 1px solid #030; padding-bottom: 2px; margin-bottom: 2px; }
#station-dashboard .up-req-header span:first-child { flex: 1; }
#station-dashboard .up-req { display: flex; gap: 6px; margin: 1px 0; }
#station-dashboard .up-req span:first-child { flex: 1; }

/* marketplace supply/demand colors */
#station-dashboard .market-surplus { color: #080; }
#station-dashboard .market-scarce { color: #f80; font-weight: bold; }

/* faction inventory */
#station-dashboard .faction-inv { margin: 3px 0; padding: 2px 0; border-top: 1px solid #030; }
#station-dashboard .faction-inv-item { display: inline-block; margin: 1px 6px 1px 0; font-size: 10px; color: #0a8; }

/* work order type badge */
#station-dashboard .wo-type { font-size: 9px; padding: 1px 4px; border-radius: 2px; color: #0a0; border: 1px solid #040; margin-left: 4px; }

/* station properties */
#station-dashboard .prop-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 8px; }
#station-dashboard .prop-cat { margin-bottom: 4px; }
#station-dashboard .prop-cat-header { padding: 2px 6px; display: flex; align-items: center; gap: 6px; margin-bottom: 3px; }
#station-dashboard .prop-cat-icon { font-size: 9px; font-weight: bold; }
#station-dashboard .prop-cat-name { font-size: 11px; color: #aaa; font-weight: bold; }
#station-dashboard .prop-row { display: flex; align-items: center; gap: 4px; font-size: 10px; padding: 1px 6px; }
#station-dashboard .prop-name { color: #888; flex: 1; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
#station-dashboard .prop-val { color: #0f0; white-space: nowrap; min-width: 50px; text-align: right; }
#station-dashboard .prop-bar { width: 40px; height: 4px; background: #222; border-radius: 2px; flex-shrink: 0; }
#station-dashboard .prop-bar-fill { height: 100%; border-radius: 2px; transition: width 0.3s; }

/* station event log */
#station-dashboard .station-log { grid-column: 1 / -1; }
#station-dashboard .log-scroll { max-height: 400px; overflow-y: auto; }
#station-dashboard .log-scroll::-webkit-scrollbar { width: 4px; }
#station-dashboard .log-scroll::-webkit-scrollbar-thumb { background: #0a0; border-radius: 2px; }
#station-dashboard .log-time { white-space: nowrap; font-size: 10px; }
#station-dashboard .log-detail { font-size: 10px; word-break: break-word; white-space: normal; }
#station-dashboard .log-danger { color: #f44; font-weight: bold; }
#station-dashboard .log-good { color: #4f4; }
#station-dashboard .log-trade { color: #fc0; }
#station-dashboard .log-project { color: #0af; }
/* LOG tab szűrő gombok */
#station-dashboard .log-filters { margin-bottom: 8px; display: flex; gap: 4px; flex-wrap: wrap; }
/* LOG tab event type badge-ek */
#station-dashboard .log-type { font-size: 9px; padding: 1px 4px; border-radius: 2px; text-transform: uppercase; font-weight: bold; }
#station-dashboard .log-type-ceo { color: #0c0; border: 1px solid #060; }
#station-dashboard .log-type-trade { color: #fc0; border: 1px solid #860; }
#station-dashboard .log-type-economy { color: #0af; border: 1px solid #046; }
#station-dashboard .log-type-faction { color: #f80; border: 1px solid #840; }
#station-dashboard .log-type-system { color: #888; border: 1px solid #444; }
#station-dashboard .log-type-combat { color: #f44; border: 1px solid #800; }

/* quest board */
#station-dashboard .panel-quest { border-color: #fa0; box-shadow: 0 0 8px rgba(255,170,0,0.1); grid-column: 1 / -1; }
#station-dashboard .panel-quest h3 { color: #fa0; border-bottom-color: #530; }
#station-dashboard .quest-section { margin: 8px 0; }
#station-dashboard .quest-section-title { color: #f80; font-size: 10px; font-weight: bold; margin-bottom: 6px; border-bottom: 1px solid #330; padding-bottom: 2px; }
#station-dashboard .quest-card { padding: 10px; margin: 6px 0; background: rgba(30,15,0,0.5); border: 1px solid #530; border-radius: 3px; }
#station-dashboard .quest-card.quest-completable { border-color: #0f0; box-shadow: 0 0 8px rgba(0,255,0,0.15); }
#station-dashboard .quest-card.quest-available { border-color: #860; }
#station-dashboard .quest-title { color: #fa0; font-weight: bold; font-size: 13px; margin-bottom: 4px; }
#station-dashboard .quest-desc { color: #a80; font-size: 10px; margin-bottom: 6px; line-height: 1.4; }
#station-dashboard .quest-reward { color: #ff0; font-size: 11px; margin-bottom: 4px; }
#station-dashboard .quest-objectives { margin: 6px 0; }
#station-dashboard .quest-obj { color: #ca8; font-size: 11px; padding: 2px 0; }
#station-dashboard .quest-obj.obj-done { color: #0a0; text-decoration: line-through; opacity: 0.7; }
#station-dashboard .btn-quest-accept { border-color: #fa0; color: #fa0; }
#station-dashboard .btn-quest-accept:hover { background: rgba(80,40,0,0.4); }
#station-dashboard .btn-quest-complete { border-color: #0f0; color: #0f0; font-weight: bold; }
#station-dashboard .btn-quest-complete:hover { background: rgba(0,80,0,0.4); }

/* quest waypoint label in space */
.label-quest {
  font-size: 12px;
  font-weight: bold;
  color: #fa0;
  text-shadow: 0 0 8px #fa0, 0 0 16px rgba(255,170,0,0.5);
  background: rgba(40,20,0,0.7);
  padding: 4px 10px;
  border: 1px solid #fa0;
  border-radius: 3px;
  pointer-events: none;
  text-align: center;
  animation: quest-pulse 2s ease-in-out infinite;
}
.label-quest .quest-wp-title { font-size: 10px; color: #fc8; margin-top: 2px; font-weight: normal; }
.label-quest .quest-wp-dist { font-size: 9px; color: #a80; margin-top: 1px; opacity: 0.8; }
@keyframes quest-pulse { 0%,100% { opacity: 1; } 50% { opacity: 0.7; } }

/* player ship panel */
#station-dashboard .player-panel { border-color: #0f0; box-shadow: 0 0 8px rgba(0,255,0,0.1); }
#station-dashboard .bar-row { display: flex; align-items: center; gap: 4px; margin: 2px 0; }
#station-dashboard .bar-lbl { width: 30px; font-size: 10px; color: #080; text-align: right; }
#station-dashboard .flex-bar { flex: 1; }
#station-dashboard .bar-val { width: 70px; font-size: 10px; color: #0a0; text-align: right; }
#station-dashboard .ship-actions { display: flex; gap: 4px; margin: 6px 0; flex-wrap: wrap; }
#station-dashboard .btn-sm { padding: 3px 8px; font-size: 10px; }
#station-dashboard .btn-xs { padding: 2px 6px; font-size: 9px; }
#station-dashboard .btn-sell { border-color: #f80; color: #f80; }
#station-dashboard .btn-sell:hover { background: rgba(80,40,0,0.4); }
#station-dashboard .btn-buy { border-color: #0af; color: #0af; }
#station-dashboard .btn-buy:hover { background: rgba(0,40,80,0.4); }
#station-dashboard .equip-tag { display: inline-block; padding: 1px 5px; margin: 1px 2px; font-size: 9px; color: #0af; border: 1px solid #046; border-radius: 2px; }
#station-dashboard .equip-list { margin: 4px 0; }

/* ship fitting */
#station-dashboard .fit-grid { display: flex; flex-direction: column; gap: 4px; }
#station-dashboard .fit-item { display: flex; align-items: center; gap: 6px; padding: 3px 6px; font-size: 10px; background: rgba(0,10,0,0.5); border: 1px solid #030; border-radius: 2px; }
#station-dashboard .fit-item.equipped { border-color: #0a0; background: rgba(0,20,0,0.6); }
#station-dashboard .fit-name { color: #0c0; min-width: 90px; }

/* ─── SHOP CARDS (weapon & equipment) ──────────────────── */
#station-dashboard .shop-grid {
  display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px;
}
#station-dashboard .shop-card {
  display: flex; gap: 10px; padding: 10px;
  background: rgba(0,8,20,0.6); border: 1px solid #134; border-radius: 4px;
  transition: border-color 0.2s;
}
#station-dashboard .shop-card:hover { border-color: #0af; }
#station-dashboard .shop-card-equipped { border-color: #0a0; background: rgba(0,20,10,0.5); }
#station-dashboard .shop-card-locked { opacity: 0.5; }
#station-dashboard .shop-card-locked:hover { border-color: #f44; }
#station-dashboard .shop-card-img {
  flex: 0 0 64px; width: 64px; height: 64px;
  background: rgba(0,10,30,0.5); border: 1px solid #123; border-radius: 3px;
  display: flex; align-items: center; justify-content: center;
}
.shop-weapon-svg, .shop-equip-svg { width: 48px; height: 48px; }
#station-dashboard .shop-card-body { flex: 1; min-width: 0; }
#station-dashboard .shop-card-name {
  color: #0cf; font-size: 11px; font-weight: bold; text-transform: uppercase;
  margin-bottom: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
#station-dashboard .shop-card-desc { color: #068; font-size: 9px; line-height: 1.3; margin-bottom: 4px; }
#station-dashboard .shop-card-stats {
  display: flex; gap: 8px; font-size: 9px; color: #0a0; margin-bottom: 4px; flex-wrap: wrap;
}
#station-dashboard .shop-card-stats span { white-space: nowrap; }
#station-dashboard .shop-card-price { color: #ff0; font-size: 11px; font-weight: bold; margin-bottom: 4px; }
#station-dashboard .shop-status { font-size: 9px; padding: 2px 6px; border-radius: 2px; text-align: center; }
#station-dashboard .shop-equipped { color: #0f0; border: 1px solid #0a0; background: rgba(0,40,0,0.3); }
#station-dashboard .shop-incompatible { color: #f44; border: 1px solid #a00; background: rgba(40,0,0,0.3); font-size: 8px; }
#station-dashboard .shop-noslot { color: #888; border: 1px solid #444; background: rgba(20,20,20,0.3); }
#station-dashboard .shop-actions { display: flex; gap: 4px; }
#station-dashboard .btn-disabled { opacity: 0.3; cursor: not-allowed; }

/* ─── SHIPYARD (ship cards, 2 per row) ─────────────────── */
#station-dashboard .shipyard-grid {
  display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px;
}
#station-dashboard .shipyard-card {
  display: flex; gap: 10px; padding: 10px;
  background: rgba(0,8,20,0.6); border: 1px solid #134; border-radius: 4px;
  transition: border-color 0.2s;
}
#station-dashboard .shipyard-card:hover { border-color: #0af; }
#station-dashboard .shipyard-current { border-color: #0f0; box-shadow: 0 0 8px rgba(0,255,0,0.15); }
#station-dashboard .shipyard-card-visual {
  flex: 0 0 120px; width: 120px; position: relative;
  background: rgba(0,10,30,0.4); border: 1px solid #123; border-radius: 3px;
  display: flex; align-items: center; justify-content: center; min-height: 90px;
}
.ship-sil-svg { width: 100px; height: 70px; }
#station-dashboard .shipyard-badge-current {
  position: absolute; top: 4px; right: 4px;
  font-size: 8px; font-weight: bold; color: #0f0;
  padding: 1px 4px; border: 1px solid #0a0; border-radius: 2px;
  background: rgba(0,40,0,0.6);
}
#station-dashboard .shipyard-card-info { flex: 1; min-width: 0; }
#station-dashboard .shipyard-card-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 2px; }
#station-dashboard .shipyard-card-name { color: #0af; font-weight: bold; font-size: 13px; }
#station-dashboard .shipyard-card-role { font-size: 9px; color: #086; border: 1px solid #046; padding: 1px 5px; border-radius: 2px; }
#station-dashboard .shipyard-card-price { color: #ff0; font-size: 12px; font-weight: bold; margin-bottom: 4px; }

/* ─── LOGIN SCREEN ─────────────────────────────────────────── */
#login-screen {
  position: fixed; top: 0; left: 0; right: 0; bottom: 0;
  z-index: 100;
  background: rgba(0, 5, 0, 0.75);
  display: flex; align-items: center; justify-content: center;
  font-family: 'Courier New', monospace;
}
#login-screen .login-box {
  background: rgba(0, 10, 0, 0.92);
  border: 1px solid #0a0;
  border-radius: 6px;
  padding: 32px 36px;
  min-width: 320px;
  max-width: 400px;
  box-shadow: 0 0 40px rgba(0, 255, 0, 0.08), inset 0 0 60px rgba(0, 20, 0, 0.3);
}
#login-screen .login-title {
  color: #0f0;
  font-size: 18px;
  font-weight: bold;
  text-align: center;
  margin-bottom: 4px;
  text-shadow: 0 0 8px #0f0;
  letter-spacing: 2px;
}
#login-screen .login-subtitle {
  color: #060;
  font-size: 10px;
  text-align: center;
  margin-bottom: 24px;
  letter-spacing: 1px;
}
#login-screen .login-field {
  margin-bottom: 14px;
}
#login-screen .login-field label {
  display: block;
  color: #080;
  font-size: 10px;
  margin-bottom: 4px;
  letter-spacing: 1px;
}
#login-screen .login-field input {
  width: 100%;
  padding: 8px 10px;
  background: rgba(0, 15, 0, 0.6);
  border: 1px solid #040;
  color: #0f0;
  font-family: 'Courier New', monospace;
  font-size: 13px;
  border-radius: 3px;
  outline: none;
  box-sizing: border-box;
}
#login-screen .login-field input:focus {
  border-color: #0a0;
  box-shadow: 0 0 6px rgba(0, 255, 0, 0.2);
}
#login-screen .login-error {
  color: #f44;
  font-size: 11px;
  min-height: 16px;
  margin-bottom: 8px;
  text-align: center;
  text-shadow: 0 0 4px #f00;
}
#login-screen .login-btn {
  display: block;
  width: 100%;
  padding: 10px;
  background: rgba(0, 40, 0, 0.6);
  border: 1px solid #0a0;
  color: #0f0;
  font-family: 'Courier New', monospace;
  font-size: 14px;
  font-weight: bold;
  cursor: pointer;
  border-radius: 3px;
  letter-spacing: 2px;
  text-shadow: 0 0 6px #0f0;
}
#login-screen .login-btn:hover {
  background: rgba(0, 80, 0, 0.6);
  border-color: #0f0;
}
#login-screen .login-btn:disabled {
  opacity: 0.5;
  cursor: default;
}
#login-screen .login-toggle {
  text-align: center;
  margin-top: 16px;
  color: #060;
  font-size: 11px;
}
#login-screen .login-toggle a {
  color: #0f0;
  text-decoration: none;
  cursor: pointer;
}
#login-screen .login-toggle a:hover {
  text-shadow: 0 0 6px #0f0;
}

/* ─── PLAYER SHIP LABELS (multiplayer) ──────────────────────── */
.label-player {
  font-size: 10px;
  color: #0ff;
  line-height: 1.3;
  text-shadow: 0 0 4px #0ff, 0 0 8px rgba(0,0,0,0.9);
}

/* ─── STATION DASHBOARD TABS ───────────────────────────────── */
#station-dashboard .tab-bar { display: flex; gap: 2px; justify-content: center; margin: 8px 0; flex-wrap: wrap; }
#station-dashboard .tab-btn { padding: 6px 14px; background: rgba(0,20,0,0.6); border: 1px solid #040; color: #080; cursor: pointer; font-family: inherit; font-size: 11px; pointer-events: auto; }
#station-dashboard .tab-btn:hover { border-color: #0a0; color: #0a0; }
#station-dashboard .tab-btn.active { border-color: #0f0; color: #0f0; background: rgba(0,40,0,0.6); }

/* ─── SHIP SCHEMATIC ──────────────────────────────────────── */
.ship-tab-layout { display: flex; gap: 20px; align-items: flex-start; }
.ship-tab-left { flex: 0 0 280px; }
.ship-tab-right { flex: 1; min-width: 200px; }
.ship-schematic {
  position: relative; width: 260px; height: 360px;
  border: 1px solid #040; background: rgba(0,10,0,0.4); border-radius: 4px;
  margin: 0 auto;
}
.sch-svg { width: 100%; height: 100%; }
.sch-slot-weapon, .sch-slot-equip {
  position: absolute; transform: translate(-50%, -50%);
  font-size: 9px; font-family: inherit; text-align: center;
  padding: 2px 4px; border-radius: 3px; white-space: nowrap;
  pointer-events: auto; cursor: default;
}
.sch-slot-weapon { border: 1px solid #f44; background: rgba(60,0,0,0.7); }
.sch-slot-weapon.filled { border-color: #f80; background: rgba(80,30,0,0.7); }
.sch-slot-equip { border: 1px solid #08f; background: rgba(0,0,40,0.7); }
.sch-slot-equip.filled { border-color: #0ff; background: rgba(0,30,60,0.7); }
.sch-slot-weapon.empty, .sch-slot-equip.empty { opacity: 0.5; }
.sch-slot-icon { display: block; font-weight: bold; color: #fff; font-size: 8px; }
.sch-slot-name { display: block; color: #aaa; font-size: 8px; max-width: 70px; overflow: hidden; text-overflow: ellipsis; }
.sch-slot-weapon.filled .sch-slot-name { color: #f80; }
.sch-slot-equip.filled .sch-slot-name { color: #0ff; }
.sch-missiles { position: absolute; bottom: 4px; left: 50%; transform: translateX(-50%); font-size: 10px; color: #f80; white-space: nowrap; }

/* ─── MAP ─────────────────────────────────────────────────── */
.map-section { margin-bottom: 10px; }
.map-type-header { font-size: 12px; font-weight: bold; margin-bottom: 4px; padding: 2px 6px; border-bottom: 1px solid #040; }

/* ─── RESEARCH & DEVELOPMENT ──────────────────────────────── */
.rd-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 8px; }
.rd-card { border: 1px solid #040; background: rgba(0,10,0,0.4); padding: 10px; border-radius: 4px; }
.rd-card.rd-locked { opacity: 0.6; }
.rd-card.rd-available { border-color: #0f0; }
.rd-card.rd-researching { border-color: #ff0; }
.rd-title { color: #0f0; font-size: 12px; font-weight: bold; margin-bottom: 4px; }
.rd-locked .rd-title { color: #080; }
.rd-desc { font-size: 10px; margin-bottom: 4px; }
.rd-cost { font-size: 10px; margin-bottom: 4px; }
.rd-status { font-size: 9px; border-top: 1px solid #030; padding-top: 4px; margin-top: 4px; }

/* ─── ORBITAL MAP ─────────────────────────────────────────── */
.orbital-map { width: 100%; background: rgba(0,5,15,0.6); border: 1px solid #123; border-radius: 4px; margin-bottom: 10px; overflow: hidden; }
.orbital-map-svg { width: 100%; height: auto; display: block; }

/* ─── SHIP SPECS GRID ─────────────────────────────────────── */
.ship-specs-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 8px; margin-top: 10px; padding-top: 10px; border-top: 1px solid #040; }
.ship-spec-section { }
.ship-spec-section h3 { margin-bottom: 4px; font-size: 11px; }
.ship-spec-table { width: 100%; font-size: 10px; border-collapse: collapse; }
.ship-spec-table td { padding: 1px 4px; }
.ship-spec-table td.dim { color: #080; }
.ship-spec-table td.val { color: #0f0; }

.map-fuel-bar { display: flex; align-items: center; gap: 6px; padding: 6px 10px; font-size: 11px; border-top: 1px solid #123; }

/* ─── CORP MANAGEMENT PANEL ──────────────────────────────── */
#station-dashboard .corp-header { display: flex; justify-content: space-between; align-items: center; }
#station-dashboard .corp-name-row { margin: 4px 0 10px; display: flex; align-items: center; gap: 8px; }
#station-dashboard .corp-big-name { color: #0ff; font-size: 16px; font-weight: bold; text-shadow: 0 0 8px rgba(0,255,255,0.3); }
#station-dashboard .corp-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
#station-dashboard .corp-col { display: flex; flex-direction: column; gap: 8px; }
#station-dashboard .corp-section { background: rgba(0,10,20,0.4); border: 1px solid #134; border-radius: 4px; padding: 8px; }
#station-dashboard .corp-section h3 { color: #0af; border-bottom-color: #134; }
#station-dashboard .corp-actions { display: flex; gap: 4px; flex-wrap: wrap; margin-top: 6px; }
#station-dashboard .corp-at-home { margin-top: 10px; padding: 6px 10px; border-top: 1px solid #134; text-align: center; font-size: 11px; }

/* ─── PLATFORM DEPLOY INFO ────────────────────────────────── */
.platform-info-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 8px; }
.platform-info-card { border: 1px solid #040; background: rgba(0,15,0,0.4); padding: 10px; border-radius: 4px; }
.platform-info-card:hover { border-color: #0a0; }
.platform-info-title { color: #0f0; font-size: 12px; font-weight: bold; margin-bottom: 4px; }
.platform-info-card p { font-size: 10px; line-height: 1.4; }

/* ─── CHAT TAB ───────────────────────────────────────────── */
#station-dashboard .chat-scroll {
  max-height: 600px; overflow-y: auto; padding: 8px;
  background: rgba(0,5,10,0.5); border: 1px solid #134; border-radius: 4px;
  margin-bottom: 8px;
}
#station-dashboard .chat-scroll::-webkit-scrollbar { width: 4px; }
#station-dashboard .chat-scroll::-webkit-scrollbar-thumb { background: #0af; border-radius: 2px; }
#station-dashboard .chat-msg { margin: 6px 0; padding: 4px 8px; border-radius: 4px; }
#station-dashboard .chat-player { background: rgba(0,40,0,0.3); border-left: 2px solid #0f0; }
#station-dashboard .chat-ceo { background: rgba(0,20,40,0.3); border-left: 2px solid #0cf; }
#station-dashboard .chat-npc { background: rgba(40,20,0,0.3); border-left: 2px solid #f80; }
#station-dashboard .chat-system { background: rgba(20,20,20,0.3); border-left: 2px solid #666; }
#station-dashboard .chat-badge { font-size: 8px; font-weight: bold; border: 1px solid currentColor; padding: 0 3px; border-radius: 2px; margin-right: 4px; }
#station-dashboard .chat-name { font-weight: bold; font-size: 10px; margin-right: 6px; }
#station-dashboard .chat-player .chat-name { color: #0f0; }
#station-dashboard .chat-ceo .chat-name { color: #0ff; }
#station-dashboard .chat-time { color: #060; font-size: 9px; }
#station-dashboard .chat-text { color: #0c0; font-size: 11px; margin-top: 2px; line-height: 1.4; white-space: normal; word-wrap: break-word; }
#station-dashboard .chat-ceo .chat-text { color: #0af; }
#station-dashboard .chat-input-row { display: flex; gap: 6px; align-items: center; }
#station-dashboard .chat-input {
  flex: 1; padding: 8px 10px; background: rgba(0,15,0,0.6);
  border: 1px solid #040; color: #0f0; font-family: 'Courier New', monospace;
  font-size: 12px; border-radius: 3px; outline: none;
}
#station-dashboard .chat-input:focus { border-color: #0a0; box-shadow: 0 0 6px rgba(0,255,0,0.2); }

/* ─── ROUTE HUD (autopilot2) ─────────────────────────────── */
#combat-hud .route-info { color: #ff0; font-size: 10px; font-weight: bold; border-top: 1px solid #330; padding-top: 3px; margin-top: 3px; }
#combat-hud .route-next { color: #0ff; font-size: 9px; }

/* ─── MINIMAP ZOOM ───────────────────────────────────────── */
#minimap { position: relative; }
.minimap-zoom-btn {
  position: absolute; z-index: 2; width: 20px; height: 20px;
  background: rgba(0,10,0,0.8); border: 1px solid #0a0; color: #0f0;
  font-family: 'Courier New', monospace; font-size: 14px; font-weight: bold;
  cursor: pointer; text-align: center; line-height: 18px; pointer-events: auto;
}
.minimap-zoom-btn:hover { background: rgba(0,40,0,0.8); border-color: #0f0; }
.minimap-zoom-in { right: 2px; top: 2px; }
.minimap-zoom-out { right: 2px; top: 24px; }
.minimap-zoom-level { position: absolute; right: 2px; top: 47px; color: #060; font-size: 8px; text-align: center; width: 20px; }

/* Route panel (MAP tab) */
.route-panel { border-radius: 4px; }
.route-wp-row { display: flex; align-items: center; font-size: 10px; padding: 2px 0; border-bottom: 1px solid rgba(255,255,0,0.1); }
.route-wp-active { background: rgba(0,255,255,0.08); }
.route-fuel { font-size: 10px; }
