@import url('https://fonts.googleapis.com/css2?family=Josefin+Sans:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;1,100;1,200;1,300;1,400;1,500;1,600;1,700&display=swap');

@font-face {
    font-family: "NorthCarossela";
    src: url("fonts/NorthCarossela.otf") format("opentype");
}

@keyframes imgSlide {
    0%{
        object-position: 50% 0%;
    }
    
    50%{
        object-position: 50% 100%;
    }

    100%{
        object-position: 50% 0%;
    }
}
  
body{
    width: 100vw;
    height: 100dvh;
    font-family: 'Josefin Sans', sans-serif;
    background-color: black;
    color: black;
    line-height: 1;
    display: flex;
    flex-direction: column;
    gap: 15px;
    justify-content: flex-end;
    padding: 30px;
    overflow: hidden;
}

h1{
    width: 100%;
    font-size: 100px;
    color: white;
    font-family: "NorthCarossela", sans-serif;
    margin-bottom: 30px;
}

p, a{
    font-size: 30px;
    font-weight: 300;
    text-decoration: none;
    color: black;
}

.cards{
    width: 100%;
    height: 80%;
    display: flex;
    flex-direction: row;
    gap: 15px;
    align-items: center;
    flex-wrap: nowrap;
}
.card{
    width: 22%;
    height: 100%;
    border-radius: 20px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}
.card .image{
    width: 100%;
    height: 100%;
    overflow: hidden;
}
.card .image img{
    width: 100%;
    height: 100%;    
    object-fit: cover;
    object-position: 50% 0;
    animation: imgSlide 20s ease-in-out infinite;
}
.card .image img[src="img/recettes.jpg"]{
    animation-duration: 38s;
}
.card .image img[src="img/portfoliorob.jpg"]{
    animation-delay: 3s;
}
.card .text-content{
    width: 100%;
    height: fit-content;
    flex-shrink: 0;
    padding: 30px;
    display: flex;
    flex-direction: column;
    gap: 5px;
    align-items: flex-end;
    background: linear-gradient(to right,#e9b7ce, #d3f3f1);
}
.card .text-content p{
    text-align: right;
}
.card.more{
    background-color: unset;
    justify-content: center;
    align-items: center;
}
.card.more p{
    color: white;
    font-size: 40px;
}

.btn{
    display: flex;
    flex-direction: row;
    gap: 10px;
    text-transform: uppercase;
    color: black;
    font-size: 20px;
    margin-bottom: 15px;
}
.btn .arrow{
    position: relative;
    width: 13px;
    height: 15px;
    overflow: hidden;
}
.btn .arrow::before, .btn .arrow::after{
    content: "";
    width: 100%;
    height: 100%;
    background-image: url("data:image/svg+xml,%3Csvg width='20' height='20' viewBox='0 0 20 20' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M18.5 0H20V20H18.5V0Z' fill='black'/%3E%3Cpath d='M6.55673e-08 1.5L0 0H20V1.5L6.55673e-08 1.5Z' fill='black'/%3E%3Cpath d='M18.0421 0.9L19.1028 1.96066L1.07158 19.9919L0.0109165 18.9312L18.0421 0.9Z' fill='black'/%3E%3C/svg%3E%0A");
    background-position: 50%;
    background-repeat: no-repeat;
    background-size: contain;
    position: absolute;
    top: 0px;
    left: 0px;
    transition: all 300ms;
}
.btn .arrow::after{
    top: 18px;
    left: -18px;
}
.card:hover .btn .arrow::before{
    top: -18px;
    left: 18px;
}
.card:hover .btn .arrow::after{
    top: 0px;
    left: 0px;
}

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

    body{
        overflow: scroll;
        height: fit-content;
    }

    h1{
        font-size: 50px;
    }

    .cards{
        flex-direction: column;
        height: fit-content;
        gap: 30px;
    }

    .card{
        width: 100%;
        height: fit-content;
    }

    .card .image{
        height: auto;
        aspect-ratio: 16 / 9;
    }

    .card.more{
        padding: 60px 0px;
    }

    .card.more p{
        font-size: 30px;
    }
}