@font-face {
  font-display: swap;
}

* {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  padding: 0;
  height: 100%;
  background: #000;
}

body {
  display: flex;
  align-items: stretch;
}

#terminal {
  width: 100%;
  min-height: 100vh;
  background: #000;
  color: #33ff66;
  font-family: "Courier New", Consolas, Menlo, monospace;
  font-size: 16px;
  line-height: 1.4;
  padding: 24px;
  outline: none;
  cursor: text;
  white-space: pre-wrap;
  word-break: break-word;
  text-shadow: 0 0 4px rgba(51, 255, 102, 0.55);
}

#output {
  white-space: pre-wrap;
}

#output .line {
  margin: 0;
}

#output .error {
  color: #ff4d4d;
}

#output .dim {
  color: #1f8f3f;
}

.input-line {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
}

.prompt {
  margin-right: 8px;
  color: #33ff66;
}

#typed {
  white-space: pre;
}

.cursor {
  display: inline-block;
  width: 9px;
  height: 17px;
  background: #33ff66;
  margin-left: 2px;
  animation: blink 1s steps(1) infinite;
  vertical-align: text-bottom;
}

@keyframes blink {
  0%, 49% { opacity: 1; }
  50%, 100% { opacity: 0; }
}

#hiddenInput {
  position: absolute;
  opacity: 0;
  pointer-events: none;
  width: 1px;
  height: 1px;
}
