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

.ms {
  box-sizing: border-box;
  width: min(268px, 88vw);
  font-family: -apple-system, "Segoe UI", "Noto Sans KR", sans-serif;
  color: #fff;
}

.ms__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin: 0 0 8px;
}

.ms__title {
  font-size: 10px;
  line-height: 12px;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: rgba(255, 255, 255, 0.6);
}

.ms__badge {
  position: relative;
  box-sizing: border-box;
  height: 20px;
  padding: 0 8px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.1);
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  overflow: hidden;
}

.ms__b, .ms__breal {
  position: absolute;
  right: 8px;
  font-size: 10px;
  line-height: 20px;
  font-weight: 800;
  white-space: nowrap;
  color: rgba(255, 255, 255, 0.75);
}

.ms__b--1, .ms__b--4 {
  color: #ffd23f;
}

.ms__b {
  opacity: 0;
}

.ms__b--0 {
  opacity: 1;
}

.ms__list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.ms__list:focus-visible {
  outline: none;
}

.ms__row {
  box-sizing: border-box;
  height: 22px;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 8px;
  margin-bottom: 4px;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.05);
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  user-select: none;
  transition: background 220ms cubic-bezier(0.2, 0.8, 0.2, 1);
}

.ms__row:hover {
  background: rgba(255, 255, 255, 0.1);
}

.ms__item.is-sel .ms__row {
  background: rgba(47, 109, 246, 0.3);
}

.ms__ico {
  display: inline-flex;
  flex: 0 0 auto;
  color: rgba(255, 255, 255, 0.8);
}

.ms__name {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.ms__ok {
  margin-left: auto;
  display: inline-flex;
  flex: 0 0 auto;
  color: #ffd23f;
  opacity: 0;
  transform: scale(0.6);
  transition: opacity 220ms cubic-bezier(0.2, 0.8, 0.2, 1), transform 220ms cubic-bezier(0.2, 1.4, 0.4, 1);
}

.ms__item.is-sel .ms__ok {
  opacity: 1;
  transform: scale(1);
}

.ms.is-demo .ms__item.is-a .ms__row {
  animation-name: ms-sela;
  animation-duration: 2s;
  animation-timing-function: steps(1, end);
  animation-iteration-count: infinite;
}

@keyframes ms-sela {
  0%, 9.9% {
    background: rgba(255, 255, 255, 0.05);
  }
  10%, 82% {
    background: rgba(47, 109, 246, 0.3);
  }
  82.01%, 100% {
    background: rgba(255, 255, 255, 0.05);
  }
}
.ms.is-demo .ms__item.is-a .ms__ok {
  animation-name: ms-oka;
  animation-duration: 2s;
  animation-timing-function: steps(1, end);
  animation-iteration-count: infinite;
}

@keyframes ms-oka {
  0%, 9.9% {
    opacity: 0;
  }
  10%, 82% {
    opacity: 1;
  }
  82.01%, 100% {
    opacity: 0;
  }
}
.ms.is-demo .ms__item.is-b .ms__row {
  animation-name: ms-selb;
  animation-duration: 2s;
  animation-timing-function: steps(1, end);
  animation-iteration-count: infinite;
  animation-delay: calc(var(--i) * 90ms);
}

@keyframes ms-selb {
  0%, 21.9% {
    background: rgba(255, 255, 255, 0.05);
  }
  22%, 82% {
    background: rgba(47, 109, 246, 0.3);
  }
  82.01%, 100% {
    background: rgba(255, 255, 255, 0.05);
  }
}
.ms.is-demo .ms__item.is-b .ms__ok {
  animation-name: ms-okb;
  animation-duration: 2s;
  animation-timing-function: steps(1, end);
  animation-iteration-count: infinite;
  animation-delay: calc(var(--i) * 90ms);
}

@keyframes ms-okb {
  0%, 21.9% {
    opacity: 0;
  }
  22%, 82% {
    opacity: 1;
  }
  82.01%, 100% {
    opacity: 0;
  }
}
.ms.is-demo .ms__b--0 {
  animation-name: ms-b0;
  animation-duration: 2s;
  animation-timing-function: steps(1, end);
  animation-iteration-count: infinite;
}

@keyframes ms-b0 {
  0% {
    opacity: 1;
  }
  13% {
    opacity: 0;
  }
  89% {
    opacity: 1;
  }
  100% {
    opacity: 1;
  }
}
.ms.is-demo .ms__b--1 {
  animation-name: ms-b1;
  animation-duration: 2s;
  animation-timing-function: steps(1, end);
  animation-iteration-count: infinite;
}

@keyframes ms-b1 {
  0% {
    opacity: 0;
  }
  13% {
    opacity: 1;
  }
  37% {
    opacity: 0;
  }
  100% {
    opacity: 0;
  }
}
.ms.is-demo .ms__b--4 {
  animation-name: ms-b4;
  animation-duration: 2s;
  animation-timing-function: steps(1, end);
  animation-iteration-count: infinite;
}

@keyframes ms-b4 {
  0% {
    opacity: 0;
  }
  37% {
    opacity: 1;
  }
  89% {
    opacity: 0;
  }
  100% {
    opacity: 0;
  }
}
@media (max-width: 340px) {
  .ms__row {
    height: 20px;
    font-size: 11px;
  }
}
@media (prefers-reduced-motion: reduce) {
  .ms.is-demo .ms__row, .ms.is-demo .ms__ok, .ms.is-demo .ms__b {
    animation: none !important;
  }
  .ms__row, .ms__ok {
    transition: none;
  }
}
