:root {
  color-scheme: dark;
  font-family: "Segoe UI", "Noto Sans TC", Arial, sans-serif;
  background: #081017;
  color: #eef5fb;
}

html,
body,
#scene {
  width: 100%;
  height: 100%;
  margin: 0;
  overflow: hidden;
}

#scene canvas {
  display: block;
}

.hud {
  position: fixed;
  z-index: 10;
  background: rgba(7, 12, 18, 0.74);
  border: 1px solid rgba(190, 210, 230, 0.18);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.28);
  backdrop-filter: blur(12px);
}

.title {
  top: 18px;
  left: 18px;
  padding: 14px 18px;
}

.title h1 {
  margin: 0;
  font-size: 24px;
  letter-spacing: 0;
}

.title p {
  margin: 4px 0 0;
  color: #aabccc;
  font-size: 13px;
}

.stats {
  top: 18px;
  right: 18px;
  width: 236px;
  padding: 14px;
}

.stats dl {
  margin: 12px 0 0;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 7px 14px;
  font-size: 13px;
}

.stats dt {
  color: #9db1c4;
}

.stats dd {
  margin: 0;
}

.controls {
  left: 18px;
  right: 18px;
  bottom: 18px;
  min-height: 66px;
  display: grid;
  grid-template-columns: 96px 104px 86px minmax(210px, 1fr) 190px 136px;
  align-items: center;
  gap: 14px;
  padding: 12px 14px;
}

.controls label {
  display: grid;
  gap: 5px;
  color: #afbfce;
  font-size: 13px;
}

button,
select {
  height: 36px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: #1d2a36;
  color: #f2f6fa;
  font: inherit;
}

button {
  cursor: pointer;
}

button:hover {
  background: #273847;
}

input[type="range"] {
  width: 100%;
}

.legend {
  position: fixed;
  left: 18px;
  bottom: 102px;
  z-index: 10;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 12px;
  background: rgba(7, 12, 18, 0.74);
  border: 1px solid rgba(190, 210, 230, 0.18);
  font-size: 12px;
  color: #cfdae5;
}

.depth-bar {
  width: 170px;
  height: 12px;
  background: linear-gradient(90deg, #fff3a4, #f5a742, #d9351c, #5e0b10);
}

.disclaimer {
  position: fixed;
  right: 18px;
  bottom: 102px;
  z-index: 10;
  color: rgba(238, 244, 250, 0.76);
  font-size: 12px;
  text-shadow: 0 1px 2px #000;
}
