@import url("https://fonts.googleapis.com/css?family=Major+Mono+Display");
:root {
  --Hsl: 140;
  --hsL: 40;
}

body {
  position: relative;
  margin: 0;
  padding: 60px 0 60px 0;
  min-height: calc(100vh - 120px);
  display: flex;
  justify-content: center;
  align-items: center;
}
body:after, body:before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100%;
  background-repeat: no-repeat;
  background-size: cover;
  background-position: center;
  transition: all 0.3s cubic-bezier(0.455, 0.03, 0.515, 0.955);
}
body:after {
  background: radial-gradient(circle, hsl(var(--Hsl), 89%, 86%) 0%, #fafafa 100%);
  opacity: 1;
  z-index: -1;
}
body:before {
  background: radial-gradient(circle, hsl(var(--Hsl), 29%, 6%) 0%, #2e2e2e 100%);
  opacity: 0;
}

.tesseract {
  width: 60vw;
  max-height: calc(100vh - 120px);
  filter: drop-shadow(3px 3px 4px rgba(0, 0, 0, 0.4));
  stroke: #2D4671;
  opacity: 0;
  transition: stroke 0.3s cubic-bezier(0.455, 0.03, 0.515, 0.955);
}
.tesseract .up {
  fill: hsl(var(--Hsl), 72%, 78%);
}
.tesseract .left {
  fill: hsl(var(--Hsl), 39%, 34%);
}
.tesseract .right {
  fill: hsl(var(--Hsl), 39%, 54%);
}
.tesseract polygon {
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-miterlimit: 10;
}
.tesseract .cube,
.tesseract polygon[class*=cube] {
  -webkit-animation: pulse 3.6s cubic-bezier(0.455, 0.03, 0.515, 0.955) infinite;
          animation: pulse 3.6s cubic-bezier(0.455, 0.03, 0.515, 0.955) infinite;
  -webkit-animation-play-state: running;
          animation-play-state: running;
}
.tesseract .cube-1 {
  -webkit-animation-delay: 0.225s !important;
          animation-delay: 0.225s !important;
}
.tesseract .cube-2 {
  -webkit-animation-delay: 0.45s !important;
          animation-delay: 0.45s !important;
}
.tesseract .cube-3 {
  -webkit-animation-delay: 0.675s !important;
          animation-delay: 0.675s !important;
}
.tesseract .cube-4 {
  -webkit-animation-delay: 0.9s !important;
          animation-delay: 0.9s !important;
}
.tesseract .cube-5 {
  -webkit-animation-delay: 1.125s !important;
          animation-delay: 1.125s !important;
}
.tesseract .cube-6 {
  -webkit-animation-delay: 1.35s !important;
          animation-delay: 1.35s !important;
}
.tesseract .cube-7 {
  -webkit-animation-delay: 1.575s !important;
          animation-delay: 1.575s !important;
}
.tesseract .cube-8 {
  -webkit-animation-delay: 1.8s !important;
          animation-delay: 1.8s !important;
}
@-webkit-keyframes pulse {
  0%, 40% {
    transform: scale(1);
    opacity: 1;
  }
  20% {
    transform: scale(0);
    opacity: 0;
  }
}
@keyframes pulse {
  0%, 40% {
    transform: scale(1);
    opacity: 1;
  }
  20% {
    transform: scale(0);
    opacity: 0;
  }
}

.controls {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  display: flex;
  justify-content: space-between;
}
.controls h5 {
  font-family: "Major Mono Display", monospace;
  font-size: 10px;
  color: hsl(var(--Hsl), 72%, 20%);
  margin: 0;
  margin-top: 6px;
  transition: color 0.3s cubic-bezier(0.455, 0.03, 0.515, 0.955);
}
.controls > div {
  display: flex;
  justify-content: center;
  align-items: center;
  flex-direction: column;
  width: 33%;
  padding-top: 5px;
  text-align: center;
}
.controls > div:first-of-type h5 span:first-of-type {
  display: inline-block;
}
.controls > div:first-of-type h5 span:last-of-type {
  display: none;
}
.controls .svg-wrap {
  display: flex;
  align-items: flex-end;
  height: 36px;
}
.controls .dragIndicator {
  width: 60px;
  stroke: hsl(var(--Hsl), 72%, 20%);
  opacity: 0.9;
  transition: all 0.4s cubic-bezier(0.455, 0.03, 0.515, 0.955);
}
.controls .dragIndicator #arrows {
  opacity: 0.6;
}
.controls .dragIndicator .mouse {
  -webkit-animation: BandF 2s cubic-bezier(0.455, 0.03, 0.515, 0.955) infinite;
          animation: BandF 2s cubic-bezier(0.455, 0.03, 0.515, 0.955) infinite;
}
@-webkit-keyframes BandF {
  0%, 100% {
    transform: translateX(-3px);
  }
  50% {
    transform: translateX(3px);
  }
}
@keyframes BandF {
  0%, 100% {
    transform: translateX(-3px);
  }
  50% {
    transform: translateX(3px);
  }
}
.controls .toggle-lightMode svg {
  width: 36px;
  -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
  -webkit-tap-highlight-color: transparent;
}
.controls .toggle-lightMode svg:hover {
  cursor: pointer;
}
.controls .toggle-lightMode h5 span:first-of-type {
  display: inline-block;
}
.controls .toggle-lightMode h5 span:last-of-type {
  display: none;
}
.controls .toggle-lightMode #toggle-mode {
  filter: drop-shadow(0px 0px 5px hsl(var(--Hsl), 72%, 100%));
}
.controls .toggle-lightMode .day {
  fill: hsl(var(--Hsl), 100%, 80%);
  opacity: 1;
}
.controls .toggle-lightMode .night {
  transform: translateY(-100%);
  fill: #2e3e46;
  opacity: 0;
  transition: all 0.3s cubic-bezier(0.455, 0.03, 0.515, 0.955);
}
.controls .play-pause {
  width: 30px;
  height: 30px;
  opacity: 0.6;
  -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
  -webkit-tap-highlight-color: transparent;
}
.controls .play-pause path {
  fill: hsl(var(--Hsl), 72%, 40%);
}
.controls .play-pause #play,
.controls .play-pause #pause {
  transition: 0.3s cubic-bezier(0.455, 0.03, 0.515, 0.955);
  transition-property: transform, opacity;
  transform-origin: 15px 15px;
}
.controls .play-pause #play {
  transform: scale(0);
  opacity: 0;
}
.controls .play-pause #pause {
  transform: scale(1);
  opacity: 1;
}
.controls .play-pause:hover {
  cursor: pointer;
}
@media (max-width: 400px) {
  .controls h5 {
    font-size: 8px;
  }
}

body.darkMode:after {
  opacity: 0;
}
body.darkMode:before {
  opacity: 1;
}
body.darkMode .toggle-lightMode .night {
  transform: translateY(0%);
  opacity: 1;
}
body.darkMode .toggle-lightMode h5 span:first-of-type {
  display: none;
}
body.darkMode .toggle-lightMode h5 span:last-of-type {
  display: inline-block;
}
body.darkMode .tesseract {
  filter: drop-shadow(2px 2px 2px rgba(255, 255, 255, 0.4));
  stroke: #c5c5c5;
}
body.darkMode .tesseract .up {
  fill: hsl(var(--Hsl), 62%, 90%);
}
body.darkMode .tesseract .left {
  fill: hsl(var(--Hsl), 29%, 46%);
}
body.darkMode .tesseract .right {
  fill: hsl(var(--Hsl), 29%, 66%);
}
body.darkMode .dragIndicator {
  stroke: hsl(var(--Hsl), 72%, 96%);
}
body.darkMode .play-pause {
  filter: drop-shadow(2px 2px 2px rgba(255, 255, 255, 0.3));
}
body.darkMode .play-pause path {
  fill: hsl(var(--Hsl), 72%, 90%);
}
body.darkMode h5 {
  color: hsl(var(--Hsl), 72%, 96%);
}

body.togglePaused .tesseract .cube,
body.togglePaused .tesseract polygon[class*=cube] {
  -webkit-animation-play-state: paused;
          animation-play-state: paused;
}
body.togglePaused .controls > div:first-of-type h5 span:first-of-type {
  display: none;
}
body.togglePaused .controls > div:first-of-type h5 span:last-of-type {
  display: inline-block;
}
body.togglePaused .play-pause #play {
  transform: scale(1);
  opacity: 1;
}
body.togglePaused .play-pause #pause {
  transform: scale(0);
  opacity: 0;
}