* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}
.book_acount
{
    margin-right: 10px;
}
body {
    font-family: 'Cairo', sans-serif;
    background: #F5F7FA;
    color: #1a1a1a;
    overflow-x: hidden;
}

/* ========================================
   NAVBAR STYLES ONLY - ADD THIS TO YOUR EXISTING CSS
   ======================================== */

/* New Navbar */
.navbar-new {
    background: #ffffff;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    padding: 16px 0;
    position: sticky;
    top: 0;
    z-index: 1000;
}

.navbar-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 40px;
}

/* Logo Section (Right) - Using nav-left class name as per your HTML */
.nav-left {
    flex-shrink: 0;
    display: flex;
    align-items: center;
}

.globe-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 8px;
    background: #ffffff;
    border-radius: 8px;
}

.globe-icon img {
    height: 50px;
    width: auto;
    max-width: 180px;
    object-fit: contain;
    display: block;
}

/* Search Bar (Center) */
.navbar-center {
    flex: 1;
    max-width: 600px;
}

.search-bar-nav {
    position: relative;
    width: 100%;
}

.search-input-nav {
    width: 100%;
    padding: 12px 50px 12px 20px;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    font-family: 'Cairo', sans-serif;
    font-size: 14px;
    background: #f9f9f9;
    transition: all 0.3s;
    direction: rtl;
}

.search-input-nav:focus {
    outline: none;
    border-color: #3FA56C;
    background: #ffffff;
}

.search-input-nav::placeholder {
    color: #999;
}

.search-button-nav {
    position: absolute;
    left: 8px;
    top: 50%;
    transform: translateY(-50%);
    background: transparent;
    border: none;
    padding: 8px;
    cursor: pointer;
    color: #666;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.3s;
}

.search-button-nav:hover {
    color: #3FA56C;
}

/* Navigation Links (Left Side) */
.navbar-left {
    display: flex;
    align-items: center;
    gap: 24px;
    flex-shrink: 0;
}

.nav-link-new {
    color: #333;
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: color 0.3s;
    white-space: nowrap;
}

.nav-link-new:hover {
    color: #3FA56C;
}

/* Language Button */
.lang-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 12px;
    background: transparent;
    border: 1px solid #e0e0e0;
    border-radius: 6px;
    font-family: 'Cairo', sans-serif;
    font-size: 14px;
    font-weight: 500;
    color: #666;
    cursor: pointer;
    transition: all 0.3s;
}

.lang-btn:hover {
    border-color: #3FA56C;
    color: #3FA56C;
}

.lang-btn svg {
    color: inherit;
}

/* Responsive Design for New Navbar */
@media (max-width: 1200px) {
    .navbar-left {
        gap: 16px;
    }

    .nav-link-new {
        font-size: 13px;
    }

    .globe-icon img {
        height: 40px;
        max-width: 150px;
    }
}

@media (max-width: 992px) {
    .navbar-container {
        flex-direction: column;
        gap: 16px;
    }

    .navbar-center {
        max-width: 100%;
        order: 3;
    }

    .navbar-left {
        order: 2;
        flex-wrap: wrap;
        justify-content: center;
    }

    .nav-left {
        order: 1;
    }
}

@media (max-width: 768px) {
    .navbar-left {
        display: none;
    }

    .navbar-container {
        flex-direction: row;
    }

    .navbar-center {
        order: 2;
    }

    .globe-icon img {
        height: 35px;
        max-width: 120px;
    }
}

/* ========================================
   END OF NAVBAR STYLES
   ======================================== */
.library-title {
    color: #3FA56C;
    font-size: 18px;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 8px;
}

/* Top Search Bar */
.top-search-bar {
    background: #ffffff;
    padding: 20px 24px;
    margin-top: 60px;
    border-bottom: 1px solid #e5e7eb;
}

.search-container {
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    gap: 12px;
    align-items: center;
}

.main-search-input {
    flex: 1;
    padding: 12px 16px;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    font-family: 'Cairo', sans-serif;
    font-size: 14px;
    background: #F9FAFB;
}

.main-search-input::placeholder {
    color: #9ca3af;
}

.search-btn {
    padding: 12px 24px;
    background: #ffffff;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    font-family: 'Cairo', sans-serif;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s;
}

.search-btn:hover {
    background: #F9FAFB;
}

/* Catalog Section */
.catalog-section {
    padding: 40px 20px 80px;
    background: #F5F7FA;
    min-height: 100vh;
}

.catalog-container {
    max-width: 1400px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 24px;
}

/* Sidebar */
.catalog-sidebar {
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    padding: 24px;
    height: fit-content;
    position: sticky;
    top: 160px;
}

.sidebar-title {
    font-family: 'Cairo', sans-serif;
    font-size: 16px;
    font-weight: 700;
    color: #1a1a1a;
    margin-bottom: 16px;
}

.sidebar-search {
    margin-bottom: 32px;
}

.search-input-group {
    display: flex;
    align-items: center;
    background: #F9FAFB;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    padding: 0 12px;
    transition: all 0.3s ease;
}

.search-input-group:focus-within {
    border-color: #3FA56C;
    box-shadow: 0 0 0 3px rgba(63, 165, 108, 0.1);
}

.sidebar-search-input {
    flex: 1;
    background: transparent;
    border: none;
    color: #1a1a1a;
    font-family: 'Cairo', sans-serif;
    font-size: 13px;
    padding: 10px 8px;
    outline: none;
}

.sidebar-search-input::placeholder {
    color: #9ca3af;
}

.sidebar-search-btn {
    background: transparent;
    border: none;
    color: #6b7280;
    font-size: 16px;
    cursor: pointer;
    padding: 4px;
}

.sidebar-filter {
    margin-bottom: 28px;
    padding-bottom: 20px;
    border-bottom: 1px solid #e5e7eb;
    position: relative;
}

.sidebar-filter:last-child {
    border-bottom: none;
}

.filter-options {
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-height: 300px;
    overflow-y: auto;
    overflow-x: hidden;
    padding-right: 8px;
    margin-right: -8px;
    scroll-behavior: smooth;
}

.filter-option {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    padding: 6px 8px;
    border-radius: 6px;
    transition: all 0.2s ease;
    font-family: 'Cairo', sans-serif;
    font-size: 13px;
    color: #4b5563;
}

.filter-option:hover {
    background: #F9FAFB;
    background-color: rgba(0, 0, 0, 0.02);
    border-radius: 4px;
    padding-right: 4px;
}

.filter-option input[type="radio"] {
    width: 16px;
    height: 16px;
    cursor: pointer;
    accent-color: #3FA56C;
}

/* Count Badge */
.count {
    font-size: 12px;
    color: #999;
    background: #f5f5f5;
    padding: 2px 8px;
    border-radius: 10px;
    font-weight: 500;
}

/* Modern Scrollbar Design - Webkit Browsers (Chrome, Safari, Edge) */
.filter-options::-webkit-scrollbar {
    width: 8px;
}

.filter-options::-webkit-scrollbar-track {
    background: linear-gradient(to bottom, #f8f9fa 0%, #e9ecef 100%);
    border-radius: 10px;
    margin: 4px 0;
}

.filter-options::-webkit-scrollbar-thumb {
    background: linear-gradient(to bottom, #6c757d 0%, #495057 100%);
    border-radius: 10px;
    border: 2px solid #f8f9fa;
    transition: all 0.3s ease;
}

.filter-options::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(to bottom, #495057 0%, #343a40 100%);
    border-color: #e9ecef;
}

.filter-options::-webkit-scrollbar-thumb:active {
    background: #212529;
}

/* Firefox Scrollbar */
.filter-options {
    scrollbar-width: thin;
    scrollbar-color: #6c757d #f8f9fa;
}

/* Fade effect at top and bottom to indicate scrollable content */
.sidebar-filter::before,
.sidebar-filter::after {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    height: 20px;
    pointer-events: none;
    z-index: 1;
    transition: opacity 0.3s ease;
}

.sidebar-filter::before {
    top: 40px;
    background: linear-gradient(to bottom, rgba(255,255,255,1) 0%, rgba(255,255,255,0) 100%);
    opacity: 0;
}

.sidebar-filter::after {
    bottom: 0;
    background: linear-gradient(to top, rgba(255,255,255,1) 0%, rgba(255,255,255,0) 100%);
}

/* Show fade effects when scrolled */
.sidebar-filter.scrolled-top::before {
    opacity: 0;
}

.sidebar-filter.scrolled-bottom::after {
    opacity: 0;
}

.sidebar-filter.scrolled-middle::before,
.sidebar-filter.scrolled-middle::after {
    opacity: 1;
}

/* Main Content */
.catalog-main {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.catalog-title {
    font-family: 'Cairo', sans-serif;
    font-size: 20px;
    font-weight: 700;
    color: #1a1a1a;
}

.filter-tabs {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    padding: 16px;
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
}

.filter-tab {
    padding: 8px 18px;
    background: #F9FAFB;
    border: 1px solid #e5e7eb;
    border-radius: 20px;
    color: #4b5563;
    font-family: 'Cairo', sans-serif;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.filter-tab:hover {
    background: #F3F4F6;
    color: #1a1a1a;
}

.filter-tab.active {
    background: #3FA56C;
    border-color: #3FA56C;
    color: #ffffff;
    font-weight: 600;
}

/* Books Grid Layout */
.books-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

/* Book Card */
.book-card {
    background: #ffffff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    border: 2px solid transparent;
    cursor: pointer;
}

.book-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.12);
    border-color: #4A90A4;
}

/* Book Image */
.book-image {
    width: 100%;
    height: 320px;
    overflow: hidden;
    background-image: url('/university/background_image.jpg');
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.book-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

/* Book Info Section */
.book-info {
    padding: 20px;
    direction: rtl;
    text-align: right;
}

/* Book Title */
.book-title {
    font-size: 20px;
    font-weight: 700;
    color: #1a1a1a;
    margin: 0 0 12px 0;
    line-height: 1.4;
    min-height: 56px;
}

/* Book Badges */
.book-badges {
    gap: 8px;
    margin-bottom: 14px;
    justify-content: flex-end;
}

.badge-format {
    padding: 6px 16px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
    color: #ffffff;
}

.badge-pdf {
    background: #28a745;
    border-radius: 20px;
}

.badge-type {
    padding: 6px 16px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 500;
    background: #f0f0f0;
    color: #666;
}

/* Book Author */
.book-author {
    align-items: center;
    gap: 8px;
    font-size: 15px;
    color: #555;
    margin: 0 0 14px 0;
    justify-content: flex-end;
}

.author-icon {
    font-size: 16px;
}

/* Download Button */
.btn-download-new {
    width: 100%;
    padding: 12px 20px;
    /* background: #28a745; */
    color: #000000;
    font-family: 'Cairo', sans-serif;
    border: none;
    border-radius: 15px;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: all 0.3s ease;
    margin-bottom: 10px;
}

.btn-download-new:hover {
    background: #218838;
    border-color: #999;
    color: #FFFFFF;
}

.download-icon {
    font-size: 18px;
}
/* Change download icon to white on button hover */
.btn-download-new:hover .download-icon img {
    filter: brightness(0) invert(1);
}
/* Optional: Add transition for smooth color change */
.download-icon img {
    transition: filter 0.3s ease;
}

/* Compare Button */
.btn-compare {
    font-family: 'Cairo', sans-serif;
    width: 100%;
    padding: 10px 20px;
    background: transparent;
    color: #666;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: all 0.3s ease;
    margin-bottom: 14px;
}

.btn-compare:hover {
    background: #218838;
    border-color: #999;
    color: #FFFFFF;
}

.compare-icon {
    font-size: 16px;
}

/* Change download icon to white on button hover */
.btn-download-new:hover .download-icon img {
    filter: brightness(0) invert(1);
}

/* Change compare icon to white on button hover */
.btn-compare:hover .compare-icon img {
    filter: brightness(0) invert(1);
}

/* Optional: Add transition for smooth color change */
.download-icon img,
.compare-icon img {
    transition: filter 0.3s ease;
}



/* Book Publisher */
.book-publisher {
    align-items: center;
    gap: 8px;
    font-size: 13px;
    color: #777;
    margin: 0;
    padding-top: 12px;
    border-top: 1px solid #f0f0f0;
    justify-content: flex-end;
}

.publisher-icon {
    font-size: 14px;
}

/* Old book card styles for compatibility */
.book-badge {
    position: absolute;
    top: 12px;
    right: 12px;
    display: flex;
    gap: 8px;
}

.badge-size {
    background: rgba(0, 0, 0, 0.6);
    color: #ffffff;
    padding: 6px 12px;
    border-radius: 6px;
    font-size: 11px;
    font-weight: 600;
}

.book-actions {
    display: flex;
    gap: 8px;
    margin-bottom: 12px;
}

.btn-icon {
    flex: 1;
    background: #F9FAFB;
    border: 1px solid #e5e7eb;
    color: #4b5563;
    padding: 10px;
    border-radius: 8px;
    font-size: 12px;
    font-family: 'Cairo', sans-serif;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.btn-icon:hover {
    background: #F3F4F6;
    color: #1a1a1a;
}

.btn-download {
    flex: 1;
    background: #3FA56C;
    border: none;
    color: #ffffff;
    padding: 10px;
    border-radius: 8px;
    font-size: 12px;
    font-weight: 600;
    font-family: 'Cairo', sans-serif;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.btn-download:hover {
    background: #2E8B57;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(63, 165, 108, 0.3);
}

.book-meta {
    display: flex;
    justify-content: space-between;
    padding-top: 12px;
    border-top: 1px solid #e5e7eb;
}

.book-meta span {
    font-family: 'Cairo', sans-serif;
    font-size: 11px;
    color: #9ca3af;
}

/* Pagination */
.pagination {
    display: flex;
    justify-content: center;
    gap: 8px;
    padding: 32px 0;
}

.page-btn {
    min-width: 40px;
    height: 40px;
    background: #ffffff;
    border: 1px solid #e5e7eb;
    color: #4b5563;
    border-radius: 8px;
    font-family: 'Cairo', sans-serif;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.page-btn:hover {
    background: #F9FAFB;
    color: #1a1a1a;
}

.page-btn.active {
    background: #3FA56C;
    border-color: #3FA56C;
    color: #ffffff;
}

/* Responsive Design */
@media (max-width: 1200px) {
    .catalog-container {
        grid-template-columns: 260px 1fr;
    }
    .books-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 992px) {
    .catalog-container {
        grid-template-columns: 1fr;
    }
    .catalog-sidebar {
        position: relative;
        top: 0;
    }
}

@media (max-width: 768px) {
    .nav-center {
        display: none;
    }
    .books-grid {
        grid-template-columns: 1fr;
    }

    .book-title {
        font-size: 18px;
        min-height: auto;
    }

    .book-image {
        height: 220px;
    }
}

@media (max-width: 480px) {
    .books-grid {
        grid-template-columns: 1fr;
    }

    .book-card {
        max-width: 100%;
    }
}
/*///////////////////////////////////*/

.book-card-link {
    text-decoration: none;
    color: inherit;
    display: block;
    transition: transform 0.2s ease;
}

.book-card-link:hover {
    transform: translateY(-5px);
}

.book-card-link:hover .book-card {
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2);
}
