/* Home page */
body {
    background-color: beige;

}

.container {
    display: flex;
    flex-direction: column;
}

.header {
    display: flex;
    align-items: center;
    width: 90vw;
}

.logo {
    order: 1;
    margin-right: auto;
    width: 20%;
    max-width: 200px;
    height: auto;
}

.shoppingChart {
    order: 4;
    width: 100%;
    max-width: 50px;
    height: auto;
}

.searchBar {
    order: 2;
    width: 100%;
    max-width: 1200px;
    height: 40px;
    border-radius: 10px;
    border: 0.5px solid gray;
    padding-left: 10px;
    margin-right: 5%;
}

.searchButton {
    order: 3;
    height: 40px;
    width: 15%;
    max-width: 150px;
    background-color: burlywood;
    border-radius: 10px;
    border: none;
    margin-right: 10%;
}

.categories{
    display: flex;
    justify-content: space-between;
    flex-wrap: nowrap;
    width: 80%;

}

.categories label{
    margin-left: 1%;
    text-decoration: none;
    color: black;
    padding: 8px;
    font-size: large;
}

.categories a{
    margin-left: 1%;
    text-decoration: none;
    color: brown;
    height: 30px;
    padding: 8px;
    text-align: center;

}

.categories a:hover{
    background-color: brown;
    color: white;
}

.subTitle {
    font-size: 24px;
}

.Box {
    margin: 10px;
    padding: 10px;
    display: flex;
    flex-wrap: wrap;
    gap: 5%;
}

.bookBox {
    border: none;
    margin: 10px;
    padding: 10px;
    display: flex;
    flex-direction: column;
    border-radius: 10px;
    transition: transform 0.5s;
    width: 22%;
    max-width: 250px;
    justify-content: space-between;
}

.bookBox:hover{
    transform: scale(1);
    box-shadow: 5px 5px 5px 5px gray;
}

.sub-logo {
    display: flex;
    flex-direction: row;
    margin-top: 20px;
    margin-bottom: 0px;
    justify-content: space-between;
}

.sub-logo div {
    display: flex;
    align-items: center;
    margin-right: 12%;
}

.sub-logo > div > h2{
    padding-top: 20px;
}

.sortByLabel{
    margin-right: 10px;
}

.sub-logo div select {
    background-color: beige;
    border: 1px solid grey;
    padding: 8px;
    border-radius: 5px;
    cursor: pointer;
}

.sub-logo div select:hover {
    border-color: brown;
}

/* Style the dropdown options */
.sub-logo div select optgroup option {
    background-color: beige;
    color: #333;
    height: 10px;
}

.sub-logo img {
    width: 30px;
    height: 30px;
    margin-left: 30px;
    margin-right: 5px;
    margin-top: 15px;
}

.bookBox img {
    border-radius: 10px;
    width: 100%;
    height: auto;
}

.titleContainer {
    display: flex;
    flex-direction: column;
}

.titleContainer h3 {
    margin-top: 20px;
    margin-bottom: 0px;
}

.pageNum {
    color: gray;
    font-size: small;
}

.description {
    margin: 0;
    flex-shrink: 1;
    font-size: medium;
    text-align: center;
}

.authorName {
    color: gray;
    font-size: medium;
}

.shoppingButton {
    height: 40px;
    background-color: burlywood;
    border-radius: 10px;
    border: none;
}

.shoppingButton:hover, .searchButton:hover {
    background-color: brown;
    color: white;
}

footer {
    display: flex;
    justify-content: space-between;
    padding: 10px;
}

footer a {
    margin: 20px;
    color: brown;
}



/* media queries */
@media (max-width: 600px) {
    .logo {
        max-width: none; 
        height: auto;
    }

    .shoppingChart {
        width: 30px;
        height: 30px;
    }

    .searchBar {
        order: 1;
        max-width: none; 
        height: 25px;
        font-size: 10px;
    }

    .searchButton {
        order: 2;
        max-width: none;
        height: 25px;
        font-size: 10px;
    }

    .categories{
        margin-top: 20px;
    }

    .categories label{
        font-size: small;
    }

    .categories a{
        font-size: small;
    }

    .subTitle {
        font-size: 18px;
        width: 100px;
        margin-top: 8px;
        margin-left: 8px;
    }

    .Box {
        flex-direction: column;
        gap: 20px;
        width: 80%;
        margin: 0px;
    }

    .bookBox {
        width: 100%;
        max-width: none;
    }

    .sub-logo {
        margin-left: 18px;
    }

    .sub-logo img {
        margin-left: 0px;
        margin-right: 0px;
        margin-top: 0px;
    }

    .titleContainer {
        flex-direction: column;
    }

    .description {
        margin-top: 10px;
    }

    footer {
        flex-direction: column;
        width: 80%;
    }

    footer a {
        margin: 2px;
    }
}

@media screen and (hover: none) {
    .bookBox:hover {
        transform: none; /* Reset the transform on touch devices */
        box-shadow: none; /* Reset the box-shadow on touch devices */
    }
}


/* shopping cart */

.shooppingCartHeading{
    text-align: center;
    font-size: 2rem;
}
.shoppingCart{
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    margin: 2rem 0;
}
.shoppingCartItems{
    width: 70%;
}

.shoppingCartItem{
    display: flex;
    justify-content: center;
    margin: 1rem 0;
}
.shoppingCartItem .bookImg{
    width: 100px;
    height: 100px;
    border-radius: 10px;
}

.removeIcon{
    width: 18px;
    height: 15px;
    margin-left: 10%;
}

.shoppingCartItemDetails{
    margin-left: 1rem;
}
.shoppingCartTotal{
    width: 25%;
    padding: 1rem;
    margin-top: 5%;
    border-radius: 10px;
}
.shoppingCartTotal h3{
    text-align: center;
}
.shoppingCartTotal button{
    width: 100%;
    padding: 0.5rem;
    background-color: burlywood;
    border: none;
    cursor: pointer;
    border-radius: 10px;
}
.shoppingCartTotal button:hover{
    background-color: brown;
    color: white;
}