

*, *::after, *::before {
  box-sizing: border-box;
}

html {
  font-size: 62.5%;
}

body {
  font-size: 1.6rem;
  margin: 0;
  height: 100vh;
  background: url(../images/bg_1920.jpg) no-repeat center center fixed #fce300;
	  -webkit-background-size: cover;
	  -moz-background-size: cover;
	  -o-background-size: cover;
	  background-size: cover;
  font-family: "Mouse Memoirs", "Montserrat", "Arial", sans-serif;
  letter-spacing: 1px;
}

.drawer {
  width: 80%;
  margin: 0 auto;
  padding-top: 50px;
}

.board {
  display: flex;
  flex-wrap: wrap;
  width: 320px;
  height: 320px;
  margin: 0 auto;
}

.cell {
  position: relative;
  width: 90px;
  height: 90px;
  margin: 5px;
  border-radius: 0.3em;
  background: url("../images/bg_card.png") no-repeat center center #f3da00;
}

.cell.circle,
.cell.cross {
  background: transparent;
}

.circle::after,
.cross::before,
.cross::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
}

.cross::before,
.cross::after {
  width: 5px;
  height: 75px;
  background: #147edc;
}

.playing .cross::before,
.playing .cross::after {
  background: #226bac;
}

.cross::before {
  transform: translate(-50%, -50%) rotate(45deg);
}

.cross::after {
  transform: translate(-50%, -50%) rotate(-45deg);
}

.circle::after {
  width: 70px;
  height: 70px;
  border-radius: 50%;
  transform: translate(-50%, -50%);
  border: 5px solid #ff9900;
}

.playing .circle::after {
  border-color: #ff6600;
}

.playing .cell:not(.cross):not(.circle) {
  cursor: pointer;
}

.playing .cell:not(.cross):not(.circle):hover {
  background: #0054ff;
}

#instructions {
  display: none;
}

.message {
  text-align: center;
  color: #c40d0d;
  font-size: 3rem;
}

.play-btn {
  position: absolute;
  top: 0;
  left: 50%;
  outline: none;
  border: none;
  cursor: pointer;
  background: #000000;
  padding: 1rem 1.5rem;
  font-size: 2.4rem;
  color: #18db03;
  border-radius: 0 0 0.2rem 0.2rem;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
  border: 1px solid #000000;
  transform: translate(-50%, 0);
  transition: transform 200ms ease-out;
}

.play-btn:hover {
  background: #18db03;
  color: #000000;
  border: 1px solid #18db03;
}

.play-btn.hide {
  display: inline-block;
  transform: translate(-50%, -100%);
}

header {
  max-width: 320px;
  margin: 0 auto 20px;
}

.scores {
  display: flex;
  justify-content: space-between;
  position: relative;
  max-width: 320px;
  margin: 2rem auto 0;
  border-top: 2px solid #ff0000;
  padding-top: 2rem;
  opacity: 1;
  transform: translate(0, 0);
  transition: all 200ms 75ms ease-out;
}

.scores.hide {
  display: flex;
  opacity: 0;
  transform: translate(0, 20%);
}

.scores div {
  flex: 1;
}

.scores span {
  display: block;
  color: #3b2b3b;
}

.scores ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: inline-block;
}

.scores li {
  width: 10px;
  height: 10px;
  border: 2px solid #3b2b3b;
  border-radius: 50%;
  display: inline-block;
}

.scores li.won {
  background: #997599;
  -webkit-animation: win 300ms;
          animation: win 300ms;
}

@-webkit-keyframes win {
  0% {
    transform: scale(1);
  }
  40% {
    transform: scale(3);
  }
  100% {
    transform: scale(1);
  }
}

@keyframes win {
  0% {
    transform: scale(1);
  }
  40% {
    transform: scale(3);
  }
  100% {
    transform: scale(1);
  }
}
.scores::after {
  display: none;
  content: "vs";
  position: absolute;
  left: 50%;
  top: 50%;
  font-size: 2.4rem;
  transform: translate(-50%, -50%);
  color: #bdbdbd;
}

.scores > div:last-child {
  text-align: right;
}

.hide {
  display: none;
}

.dice-roll {
  text-align: center;
  padding: 1rem;
  font-size: 2.4rem;
}

	@media only screen and (max-width: 1440px) {
		body { background: url(../images/bg_1440.jpg) no-repeat center center fixed #f3da00; }
	}

	@media only screen and (max-width: 1024px) {
		body { background: url(../images/bg_1024.jpg) no-repeat center center fixed #f3da00; }
	}

	@media only screen and (max-width: 800px) and (orientation:portrait) {
		body { background: url(../images/bg_800_p.jpg) no-repeat center center fixed #f3da00; }
	}

	@media only screen and (max-width: 800px) and (orientation:landscape) {
		body { background: url(../images/bg_800_l.jpg) no-repeat center center fixed #f3da00; }
	}
