:root{
    --tipoletra: SweetPineapple;
    --colorverde: rgba(30, 185, 69, 0.5);
    --CursorJuego: url(../Assets/Cursores/BlueCGC.cur), auto;
    --CursorNivel: url(../Assets/Cursores/WhiteCGC.cur), auto;
    --CardRadius: 12px;
}

@font-face {
    font-family:"SweetPineapple";
    src: url("../Assets/Fonts/sweetpineapple-webfont.woff") format("woff"), 
    url("../Assets/Fonts/sweetpineapple-webfont.woff2") format("woff2")
}

*{
    box-sizing: border-box;
    
}

html{
    min-height: 100vh;
    cursor: url(../Assets/Cursores/BlueCGC.cur), auto;
}

body{
    margin: 0;
    background: #3ba07d93;  /* fallback for old browsers */
    background: -webkit-linear-gradient(to right, #93F9B9, #1d976c93);  /* Chrome 10-25, Safari 5.1-6 */
    background: linear-gradient(to right, #93F9B9, #1d976c91); /* W3C, IE 10+/ Edge, Firefox 16+, Chrome 26+, Opera 12+, Safari 7+ */

    zoom: 80%;
}

.page-titulo{
    color:#31a821;
    font-family: var(--tipoletra), serif;
    font-weight: 900;
    text-align: center;
    font-size: 96px;
}

.juego-info-container{
    grid-column: 1/-1;
    display: flex;
    justify-content: space-between;
}

.juego-info{
    font-family: var(--tipoletra), serif;
    color:#27a117;
    font-size: 50px;


}

.juego-container{
    display: grid;
    grid-template-columns: repeat(4, auto);
    grid-gap: 10px;
    margin: 50px;
    justify-content: center;
    perspective: 500px;
    zoom: 90%;
}

.card{
    position: relative;
    background-color: rgb(27, 143, 62);
    height: 175px;
    width: 125px;
    border-radius: 12px;
    
}

.card:hover{
    cursor: url(../Assets/Cursores/WhiteCGC.cur), auto;
}

.card.visible .card-atras{
    transform: rotateY(-180deg);
}

.card.visible .card-frente{
    transform: rotateY(0);
}

.card:hover .card-value{
    animation: dance 1s linear infinite 500ms;
}

.overlay-text{
    display: none;
    position: fixed;
    font-weight: 800;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    justify-content: center;
    align-items: center;
    z-index: 100;
    color: var(--colorverde);
    font-family: var(--tipoletra), serif;
}

.overlay-text-small{
    font-size: .3em;
}

.overlay-text.visible{
    display: flex;
    flex-direction: column;
    animation: overlay-grow 500ms forwards;
}

.tinstrucciones{
  margin-bottom: 5px;  
}

@keyframes overlay-grow {
    from{
        background-color: rgba(0,0,0,0);
        font-size: 0;
    } to{
        background-color: rgba(0,0,0,0.9);
        font-size: 100px ;
    }
}


@keyframes dance {
    0%, 100%{
        transform: rotate(0);
    }
    25%{
        transform: rotate(-30deg);
    }
    75%{
        transform: rotate(30deg);
    }
}

.card-cara{
    position: absolute;
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
    backface-visibility: hidden;
    border-radius: 12px;
    border-width: 1px;
    border-style: solid;
    transition: transform 500ms ease-in-out;
}

.card-atras{
    background-color: rgba(47, 190, 90, 0.349);
    border:4px solid rgba(162, 229, 179, 0.747);
    border-radius: 12px;
    


}
.card-frente{
    transform: rotateY(180deg); 
    border-color: #0d8030;
    background-color: rgba(88, 165, 111, 0.349);
    border-radius: 12px;
}

.card-value{
    transition: transform 100ms ease-in-out;
    transform: scale(0.9);
}

.card-frente:hover .card-value{
    transform: scale(1);
}

.leaf{
   position: absolute; 
   width: 37px;
   height: 37px;
   transition: width 100ms ease-in-out, heigth 100ms ease-in-out;
}

.card-cara:hover .leaf{
    width: 42px;
    height: 42px;
}

.leaf-top-left{
    transform: rotate(137deg);
    top:-8px;
    left: -7px;
}

.leaf-top-right{
    transform: rotate(227deg);
    top:-6px;
    right: -8px;
}

.leaf-bottom-left{
    transform: rotate(47deg);
    bottom: -6px;
    left: -8px;
}

.leaf-bottom-right{
    transform: rotate(315deg);
    bottom:-8px;
    right: -6px;
}

.estrella{
    width: 75px;
    align-self: center;
    transform: translateY(-10);
    transition: transform 100ms ease-in-out;
}

.card-atras:hover .estrella{
    transform: translateY(0) ;
    width: 90px;
}

.overlay-text .instrucciones{
    font-size: 40px;
    font-weight: 700;
}

.lvl-container{
    max-width: 500px;
    max-height: 100px;
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
}
.btn-lvl{
    color:seashell;
    background-color: rgb(28, 90, 12);
    padding: 15px 5px;
    margin: 15px;
    border: 2px solid transparent;
    border-radius: 6px;
    box-shadow: 3px 3px 10px 0px rgba(255, 255, 255, 0.219);
    transition: 200ms ease-in-out
     
}

.btn-lvl:hover{
    color:rgb(28, 90, 12); 
    background-color: rgb(255, 245, 238);
    box-shadow: 3px 3px 10px 5px rgb(28, 90, 12); 
    cursor: pointer;
    
}

.volver{
    display: block;    
    width: 150px;
    height: 50px;
    margin: 0 auto;
    
}

.lvl-container-index{
    height: 300px;
    width: 90%;
    margin: 0 auto;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    
}

.btn-index{
    margin: 25px;
    padding: 60px 110px;
    font-size: 50px;
    border-radius: 30px;
}



@media (max-with: 600px) {
    .juego-container{
        grid-template-columns: repeat(2, auto);
    }

    .juego-info-container{
        flex-direction: column;
        align-items: center;
    }
    
}