* {
    padding: 0;
    margin: 0;
    transform:rotateZ(0);
    box-sizing: border-box;
}
body {
    background-color: #202328;
    color: #fff;
    font-family: 'Roboto Slab', serif;
    font-weight: 100;
    overflow-x: hidden;
}

header {
  display: flex;
  justify-content: center;
  width: 100%;
  margin-top: 230px;
  z-index: 1;
}
header > .inner {
  width: 100%;
  padding: 0 10px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 600px;
}
header .link {
  /* text-transform: uppercase; */
  font-style: italic;
  font-weight: 300;
  font-size: 18px;
  padding: 4px 8px 5px;
  cursor: pointer;
  border-radius: 2px;
  transition: transform 0.3s, color 0.3s;
  /* background: linear-gradient(90deg, rgba(255,0,0,0) 0%, rgba(255,0,0,1) 7%, rgba(255,196,0,1) 15%, rgba(0,255,56,1) 22%, rgba(56,187,255,1) 29%, rgba(224,250,255,1) 41%, rgba(182,255,252,1) 70%, rgba(114,255,239,1) 95%, rgba(0,212,255,0) 100%); */
  /* background-position-x: 120px; */
  /* background-repeat: no-repeat; */
  /* background-size: 200px; */
  opacity: 0.9;
  display: flex;
  flex-direction: column;
  align-items: center;
}
header .link .underline {
  width: 0px;
  height: 1px;
  background-color: #34d4c6;
  transition: width 0.3s;
}
header .link.selected {
  color: #34d4c6;
  font-weight: 400;
}
header .link.selected .underline {
  width: 100%;
}
header .link:hover {
  color: #202328;
  color: #34d4c6;
  /* background-position: -80px; */
  transform: scale(1.08);
}

.container {
  width: 100vw;
  height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
}
#content {
  width:100%;
  margin: 60px 30px 0;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.piece {
  padding: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(90deg, rgba(255,0,0,0) 0%, rgba(255,0,0,1) 10%, rgba(255,196,0,1) 22%, rgba(0,255,56,1) 33%, rgba(56,187,255,1) 43%, rgba(224,250,255,1) 58%, rgba(182,255,252,1) 87%, rgba(114,255,239,0) 100%);
  background-position-x: -200%;
  background-repeat: no-repeat;
  background-size: 150%;
  transition: transform 0.3s, background-position 0.3s, opacity 0.3s;
  position: absolute;
  top:0px;
}
.piece.hidden {
  transform: scale(0.95);
  background-position-x: 200%;
  opacity: 0;
  pointer-events: none;
}
h2 {
  font-weight: 200;
  font-size: 26px;
}
p {
  margin-bottom: 6px;
}

#game-buttons {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  position: absolute;
  top:0px;
  padding: 60px 0 0;
}

.box {
  width: 70px;
  height: 70px;
  position: relative;
  transition: width 0.3s, height 0.3s, color 0.3s, margin 0.3s, transform 0.3s, opacity 0.15s;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  text-align: center;
  margin: -17px 0 0 -52px;
  line-height: 14px;
  flex-shrink: 0;
}
.box:nth-child(even) {
  margin: -17px 0 0 52px;
}
.outline {
  width: 100%;
  height: 100%;
  position: absolute;
  top:0px;
  left:0px;
  animation: jitter 0.025s ease-in-out infinite alternate both;
}
.outline > div {
  position: relative;
  width: 100%;
  height: 100%;
}
.outline-box {
  width: 100%;
  height: 100%;
  position: absolute;
  mix-blend-mode: screen;
  top:0px;
  left:0px;
  border-radius: 2px;
  transform: rotate(45deg);
}
.red {
  border: 1px solid #f00;
  background: linear-gradient(90deg, rgba(255,0,0,0) 0%, rgba(255,0,0,1) 25%, rgba(255,0,0,1) 50%, rgba(255,0,0,0) 100%);
  background-position-x: 80px;
  background-repeat: no-repeat;
  background-size: 150px;
  transition: transform 0.3s cubic-bezier(.56,1.81,.61,.94), background-position 0.2s ease-out;
}
.green {
  border: 1px solid #0f0;
  background: linear-gradient(90deg, rgba(0,255,0,0) 0%, rgba(0,255,0,1) 25%, rgba(0,255,0,1) 50%, rgba(0,255,0,0) 100%);
  background-position-x: 80px;
  background-repeat: no-repeat;
  background-size: 150px;
  transition: transform 0.3s cubic-bezier(.56,1.81,.61,.94), background-position 0.2s ease-out;
  transition-delay: 0.04s;
}
.blue {
  border: 1px solid #00f;
  background: linear-gradient(90deg, rgba(0,0,255,0) 0%, rgba(0,0,255,1) 25%, rgba(0,0,255,1) 50%, rgba(0,0,255,0) 100%);
  background-position-x: 80px;
  background-repeat: no-repeat;
  background-size: 150px;
  transition: transform 0.3s cubic-bezier(.56,1.81,.61,.94), background-position 0.2s ease-out;
  transition-delay: 0.08s;
}

.box:hover {
  /* width: 200px;
  height: 120px; */
  color: #202328;
  font-weight: 500;
}
.box:hover .red {
  /* background-color: #f00; */
  /* transform: rotate(0); */
  transform: rotate(45deg) scale(1.05);
  background-position: -80px;
  border: 0px;
}
.box:hover .green {
  /* background-color: #0f0; */
  /* transform: rotate(0); */
  transform: rotate(45deg) scale(1.05);
  background-position: -40px;
  border: 0px;
}
.box:hover .blue {
  /* background-color: #00f; */
  /* transform: rotate(0); */
  transform: rotate(45deg) scale(1.05);
  background-position: -30px;
  border: 0px;
}

.box.hidden {
  transform: rotateY(90deg);
  opacity: 0;
}
.box.hidden .red {
  transform: rotate(45deg);
  background-position: -80px;
}
.box.hidden .green {
  transform: rotate(45deg);
  background-position: -40px;
}
.box.hidden .blue {
  transform: rotate(45deg);
  background-position: -30px;
}

#timeScale {
    position: absolute;
    z-index: 1;
}

#education {
  padding: 20px 20px 60px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  position: absolute;
  top:0px;
}
#education .piece {
  position: static;
  padding: 0;
  width: 100%;
  max-width: 500px;
  margin-bottom: 10px;
}
#education .piece.hidden {
  transform: rotateX(90deg) translateY(40px);
}
#education .piece:hover {
  transform: scale(1.03);
}
.ed-link {
  display: block;
  padding: 0 0 0 20px;
}
#education .piece h4 {
  font-weight: 300;
  font-size: 18px;
  margin-bottom: 5px;
  transition: color 0.3s;
}
#education .piece:hover h4 {
  color: #34d4c6;
}
#education .piece p {
  font-size: 12px;
}
#education a {
  color: #fff;
  text-decoration: none;
}
a {
  color: #34d4c6;
  text-decoration: none;
}
a:hover {
  text-decoration: underline;
}

.game.piece {
  flex-direction: column;
  align-items: flex-start;
  width: 100%;
  max-width: 540px;
}
.game h4 {
  font-weight: 200;
  font-size: 26px;
  margin-bottom: 5px;
}
.game p {
  margin-bottom: 20px;
  font-size: 12px;
}
.vimeo-container {
  width: 100%;
  position: relative;
  padding-top: 56.25%;
  box-shadow: 0 0 20px #000000C2;
}
.vimeo-container > iframe {
  width: 100%;
  height: 100%;
  position: absolute;
  top: 0px;
  left: 0px;
}
.close-button {
  width: 100%;
  padding: 20px 0 0;
  cursor: pointer;
  font-size: 14px;
  text-align: center;
}

.thumbnail {
  width: 80px;
  height: 80px;
  flex-shrink: 0;
  mix-blend-mode: screen;
}
#twitterLink {
  width: 20px;
  margin: 6px 0 0 20px;
}
#mailLink {
  width: 20px;
  margin: 6px 0 0 10px;
}

@keyframes jitter {
  0% {
    transform: scale(0.99);
    opacity: 0.95;
  }
  100% {
    transform: scale(1);
    opacity: 0.85;
  }
}
