/* ============================================
   EduLearn LMS - Main Stylesheet
   Theme: White + Blue Professional
   ============================================ */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&family=Outfit:wght@400;500;600;700;800&display=swap');

/* ---- CSS Variables ---- */
:root {
    --primary: #1565C0;
    --primary-dark: #0D47A1;
    --primary-light: #42A5F5;
    --primary-pale: #E3F2FD;
    --primary-mid: #BBDEFB;
    --accent: #00BCD4;
    --success: #2E7D32;
    --warning: #F57C00;
    --danger: #C62828;
    --white: #FFFFFF;
    --bg: #F0F4F8;
    --bg2: #EAF1FB;
    --sidebar-bg: #0D47A1;
    --sidebar-width: 260px;
    --text: #1A1A2E;
    --text-muted: #6B7280;
    --border: #D1E4F6;
    --card-shadow: 0 2px 16px rgba(21, 101, 192, .10);
    --radius: 14px;
    --radius-sm: 8px;
    --transition: all .22s ease;
    --font-main: 'Inter', sans-serif;
    --font-heading: 'Outfit', sans-serif;
}

/* ---- Reset & Base ---- */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-main);
    background: var(--bg);
    color: var(--text);
    min-height: 100vh;
    font-size: 15px;
    line-height: 1.6;
}

a {
    text-decoration: none;
    color: var(--primary);
    transition: var(--transition);
}

a:hover {
    color: var(--primary-dark);
}

img {
    max-width: 100%;
    display: block;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-heading);
    font-weight: 700;
}

/* ============================================
   LAYOUT - SIDEBAR + CONTENT WRAPPER
   ============================================ */
.lms-wrapper {
    display: flex;
    min-height: 100vh;
}

/* SIDEBAR */
.lms-sidebar {
    width: var(--sidebar-width);
    background: linear-gradient(180deg, var(--sidebar-bg) 0%, #1565C0 100%);
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    z-index: 1000;
    display: flex;
    flex-direction: column;
    overflow-y: auto;
    transition: var(--transition);
    box-shadow: 4px 0 24px rgba(13, 71, 161, .18);
}

.lms-sidebar::-webkit-scrollbar {
    width: 4px;
}

.lms-sidebar::-webkit-scrollbar-track {
    background: transparent;
}

.lms-sidebar::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, .2);
    border-radius: 10px;
}

/* Sidebar Brand */
.sidebar-brand {
    padding: 28px 24px 20px;
    border-bottom: 1px solid rgba(255, 255, 255, .12);
}

.sidebar-brand .brand-logo {
    display: flex;
    align-items: center;
    gap: 12px;
}

.brand-icon {
    width: 44px;
    height: 44px;
    background: rgba(255, 255, 255, .18);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    color: #fff;
}

.brand-name {
    color: #fff;
    font-family: var(--font-heading);
    font-size: 20px;
    font-weight: 700;
    line-height: 1.2;
}

.brand-tagline {
    color: rgba(255, 255, 255, .6);
    font-size: 11px;
}

/* Sidebar User */
.sidebar-user {
    padding: 20px 24px;
    border-bottom: 1px solid rgba(255, 255, 255, .1);
    display: flex;
    align-items: center;
    gap: 12px;
}

.sidebar-user-avatar {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid rgba(255, 255, 255, .35);
}

.sidebar-user-name {
    color: #fff;
    font-weight: 600;
    font-size: 14px;
}

.sidebar-user-role {
    color: rgba(255, 255, 255, .65);
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: .5px;
    padding: 2px 8px;
    background: rgba(255, 255, 255, .12);
    border-radius: 20px;
    display: inline-block;
    margin-top: 2px;
}

/* Sidebar Nav */
.sidebar-nav {
    padding: 16px 0;
    flex: 1;
}

.sidebar-section-label {
    color: rgba(255, 255, 255, .45);
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    padding: 12px 24px 6px;
}

.sidebar-nav-item {
    list-style: none;
}

.sidebar-nav-link {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 11px 24px;
    color: rgba(255, 255, 255, .8);
    font-size: 14px;
    font-weight: 500;
    border-radius: 0;
    transition: var(--transition);
    position: relative;
}

.sidebar-nav-link i {
    font-size: 18px;
    width: 22px;
    text-align: center;
}

.sidebar-nav-link:hover,
.sidebar-nav-link.active {
    background: rgba(255, 255, 255, .14);
    color: #fff;
    padding-left: 28px;
}

.sidebar-nav-link.active::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 3px;
    background: #fff;
    border-radius: 0 4px 4px 0;
}

.sidebar-nav-link .badge-nav {
    margin-left: auto;
    background: #FF5252;
    color: #fff;
    font-size: 10px;
    padding: 2px 7px;
    border-radius: 20px;
}

/* Sidebar Footer */
.sidebar-footer {
    padding: 16px 24px;
    border-top: 1px solid rgba(255, 255, 255, .1);
}

.sidebar-footer .logout-btn {
    display: flex;
    align-items: center;
    gap: 10px;
    color: rgba(255, 255, 255, .75);
    font-size: 13px;
    padding: 10px 14px;
    border-radius: var(--radius-sm);
    width: 100%;
    background: rgba(255, 255, 255, .08);
    border: none;
    cursor: pointer;
    transition: var(--transition);
}

.sidebar-footer .logout-btn:hover {
    background: rgba(220, 53, 69, .25);
    color: #FF8A80;
}

/* MAIN CONTENT */
.lms-content {
    margin-left: var(--sidebar-width);
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

/* TOPBAR */
.lms-topbar {
    background: var(--white);
    padding: 0 30px;
    height: 68px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    z-index: 900;
    box-shadow: 0 2px 12px rgba(21, 101, 192, .06);
}

.topbar-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 24px;
    color: var(--primary);
    cursor: pointer;
}

.topbar-title {
    font-size: 18px;
    font-weight: 700;
    color: var(--text);
    font-family: var(--font-heading);
}

.topbar-right {
    display: flex;
    align-items: center;
    gap: 14px;
}

.topbar-icon-btn {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg);
    border: 1px solid var(--border);
    color: var(--text-muted);
    cursor: pointer;
    transition: var(--transition);
    font-size: 18px;
    position: relative;
}

.topbar-icon-btn:hover {
    background: var(--primary-pale);
    color: var(--primary);
}

.topbar-badge {
    position: absolute;
    top: -4px;
    right: -4px;
    background: #FF5252;
    color: #fff;
    font-size: 10px;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.topbar-avatar {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--primary-mid);
    cursor: pointer;
}

/* PAGE CONTENT AREA */
.page-content {
    padding: 30px;
    flex: 1;
}

/* ============================================
   CARDS
   ============================================ */
.lms-card {
    background: var(--white);
    border-radius: var(--radius);
    box-shadow: var(--card-shadow);
    border: 1px solid var(--border);
    overflow: hidden;
}

.lms-card-header {
    padding: 20px 24px;
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.lms-card-title {
    font-size: 17px;
    font-weight: 700;
    font-family: var(--font-heading);
}

.lms-card-body {
    padding: 24px;
}

/* ============================================
   STAT CARDS (Dashboard)
   ============================================ */
.stat-card {
    background: var(--white);
    border-radius: var(--radius);
    padding: 24px;
    display: flex;
    align-items: center;
    gap: 18px;
    box-shadow: var(--card-shadow);
    border: 1px solid var(--border);
    transition: var(--transition);
}

.stat-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 30px rgba(21, 101, 192, .15);
}

.stat-icon {
    width: 58px;
    height: 58px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 26px;
    flex-shrink: 0;
}

.stat-icon.blue {
    background: var(--primary-pale);
    color: var(--primary);
}

.stat-icon.green {
    background: #E8F5E9;
    color: #2E7D32;
}

.stat-icon.orange {
    background: #FFF3E0;
    color: #E65100;
}

.stat-icon.teal {
    background: #E0F7FA;
    color: #00838F;
}

.stat-value {
    font-size: 28px;
    font-weight: 800;
    font-family: var(--font-heading);
    line-height: 1;
}

.stat-label {
    font-size: 13px;
    color: var(--text-muted);
    margin-top: 4px;
}

.stat-trend {
    font-size: 12px;
    margin-top: 6px;
}

.stat-trend.up {
    color: #2E7D32;
}

.stat-trend.down {
    color: #C62828;
}

/* ============================================
   FORMS
   ============================================ */
.lms-form-label {
    font-weight: 600;
    font-size: 13px;
    color: var(--text);
    margin-bottom: 6px;
    display: block;
}

.lms-form-control {
    width: 100%;
    padding: 11px 16px;
    border: 1.5px solid var(--border);
    border-radius: var(--radius-sm);
    font-family: var(--font-main);
    font-size: 14.5px;
    color: var(--text);
    background: var(--white);
    transition: var(--transition);
    outline: none;
}

.lms-form-control:focus {
    border-color: var(--primary-light);
    box-shadow: 0 0 0 3.5px rgba(66, 165, 245, .15);
}

.lms-form-control::placeholder {
    color: #B0BEC5;
}

.input-icon-wrap {
    position: relative;
}

.input-icon-wrap .lms-form-control {
    padding-left: 42px;
}

.input-icon-wrap .input-icon {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    font-size: 17px;
}

.input-group-right {
    padding-right: 42px;
}

.input-icon-right {
    position: absolute;
    right: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    cursor: pointer;
    font-size: 17px;
}

/* ============================================
   BUTTONS
   ============================================ */
.btn-primary-lms {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    color: #fff;
    border: none;
    padding: 12px 28px;
    border-radius: var(--radius-sm);
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 8px;
    box-shadow: 0 4px 14px rgba(21, 101, 192, .25);
}

.btn-primary-lms:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(21, 101, 192, .35);
    color: #fff;
}

.btn-outline-lms {
    background: transparent;
    color: var(--primary);
    border: 1.5px solid var(--primary);
    padding: 11px 26px;
    border-radius: var(--radius-sm);
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.btn-outline-lms:hover {
    background: var(--primary);
    color: #fff;
}

.btn-danger-lms {
    background: linear-gradient(135deg, #C62828, #E53935);
    color: #fff;
    border: none;
    padding: 9px 20px;
    border-radius: var(--radius-sm);
    font-weight: 600;
    font-size: 13px;
    cursor: pointer;
    transition: var(--transition);
}

.btn-danger-lms:hover {
    transform: translateY(-1px);
}

.btn-success-lms {
    background: linear-gradient(135deg, #2E7D32, #43A047);
    color: #fff;
    border: none;
    padding: 9px 20px;
    border-radius: var(--radius-sm);
    font-weight: 600;
    font-size: 13px;
    cursor: pointer;
    transition: var(--transition);
}

/* ============================================
   TABLES
   ============================================ */
.lms-table {
    width: 100%;
    border-collapse: collapse;
}

.lms-table thead tr {
    background: var(--primary-pale);
}

.lms-table th {
    padding: 14px 18px;
    text-align: left;
    font-size: 12px;
    font-weight: 700;
    color: var(--primary);
    text-transform: uppercase;
    letter-spacing: .5px;
    border-bottom: 2px solid var(--border);
}

.lms-table td {
    padding: 14px 18px;
    border-bottom: 1px solid var(--border);
    font-size: 14px;
    color: var(--text);
    vertical-align: middle;
}

.lms-table tbody tr {
    transition: var(--transition);
}

.lms-table tbody tr:hover {
    background: var(--bg2);
}

.lms-table tbody tr:last-child td {
    border-bottom: none;
}

/* ============================================
   BADGES / STATUS PILLS
   ============================================ */
.badge-lms {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: .3px;
}

.badge-pending {
    background: #FFF3E0;
    color: #E65100;
}

.badge-approved {
    background: #E8F5E9;
    color: #2E7D32;
}

.badge-rejected {
    background: #FFEBEE;
    color: #C62828;
}

.badge-active {
    background: #E3F2FD;
    color: #1565C0;
}

.badge-info {
    background: #E0F7FA;
    color: #00838F;
}

/* ============================================
   ALERT / FLASH
   ============================================ */
.lms-alert {
    padding: 14px 20px;
    border-radius: var(--radius-sm);
    font-size: 14px;
    margin-bottom: 18px;
    border-left: 4px solid;
    display: flex;
    align-items: center;
    gap: 10px;
}

.lms-alert-success {
    background: #E8F5E9;
    border-color: #2E7D32;
    color: #1B5E20;
}

.lms-alert-error {
    background: #FFEBEE;
    border-color: #C62828;
    color: #B71C1C;
}

.lms-alert-info {
    background: #E3F2FD;
    border-color: #1565C0;
    color: #0D47A1;
}

.lms-alert-warning {
    background: #FFF3E0;
    border-color: #F57C00;
    color: #E65100;
}

/* ============================================
   AUTH PAGES
   ============================================ */
.auth-wrapper {
    min-height: 100vh;
    background: linear-gradient(135deg, #0D47A1 0%, #1565C0 50%, #42A5F5 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    position: relative;
    overflow: hidden;
}

.auth-wrapper::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle at 30% 40%, rgba(255, 255, 255, .06) 0%, transparent 50%),
        radial-gradient(circle at 70% 80%, rgba(0, 188, 212, .1) 0%, transparent 50%);
    animation: bgPulse 8s ease-in-out infinite alternate;
}

@keyframes bgPulse {
    from {
        transform: scale(1) rotate(0deg);
    }

    to {
        transform: scale(1.05) rotate(3deg);
    }
}

.auth-panel {
    background: rgba(255, 255, 255, .97);
    border-radius: 24px;
    padding: 48px 44px;
    width: 100%;
    max-width: 460px;
    position: relative;
    z-index: 10;
    box-shadow: 0 24px 64px rgba(13, 71, 161, .3);
}

.auth-logo {
    text-align: center;
    margin-bottom: 32px;
}

.auth-logo .logo-icon {
    width: 68px;
    height: 68px;
    border-radius: 18px;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    color: #fff;
    margin: 0 auto 14px;
    box-shadow: 0 8px 24px rgba(21, 101, 192, .3);
}

.auth-logo h2 {
    font-size: 24px;
    color: var(--text);
    font-family: var(--font-heading);
}

.auth-logo p {
    color: var(--text-muted);
    font-size: 13.5px;
    margin-top: 4px;
}

/* OTP Input */
.otp-inputs {
    display: flex;
    gap: 12px;
    justify-content: center;
    margin: 20px 0;
}

.otp-input {
    width: 54px;
    height: 58px;
    border: 2px solid var(--border);
    border-radius: 12px;
    text-align: center;
    font-size: 24px;
    font-weight: 700;
    color: var(--primary);
    outline: none;
    transition: var(--transition);
}

.otp-input:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(21, 101, 192, .15);
}

/* ============================================
   COURSE CARDS
   ============================================ */
.course-card {
    background: var(--white);
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--card-shadow);
    border: 1px solid var(--border);
    transition: var(--transition);
    height: 100%;
}

.course-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 36px rgba(21, 101, 192, .18);
}

.course-thumbnail {
    height: 180px;
    overflow: hidden;
    background: var(--primary-pale);
}

.course-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

.course-card:hover .course-thumbnail img {
    transform: scale(1.05);
}

.course-body {
    padding: 20px;
}

.course-level {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 600;
    margin-bottom: 10px;
    text-transform: uppercase;
    letter-spacing: .5px;
}

.level-beginner {
    background: #E8F5E9;
    color: #2E7D32;
}

.level-intermediate {
    background: #FFF8E1;
    color: #F9A825;
}

.level-advanced {
    background: #FFF3E0;
    color: #E65100;
}

.course-title {
    font-size: 17px;
    font-weight: 700;
    margin-bottom: 8px;
    color: var(--text);
}

.course-desc {
    font-size: 13px;
    color: var(--text-muted);
    margin-bottom: 16px;
    line-height: 1.5;
}

.course-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.course-price {
    font-size: 22px;
    font-weight: 800;
    color: var(--primary);
}

.course-price .original {
    font-size: 14px;
    text-decoration: line-through;
    color: var(--text-muted);
    margin-right: 6px;
}

/* ============================================
   CHAT SYSTEM
   ============================================ */
.chat-wrapper {
    display: flex;
    height: calc(100vh - 148px);
    overflow: hidden;
    border-radius: var(--radius);
    border: 1px solid var(--border);
    background: var(--white);
    box-shadow: var(--card-shadow);
}

.chat-sidebar {
    width: 300px;
    border-right: 1px solid var(--border);
    display: flex;
    flex-direction: column;
}

.chat-sidebar-header {
    padding: 18px 20px;
    border-bottom: 1px solid var(--border);
    font-weight: 700;
    font-size: 16px;
}

.chat-contacts {
    flex: 1;
    overflow-y: auto;
}

.chat-contact-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 18px;
    cursor: pointer;
    border-bottom: 1px solid rgba(209, 228, 246, .5);
    transition: var(--transition);
    position: relative;
}

.chat-contact-item:hover,
.chat-contact-item.active {
    background: var(--primary-pale);
}

.chat-contact-avatar {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--border);
    flex-shrink: 0;
}

.chat-contact-name {
    font-weight: 600;
    font-size: 14px;
}

.chat-contact-last {
    font-size: 12px;
    color: var(--text-muted);
    margin-top: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 150px;
}

.chat-unread {
    position: absolute;
    right: 14px;
    top: 14px;
    background: var(--primary);
    color: #fff;
    font-size: 10px;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.chat-main {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.chat-main-header {
    padding: 16px 20px;
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    gap: 12px;
    background: var(--bg2);
}

.chat-online-dot {
    width: 10px;
    height: 10px;
    background: #43A047;
    border-radius: 50%;
    margin-left: auto;
}

.chat-messages-area {
    flex: 1;
    overflow-y: auto;
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.chat-messages-area::-webkit-scrollbar {
    width: 5px;
}

.chat-messages-area::-webkit-scrollbar-thumb {
    background: var(--border);
    border-radius: 10px;
}

.chat-msg {
    display: flex;
    gap: 10px;
    max-width: 75%;
}

.chat-msg.outgoing {
    margin-left: auto;
    flex-direction: row-reverse;
}

.chat-msg-avatar {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
}

.chat-bubble {
    padding: 10px 16px;
    border-radius: 18px;
    font-size: 14px;
    line-height: 1.5;
    word-break: break-word;
}

.chat-msg.incoming .chat-bubble {
    background: var(--bg);
    border: 1px solid var(--border);
    border-top-left-radius: 4px;
}

.chat-msg.outgoing .chat-bubble {
    background: var(--primary);
    color: #fff;
    border-top-right-radius: 4px;
}

.chat-bubble img {
    max-width: 220px;
    border-radius: 10px;
    margin-top: 6px;
    cursor: pointer;
}

.chat-time {
    font-size: 11px;
    color: var(--text-muted);
    margin-top: 4px;
    text-align: right;
}

.chat-msg.outgoing .chat-time {
    color: rgba(255, 255, 255, .7);
}

.chat-input-area {
    padding: 16px 20px;
    border-top: 1px solid var(--border);
    display: flex;
    gap: 10px;
    align-items: flex-end;
    background: var(--white);
}

.chat-input {
    flex: 1;
    border: 1.5px solid var(--border);
    border-radius: 22px;
    padding: 10px 18px;
    font-size: 14px;
    outline: none;
    resize: none;
    max-height: 100px;
    font-family: var(--font-main);
    transition: var(--transition);
}

.chat-input:focus {
    border-color: var(--primary-light);
}

.chat-send-btn {
    width: 44px;
    height: 44px;
    background: var(--primary);
    color: #fff;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    transition: var(--transition);
    flex-shrink: 0;
}

.chat-send-btn:hover {
    background: var(--primary-dark);
    transform: scale(1.08);
}

.chat-file-btn {
    width: 44px;
    height: 44px;
    background: var(--bg);
    border: 1.5px solid var(--border);
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    color: var(--text-muted);
    transition: var(--transition);
}

.chat-file-btn:hover {
    background: var(--primary-pale);
    border-color: var(--primary-light);
    color: var(--primary);
}

/* ============================================
   LIVE CLASS - ANTI-SCREEN-RECORD
   ============================================ */
.live-frame-wrap {
    position: relative;
    background: #000;
    border-radius: var(--radius);
    overflow: hidden;
}

.live-watermark {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    pointer-events: none;
    z-index: 99;
    display: flex;
    align-items: center;
    justify-content: center;
}

.live-watermark span {
    color: rgba(255, 255, 255, .12);
    font-size: 22px;
    font-weight: 700;
    transform: rotate(-35deg);
    user-select: none;
    white-space: nowrap;
    text-shadow: 0 0 20px rgba(0, 0, 0, .5);
}

/* ============================================
   PORTAL (PUBLIC) PAGES
   ============================================ */
.portal-nav {
    background: var(--white);
    padding: 0 5%;
    height: 70px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    box-shadow: 0 2px 16px rgba(21, 101, 192, .08);
    position: sticky;
    top: 0;
    z-index: 999;
}

.portal-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-family: var(--font-heading);
    font-size: 22px;
    font-weight: 800;
    color: var(--primary);
}

.portal-logo .icon {
    font-size: 30px;
}

.portal-nav-links {
    display: flex;
    align-items: center;
    gap: 24px;
}

.portal-nav-links a {
    color: var(--text);
    font-weight: 600;
    text-decoration: none;
    transition: var(--transition);
}

.portal-nav-links a:hover {
    color: var(--primary);
}

.portal-nav-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 28px;
    color: var(--primary);
    cursor: pointer;
}

.hero-section {
    background: linear-gradient(135deg, #0D47A1 0%, #1565C0 60%, #42A5F5 100%);
    padding: 90px 5% 80px;
    color: #fff;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.hero-section::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    right: 0;
    height: 60px;
    background: var(--bg);
    clip-path: ellipse(55% 100% at 50% 100%);
}

.hero-title {
    font-size: clamp(34px, 5vw, 56px);
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 20px;
}

.hero-sub {
    font-size: 18px;
    color: rgba(255, 255, 255, .85);
    max-width: 600px;
    margin: 0 auto 36px;
}

/* Team Card */
.team-card {
    background: var(--white);
    border-radius: 20px;
    overflow: hidden;
    position: relative;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    transition: var(--transition);
    cursor: pointer;
    text-align: center;
}

.team-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(21, 101, 192, 0.15);
}

.team-photo-wrap {
    width: 100%;
    aspect-ratio: 1/1;
    overflow: hidden;
    position: relative;
}

.team-photo {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.team-card:hover .team-photo {
    transform: scale(1.05);
}

.team-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(13, 71, 161, 0.9), rgba(13, 71, 161, 0.3));
    opacity: 0;
    transition: opacity 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.team-card:hover .team-overlay {
    opacity: 1;
}

.team-overlay-content {
    transform: translateY(20px);
    opacity: 0;
    transition: all 0.4s ease;
}

.team-card:hover .team-overlay-content {
    transform: translateY(0);
    opacity: 1;
}

.team-portfolio-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: var(--white);
    color: var(--primary);
    padding: 10px 20px;
    border-radius: 50px;
    font-weight: 700;
    font-size: 14px;
    text-decoration: none;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    transition: var(--transition);
}

.team-portfolio-btn:hover {
    background: var(--primary-light);
    color: var(--white);
}

.team-info {
    padding: 24px 20px;
    border-top: 1px solid var(--border);
}

.team-name {
    font-family: var(--font-heading);
    color: var(--text);
    font-size: 20px;
    font-weight: 800;
    margin-bottom: 6px;
}

.team-role {
    color: var(--primary);
    font-size: 14px;
    font-weight: 600;
    margin: 0;
}

/* ============================================
   ANIMATIONS
   ============================================ */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(24px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in-up {
    animation: fadeInUp .5s ease both;
}

.delay-1 {
    animation-delay: .1s;
}

.delay-2 {
    animation-delay: .2s;
}

.delay-3 {
    animation-delay: .3s;
}

/* ============================================
   UTILITY
   ============================================ */
.text-primary {
    color: var(--primary) !important;
}

.text-muted-lms {
    color: var(--text-muted) !important;
}

.bg-pale {
    background: var(--primary-pale) !important;
}

.fw-700 {
    font-weight: 700;
}

.fw-800 {
    font-weight: 800;
}

.rounded-lms {
    border-radius: var(--radius) !important;
}

.gap-12 {
    gap: 12px;
}

.d-flex-center {
    display: flex;
    align-items: center;
    justify-content: center;
}

.w-100 {
    width: 100%;
}

.mb-4-lms {
    margin-bottom: 24px;
}

/* ============================================
   MOBILE BOTTOM NAV
   ============================================ */
.mobile-bottom-nav {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: var(--white);
    border-top: 1px solid var(--border);
    z-index: 1000;
    justify-content: space-around;
    align-items: center;
    padding: 6px 0;
    padding-bottom: calc(6px + env(safe-area-inset-bottom));
    box-shadow: 0 -4px 20px rgba(0, 0, 0, .08);
}

.mobile-nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2px;
    padding: 6px 8px;
    color: var(--text-muted);
    font-size: 10px;
    font-weight: 600;
    text-decoration: none;
    position: relative;
    transition: var(--transition);
    border-radius: 10px;
    min-width: 56px;
}

.mobile-nav-item i {
    font-size: 22px;
    transition: var(--transition);
}

.mobile-nav-item.active {
    color: var(--primary);
}

.mobile-nav-item.active i {
    transform: translateY(-2px);
}

.mobile-nav-item.active::after {
    content: '';
    position: absolute;
    top: -6px;
    left: 50%;
    transform: translateX(-50%);
    width: 24px;
    height: 3px;
    background: var(--primary);
    border-radius: 0 0 6px 6px;
}

.mobile-nav-badge {
    position: absolute;
    top: 0;
    right: 6px;
    background: #FF5252;
    color: #fff;
    font-size: 9px;
    font-weight: 700;
    min-width: 16px;
    height: 16px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 4px;
}

/* ============================================
   RESPONSIVE - TABLET (max 992px)
   ============================================ */
@media (max-width: 992px) {
    .lms-sidebar {
        transform: translateX(-100%);
        z-index: 1100;
    }

    .lms-sidebar.open {
        transform: translateX(0);
    }

    .lms-content {
        margin-left: 0;
    }

    .topbar-toggle {
        display: block;
    }

    .sidebar-overlay {
        display: none;
        position: fixed;
        inset: 0;
        background: rgba(0, 0, 0, .45);
        z-index: 1050;
    }

    .sidebar-overlay.open {
        display: block;
    }

    .page-content {
        padding: 20px;
    }

    .chat-sidebar {
        display: none;
    }

    .chat-sidebar.mobile-show {
        display: flex;
        width: 100%;
    }

    .chat-main {
        display: none;
    }

    .chat-main.mobile-show {
        display: flex;
        width: 100%;
    }

    .chat-wrapper {
        height: calc(100vh - 140px);
    }

    .auth-panel {
        padding: 32px 24px;
    }

    .lms-card-body {
        padding: 18px;
    }
}

/* ============================================
   RESPONSIVE - MOBILE (max 768px)
   ============================================ */
@media (max-width: 768px) {

    /* Portal Navbar */
    .portal-nav {
        padding: 0 16px;
        height: 60px;
    }

    .portal-logo {
        font-size: 18px;
    }

    .portal-logo .icon {
        font-size: 24px;
    }

    .portal-nav-toggle {
        display: block;
    }

    .portal-nav-links {
        display: none;
        position: absolute;
        top: 60px;
        left: 0;
        right: 0;
        background: var(--white);
        flex-direction: column;
        padding: 20px;
        gap: 16px;
        box-shadow: 0 10px 20px rgba(0, 0, 0, .1);
        border-top: 1px solid var(--border);
    }

    .portal-nav-links.open {
        display: flex;
    }

    .portal-nav-links a {
        width: 100%;
        text-align: center;
    }

    .portal-nav-links .btn-primary-lms {
        padding: 12px !important;
        font-size: 14px !important;
    }

    /* Hero */
    .hero-section {
        padding: 50px 5% 60px;
    }

    .hero-title {
        font-size: 28px !important;
    }

    .hero-sub {
        font-size: 15px;
        margin-bottom: 24px;
    }

    .hero-section .d-flex {
        gap: 10px !important;
    }

    .hero-section .btn-primary-lms,
    .hero-section .btn-outline-lms {
        padding: 12px 24px !important;
        font-size: 14px !important;
    }

    .hero-section::after {
        height: 30px;
    }

    /* Stats section */
    .stats-section {
        padding: 40px 5%;
    }

    .stat-num {
        font-size: 32px;
    }

    .stat-lbl {
        font-size: 12px;
    }

    /* Features / Sections */
    .features-section {
        padding: 50px 4%;
    }

    .courses-section {
        padding: 50px 4%;
    }

    .section-title {
        margin-bottom: 30px;
    }

    .section-title h2 {
        font-size: 26px;
    }

    .section-title p {
        font-size: 14px;
    }

    .apply-teacher-banner {
        padding: 50px 5%;
    }

    .apply-teacher-banner h2 {
        font-size: 26px !important;
    }

    /* Dashboard stat cards */
    .stat-card {
        padding: 16px;
        gap: 12px;
    }

    .stat-icon {
        width: 48px;
        height: 48px;
        font-size: 20px;
        border-radius: 12px;
    }

    .stat-value {
        font-size: 22px;
    }

    .stat-label {
        font-size: 12px;
    }

    /* Cards */
    .lms-card-header {
        padding: 14px 16px;
        flex-wrap: wrap;
        gap: 8px;
    }

    .lms-card-title {
        font-size: 15px;
    }

    .lms-card-body {
        padding: 16px;
    }

    /* Tables - horizontal scroll */
    .lms-table th {
        padding: 10px 12px;
        font-size: 11px;
        white-space: nowrap;
    }

    .lms-table td {
        padding: 10px 12px;
        font-size: 13px;
    }

    /* Topbar */
    .lms-topbar {
        padding: 0 14px;
        height: 58px;
    }

    .topbar-title {
        font-size: 16px;
    }

    .topbar-right {
        gap: 8px;
    }

    .topbar-icon-btn {
        width: 36px;
        height: 36px;
        font-size: 16px;
    }

    .topbar-avatar {
        width: 34px;
        height: 34px;
    }

    /* Forms */
    .lms-form-control {
        padding: 10px 14px;
        font-size: 14px;
    }

    .input-icon-wrap .lms-form-control {
        padding-left: 38px;
    }

    .search-filter-bar {
        padding: 16px;
        margin-bottom: 24px;
    }

    /* Buttons */
    .btn-primary-lms {
        padding: 10px 20px;
        font-size: 13px;
    }

    .btn-outline-lms {
        padding: 10px 18px;
        font-size: 13px;
    }

    /* Course cards */
    .course-thumbnail {
        height: 150px;
    }

    .course-body {
        padding: 16px;
    }

    .course-title {
        font-size: 15px;
    }

    .course-desc {
        font-size: 12px;
        margin-bottom: 12px;
    }

    .course-price {
        font-size: 19px;
    }

    .course-meta {
        flex-direction: column;
        gap: 12px;
        align-items: flex-start;
    }

    /* Chat */
    .chat-wrapper {
        height: calc(100vh - 120px);
        flex-direction: column;
    }

    .chat-input-area {
        padding: 10px 14px;
    }

    .chat-input {
        padding: 8px 14px;
        font-size: 13px;
    }

    .chat-send-btn {
        width: 40px;
        height: 40px;
        font-size: 18px;
    }

    .chat-file-btn {
        width: 40px;
        height: 40px;
        font-size: 18px;
    }

    .chat-bubble {
        padding: 8px 14px;
        font-size: 13px;
    }

    .chat-msg {
        max-width: 85%;
    }

    /* Upload zone */
    .upload-zone {
        padding: 24px 16px;
    }

    .upload-zone i {
        font-size: 32px;
    }

    /* OTP inputs */
    .otp-inputs {
        gap: 8px;
    }

    .otp-input {
        width: 46px;
        height: 50px;
        font-size: 20px;
    }

    /* Alerts */
    .lms-alert {
        padding: 12px 14px;
        font-size: 13px;
    }

    /* Footer */
    footer {
        padding: 30px 4%;
        font-size: 13px;
    }

    footer .d-flex {
        flex-wrap: wrap;
        gap: 12px !important;
    }
}

/* ============================================
   RESPONSIVE - SMALL MOBILE (max 480px)
   ============================================ */
@media (max-width: 480px) {
    .page-content {
        padding: 14px !important;
    }

    .lms-topbar {
        height: 52px;
    }

    .topbar-title {
        font-size: 14px;
        max-width: 140px;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .topbar-icon-btn {
        width: 32px;
        height: 32px;
        font-size: 15px;
        border-radius: 8px;
    }

    .topbar-avatar {
        width: 30px;
        height: 30px;
    }

    /* Hide some topbar icons on very small */
    .topbar-right .topbar-icon-btn[title="Profile"] {
        display: none;
    }

    /* Portal nav stacking */
    .portal-nav .btn-outline-lms:nth-child(2) {
        display: none;
    }

    /* Hero */
    .hero-title {
        font-size: 24px !important;
    }

    .hero-sub {
        font-size: 13px;
    }

    .hero-section {
        padding: 40px 4% 50px;
    }

    /* Stats */
    .stat-card {
        flex-direction: column;
        text-align: center;
        gap: 8px;
    }

    .stat-value {
        font-size: 20px;
    }

    .stat-label {
        font-size: 11px;
    }

    /* Cards */
    .lms-card-header {
        padding: 12px 14px;
    }

    .lms-card-body {
        padding: 14px;
    }

    .lms-card-title {
        font-size: 14px;
    }

    /* Badges */
    .badge-lms {
        font-size: 10px;
        padding: 3px 8px;
    }

    /* Tables compact */
    .lms-table th {
        padding: 8px 10px;
        font-size: 10px;
    }

    .lms-table td {
        padding: 8px 10px;
        font-size: 12px;
    }

    /* Course cards */
    .course-thumbnail {
        height: 130px;
    }

    .course-body {
        padding: 14px;
    }

    .course-title {
        font-size: 14px;
    }

    .course-price {
        font-size: 17px;
    }

    /* Auth pages */
    .auth-panel {
        padding: 24px 18px;
        border-radius: 18px;
    }

    .auth-logo .logo-icon {
        width: 56px;
        height: 56px;
        font-size: 26px;
    }

    .auth-logo h2 {
        font-size: 20px;
    }

    /* Forms */
    .lms-form-control {
        padding: 9px 12px;
    }

    .lms-form-label {
        font-size: 12px;
    }

    /* OTP */
    .otp-inputs {
        gap: 6px;
    }

    .otp-input {
        width: 40px;
        height: 44px;
        font-size: 18px;
        border-radius: 10px;
    }

    /* Buttons */
    .btn-primary-lms {
        padding: 9px 16px;
        font-size: 12px;
    }

    .btn-outline-lms {
        padding: 9px 14px;
        font-size: 12px;
    }
}

/* ============================================
   SCROLLBAR GLOBAL
   ============================================ */
::-webkit-scrollbar {
    width: 7px;
    height: 7px;
}

::-webkit-scrollbar-track {
    background: var(--bg);
}

::-webkit-scrollbar-thumb {
    background: var(--border);
    border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--primary-mid);
}

/* ============================================
   PRINT PROTECTION
   ============================================ */
@media print {
    body {
        display: none !important;
    }
}