* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: sans-serif;
}

:root {
    --primary-color: #0068E9;
}

body {
    background: #E9E9E9;
    margin: 0;
    overflow: hidden;
}

.container {
    width: 100%;
    margin: auto;
}

/* Start Navbar Section */
nav {
    background-color: var(--primary-color);
    height: 50px;
    position: sticky;
    top: 0;
    z-index: 100;
    padding: 0 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo {
    cursor: pointer;
    color: white;
}

.main-wrapper {
    display: flex;
    gap: 15px;
    width: 100%;
}

.search-box {
    & input {
        padding: 8px 15px;
        font-size: 17px;
        border-radius: 5px;
        border: 1px solid #ccc;
        min-width: 300px;
    }

    & button {
        padding: 8px 15px;
        border-radius: 5px;
        border: 1px solid #ccc;
        font-size: 17px;
        cursor: pointer;
        outline: none;

        &:hover {
            background: #ccc;
        }
    }
}

/* End Navbar Section */

/* Start Product Detail Modal Section */
#view-detail-dialog {
    min-width: 700px;
    max-width: 800px;
    min-height: 550px;
    border: none;
    margin: auto;
    box-shadow: 0 0 5 dimgray;
    border-radius: 5px;
    position: relative;


    &>.close-dialog-btn {
        position: absolute;
        right: 10px;
        top: -1px;
        border: none;
        background: transparent;
        font-size: 28px;
        cursor: pointer;
        outline: none;
    }
}

.product-detail-wrapper {
    width: 100%;
    display: flex;
    gap: 10px;
    flex-direction: row;
    padding: 15px;

    & .product-image {
        width: 40%;

        &>img {
            width: 90%;
            background: #f6f6f6;
            cursor: pointer;
        }
    }

    & .product-info {
        width: 60%;
        padding-top: 20px;

        &>h1 {
            font-size: 20px;
            margin-bottom: 10px;
        }

        & ul.description {
            margin-left: 25px;
            list-style: "- ";
            margin-top: 5px;
        }
    }
}

/* End Product Detail Modal Section */

/* Start Sidebar Section (Left Sidebar) */
.sidebar {
    width: 350px;
    height: 100%;
    padding: 8px 18px;
    background-color: white;
    box-shadow: 0px 0px 10px 0px rgba(0, 0, 0, 0.1);
    position: fixed;
    left: 0;
    top: 50px;
    height: calc(100% - 50px);
    padding-top: 25px;

    & h3 {
        text-align: center;
    }

    & #brand-list {
        display: flex;
        gap: 10px;
        flex-wrap: wrap;
        margin-top: 18px;
    }

    & button.brand-item.active {
        background: var(--primary-color);
        color: white;
    }

    & button.brand-item {
        border: 1px solid var(--primary-color);
        background: white;
        padding: 7px 20px;
        font-size: 15px;
        border-radius: 5px;
        flex: 1;
        cursor: pointer;

        &:hover {
            background: var(--primary-color);
            color: white;
        }
    }
}

/* End Sidebar Section (Left Sidebar) */

/* Start Product List Section (Right Sidebar) */
.product-list-container {
    position: relative;
    width: calc(100% - 350px);
    padding: 15px;
    margin-left: auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 18px;
    overflow-x: hidden;
    cursor: pointer;
    height: calc(100vh - 50px);
    overflow-y: scroll;
}

.product-card {
    border: 1px solid rgb(116, 116, 116);
    text-align: center;

    & img {
        width: 100%;
        transition: transform .3s;

        &:hover {
            transform: scale(1.3);
        }
    }

    & p {
        font: 20px;
    }

    & h5 {
        margin: 0;
        font-size: 30px;
        color: red;
    }
}

.product-not-found-message {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: red;
    font-size: 20px;
}

/* End Product List Section (Right Sidebar) */

/* Start Loading Section */
.loading-wrapper {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 99999;
}

.loader {
    width: 48px;
    height: 48px;
    border: 5px solid var(--primary-color);
    border-bottom-color: transparent;
    border-radius: 50%;
    display: inline-block;
    box-sizing: border-box;
    animation: rotation 1s linear infinite;
}

@keyframes rotation {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

/* End Loading Section */