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

.pal {
  box-sizing: border-box;
  width: min(264px, 88vw);
  padding: 4px 8px;
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 14px 24px rgba(23, 20, 26, 0.32);
  font-family: -apple-system, "Segoe UI", "Noto Sans KR", sans-serif;
  color: #17141a;
}

.pal.is-shut {
  display: none;
}

.pal__bar {
  box-sizing: border-box;
  height: 28px;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 8px;
  border-radius: 8px;
  background: rgba(23, 20, 26, 0.05);
}

.pal__mag {
  display: inline-flex;
  color: rgba(23, 20, 26, 0.42);
}

.pal__input {
  flex: 1 1 auto;
  min-width: 0;
  border: 0;
  background: transparent;
  font-family: inherit;
  font-size: 12px;
  font-weight: 600;
  color: #17141a;
}

.pal__input:focus-visible {
  outline: 2px solid #2f6df6;
  outline-offset: 2px;
  border-radius: 4px;
}

.pal__kbd {
  flex: 0 0 auto;
  height: 14px;
  display: inline-flex;
  align-items: center;
  padding: 0 4px;
  border-radius: 4px;
  background: #fff;
  box-shadow: 0 1px 0 rgba(23, 20, 26, 0.22);
  font-family: inherit;
  font-size: 9px;
  font-weight: 800;
  color: rgba(23, 20, 26, 0.5);
}

.pal__list {
  margin: 4px 0 0;
}

.pal__grp + .pal__grp {
  margin-top: 4px;
}

.pal__head {
  margin: 0 0 4px;
  padding: 0 8px;
  font-size: 9px;
  line-height: 12px;
  font-weight: 800;
  letter-spacing: 0.08em;
  color: rgba(23, 20, 26, 0.72);
}

.pal__opt {
  box-sizing: border-box;
  height: 22px;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 8px;
  border-radius: 8px;
  cursor: pointer;
}

.pal__ic {
  display: inline-flex;
  color: rgba(23, 20, 26, 0.5);
}

.pal__name {
  overflow: hidden;
  font-size: 12px;
  font-weight: 600;
  color: rgba(23, 20, 26, 0.82);
  white-space: nowrap;
  text-overflow: ellipsis;
}

.pal__opt.is-at {
  background: rgba(47, 109, 246, 0.12);
}

.pal__opt.is-at .pal__ic,
.pal__opt.is-at .pal__name {
  color: #2f6df6;
}

.pal__opt.is-run {
  background: rgba(47, 109, 246, 0.22);
}

.pal.is-demo .pal__opt {
  animation: opt-cascade 2s cubic-bezier(0.2, 0.8, 0.2, 1) infinite;
}

.pal.is-demo #o2 {
  animation-delay: 60ms;
}

.pal.is-demo #o3 {
  animation-delay: 120ms;
}

.pal.is-demo #o4 {
  animation-delay: 180ms;
}

@keyframes opt-cascade {
  0%, 10% {
    opacity: 1;
    transform: translateY(0);
  }
  30%, 38% {
    opacity: 0;
    transform: translateY(10px);
  }
  64%, 100% {
    opacity: 1;
    transform: translateY(0);
  }
}
.pal.is-demo .pal__head {
  animation: head-dim 2s cubic-bezier(0.2, 0.8, 0.2, 1) infinite;
}

@keyframes head-dim {
  0%, 10% {
    opacity: 1;
  }
  30%, 38% {
    opacity: 0.25;
  }
  64%, 100% {
    opacity: 1;
  }
}
@media (prefers-reduced-motion: reduce) {
  .pal.is-demo .pal__opt,
  .pal.is-demo .pal__head {
    animation: none !important;
  }
}
