* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: "Nunito", sans-serif;
}

body {
    background-color: #f2f2f2;
    color: #333;
}

.navbar {
    background-color: #4a90e2;
    padding: 1rem 2rem;
    text-align: center;
    color: white;
}

.bookcontainer {
    display: grid;
    grid-template-columns: repeat(3,1fr);
    gap: 20px;
    padding: 20px;
    max-width: 1200px;
    margin: auto;
}

.bookspace {
    border: 1px solid #ccc;
    padding: 15px;
    border-radius: 10px;
    background-color: #fdfdfd;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}


.bookspace:hover {
    transform: scale(1.02);
}

.bookspace h2 {
    font-size: 1.2rem;
    color: #333;
}

.bookspace h5 {
    font-size: 0.9rem;
    color: #888;
    margin-bottom: 0.5rem;
}
.bookspace h2,
.bookspace h5 {
    word-wrap: break-word;
    overflow-wrap: break-word;
    max-width: 100%;
    line-height: 1.3;
}


.bookspace p {
    font-size: 0.95rem;
    margin: 0.5rem 0 1rem;
    word-wrap: break-word;
    overflow-wrap: break-word;
    max-width: 100%;
}


.bookspace button {
    background-color: #e74c3c;
    color: white;
    border: none;
    padding: 0.4rem 0.8rem;
    border-radius: 5px;
    cursor: pointer;
}

.addbook {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    background-color: #2ecc71;
    color: white;
    font-size: 2rem;
    border: none;
    border-radius: 50%;
    width: 60px;
    height: 60px;
    cursor: pointer;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.bookaddbox {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0);
    background-color: white;
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
    z-index: 1000;
    width: 90%;
    max-width: 400px;
    transition: transform 0.3s ease;
}

.bookaddbox.active {
    transform: translate(-50%, -50%) scale(1);
}

.bookaddbox h3 {
    margin-bottom: 1rem;
}

.bookaddbox form {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.bookaddbox input,
.bookaddbox textarea {
    padding: 0.5rem;
    font-size: 1rem;
    border: 1px solid #ccc;
    border-radius: 5px;
}

.bookaddbox button {
    padding: 0.5rem;
    font-size: 1rem;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    background-color: #3498db;
    color: white;
}

.overlay {
    position: fixed;
    top: 0;
    left: 0;
    height: 100%;
    width: 100%;
    background-color: rgba(0, 0, 0, 0.4);
    display: none;
    z-index: 999;
}

.overlay.active {
    display: block;
}
@media screen and (max-width: 768px) {
    .bookspace {
        width: 90%;
    }
}
@media (max-width: 768px) {
    .bookcontainer {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 480px) {
    .bookcontainer {
        grid-template-columns: 1fr;
    }
}

