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

.cp {
  display: grid;
  gap: 12px;
  justify-items: center;
  width: 100%;
}

.cp__caption {
  margin: 0;
  font-size: 12px;
  font-weight: 600;
  color: #17141a;
}

.cp__scene {
  position: relative;
  width: 260px;
  height: 190px;
  display: flex;
  justify-content: center;
}

.cp__btn {
  position: relative;
  z-index: 2;
  border: 0;
  background: #ffffff;
  border-radius: 999px;
  padding: 16px;
  height: max-content;
  cursor: pointer;
  color: #0a4fe8;
  box-shadow: 0 14px 24px rgba(23, 20, 26, 0.32);
}

.cp__btn:focus-visible {
  outline: 2px solid #5b8cf8;
  outline-offset: 3px;
}

.cp__shape {
  fill: none;
  stroke: #0a4fe8;
  stroke-width: 1.6;
  stroke-linejoin: round;
}

.cp__btn[aria-pressed=true] .cp__shape {
  fill: #0a4fe8;
}

.cp__panel {
  position: absolute;
  top: 64px;
  left: 50%;
  transform: translateX(-50%);
  width: 200px;
  display: grid;
  gap: 8px;
  padding: 16px;
  border-radius: 16px;
  background: #fff7e6;
  box-shadow: 0 14px 24px rgba(23, 20, 26, 0.32);
  opacity: 0;
  pointer-events: none;
  transition: opacity 300ms ease-out;
}

.cp__panel--open {
  opacity: 1;
  pointer-events: auto;
}

.cp__panelTitle {
  margin: 0 0 4px;
  font-size: 11px;
  font-weight: 700;
  color: #0a4fe8;
}

.cp__item {
  border: 0;
  border-radius: 8px;
  background: #6ec8ff;
  padding: 8px 12px;
  font-size: 12px;
  font-weight: 600;
  color: #17141a;
  text-align: left;
  cursor: pointer;
  will-change: transform, opacity;
}

.cp__item:hover,
.cp__item:focus-visible {
  background: #5b8cf8;
  outline: none;
}

.cp__status {
  margin: 0;
  font-size: 11px;
  color: #17141a;
  font-weight: 600;
}

@media (max-width: 340px) {
  .cp__scene {
    width: 200px;
    height: 100px;
  }
  .cp__btn {
    padding: 12px;
  }
  .cp__panel {
    top: 42px;
    width: 180px;
    padding: 8px;
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    justify-content: center;
  }
  .cp__panelTitle {
    display: none;
  }
  .cp__item {
    font-size: 10px;
    padding: 4px 8px;
  }
}
@media (prefers-reduced-motion: reduce) {
  .cp__panel,
  .cp__item {
    transition: none;
  }
}
