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);
}

.qx {
  box-sizing: border-box;
  width: min(300px, 92vw);
  margin: 0;
  padding: 16px 20px;
  border-radius: 16px;
  background: #fff7e6;
  color: #17141a;
  display: grid;
  gap: 12px;
  font-family: inherit;
}

.qx * {
  box-sizing: border-box;
}

.qx__mark {
  color: #2f6df6;
}

.qx__swap {
  display: grid;
  min-height: 48px;
}

.qx__line {
  grid-area: 1/1;
  margin: 0;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.7;
  color: #17141a;
  opacity: 0;
  transition-property: opacity;
  transition-duration: 140ms;
}

.qx__line.is-on {
  opacity: 1;
}

.qx__foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.qx__dots {
  display: flex;
  gap: 8px;
}

.qx__dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(23, 20, 26, 0.25);
  transition-property: transform, background-color;
  transition-duration: 140ms;
}

.qx__dot.is-on {
  background: #17141a;
  transform: scale(1.15);
}

.qx__next {
  border: 0;
  border-radius: 999px;
  padding: 8px 16px;
  background: #17141a;
  color: #fff7e6;
  font-family: inherit;
  font-size: 11px;
  font-weight: 700;
  line-height: 1.4;
  cursor: pointer;
}

.qx__next:focus-visible {
  outline: 2px solid #2f6df6;
  outline-offset: 2px;
}

.qx__mark.is-bump {
  animation-name: qxBumpOnce;
  animation-duration: 240ms;
  animation-timing-function: cubic-bezier(0.2, 0.8, 0.2, 1);
  animation-iteration-count: 1;
}

@keyframes qxBumpOnce {
  0% {
    transform: translateY(0);
  }
  40% {
    transform: translateY(-5px);
  }
  100% {
    transform: translateY(0);
  }
}
.qx.is-demo .qx__line {
  transition: none;
}

.qx.is-demo .qx__line {
  animation-timing-function: steps(1, end);
  animation-duration: 2s;
  animation-iteration-count: infinite;
}

.qx.is-demo .qx__line:nth-child(1) {
  animation-name: qxLine1;
}

.qx.is-demo .qx__line:nth-child(2) {
  animation-name: qxLine2;
}

.qx.is-demo .qx__line:nth-child(3) {
  animation-name: qxLine3;
}

.qx.is-demo .qx__dot {
  animation-timing-function: steps(1, end);
  animation-duration: 2s;
  animation-iteration-count: infinite;
}

.qx.is-demo .qx__dot:nth-child(1) {
  animation-name: qxDot1;
}

.qx.is-demo .qx__dot:nth-child(2) {
  animation-name: qxDot2;
}

.qx.is-demo .qx__dot:nth-child(3) {
  animation-name: qxDot3;
}

.qx.is-demo .qx__mark {
  animation-name: qxMarkLoop;
  animation-duration: 2s;
  animation-timing-function: cubic-bezier(0.2, 0.8, 0.2, 1);
  animation-iteration-count: infinite;
}

@keyframes qxLine1 {
  0% {
    opacity: 1;
  }
  33%, 100% {
    opacity: 0;
  }
}
@keyframes qxLine2 {
  0% {
    opacity: 0;
  }
  33% {
    opacity: 1;
  }
  67%, 100% {
    opacity: 0;
  }
}
@keyframes qxLine3 {
  0%, 66% {
    opacity: 0;
  }
  67%, 100% {
    opacity: 1;
  }
}
@keyframes qxDot1 {
  0% {
    transform: scale(1.15);
    background-color: rgb(23, 20, 26);
  }
  33%, 100% {
    transform: scale(1);
    background-color: rgba(23, 20, 26, 0.25);
  }
}
@keyframes qxDot2 {
  0%, 33% {
    transform: scale(1);
    background-color: rgba(23, 20, 26, 0.25);
  }
  33.01% {
    transform: scale(1.15);
    background-color: rgb(23, 20, 26);
  }
  67%, 100% {
    transform: scale(1);
    background-color: rgba(23, 20, 26, 0.25);
  }
}
@keyframes qxDot3 {
  0%, 66% {
    transform: scale(1);
    background-color: rgba(23, 20, 26, 0.25);
  }
  67%, 100% {
    transform: scale(1.15);
    background-color: rgb(23, 20, 26);
  }
}
@keyframes qxMarkLoop {
  0% {
    transform: translateY(0);
  }
  3% {
    transform: translateY(-5px);
  }
  7%, 34% {
    transform: translateY(0);
  }
  37% {
    transform: translateY(-5px);
  }
  41%, 68% {
    transform: translateY(0);
  }
  71% {
    transform: translateY(-5px);
  }
  75%, 100% {
    transform: translateY(0);
  }
}
@media (prefers-reduced-motion: reduce) {
  .qx.is-demo .qx__line,
  .qx.is-demo .qx__dot,
  .qx.is-demo .qx__mark {
    animation: none !important;
  }
  .qx__line, .qx__dot {
    transition: none !important;
  }
}
@media (max-width: 340px) {
  .qx {
    padding: 12px 16px;
  }
  .qx__line {
    font-size: 13px;
  }
  .qx__swap {
    min-height: 44px;
  }
}
