/*// Ignore all of this, scroll down until you see the next comment.*/
/*// I just like my eye candy. */
@import url("https://fonts.googleapis.com/css?family=Montserrat:100");
html, body, h1 {
  padding: 0;
  margin: 0;
  font-family: "Montserrat", sans-serif;
}

#app {
  background: rgb(10, 10, 10);
  height: 100vh;
  width: 100%;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  background: linear-gradient(rgba(10, 10, 10, 0.6), rgba(0, 0, 0, 0.9)), repeating-linear-gradient(0, transparent, transparent 2px, black 3px, black 3px), url("http://mothershiplabs.com/img/cyberpunk_city_fantasy_54664.jpg");
  background-size: cover;
  background-position: center;
  z-index: 1;
}

/*url('https://images.unsplash.com/photo-1506399558188-acca6f8cbf41?ixlib=rb-0.3.5&q=85&fm=jpg&crop=entropy&cs=srgb&ixid=eyJhcHBfaWQiOjE0NTg5fQ&s=7118759521e3184778a3b5e010e202c6');*/
#wrapper {
  text-align: center;
}

.sub {
  color: rgb(100, 220, 220);
  letter-spacing: 1em;
}

/*// Here's the meat and potatoes.*/
/* Our mixin positions a copy of our text
directly on our existing text, while
also setting content to the appropriate
text set in the data-text attribute. */
.glitch {
  position: relative;
  color: white;
  font-size: 3em;
  letter-spacing: 0.4em;
  /* Animation provies a slight random skew. Check bottom of doc
  for more information on how to random skew. */
  animation: glitch-skew 1s infinite linear alternate-reverse;
  /*// Creates a copy before our text. */
  /*// Creates a copy after our text. Note comments from ::before.*/
}
.glitch::before {
  /*// Duplicates our text with the mixin.*/
  content: attr(data-text);
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  /*// Scoots text slightly to the left for the color offset.*/
  left: 2px;
  /*// Creates the color 'shadow' that happens on the glitch.*/
  text-shadow: -2px 0 #ff00c1;
  /* Creates an initial clip for our glitch. This works in
  a typical top,right,bottom,left fashion and creates a mask
  to only show a certain part of the glitch at a time. */
  clip: rect(44px, 450px, 56px, 0);
  /* Runs our glitch-anim defined below to run in a 5s loop, infinitely,
  with an alternating animation to keep things fresh. */
  animation: glitch-anim 5s infinite linear alternate-reverse;
}
.glitch::after {
  content: attr(data-text);
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  left: -2px;
  text-shadow: -2px 0 #00fff9, 2px 2px #ff00c1;
  animation: glitch-anim2 1s infinite linear alternate-reverse;
}

/* Creates an animation with 20 steaps. For each step, it calculates 
a percentage for the specific step. It then generates a random clip
box to be used for the random glitch effect. Also adds a very subtle
skew to change the 'thickness' of the glitch.*/
@keyframes glitch-anim {
  0% {
    clip: rect(76px, 9999px, 50px, 0);
    transform: skew(0.75deg);
  }
  5% {
    clip: rect(18px, 9999px, 13px, 0);
    transform: skew(0.1deg);
  }
  10% {
    clip: rect(8px, 9999px, 91px, 0);
    transform: skew(0.05deg);
  }
  15% {
    clip: rect(44px, 9999px, 11px, 0);
    transform: skew(0.13deg);
  }
  20% {
    clip: rect(65px, 9999px, 94px, 0);
    transform: skew(0.45deg);
  }
  25% {
    clip: rect(18px, 9999px, 32px, 0);
    transform: skew(0.47deg);
  }
  30% {
    clip: rect(71px, 9999px, 7px, 0);
    transform: skew(0.75deg);
  }
  35% {
    clip: rect(4px, 9999px, 55px, 0);
    transform: skew(0.36deg);
  }
  40% {
    clip: rect(76px, 9999px, 59px, 0);
    transform: skew(0.88deg);
  }
  45% {
    clip: rect(17px, 9999px, 29px, 0);
    transform: skew(0.37deg);
  }
  50% {
    clip: rect(36px, 9999px, 45px, 0);
    transform: skew(0.72deg);
  }
  55% {
    clip: rect(12px, 9999px, 60px, 0);
    transform: skew(0.94deg);
  }
  60% {
    clip: rect(34px, 9999px, 2px, 0);
    transform: skew(0.74deg);
  }
  65% {
    clip: rect(40px, 9999px, 87px, 0);
    transform: skew(0.52deg);
  }
  70% {
    clip: rect(47px, 9999px, 43px, 0);
    transform: skew(0.84deg);
  }
  75% {
    clip: rect(93px, 9999px, 38px, 0);
    transform: skew(0.63deg);
  }
  80% {
    clip: rect(49px, 9999px, 40px, 0);
    transform: skew(0.17deg);
  }
  85% {
    clip: rect(72px, 9999px, 67px, 0);
    transform: skew(0.23deg);
  }
  90% {
    clip: rect(42px, 9999px, 73px, 0);
    transform: skew(0.91deg);
  }
  95% {
    clip: rect(43px, 9999px, 53px, 0);
    transform: skew(0.29deg);
  }
  100% {
    clip: rect(9px, 9999px, 6px, 0);
    transform: skew(0.6deg);
  }
}
/*// Same deal, just duplicated for ultra randomness.*/
@keyframes glitch-anim2 {
  0% {
    clip: rect(16px, 9999px, 64px, 0);
    transform: skew(0.39deg);
  }
  5% {
    clip: rect(10px, 9999px, 56px, 0);
    transform: skew(0.98deg);
  }
  10% {
    clip: rect(56px, 9999px, 90px, 0);
    transform: skew(0.14deg);
  }
  15% {
    clip: rect(43px, 9999px, 3px, 0);
    transform: skew(0.93deg);
  }
  20% {
    clip: rect(32px, 9999px, 85px, 0);
    transform: skew(0.91deg);
  }
  25% {
    clip: rect(61px, 9999px, 30px, 0);
    transform: skew(0.55deg);
  }
  30% {
    clip: rect(87px, 9999px, 14px, 0);
    transform: skew(0.78deg);
  }
  35% {
    clip: rect(16px, 9999px, 49px, 0);
    transform: skew(0.89deg);
  }
  40% {
    clip: rect(29px, 9999px, 96px, 0);
    transform: skew(0.52deg);
  }
  45% {
    clip: rect(5px, 9999px, 47px, 0);
    transform: skew(0.14deg);
  }
  50% {
    clip: rect(53px, 9999px, 30px, 0);
    transform: skew(0.14deg);
  }
  55% {
    clip: rect(100px, 9999px, 6px, 0);
    transform: skew(0.25deg);
  }
  60% {
    clip: rect(47px, 9999px, 13px, 0);
    transform: skew(0.98deg);
  }
  65% {
    clip: rect(86px, 9999px, 64px, 0);
    transform: skew(0.41deg);
  }
  70% {
    clip: rect(75px, 9999px, 35px, 0);
    transform: skew(0.65deg);
  }
  75% {
    clip: rect(4px, 9999px, 22px, 0);
    transform: skew(0.12deg);
  }
  80% {
    clip: rect(69px, 9999px, 78px, 0);
    transform: skew(0.61deg);
  }
  85% {
    clip: rect(39px, 9999px, 43px, 0);
    transform: skew(0.67deg);
  }
  90% {
    clip: rect(2px, 9999px, 42px, 0);
    transform: skew(0.55deg);
  }
  95% {
    clip: rect(18px, 9999px, 80px, 0);
    transform: skew(0.06deg);
  }
  100% {
    clip: rect(47px, 9999px, 10px, 0);
    transform: skew(0.79deg);
  }
}
/*// Does the same deal as before, but now only skews. Used for main text.*/
@keyframes glitch-skew {
  0% {
    transform: skew(4deg);
  }
  10% {
    transform: skew(3deg);
  }
  20% {
    transform: skew(4deg);
  }
  30% {
    transform: skew(1deg);
  }
  40% {
    transform: skew(0deg);
  }
  50% {
    transform: skew(2deg);
  }
  60% {
    transform: skew(3deg);
  }
  70% {
    transform: skew(2deg);
  }
  80% {
    transform: skew(1deg);
  }
  90% {
    transform: skew(-3deg);
  }
  100% {
    transform: skew(2deg);
  }
}

/*# sourceMappingURL=glitch.css.map */