/* CSS is how you can add style to your website, such as colors, fonts, and positioning of your
 *   HTML content. To learn how to do something, just try searching Google for questions like
 *   "how to change link color." */

:root {
  --crt-red: rgb(218, 49, 49);
  --crt-green: rgb(112, 159, 115);
  --crt-blue: rgb(40, 129, 206);
}
/* Global */
html {
  font-size: 1.5rem;
  font-family: "OCR A Std", monospace;
  min-height: 100%;
}
main {
  height: 100vh;
  height: 100dvh;
  color: #f1e2de;

}

.pink {
  color: #d98fcc;
}
.purple {
  color: #b5a8d5;
}
.blue {
  color: #6d8fd1;
}
.code {
  color: attr(data-color);
}
.wrapper {
  padding-top: 5rem;
  padding-left: 5rem;
  padding-right: 5rem;
  display: inline-block;
  white-space: normal;
}

.code {
  animation: typewriter 1s steps(14) 1s 1 normal both;
  line-height: 1;
  margin: 0;
  display: inline-block;
  white-space: nowrap;
  overflow-x: hidden;
  overflow: hidden;
}
.cursor {
  display: inline-block;
  animation: blinkTextCursor 500ms infinite normal;
}
.scanline {
  width: 100%;
  height: 100px;
  z-index: 8;
  background: linear-gradient(
    0deg,
    rgba(0, 0, 0, 0) 0%,
                              rgba(255, 255, 255, 0.2) 10%,
                              rgba(0, 0, 0, 0.1) 100%
  );
  opacity: 0.1;
  position: fixed;
  bottom: 100%;
  animation: scanline 10s linear infinite;
}
.bg_rgba {
  background-image: url(https://www.startpage.com/av/proxy-image?piurl=https%3A%2F%2Fimg1.picmix.com%2Foutput%2Fstamp%2Fnormal%2F1%2F5%2F3%2F7%2F2727351_6bbf2.png&sp=1784399378T716704c8845b5f4500c5616be6a6d369b803e9d68e6ab456fbafa529306abcba);
  background-color: #252528;
  background-blend-mode: overlay;
  background-repeat:no-repeat;
  background-position: fixed;
 
}


.crt {
  text-shadow: 0 0 0.2em currentColor, 1px 1px rgba(255, 0, 255, 0.5),
  -1px -1px rgba(0, 255, 255, 0.4);
  content: " ";
  position:absolute;
    left:21%;
    top:28%;
    width:58%;
    height:44%;
    scale: 78%;
    overflow:hidden;
    border-radius:10px;
    background:#282823;
  &:before,
  &:after {
    content: "";
    transform: translateZ(0);
    pointer-events: none;
    //opacity: 0.5;
    mix-blend-mode: overlay;
    position: fixed;
    height: 100%;
    width: 100%;
    top: 0;
    left: 0;
    bottom: 0;
    right: 0;
    
  }

  &:before {
    background: repeating-linear-gradient(
      var(--crt-red) 0px,
                                          var(--crt-green) 2px,
                                          var(--crt-blue) 4px
    );
  }
  &:after {
    background: repeating-linear-gradient(
      90deg,
      var(--crt-red) 1px,
                                          var(--crt-green) 2px,
                                          var(--crt-blue) 3px
    );
  }
}
.typing-window {
  transition: opacity 0.5s, max-height 0.5s;
  max-height: 9000px;
  font-size: 1.6rem;
  line-height: 1.2;
  font-weight: 400;
  font-family: var(--code-font-family);
  background-color: #1f1f21;
  border-radius: 0.5rem;
  padding: 0;
  color: #ccc;
  margin-bottom: 2rem;
  box-shadow: 0 1px 1px rgba(0,0,0,0.12), 0 2px 2px rgba(0,0,0,0.12), 0 4px 4px rgba(0,0,0,0.12), 0 8px 8px rgba(0,0,0,0.12), 0 16px 16px rgba(0,0,0,0.12);

  strong {
    font-weight: 700;
  }

  .typing-area{
    padding: 1.5rem 1.5rem 1.5rem 1rem;
  }
}

*{
    margin:0;
    padding:0;
    box-sizing:border-box;
}

body{
    display:flex;
    justify-content:center;
    align-items:center;
    height:90vh;
    overflow:hidden;
    font-family:Consolas,monospace;
}

/* TV container */
.tv{
    position:relative;
    width:900px;
}

/* TV image */
.tv img{
    width: 100%;
    display:block;
    user-select:none;
    pointer-events:none;
}

/* Screen area (adjust these values to fit your TV image) */
.screen{
    position:absolute;
    left:21%;
    top:28%;
    width:58%;
    height:44%;
    scale: 78%;
    overflow:hidden;
    border-radius:10px;
    background:#282823;
    
}

/* CRT effects */
.screen::before{
    content:"";
    position:absolute;
    inset:0;
    background:
        repeating-linear-gradient(
            to bottom,
            rgba(255,255,255,.04) 0px,
            rgba(255,255,255,.04) 2px,
            transparent 2px,
            transparent 4px
        );
    pointer-events:none;
    
}

.screen::after{
    content:"";
    position:absolute;
    inset:0;
    background:radial-gradient(circle,
        transparent 55%,
        rgba(16, 16, 17, 0.877) 100%);
    pointer-events:none;
    mix-blend-mode: overlay;
}

/* Terminal text */
.terminal{
    position:absolute;
    left:15px;
    right:15px;
    bottom:10px;
    color:#6d8fd1;
    font-size:18px;
    line-height:1.45em;
    text-shadow: 0 0 0.2em currentColor, 1px 1px rgba(255, 0, 255, 0.5),
  -1px -1px rgba(0, 255, 255, 0.4);
    white-space:pre-wrap;
    
}

/* Cursor */
.cursor{
    animation:blink .8s infinite;
}

@keyframes blink{
    50%{opacity:0;}
}

.choice {
    color: #55ff55;
    text-decoration: none;
    cursor: pointer;
    transition: color .2s;
}

.choice:hover {
    color: #6d8fd1;
}
