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

.ld {
  display: flex;
  flex-direction: column;
  gap: 8px;
  width: 100%;
  max-width: 360px;
}

.ld__hint {
  margin: 0;
  font-weight: 700;
  font-size: clamp(10px, 2.8vw, 12px);
  line-height: 1.35;
  color: #17141a;
  text-align: center;
}

.ld__field {
  position: relative;
  height: 208px;
  border-radius: 16px;
  overflow: hidden;
  background: rgb(100%, 20.6603641457%, 0.1568627451%);
  box-shadow: inset 0 0 0 1px rgba(23, 20, 26, 0.16);
  display: grid;
  place-items: center;
  cursor: pointer;
  perspective: clamp(320px, 70vw, 480px);
}

.ld__field:focus-visible {
  outline: 2px solid #17141a;
  outline-offset: 2px;
}

.c3__deck {
  position: relative;
  width: 116px;
  height: 74px;
  transform-style: preserve-3d;
}

.c3__card {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: #fff7e6;
  color: #17141a;
  font-weight: 700;
  font-size: 20px;
  line-height: 1;
  box-shadow: 0 14px 24px rgba(23, 20, 26, 0.32);
  will-change: transform, opacity;
}

.ld__badge {
  position: absolute;
  right: 8px;
  top: 8px;
  display: flex;
  align-items: baseline;
  gap: 4px;
  padding: 4px 8px;
  border-radius: 999px;
  background: rgba(23, 20, 26, 0.78);
  color: #fff7e6;
  font-weight: 700;
  font-size: 11px;
}

.ld__badgeNum {
  font-size: 13px;
  color: #ffd23f;
}

.ld__badgeUnit {
  font-weight: 700;
}

@media (max-width: 340px) {
  .ld {
    gap: 4px;
  }
  .ld__field {
    height: 124px;
  }
  .c3__deck {
    width: 84px;
    height: 54px;
  }
  .ld__badge {
    font-size: 10px;
    padding: 0 4px;
  }
  .ld__badgeNum {
    font-size: 11px;
  }
}
@media (prefers-reduced-motion: reduce) {
  .ld.is-still .ld__field {
    cursor: default !important;
  }
  .ld.is-still .ld__badge {
    opacity: 0.92 !important;
  }
}
