/* e-SCRA LMS Dashboard Styles */
@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@400;500;600;700;900&display=swap');

:root {
    --escra-red: #c51b22;
    --escra-dark: #1e1e1e;
    --escra-bg: #f4f7f6;
    --escra-text: #333333;
    --escra-gray: #6c757d;
    --card-bg: rgba(255, 255, 255, 0.85);
    --card-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    --border-radius: 12px;
}

.escra-dashboard-container {
    display: flex;
    height: 100vh;
    overflow: hidden;
    background-color: var(--escra-bg);
    font-family: 'Outfit', sans-serif !important;
    color: var(--escra-text);
    margin: -15px; /* offset default elementor padding if necessary */
}

.escra-dashboard-container,
.escra-dashboard-container h1,
.escra-dashboard-container h2,
.escra-dashboard-container h3,
.escra-dashboard-container a,
.escra-dashboard-container span,
.escra-dashboard-container div,
.escra-dashboard-container input,
.escra-dashboard-container button {
    font-family: 'Outfit', sans-serif !important;
}

/* Sidebar */
.escra-sidebar {
    width: 320px;
    background-color: var(--escra-dark);
    color: #ffffff;
    display: flex;
    flex-direction: column;
    padding: 30px 20px;
    box-shadow: 2px 0 15px rgba(0,0,0,0.1);
    flex-shrink: 0;
    overflow-y: auto;
}

.escra-sidebar::-webkit-scrollbar {
    width: 0px;
    background: transparent;
}

.escra-logo-container {
    text-align: center;
    margin-bottom: 40px;
}

.escra-logo-text {
    font-size: 54px;
    font-weight: 900;
    letter-spacing: -1px;
    display: flex;
    align-items: baseline;
    justify-content: center;
    line-height: 1;
    margin-bottom: 12px;
}

.escra-logo-text .e {
    color: var(--escra-red);
}

.escra-logo-text .scra {
    color: #ffffff; /* white in sidebar, black on white bg usually, but we are in dark sidebar */
}

.escra-logo-sub {
    background-color: #000000;
    color: #ffffff;
    font-size: 9.5px;
    padding: 6px 14px;
    border-radius: 20px;
    display: block;
    text-align: center;
    white-space: nowrap;
    letter-spacing: 0.5px;
    line-height: 1.4;
    margin: 0 auto;
    max-width: 100%;
    box-sizing: border-box;
}

.escra-nav-list {
    list-style: none;
    padding: 0;
    margin: 0;
    flex-grow: 1;
}

.escra-nav-item {
    margin-bottom: 10px;
}

.escra-nav-link {
    display: flex;
    align-items: center;
    padding: 12px 20px;
    color: #a0a0a0;
    text-decoration: none;
    border-radius: 50px !important;
    transition: all 0.3s ease;
    font-weight: 500;
    font-size: 15px;
}

.escra-nav-link i {
    margin-right: 15px;
    font-size: 18px;
    width: 20px;
    text-align: center;
}

.escra-nav-link:hover, .escra-nav-link.active {
    background-color: var(--escra-red);
    color: #ffffff;
}

.escra-user-profile {
    display: flex;
    align-items: center;
    padding-top: 20px;
    border-top: 1px solid rgba(255,255,255,0.1);
}

.escra-user-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: var(--escra-red);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    margin-right: 12px;
}

.escra-user-info {
    display: flex;
    flex-direction: column;
}

.escra-user-name {
    font-size: 14px;
    font-weight: 600;
    color: #ffffff;
}

.escra-user-email {
    font-size: 12px;
    color: #a0a0a0;
}

/* Main Content Area */
.escra-main-content {
    flex: 1;
    padding: 40px;
    overflow-y: auto;
}

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

.escra-welcome h1 {
    font-size: 26px;
    font-weight: 700;
    margin: 0;
    color: var(--escra-text);
    display: flex;
    align-items: center;
}

.escra-welcome h1 span {
    color: var(--escra-red);
}

.escra-date {
    font-size: 18px;
    color: var(--escra-gray);
    margin-left: 15px;
    font-weight: 400;
    border-left: 2px solid #e0e0e0;
    padding-left: 15px;
}

/* Search Bar */
.escra-search-bar {
    display: flex;
    background: #ffffff;
    border-radius: 12px;
    padding: 10px 15px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.03);
    margin-bottom: 40px;
    align-items: center;
}

.escra-search-bar input {
    flex: 1;
    border: none;
    outline: none;
    font-size: 16px;
    padding: 10px;
    background: transparent;
}

.escra-search-btn {
    background-color: var(--escra-red);
    color: white;
    border: none;
    border-radius: 8px;
    padding: 12px 20px;
    cursor: pointer;
    font-weight: 600;
    transition: background 0.3s;
    white-space: nowrap;
}

.escra-search-btn:hover {
    background-color: #a00000;
}

/* Section Titles */
.escra-section-title {
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 20px;
    color: var(--escra-text);
}

/* Cards Grid */
.escra-cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
    margin-bottom: 40px;
}

.escra-card {
    background: var(--card-bg);
    border-radius: var(--border-radius);
    padding: 25px;
    box-shadow: var(--card-shadow);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255,255,255,0.4);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    position: relative;
    overflow: hidden;
}

.escra-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.08);
}

.escra-card::after {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 80px;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(197, 27, 34, 0.05));
    pointer-events: none;
}

.escra-card-tag {
    font-size: 12px;
    color: var(--escra-gray);
    margin-bottom: 8px;
    display: block;
}

.escra-card-title {
    font-size: 16px;
    font-weight: 700;
    margin: 0 0 5px 0;
    color: var(--escra-text);
}

.escra-card-subtitle {
    font-size: 14px;
    color: var(--escra-gray);
    margin-bottom: 20px;
}

.escra-card-meta {
    font-size: 13px;
    color: #999;
    margin-bottom: 10px;
}

.escra-card-footer {
    display: flex;
    justify-content: space-between;
    font-size: 13px;
    color: var(--escra-gray);
    font-weight: 500;
    border-top: 1px solid rgba(0,0,0,0.05);
    padding-top: 15px;
}

/* Responsive */
@media (max-width: 768px) {
    .escra-dashboard-container {
        flex-direction: column;
    }
    .escra-sidebar {
        width: 100%;
        padding: 20px;
    }
    .escra-main-content {
        padding: 20px;
    }
    .escra-header {
        flex-direction: column;
        align-items: flex-start;
    }
    .escra-welcome h1 {
        margin-bottom: 10px;
    }
    .escra-date {
        margin-left: 0;
    }
}

/* Library Grid */
.escra-library-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 30px;
    margin-top: 30px;
}


/* Pagination */
.escra-pagination-container {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: 40px;
    margin-bottom: 20px;
}

.escra-main-content button.escra-page-btn {
    padding: 8px 16px;
    border: 1px solid #e0e0e0 !important;
    background: #ffffff !important;
    color: #555555 !important;
    border-radius: 6px !important;
    cursor: pointer;
    font-family: inherit;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.2s ease;
    box-shadow: none !important;
}

.escra-main-content button.escra-page-btn:hover {
    background: #f8f9fa !important;
    border-color: #cccccc !important;
    color: #333333 !important;
}

.escra-main-content button.escra-page-btn.active {
    background: #f0f0f0 !important;
    color: var(--escra-dark) !important;
    border-color: #bbbbbb !important;
}

.escra-page-dots {
    padding: 8px;
    color: #999;
}

/* Enhanced Realistic Books */
.escra-book-card {
    background: #fff;
    border-radius: 4px 12px 12px 4px;
    box-shadow: inset -5px 0 10px rgba(0,0,0,0.05), 5px 5px 15px rgba(0,0,0,0.1);
    display: flex;
    height: 240px;
    cursor: pointer;
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275), box-shadow 0.3s ease;
    position: relative;
    overflow: hidden;
}

.escra-book-card::after {
    content: '';
    position: absolute;
    top: 0; bottom: 0; left: 30px; right: 0;
    box-shadow: inset 2px 0 5px rgba(255,255,255,0.7), inset -1px 0 2px rgba(0,0,0,0.1);
    border-radius: 0 12px 12px 0;
    pointer-events: none;
}

.escra-book-card:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: inset -5px 0 10px rgba(0,0,0,0.05), 10px 20px 30px rgba(0,0,0,0.15);
}

.escra-book-spine {
    width: 30px;
    background: linear-gradient(90deg, #111, #3a3a3a, #111);
    border-right: 2px solid rgba(0,0,0,0.4);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    align-items: center;
    padding: 15px 0;
    position: relative;
    box-shadow: inset -2px 0 4px rgba(0,0,0,0.5);
    border-radius: 3px 0 0 3px;
    z-index: 2;
}

.escra-spine-title {
    color: #d4af37;
    writing-mode: vertical-rl;
    text-orientation: mixed;
    transform: rotate(180deg);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 2px;
    opacity: 0.9;
}

.escra-spine-lines {
    width: 20px;
    height: 3px;
    background: linear-gradient(90deg, #b8860b, #ffd700, #b8860b);
    border-radius: 1px;
    box-shadow: 0 1px 2px rgba(0,0,0,0.5);
}

.escra-book-cover {
    flex: 1;
    padding: 20px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    background: #5c3a21;
    background-image: url('data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSI0IiBoZWlnaHQ9IjQiPjxyZWN0IHdpZHRoPSI0IiBoZWlnaHQ9IjQiIGZpbGw9IiM1YzNhMjEiPjwvcmVjdD48cmVjdCB3aWR0aD0iMSIgaGVpZ2h0PSIxIiBmaWxsPSJyZ2JhKDAsMCwwLDAuMDUpIj48L3JlY3Q+PC9zdmc+');
    position: relative;
    z-index: 1;
}

.escra-book-texture {
    position: absolute;
    top: 10px; bottom: 10px; left: 10px; right: 10px;
    border: 1px solid rgba(212, 175, 55, 0.4);
    border-radius: 4px;
    pointer-events: none;
}

.escra-book-cover h3 {
    font-size: 22px;
    font-weight: 900;
    color: #fff;
    margin: 0 0 10px 0;
    text-shadow: 1px 1px 3px rgba(0,0,0,0.4);
}

.escra-book-cover p {
    font-size: 14px;
    color: #d4af37;
    font-weight: 700;
    margin: 0;
    letter-spacing: 3px;
    text-transform: uppercase;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.5);
}
