@import url('https://fonts.googleapis.com/css2?family=Merienda:wght@300..900&display=swap');

:root{
    /* --bg-back: #fafcf3; */
    --bg-back: #ffe4c4;
    --bg-front: #a9a9a9;
    --bg-grid: #331515;
    --img-logo: url(../assets/LogoTRR_800x800-2.png);
    --img-perfil: url(../assets/perfil.png);
    --bg_txt_outline-button: #ffe4c4;
    --bg-button: #350909;
    --button-hover: #daa520;
    --shadow-grid: 0 0 20px 10px rgba(138, 135, 135, 0.5);
    --shadow-button: 0px 0px 15px 8px #ffffff38;

    --text-shadow: 1px 1px 2px black;
    --box-shadow2: 7px -5px 15px -1px #000000;
    --bg-cards: #dadadad2;
}

*, ::after, ::before{
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    /* outline: 2px solid red; */
}

body{
    font-family: "Merienda", cursive;
    /* background: var(--bg-back); */
}

.bg__header{
    background: var(--bg-back);
    height: 100vh;
    /*contenedor padre con flex*/
    display: flex;
    /* justify-content: center; align-items: center; */
}

.bgfront__header{
    width: 100%;
    height: 80vh;
    background:var(--bg-front);
    margin: 0;
}

.title,.paragraph{
    color:var(--bg_txt_outline-button);
}



.grid__header{
    background: var(--bg-grid);
    width: 90%;
    height: 90vh;
    max-width: 1200px;
    
    /*contenedor hijo para centrar puede ocupar "margin: auto" o en el padre justify align "en center"*/
    margin: 5vh auto;

    box-shadow: var(--shadow-grid);
    border-radius: 23px;

    display: grid;
    grid-template-columns: repeat(8,1fr);
    grid-template-rows: repeat(6,1fr);
    
    overflow: hidden;
}

.grid__header::before{
    content: "";
    grid-column: 2/-1;
    grid-row: 1/-1;
    background-image: var(--img-perfil);
    background-size: cover;
    background-position: center;

    clip-path: polygon(50% 0, 100% 0, 100% 0, 50% 0);
    animation: show 2s forwards;
}


.picture__logo{
    grid-column: 1/-5;
    grid-row: 1/-2;

    display: flex;
    align-items: center;
    justify-content: center;

    transform: scale(0);
    transform-origin: top center; 
    animation: move 1s 1.5s forwards;  
}

.img__logo{
    width: 100%;
    height: 100%;
}

.grid__button{
    grid-column: 4/-3;
    grid-row: 6/-1;

    display: grid;
    grid-template-columns: repeat(3, 1fr);
    grid-template-rows: repeat(3,1fr);

    transform: scale(0);
    animation: link .5s 2.3s forwards;
}

.button__cta{
    grid-column: 1/-1;
    grid-row: 2/-2;
    display: block;
    text-decoration: none;
    color: var(--bg_txt_outline-button);
    background: var(--bg-button);
    width: 250px;
    height: 50px;
    padding: 10px 25px;
    text-align: center;
    line-height: 30px;
    margin: 0 auto;
    border-radius: 50px;
    outline: 1px solid var(--bg_txt_outline-button);
    box-shadow: var(--shadow-button);
}

.button__cta:hover{
    outline: 1px solid var(--button-hover);
}

.button__cta:active{
    background: var(--bg_txt_outline-button);
    color: var(--bg-button);
    outline: none;
}







/* SECTION 2 */

.bg__section2{
    background: var(--bg-front);
    height: 60vh;
    display: flex;
    justify-content: center;
    align-items: center;
}

.container__section2{
    background: var(--bg-grid);
    width: 80%;
    height: 80%;
    display: flex;
    justify-content: center;
    align-items: center;
    border-radius: 35% 0 35% 0;
}

.title--section2{
    font-size: 3rem;
    text-align: center;
    padding: 0 20px;
}




/* SECTION 3 */

.bg__section3{
    background: var(--bg-back);
    height: auto;
    display: flex;
    justify-content: start;
    align-items: center;
    flex-direction: column;
}

.container__section31{
    background: var(--bg-grid);
    width: 80%;
    height: 10%;
    display: flex;
    justify-content: center;
    align-items: center;
    margin-top: 50px;
    margin-bottom: 1px;
    border-radius: 25px 25px 0 0;
    text-align: center;
    padding: 10px 20px;
}

.container__section32{
    background: var(--bg-grid);
    width: 80%;
    height: auto;
    display: flex;
    justify-content: center;
    align-items: center;
}

.container__section33{
    background: var(--bg-grid);
    width: 80%;
    height: 10%;
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
    margin-top: 1px;
    margin-bottom: 50px;
    border-radius: 0px 0px 25px 25px;
    padding: 10px 20px;
}

.title--section33{
    color: var(--button-hover);
}



.portfolio__cards {
    display: grid;
    /* para hacer cards responsive */
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    margin: 50px 0;

    display: flex;
    flex-wrap: wrap;
    justify-content: space-around;

    padding: 0 40px;
}

.portfolio__card {
    width: 330px; /*MAGIA para que las tarjetas no se desborden 1200px 330px + sombra*/
    box-shadow: var(--box-shadow2);
    border-radius: 10px;
    display: flex;
    flex-direction: column;
}



.portfolio__card__container {
    padding: 30px 20px;
    /* background: #a9a9a9; */
    /* https://grabient.com/HQVgzAHANKDsCcMQAYCMUC0rhldHs6GywATMvqvLDKajTgGxhSnCMQvKvDLwAsMXCCFoo2fqRFZQ8CEA?angle=225 */

    background: linear-gradient(225deg, #abc8de 0.000%, #c7c9d8 16.667%, #e5cccf 33.333%, #ffd3c7 50.000%, #ffdbc2 66.667%, #ffe4c0 83.333%, #ffedc3 100.000%);
    border-radius: 10px; 

    flex-grow: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.portfolio__card__name {
    font-size: 1.4rem;
    text-align: center;
    margin-bottom: 30px;
    color: var(--bg-button);
    /* text-shadow: var(--text-shadow); */
}

.portfolio__card__text{
    display: flex;
    flex-direction: column;
    height: 100%;
    align-items: flex-start;
    text-align: center;
}

.portfolio__card__copy {
    font-weight: 200;
    margin-bottom: 30px;
    color: var(--bg-button);
    line-height: 2;
}

.portfolio__card__cta {
    background: var(--bg-button);
    color: var(--bg_txt_outline-button);
    text-decoration: none;
    text-align: center;
    display: block;
    padding: 15px 0;
    width: 200px;
    margin: 0 auto;
    border-radius: 25px;
}

.portfolio__card__cta:hover {
    background: var(--bg-cards);
    color: var(--bg-button);
    outline: 1px solid var(--button-hover);
    transition: .3s ease all;
}



.bg__footer{
    background: var(--bg-front);
    width: 100%;
    height: 20vh;
    display: flex;
    justify-content: center;
    align-items: center;

}

.container__footer{
    background: var(--bg-grid);
    width: 100%;
    height: 60%;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
}

.footer__picture{
    /* background: peru; */
    width: 60px;
    height: 60px;
}
.footer__logo{
    width: 100%;
    height: 100%;
}









@keyframes show {
    to {
        clip-path: polygon(50% 0, 100% 0, 100% 100%, 0 100%);
    }
}

@keyframes move {
    to {
        transform: scale(1);
    }
}

@keyframes link {
    to {
        transform: scale(1);
    }
}





@media screen and ((min-width:280px) and (max-width:480px)) and (orientation: portrait) {
    .grid__header::before{
        grid-row: 3/-1;
    }
    .picture__logo{
        grid-column: 1/-2;
        grid-row: 1/-3; 
    }
    .grid__button{
        grid-column: 1/-1;
    }
    .button__cta{
        width: 150px;
        height: 40px;
        padding: 10px 15px;
        line-height: 20px;
        font-size: 0.7rem;
    }


    .container__section2{
        width: 100%;
        height: 50%;
        border-radius: 0;
    }
    .title--section2{
        font-size: 1.5rem;
    }



    .container__section31{
        width: 100%;
        border-radius: 15px 15px 0 0;
        padding: 10px 20px;
    }
    .title--section31{
        font-size: 0.8rem;
    }


    
    .container__section32{
        width: 100%;
    }
    .portfolio__card {
        width: 260px;
    }



    .container__section33{        
        width: 100%;
        border-radius: 0 0 15px 15px;
        padding: 10px 20px;
    }
    .title--section33{
        font-size: 0.8rem;
    }


    .container__footer{
        padding: 0 20px;
    }
    .footer__logo{
        width: 80%;
        height: 80%;
        margin: 10% auto;
    }
    .footer__copy{
        font-size: 0.4rem;
    }

}

@media screen and ((min-height:250px) and (max-height:480px)) and (orientation: landscape) {
    .picture__logo{
        grid-column: 1/-5;
        grid-row: 1/-1;
    }
    .grid__button{
        grid-column: 6/-1;
    }
    .button__cta{
        width: 150px;
        height: 40px;
        padding: 10px 15px;
        line-height: 20px;
        font-size: 0.7rem;
    }


    .container__section2{
        width: 100%;
        height: 50%;
        border-radius: 0;
    }
    .title--section2{
        font-size: 1.5rem;
    }


    .container__section31{
        height: 20%;
    }
    .title--section31{
        font-size: 0.8rem;
        padding: 10px 20px;
    }


    .container__section33{
        height: 20%;
    }
    .title--section33{
        font-size: 0.8rem;
        padding: 10px 20px;
    }

    .bg__footer{
        height: 20vh;
    }

}

@media screen and ((min-width:481px) and (max-width:650px)) and (orientation: portrait){
    .title--section2{
        font-size: 2rem;
    }
    
    .container__section31{
        height: 30%;
    }
    .title--section31{
        font-size: 1rem;
        padding: 10px 20px;
    }

    .container__section33{
        height: 30%;
    }
    .title--section33{
        font-size: 0.8rem;
        padding: 10px 20px;
    }

    .footer__copy{
        font-size: 0.6rem;
    }
}
