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

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

.dogear {
  display: flex;
  gap: 12px;
  align-items: stretch;
}

.dogear__plan {
  box-sizing: border-box;
  position: relative;
  width: 124px;
  padding: 16px;
  border-radius: 16px;
  background: #ffffff;
  box-shadow: 0 6px 0 rgba(42, 35, 32, 0.16);
  overflow: hidden;
}

.dogear__plan--pick {
  background: #ffffff;
  outline: 3px solid #b97b71;
  outline-offset: -3px;
}

.dogear__fold {
  position: absolute;
  top: 0;
  right: 0;
  width: 40px;
  height: 40px;
  background: #d6c9ab;
  clip-path: polygon(100% 0, 0 0, 100% 100%);
  transform-origin: 100% 0;
  animation: cornerFold 2s ease-out infinite;
}

.dogear__star {
  position: absolute;
  top: 12px;
  left: 12px;
  color: #b97b71;
  font-size: 16px;
  line-height: 1;
}

.dogear__name {
  margin: 20px 0 4px;
  color: #5c5048;
  font-weight: 700;
  font-size: 11px;
  line-height: 1;
  font-family: inherit;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.dogear__plan:not(.dogear__plan--pick) .dogear__name {
  margin-top: 0;
}

.dogear__price {
  margin: 0 0 4px;
  color: #2a2320;
  font-weight: 800;
  font-size: 24px;
  line-height: 1.1;
  font-family: inherit;
}

.dogear__price span {
  font-size: 15px;
}

.dogear__note {
  margin: 0;
  color: #5c5048;
  font-weight: 500;
  font-size: 11px;
  line-height: 1.35;
  font-family: inherit;
}

@keyframes cornerFold {
  0%, 100% {
    transform: scale(1);
  }
  50% {
    transform: scale(0.28);
  }
}
@media (max-width: 340px), (max-height: 220px) {
  .dogear {
    gap: 8px;
  }
  .dogear__plan {
    width: 96px;
    padding: 12px;
  }
  .dogear__fold {
    width: 28px;
    height: 28px;
  }
  .dogear__star {
    font-size: 13px;
    top: 8px;
    left: 8px;
  }
  .dogear__name {
    margin-top: 16px;
    font-size: 9px;
  }
  .dogear__price {
    font-size: 18px;
  }
  .dogear__price span {
    font-size: 12px;
  }
  .dogear__note {
    display: none;
  }
}
@media (prefers-reduced-motion: reduce) {
  .dogear__fold {
    animation: none !important;
    transform: none;
  }
}
