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

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

.cr {
  width: min(300px, 88vw);
  text-align: center;
}

.cr__status {
  margin: 0 0 8px;
  font-size: 11px;
  font-weight: 700;
  color: rgba(23, 20, 26, 0.6);
}

.cr__row {
  display: flex;
  gap: 12px;
}

.cr__col {
  flex: 1 1 0;
  min-width: 0;
}

.cr__label {
  display: block;
  margin-bottom: 4px;
  font-size: 11px;
  font-weight: 700;
  color: rgba(23, 20, 26, 0.68);
}

.cr__chart {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 4px;
  height: 84px;
  padding: 0 4px;
  border-bottom: 2px solid rgba(23, 20, 26, 0.16);
}

.cr__bar {
  width: 100%;
  height: 100%;
  border-radius: 4px 4px 0 0;
  transform-origin: bottom;
  transform: scaleY(0.16);
  opacity: 0.32;
}

.cr__bar--normal {
  background: #2f6df6;
  animation: crRevealSmooth 2s var(--phase, 0ms) cubic-bezier(0.2, 0.8, 0.2, 1) infinite;
}

.cr__bar--reduced {
  background: #2b9d74;
  animation: crRevealInstant 2s cubic-bezier(0.2, 0.8, 0.2, 1) infinite;
}

.cr--force-instant .cr__bar--normal {
  animation-name: crRevealInstant;
  animation-delay: 0ms;
}

.cr__toggle {
  display: block;
  margin: 12px auto 0;
  appearance: none;
  border: none;
  cursor: pointer;
  background: #17141a;
  color: #fff7e6;
  font-weight: 700;
  font-size: 12px;
  padding: 4px 12px;
  border-radius: 999px;
}

.cr__toggle:focus-visible {
  outline: 2px solid #17141a;
  outline-offset: 2px;
}

.cr__toggle[aria-pressed=true] {
  background: #2f6df6;
}

@keyframes crRevealSmooth {
  0% {
    transform: scaleY(0.16);
    opacity: 0.32;
  }
  14% {
    transform: scaleY(0.16);
    opacity: 0.32;
  }
  46% {
    transform: scaleY(var(--real, 0.6));
    opacity: 1;
  }
  84% {
    transform: scaleY(var(--real, 0.6));
    opacity: 1;
  }
  100% {
    transform: scaleY(0.16);
    opacity: 0.32;
  }
}
@keyframes crRevealInstant {
  0% {
    transform: scaleY(0.16);
    opacity: 0.32;
  }
  45% {
    transform: scaleY(0.16);
    opacity: 0.32;
  }
  46% {
    transform: scaleY(var(--real, 0.6));
    opacity: 1;
  }
  84% {
    transform: scaleY(var(--real, 0.6));
    opacity: 1;
  }
  85% {
    transform: scaleY(0.16);
    opacity: 0.32;
  }
  100% {
    transform: scaleY(0.16);
    opacity: 0.32;
  }
}
.cr__bar--reduced, .cr--force-instant .cr__bar--normal {
  animation-timing-function: steps(1, end);
}

@media (max-width: 340px) {
  .cr {
    width: min(250px, 86vw);
  }
  .cr__chart {
    height: 68px;
  }
}
@media (prefers-reduced-motion: reduce) {
  .cr__bar {
    animation: none;
    transform: scaleY(var(--real, 0.6));
    opacity: 1;
  }
}
