:root {
  --bg: #06111f;
  --panel: rgba(6, 22, 39, 0.82);
  --line: rgba(41, 207, 220, 0.24);
  --text: #e7f8ff;
  --muted: #86a7b6;
  --cyan: #27d6df;
  --red: #ff4c4c;
  --green: #42dd70;
  --gold: #f2be3d;
  --silver: #b9d5ff;
  --blue: #48a6ff;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-width: 1180px;
  min-height: 680px;
  overflow: hidden;
  color: var(--text);
  font-family: "Microsoft YaHei", "PingFang SC", Arial, sans-serif;
  background:
    linear-gradient(rgba(39, 214, 223, 0.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(39, 214, 223, 0.05) 1px, transparent 1px),
    radial-gradient(circle at 50% 48%, rgba(31, 189, 181, 0.18), transparent 34%),
    #04101d;
  background-size: 48px 48px, 48px 48px, auto, auto;
}

.screen {
  position: relative;
  width: 100vw;
  min-width: 1180px;
  height: 100vh;
  min-height: 680px;
  padding: 14px 18px 18px;
  display: grid;
  grid-template-rows: 74px minmax(0, 1fr) 112px;
  gap: 16px;
}

.screen::before,
.screen::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.screen::before {
  background: linear-gradient(180deg, rgba(13, 87, 126, 0.3), transparent 12%, transparent 88%, rgba(13, 87, 126, 0.22));
  border: 1px solid rgba(39, 214, 223, 0.18);
}

.screen::after {
  background: repeating-linear-gradient(180deg, transparent 0, transparent 7px, rgba(255, 255, 255, 0.025) 8px);
  mix-blend-mode: screen;
}

.topbar {
  position: relative;
  z-index: 2;
  height: 74px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 22px;
  border-bottom: 1px solid rgba(39, 214, 223, 0.22);
  background: linear-gradient(90deg, rgba(6, 21, 37, 0.94), rgba(6, 21, 37, 0.56), rgba(6, 21, 37, 0.94));
}

.title-wrap {
  text-align: center;
  flex: 1;
  min-width: 0;
}

.title-kicker {
  display: block;
  margin-bottom: 3px;
  color: var(--muted);
  font-size: 11px;
  letter-spacing: 0;
}

h1 {
  margin: 0;
  color: #fff1ae;
  text-shadow: 0 0 14px rgba(39, 214, 223, 0.72), 0 0 24px rgba(242, 190, 61, 0.38);
  font-size: 25px;
  letter-spacing: 0;
  white-space: nowrap;
}

h1::before {
  content: "";
  display: inline-block;
  width: 78px;
  height: 7px;
  margin-right: 12px;
  vertical-align: middle;
  background: linear-gradient(90deg, var(--red), var(--green), var(--gold), var(--silver), var(--blue));
  box-shadow: 0 0 18px rgba(255, 255, 255, 0.28);
}

h1::after {
  content: "";
  display: inline-block;
  width: 78px;
  height: 7px;
  margin-left: 12px;
  vertical-align: middle;
  background: linear-gradient(90deg, var(--blue), var(--silver), var(--gold), var(--green), var(--red));
  box-shadow: 0 0 18px rgba(255, 255, 255, 0.28);
}

.meta-strip {
  display: grid;
  grid-template-columns: repeat(3, 78px);
  gap: 10px;
}

.meta-strip div {
  height: 48px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(39, 214, 223, 0.26);
  background: rgba(4, 16, 29, 0.7);
}

.meta-strip strong {
  color: var(--cyan);
  font-size: 20px;
  line-height: 20px;
}

.meta-strip span {
  color: var(--muted);
  font-size: 11px;
}

@media (max-width: 1320px) {
  .topbar {
    padding: 0 16px;
  }

  h1 {
    font-size: 23px;
  }

  h1::after {
    display: none;
  }

  .meta-strip {
    grid-template-columns: repeat(3, 68px);
    gap: 8px;
  }
}

.layout {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: 310px minmax(560px, 1fr) 310px;
  gap: 16px;
  min-height: 0;
}

.side-panel,
.chart-card {
  border: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(5, 22, 39, 0.92), rgba(4, 14, 26, 0.78));
  box-shadow: inset 0 0 24px rgba(39, 214, 223, 0.06), 0 0 30px rgba(0, 0, 0, 0.26);
}

.side-panel {
  min-height: 0;
  padding: 14px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.panel-head {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
  border-bottom: 1px solid rgba(39, 214, 223, 0.16);
  padding-bottom: 9px;
}

.panel-head.compact {
  margin-top: 14px;
}

.panel-head span {
  width: 8px;
  height: 8px;
  background: var(--cyan);
  box-shadow: 0 0 12px var(--cyan);
}

h2 {
  margin: 0;
  font-size: 16px;
}

.category-list {
  display: grid;
  gap: 8px;
}

.category {
  width: 100%;
  display: grid;
  grid-template-columns: 8px minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  padding: 10px;
  color: var(--text);
  border: 1px solid rgba(255, 255, 255, 0.07);
  background: rgba(11, 36, 59, 0.72);
  cursor: pointer;
}

.category.active {
  border-color: rgba(39, 214, 223, 0.7);
  background: rgba(14, 61, 83, 0.86);
}

.category i {
  width: 8px;
  height: 28px;
  display: block;
}

.category strong {
  display: block;
  font-size: 14px;
}

.category em {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 11px;
  font-style: normal;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.category small {
  color: var(--muted);
}

.search {
  width: 100%;
  height: 38px;
  border: 1px solid rgba(39, 214, 223, 0.24);
  background: rgba(2, 12, 23, 0.86);
  color: var(--text);
  padding: 0 12px;
  outline: none;
}

.result-list {
  margin-top: 10px;
  flex: 1;
  min-height: 90px;
  overflow: auto;
  scrollbar-color: rgba(39, 214, 223, 0.45) transparent;
}

.result {
  width: 100%;
  text-align: left;
  display: block;
  margin-bottom: 7px;
  padding: 9px 10px;
  color: var(--text);
  border: 1px solid rgba(255, 255, 255, 0.06);
  background: rgba(255, 255, 255, 0.035);
  cursor: pointer;
}

.result strong {
  display: block;
  font-size: 13px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.result span {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 11px;
}

.map-stage {
  min-width: 0;
}

.map-shell {
  position: relative;
  height: 100%;
  border: 1px solid rgba(39, 214, 223, 0.22);
  background: radial-gradient(circle at 52% 50%, rgba(0, 198, 188, 0.15), transparent 45%), rgba(2, 12, 23, 0.62);
  overflow: hidden;
}

#mapChart {
  width: 100%;
  height: 100%;
}

.detail-card {
  position: absolute;
  left: 22px;
  bottom: 22px;
  width: 330px;
  min-height: 128px;
  padding: 16px;
  border: 1px solid rgba(39, 214, 223, 0.32);
  background: rgba(4, 16, 29, 0.86);
  box-shadow: 0 0 24px rgba(0, 0, 0, 0.32);
}

.detail-tag {
  color: var(--cyan);
  font-size: 12px;
}

.detail-card h3 {
  margin: 8px 0 8px;
  font-size: 17px;
}

.detail-card p {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.7;
}

.city-list {
  height: 236px;
  overflow: auto;
}

.city-row {
  display: grid;
  grid-template-columns: 72px 1fr 34px;
  gap: 8px;
  align-items: center;
  margin-bottom: 10px;
  font-size: 12px;
}

.city-bar {
  height: 8px;
  background: rgba(255, 255, 255, 0.08);
}

.city-bar span {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, var(--cyan), #5e93ff);
  box-shadow: 0 0 12px rgba(39, 214, 223, 0.45);
}

.color-legend {
  display: grid;
  gap: 9px;
}

.legend-card {
  display: grid;
  grid-template-columns: 14px 1fr auto;
  align-items: center;
  gap: 10px;
  min-height: 42px;
  padding: 9px 10px;
  color: var(--text);
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.045);
  cursor: pointer;
  text-align: left;
}

.legend-card:hover {
  border-color: rgba(39, 214, 223, 0.48);
  background: rgba(16, 55, 78, 0.62);
}

.legend-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
}

.legend-card strong {
  font-size: 13px;
}

.legend-card small {
  color: var(--muted);
  font-size: 11px;
}

.hint-box {
  margin-top: 18px;
  padding: 14px;
  border: 1px solid rgba(255, 215, 124, 0.2);
  background: rgba(242, 190, 61, 0.08);
}

.hint-box strong {
  color: #ffd77c;
}

.hint-box p {
  margin: 8px 0 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.65;
}

.bottom-dashboard {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: 430px 1fr;
  gap: 16px;
  min-height: 0;
}

.chart-card {
  padding: 12px 14px;
}

#barChart {
  height: 72px;
}

.ticker {
  min-width: 0;
  display: flex;
  align-items: center;
  overflow: hidden;
  border: 1px solid var(--line);
  background: rgba(4, 16, 29, 0.72);
}

.ticker-track {
  display: flex;
  gap: 14px;
  animation: scroll 92s linear infinite;
  white-space: nowrap;
}

.ticker-item {
  padding: 9px 13px;
  border: 1px solid rgba(39, 214, 223, 0.2);
  background: rgba(255, 255, 255, 0.035);
  font-size: 13px;
}

@keyframes scroll {
  from {
    transform: translateX(0);
  }
  to {
    transform: translateX(-50%);
  }
}
