@import url('./reset.css');

@font-face {
    font-family: 'oswald';
    src: url('../font/Oswald-VariableFont_wght.ttf');
}

/* Global class,id and objects definition */

:root {
    --color-primary: #FFB700;
    --color-orange-light: #FFD480;
    --color-secondary: #2A2C2D;
    --color-light: #959595;
    --color-success: #63A464;
}

* {
    font-family: 'oswald', sans-serif;
    font-size: 1rem;
}

.container {
    width: 95vw;
    margin: 0 auto;
}

/* Menu section CSS */

#menuHeaderSection {
    background-color: black;
    width: 100vw;
}

#menuSection {
    width: 100vw;
    background-color: var(--color-primary);
}

#menuHeaderContainer {
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.5rem 0;
}

#menuIcons {
    display: flex;
    align-items: center;
    color: white;

    div {
        padding: 0.5rem;
    }
}

#cartIcon {
    position: relative;
}

#cartNumber {
    display: flex;
    align-items: center;
    justify-content: center;
    position: absolute;
    background-color: var(--color-primary);
    border-radius: 50%;
    top: .5rem;
    right: .5rem;
    width: 1.2rem;
    height: 1.2rem;
    font-size: 0.8rem;
}

#menuContainer {
    padding: 0.5rem 0;
    width: fit-content;
    margin: 0 auto;

    ul {
        display: flex;
        align-items: center;

        li {
            display: none;
            padding: 0.5rem;
        }

        li:hover {
            cursor: pointer;
        }

        li:first-child {
            display: block;
        }

        li:last-child {
            display: block;
            margin-left: 2rem;

            i {
                color: white;
                margin-right: 1rem;
            }
        }
    }
}

#menuAllCategoriesContainer {
    position: relative;
}

#menuAllCategories {
    display: flex;
    padding: 0.3rem 1rem;
    background-color: white;
    width: fit-content;
    border-radius: 0.3rem;

    div:first-child {
        margin-right: 1rem;
    }
}

#subMenuAllCategories {
    display: none;
    position: absolute;
    z-index: 1;
    top: 100%;
    left: 1rem;
    padding: 1rem;
    background-color: white;
    border-radius: 0.3rem;
    width: 14rem;
}

#menuAllCategories:hover {
    cursor: pointer;
    background-color: #EEEEEE;
}

.menuItem {
    position: relative;
    display: flex;
    align-items: center;
    margin: 0.3rem 0;
    color: black;
    width: 100%;

    div:first-child {
        margin-right: 1rem;
    }

    div:last-child {
        font-size: 1.2rem;
    }
}

.subMenu {
    position: absolute;
    left: calc(100% + 0.5rem);
    background-color: white;
    width: 12rem;

    a {
        font-size: 1.2rem;
    }
}

.menuItem:hover {
    cursor: pointer;
    color: var(--color-primary);
}

/* Slider section CSS */

#heroSection {
    width: 100vw;

    .container {
        width: 100%;
    }

    button:hover {
        cursor: pointer;
    }
}

#heroContainer {
    position: relative;
}


.heroText {
    position: absolute;
    top: 2rem;
    left: 2rem;
}

.promos {
    color: var(--color-primary);
    font-size: 1rem;
}

.promosTitle {
    color: black;
    font-size: 1.5rem;
    font-weight: 500;
}

#slide-1 {
    display: block;
}

#slide-2,
#slide-3 {
    display: none;
}

.topImage {
    position: absolute;
    top: 0;
    left: 0;
    z-index: 1;
}

.bottomImage {
    position: absolute;
    top: 0;
    left: 0;
    z-index: 0;
}

#promosButton-1,
#promosButton-2,
#promosButton-3 {
    border: none;
    color: white;
    background-color: var(--color-primary);
    padding: 0.8rem 2rem;
    margin-top: 2rem;
}

/* Header of each section of the shop */

.rubriqueHeader {
    display: flex;
    justify-content: space-between;
    margin: 2rem 0;
}

.rubriqueName {
    font-weight: 600;
}

.rubriqueLinks {
    ul {
        display: flex;

        li {
            padding: 0 0.3rem;
        }

        li:first-child {
            color: var(--color-primary);
        }
    }
}

/*
 * Cards CSS sections
 */

.cardContainer {
    display: flex;
    flex-direction: column;

    .card {
        width: 95%;
        margin: 0 auto;
    }
}

.cardImage {
    position: relative;
}

/* soldout or sale overlay CSS*/
.cardOverlay {
    position: absolute;
    top: 1rem;
    left: 1rem;
    color: white;
    padding: 0.5rem;
}

.soldout {
    background-color: var(--color-primary);
}

.sale {
    background-color: var(--color-success);
}

/* content */
.cardTitle {
    font-weight: 600;
}

.cardPrice {
    font-size: 0.8rem;
    color: var(--color-primary);

    span:first-child {
        color: black;
        font-size: 0.7rem;
        text-decoration: line-through;
    }

    span:last-child {
        color: var(--color-success)
    }
}

.cardNotation {
    color: var(--color-primary)
}

/* Partners CSS section */

#partners {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;

    >div {
        width: 33%;
    }
}

/*
 * Call to action CSS section
 */

#callToActionSection {
    width: 100vw;
    padding: 4rem 0;
    background-color: var(--color-primary);

    .container {
        text-align: center;
        display: flex;
    }
}

#callToActionContainer {
    margin: 0 auto;
    display: flex;
    align-items: center;

    /* Mise en forme du texte */
    div:first-child {
        display: flex;
        align-items: center;

        i {
            font-size: 3rem;
            color: white;
            margin-right: 1rem;
        }

        h2 {
            text-align: left;
            font-size: 1.4rem;
            color: white;
            margin-right: 1rem;
        }
    }

    /* mise en forme du formulaire */
    form {
        background-color: white;
        padding: 0.2rem;
        display: flex;

        input[type="email"] {
            border: none;
            padding: 0.5rem 1rem;
        }

        input[type="submit"] {
            border: none;
            color: white;
            background-color: black;
            height: 100%;
            padding: 0 1rem;
        }
    }
}

/*
 * Footer section CSS
 */

#footerContainer {
    width: 100vw;
    background-color: var(--color-secondary);
    padding: 0.5rem 0;
}

#footerInsideContainer {
    display: flex;
    flex-direction: column;
    color: white;

    .leftside,
    .rightside {
        width: 100%;
    }

    .leftside {
        div {
            width: 12rem;
        }

        p {
            font-size: 0.8rem;
        }

        ul {
            li {
                font-size: 0.8rem;
                margin: 0.8rem 0;

                i {
                    margin-right: 1rem;
                }
            }
        }
    }

    .rightside {
        padding-top: 3rem;

        i {
            color: var(--color-primary);
            font-size: 1.5rem;
            margin-right: 0.5rem;
        }
    }
}

#miniaturesInstaContainer {
    margin-top: 1rem;
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;

    >div {
        width: 49%;
        margin-bottom: 0.3rem;

        img {
            width: 100%;
        }
    }
}

.copyright {
    color: white;
    font-size: 0.8rem;
    text-align: center;
}

/*
 * Media querys tricks
 */

@media screen and (min-width: 576px) {

    .container {
        max-width: 1200px;
        margin: 0 auto;
    }

    #hamburgerMenu {
        display: none;
    }

    #heroSection {
        .container {
            width: unset;
        }
    }

    .heroText {
        left: 0;
    }

    #menuContainer {
        ul {
            li {
                display: block;
            }

            li:first-child {
                display: block;
            }

            li:last-child {
                margin-left: 1rem;
            }
        }
    }

    .cardContainer {
        flex-direction: row;

        .card {
            width: unset;
            margin: unset;
        }
    }

    #partners {
        display: flex;
        flex-wrap: nowrap;
        justify-content: space-between;
        align-items: center;
    }

    #footerInsideContainer {
        flex-direction: row;

        .leftside,
        .rightside {
            width: 100%;
        }

        .rightside {
            padding-top: unset;
        }
    }

    #miniaturesInstaContainer {
        margin-top: 1rem;
        display: flex;
        flex-wrap: wrap;
        justify-content: space-between;

        >div {
            width: 24.2%;
            margin-bottom: 0.3rem;
        }
    }
}

@media screen and (min-width:1024px) {
    #menuContainer {
        ul {
            li:last-child {
                margin-left: 6rem;
            }
        }
    }
}