/* Modern Design System for Library */
@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700&display=swap');

:root {
    --primary-color: #0f172a;
    --secondary-color: #1B9E98;
    /* Keeping the teal theme */
    --accent-color: #900C3F;
    /* Keeping the maroon theme */
    --text-color: #334155;
    --light-bg: #f8fafc;
    --white: #ffffff;
    --glass-bg: rgba(255, 255, 255, 0.9);
    --glass-border: rgba(255, 255, 255, 0.3);
    --shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.05);
    --shadow-lg: 0 20px 40px -10px rgba(0, 0, 0, 0.1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Outfit', sans-serif;
    color: var(--text-color);
    background-color: var(--light-bg);
    line-height: 1.6;
}

.container-fluid {
    padding: 0;
}

/* Layout */
.main-wrapper {
    display: flex;
    min-height: 100vh;
}

/* Sidebar Styling */
.sidebar {
    width: 280px;
    background: var(--white);
    border-right: 1px solid #e2e8f0;
    padding: 2rem 1.5rem;
    position: sticky;
    top: 0;
    height: 100vh;
    overflow-y: auto;
    z-index: 1000;
    transition: all 0.3s ease;
}

/* Mobile Toggle - Hidden by default */
.mobile-toggle {
    display: none;
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 2000;
    background: var(--secondary-color);
    color: white;
    width: 50px;
    height: 50px;
    border-radius: 12px;
    align-items: center;
    justify-content: center;
    border: none;
    cursor: pointer;
    box-shadow: var(--shadow-lg);
}

.sidebar-logo {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 2.5rem;
    padding: 0 0.5rem;
}

.sidebar-logo img {
    width: 45px;
    height: 45px;
    border-radius: 50%;
}

.sidebar-logo h2 {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--primary-color);
    letter-spacing: -0.5px;
}

.vertical-menu ul {
    list-style: none;
}

.vertical-menu li {
    margin-bottom: 0.5rem;
}

.vertical-menu .btn {
    display: block;
    width: 100%;
    padding: 0.85rem 1.25rem;
    border-radius: 12px;
    text-decoration: none;
    color: var(--text-color);
    font-weight: 500;
    font-size: 0.95rem;
    transition: all 0.3s ease;
    text-align: left;
    background: transparent;
    border: none;
}

.vertical-menu .btn:hover,
.vertical-menu .btn.active {
    background: rgba(27, 158, 152, 0.1);
    color: var(--secondary-color);
    transform: translateX(5px);
}

.vertical-menu .btn.active {
    background: var(--secondary-color);
    color: white;
    box-shadow: 0 10px 15px -3px rgba(27, 158, 152, 0.25);
}

/* Main Content Area */
.content-area {
    flex: 1;
    padding: 2rem 3.5rem;
}

/* Page Header */
.page-header {
    margin-bottom: 3rem;
    text-align: center;
}

.page-header h1 {
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Banner Section */
.hero-banner {
    height: 350px;
    border-radius: 32px;
    overflow: hidden;
    position: relative;
    margin-bottom: 3rem;
    box-shadow: var(--shadow-lg);
}

.hero-banner img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(rgba(15, 23, 42, 0.4), rgba(15, 23, 42, 0.6));
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 3rem;
    color: white;
}

.hero-overlay h2 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

.hero-overlay p {
    font-size: 1.1rem;
    max-width: 600px;
    opacity: 0.9;
}

/* Section Cards */
.info-section {
    margin-bottom: 4rem;
}

.section-label {
    display: inline-block;
    padding: 0.5rem 1.25rem;
    background: rgba(27, 158, 152, 0.1);
    color: var(--secondary-color);
    border-radius: 50px;
    font-weight: 600;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 1.5rem;
}

.card {
    background: var(--white);
    border-radius: 24px;
    padding: 2.5rem;
    box-shadow: var(--shadow);
    border: 1px solid #f1f5f9;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.grid-2 {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 2rem;
}

@media (max-width: 1100px) {
    .grid-2 {
        grid-template-columns: 1fr;
    }
}

/* Librarian Card */
.librarian-card {
    text-align: center;
}

.librarian-img {
    width: 150px;
    height: 200px;
    object-fit: cover;
    border-radius: 20px;
    margin-bottom: 1.5rem;
    box-shadow: var(--shadow);
}

.librarian-name {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 0.25rem;
}

.librarian-title {
    color: var(--secondary-color);
    font-weight: 600;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Stats Section */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    margin-top: 2rem;
}

.stat-card {
    background: var(--white);
    padding: 2rem;
    border-radius: 20px;
    text-align: center;
    border: 1px solid #f1f5f9;
}

.stat-card h3 {
    font-size: 2rem;
    color: var(--secondary-color);
    margin-bottom: 0.5rem;
}

.stat-card p {
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: #64748b;
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-fade {
    animation: fadeIn 0.6s ease-out forwards;
}

/* Responsive Design Queries */
@media (max-width: 1024px) {
    .content-area {
        padding: 2rem;
    }

    .hero-banner {
        height: 300px;
    }
}

@media (max-width: 768px) {
    .main-wrapper {
        flex-direction: column;
    }

    .sidebar {
        position: fixed;
        left: -280px;
        top: 0;
        width: 280px;
        height: 100vh;
        box-shadow: 20px 0 50px rgba(0, 0, 0, 0.1);
    }

    .sidebar.active {
        left: 0;
    }

    .mobile-toggle {
        display: flex;
    }

    .content-area {
        padding: 4rem 1.5rem 2rem;
        width: 100%;
    }

    .page-header h1 {
        font-size: 2rem;
    }

    .hero-banner {
        height: 250px;
        border-radius: 20px;
    }

    .hero-overlay {
        padding: 1.5rem;
    }

    .hero-overlay h2 {
        font-size: 1.75rem;
    }

    .hero-overlay p {
        font-size: 0.95rem;
    }

    .card {
        padding: 1.5rem;
        border-radius: 20px;
    }

    .page-header {
        margin-bottom: 2rem;
    }

    .info-section {
        margin-bottom: 2.5rem;
    }

    /* Grid adjustments for mobile */
    .grid-2,
    .stats-grid {
        gap: 1.25rem;
    }

    .stat-card {
        padding: 1.5rem 1rem;
    }

    .stat-card h3 {
        font-size: 1.5rem;
    }

    /* Overlay background when sidebar is active on mobile */
    .sidebar-overlay {
        display: none;
        position: fixed;
        inset: 0;
        background: rgba(0, 0, 0, 0.4);
        backdrop-filter: blur(4px);
        z-index: 900;
    }

    .sidebar-overlay.active {
        display: block;
    }
}

@media (max-width: 480px) {
    .page-header h1 {
        font-size: 1.75rem;
    }

    .hero-banner {
        height: 200px;
    }
}