html {
  box-sizing: border-box;
}

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

html,
body {
  width: 100%;
  height: 100%;
  margin: 0;
  padding: 0;
}

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

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

/*
 * Styles for card frame
 */

.card_frame {
  width: 50vw;
  height: 70vh;
  background: linear-gradient(160deg, #02ccba 0%, #aa7ecd 100%);
  padding: 1em 1.5em;
  border-radius: 10px;
  box-shadow: 12px 15px 20px 0 rgba(46, 61, 73, 0.5);
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  margin: 0 0 1.5em;
}

.card_frame .card {
  height: calc((100% / 4) - 20px);
  width: calc((100% / 4) - 20px);
  background: #2e3d49;
  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);
  transition: all 0.5s;
}

.card_frame .card.open {
  transform: rotateY(360deg);
  background: #02b3e4;
  cursor: default;
}

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

.card_frame .card.match {
  transform: rotate(360deg);
  cursor: default;
  background: #02ccba;
  font-size: 33px;
}

/*
 * Styles for the Score Panel
 */

.score-panel {
  text-align: left;
  width: 35%;
  margin-bottom: 10px;
  display: flex;
  justify-content: space-between;
}

.score-panel .stars {
  margin: 0;
  padding: 0;
  display: inline-block;
  margin: 0 5px 0 0;
  color: yellowgreen;
}

.score-panel .stars li {
  list-style: none;
  display: inline-block;
  padding-top: 0;
}

.score-panel .reset {
  cursor: pointer;
}

/*
 * Styles for the Modal
 */

.bg-modal {
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.5);
  position: absolute;
  top: 0;
  /* display: flex; */
  justify-content: center;
  align-items: center;
  font-family: "Trebuchet MS", "Lucida Sans Unicode", "Lucida Grande",
    "Lucida Sans", Arial, sans-serif;
  display: none;
}

.modal-content {
  width: 45%;
  height: 300px;
  background-color: #02ccba;
  border-radius: 10px;
  padding: 20px;
  text-align: center;
  color: #fff;
  position: relative;
}

.close-modal {
  padding: 5px 12px;
  border-radius: 4px;
  border: 1px solid #fff;
  color: #fff;
  text-transform: uppercase;
  text-decoration: none;
}

.close-modal:hover {
  background-color: #fff;
  color: #02ccba;
}

.modalrate {
  display: flex;
  justify-content: center;
}

.modalrate .stars {
  display: flex;
  list-style: none;
  color: yellow;
}

/*
 * Styles for the Footer
 */

footer {
  font-weight: bold;
  font-family: Arial, Helvetica, sans-serif;
}

/*
 * Media Queries
 */
@media screen and (max-width: 900px) {
  .card_frame {
    /* width: 50vw; */
    height: 50vh;
    padding: 0.5em 1em;
    margin: 0 0 1.5em;
  }

  .score-panel {
    /* text-align: left; */
    width: 48%;
    font-size: 12px;
    margin-bottom: 5px;
    font-weight: bold;
    /* display: flex; */
    /* justify-content: space-between; */
  }

  .card_frame .card {
    height: calc((100% / 4) - 5px);
    width: calc((100% / 4) - 5px);
  }
}
