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

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

.ir {
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  gap: 8px;
  width: clamp(272px, 84vw, 376px);
  padding: 16px;
  border-radius: 16px;
  background: #fdf8f0;
  box-shadow: 0 14px 24px rgba(23, 20, 26, 0.32);
}

.ir__title {
  margin: 0;
  color: #15131a;
  font-weight: 700;
  font-size: 15px;
  line-height: 1.3;
  font-family: inherit;
}

.ir__row {
  display: block;
  height: 8px;
  border-radius: 999px;
  background: #e3ddd2;
}

.ir__row--full {
  width: 100%;
}

.ir__row--wide {
  width: 88%;
}

.ir__row--mid {
  width: 62%;
}

.ir__share {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 8px;
  padding-top: 12px;
  border-top: 1px solid #e3ddd2;
}

.ir__label {
  margin: 0;
  color: #5b5566;
  font-weight: 600;
  font-size: 12px;
  line-height: 1;
  font-family: inherit;
}

.ir__btns {
  display: flex;
  gap: 12px;
}

.ir__btn {
  position: relative;
  box-sizing: border-box;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: #ffffff;
  color: #15131a;
  cursor: pointer;
  box-shadow: 0 6px 12px rgba(23, 20, 26, 0.32);
  transition: transform 220ms cubic-bezier(0.2, 0.8, 0.2, 1), background-color 220ms cubic-bezier(0.2, 0.8, 0.2, 1), color 220ms cubic-bezier(0.2, 0.8, 0.2, 1);
}

.ir__ring {
  position: absolute;
  inset: 0;
  border: 2px solid #477690;
  border-radius: 50%;
  transform: scale(0.72);
  opacity: 0;
  transition: transform 220ms cubic-bezier(0.2, 0.8, 0.2, 1), opacity 220ms cubic-bezier(0.2, 0.8, 0.2, 1);
}

.ir__ic {
  display: grid;
  place-items: center;
}

.ir__ic svg {
  display: block;
}

.ir__btn:hover,
.ir__btn:focus-visible {
  transform: translateY(-4px);
}

.ir__btn:hover .ir__ring,
.ir__btn:focus-visible .ir__ring {
  transform: scale(1);
  opacity: 1;
}

.ir__btn:focus-visible {
  outline: 2px solid #15131a;
  outline-offset: 2px;
}

.ir__btn[aria-pressed=true] {
  background: #477690;
  color: #ffffff;
}

.ir__btn[aria-pressed=true] .ir__ring {
  opacity: 0;
}

.is-demo .ir__btn {
  animation-name: irLift;
  animation-duration: 2s;
  animation-timing-function: cubic-bezier(0.2, 0.8, 0.2, 1);
  animation-iteration-count: infinite;
  animation-fill-mode: backwards;
}

.is-demo .ir__ring {
  animation-name: irRing;
  animation-duration: 2s;
  animation-timing-function: cubic-bezier(0.2, 0.8, 0.2, 1);
  animation-iteration-count: infinite;
  animation-fill-mode: backwards;
}

.is-demo .ir__btn:nth-child(1), .is-demo .ir__btn:nth-child(1) .ir__ring {
  animation-delay: 0s;
}

.is-demo .ir__btn:nth-child(2), .is-demo .ir__btn:nth-child(2) .ir__ring {
  animation-delay: 0.18s;
}

.is-demo .ir__btn:nth-child(3), .is-demo .ir__btn:nth-child(3) .ir__ring {
  animation-delay: 0.36s;
}

.is-demo .ir__btn:nth-child(4), .is-demo .ir__btn:nth-child(4) .ir__ring {
  animation-delay: 0.54s;
}

@keyframes irLift {
  0% {
    transform: translateY(0);
  }
  6%, 22% {
    transform: translateY(-6px);
  }
  36%, 100% {
    transform: translateY(0);
  }
}
@keyframes irRing {
  0% {
    transform: scale(0.72);
    opacity: 0;
  }
  6%, 22% {
    transform: scale(1);
    opacity: 1;
  }
  36%, 100% {
    transform: scale(0.72);
    opacity: 0;
  }
}
@media (max-width: 340px), (max-height: 220px) {
  .ir {
    gap: 4px;
    padding: 12px;
  }
  .ir__title {
    font-size: 13px;
  }
  .ir__row {
    height: 6px;
  }
  .ir__share {
    margin-top: 0;
    padding-top: 8px;
  }
  .ir__btns {
    gap: 8px;
  }
  .ir__btn {
    width: 40px;
    height: 40px;
  }
  .ir__ic svg {
    width: 18px;
    height: 18px;
  }
}
@media (prefers-reduced-motion: reduce) {
  .is-demo .ir__btn, .is-demo .ir__ring {
    animation: none !important;
  }
  .ir__btn, .ir__ring {
    transition: none !important;
  }
  .ir__btn:hover .ir__ring, .ir__btn:focus-visible .ir__ring {
    opacity: 1;
    transform: scale(1);
  }
}
