body {
    margin: 0;
    background: #0a0a0a url('images/grunge_purple.jpg') repeat; 
    color: #c7b7d8;
    font-family: "Verdana", sans-serif;
    font-size: 14px;
}


#content-area {
    display: flex;
    gap: 20px;
}

#wrapper {
    width: 800px;
    margin: 40px auto;
    background: rgba(20, 0, 30, 0.65);
    border: 1px solid #3a003a;
    padding: 20px;
    box-shadow: 0 0 30px #2d1338;
}

header h1 {
    font-family: "Press Start 2P", monospace;
    font-size: 36px;
    color: #9f1fff;
    text-shadow: 0 0 8px #9f1fff;
    text-align: center;
    margin-bottom: 5px;
}

nav {
    text-align: center;
    margin-bottom: 25px;
    padding: 12px 0;
    background: rgba(20, 0, 30, 0.45);
    border-top: 1px solid #3a003a;
    border-bottom: 1px solid #3a003a;
    box-shadow: 0 0 12px #2d1338;
    backdrop-filter: blur(2px);
    position: relative;
    overflow: hidden;
}

.divider {
    width: 100%;
    height: 2px;
    background: linear-gradient(to right, #3a003a, #b300ff, #3a003a);
    margin: 30px 0;
    box-shadow: 0 0 10px #6a00a8;
}


nav a {
    color: #c7b7d8;
    text-decoration: none;
    font-family: "Press Start 2P", monospace;
    font-size: 12px;
    padding: 8px 14px;
    margin: 0 6px;
    display: inline-block;
    transition: 0.2s ease;
    border-radius: 3px;
    position: relative;
}

nav a .icon {
    color: #b300ff;
    margin-right: 6px;
    text-shadow: 0 0 6px #b300ff;
}


nav a:hover {
    color: #b300ff;
    text-shadow: 0 0 6px #b300ff, 0 0 12px #6a00a8;
    background: rgba(179, 0, 255, 0.12);
    box-shadow: 0 0 10px #6a00a8;
    transform: translateY(-1px);
}


nav a.active {
    color: #d8b4ff;
    background: rgba(179, 0, 255, 0.18);
    box-shadow: 0 0 12px #b300ff inset;
}


#header-title {
    position: relative;
    bottom: 50px;
    left: 20px;
    font-family: "Press Start 2P", monospace;
    font-size: 42px;
    color: #d8b4ff;
    text-shadow: 
        0 0 6px #d8b4ff,
        0 0 12px #9f1fff,
        0 0 20px #9f1fff;
    letter-spacing: 2px;
}

#content-area {
    display: flex;
    gap: 20px;
}

#main {
    flex: 1;
}

#bookshelf {
    display: flex;
    justify-content: center;
    gap: 40px;
    margin-top: 40px;
    background: url('') center/cover no-repeat;
    padding: 40px;
}

.book {
    text-align: center;
    cursor: pointer;
    width: 160px;
    transition: transform 0.3s ease, filter 0.3s ease;
    perspective: 800px;
}

.book img {
    height: auto;
    filter: drop-shadow(0 0 10px #6a00a8);
    width: 100%;
    transform: rotateY(-8deg);
    transition: transform 0.3s ease;
}

.book:hover {
    transform: rotateY(0deg) scale(1.05);
    filter: drop-shadow(0 0 12px #b300ff);
}

.book h3 {
    font-family: "Press Start 2P", monospace;
    color: #d8b4ff;
     margin-top: 10px;
}


#book-modal {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.7);
    backdrop-filter: blur(3px);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 999;
    
}

#book-modal.hidden {
    display: none;
}

#book-open {
    width: 800px;
    height: 500px;
    background-size: cover;
    background-position: center;
    border: 2px solid #3a003a;
    box-shadow: 0 0 25px #b300ff;
    border-radius: 8px;
    position: relative;
    display: flex;
    animation: openBook 0.6s ease forwards;
}

@keyframes openBook {
    0% { transform: scale(0.8) rotateY(-30deg); opacity: 0; }
    100% { transform: scale(1) rotateY(0deg); opacity: 1; }
}

.book-left-page,
.book-right-page {
    width: 50%;
    padding: 30px;
    overflow-y: auto;
    font-family: "Cormorant Garamond", serif;
    font-size: 18px;
    color: #37284F;
}

.book-left-page {
    border-right: 1px solid #3a003a;
}

.page-controls {
    position: absolute;
    bottom: 20px;
    right: 20px;
}

.page-controls button {
    background: #b300ff;
    color: white;
    border: none;
    padding: 8px 12px;
    margin-left: 5px;
    cursor: pointer;
    font-family: "Press Start 2P", monospace;
    border-radius: 4px;
}

#book-content {
    width: 70%;
    max-width: 800px;
    background: rgba(20, 0, 30, 0.8);
    border: 2px solid #3a003a;
    box-shadow: 0 0 20px #b300ff;
    padding: 30px;
    border-radius: 8px;
    position: relative;
    color: #37284F;
    font-family: "Cormorant Garamond", serif;
    font-size: 18px;
    line-height: 1.6;
}


#close-book {
    position: absolute;
    top: 10px;
    right: 10px;
    background: #b300ff;
    color: white;
    border: none;
    padding: 6px 10px;
    cursor: pointer;
    font-family: "Press Start 2P", monospace;
    font-size: 12px;
    border-radius: 4px;
}


.poetry-theme .book-left-page,
.poetry-theme .book-right-page {
    background: rgba(255, 240, 220, 0.1);
}

.art-theme .book-left-page,
.art-theme .book-right-page {
    background: rgba(255, 255, 255, 0.05);
}

.stories-theme .book-left-page,
.stories-theme .book-right-page {
    background: rgba(20, 0, 30, 0.2);
}



.divider {
    width: 100%;
    height: 2px;
    background: linear-gradient(to right, #3a003a, #b300ff, #3a003a);
    margin: 30px 0;
    box-shadow: 0 0 10px #6a00a8;
}

h2 {
    font-family: "Press Start 2P", monospace;
    color: #b300ff;
    border-bottom: 1px solid #333;
    padding-bottom: 5px;
    margin-top: 40px;
}

p {
    font-family: "Cinzel", serif;
    color: #37284F;
    font-size: 15px;
}

footer {
    text-align: center;
    margin-top: 40px;
    font-size: 12px;
    color: #555;
}
