html {
    box-sizing: border-box;
}

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

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

body {
    background-image: url('../img/geometry2.png'); /* Background pattern Freepik.com */
    font-family: 'Lato', sans-serif;
    height: 100%;
    background-position: center;
    background-repeat: no-repeat;
    background-size: cover;
}

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

h1 {
    font-family: 'Open Sans', sans-serif;
    font-weight: bold;
    color: #433F5D;
}
.game_title {
    font-family: 'Lobster', cursive;
    font-size: 48px;
}

/*
 * Styles for the deck of cards
 */

.deck {
    width: 660px;
    min-height: 680px;
    background:  #cccdce ;
    padding: 32px;
    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 3em;
}

.deck .card {
    height: 125px;
    width: 125px;
    background: #433F5D;
    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: #e5c7c1;
    cursor: default;
}

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

.deck .card.match {
    cursor: default;
    background: #baa19c;
    font-size: 33px;
}

/*
 * Styles for the Score Panel
 */

.score-panel {
    text-align: left;
    width: 345px;
    margin-bottom: 10px;
    color: #433F5D;
    font-weight: bold;
    font-family: 'Lato', sans-serif;
}

.score-panel .stars {
    padding-left: 48px;
    display: inline-block;
    margin: 0 5px 0 0;
    color: #433F5D;
}

.score-panel .stars li {
    list-style: none;
    display: inline-block;
}
.score-panel .clock {
    display : inline-block;
    text-align: center;
    color: white;
    margin-left: 40px;
    border-radius: 5px;
    width: 90px;
    height: 27px;
    background-color: #e5c7c1;
}

.score-panel .restart {
    float: right;
    cursor: pointer;
    background-color: #e5c7c1;
    border-radius: 4px;
    padding: 4px;
}
.restart:hover {
    color: #d46391;
    background-color: #433F5D;
    color: white;
}

/*
 * Styles for Modal Popup
 */
 .modal_background {
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    width: 100%;
    background: rgba(0, 0, 0, 0.438); /* See through effect */
 }

 .hide {
    display: none;
 }

 .modal_body {
    position: relative;
    top: 50%;
    left: 50%;
    height: 50%;
    width: 400px;
    background: url('../img/1051.jpg'); /* Background pattern Freepik.com */
    background-position: center;
    background-repeat: no-repeat;
    background-size: cover;
    transform: translate(-50%, -70%);
    border-radius: 10px; 
 }
 .modal_heading {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 1.5rem;
    border-bottom: 1px solid gray;
}
.modal_title {
    text-transform: uppercase;
    padding-top: 18px;
}
.modal_cancel {
    color: #433F5D;
    background-color: #FFFAEE;
    cursor: pointer;
    border-radius: 4px;
    padding: 2px;
    margin: 10px;
    float: right;
}

/* Changes the color of the modal's close button when hover */
.modal_cancel:hover {
    background-color: #433F5D;
    color: white;
}

.modal_stats {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 1rem;
    border-bottom: 1px solid gray;
    color: #433F5D;
    font-weight: bold;

}

.modal_buttons {
    display: flex;
    justify-content: space-around;
    padding: 1rem;
}

.modal_button {
    width: 60px;
    height: 30px;
    font-size: 14px;
    border-radius: 4px;
    cursor: pointer;
    background-color: #e5c7c1;
    color: #433F5D;
    font-weight: bold;
}
.modal_button:hover {
    background-color: #433F5D;
    color: white;
}

/*-----------FOOTER------------*/
footer {
    background-color: #EBECED;
    color: #433F5D;
    padding: 24px;
    text-align: center;
}

footer a {
    text-decoration: none;
}

footer a:hover {
    color: #433F5D;
    text-decoration: none;
}
