@keyframes blinkCursor {
  50% {
    border-right-color: transparent;
  }
}

@keyframes typeAndDelete {
  0%, 10% {
    width: 0;
  }
  45%, 55% {
    width: 9.5em;
  }
  90%, 100% {
    width: 0;
  }
}

/* Reset & Centering */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  background-color: #111;
  display: flex;
  justify-content: center;
  align-items: center;
  height: 100vh;
  font-family: "Courier New", Courier, monospace;
  flex-direction: column;
}

.terminal-wrapper {
  display: flex;
  flex-direction: column;
  align-items: center;
}

/* Terminal Loader */
.terminal-loader {
  border: 0.15em solid #333;
  background-color: #1a1a1a;
  color: #0f0;
  font-size: 2em;
  padding: 2.5em 2em;
  width: 22em;
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.25);
  border-radius: 6px;
  position: relative;
  overflow: hidden;
}

/* Header */
.terminal-header {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2em;
  background-color: #333;
  border-top-left-radius: 6px;
  border-top-right-radius: 6px;
  padding: 0 0.6em;
  box-sizing: border-box;
}

.terminal-controls {
  float: right;
  margin-top: 0.5em;
}

.control {
  display: inline-block;
  width: 1em;
  height: 1em;
  margin-left: 0.6em;
  border-radius: 50%;
  background-color: #777;
}

.control.close {
  background-color: #e33;
}

.control.minimize {
  background-color: #ee0;
}

.control.maximize {
  background-color: #0b0;
}

.terminal-title {
  float: left;
  line-height: 2em;
  color: #eee;
  font-size: 0.6em;
}

/* Typing Text */
.text {
  display: inline-block;
  white-space: nowrap;
  overflow: hidden;
  border-right: 0.25em solid green;
  animation:
    typeAndDelete 4s steps(13) infinite,
    blinkCursor 0.5s step-end infinite alternate;
  margin-top: 2em;
  font-size: 1em;
}

/* Ashwanth Credit */
.credits {
  margin-top: 1em;
  font-size: 1.2em;
  color: #0f0;
  font-family: "Courier New", Courier, monospace;
  background: #1a1a1a;
  padding: 0.5em 1em;
  border: 1px solid #333;
  border-radius: 4px;
  box-shadow: 0 0 10px rgba(0, 255, 0, 0.2);
}
