.shelf-main{
    width: 100%;
    display: flex;
    flex-direction:column;    
}



/* -------------------------------------------------------------- */
/* shelf content styling */
.shelf-listing{
    width: 100%;

    margin:0;
    padding-left: 0;
}

/* ------------------------------------------------------------------ */
/* top bar styling  */
.topbar{
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1em;
    padding-bottom: 5px;
    border-bottom: 1px solid black;
    margin-bottom: 5px;
}
.top-tab{
    width: 100%;
    display:flex;
    justify-content: space-between;
    align-items: center;
    gap:20px;
}

/* -------------------------------------------------------------------------------------------------------------------------------- */
/* topbar icon toggles  */
.topbar svg{
    border-radius: 20%;
    background-color: rgba(0, 0, 0, 0.763);
    transition:all 0.2s ease;
}



.topbar button{
    padding:0.6em;
    height: fit-content;
    border-radius: 10px;
    outline: none;
    border:none;
    background-color: black;
    color :beige;
}
.topbar button:hover{
    cursor:pointer;
}

/* ---------------------------------------------------- */
/* styling for viewing all books */
.all-books-shelf{
    position: relative;
    display: none;
    justify-content: flex-start;
    align-items: flex-start;
    width:100%;
    height: 350px;
    flex-direction: row;
    gap: 20px;
    overflow-x: scroll;
    padding: 20px;
}

#shelf-list{
    display: flex;
}

.all-books-shelf::-webkit-scrollbar{
    background: transparent;
    height: 8px;
}

.all-books-shelf::-webkit-scrollbar-thumb{
    background: black;
    border-radius: 8px;

}


.all-books-shelf::-webkit-scrollbar-track{
    background-color: transparent;
    border-radius: 8px;
    
}

/* --------------------------------------------------- */
/* styling each book */
.shelf-book-item{
    position: relative;
    width:fit-content ;
    transition: all 0.3s ease-in;
}

.shelf-book-item:hover{
    scale: 1.07;
}



.shelf-book-item h3{
    font-size: 1em;
    width: 120px;
    word-wrap: break-word;
    color: black;

}

.shelf-book-item h3:hover{
    padding: 0.2em;
    background-color: black;
    color: beige;
    border-radius:10px;
}

.shelf-book-item img{
    border:solid 1px black;
    border-radius:6px;
    height: 220px;
    width: 150px;
}



.shelf-more{
    position: absolute;
    top: 5px;
    right: 5px;
    border: none;
    z-index:0;
}
.shelf-more:hover{
    cursor:pointer;
}

/* ---------------------------------------------------------- */
/* styling the menu for each book  */
.book-menu-div{
    position:fixed;
    top: 0;
    left: 0;
    height: 100vh;
    width:100vw;
    display: flex;
    align-items: center;
    justify-content:center ;
    z-index: 1;
    backdrop-filter: blur(12px);
    background: fixed;
    transition: opacity 0.5s ease;
    opacity: 0;
    scale: 0;
}
.book-menu{
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    gap:18px;
    background-color: rgba(0, 0, 0, 0.763);
    border-radius:10px;
    padding: 1em;
    border: 1px black solid;
    width:fit-content;
    height: fit-content;
    z-index: 2;
    overflow: hidden;
}

/* toggle for book item menu  */
/* --------------------------------------------------------------- */
.book-menu-div.menu-open{
    scale: 1;
    opacity: 1;
    
}

.book-menu li{
    font-size: 18px;
    font-weight: bold;
    list-style-type:none;
    text-align: center;
    color:black;
    background-color: beige;
    padding:1em;
    border: 1px solid black;
    border-radius: 5px;
    margin: 3px;
    z-index: 2;
}


.book-menu li:hover{
    cursor: pointer;
}

.book-menu.book-menu-hide{
    display: none;
}

.cancel-menu{
    position: absolute;
    top:75px;
    right: 0;
    z-index: 3;
}
.cancel-menu:hover{
    cursor: pointer;
}

/* status section styling */
/* ------------------------------------------------------------- */
.book-status-section-div{
    z-index: 4;
}

.book-status-section-div.book-status-section-open{
    scale:1;
    opacity:1;
    transform: translate(0%);    
}




/* --------------------------------------------------------------- */
/* tab styling */
/* ---------------------------------------------------------------------- */
.tab-section ul{
    display: flex;
    justify-content:flex-start;
    gap:20px;
    align-items: center;
    width: 100%;
    padding: 0 10px;

}
.tab-section li{
    padding: 0.5em;
    background-color: rgb(255, 255, 144);
    border-radius: 10px;
    margin: 3px 0;
    font-weight: bold;
    text-align: center;
    color:black;
    list-style: none;
    width: fit-content;
    transition: all 0.2s ease;
}

.tab-section li:first-child{
    color:rgb(255, 255, 144);
    background-color: black;
}

.tab-section li:hover{
    cursor:pointer;
}


/* --------------------------------------------------------------------------- */
/* collection tab styling */
.collection-tab{
    position: relative;
    width:100%;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
    padding: 0.5em;
    border-bottom:  1px solid black;
}

.collection-tab a{
    padding: .4em;
    background-color: black;
    color: beige;
    border-radius: 8px;
}

/* add collection menu  */
/* ----------------------------------------------------------------------------------------------------------------- */
.add-collection{
    padding: .3em;
    background-color: black;
    color: beige;
    border-radius: 8px;
}


.add-collection:hover{
    cursor:pointer;
}

.add-collection-section-div{
    display: none;
    z-index: 4;
}

.add-collection-section{
    transition: all 0.4s ease;
    overflow-y:scroll ;
}

.add-collection-section-div.open-add-section{
    display:flex ;
}

/* cancel universal styling  */
/* -------------------------------------------------------------------------------- */
.cancel{
    position:fixed;
    top: 75px;
    right: 0;
}

/* collection creation input  */
/* --------------------------------------------------------------------------------------------- */
#collectionNameCreate{
    position: fixed;
    top: 0;
    right: 0;
    width: 100%;
    height: 100%;
    padding: 20px;
    backdrop-filter: blur(8px);
    display: flex;
    gap:10px;
    align-items: center;
    justify-content: center;
    transition:all 0.2s ease;
    transform: translateY(-100%);
    z-index: 1;
    animation: slide_down 1s forward;
}
#collectionNameCreate.open{
    transform:translateY(0%);
}

#collectionNameCreate button{
    outline: none;
    border:1px solid black;
    border-radius: 10%;
    padding: 1em;
    background-color: black;
    color: rgb(253, 253, 162);
}

#collectionNameCreate input:hover{
    cursor:pointer;
}
.cancel-input-collection{
    position: absolute;
    top:75px;
    right: 0;
    z-index: 3;
}

.cancel-input-collection:hover{
    cursor: pointer;
}

/* Public shelf viewing styling */
/* ------------------------------------------------------------------------------------------------------------------------------------- */

/*shelf public and private toggle button*/
.shelf-status{
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
    border-radius: 10px;
}
.shelf-status button{
    border: 1px solid black;
    background-color: beige;
    color :black;
}
.shelf-status button:hover{
    background-color: black;
    color: beige;
}
/* page view styling  */
.users-shelves{
    padding: 20px;
    display: flex;
    flex-direction: column;
    width: 100%;
}
.shelf-owner{
    padding: 1rem;
    font-size: 25px;
    padding-left: 0;
    font-style: italic;
}
.user-shelf{
    margin-bottom: 0;
    border-radius:10px ;
    padding:0;
    padding-top: 10px;
}

.user-shelf-div{
    border: 2px solid black;
    box-shadow: 0 0 18px black;
    background-color: rgba(0, 0, 0, 0.129);
    margin-bottom: 3rem;
    padding: 1rem;
    padding-bottom: 0;
    height: fit-content;
    border-radius: 10px;
}


@media (max-width:1030px) {
    .add-collection-section{
        right: 50vw;
    }
}


@media (max-width:590px) {
    
    .shelf-book-item img{
        height: auto;
        width: 120px ;
    }
    .shelf-book-item h3{
        font-size: 12px;
    }
    .all-books-shelf{
        height: 250px;
        padding: 0;
        /* overflow: visible;
        flex-wrap: wrap; */
        padding-left: 10px;
    }
    .all-books-shelf::-webkit-scrollbar{
        height: 5px;
    }
    .tab-section ul{
        flex-wrap: wrap;
        gap: 0;
    }
    .tab-section li{
        font-size: 14px;
        padding:2px;
        margin-left: 5px;
        border-radius: 5px;
        
    }
    
}

@media (max-width:278px) {
    .topbar{
        justify-content: center;
    }
    .top-tab{
        gap:7px;
        align-items: center;
    }
    .topbar button{
        font-size: 13px;
    }
    .book-menu li{
        font-size: 15px;
        padding: 0.5em;
    }

}

@media (max-width:480px) {
    .top-tab{
        gap: 1px;
        flex-direction: column;
    }
    .top-tab h1{
        align-self: flex-start;
    }
    .top-tab .community-shelf{
        align-self:flex-end;
    }
}