/* ========================================
   Yemen University - Library Page Styles
   ======================================== */

/* Library Hero */
.library-hero {
    position: relative;
    padding: 120px 0 80px;
    background: linear-gradient(135deg, #0d2550 0%, #1a3a6e 50%, #0d1f45 100%);
    color: white;
    overflow: hidden;
}

.library-hero-bg {
    position: absolute;
    inset: 0;
}

.library-hero-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.3);
}

.library-hero-pattern {
    position: absolute;
    inset: 0;
    background-image: 
        radial-gradient(circle at 10% 20%, rgba(201, 162, 39, 0.08) 0%, transparent 40%),
        radial-gradient(circle at 90% 80%, rgba(122, 74, 30, 0.06) 0%, transparent 50%);
}

.library-hero-content {
    position: relative;
    z-index: 2;
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
}









.library-hero-tag {
    display: inline-block;
    padding: 6px 16px;
    background: rgba(201, 162, 39, 0.15);
    border: 1px solid rgba(201, 162, 39, 0.3);
    border-radius: 100px;
    color: #e8c547;
    font-size: 12px;
    font-weight: 600;
    margin-bottom: 20px;
    backdrop-filter: blur(8px);
}

.library-hero-title {
    font-size: clamp(32px, 5vw, 52px);
    font-weight: 800;
    margin-bottom: 20px;
    line-height: 1.25;
}

.library-hero-desc {
    font-size: clamp(15px, 1.8vw, 18px);
    color: rgba(255, 255, 255, 0.8);
    line-height: 1.7;
    margin-bottom: 36px;
}

/* Search Box */
.library-search-box {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: var(--radius-lg);
    padding: 12px;
    box-shadow: var(--shadow-lg);
}

.lib-search-form {
    display: flex;
    gap: 12px;
    width: 100%;
}

.lib-search-input {
    flex: 1;
    background: white;
    border: 1.5px solid transparent;
    padding: 14px 20px;
    border-radius: var(--radius);
    font-family: inherit;
    font-size: 14px;
    outline: none;
    color: var(--text-primary);
    transition: var(--transition);
}

.lib-search-input:focus {
    border-color: #c9a227;
}

.lib-search-select {
    background: white;
    border: 1.5px solid transparent;
    padding: 14px 20px;
    border-radius: var(--radius);
    font-family: inherit;
    font-size: 14px;
    outline: none;
    cursor: pointer;
    color: var(--text-secondary);
    transition: var(--transition);
}

.btn-search {
    padding: 0 32px;
}

@media (max-width: 768px) {
    .lib-search-form {
        flex-direction: column;
    }
    .lib-search-select, .btn-search {
        width: 100%;
        padding: 14px;
    }
}

/* Stats Section */
.library-stats-section {
    padding: 60px 0;
    background: var(--bg-secondary);
    border-bottom: 1px solid var(--border-light);
}

.lib-stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
}

.lib-stat-card {
    background: white;
    border-radius: var(--radius-lg);
    padding: 24px;
    display: flex;
    align-items: center;
    gap: 20px;
    border: 1px solid var(--border-light);
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
}

.lib-stat-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow);
    border-color: #c9a227;
}

.lib-stat-icon {
    font-size: 32px;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: var(--bg-secondary);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.lib-stat-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.lib-stat-number {
    font-size: 24px;
    font-weight: 800;
    color: #1a3a6e;
    font-family: var(--font-en);
    line-height: 1.1;
}

.lib-stat-label {
    font-size: 13px;
    color: var(--text-secondary);
}

@media (max-width: 1024px) {
    .lib-stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}
@media (max-width: 576px) {
    .lib-stats-grid {
        grid-template-columns: 1fr;
    }
}

/* Books Section */
.library-books-section {
    padding: 80px 0;
    background: white;
}

.books-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 32px;
}

.book-card {
    background: white;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-light);
    overflow: hidden;
    transition: var(--transition);
}

.book-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
    border-color: var(--border);
}

.book-cover {
    height: 240px;
    background: var(--bg);
    position: relative;
    padding: 24px;
    color: white;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    overflow: hidden;
}

.book-cover::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(to right, rgba(0,0,0,0.15) 0%, transparent 8%, transparent 92%, rgba(0,0,0,0.05) 100%);
}

.book-cover-tag {
    align-self: flex-start;
    padding: 4px 10px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 4px;
    font-size: 11px;
    font-weight: 600;
}

.book-title-visual {
    font-size: 20px;
    font-weight: 700;
    line-height: 1.4;
    text-shadow: 0 2px 4px rgba(0,0,0,0.3);
    z-index: 1;
}

.book-author-visual {
    font-size: 12px;
    opacity: 0.85;
    z-index: 1;
}

.book-details {
    padding: 24px;
}

.book-category {
    font-size: 12px;
    font-weight: 600;
    color: #c9a227;
    text-transform: uppercase;
    margin-bottom: 8px;
    display: block;
}

.book-title {
    font-size: 16px;
    font-weight: 700;
    color: var(--text-primary);
    line-height: 1.5;
    margin-bottom: 8px;
}

.book-author {
    font-size: 13px;
    color: var(--text-secondary);
    margin-bottom: 20px;
}

.book-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: 1px solid var(--border-light);
    padding-top: 16px;
}

.book-pages {
    font-size: 12px;
    color: var(--text-muted);
}

@media (max-width: 1024px) {
    .books-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}
@media (max-width: 768px) {
    .books-grid {
        grid-template-columns: 1fr;
    }
}

/* Journals Section */
.library-journals-section {
    padding: 80px 0;
    background: var(--bg-secondary);
}

.journals-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 32px;
}

.journal-card {
    background: white;
    border-radius: var(--radius-lg);
    padding: 32px;
    border: 1px solid var(--border-light);
    position: relative;
    overflow: hidden;
    transition: var(--transition);
}

.journal-card::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    width: 5px;
    background: #1a3a6e;
}

.journal-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
    border-color: #c9a227;
}

.journal-badge {
    display: inline-block;
    padding: 4px 12px;
    background: var(--bg-secondary);
    border-radius: 100px;
    font-size: 12px;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 16px;
    font-family: var(--font-en);
}

.journal-title {
    font-size: 18px;
    font-weight: 700;
    color: var(--text-primary);
    line-height: 1.5;
    margin-bottom: 12px;
}

.journal-desc {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.7;
    margin-bottom: 20px;
}

.journal-meta {
    display: flex;
    gap: 24px;
    margin-bottom: 24px;
    border-bottom: 1px solid var(--border-light);
    padding-bottom: 16px;
}

.meta-item {
    font-size: 13px;
    color: var(--text-secondary);
}

.journal-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    font-weight: 600;
    color: #1a3a6e;
    transition: var(--transition);
}

.journal-link svg {
    transition: var(--transition);
}

.journal-card:hover .journal-link svg {
    transform: translateX(-4px);
}

@media (max-width: 768px) {
    .journals-grid {
        grid-template-columns: 1fr;
    }
}

/* Databases Section */
.library-databases-section {
    padding: 80px 0;
    background: white;
}

.databases-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
}

.db-card {
    background: linear-gradient(135deg, #0d2550 0%, #1a3a6e 100%);
    color: white;
    border-radius: var(--radius-lg);
    padding: 32px 24px;
    text-align: center;
    transition: var(--transition);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.db-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-lg);
    background: linear-gradient(135deg, #102d60 0%, #204580 100%);
}

.db-logo-wrapper {
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    padding-bottom: 16px;
}

.db-logo-text {
    font-size: 24px;
    font-weight: 800;
    font-family: var(--font-en);
    letter-spacing: -0.5px;
    color: #c9a227;
}

.db-name {
    font-size: 16px;
    font-weight: 700;
    margin-bottom: 12px;
}

.db-desc {
    font-size: 13px;
    color: rgba(255,255,255,0.75);
    line-height: 1.6;
    margin-bottom: 24px;
    flex: 1;
}

.db-btn {
    border-color: rgba(255,255,255,0.25);
    width: 100%;
}

.db-btn:hover {
    background: #c9a227;
    border-color: #c9a227;
    color: #1a1a1a;
}

@media (max-width: 1024px) {
    .databases-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}
@media (max-width: 576px) {
    .databases-grid {
        grid-template-columns: 1fr;
    }
}

/* Services Section */
.library-services-section {
    padding: 80px 0;
    background: var(--bg-secondary);
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
}

.service-card {
    background: white;
    border-radius: var(--radius-lg);
    padding: 32px 24px;
    border: 1px solid var(--border-light);
    transition: var(--transition);
}

.service-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
    border-color: #c9a227;
}

.service-icon {
    font-size: 32px;
    margin-bottom: 16px;
}

.service-title {
    font-size: 16px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 12px;
}

.service-desc {
    font-size: 13px;
    color: var(--text-secondary);
    line-height: 1.6;
}

@media (max-width: 1024px) {
    .services-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}
@media (max-width: 576px) {
    .services-grid {
        grid-template-columns: 1fr;
    }
}

/* Working Hours Section */
.library-contact-section {
    padding: 80px 0;
    background: white;
}

.lib-contact-grid {
    display: grid;
    grid-template-columns: 1.5fr 1fr;
    gap: 40px;
}

.lib-hours-card, .lib-info-card {
    background: white;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-light);
    padding: 32px;
    box-shadow: var(--shadow-sm);
}

.card-title {
    font-size: 20px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 24px;
    border-bottom: 2px solid var(--border-light);
    padding-bottom: 12px;
}

.hours-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 20px;
}

.hours-table th, .hours-table td {
    padding: 14px 16px;
    text-align: right;
    border-bottom: 1px solid var(--border-light);
}

.hours-table th {
    font-weight: 700;
    color: var(--text-primary);
    background: var(--bg-secondary);
}

.highlight-closed {
    color: #8b1a1a;
    font-weight: 600;
}

.hours-note {
    font-size: 13px;
    color: var(--text-muted);
}

.card-desc {
    font-size: 14px;
    color: var(--text-secondary);
    margin-bottom: 24px;
    line-height: 1.6;
}

.contact-items {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 14px;
    color: var(--text-secondary);
}

.contact-item .icon {
    font-size: 18px;
}

.contact-item a {
    color: #1a3a6e;
    font-weight: 600;
    transition: var(--transition);
}

.contact-item a:hover {
    color: #c9a227;
}

@media (max-width: 992px) {
    .lib-contact-grid {
        grid-template-columns: 1fr;
    }
}
