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

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

.marquee {
  position: relative;
  width: min(300px, 82vw);
  overflow: hidden;
  border-radius: 16px;
  padding: 16px 0;
  background: rgba(255, 247, 230, 0.12);
  outline: none;
}

.marquee__track {
  display: flex;
  width: max-content;
  animation: marquee-scroll 10s linear infinite;
}

.marquee__chip {
  margin-right: 40px;
  flex-shrink: 0;
  white-space: nowrap;
  font-weight: 700;
  font-size: clamp(13px, 3.6vw, 15px);
  line-height: 1;
  font-family: inherit;
  color: #17141a;
}

.marquee__cursor {
  position: absolute;
  top: 8px;
  right: 22px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #2f6df6;
  box-shadow: 0 0 0 3px rgba(47, 109, 246, 0.28);
  opacity: 0;
}

.marquee:hover .marquee__track,
.marquee:focus-within .marquee__track,
.marquee:active .marquee__track {
  animation-play-state: paused;
}

.marquee.is-demo .marquee__track {
  animation: marquee-hover-cycle 2s linear infinite;
}

.marquee.is-demo .marquee__cursor {
  animation: cursor-hover 2s linear infinite;
}

@keyframes marquee-hover-cycle {
  0% {
    transform: translateX(0);
  }
  38% {
    transform: translateX(-32%);
  }
  62% {
    transform: translateX(-32%);
  }
  100% {
    transform: translateX(-50%);
  }
}
@keyframes cursor-hover {
  0%, 30% {
    opacity: 0;
    transform: translateY(6px) scale(0.6);
  }
  38%, 62% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
  70%, 100% {
    opacity: 0;
    transform: translateY(6px) scale(0.6);
  }
}
@media (prefers-reduced-motion: reduce) {
  .marquee__track {
    animation: none;
    transform: translateX(0);
  }
  .marquee__cursor {
    animation: none;
    opacity: 0;
  }
}
