/* General Body and Layout */
body {
    font-family: 'Arial', sans-serif;
    margin: 0;
    padding: 0;
    background-color: #e8f5e9; /* Light green background */
    color: #388e3c; /* Dark green text */
    overflow-x: hidden; /* Prevent horizontal scrolling */
    overflow-y: auto; /* Allow vertical scrolling */
    padding-top: 80px; /* Reduced padding to accommodate header */
    padding-bottom: 60px; /* Space for fixed footer */
}

/* Header */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background-color: #388e3c;
    color: white;
    padding: 20px 0;
    display: flex;
    justify-content: center; /* Center-aligns .site-title */
    align-items: center;
    z-index: 12;
}

/* Logo */
.logo img {
    width: 180px; /* Set logo size */
    height: 60px;
    transition: transform 0.3s ease;
}

/* Site Title */
.site-title {
    font-size: 2rem;
    color: #ffcc00; /* Golden color for contrast */
    margin: 0;
    opacity: 0;
    transform: translateY(-20px); /* Slightly reduced offset */
    animation: fadeInUp 1s forwards 0.5s;
    animation-fill-mode: forwards; /* Ensures final state is retained */
    z-index: 11; /* Higher than other elements if needed */
}
/* Fade-in Animation for Heading */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}
/* Update Header's z-index if necessary */
.header {
    z-index: 12; /* Ensures header is above other elements */
}
/* Heading Animations */
.site-title.animate-heading, .edition-title.animate-heading {
    animation: colorShift 2s infinite alternate, scaleUp 1.5s ease-out;
}

/* Color Shift Animation */
@keyframes colorShift {
    0% {
        color: #388e3c; /* Dark green */
    }
    50% {
        color: #4caf50; /* Light green */
    }
    100% {
        color: #2e7d32; /* Another shade of green */
    }
}

/* Scale Effect Animation */
@keyframes scaleUp {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
    100% {
        transform: scale(1);
    }
}

/* Main Content */
.main {
    padding: 20px;
    text-align: center;
    margin-top: 20px; /* Reduce spacing below fixed header */
}

/* Cover Image Container */
.cover-image {
    width: 375px;
    height: 400px;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
    margin: 0 auto; /* Center align */
}

/* Cover Image */
.cover-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

/* Content Section */
.content {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
}

.card {
    background-color: white;
    border: 2px solid #388e3c;
    border-radius: 10px;
    width: 300px;
    margin: 15px;
    padding: 20px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease-in-out, box-shadow 0.3s ease;
}

.card:hover {
    transform: translateY(-10px);
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.2);
}

/* Card Icon */
.card-icon img {
    width: 50px;
    height: 50px;
    margin-bottom: 15px;
}

/* Card Content */
.card-content p {
    font-size: 1.2rem;
    margin-bottom: 10px;
}

.card-content .btn-read {
    display: block;
    margin-top: 10px;
    padding: 10px;
    background-color: #388e3c;
    color: white;
    text-decoration: none;
    border-radius: 5px;
    transition: background-color 0.3s ease;
}

.card-content .btn-read:hover {
    background-color: #2e7d32;
}

/* Footer */
.footer {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background-color: #388e3c;
    color: white;
    padding: 15px;
    text-align: center;
    z-index: 10;
}

.footer a {
    color: #ffcc00; /* Golden color for contrast */
    text-decoration: none;
}

.footer a:hover {
    text-decoration: underline;
}

/* Scroll-to-Top Button */
.scroll-top-btn {
    position: fixed;
    bottom: 80px; /* Space above footer */
    right: 30px;
    background-color: #388e3c;
    color: white;
    border: none;
    border-radius: 50%;
    padding: 15px;
    font-size: 20px;
    cursor: pointer;
    display: none;
    transition: background-color 0.3s ease;
}

.scroll-top-btn:hover {
    background-color: #2e7d32;
}

/* Media Queries */
@media (max-width: 768px) {
    .content {
        flex-direction: column;
        align-items: center;
    }

    .card {
        width: 90%;
    }
}

/* Book Viewer Section */
.pdf-book-section {
    margin: 30px auto;
    text-align: center;
    padding: 20px;
    background-color: #f1f8e9;
    border: 2px solid #388e3c;
    border-radius: 10px;
    width: 90%;
    max-width: 1000px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

.pdf-title {
    font-size: 1.5rem;
    color: #388e3c;
    margin-bottom: 15px;
}

/* Book Canvas */
.pdf-book {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
    margin-bottom: 15px;
}

.pdf-book canvas {
    border: 1px solid #388e3c;
    border-radius: 5px;
    width: 45%;
    height: auto;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

/* Navigation Buttons */
.book-controls {
    display: flex;
    justify-content: center;
    gap: 20px;
}

.btn-nav {
    background-color: #388e3c;
    color: white;
    border: none;
    padding: 10px 20px;
    font-size: 1rem;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.btn-nav:hover {
    background-color: #2e7d32;
}

