/* Basic Reset */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Arial, sans-serif;
}

body {
    background-color: #f4f7f6;
    color: #333;
    line-height: 1.6;
    animation: fadeIn 0.8s ease-in-out; 
    overflow-x: hidden; /* Drawer slide hote waqt page horizontal scroll na ho */
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Upgraded Navbar Layout */
.custom-navbar {
    background: linear-gradient(135deg, #2c3e50 100%); 
    height: 80px;
    display: flex;
    align-items: center;
    position: sticky;
    top: 0;
    z-index: 1000;
    width: 100%;
    padding: 0 5%;
    justify-content: space-between;
}

/* Logo aur Text Area Alignment */
.nav-logo-section {
    display: flex;
    align-items: center;
    gap: 15px;
}

.nav-logo-img {
    height: 65px; 
    width: auto;
    object-fit: contain;
    margin-left: 100px;
}

.nav-brand-title {
    color: white;
    font-size: 1.6rem;
    font-weight: bold;
    line-height: 1.2;
    letter-spacing: 0.5px;
}

/* Right Side Elements: Home, Button, Login/Logout */
.nav-main-links {
    display: flex;
    align-items: center;
    gap: 25px;
    margin-right: 100px;
}

.nav-fixed-link {
    color: white !important;
    text-decoration: none;
    font-weight: bold;
    font-size: 20px;
    padding: 8px 16px;
    transition: all 0.3s ease;
    border-radius: 5px;
}

.nav-fixed-link:hover, .active-link:hover {
    background-color: #000000;
    color: #ffffff !important;
}

/* Three Line Hamburger Icon Component Construction */
.hamburger-menu-btn {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    width: 25px;
    height: 18px;
    background: transparent !important;
    border: none !important;
    cursor: pointer;
    padding: 0;
    outline: none !important;
}

.hamburger-menu-btn .bar {
    width: 100%;
    height: 3px;
    background-color: #ffffff;
    border-radius: 4px;
    transition: all 0.3s ease-in-out;
}

.hamburger-menu-btn:hover .bar {
    background-color: #ff4757; /* Modern Hover Color Accent */
}

/* Pop-Out Light-Mode Action Navigation Drawer Panel */
.menu-drawer-overlay {
    position: fixed;
    top: 0;
    right: -320px; /* Window se bahar default state */
    width: 290px;
    height: 100vh;
    background: #ffffff !important; /* Premium light mode look */
    box-shadow: -8px 0 30px rgba(0, 0, 0, 0.2);
    transition: right 0.35s cubic-bezier(0.25, 0.8, 0.25, 1);
    z-index: 99999;
    padding: 40px 25px;
    display: flex;
    flex-direction: column;
}

/* Trigger state jab menu open hoga */
.menu-drawer-overlay.drawer-open {
    right: 0 !important;
}

.close-drawer-btn {
    position: absolute;
    top: 15px;
    right: 22px;
    background: transparent;
    border: none;
    font-size: 2.2rem;
    color: #88898b;
    cursor: pointer;
    line-height: 1;
    transition: color 0.2s;
}

.close-drawer-btn:hover {
    color: #ff4757;
}

.drawer-links-wrapper {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 35px;
    text-align: left;
}

.drawer-section-title {
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 1.8px;
    color: #a4b0be;
    font-weight: 700;
    margin: 15px 0 6px 0;
    border-bottom: 1px solid #f1f2f6;
    padding-bottom: 6px;
}

/* Links inside the sliding drawer */
.drawer-links-wrapper a {
    color: #2c3e50 !important;
    text-decoration: none !important;
    font-size: 1.02rem;
    font-weight: 600;
    padding: 11px 14px;
    border-radius: 8px;
    transition: all 0.25s ease;
    display: block;
}

.drawer-links-wrapper a:hover {
    background: #fff0f1 !important;
    color: #ff4757 !important;
    padding-left: 22px; /* Smooth left sliding effect */
}

/* Header Container */
.header {
    position: relative; 
    height: 623px;
    width: 100%;
    overflow: hidden; 
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: white;
}

/* Background Slider Styling */
.header-slider {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1; 
}

.slide {
    position: absolute;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    opacity: 0;
    animation: fadeSlider 15s infinite; 
}

/* Dark Overlay */
.slide::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6); 
}

/* Slider Timing Controls */
.slide:nth-child(1) { animation-delay: 0s; }
.slide:nth-child(2) { animation-delay: 5s; }
.slide:nth-child(3) { animation-delay: 10s; }

/* Text Content Styling */
.header-content {
    position: relative;
    z-index: 2; 
}

/* Smooth Fade Animation */
@keyframes fadeSlider {
    0% { opacity: 0; }
    10% { opacity: 1; } 
    33% { opacity: 1; } 
    43% { opacity: 0; } 
    100% { opacity: 0; }
}

.logo {
    bottom: 50%;
    top: 10px;
    margin-bottom: 15px;
    border: 3px solid rgb(221, 217, 217);
    border-radius: 80px;
    position: absolute;
    transform: translate(-50%, -50%);
}

.header h1 {
    font-size: 3rem;
    margin-top: 80px;
}

/* Search Container */
.search-container {
    text-align: center;
    margin: 40px auto;
    max-width: 600px;
    padding: 0 20px;
}

/* Styled Search Input */
#myInput {
    width: 100%;
    padding: 15px 25px;
    font-size: 18px;
    border: none;
    border-radius: 50px; 
    background: #ffffff;
    box-shadow: 0 0 10px rgba(0,0,0,0.1), 
                0 0 20px rgba(231, 76, 60, 0.2); 
    outline: none;
    transition: all 0.4s ease;
    color: #333;
}

.books {
    margin-top: 50px;
    padding-right: 150px;
    background-color: #000000;
    font-style: italic;
    color: #dd9999;
}

/* Featured Categories - Systematic Layout */
.featured-categories {
    padding: 80px 20px;
    text-align: center;
    background: #ffffff; 
}

.section-title {
    font-size: 32px;
    color: #235d93;
    margin-bottom: 50px;
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.category-grid {
    display: flex;
    justify-content: center;
    gap: 25px;
    flex-wrap: wrap;
    max-width: 1100px;
    margin: 0 auto;
}

.category-card {
    background: rgba(118, 75, 162, 0.03); 
    padding: 40px 25px;
    border-radius: 25px;
    width: 300px;
    border: 2px solid #eef0f2;
    transition: all 0.4s ease;
}

.category-card:hover {
    transform: translateY(-15px);
    background: white;
    box-shadow: 0 20px 40px rgba(118, 75, 162, 0.15);
    border-color: #764ba2;
}

.category-card .icon {
    font-size: 40px;
    margin-bottom: 15px;
}

.category-card h3 {
    color: #755f9a;
    font-size: 22px;
    margin-bottom: 15px;
}

.category-card p {
    color: #666;
    font-size: 14px;
    line-height: 1.6;
}

.cat-btn {
    margin-top: 25px;
    display: inline-block;
    padding: 10px 30px;
    background: #5a617b;
    color: white;
    text-decoration: none;
    border-radius: 50px;
    font-weight: bold;
    transition: 0.3s;
}

/* Wisdom/Quote Section */
.wisdom-section {
    padding: 100px 20px;
    background-size: cover;
    background-attachment: fixed;
    color: rgb(27, 22, 22);
    text-align: center;
}

.quote-container {
    max-width: 900px;
    margin: 0 auto;
}

.quote-box {
    margin: 40px 0;
}

.quote-text {
    font-size: 23px;
    font-family: 'Georgia', serif;
    font-style: italic;
    line-height: 1.4;
    margin-bottom: 15px;
}

.quote-author {
    font-size: 18px;
    color: #5065c0;
    font-weight: bold;
    display: block;
    margin-top: 10px;
}

.quote-divider {
    height: 2px;
    width: 100px;
    background: rgba(255, 255, 255, 0.3);
    margin: 0 auto;
}

/* Footer/About */
.main-footer {
    background: linear-gradient(135deg, #2c3e50 100%); 
    color: white;
    padding: 70px 0 40px 0;
    font-family: 'Poppins', sans-serif;
    margin-top: 15px; 
}

.footer-content {
    max-width: 1000px;
    margin: 0 auto;
    display: flex;
    justify-content: space-around;
    flex-wrap: wrap; 
    padding: 0 20px;
}

.footer-section {
    flex: 1;
    padding: 50px;
    min-width: 250px;
}

.footer-section h2, .footer-section h3 {
    color: #ffffff;
    margin-bottom: 20px;
    font-size: 30px;
    font-weight: bold;
}

.footer-logo {
    font-size: 30px;
    font-weight: bold;
}

.footer-section p {
    font-size: 17px;
    line-height: 1.6;
    opacity: 0.9;
}

.footer-section ul li a:visited {
    color: white;
}

.footer-section ul {
    padding-left: 25px;
}

/* Footer Bottom Strip */
.footer-bottom {
    text-align: center;
    padding-top: 20px;
    margin-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.2);
    font-size: 18px;
    opacity: 0.7;
}

/* Mobile Responsive Setup */
@media (max-width: 768px) {
    .custom-navbar {
        padding: 0 20px;
    }
    .nav-brand-title {
        font-size: 1.2rem;
    }
    .category-grid {
        gap: 15px;
    }
}

@media (max-width: 600px) {
    .header h1 { font-size: 2rem; }
    .nav-fixed-link { font-size: 15px; padding: 6px 10px; }
}