/* @keyframes pulse-intent {
  0% {
    transform: scale(-.33, .33);}
  50% {
    transform: scale(-.35, .35);
  }
  100% {
    transform: scale(-.33, .33);}
} */

@keyframes changed {
  0% {
    transform: scale(1);
  }

  30% {
    transform: scale(1);
  }

  70% {
    transform: scale(1.5);
  }

  100% {
    transform: scale(1);
  }
}

@keyframes bumpUp {
  0% {
    top: 0px;
  }

  10% {
    top: 10px;
  }

  20% {
    top: -20px;
  }

  100% {
    top: 0px;
  }
}

@keyframes bumpLeft {
  0% {
    left: 0px;
  }

  10% {
    left: -50px;
  }

  100% {
    left: 0px;
  }
}

@keyframes bumpRight {
  0% {
    left: 0px;
  }

  10% {
    left: 50px;
  }

  100% {
    left: 0px;
  }
}

@keyframes dead {
  0% {
    opacity: 100%;
  }

  50% {
    opacity: 0%;
    width: 13px;
  }

  100% {
    width: 0px;
    opacity: 0%;
  }
}

#enemy {
  position: absolute;
  top: 36%;
  left: 0px;
  width: 60%;
  display: flex;
  justify-content: space-evenly;
}

#player {
  position: absolute;
  top: 36%;
  left: 50%;
  width: 50%;
  display: flex;
  justify-content: space-evenly;
}

.sprite-wrapper {
  display: flex;
  transform: scale(8, 8);
  width: 13px;
  height: 13px;
  justify-content: center;
  position: relative;
  animation-duration: 1s;
  animation-iteration-count: 1;
}

.sprite-wrapper.enemy {
  transform: scale(-8, 8);
}

.sprite-wrapper.mounted {
  width: 26px;
}

.sprite {
  width: 13px;
  height: 13px;
  position: absolute;
  z-index: 5;
  display: flex;
  justify-content: center;
  align-items: flex-end;
}

.mounted .horse {
  width: 26px;
  height: 13px;
  z-index: 4;
}

.mounted .sprite:not(.horse) {
  top: -7px;
  left: 7px;
}

.khan {
  background: url('s.png') -52px 0;
}

.horse {
  background: url('s.png') -65px 0;
}

.king {
  background: url('s.png') 0 0;
}

.archer {
  background: url('s.png') -13px 0;
}

.knight {
  background: url('s.png') -26px 0;
}

.dervish {
  background: url('s.png') -39px 0;
}

.snake {
  background: url('s.png') 0px -13px;
}

.rok {
  background: url('s.png') -13px -13px;
}

.wolf {
  background: url('s.png') -26px -13px;
}

.bear1 {
  background: url('s.png') -39px -13px;
}

.bear2 {
  background: url('s.png') -52px -13px;
}

.intent {
  width: 8px;
  height: 13px;
  transform: scale(-.33, .33);
  position: relative;
  top: -10px;
  left: 1px;
  /* animation-name: pulse-intent;
  animation-duration: 1s;
  animation-iteration-count: infinite; */
}

.assault {
  background: url('s.png') -65px -13px;
}

.assault:hover:before, .defense:hover:before, .ability:hover:before {

  font-size: .5rem;
  position: absolute;
  display: block;
  top: -10px;
  width: 150px;
}

.assault:hover:before {
  content: "Planning to attack you!";
}

.assault-value {
  display: block;
  position: relative;
  left: 8px;
  top: -3px;
}

.intent:not(.assault) .assault-value {
  display: none;
}

.defense:hover:before {
  content: "Planning to defend itself!";
}

.defense {
  background: url('s.png') -73px -13px;
}

.ability:hover:before {
  content: "Planning something unpleasant!";
}

.ability {
  background: url('s.png') -81px -13px;
}

.hp, .affects {
  position: absolute;
  border: 1px black solid;
  min-width: 90px;
  width: 90px;
  height: 5px;
  text-align: center;
  display: flex;
  justify-content: center;
  align-items: center;
  bottom: -6px;
  transform: scale(.25, .25);
  z-index: 2;
  text-shadow: 0px 0px 5px #000;
  transition: all .25s;
}

.affects {
  bottom: -10px;
  border: none;
  font-size: .75rem;
}

.affects div.changed {
  animation-name: changed;
  animation-duration: 1s;
}

.affects div {
  text-shadow: 0px 0px 0px 0px #fff;
  transition: all .5s;
  margin: 0 5px;
}

.affects div:hover:before {
  position: absolute;
  top: 10px;
  width: 160px;
  text-align: left;
}

.affects div.armor:hover:before {
  position: absolute;
  top: 0px;
  left: -40px;
  width: 250%;
}

.stats .number {
  position: relative;
  z-index: 2;
}

.stats .fill {
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 100%;
  background: red;
  z-index: 1;
  transition: width .5s;
}

.stats .fill.armored {
  background: lightskyblue;
}

.armor {
  position: absolute;
  left: -15px;
  top: -35px;
}

.armor:hover:before {
  content: 'Defend: block X attack damage';
  top: 20px;
  width: 200%;
}

.weak:hover:before {
  content: 'Weaken: Do 25% less damage and gain 50% less defence for X turns';
}

.enrage:hover:before {
  content: 'Enrage: do 50% more damage for X turns';
}

/* .falter:hover:before {
  content: 'Falter: do 25% less damage for X turns';
} */

.enemy .stats {
  transform: scale(-.25, .25);
}

.targeting.targeted {
  box-shadow: 0px 0px 12px 10px #c0ae92;
  width: 0;
  height: 0;
  margin-top: 6px;
}
