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

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

@property --open {
  syntax: "<number>";
  inherits: true;
  initial-value: 0;
}
.faq {
  display: flex;
  flex-direction: column;
  gap: 8px;
  width: 100%;
  max-width: 340px;
}

.faq__item {
  --open: 0;
  border-radius: 16px;
  background: #ffffff;
  overflow: hidden;
}

.faq__q {
  width: 100%;
  box-sizing: border-box;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  border: 0;
  background: transparent;
  padding: 12px 16px;
  color: #17141a;
  font-family: inherit;
  font-weight: 600;
  font-size: 12px;
  line-height: 1.4;
  text-align: left;
  cursor: pointer;
}

.faq__caret {
  flex: 0 0 auto;
  width: 7px;
  height: 7px;
  border-right: 2px solid #0a4fe8;
  border-bottom: 2px solid #0a4fe8;
  transform: rotate(calc(45deg + var(--open) * 180deg));
  transition: transform 300ms ease-out;
}

.faq__a {
  max-height: calc(var(--open) * var(--h));
  overflow: hidden;
  transition: max-height 300ms ease-out;
}

.faq__a-inner {
  margin: 0;
  padding: 0 16px 12px;
  color: rgba(23, 20, 26, 0.78);
  font-weight: 400;
  font-size: 11px;
  line-height: 1.5;
}

.is-demo .faq__item:nth-child(1) {
  animation: open-1 2s ease-out infinite;
}

.is-demo .faq__item:nth-child(2) {
  animation: open-2 2s ease-out infinite;
}

.is-demo .faq__item:nth-child(3) {
  animation: open-3 2s ease-out infinite;
}

@keyframes open-1 {
  0%, 8% {
    --open: 0;
  }
  22%, 45% {
    --open: 1;
  }
  58%, 100% {
    --open: 0;
  }
}
@keyframes open-2 {
  0%, 45% {
    --open: 0;
  }
  58%, 78% {
    --open: 1;
  }
  88%, 100% {
    --open: 0;
  }
}
@keyframes open-3 {
  0%, 78% {
    --open: 0;
  }
  88%, 96% {
    --open: 1;
  }
  100% {
    --open: 0;
  }
}
@media (max-width: 340px) {
  .faq__q {
    padding: 8px 12px;
    font-size: 11px;
  }
  .faq__a-inner {
    padding: 0 12px 8px;
  }
}
@media (prefers-reduced-motion: reduce) {
  .is-demo .faq__item:nth-child(1),
  .is-demo .faq__item:nth-child(2),
  .is-demo .faq__item:nth-child(3) {
    animation: none;
  }
  .faq__caret, .faq__a {
    transition: none;
  }
}
