/* ============================================================
   EduEnglish — Hoja de estilos global
   Fuente: Inter · Bootstrap 5.3 como base
   ============================================================ */

/* ---- Variables CSS ---------------------------------------- */
:root {
    --primary:       #2563eb;
    --primary-dark:  #1d4ed8;
    --primary-light: #dbeafe;
    --secondary:     #7c3aed;
    --success:       #059669;
    --warning:       #d97706;
    --danger:        #ef4444;
    --info:          #0891b2;

    --sidebar-bg:    #0f172a;
    --sidebar-hover: rgba(255,255,255,0.08);
    --sidebar-active:#2563eb;
    --sidebar-text:  rgba(255,255,255,0.75);
    --sidebar-width: 260px;

    --topbar-height: 62px;
    --content-bg:    #f1f5f9;
    --card-bg:       #ffffff;
    --border:        #e2e8f0;
    --text-primary:  #0f172a;
    --text-secondary:#64748b;

    --radius-sm:  8px;
    --radius:     12px;
    --radius-lg:  16px;
    --shadow-sm:  0 1px 3px rgba(0,0,0,.06), 0 1px 2px rgba(0,0,0,.04);
    --shadow:     0 4px 12px rgba(0,0,0,.07);
    --shadow-md:  0 8px 24px rgba(0,0,0,.09);

    --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

/* ---- Reset & Base ----------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }
body { font-family: var(--font); color: var(--text-primary); margin: 0; padding: 0; }

/* ---- Layout principal ------------------------------------- */
.app-body {
    display: flex;
    min-height: 100vh;
    background: var(--content-bg);
}

/* Sidebar */
.sidebar {
    width: var(--sidebar-width);
    background: var(--sidebar-bg);
    display: flex;
    flex-direction: column;
    position: fixed;
    top: 0; left: 0; bottom: 0;
    z-index: 1000;
    transition: transform 0.25s ease;
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: rgba(255,255,255,0.1) transparent;
}
.sidebar::-webkit-scrollbar { width: 4px; }
.sidebar::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.1); border-radius: 4px; }

.sidebar-header {
    padding: 24px 20px 16px;
    border-bottom: 1px solid rgba(255,255,255,0.06);
}
.sidebar-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 8px;
}
.logo-icon { font-size: 24px; }
.logo-text {
    font-size: 1.2rem;
    font-weight: 800;
    color: #fff;
    letter-spacing: -0.5px;
}
.sidebar-role-badge {
    display: inline-block;
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    padding: 3px 10px;
    border-radius: 20px;
    background: rgba(37,99,235,0.3);
    color: #93c5fd;
    border: 1px solid rgba(37,99,235,0.4);
}
.role-teacher-badge { background: rgba(124,58,237,0.3); color: #c4b5fd; border-color: rgba(124,58,237,0.4); }
.role-student-badge { background: rgba(5,150,105,0.3); color: #6ee7b7; border-color: rgba(5,150,105,0.4); }

.sidebar-nav { flex: 1; padding: 16px 12px; }
.nav-section-label {
    font-size: 0.68rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: rgba(255,255,255,0.3);
    padding: 14px 8px 6px;
    margin-top: 4px;
}
.nav-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 9px 12px;
    border-radius: var(--radius-sm);
    color: var(--sidebar-text);
    text-decoration: none;
    font-size: 0.875rem;
    font-weight: 500;
    margin-bottom: 2px;
    transition: all 0.15s;
    cursor: pointer;
    border: none;
    background: none;
    width: 100%;
    text-align: left;
}
.nav-item:hover { background: var(--sidebar-hover); color: #fff; }
.nav-item.active { background: var(--sidebar-active); color: #fff; box-shadow: 0 2px 8px rgba(37,99,235,0.4); }
.nav-icon { font-size: 1rem; width: 20px; text-align: center; flex-shrink: 0; }
.nav-badge {
    margin-left: auto;
    background: var(--danger);
    color: #fff;
    font-size: 0.65rem;
    font-weight: 700;
    padding: 2px 6px;
    border-radius: 10px;
    min-width: 18px;
    text-align: center;
}
.nav-logout { color: rgba(239,68,68,0.8) !important; }
.nav-logout:hover { background: rgba(239,68,68,0.1) !important; color: #ef4444 !important; }
.sidebar-footer { padding: 12px; border-top: 1px solid rgba(255,255,255,0.06); }

/* Main wrapper */
.main-wrapper {
    flex: 1;
    margin-left: var(--sidebar-width);
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    transition: margin-left 0.25s ease;
}

/* Topbar */
.topbar {
    height: var(--topbar-height);
    background: #fff;
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    padding: 0 24px;
    gap: 16px;
    position: sticky;
    top: 0;
    z-index: 900;
    box-shadow: var(--shadow-sm);
}
.sidebar-toggle {
    background: none;
    border: none;
    font-size: 20px;
    cursor: pointer;
    color: var(--text-secondary);
    padding: 4px 8px;
    border-radius: 6px;
    display: none;
}
.topbar-title {
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--text-primary);
    flex: 1;
}
.topbar-right { display: flex; align-items: center; gap: 8px; }
.topbar-btn {
    width: 38px; height: 38px;
    display: flex; align-items: center; justify-content: center;
    border-radius: 50%;
    text-decoration: none;
    font-size: 18px;
    transition: background 0.15s;
    color: var(--text-secondary);
}
.topbar-btn:hover { background: var(--content-bg); }
.notif-badge {
    position: absolute;
    top: -2px; right: -2px;
    background: var(--danger);
    color: #fff;
    font-size: 0.6rem;
    font-weight: 700;
    min-width: 16px; height: 16px;
    border-radius: 8px;
    display: flex; align-items: center; justify-content: center;
    padding: 0 3px;
}
.topbar-user {
    display: flex; align-items: center; gap: 8px;
    background: none; border: none; cursor: pointer;
    padding: 4px 8px;
    border-radius: 8px;
    font-family: var(--font);
    transition: background 0.15s;
}
.topbar-user:hover { background: var(--content-bg); }
.user-avatar { width: 34px; height: 34px; border-radius: 50%; object-fit: cover; }
.user-name { font-size: 0.875rem; font-weight: 600; color: var(--text-primary); }

/* Page content */
.page-content { flex: 1; padding: 28px; }
.page-footer {
    padding: 14px 24px;
    border-top: 1px solid var(--border);
    background: #fff;
    font-size: 0.8rem;
    color: var(--text-secondary);
    text-align: center;
}

/* ---- Cards ------------------------------------------------ */
.content-card {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 24px;
    box-shadow: var(--shadow-sm);
}
.card-header-custom {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 20px;
    flex-wrap: wrap;
    gap: 8px;
}
.card-title-custom {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0;
}
.card-link {
    font-size: 0.825rem;
    font-weight: 600;
    color: var(--primary);
    text-decoration: none;
    white-space: nowrap;
}
.card-link:hover { text-decoration: underline; }

/* ---- Stat cards ------------------------------------------- */
.stat-card {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-left: 4px solid var(--accent);
    border-radius: var(--radius);
    padding: 20px;
    box-shadow: var(--shadow-sm);
    display: flex;
    flex-direction: column;
    gap: 8px;
    position: relative;
    overflow: hidden;
    transition: box-shadow 0.2s, transform 0.2s;
}
.stat-card:hover { box-shadow: var(--shadow-md); transform: translateY(-2px); }
.stat-icon { font-size: 2rem; }
.stat-body { flex: 1; }
.stat-number { font-size: 2rem; font-weight: 800; color: var(--text-primary); line-height: 1; }
.stat-label  { font-size: 0.825rem; color: var(--text-secondary); font-weight: 500; margin-top: 4px; }
.stat-link   { font-size: 0.775rem; font-weight: 600; color: var(--accent); text-decoration: none; }
.stat-link:hover { text-decoration: underline; }

/* Mini stat cards for student */
.stat-card-mini {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-top: 3px solid var(--accent);
    border-radius: var(--radius);
    padding: 18px 16px;
    text-align: center;
    box-shadow: var(--shadow-sm);
}
.stat-mini-icon { font-size: 1.5rem; margin-bottom: 8px; }
.stat-mini-num  { font-size: 1.6rem; font-weight: 800; color: var(--text-primary); }
.stat-mini-label { font-size: 0.775rem; color: var(--text-secondary); font-weight: 500; margin-top: 2px; }

/* ---- Alert info card -------------------------------------- */
.alert-info-card {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 16px 20px;
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-left: 4px solid var(--accent);
    border-radius: var(--radius);
    font-size: 0.875rem;
    color: var(--text-primary);
}
.alert-icon { font-size: 1.5rem; }

/* ---- Buttons ---------------------------------------------- */
.btn-primary-custom {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 9px 18px;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: #fff;
    border: none;
    border-radius: var(--radius-sm);
    font-family: var(--font);
    font-size: 0.875rem;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.2s;
    box-shadow: 0 2px 8px rgba(37,99,235,0.25);
    white-space: nowrap;
}
.btn-primary-custom:hover { transform: translateY(-1px); box-shadow: 0 4px 14px rgba(37,99,235,0.35); color: #fff; }
.btn-sm-custom { padding: 6px 12px; font-size: 0.8rem; }
.btn-secondary-custom {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 9px 18px;
    background: #f1f5f9;
    color: var(--text-primary);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    font-family: var(--font);
    font-size: 0.875rem;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.15s;
    white-space: nowrap;
}
.btn-secondary-custom:hover { background: #e2e8f0; color: var(--text-primary); }
.btn-join {
    padding: 6px 14px;
    background: linear-gradient(135deg, #059669, #047857);
    color: #fff;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    text-decoration: none;
    white-space: nowrap;
    transition: all 0.15s;
    flex-shrink: 0;
}
.btn-join:hover { transform: scale(1.05); color: #fff; }
.btn-review {
    padding: 5px 12px;
    background: var(--primary-light);
    color: var(--primary);
    border-radius: 6px;
    font-size: 0.78rem;
    font-weight: 600;
    text-decoration: none;
    white-space: nowrap;
    flex-shrink: 0;
    transition: all 0.15s;
}
.btn-review:hover { background: var(--primary); color: #fff; }
.mini-btn {
    padding: 4px 10px;
    background: var(--content-bg);
    color: var(--text-secondary);
    border-radius: 6px;
    font-size: 0.775rem;
    font-weight: 500;
    text-decoration: none;
    border: 1px solid var(--border);
    transition: all 0.15s;
}
.mini-btn:hover { background: var(--primary-light); color: var(--primary); border-color: var(--primary-light); }

/* ---- Forms ----------------------------------------------- */
.form-control, .form-select {
    border: 1.5px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 10px 14px;
    font-family: var(--font);
    font-size: 0.9rem;
    background: #fff;
    color: var(--text-primary);
    transition: border-color 0.15s, box-shadow 0.15s;
}
.form-control:focus, .form-select:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(37,99,235,0.1);
    outline: none;
}
.form-label { font-size: 0.875rem; font-weight: 600; color: var(--text-primary); margin-bottom: 6px; }

/* Search */
.search-form { display: flex; gap: 0; }
.search-input {
    border: 1.5px solid var(--border);
    border-right: none;
    border-radius: var(--radius-sm) 0 0 var(--radius-sm);
    padding: 9px 14px;
    font-family: var(--font);
    font-size: 0.875rem;
    min-width: 240px;
    outline: none;
    transition: border-color 0.15s;
}
.search-input:focus { border-color: var(--primary); }
.search-btn {
    padding: 9px 14px;
    background: var(--primary);
    color: #fff;
    border: none;
    border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
    cursor: pointer;
    font-size: 0.9rem;
    transition: background 0.15s;
}
.search-btn:hover { background: var(--primary-dark); }

/* ---- Tables ---------------------------------------------- */
.data-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.875rem;
}
.data-table th {
    padding: 12px 16px;
    background: var(--content-bg);
    color: var(--text-secondary);
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-bottom: 1px solid var(--border);
    text-align: left;
    white-space: nowrap;
}
.data-table td {
    padding: 14px 16px;
    border-bottom: 1px solid var(--border);
    vertical-align: middle;
    color: var(--text-primary);
}
.data-table tbody tr:hover { background: #f8fafc; }
.data-table tbody tr:last-child td { border-bottom: none; }
.table-avatar { width: 36px; height: 36px; border-radius: 50%; object-fit: cover; }
.table-actions { display: flex; gap: 6px; }
.action-btn {
    padding: 5px 10px;
    border-radius: 6px;
    font-size: 0.8rem;
    text-decoration: none;
    transition: all 0.15s;
    font-weight: 500;
}
.action-edit  { background: #dbeafe; color: var(--primary); }
.action-edit:hover  { background: var(--primary); color: #fff; }
.action-delete { background: #fee2e2; color: var(--danger); }
.action-delete:hover { background: var(--danger); color: #fff; }

/* ---- Badges / Status ------------------------------------- */
.status-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 3px 10px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    white-space: nowrap;
}
.status-active   { background: #d1fae5; color: #065f46; }
.status-inactive { background: #f1f5f9; color: #475569; }
.status-pending  { background: #fef3c7; color: #92400e; }
.status-submitted{ background: #dbeafe; color: #1e40af; }
.status-reviewed { background: #d1fae5; color: #065f46; }
.status-overdue  { background: #fee2e2; color: #991b1b; }

.role-badge {
    padding: 3px 10px;
    border-radius: 20px;
    font-size: 0.72rem;
    font-weight: 700;
    white-space: nowrap;
}
.role-admin   { background: #e0e7ff; color: #3730a3; }
.role-teacher { background: #f3e8ff; color: #6b21a8; }
.role-student { background: #d1fae5; color: #065f46; }

.platform-badge {
    font-size: 0.7rem;
    font-weight: 700;
    padding: 3px 8px;
    border-radius: 6px;
    letter-spacing: 0.3px;
    flex-shrink: 0;
}
.platform-zoom  { background: #dbeafe; color: #1d4ed8; }
.platform-meet  { background: #dcfce7; color: #166534; }
.platform-teams { background: #ede9fe; color: #5b21b6; }
.platform-other { background: #f1f5f9; color: #475569; }

/* ---- Class list ------------------------------------------ */
.class-list { display: flex; flex-direction: column; gap: 0; }
.class-item {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 0;
    border-bottom: 1px solid var(--border);
}
.class-item:last-child { border-bottom: none; }
.class-date-box {
    min-width: 44px;
    text-align: center;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    border-radius: 10px;
    padding: 8px 4px;
    color: #fff;
    flex-shrink: 0;
}
.class-day   { font-size: 1.2rem; font-weight: 800; line-height: 1; }
.class-month { font-size: 0.65rem; font-weight: 700; text-transform: uppercase; opacity: 0.85; }
.class-info  { flex: 1; min-width: 0; }
.class-name  { font-weight: 600; font-size: 0.9rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.class-meta  { font-size: 0.775rem; color: var(--text-secondary); margin-top: 2px; }

/* ---- User list ------------------------------------------- */
.user-list { display: flex; flex-direction: column; gap: 0; }
.user-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 0;
    border-bottom: 1px solid var(--border);
}
.user-item:last-child { border-bottom: none; }
.user-item-avatar { width: 38px; height: 38px; border-radius: 50%; object-fit: cover; flex-shrink: 0; }
.user-item-info  { flex: 1; min-width: 0; }
.user-item-name  { font-weight: 600; font-size: 0.875rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.user-item-email { font-size: 0.775rem; color: var(--text-secondary); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* ---- Submission list -------------------------------------- */
.submission-list { display: flex; flex-direction: column; gap: 0; }
.submission-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 0;
    border-bottom: 1px solid var(--border);
}
.submission-item:last-child { border-bottom: none; }
.submission-info { flex: 1; min-width: 0; }
.submission-student { font-weight: 600; font-size: 0.875rem; }
.submission-task    { font-size: 0.8rem; color: var(--text-secondary); }
.submission-time    { font-size: 0.75rem; color: var(--text-secondary); }

/* ---- Task list (student) ---------------------------------- */
.task-list { display: flex; flex-direction: column; gap: 0; }
.task-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 0;
    border-bottom: 1px solid var(--border);
}
.task-item:last-child { border-bottom: none; }
.task-item.task-overdue { background: #fef9f9; }
.task-status-dot {
    width: 10px; height: 10px;
    border-radius: 50%;
    flex-shrink: 0;
}
.status-pending   .task-status-dot, .task-status-dot.status-pending   { background: var(--warning); }
.status-submitted .task-status-dot, .task-status-dot.status-submitted { background: var(--primary); }
.status-reviewed  .task-status-dot, .task-status-dot.status-reviewed  { background: var(--success); }
.task-info  { flex: 1; min-width: 0; }
.task-title { font-weight: 600; font-size: 0.875rem; }
.task-due   { font-size: 0.775rem; font-weight: 500; margin-top: 2px; }

/* ---- Quiz list ------------------------------------------- */
.quiz-list { display: flex; flex-direction: column; gap: 0; }
.quiz-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 0;
    border-bottom: 1px solid var(--border);
}
.quiz-item:last-child { border-bottom: none; }
.quiz-icon { font-size: 1.5rem; flex-shrink: 0; }
.quiz-info { flex: 1; min-width: 0; }
.quiz-title { font-weight: 600; font-size: 0.875rem; }

/* ---- Grade list ------------------------------------------ */
.grade-list { display: flex; flex-direction: column; gap: 0; }
.grade-item {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 12px 0;
    border-bottom: 1px solid var(--border);
}
.grade-item:last-child { border-bottom: none; }
.grade-circle {
    width: 46px; height: 46px;
    border-radius: 50%;
    background: conic-gradient(var(--grade-color) calc(var(--grade) * 1%), #e2e8f0 0);
    display: flex; align-items: center; justify-content: center;
    font-weight: 800; font-size: 0.8rem;
    color: var(--grade-color);
    flex-shrink: 0;
    position: relative;
}
.grade-circle::before {
    content: '';
    position: absolute;
    width: 34px; height: 34px;
    background: #fff;
    border-radius: 50%;
}
.grade-circle span { position: relative; z-index: 1; }
.grade-info  { flex: 1; min-width: 0; }
.grade-task  { font-weight: 600; font-size: 0.875rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.grade-course { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* ---- Notifications ---------------------------------------- */
.notif-list { display: flex; flex-direction: column; gap: 0; }
.notif-item {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    padding: 14px 0;
    border-bottom: 1px solid var(--border);
}
.notif-item:last-child { border-bottom: none; }
.notif-item.notif-unread { background: #f8faff; border-radius: 8px; padding: 14px 12px; margin: 0 -12px; }
.notif-type-icon { font-size: 1.3rem; flex-shrink: 0; margin-top: 2px; }
.notif-content { flex: 1; min-width: 0; }
.notif-title { font-weight: 600; font-size: 0.875rem; }
.notif-msg   { font-size: 0.825rem; color: var(--text-secondary); margin-top: 2px; }
.notif-time  { font-size: 0.75rem; white-space: nowrap; }

/* ---- Quick actions ---------------------------------------- */
.quick-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}
.quick-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    padding: 16px 20px;
    background: var(--content-bg);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    text-decoration: none;
    color: var(--text-primary);
    font-size: 0.8rem;
    font-weight: 600;
    transition: all 0.2s;
    min-width: 90px;
    text-align: center;
}
.quick-btn:hover {
    background: var(--primary-light);
    border-color: var(--primary);
    color: var(--primary);
    transform: translateY(-2px);
    box-shadow: var(--shadow);
}
.quick-icon { font-size: 1.6rem; }

/* ---- Course cards ---------------------------------------- */
.course-card {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 20px;
    box-shadow: var(--shadow-sm);
    height: 100%;
    display: flex;
    flex-direction: column;
    gap: 12px;
    transition: box-shadow 0.2s, transform 0.2s;
}
.course-card:hover { box-shadow: var(--shadow-md); transform: translateY(-2px); }
.course-card-header { display: flex; justify-content: space-between; align-items: center; }
.course-card-title  { font-size: 1rem; font-weight: 700; color: var(--text-primary); margin: 0; }
.course-card-desc   { font-size: 0.825rem; color: var(--text-secondary); flex: 1; margin: 0; }
.course-card-meta   { display: flex; flex-wrap: wrap; gap: 12px; font-size: 0.8rem; color: var(--text-secondary); }
.course-card-actions { display: flex; gap: 8px; flex-wrap: wrap; }

.mini-course-card {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 18px;
    height: 100%;
    transition: box-shadow 0.2s;
}
.mini-course-card:hover { box-shadow: var(--shadow); }

/* ---- Welcome banner (student) ----------------------------- */
.welcome-banner {
    background: linear-gradient(135deg, #0f172a, #1e3a5f);
    border-radius: var(--radius-lg);
    padding: 28px 32px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    color: #fff;
}
.welcome-title { font-size: 1.5rem; font-weight: 800; margin: 0 0 6px; }
.welcome-sub   { color: rgba(255,255,255,0.7); margin: 0; font-size: 0.9rem; }
.score-circle {
    width: 80px; height: 80px;
    border-radius: 50%;
    background: conic-gradient(#38bdf8 calc(var(--score) * 1%), rgba(255,255,255,0.15) 0);
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    position: relative;
    flex-shrink: 0;
}
.score-circle::before {
    content: '';
    position: absolute;
    width: 60px; height: 60px;
    background: #0f172a;
    border-radius: 50%;
}
.score-number { position: relative; z-index: 1; font-size: 1.1rem; font-weight: 800; color: #38bdf8; }
.score-label  { position: relative; z-index: 1; font-size: 0.6rem; color: rgba(255,255,255,0.6); font-weight: 600; }

/* ---- Page actions ---------------------------------------- */
.page-actions { margin-bottom: 4px; }

/* ---- Empty state ----------------------------------------- */
.empty-state {
    text-align: center;
    padding: 40px 20px;
    color: var(--text-secondary);
}
.empty-icon { font-size: 3rem; margin-bottom: 12px; opacity: 0.5; }
.empty-state p { font-size: 0.9rem; margin: 0; }

/* ---- Dropdown --------------------------------------------- */
.dropdown-menu { border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow-md); padding: 6px; }
.dropdown-item { border-radius: 6px; font-size: 0.875rem; padding: 8px 12px; }
.dropdown-item:hover { background: var(--content-bg); }
.dropdown-header { font-size: 0.775rem; color: var(--text-secondary); padding: 6px 12px; }
.dropdown-toggle::after { display: none; }

/* ---- Bootstrap overrides ---------------------------------- */
.badge { font-weight: 600; font-size: 0.72rem; }
.alert { border-radius: var(--radius); font-size: 0.875rem; }
.alert-success { background: #f0fdf4; border-color: #bbf7d0; color: #166534; }
.alert-danger  { background: #fef2f2; border-color: #fecaca; color: #991b1b; }
.alert-warning { background: #fffbeb; border-color: #fde68a; color: #92400e; }
.alert-info    { background: #f0f9ff; border-color: #bae6fd; color: #0c4a6e; }

/* ---- Font-weight utilities (complementan Bootstrap 5) ----- */
.fw-500 { font-weight: 500 !important; }
.fw-600 { font-weight: 600 !important; }
.fw-700 { font-weight: 700 !important; }
.fw-800 { font-weight: 800 !important; }

/* ---- Responsive ------------------------------------------ */
@media (max-width: 991px) {
    .sidebar { transform: translateX(-100%); }
    .sidebar.open { transform: translateX(0); }
    .sidebar-toggle { display: flex; }
    .main-wrapper { margin-left: 0; }
    .page-content { padding: 20px 16px; }
    .search-input { min-width: 160px; }
    .welcome-banner { flex-direction: column; text-align: center; }
}
@media (max-width: 576px) {
    .topbar { padding: 0 14px; }
    .user-name { display: none; }
    .quick-btn { min-width: 75px; padding: 12px; }
    .class-item { flex-wrap: wrap; }
}
