@import url("https://fonts.googleapis.com/css2?family=Alexandria:wght@100;200;300;400;500;600;700;800;900&display=swap");

:root {
    --primary-color: #98703d;
    --primary-dark: #71522a;
    --secondary-color: #2c3e50;
    --light-blue: #ecf0f5;
    --text-color: #485b6e;
}

body {
    font-family: "Alexandria", sans-serif;
    background-color: var(--primary-dark);
    color: var(--text-color);
}

h1,
h2,
h3,
h4,
h5,
h6,
.section-title,
.book-title,
.research-title,
.author-name {
    font-family: "Alexandria", sans-serif;
}

.btn {
    font-family: "Alexandria", sans-serif;
}

.nav-link,
.dropdown-item {
    font-family: "Alexandria", sans-serif;
}

p,
span,
a,
input,
textarea,
select {
    font-family: "Alexandria", sans-serif;
}

.hero-section {
    background: linear-gradient(rgba(21, 101, 192, 0.9), rgba(21, 101, 192, 0.9)), url("../assets/img/library-bg.jpg");
    background-size: cover;
    background-position: center;
    padding: 120px 0 80px;
    color: #fff;
    text-align: center;
    position: relative;
}

.hero-content {
    position: relative;
    z-index: 2;
}

.hero-content h1 {
    font-size: 3.5rem;
    font-weight: 600;
    margin-bottom: 25px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.2);
    letter-spacing: -1px;
}

.hero-content p {
    font-size: 1.5rem;
    margin-bottom: 40px;
    opacity: 0.95;
    font-weight: 200;
    letter-spacing: -0.5px;
}

.search-box {
    /* background: rgba(255, 255, 255, 0.15); */
    /* padding: 40px; */
    border-radius: 20px;
    /* backdrop-filter: blur(10px); */
    margin: 0 auto;
    max-width: 800px;
    /* border: 1px solid rgba(255, 255, 255, 0.2); */
}

.search-box .form-control {
    height: 60px;
    border-radius: 30px;
    padding: 0 30px;
    border: 2px solid rgba(255, 255, 255, 0.2);
    background: rgba(255, 255, 255, 0.9);
    font-size: 1.1rem;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    font-weight: 300;
}

.search-box .form-control:focus {
    border-color: #71522a;
    box-shadow: 0 0 0 0.25rem rgba(21, 101, 192, 0.25);
}

.search-box .btn-search {
    height: 60px;
    border-radius: 30px;
    padding: 0 40px;
    background: #98703d;
    border: none;
    color: #fff;
    font-size: 1.1rem;
    transition: all 0.3s ease;
    font-weight: 600;
}

.search-box .btn-search:hover {
    background: #71522a;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.quick-links {
    margin-top: 60px;
    margin-bottom: 60px;
    padding-bottom: 20px;
}

.quick-link-item {
    display: block;
    background: rgba(0, 0, 0, 0.15);
    padding: 35px 25px;
    border-radius: 20px;
    text-align: center;
    color: #fff;
    transition: all 0.3s ease;
    text-decoration: none;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.quick-link-item:hover {
    background: rgba(0, 0, 0, 0.25);
    transform: translateY(-5px);
    color: #fff;
    border-color: rgba(255, 255, 255, 0.4);
}

.quick-link-item i {
    font-size: 2.5rem;
    margin-bottom: 15px;
    color: var(--primary-color);
}

.quick-link-item h4 {
    font-size: 1.3rem;
    margin: 15px 0 10px;
    font-weight: 700;
    letter-spacing: -0.5px;
}

.quick-link-item p {
    margin: 0;
    opacity: 0.9;
    font-size: 1rem;
    line-height: 1.5;
    font-weight: 300;
}

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

.section-title {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--secondary-color);
    margin: 0;
    position: relative;
    padding-right: 15px;
    letter-spacing: -0.5px;
}

.section-title::before {
    content: "";
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 4px;
    height: 25px;
    background: #71522a;
    border-radius: 2px;
}

.content-card {
    background: #fff;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 3px 15px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    margin-bottom: 30px;
    height: 100%;
}

.content-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.15);
    border-color: #71522a;
}

.card-img {
    height: 200px;
    overflow: hidden;
}

.card-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: all 0.3s ease;
}

.content-card:hover .card-img img {
    transform: scale(1.1);
}

.card-body {
    padding: 20px;
}

.card-title {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 15px;
    color: var(--secondary-color);
    letter-spacing: -0.3px;
}

.card-meta {
    display: flex;
    justify-content: space-between;
    color: #666;
    font-size: 0.9rem;
    margin-bottom: 15px;
    font-weight: 400;
}

.ad-banner {
    margin: 40px 0;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 3px 15px rgba(0, 0, 0, 0.1);
}

.ad-banner img {
    width: 100%;
    height: auto;
}

.latest-books {
    padding: 80px 0;
    background-color: #fff;
}

.book-card {
    background: #fff;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 3px 15px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.book-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.book-cover {
    position: relative;
    padding-top: 140%;
    overflow: hidden;
    flex-shrink: 0;
}

.book-cover img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: all 0.3s ease;
}

.book-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(21, 101, 192, 0.9);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: all 0.3s ease;
}

.book-card:hover .book-overlay {
    opacity: 1;
}

.book-card:hover .book-cover img {
    transform: scale(1.1);
}

.book-info {
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.book-title {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 5px;
    color: var(--secondary-color);
    line-height: 1.4;
}

.book-author {
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 5px;
}

.book-author::before {
    content: "تأليف:";
    font-size: 0.85rem;
    color: #666;
}

.book-author a {
    color: var(--primary-color);
    font-weight: 500;
    font-size: 0.95rem;
    text-decoration: none;
    transition: color 0.3s ease;
    display: inline-block;
}

.book-author a:hover {
    color: var(--primary-dark);
    transform: translateX(-3px);
}

.book-rating {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.stars {
    display: flex;
    align-items: center;
    gap: 2px;
    color: #ffc107;
}

.stars i {
    font-size: 0.9rem;
}

.rating-count {
    color: #666;
    font-size: 0.85rem;
    margin-right: 5px;
}

.year {
    background: rgba(21, 101, 192, 0.1);
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.85rem;
    color: var(--primary-color);
    font-weight: 500;
}

.section-header .btn-outline-primary {
    font-weight: 500;
    padding: 8px 25px;
    border-width: 2px;
}

.book-overlay .btn-light {
    font-weight: 500;
    padding: 8px 25px;
    transition: all 0.3s ease;
    background: rgba(255, 255, 255, 0.95);
}

.book-overlay .btn-light:hover {
    background: #fff;
    transform: scale(1.05);
}

.navbar {
    /* background: linear-gradient(to right, rgba(152, 110, 62, 0.98), rgba(80, 52, 13, 0.95)); */

    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    padding: 15px 0;
    /* box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1); */
}

.navbar-brand {
    font-size: 1.6rem;
    font-weight: 700;
    color: #fff;
    letter-spacing: -0.5px;
}

.navbar-brand:hover {
    color: rgba(255, 255, 255, 0.95);
}

.nav-item {
    margin: 0 5px;
}

.nav-link {
    color: rgba(255, 255, 255, 0.9) !important;
    font-weight: 500;
    padding: 10px 20px !important;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.nav-link:hover {
    color: #fff !important;
    background: rgba(255, 255, 255, 0.1);
}

.nav-link.active {
    color: #fff !important;
    background: rgba(255, 255, 255, 0.15);
}

.nav-link.btn-login {
    border: 1px solid rgba(255, 255, 255, 0.3);
    padding: 8px 20px !important;
    margin-right: 10px;
}

.nav-link.btn-login:hover {
    background: rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 255, 255, 0.4);
}

.dropdown-menu {
    background: #fff;
    border: none;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    padding: 8px;
    margin-top: 10px;
}

.dropdown-item {
    padding: 10px 20px;
    border-radius: 8px;
    color: var(--text-color);
    transition: all 0.3s ease;
    font-weight: 500;
}

.dropdown-item:hover {
    background: rgba(21, 101, 192, 0.1);
    color: #71522a;
}

.navbar-toggler {
    border: none;
    padding: 0;
}

.navbar-toggler:focus {
    box-shadow: none;
}

.navbar-toggler-icon {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba(255, 255, 255, 0.9)' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
}

.btn-primary {
    background-color: #71522a;
    border-color: #71522a;
}

.btn-primary:hover {
    background-color: #0d47a1;
    border-color: #0d47a1;
}

.btn-outline-primary {
    color: #71522a;
    border-color: #71522a;
}

.btn-outline-primary:hover {
    background-color: #71522a;
    border-color: #71522a;
    color: #fff;
}

a {
    color: #71522a;
}

a:hover {
    color: #0d47a1;
}

.nav-link.active {
    background: rgba(255, 255, 255, 0.15);
}

.form-control:focus {
    border-color: #71522a;
    box-shadow: 0 0 0 0.25rem rgba(21, 101, 192, 0.25);
}

.footer a:hover {
    color: #71522a;
}

.research-card {
    background: #fff;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 3px 15px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    height: 100%;
    padding: 25px;
}

.research-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.research-title {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 15px;
    color: var(--secondary-color);
    line-height: 1.4;
}

.research-abstract {
    color: #666;
    font-size: 0.95rem;
    line-height: 1.6;
    margin-bottom: 20px;
}

.research-author {
    margin-bottom: 20px;
    position: relative;
    padding-right: 45px;
}

.research-author::before {
    content: "الباحث:";
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    font-size: 0.85rem;
    color: #666;
    font-weight: 400;
}

.research-author a {
    color: var(--primary-color);
    font-weight: 500;
    font-size: 0.95rem;
    text-decoration: none;
    transition: all 0.3s ease;
}

.research-author a:hover {
    color: var(--primary-dark);
    padding-right: 5px;
}

.research-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: auto;
    padding-top: 20px;
    border-top: 1px solid rgba(0, 0, 0, 0.1);
}

.research-info {
    display: flex;
    align-items: center;
    gap: 15px;
}

.research-info .stars {
    display: flex;
    align-items: center;
    gap: 2px;
    color: #ffc107;
}

.research-info .stars i {
    font-size: 0.9rem;
}

.research-info .rating-count {
    color: #666;
    font-size: 0.85rem;
    margin-right: 5px;
}

.research-info .year {
    background: rgba(21, 101, 192, 0.1);
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.85rem;
    color: var(--primary-color);
    font-weight: 500;
}

.research-meta .btn {
    font-size: 0.9rem;
    padding: 8px 20px;
}

.latest-researches {
    background-color: var(--light-blue);
}

.authors-section {
    background-color: #fff;
}

.author-card {
    background: #fff;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 3px 15px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 25px;
    text-align: center;
}

.author-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.author-image {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    overflow: hidden;
    margin-bottom: 20px;
    border: 3px solid var(--primary-color);
    padding: 3px;
}

.author-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
    transition: all 0.3s ease;
}

.author-card:hover .author-image img {
    transform: scale(1.1);
}

.author-info {
    flex: 1;
    width: 100%;
}

.author-name {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 15px;
}

.author-name a {
    color: var(--secondary-color);
    text-decoration: none;
    transition: color 0.3s ease;
}

.author-name a:hover {
    color: var(--primary-color);
}

.author-stats {
    display: flex;
    justify-content: right;
    gap: 20px;
    margin-top: 15px;
}

.stat-item {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #666;
    font-size: 0.95rem;
}

.stat-item i {
    color: var(--primary-color);
    font-size: 1.1rem;
}

.ad-banner {
    margin: 20px 0;
    text-align: center;
    overflow: hidden;
    border-radius: 8px;
}

.ad-banner.header {
    width: 100%;
    max-height: 200px;
}

.ad-banner.sidebar {
    width: 100%;
    margin-bottom: 20px;
}

.ad-banner.footer {
    width: 100%;
    max-height: 200px;
}

.ad-banner img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    transition: transform 0.3s ease;
}

.ad-banner img:hover {
    transform: scale(1.02);
}

.sidebar-ads {
    position: sticky;
    top: 20px;
}

/* */

body {
    font-family: "Cairo", sans-serif;
    background-color: #f8f9fa;
}

.navbar {
    background-color: #485b6e;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.navbar-brand {
    color: #fff;
    font-weight: 600;
}

.nav-link {
    color: rgba(255, 255, 255, 0.9);
}

.nav-link:hover {
    color: #fff;
}

.search-form {
    position: relative;
}

.search-input {
    padding-right: 40px;
    border-radius: 20px;
}

.search-btn {
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: #6c757d;
}

.footer {
    background-color: #f8f9fa;
    padding: 60px 0 30px;
    margin-top: 80px;
    border-top: 1px solid #eee;
    position: relative;
}

.footer-section {
    margin-bottom: 30px;
}

.footer-title {
    color: #2d3436;
    font-family: "Alexandria", sans-serif;
    font-weight: 600;
    font-size: 1.2rem;
    margin-bottom: 20px;
    position: relative;
}

.footer-text {
    color: #636e72;
    line-height: 1.8;
    font-size: 0.95rem;
    font-family: "Alexandria", sans-serif;
}

.footer-links {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-links li {
    margin-bottom: 12px;
}

.footer-links a {
    color: #636e72;
    text-decoration: none;
    transition: color 0.3s ease;
    font-size: 0.95rem;
}

.footer-links a:hover {
    color: #71522a;
}

.footer-contact {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-contact li {
    display: flex;
    align-items: center;
    margin-bottom: 15px;
    color: #636e72;
    font-size: 0.95rem;
}

.footer-contact i {
    width: 25px;
    color: #71522a;
    margin-left: 10px;
}

.footer-bottom {
    margin-top: 40px;
    padding-top: 20px;
    border-top: 1px solid #eee;
    text-align: center;
}

.copyright {
    color: #636e72;
    font-size: 0.9rem;
    font-family: "Alexandria", sans-serif;
}

.book-icon {
    position: fixed;
    bottom: 30px;
    left: 30px;
    width: 50px;
    height: 50px;
    background: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 0 15px rgba(0, 0, 0, 0.1);
    opacity: 0;
    transition: all 0.3s ease;
    cursor: pointer;
    z-index: 999;
}

.book-icon i {
    font-size: 24px;
    color: #71522a;
    transition: all 0.3s ease;
}

.book-icon:hover {
    background: #71522a;
    transform: translateY(-5px);
    box-shadow: 0 0 20px rgba(9, 132, 227, 0.3);
}

.book-icon:hover i {
    color: #fff;
}

.center-book-icon {
    position: absolute;
    top: -25px;
    left: 50%;
    transform: translateX(-50%);
    width: 50px;
    height: 50px;
    background: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 0 15px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.center-book-icon i {
    font-size: 24px;
    color: #71522a;
    transition: all 0.3s ease;
}

.center-book-icon:hover {
    background: #71522a;
    transform: translateX(-50%) rotate(360deg);
    box-shadow: 0 0 20px rgba(9, 132, 227, 0.3);
}

.center-book-icon:hover i {
    color: #fff;
}

@media (max-width: 768px) {
    .footer {
        padding: 40px 0 20px;
        margin-top: 60px;
    }

    .footer-section {
        text-align: center;
    }

    .footer-contact li {
        justify-content: center;
    }

    .book-icon {
        width: 40px;
        height: 40px;
        bottom: 20px;
        left: 20px;
    }

    .book-icon i {
        font-size: 20px;
    }

    .center-book-icon {
        width: 40px;
        height: 40px;
        top: -20px;
    }

    .center-book-icon i {
        font-size: 20px;
    }
}
