html {
  box-sizing: border-box;
}

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

html,
body {
  width: 100%;
  height: 100%;
  margin: 0;
  padding: 0;
  color: #fff;
  text-align: center;
}

body {
  background: #ffffff url('https://images7.alphacoders.com/782/782527.jpg'); /* Background pattern from Subtle Patterns */
background-repeat: no-repeat;
  background-size: cover;
  font-family: 'Coda', cursive;
  font-size: 1em; /*16px*/
}

.container {
  display: flex;
  justify-content: center;
  align-items: center;
  flex-direction: column;
}

h1 {
  font-family: 'Open Sans', sans-serif;
  font-weight: 300;
}

/*
* Styles for the deck of cards
*/

.deck {
  width: 42.5em; /*680px*/
  min-height: 42.5em; /*680px*/
  background: linear-gradient(160deg, rgba(39, 47, 66, 0.8) 0%, rgba(98, 191, 228, 0.5) 100%);
  padding: 2em;  /*32px*/
  border-radius: 10px;
  box-shadow: 12px 15px 20px 0 rgba(46, 61, 73, 0.5);
  display: flex;
  flex-wrap: wrap;
  justify-content: space-around;
  align-items: center;
  margin: 0 0 3em;
}

.deck .card {
  height: 125px; /*125px*/
  width: 125px;
  margin: 0.2rem 0.2rem;
  background: rgba(46, 61, 73, 0.9);
  font-size: 0;
  color: #ffffff;
  border-radius: 8px;
  cursor: pointer;
  display: flex;
  justify-content: center;
  align-items: center;
  box-shadow: 5px 2px 20px 0 rgba(46, 61, 73, 0.5);
}

.deck .card.open {
  transform: rotateY(0);
  background: #86a9e3; /*#02b3e4*/
  cursor: default;
  animation-name: flipInY;
  -webkit-backface-visibility: visible !important;
  backface-visibility: visible !important;
  animation-duration: .75s;
}

.deck .card.show {
  font-size: 33px;
}

.deck .card.match {
  cursor: default;
  background: #1bc45f;
  font-size: 33px;
  animation-name: rubberBand;
  -webkit-backface-visibility: visible !important;
  backface-visibility: visible !important;
  animation-duration: .75s;

}

.deck .card.unMatch {
  animation-name: pulse;
  -webkit-backface-visibility: visible !important;
  backface-visibility: visible !important;
  animation-duration: .75s;
  cursor: default;
  background: #ffb366;
  font-size: 33px;
}


.back {
  background: #2e3d49;
  position: absolute;
  left: 0;
  top: 0;
  padding: 0;
  border: none;
  outline: none;
}

.check {
  transform: rotateY(180deg);
}

/*modal section*/

.pop-up {
  z-index: 1000;
  width: 100%;
  height: 100%;
  /*position: fixed;*/
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative;
}

.hidden{

}

.result {
position: absolute;
  top: 22.62em;
  left: 43.75em;
  width: 500px;
  max-width: 90vw;
  background-color: #b0cee8;
  box-shadow: 0 -1px 0 0.2em #646da8, 0 0.2em 0.2em 0 rgb(89, 167, 168);
  border-radius: 30px;
}
.fireworks {
  left: 0.5em;
  top: 5.5em;
}

.cup {
right: 0.5em;
  top: 6.5em;
}

.fireworks, .cup {
  max-width: 100px;
  max-height: 100px;
  display: block;
  position: absolute;
}

input#btn-submit{
  height: 30px;
}


/*footer section*/

footer {
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  color: #fff;
}

footer img {
  max-height: 1.5em;
  max-width: 1.5em;
}

footer .social {
  padding: 10px;
  background: linear-gradient(90deg, transparent, rgb(16, 107, 147), transparent);
  /*background: linear-gradient(160deg, rgba(39,47,66,0.3) 0%, rgba(98,191,228,0.5) 100%);*/
  border-radius: 15px;
}

.fa-star {
  color: #ffff99;
}

.hide {
  display: none;
}

.fa-heart {
  color: #ff6766;
}

.fa-coffee {
  color: #9af9ad;
}

/*
* Styles for the Score Panel
*/

.score-panel {
  display: flex;
  justify-content: space-around;
  align-items: center;
}

.score-panel {
  text-align: left;
  width: 456px;
  margin-bottom: 10px;
  background-color: rgba(29, 109, 141, 0.5);
  border-radius: 25px;
  padding: 10px;
}

.score-panel .star-rating {
  margin: 0;
  padding: 0;
  display: inline-block;
  margin: 0 5px 0 0;
}

.score-panel .star-rating li {
  list-style: none;
  display: inline-block;
}

.score-panel .restart {
  float: right;
  cursor: pointer;
  color: #fff;
  background-color: rgba(173, 190, 225, 0.6);
  box-sizing: border-box;
  outline: none;

}

.timer {
  display: inline-block;
  margin: 0 1rem;
}

/*.score-panel .moves {*/
/*color: #fff;*/
/*}*/

.btn {
  width: 85px;
  height: 45px;
  border-radius: 40px;
  font-family: 'Maven Pro', sans-serif;
  font-weight: bold;
  color: white;
  background: rgba(29, 109, 141, 0.5);
  border: 1px solid rgb(29, 109, 141);
  box-sizing: border-box;
  outline: none;
  font-size: 0.83em;
}

.counter span {
  display: inline-block;
  width: 100%;
}

/* animations */
@keyframes flipInY {
  from {
      transform: perspective(400px) rotate3d(0, 1, 0, 90deg);
      animation-timing-function: ease-in;
      opacity: 0;
  }

  40% {
      transform: perspective(400px) rotate3d(0, 1, 0, -20deg);
      animation-timing-function: ease-in;
  }

  60% {
      transform: perspective(400px) rotate3d(0, 1, 0, 10deg);
      opacity: 1;
  }

  80% {
      transform: perspective(400px) rotate3d(0, 1, 0, -5deg);
  }

  to {
      transform: perspective(400px);
  }
}

@keyframes rubberBand {
  from {
      transform: scale3d(1, 1, 1);
  }

  30% {
      transform: scale3d(1.25, 0.75, 1);
  }

  40% {
      transform: scale3d(0.75, 1.25, 1);
  }

  50% {
      transform: scale3d(1.15, 0.85, 1);
  }

  65% {
      transform: scale3d(.95, 1.05, 1);
  }

  75% {
      transform: scale3d(1.05, .95, 1);
  }

  to {
      transform: scale3d(1, 1, 1);
  }
}

@keyframes pulse {
  from {
      transform: scale3d(1, 1, 1);
  }

  50% {
      transform: scale3d(1.2, 1.2, 1.2);
  }

  to {
      transform: scale3d(1, 1, 1);
  }
}

