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

.dh {
  box-sizing: border-box;
  width: min(304px, 92vw);
  padding: 12px;
  border: 1px solid rgb(87.262745098%, 87.0980392157%, 87.4274509804%);
  border-radius: 16px;
  background: #ffffff;
  color: #17141a;
  font-family: -apple-system, "Segoe UI", "Noto Sans KR", sans-serif;
  font-size: 12px;
  line-height: 1.3;
}

.dh__h {
  display: flex;
  align-items: center;
  gap: 4px;
  margin: 0 0 8px;
}

.dh__ic {
  display: inline-flex;
  width: 14px;
  height: 14px;
  color: #2f6df6;
}

.dh__t {
  margin: 0;
  font-size: 12px;
  font-weight: 700;
}

.dh__n {
  margin-left: auto;
  padding: 0 8px;
  border-radius: 999px;
  background: rgb(94.2901960784%, 95.9921568627%, 99.7529411765%);
  color: #0a4fe8;
  font-size: 11px;
  font-weight: 700;
  line-height: 1.7;
}

.dh__list {
  display: grid;
  gap: 4px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.dh__row {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 8px;
  padding: 4px 8px;
  border: 1px solid rgb(87.262745098%, 87.0980392157%, 87.4274509804%);
  border-radius: 8px;
  background: #ffffff;
}

.dh__f {
  color: rgba(23, 20, 26, 0.72);
  font-weight: 700;
}

.dh__diff {
  position: relative;
  margin: 0;
  min-height: 18px;
}

.dh__a, .dh__b {
  position: absolute;
  inset: 0;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.dh__b {
  visibility: hidden;
}

.dh__row.is-back .dh__a {
  visibility: hidden;
}

.dh__row.is-back .dh__b {
  visibility: visible;
}

.dh__diff del {
  color: #c2361a;
  font-size: 11px;
  text-decoration: line-through;
  text-decoration-thickness: 1.5px;
}

.dh__diff ins {
  color: #2f6df6;
  font-weight: 700;
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 3px;
}

.dh__b b {
  color: #17141a;
  font-weight: 700;
}

.dh__tag {
  padding: 0 4px;
  border-radius: 4px;
  background: #4cd4a6;
  color: #17141a;
  font-size: 10px;
  font-style: normal;
  font-weight: 700;
}

.dh__undo {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 0 8px;
  border: 1px solid rgb(87.262745098%, 87.0980392157%, 87.4274509804%);
  border-radius: 999px;
  background: #ffffff;
  color: #17141a;
  font-family: inherit;
  font-size: 11px;
  font-weight: 700;
  line-height: 1.7;
  cursor: pointer;
}

.dh__undo:focus-visible {
  outline: 2px solid #2f6df6;
  outline-offset: 2px;
}

.dh__u {
  display: inline-flex;
  width: 11px;
  height: 11px;
}

.dh__row.is-back .dh__undo {
  background: rgb(94.2901960784%, 95.9921568627%, 99.7529411765%);
  color: #2f6df6;
}

.dh__row.is-back .dh__u {
  transform: rotate(-360deg);
  transition: transform 300ms cubic-bezier(0.2, 0.8, 0.2, 1);
}

.dh__live {
  margin: 8px 0 0;
  color: rgba(23, 20, 26, 0.72);
  font-size: 10px;
}

@keyframes dh-a-1 {
  0%, 24% {
    visibility: visible;
  }
  25%, 87% {
    visibility: hidden;
  }
  88%, 100% {
    visibility: visible;
  }
}
@keyframes dh-b-1 {
  0%, 24% {
    visibility: hidden;
  }
  25%, 87% {
    visibility: visible;
  }
  88%, 100% {
    visibility: hidden;
  }
}
@keyframes dh-a-2 {
  0%, 54% {
    visibility: visible;
  }
  55%, 87% {
    visibility: hidden;
  }
  88%, 100% {
    visibility: visible;
  }
}
@keyframes dh-b-2 {
  0%, 54% {
    visibility: hidden;
  }
  55%, 87% {
    visibility: visible;
  }
  88%, 100% {
    visibility: hidden;
  }
}
@keyframes dh-spin-1 {
  0%, 24% {
    transform: rotate(0deg);
  }
  30%, 87% {
    transform: rotate(-360deg);
  }
  88%, 100% {
    transform: rotate(0deg);
  }
}
@keyframes dh-spin-2 {
  0%, 54% {
    transform: rotate(0deg);
  }
  60%, 87% {
    transform: rotate(-360deg);
  }
  88%, 100% {
    transform: rotate(0deg);
  }
}
@keyframes dh-pop-1 {
  0%, 24% {
    transform: scale(1);
  }
  27% {
    transform: scale(1.14);
  }
  31%, 87% {
    transform: scale(1);
  }
  88%, 100% {
    transform: scale(1);
  }
}
@keyframes dh-pop-2 {
  0%, 54% {
    transform: scale(1);
  }
  57% {
    transform: scale(1.14);
  }
  61%, 100% {
    transform: scale(1);
  }
}
@keyframes dh-n-tick {
  0%, 24% {
    transform: translateX(0);
  }
  25%, 54% {
    transform: translateX(-2px);
  }
  55%, 87% {
    transform: translateX(-4px);
  }
  88%, 100% {
    transform: translateX(0);
  }
}
.dh.is-demo .dh__row[data-row="1"] .dh__a {
  animation-name: dh-a-1;
}
.dh.is-demo .dh__row[data-row="1"] .dh__b {
  animation-name: dh-b-1;
}
.dh.is-demo .dh__row[data-row="2"] .dh__a {
  animation-name: dh-a-2;
}
.dh.is-demo .dh__row[data-row="2"] .dh__b {
  animation-name: dh-b-2;
}
.dh.is-demo .dh__a, .dh.is-demo .dh__b {
  animation-duration: 2s;
  animation-timing-function: steps(1, end);
  animation-iteration-count: infinite;
}
.dh.is-demo .dh__row[data-row="1"] .dh__u {
  animation-name: dh-spin-1;
}
.dh.is-demo .dh__row[data-row="2"] .dh__u {
  animation-name: dh-spin-2;
}
.dh.is-demo .dh__u {
  animation-duration: 2s;
  animation-timing-function: cubic-bezier(0.2, 0.8, 0.2, 1);
  animation-iteration-count: infinite;
}
.dh.is-demo .dh__row[data-row="1"] .dh__undo {
  animation-name: dh-pop-1;
}
.dh.is-demo .dh__row[data-row="2"] .dh__undo {
  animation-name: dh-pop-2;
}
.dh.is-demo .dh__undo {
  animation-duration: 2s;
  animation-timing-function: cubic-bezier(0.2, 1.4, 0.4, 1);
  animation-iteration-count: infinite;
}
.dh.is-demo .dh__n {
  animation-name: dh-n-tick;
  animation-duration: 2s;
  animation-timing-function: steps(1, end);
  animation-iteration-count: infinite;
}

@media (max-width: 340px) {
  .dh {
    padding: 8px;
    font-size: 11px;
  }
  .dh__h {
    margin-bottom: 4px;
  }
  .dh__row {
    padding: 0 8px;
  }
  .dh__f {
    font-size: 10px;
  }
  .dh__undo {
    font-size: 10px;
  }
  .dh__live {
    margin-top: 4px;
  }
}
@media (prefers-reduced-motion: reduce) {
  .dh__row.is-back .dh__u {
    transform: none;
    transition: none;
  }
  .dh.is-demo .dh__a,
  .dh.is-demo .dh__b,
  .dh.is-demo .dh__u,
  .dh.is-demo .dh__undo,
  .dh.is-demo .dh__n {
    animation: none !important;
    transform: none !important;
  }
  .dh.is-demo .dh__row[data-row="1"] .dh__a,
  .dh.is-demo .dh__row[data-row="2"] .dh__a {
    visibility: hidden !important;
  }
  .dh.is-demo .dh__row[data-row="1"] .dh__b,
  .dh.is-demo .dh__row[data-row="2"] .dh__b {
    visibility: visible !important;
  }
}
