@keyframes redToYellow {
    from {background-color: red;}
    to {background-color: yellow;}
}

body {
  position: absolute;
  right: 0;
  bottom: 0;
  margin: 0;
  padding: 0;
  min-width: 100%;
  min-height: 100%;
  width: auto; height: auto;
  background-color: red;
  animation-name: redToYellow;
  animation-duration: 6s;
  animation-direction: alternate-reverse;
  animation-iteration-count: infinite;
  overflow: hidden;
  }

  #text {
    position: absolute;
    top: -1000px;
    z-index: 10;
    opacity: 0;
  }

  #speak {
    position:absolute;
    top:0;
    left: 0;
    margin: 5px;
    padding: 15px;
    border-radius: 20px;
    background: blue;
    padding: 5px;
    border-color: lightblue;
    font-size: 2em;
    font-family: 'Ubuntu', sans-serif;
    color: white;
    z-index:700;"
  }

  .background    { background: rgba(0, 0, 0, 0);/*rgb(52, 166, 251);*/
                 table-layout: fixed;
                 border-spacing: 0;
               }
.background td { padding: 0; }
.lava          { background: linear-gradient(0deg, rgba(255,16,0,1) 0%, rgba(255,214,0,1) 100%); }
.wall          { background: #935100; }/*white*/

.actor  { position: absolute;            }
.coin   { background-image: url(bitcoin.svg);}
.player { background: rgb(64, 64, 64);   }
.monster   { background-image: url(ethereum.svg);
  background-color: rgba(256, 0,0,0.45);
  box-shadow:0px 0px 50px 10px red;}
/*.box-shadow: -4px -7px 8px red, 4px -7px 8px red;
  monster { background: linear-gradient(0deg, rgba(20,161,0,1) 0%, rgba(0,255,29,1) 100%);}*/

.lost .player {
  background: rgb(160, 64, 64);
}
.won .player {
  box-shadow: -4px -7px 8px white, 4px -7px 8px white;
}

.game {
  overflow: hidden;
  max-width: 99vw;
  max-height: 99vh;
  position: relative;
  /*margin: auto;*/
}

canvas {
  width: 100%;
  margin: auto;
}

#bitcoin {
  position:absolute;
  bottom: 0;
  color: white;
  font-size: 36pt;
  z-index: 500;
  font-family: 'Ubuntu', sans-serif;
}
#bitcoin.h1 {
  margin-bottom: 0;
  padding-bottom: 0;
}

/*Emoticons*/
@keyframes topToBottom {
  0% {
    position: absolute;
    top: -500px;
    left: 0;
  }
  50% {
    position: absolute;
    top: 40%;
    left: 60%
  }
  100% {
    position: absolute;
    top: 100%;
    left: 0;
  }
}
@keyframes bottomToTop {
  0% {
    position: absolute;
    top: 5000px;
    left: 80%;
  }
  25% {
    position: absolute;
    top: 40%;
    left: 40%
  }
  35% {
    position: absolute;
    top: 20%;
    left: 20%
  }
  50% {
    position: absolute;
    top: -800px;
    left: 0;
  }
  75% {
    position: absolute;
    top: -100px;
    left: 0;
  }
  85% {
    position: absolute;
    left: 80%;
    top: 80%;
  }
  100% {
    position: absolute;
    left: 20%;
    top: 15000px;
  }
}
.happy {
  font-size: 15em;
  position: absolute;
  left: 0;
  top: -500px;
	color: black;
  animation-name: topToBottom;
  animation-duration: 6s;
  animation-iteration-count: infinite;
  animation-delay: 5s;
  z-index: 200;
}
.sad {
  font-size: 15em;
  position: absolute;
  right: 0;
  top: 10000px;
	color: black;
  animation-name: bottomToTop;
  animation-duration: 6s;
  animation-iteration-count: infinite;
  animation-delay: 15s;
  z-index: 300;
}
/* Pyramid */
.container {
  width: 400px;
  height: 400px;
  position: absolute;
  left: 30%;
  right: 30%;
  top: 10%;
  perspective: 300px;
  perspective-origin: 50% 40%;
  z-index: 300;
}

.side {
  position: absolute;
  left: 140px;
  top: 150px;
  width: 0;
  height: 0;
  border-left: 60px solid transparent;
  border-right: 60px solid transparent;
  border-bottom: 120px solid rgba(0,180,0,0.5);
  transform-origin: 50% 0%;
  animation: spin 5s infinite linear;
}

.back {
  animation-delay: -2.5s;
}

.right {
  animation-delay: -1.25s;
}

.left {
  animation-delay: -3.75s;
}

@keyframes spin {
  0% {
    transform: rotateY(0deg) rotateX(30deg);
    border-bottom-color: lighten(green, 5%);
  }
  25% {
    transform: rotateY(90deg) rotateX(30deg);
    border-bottom-color: darken(green, 5%);
    opacity: 1;
  }
  25.1% {
    opacity: 0;
  }
  50% {
    transform: rotateY(180deg) rotateX(30deg);
    border-bottom-color: darken(green, 12%);
  }
  74.9% {
    opacity: 0;
  }
  75% {
    transform: rotateY(270deg) rotateX(30deg);
    border-bottom-color: darken(green, 15%);
    opacity: 1;
  }
  100% {
    transform: rotateY(360deg) rotateX(30deg);
    border-bottom-color: lighten(green, 5%);
  }
}
