html {
    box-sizing: border-box;
}

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

html,
body {
    margin: 0;
    padding: 0;
}

body {
    background: linear-gradient(160deg, #02ccba 0%, #aa7ecd 100%);
    font-family: 'Montserrat', sans-serif;
    min-height:100vh;
}

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

.title {
    font-family: 'Montserrat', sans-serif;
    font-weight: 700;
    color:white;
    font-size:3rem;
}

.title img {
    width:50px;
    margin:0 10px;
    vertical-align: text-top;
}

/*
 * Styles for the deck of cards
 */

.deck {
    width: 660px;
    min-height: 680px;
    background-color: #ccc;
    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: #0a3d62;
    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);
}

.card img {display:none;}
.card.show img {display:block;}
.card.match img {display:block;}

.deck .card.open {
    transform: rotateY(180);
    background: #fff;
    cursor: default;
}

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

.deck .card.match {
    cursor: default;
    background: #1dd1a1;
    /*background-color: #1abc9c;*/
    font-size: 33px;
}

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

.card img {width:100px;}


/*
 * Styles for the Score Panel
 */

.score-panel {
    text-align: left;
    width: 660px;
    margin-bottom:20px;
    color:white;
    padding:0 10px;
}

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

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

.score-panel .restart {
    float: right;
    cursor: pointer;
}


.score-panel .timer {
    padding-left:10px;}



/*
====================
  Congrats Pop-ups
====================
*/


.overlay {
    height: 100%;
    width: 100%;
    position: fixed;
    z-index: 1;
    top: 0;
    left: 0;
    background-color: white;
    background-color: rgba(230,230,230, 0.95);
    overflow-x: hidden;
    transition: 0.5s;
    display:none;
}

.overlay-content {
    position: relative;
    top: 20%;
    width: 100%;
    text-align: center;
    margin-top: 30px;
}

.overlay-content button {
    background:#2ecc71;
    border-radius: 20px;
    border:0;
    padding:10px 20px;
    color:white;
    font-size:2em;
    cursor:pointer;
}

.overlay-content button:hover {
    background:#27ae60;
    /*font-size:1em;*/
}

.overlay-content .stars {
    margin: 0;
    padding: 0;
    display: inline-block;
    margin: 0 5px 0 0;
    font-size:30px;
    color:#ffa502;
}

.overlay-content .stars li {
    list-style: none;
    display: inline-block;
    margin:0 10px;
}






footer {
    color:white;
    text-align:center;
    font-weight: normal;
    font-size:14px;
}

footer a {
    color:white;
    text-decoration: none;
    font-weight:bold;
}

footer a:hover {
    text-decoration: underline;
}








/*
====================
  Media Queries
====================
*/



@media screen and (min-width: 500px) and (max-width: 750px) {

.title {
    font-size:2.2rem;
}

.score-panel {width:400px;}

.score-panel .timer {
    padding-left:70px;
}

.deck {
    width: 400px;
    min-height: 420px;
    background-color: #ccc;
    padding: 20px;
}

.deck .card {
    height: 75px;
    width: 75px;
}

.card img {
    width:60px;
}

.overlay-content {
    top:10%;
}

}



@media screen and (max-width: 500px)  {

.title {
    font-size:1.6rem;
}

.title img{
    width:35px;
}

.score-panel {width:280px;}

.score-panel .timer {
    padding-left:10px;
}

.deck {
    width: 280px;
    min-height: 300px;
    background-color: #ccc;
    padding: 15px;
}

.deck .card {
    height: 55px;
    width: 55px;
}

.card img {
    width:40px;
}


.overlay-content img {
    width:200px;
}

.overlay-content {
    top:5%;
}
}
