html, body, #map, #deck-static, #deck {
  margin: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: #1f2933;
}

body {
  background: #eef2f5;
}

#map, #deck-static, #deck {
  position: absolute;
  inset: 0;
}

#map {
  z-index: 0;
  background: #e7edf2;
}

#map.map-disabled {
  background:
    linear-gradient(rgba(255, 255, 255, 0.18) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.18) 1px, transparent 1px),
    #dce6ee;
  background-size: 42px 42px;
}

#deck-static {
  z-index: 1;
  pointer-events: none;
}

#deck {
  z-index: 2;
}

#panel {
  position: absolute;
  z-index: 3;
  top: 18px;
  right: 18px;
  width: 420px;
  max-height: calc(100vh - 36px);
  padding: 14px 16px;
  overflow-y: auto;
  box-sizing: border-box;
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid rgba(40, 50, 65, 0.18);
  border-radius: 8px;
  box-shadow: 0 14px 38px rgba(20, 28, 38, 0.18);
}

.map-tooltip-title {
  font-weight: 700;
  margin-bottom: 3px;
}

h1 {
  margin: 0 0 8px;
  font-size: 18px;
  font-weight: 700;
}

#clock {
  font-size: 13px;
  margin-bottom: 10px;
}

#playbackControls {
  display: grid;
  grid-template-columns: 62px 1fr;
  align-items: center;
  gap: 10px;
  margin: 2px 0 10px;
}

#playPauseButton {
  height: 28px;
  border: 1px solid rgba(64, 91, 124, 0.34);
  border-radius: 6px;
  background: #405b7c;
  color: #ffffff;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
}

#playPauseButton.is-paused {
  background: #ffffff;
  color: #24313f;
}

.control-row {
  display: grid;
  grid-template-columns: auto 1fr 34px;
  align-items: center;
  gap: 10px;
  margin: 0;
  font-size: 12px;
  color: #4a5563;
}

.control-row input[type="range"] {
  width: 100%;
  accent-color: #405b7c;
}

.control-row b {
  color: #24313f;
  font-size: 12px;
  text-align: right;
}

.chart-tiles {
  display: grid;
  gap: 8px;
  margin: 10px 0 12px;
}

.chart-tile {
  overflow: hidden;
  background: rgba(245, 247, 250, 0.88);
  border: 1px solid rgba(84, 99, 116, 0.16);
  border-radius: 6px;
}

.chart-tile-header {
  width: 100%;
  min-height: 30px;
  padding: 4px 9px 3px 10px;
  border: 0;
  border-bottom: 1px solid rgba(84, 99, 116, 0.12);
  background: rgba(255, 255, 255, 0.62);
  color: #24313f;
  cursor: pointer;
  text-align: left;
}

.chart-tile-header span {
  min-width: 0;
  display: inline-block;
  margin-left: 5px;
}

.chart-tile-header b {
  font-size: 12px;
  line-height: 1;
}

.chart-tile-body {
  padding: 0 4px 6px;
}

.chart-tile:not([open]) .chart-tile-header {
  border-bottom: 0;
}

.panel-chart {
  width: 100%;
  height: 158px;
  cursor: grab;
}

.panel-chart.small {
  height: 122px;
}

.panel-chart.cost {
  height: 156px;
}

.panel-chart.chart-fallback {
  display: grid;
  align-items: center;
  padding: 10px 12px;
  box-sizing: border-box;
}

.panel-chart.chart-fallback > div {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font-size: 12px;
  color: #4a5563;
}

.panel-chart.chart-fallback b {
  color: #24313f;
}

.charger-minimap {
  display: grid;
  gap: 7px;
  min-height: 150px;
  overflow: visible;
  padding: 6px 6px 8px;
  box-sizing: border-box;
}

.mini-site {
  display: grid;
  grid-template-columns: 132px 1fr;
  gap: 9px;
  align-items: start;
}

.mini-site-name {
  overflow: hidden;
  color: #4a5563;
  font-size: 10px;
  font-weight: 700;
  line-height: 1.15;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.mini-glyphs {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.mini-chargers,
.mini-trucks {
  display: grid;
  grid-template-columns: repeat(auto-fill, 10px);
  gap: 3px;
  align-items: center;
}

.mini-square {
  width: 10px;
  height: 10px;
  border: 1px solid rgba(255, 255, 255, 0.95);
  box-shadow: 0 0 0 1px rgba(36, 49, 63, 0.18);
  box-sizing: border-box;
}

.mini-square.empty {
  background: rgba(148, 163, 184, 0.16);
}

.mini-dot {
  width: 8px;
  height: 8px;
  border: 1px solid rgba(255, 255, 255, 0.95);
  border-radius: 999px;
  box-shadow: 0 0 0 1px rgba(36, 49, 63, 0.14);
  box-sizing: border-box;
}

.mini-dot.empty {
  background: rgba(148, 163, 184, 0.18);
}

.mini-overflow,
.minimap-empty {
  color: #6c7784;
  font-size: 10px;
  font-weight: 700;
}

#summary {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  font-size: 13px;
}

#deck.fallback {
  display: grid;
  place-items: center;
  padding-right: 410px;
  box-sizing: border-box;
}

#deck.fallback > div {
  max-width: 560px;
  padding: 24px;
  background: rgba(255, 255, 255, 0.88);
  border: 1px solid rgba(40, 50, 65, 0.18);
  border-radius: 8px;
}
