html, body {
  margin: 0;
  padding: 0;
}

.hidden {
  display: none;
}

.screen {
  position: absolute;
  overflow: hidden;
  width: 100%;
  height: 100%;
  background: #000000;
}

.terminal_emulator {
  position: absolute;
  bottom: 0;
  width: 100%;
  min-height: 100%;
  padding: 40px;
  font-size: 2vw;
  line-height: 1.25vw;
  box-sizing: border-box;
  text-align:left;
  font-family: courier;
  font-weight: 400;  
  color: #ffffff;
}
  
.terminal_emulator__command::before {
  left:0;
  top: 0;
  content:"$";
}

.terminal_emulator__command::before,
.terminal_emulator__command::after {
  position: absolute;
}

.terminal_emulator__field,
.terminal_emulator__command {
  position: relative;
  padding: 0 0;
  margin: 0 0 9px 0;
}
  
.terminal_emulator__response,
.terminal_emulator__command b{
  padding-bottom: 9px;
}

.terminal_emulator__response .red{
  color: #FF0000;
  left:0;
  top: 0;
  position: relative;
}

.terminal_emulator__response .green{
  color: #99ff99;
  left:0;
  top: 0;
  position: relative;
}

.terminal_emulator__field {
  display: inline-block;
  min-width: 1em;
  min-height: 1.5em;
  box-sizing: border-box;
}

.terminal_emulator__field::after {
  right: 0;
  bottom: 0.25em;
  content:"█";
  width: 1em;
  height: 1.5em;
  background:#ffffff;
  animation: caretBlink 1s infinite;
}
  
.waiting {
  padding-left: 0;
  padding-right: 0;
}

.terminal_emulator__field::before {
  display: none;
}

@keyframes caretBlink {
  0% {
    opacity: 0;
  }
  
  50% {
    opacity: 0;
  }
  
  51% {
    opacity: 1;
  }
  
  100% {
    opacity: 1;
  }
}


.flicker {
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    right: 0;
    background: rgba(18, 16, 16, 0.2);
    opacity: 0;
    z-index: 1000;
    pointer-events: none;
    animation: flicker 0.12s infinite;
}
@keyframes flicker {
  0% {
    opacity: 0.552;
  }
  5% {
    opacity: 0.48287;
  }
  10% {
    opacity: 0.59134;
  }
  15.0% {
    opacity: 0.79543;
  }
  20% {
    opacity: 0.75134;
  }
  25% {
    opacity: 0.1956;
  }
  30.0% {
    opacity: 0.90687;
  }
  35% {
    opacity: 0.122;
  }
  40% {
    opacity: 0.62254;
  }
  45% {
    opacity: 0.56977;
  }
  50% {
    opacity: 0.9925;
  }
  55.0% {
    opacity: 0.55487;
  }
  60.0% {
    opacity: 0.16607;
  }
  65% {
    opacity: 0.12353;
  }
  70% {
    opacity: 0.2214;
  }
  75% {
    opacity: 0.67908;
  }
  80% {
    opacity: 0.97163;
  }
  85.0% {
    opacity: 0.1275;
  }
  90% {
    opacity: 0.37186;
  }
  95% {
    opacity: 0.24475;
  }
  100% {
    opacity: 0.37221;
  }
}
.scanlines {
    top: 0;
    left: 0;
    height: 100%;
    width: 100%;
    background: linear-gradient(
        to bottom,
        rgba(255,255,255,0),
        rgba(255,255,255,0) 50%,
        rgba(0,0,0,.2) 70%,
        rgba(0,0,0,.6)
    );
    background-size: 100% .3rem;
    position: fixed;
    pointer-events: none;
}
.scanlines:before {
  position: absolute;
  top: 0px;
  width: 100%;
  height: 5px;
  background: #fff;
  background: linear-gradient(to bottom,
      rgba(255,0,0,0) 0%,
      rgba(255,250,250,1) 50%,
      rgba(255,255,255,0.98) 51%,
      rgba(255,0,0,0) 100%
  ); /* W3C */
  opacity: .1;
}
.scanlines:after {
  box-shadow: 0 2px 6px rgba(25,25,25,0.2),
      inset 0 1px rgba(50,50,50,0.1),
      inset 0 3px rgba(50,50,50,0.05),
      inset 0 3px 8px rgba(64,64,64,0.05),
      inset 0 -5px 10px rgba(25,25,25,0.1);
}
#terminal:focus-within ~ .scanlines:before {
    content: '';
    display: block;
    animation: vline calc(var(--time, 2) * 1s) linear infinite;
}
/*
 * MS Edge don't support focus-within and css vars
 * inside pseudo selector
 */
@supports (-ms-ime-align:auto) {
    .scanlines:before {
        content: '';
        animation: vline 3s linear infinite;
    }
}
@keyframes vline {
  to { transform: translate(0, 100vh)}
}
@media (prefers-reduced-motion) {
    .flicker, .scanlines:before {
        animation: none !important;
    }
}
