/* v1.0.6: Complete Dashboard UI Overhaul (Responsive, Animated, Refined) */

/* Base font injection */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap');

body.csb-tutor-dashboard-styler {
    background: var(--csb-page-bg) !important;
    color: var(--csb-text);
}

/* Typography Overhaul */
html body.csb-tutor-dashboard-styler .tutor-dashboard-content,
html body.csb-tutor-dashboard-styler .edumall-tutor-dashboard {
    font-family: 'Inter', sans-serif;
}
html body.csb-tutor-dashboard-styler .tutor-dashboard-content,
html body.csb-tutor-dashboard-styler .tutor-dashboard-content *,
html body.csb-tutor-dashboard-styler .edumall-tutor-dashboard,
html body.csb-tutor-dashboard-styler .edumall-tutor-dashboard * {
    color: var(--csb-text, #111827) !important;
    -webkit-text-fill-color: var(--csb-text, #111827);
    text-shadow: none;
    cursor: auto;
}

/* Specific text elements for font-family to avoid overriding icon fonts */
html body.csb-tutor-dashboard-styler .tutor-dashboard-content h1,
html body.csb-tutor-dashboard-styler .tutor-dashboard-content h2,
html body.csb-tutor-dashboard-styler .tutor-dashboard-content h3,
html body.csb-tutor-dashboard-styler .tutor-dashboard-content h4,
html body.csb-tutor-dashboard-styler .tutor-dashboard-content h5,
html body.csb-tutor-dashboard-styler .tutor-dashboard-content h6,
html body.csb-tutor-dashboard-styler .tutor-dashboard-content p,
html body.csb-tutor-dashboard-styler .tutor-dashboard-content label,
html body.csb-tutor-dashboard-styler .tutor-dashboard-content strong,
html body.csb-tutor-dashboard-styler .tutor-dashboard-content a {
    font-family: 'Inter', sans-serif !important;
}

/* Heading Sizes Reduction */
html body.csb-tutor-dashboard-styler .tutor-dashboard-content h1 { font-size: 26px !important; font-weight: 700 !important; margin-bottom: 20px !important; }
html body.csb-tutor-dashboard-styler .tutor-dashboard-content h2 { font-size: 22px !important; font-weight: 600 !important; margin-bottom: 16px !important; }
html body.csb-tutor-dashboard-styler .tutor-dashboard-content h3 { font-size: 18px !important; font-weight: 600 !important; margin-bottom: 12px !important; }
html body.csb-tutor-dashboard-styler .tutor-dashboard-content h4 { font-size: 16px !important; font-weight: 600 !important; margin-bottom: 10px !important; }

/* Links and basic transitions */
html body.csb-tutor-dashboard-styler .tutor-dashboard-content a,
html body.csb-tutor-dashboard-styler .tutor-dashboard-content button {
    transition: all 0.3s ease !important;
}
html body.csb-tutor-dashboard-styler .tutor-dashboard-content a {
    color: var(--csb-primary) !important;
    cursor: pointer !important;
}
html body.csb-tutor-dashboard-styler .tutor-dashboard-content a:hover {
    color: var(--csb-primary-dark) !important;
}

/* Animations (Fade Up) */
@keyframes csbFadeInUp {
    0% { opacity: 0; transform: translateY(15px); }
    100% { opacity: 1; transform: translateY(0); }
}

html body.csb-tutor-dashboard-styler .tutor-dashboard-content-inner,
html body.csb-tutor-dashboard-styler .edumall-tutor-dashboard-inner {
    animation: csbFadeInUp 0.4s ease-out forwards !important;
}

/* Header Button Layout (Add A New Course) */
body.csb-tutor-dashboard-styler .tutor-dashboard-header {
    display: flex !important;
    flex-wrap: wrap !important;
    align-items: center !important;
    justify-content: space-between !important;
    width: 100% !important;
    margin-bottom: 30px !important;
}
body.csb-tutor-dashboard-styler .tutor-dashboard-header-button {
    margin-left: auto !important;
}

/* Buttons Styling */
body.csb-tutor-dashboard-styler .tutor-dashboard-header-button a,
body.csb-tutor-dashboard-styler .tutor-dashboard-create-course {
    background: var(--csb-primary) !important;
    border-color: var(--csb-primary) !important;
    color: #fff !important;
    -webkit-text-fill-color: #fff !important;
    padding: 10px 20px !important;
    border-radius: 6px !important;
    font-weight: 600 !important;
    display: inline-block !important;
}
body.csb-tutor-dashboard-styler .tutor-dashboard-header-button a:hover,
body.csb-tutor-dashboard-styler .tutor-dashboard-create-course:hover {
    background: var(--csb-primary-dark) !important;
    border-color: var(--csb-primary-dark) !important;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

/* Sidebar */
body.csb-tutor-dashboard-styler #tutor-dashboard-left-menu,
body.csb-tutor-dashboard-styler .tutor-dashboard-left-menu,
body.csb-tutor-dashboard-styler .tutor-dashboard-sidebar {
    background: var(--csb-surface) !important;
}
body.csb-tutor-dashboard-styler .tutor-dashboard-permalinks li a,
body.csb-tutor-dashboard-styler .tutor-dashboard-menu li a,
body.csb-tutor-dashboard-styler .tutor-dashboard-nav li a {
    color: var(--csb-muted) !important;
    transition: .2s ease;
}
body.csb-tutor-dashboard-styler .tutor-dashboard-permalinks li.active a,
body.csb-tutor-dashboard-styler .tutor-dashboard-permalinks li a:hover,
body.csb-tutor-dashboard-styler .tutor-dashboard-menu li.active a,
body.csb-tutor-dashboard-styler .tutor-dashboard-menu li a:hover,
body.csb-tutor-dashboard-styler .tutor-dashboard-nav li.active a,
body.csb-tutor-dashboard-styler .tutor-dashboard-nav li a:hover {
    color: var(--csb-primary) !important;
    background: var(--csb-accent) !important;
}

/* Dashboard Cards */
body.csb-tutor-dashboard-styler .dashboard-info-card-box {
    background: var(--csb-surface) !important;
    border: 1px solid var(--csb-border) !important;
    border-radius: var(--csb-radius) !important;
    box-shadow: 0 3px 12px rgba(15,23,42,.045) !important;
    transition: .2s ease !important;
    text-decoration: none !important;
}
body.csb-tutor-dashboard-styler .dashboard-info-card-box:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 30px rgba(15,23,42,.08) !important;
}
body.csb-tutor-dashboard-styler .dashboard-info-card-icon {
    border-radius: 10px !important;
}
html body.csb-tutor-dashboard-styler div.tutor-dashboard-content .dashboard-info-card-heading {
    color: var(--csb-muted) !important;
}

/* Theme Header Recovery */
body.csb-tutor-dashboard-styler .ekit-template-content-header,
body.csb-tutor-dashboard-styler header.site-header,
body.csb-tutor-dashboard-styler #masthead,
body.csb-tutor-dashboard-styler header,
body.csb-tutor-dashboard-styler .elementor-location-header {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    position: relative !important;
    z-index: 999 !important;
    width: 100% !important;
}

/* Theme Footer Breakout (Full Width Bottom) */
body.csb-tutor-dashboard-styler .ekit-template-content-footer,
body.csb-tutor-dashboard-styler footer,
body.csb-tutor-dashboard-styler .site-footer {
    display: block !important;
    clear: both !important;
    width: 100vw !important;
    max-width: 100vw !important;
    margin-left: calc(-50vw + 50%) !important;
    margin-right: calc(-50vw + 50%) !important;
    margin-top: 50px !important;
    position: relative !important;
    left: 0 !important;
    z-index: 99 !important;
    box-sizing: border-box !important;
}

/* Visibility Force Repairs */
html body.csb-tutor-dashboard-styler .page-content,
html body.csb-tutor-dashboard-styler .tutor-dashboard,
html body.csb-tutor-dashboard-styler .tutor-dashboard-content,
html body.csb-tutor-dashboard-styler .tutor-dashboard-content-inner,
html body.csb-tutor-dashboard-styler .edumall-tutor-dashboard,
html body.csb-tutor-dashboard-styler .page-main-content {
    visibility: visible !important;
    opacity: 1 !important;
}
html body.csb-tutor-dashboard-styler .tutor-dashboard-content,
html body.csb-tutor-dashboard-styler .tutor-dashboard-content-inner,
html body.csb-tutor-dashboard-styler .edumall-tutor-dashboard {
    display: block !important;
    width: 100% !important;
    flex: 1 1 0% !important;
    height: auto !important;
    min-height: 500px !important;
    max-height: none !important;
    overflow: visible !important;
    position: relative !important;
    z-index: 99 !important;
    background: transparent !important;
}

body.csb-tutor-dashboard-styler .tutor-dashboard {
    display: flex !important;
    flex-wrap: wrap !important;
}

body.csb-tutor-dashboard-styler .content-wrapper,
body.csb-tutor-dashboard-styler .page-content {
    display: block !important;
}

/* Responsive Overrides */
@media (max-width: 991px) {
    body.csb-tutor-dashboard-styler .tutor-dashboard,
    body.csb-tutor-dashboard-styler .edumall-tutor-dashboard {
        flex-direction: column !important;
    }
    body.csb-tutor-dashboard-styler #tutor-dashboard-left-menu,
    body.csb-tutor-dashboard-styler .tutor-dashboard-left-menu,
    body.csb-tutor-dashboard-styler .tutor-dashboard-sidebar {
        width: 100% !important;
        margin-bottom: 30px !important;
    }
    body.csb-tutor-dashboard-styler .tutor-dashboard-header {
        flex-direction: column !important;
        align-items: flex-start !important;
        gap: 15px !important;
    }
    body.csb-tutor-dashboard-styler .tutor-dashboard-header-button {
        margin-left: 0 !important;
        width: 100% !important;
    }
    body.csb-tutor-dashboard-styler .tutor-dashboard-header-button a {
        display: block !important;
        text-align: center !important;
        width: 100% !important;
    }
}
@media (max-width: 767px) {
    body.csb-tutor-dashboard-styler .dashboard-info-card-box {
        min-height: 100px;
    }
    body.csb-tutor-dashboard-styler .tutor-dashboard-content,
    body.csb-tutor-dashboard-styler .edumall-tutor-dashboard {
        padding-left: 15px !important;
        padding-right: 15px !important;
        padding-bottom: 30px !important;
    }
}
