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

.term {
  box-sizing: border-box;
  width: min(300px, 92vw);
  border-radius: 16px;
  background: #17141a;
  box-shadow: 0 14px 24px rgba(23, 20, 26, 0.32);
  padding: clamp(10px, 3vw, 16px);
  font: 500 clamp(13px, 3.6vw, 16px)/1.6 "Space Mono", ui-monospace, monospace;
  color: #fff7e6;
}
.term__bar {
  display: flex;
  gap: 6px;
  margin: 0 0 clamp(6px, 2vw, 10px);
}
.term__dot {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: rgba(255, 247, 230, 0.35);
}
.term__line {
  margin: 0;
}
.term__cmd {
  display: inline-block;
  overflow: hidden;
  white-space: nowrap;
  vertical-align: bottom;
  width: 0;
  border-right: 0.1em solid #2f6df6;
  animation: cmd-type 2s linear infinite;
}
.term__resp {
  margin: clamp(6px, 2vw, 10px) 0 0;
  color: #2f6df6;
  animation: resp-fade 2s ease-out infinite;
}

@keyframes cmd-type {
  0%, 5% {
    width: 0;
    animation-timing-function: steps(13, end);
  }
  45% {
    width: var(--full, 13ch);
  }
  85% {
    width: var(--full, 13ch);
  }
  95%, 100% {
    width: 0;
  }
}
@keyframes resp-fade {
  0%, 44% {
    opacity: 0;
  }
  50% {
    opacity: 1;
  }
  82% {
    opacity: 1;
  }
  90%, 100% {
    opacity: 0;
  }
}
@media (prefers-reduced-motion: reduce) {
  .term__cmd {
    animation: none;
    width: var(--full, 13ch);
    border-right-color: transparent;
  }
  .term__resp {
    animation: none;
    opacity: 1;
  }
}
