/* Lessons Page - keep same vibe as tutorials/courses */
* {
    box-sizing: border-box;
}

body {
    background: var(--c-bg);
    min-height: 100vh;
    font-family: var(--font-body);
}

.lessons-container {
    max-width: 95vw;
    width: 95vw;
    margin: 20px auto;
    padding: 0 20px;
}

.lessons-card {
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    padding: 40px;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.page-header {
    text-align: center;
    margin-bottom: 30px;
}

.page-title {
    background: var(--g-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-size: 2.5rem;
    font-weight: 800;
    margin: 0 0 10px 0;
}

.page-subtitle {
    color: #64748b;
    font-size: 1.1rem;
    margin: 0;
    font-weight: 500;
}

.lessons-toolbar {
    margin: 10px 0 26px 0;
}

.toolbar-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 15px;
    flex-wrap: wrap;
}

.search-box {
    flex: 1;
    min-width: 260px;
    max-width: 520px;
    display: flex;
    align-items: center;
    gap: 10px;
    background: #ffffff;
    border: 2px solid #e1e8ed;
    border-radius: 12px;
    padding: 10px 12px;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.06);
}

.search-box i {
    color: #667eea;
}

.search-box input {
    border: none;
    outline: none;
    flex: 1;
    font-size: 1rem;
    background: transparent;
}

.filters {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    justify-content: center;
}

.filter {
    border: 2px solid #e1e8ed;
    border-radius: 12px;
    padding: 10px 12px;
    font-weight: 700;
    background: #fff;
    color: #2c3e50;
}

.filter-input {
    cursor: text;
}

.teacher-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    justify-content: center;
    margin-top: 14px;
}

.manage-btn {
    color: white;
    text-decoration: none;
    padding: 10px 16px;
    border-radius: 12px;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: all 0.3s ease;
    background: #0f172a;
}

.manage-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(15, 23, 42, 0.25);
}

.lessons-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(420px, 1fr));
    gap: 24px;
    margin-top: 10px;
}

.lesson-card {
    background: linear-gradient(135deg, #f8fafc, #ffffff);
    border: 2px solid #e2e8f0;
    border-radius: 16px;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.25s ease;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.06);
}

.lesson-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 18px 40px rgba(102, 126, 234, 0.18);
    border-color: rgba(102, 126, 234, 0.55);
}

.lesson-cover {
    height: 140px;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.20), rgba(118, 75, 162, 0.18));
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 40px;
}

.lesson-body {
    padding: 16px 16px 18px;
}

.lesson-title {
    margin: 0 0 6px 0;
    font-size: 1.2rem;
    font-weight: 900;
    color: #0f172a;
}

.lesson-desc {
    margin: 0 0 12px 0;
    color: #475569;
    line-height: 1.5;
    font-weight: 600;
}

.lesson-meta-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    flex-wrap: wrap;
}

.badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 10px;
    border-radius: 999px;
    border: 1px solid #e2e8f0;
    background: #ffffff;
    font-weight: 800;
    color: #334155;
    font-size: 0.9rem;
}

.teacher-chip {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    color: #0f172a;
    background: #fff;
    border: 1px solid #e2e8f0;
    padding: 6px 10px;
    border-radius: 999px;
    font-weight: 900;
}

.teacher-chip img {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    object-fit: cover;
}

.loading-state,
.error-state,
.empty-state {
    text-align: center;
    padding: 35px 10px;
    color: #64748b;
}

.loading-state i,
.error-state i {
    font-size: 2rem;
    margin-bottom: 10px;
    color: #667eea;
}

.empty-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 15px;
    background: rgba(102, 126, 234, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    color: #667eea;
}

@media (max-width: 720px) {
    .lessons-card {
        padding: 22px;
    }
    .lessons-grid {
        grid-template-columns: 1fr;
    }
}

