@import url('https://fonts.googleapis.com/css2?family=Poppins:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,100;1,200;1,300;1,400;1,500;1,600;1,700;1,800;1,900&display=swap');

*{
    margin: 0;
    padding: 0;
    box-sizing: border-box;
	font-family: "Poppins", sans-serif;
}

body {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100vh;
    width: 100vw;
    overflow: hidden;
    background: #a3a3a2;
    perspective: 1000px;
    position: relative;
    padding-bottom: 80px;
}

.logo-container {
    position: fixed;
    top: 5px;
    left: 5px;
    z-index: 1001;
    /* background: rgba(255, 255, 255, 0.9); */
    padding: 10px;
    border-radius: 8px;
    /* box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1); */
    transition: transform 0.3s ease;
}

.logo-container:hover {
    transform: scale(1.05);
}

.control-bar {
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 1000;
    background: rgba(0, 0, 0, 0.7);
    padding: 10px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-radius: 10px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    width: 90%;
    max-width: 1200px;
}

.left-controls, .center-controls, .right-controls {
    display: flex;
    align-items: center;
    gap: 15px;
}

.zoom-controls {
    display: flex;
    align-items: center;
    gap: 5px;
    background: rgba(255, 255, 255, 0.1);
    padding: 3px;
    border-radius: 25px;
}

#zoomLevel {
    background: none;
    border: none;
    color: white;
    padding: 5px;
    font-size: 14px;
    width: 70px;
    text-align: center;
    cursor: pointer;
    outline: none;
}

#zoomLevel option {
    background: #333;
    color: white;
}

.page-info {
    display: flex;
    align-items: center;
    gap: 5px;
    color: white;
    font-size: 14px;
}

#currentPage {
    background: rgba(255, 255, 255, 0.1);
    border: none;
    color: white;
    width: 40px;
    text-align: center;
    padding: 5px;
    border-radius: 4px;
    font-size: 14px;
}

#totalPages {
    color: white;
    font-size: 14px;
}

.controls {
    display: flex;
    gap: 15px;
}

.controls button {
    background: rgba(255, 255, 255, 0.1);
    border: none;
    color: white;
    font-size: 18px;
    padding: 8px;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s ease;
    min-width: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.controls button:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: scale(1.05);
}

.controls button:active {
    background: rgba(255, 255, 255, 0.3);
    transform: scale(0.95);
}

.controls button i {
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.flipbook-container {
    filter: drop-shadow(0 10px 20px rgba(0,0,0,0.3));
}

.flipbook {
    width: 900px;
    height: 580px;
    position: relative;
    transform-style: preserve-3d;
}

.flipbook.cover-page::after,
.flipbook.back-cover::after {
    display: none;
}

.flipbook:not(.cover-page):not(.back-cover)::after {
    content: '';
    position: absolute;
    right: 0;
    top: 0;
    width: 20px;
    height: 100%;
    background: linear-gradient(to right, rgba(0,0,0,0), rgba(0,0,0,0.2));
    pointer-events: none;
    z-index: 1;
}

.flipbook .hard {
    background: #fafafa !important;
    color: #fff;
    font-weight: bold;
    border: none;
    padding: 0 !important;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    gap: 1rem;
}

.flipbook .hard h2 {
    font-size: 2.5rem;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.flipbook .hard img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
    margin: 0;
    padding: 0;
}



.flipbook .page {
    background: white;
	display: flex;
	flex-direction: column;
	justify-content: center;
	align-items: center;
    gap: 10px;
    border: 1px solid rgba(0, 0, 0, 0.11);
}

.page img {
    width: 90%;
    object-fit: cover;
}

/* Turn.js specific styles */
.flipbook .turn-page {
    background-color: white;
    background-size: 100% 100%;
}

.flipbook .page-wrapper {
    perspective: 2000px;
}

.flipbook .shadow {
    box-shadow: 0 4px 10px rgba(0,0,0,0.15);
}

/* Animation for page turning */
@keyframes pageFlip {
    0% { transform: rotateY(0deg); }
    100% { transform: rotateY(-180deg); }
}

.turn-animation {
    animation: pageFlip 0.6s ease-in-out;
}

/* Gradient overlay for page edges */
.flipbook .gradient {
    position: absolute;
    top: 0;
    right: 0;
    width: 20px;
    height: 100%;
    background: linear-gradient(to right, rgba(0,0,0,0), rgba(0,0,0,0.2));
    pointer-events: none;
}


.flipbook .page small{
	font-size: 14px;
    margin-bottom: 10px;
}

/* Thumbnail view styles */
.thumbnails-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 200px;
    height: 100vh;
    background: rgba(0, 0, 0, 0.9);
    z-index: 999;
    overflow-y: auto;
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.thumbnail {
    cursor: pointer;
    transition: transform 0.2s;
    border: 2px solid transparent;
}

.thumbnail:hover {
    transform: scale(1.05);
    border-color: #f1c40f;
}

.thumbnail img {
    width: 100%;
    height: auto;
    display: block;
}

.controls button.active {
    background: rgba(241, 196, 15, 0.3);
}

.flipbook {
    transition: transform 0.3s ease;
}

/* Print styles */
@media print {
    .control-bar {
        display: none;
    }
    
    .thumbnails-container {
        display: none;
    }
    
    body {
        background: white;
    }
}

/* Mobile responsive styles */
@media (max-width: 768px) {
    .control-bar {
        padding: 5px 10px;
    }
    
    .controls button {
        padding: 6px;
        min-width: 35px;
    }
    
    .zoom-controls {
        display: none;
    }
    
    .thumbnails-container {
        width: 100%;
        height: 150px;
        flex-direction: row;
        overflow-x: auto;
    }
    
    .thumbnail {
        flex: 0 0 120px;
    }
}
