@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;700&display=swap');

:root{
    --color-primary: #444CF7;
    --color-title: #000;
    --align-title: left;
    --padding-container: 100px 0;
    --width-container: 90%;
    --max-width-container: 1200px;
    --color-btn: #444CF7;
    --text-btn: #fff;
    --padding-btn: 20px 35px;
    --height-shape:18em;
}


body{
    
    font-family: 'Inter', sans-serif;
    background-color: #FF0000;
    opacity: 1;
    background-image: #ff0000;
    background-size: 28px 28px;
    background-position: 0 0,14px 14px;
}

.container{
    width: 90%;
    max-width: var(--max-width-container);
    padding: var(--padding-container);
    margin: 0 auto;
    overflow: hidden;
}

.hero{
    height: 100vh;
    min-height: 500px;
    position: relative;
    --padding-container: 0;
}

.hero::after{
    content: "";
    display: block;
    position: absolute;
    height: var(--height-shape);
    width: 100%;
    bottom: 0;
    left: 0;
    background: #fff;
    z-index: -1;
    clip-path: polygon(0 100%, 100% 100%, 100% 0);

}

.hero__container{
    display: grid;
    height: 100%;
    grid-template-columns: 3fr 2fr;
    place-items: center;
    gap: 20px;
}

.text {
    position: left;
    top: 25%; 
    right: 70%;
    transform: translate(50%,-50%);
    text-transform: uppercase;
    font-family: verdana;
    font-size: 6em;
    font-weight: 700;
    color: #f5f5f5;
    text-shadow: 1px 1px 1px #919191,
        1px 2px 1px #919191,
        1px 3px 1px #919191,
        1px 4px 1px #919191,
        1px 5px 1px #919191,
        1px 6px 1px #919191,
        1px 7px 1px #919191,
        1px 8px 1px #919191,
        1px 9px 1px #919191,
        1px 10px 1px #919191,
    1px 18px 6px rgba(16,16,16,0.4),
    1px 22px 10px rgba(16,16,16,0.2),
    1px 25px 35px rgba(16,16,16,0.2),
    1px 30px 60px rgba(16,16,16,0.4);
}

.hero__copy{
    font-size: 1.2rem;
    margin: 25px 0;
}

.hero__cta{
    display: inline-block;
    background: var(--color-btn);
    color: #fff;
    padding: var(--padding-btn);
    text-align: center;
    text-decoration: none;
}

.hero__img{
    width: 95%;
}

/* Main */

.main{
    background: #fff;
}

.title{
    font-size: 2.5rem;
    text-align: var(--align-title);
    color: var(--color-title);
}

.title--border::after{
    content: "";
    display: block;
    width: 100px;
    margin-top: 20px;
    height: 4px;
    background-color: var(--color-primary);
}


.cta{
    display: inline-block;
    background: var(--color-btn);
    color: var(--text-btn);
    padding: var(--padding-btn);
    text-align: center;
    text-decoration: none;
}


/* Instrcutor */

.instructor{
    text-align: center;
    border-bottom: 2px solid #ccc;
    --padding-container: 30px 0 60px;
}

.instructor__container{
    width: 70%;
    margin: 0 auto;
}

.instructor__name{
    margin: 20px 0;
}

.instructor__tag{
    font-weight: 700;
    color: var(--color-primary);
    margin-bottom: 20px;
}

.instructor__paragraph{
    text-align: left;
    line-height: 1.5;
    font-style: italic;
    color: #615a5a;
}

.instructor__img{
    width: 150px;
    height: 150px;
    border-radius: 50%;
    object-fit: cover;
    object-position: top;
}

/* about */

.about{
    display: grid;
    grid-template-columns: 5fr 4fr;
    place-items: center;
}

.about__course{
    width: 90%;
}

.about__paragraph{
    margin: 20px 0;
    line-height: 1.5;
    font-weight: 300;
}

.about__picture{
    text-align: center;
}

.about__img{
    width: 95%;
}

/* Card */

.card{
    background: #f2f2f2;
}

.card__copy{
    margin-top: 20px;
}

.card__container{
    width: 99%;
    margin: 0 auto;
    margin-top: 60px;
    display: grid;
    grid-template-columns: repeat(3,1fr);
    grid-template-rows: repeat(4,1fr);
    gap: 20px;
    grid-template-areas: 
    ".      card1   .    "
    "card2  card1   card3"
    "card2  card4   card3"
    ".      card4   .   ";
}

.card__item{
    padding: 20px;
    background: #fff;
    border-top: 5px solid #667eea;
    box-shadow: 0 0 3px rgba(0, 0, 0, .5);
    display: flex;
    flex-direction: column;
    align-items: center;
}

.card__img{
    background: var(--color-primary);
    margin-top: 20px;
    width: 80px;
    height: 80px;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
}

.card__title{
    margin: 20px 0;
    font-size: 1.5rem;
}

.card__paragraph{
    font-weight: 300;
    margin-bottom: 20px;
}

.card__item:nth-last-of-type(1){
    grid-area: card1;
}

.card__item:nth-last-of-type(2){
    grid-area: card2;
}

.card__item:nth-last-of-type(3){
    grid-area: card3;
}

.card__item:nth-last-of-type(4){
    grid-area: card4;
}

/* course */

.course{
    --color-title: #fff;
    --color-btn: #fff;
    --text-btn: #444cf7;
    color: var(--color-title);
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    grid-template-rows: repeat(5, 1fr);
    /* align-items: center; */
}

.course__about{
    z-index: 100;
    align-self: center;
    width: 97%;
    margin: 0 auto;
    padding: 30px;
    box-shadow: 0 0 6px rgba(0, 0, 0, .5);
    background: var(--color-primary);
    grid-column: 1/4;
    grid-row: 2/-2;
}

.course__picture{
  
    margin:0;
    grid-column: 3/-1;
    grid-row: 1/-1;
}

.course__img{
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.course__picture--right{
    grid-column: 1/4;
}

.course__about--left{
    grid-column: 3/-1;
}

/* Footer */

.footer{
    position: relative;
    --padding-container: 160px 0 50px ;

}


.footer::before{
    content: "";
    position: absolute;
    width: 100%;
    height: 100px;
    background: #fff;
    top: 0;
    left: 0;
    clip-path: polygon(0 0, 100% 0, 50% 100%);

}

.footer__contact{
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
    place-items: center;
    margin-bottom: 30px;
}

.footer__copy{
    margin: 20px 0;
    font-weight: 300;
}

.footer__social{
    display: flex;
    padding-top: 30px;
    flex-wrap: wrap;
}

.footer__link{
    width: 60px;
    height: 60px;
    border: 1px solid #000;
    border-radius: 50%;
    margin-right: 20px;
    margin-bottom: 20px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.footer__icon{
    width: 30px;
}


.footer__picture{
    margin: 0;
}

.footer__img{
    width: 100%;
}

.footer__copyright{
    padding-top: 30px;
    border-top: 2px solid #918484;
    text-align: center;
}

.footer__copyright::after{
    content: " Frederiklopez2418@gmail.com";
}

@media screen and (max-width:768px){
    :root{
        --height-shape:14em;
    }

    /* Agregue un height auto, porque no habia espacio disponible
    para la imagen y los elementos */
    .hero{
        min-height: 100vh;
        height: auto;
    }

     /* La primera fila tendrá una fila, definida por el 
     tamaño de su contenido "max-content" */

    .hero__container{
        --padding-container: 60px 0;
        grid-template-columns: 1fr;
        grid-template-rows: max-content 1fr;
    }

     /* Quite el height y limite el width de la imagen */
    .hero__img{
        order: -1;
        max-width: 300px;
    }

    .hero__title{
        font-size: 3.8rem;
    }

    /* About */

    .about{
        grid-template-columns: 1fr;
        grid-template-rows: max-content 1fr;
        gap: 80px;
    }

    .about__course{
        width: 100%;
    }

    .about__picture{
        order: -1;
    }

    .about__img{
        width: 100%;
    }

    /* Card */

    .card__container{
        grid-template-columns: repeat(2,1fr);
        grid-template-rows: repeat(5,1fr);
        gap: 15px;
        grid-template-areas: 
        "card1      ."
        "card1  card2"
        "card3  card2"
        "card3  card4"
        ".      card4";
    }


    /* Course */

    .course{
        grid-template-columns: repeat(6,1fr);
    }

    .course__about{
        grid-column: 1/6;
    }

    .course__about--left{
        grid-column: 2/-1;
    }

    .course__picture{
        grid-column: 2/-1;
    }

    .course__picture--right{
        grid-column: 1/6;
    }

    .footer__contact{
        grid-template-columns: 1fr;
    }

    .footer__texts{
        order: 1;
        --align-title: center;
    }

    .footer__social{
        justify-content: space-evenly;
    }
}

@media screen and (max-width: 500px){
    :root{
        --padding-btn: 20px 0;
    }


    .hero__container{
        --padding-container: 45px 0;
    }

    .hero__texts{
        text-align: center;
    }

    .hero__title{
        font-size: 3rem;
    }

    .hero__cta{
        display: block;
        width: 90%;
        margin: 0 auto;
    }

    .title{
        font-size: 2rem;
    }

    .cta{
        display: block;
    }

    /* Instructor */

    .instructor{
        --padding-container: 60px 0;
    }

    .instructor__container{
        width: 90%;
    }

    /* About */

    .about{
        gap: 40px;
    }

    .about__course{
        width: 100%;
    }

    /* Card */

    .card__container{
        width: 97%;
        grid-template-columns: 1fr;
        grid-template-rows: repeat(4,1fr);
        grid-template-areas: 
        "card1"
        "card2"
        "card3"
        "card4";
    }

    /* Course */

    .course{
        grid-template-columns: 1fr;
        --padding-container: 80px 0 30px;
    }

    .course--modifier{
        --padding-container:0 0 80px;
    }

    .course__about{
        padding: 20px 20px;
        width: 95%;
        grid-column: 1/-1;
        grid-row: 1/-1;
    }

    .course__picture{
        display: none;
    }
    

}