main {
    margin-top: 80px;

    display: flex;
    flex-wrap: wrap;
    justify-content: center;

    background-color: white;
    width: 100%;
    height: auto;
    position: relative;
}
main div{
    margin: 1.25rem 0;
}

main h1 {
    margin-left: 1.25rem;
    margin-top: 1.25rem;
}

/* destacats */
#destacats{
    width: 70%;
    height: auto;
    padding: 0.625rem;
    display: flex;
    flex-direction: column;
    border-radius: 0.625rem;
    background-color: #F3F6F6;
}

/* destacats / ofertes / categories */
.parts{
    width: 70%;
    height: auto;
    padding: 0.625rem;
    display: flex;
    flex-direction: column;
    border-radius: 0.625rem;
    background-color: #F3F6F6;
}
.productes_list{
    width: 100%;
    height: auto;
    margin-top: 1.25rem;
    display: flex;
    justify-content: space-evenly;
    flex-wrap: wrap;
}

/* btn */
#div_main {
    margin: 0px;
}

.arrow {
    width: 3.125rem;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0.625rem;
}

.div_btn {
    display: none;
}

/* categories */
.categories{
    width: 70%;
    height: auto;
    padding: 0.625rem;
    display: flex;
    flex-direction: column;
    border-radius: 0.625rem;
    background-color: #F3F6F6;
}

.categories_list{
    width: 100%;
    height: auto;
    margin-top: 1.25rem;
    display: flex;
    justify-content: space-evenly;
    flex-wrap: wrap;
    gap: 20px;
}

.categoria{
    width: 15.625rem;
    height: 21.875rem;
    background-color: #fff;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    border-radius: 1.5625rem;
    display: flex;
    justify-content: center;
    align-items: end;
    padding: 0.625rem;
    transition: transform 0.3s, box-shadow 0.3s;
    flex: 0 0 auto;
}

.categoria:hover{
    transform: translateY(-0.3125rem);
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.2);
}

.button_categoria{
    width: 100%;
    height: 3.75rem;
    font-size: 1.125rem;
    padding: 0.625rem 1.25rem;
    background: linear-gradient(135deg, #bb86fc, #03dac6);
    color: #fff;
    border: none;
    border-radius: 6.25rem;
    cursor: pointer;
}

@media screen and (max-width: 1500px) {
    .parts, #destacats {
        width: 90%;
    }
    .categoria {
        width: 12rem;
        height: 20rem;
    }
}

@media (max-width: 992px) {
    #div_main .flecha, #div_main .arrow {
        display: none;
    }
    .div_btn {
        width: 100%;
        margin: 0px;
        display: flex;
        justify-content: center;
        align-items: center;
    }
    .div_btn button {
        margin: 0px 10px;
    }

    .categories_list {
        justify-content: center;
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
        justify-items: center;
    }
    
    .categoria {
        width: 100%;
        max-width: 280px;
        height: 18.75rem;
    }
    
    #destacats, .parts, .categories {
        width: 90%;
    }
}

@media (max-width: 576px) {
    .categories_list {
        grid-template-columns: 1fr;
    }
    
    .categoria {
        max-width: 300px;
        height: 16.875rem;
    }
    
    .button_categoria {
        font-size: 1rem;
        height: 3.125rem;
    }
    
    #destacats, .parts, .categories {
        width: 95%;
    }
}