html, body {
  margin: 0;
  overflow: hidden;
}

.stage {
  box-sizing: border-box;
  min-height: 100vh;
  display: grid;
  place-items: center;
  margin: 0;
  background: #17141a;
  font-family: -apple-system, "Segoe UI", "Noto Sans KR", sans-serif;
  padding: clamp(8px, 4vw, 24px);
}

.gad {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

.gad__face {
  position: relative;
  width: 200px;
  height: 108px;
  cursor: grab;
  touch-action: none;
}

.gad__face:focus-visible {
  outline: 2px solid #fff7e6;
  outline-offset: 4px;
}

.gad__zones {
  position: absolute;
  inset: 0;
}

.gad__zone {
  position: absolute;
  left: 50%;
  bottom: 0;
  width: 4px;
  height: 44px;
  margin-left: -2px;
  transform-origin: bottom center;
  border-radius: 4px;
  background: rgba(255, 247, 230, 0.28);
  transition: background 220ms ease-out, height 220ms ease-out, width 220ms ease-out;
}

.gad__zone[data-i="0"] {
  background: rgba(76, 212, 166, 0.5);
}

.gad__zone[data-i="1"] {
  background: rgba(110, 200, 255, 0.5);
}

.gad__zone[data-i="2"] {
  background: rgba(185, 160, 255, 0.5);
}

.gad__zone[data-i="3"] {
  background: rgba(201, 48, 0, 0.5);
}

.gad__zone[data-i="4"] {
  background: rgba(255, 158, 187, 0.5);
}

.gad__zone.is-active {
  height: 52px;
  width: 6px;
  margin-left: -3px;
}

.gad__zone[data-i="0"].is-active {
  background: #4cd4a6;
}

.gad__zone[data-i="1"].is-active {
  background: #6ec8ff;
}

.gad__zone[data-i="2"].is-active {
  background: #b9a0ff;
}

.gad__zone[data-i="3"].is-active {
  background: #c93000;
}

.gad__zone[data-i="4"].is-active {
  background: #ff9ebb;
}

.gad__needle {
  position: absolute;
  left: 50%;
  bottom: 0;
  width: 3px;
  height: 58px;
  margin-left: -1.5px;
  background: #fff7e6;
  border-radius: 4px;
  transform-origin: bottom center;
  transition: transform 220ms ease-out;
}

.gad__pivot {
  position: absolute;
  left: 50%;
  bottom: -5px;
  width: 12px;
  height: 12px;
  margin-left: -6px;
  border-radius: 50%;
  background: #fff7e6;
}

.gad__label {
  font-size: 12px;
  color: #fff7e6;
}

@media (max-width: 340px) {
  .gad__face {
    width: 168px;
    height: 92px;
  }
  .gad__zone {
    height: 36px;
  }
  .gad__needle {
    height: 48px;
  }
}
@media (prefers-reduced-motion: reduce) {
  .gad__needle, .gad__zone {
    transition: none;
  }
}
