:root {
    --app-bg: #f4f6fb;
    --app-card: #ffffff;
    --app-border: #e5e7eb;
    --app-text: #111827;
    --app-muted: #6b7280;
    --app-primary: #2563eb;
    --app-success: #16a34a;
}
body { background: var(--app-bg); color: var(--app-text); }
.app-navbar { background: linear-gradient(135deg, #111827, #1f2937); }
.page-header h1, .lesson-page h1 { font-weight: 750; }
.section-card { min-height: 140px; background: var(--app-card); border: 1px solid var(--app-border); border-radius: 18px; padding: 22px; text-decoration: none; color: var(--app-text); display: flex; justify-content: space-between; align-items: center; transition: .2s ease; box-shadow: 0 10px 25px rgba(15,23,42,.05); }
.section-card:hover { transform: translateY(-3px); border-color: #bfdbfe; box-shadow: 0 14px 35px rgba(15,23,42,.08); }
.section-title { font-size: 1.1rem; font-weight: 700; }
.section-meta { margin-top: 8px; color: var(--app-muted); }
.section-arrow { font-size: 1.5rem; color: var(--app-primary); }
.section-progress { height: 22px; border-radius: 999px; background: #e5e7eb; }
.section-progress .progress-bar, .translate-progress .progress-bar { background: var(--app-primary); }
.lesson-list { display: flex; flex-direction: column; gap: 12px; }
.lesson-card { background: var(--app-card); border: 1px solid var(--app-border); border-radius: 16px; padding: 16px; display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 16px; box-shadow: 0 8px 20px rgba(15,23,42,.04); color: var(--app-text); text-decoration: none; transition: border-color .18s ease, transform .18s ease, box-shadow .18s ease; }
.lesson-card:hover { color: var(--app-text); border-color: #93c5fd; transform: translateY(-1px); box-shadow: 0 10px 24px rgba(15,23,42,.07); }
.lesson-card:focus-visible { outline: 3px solid rgba(37,99,235,.28); outline-offset: 2px; }
.lesson-open { width: 36px; height: 36px; border-radius: 999px; display: grid; place-items: center; background: #eff6ff; color: var(--app-primary); font-size: 1.2rem; font-weight: 800; }
.lesson-main { display: flex; align-items: center; gap: 14px; min-width: 0; }
.lesson-icon { width: 42px; height: 42px; border-radius: 14px; background: #eff6ff; display: flex; align-items: center; justify-content: center; font-size: 1.25rem; flex-shrink: 0; }
.lesson-title { font-weight: 650; }
.lesson-number { color: var(--app-muted); }
.completion-status.completed { color: var(--app-success); font-weight: 800; }
.completion-status.not-completed { color: #9ca3af; }
.lesson-main-pane.full-width { width: min(100%, 1400px); margin: 0 auto; }
.player-card, .html-card, .ask-panel { background: var(--app-card); border: 1px solid var(--app-border); border-radius: 18px; padding: 16px; box-shadow: 0 12px 30px rgba(15,23,42,.06); }
.ask-panel { box-shadow: none; background: #f8fafc; }
.player-toolbar { display: flex; justify-content: space-between; align-items: end; gap: 16px; flex-wrap: wrap; margin-bottom: 14px; }
.control-group { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.control-group label { font-size: .9rem; color: var(--app-muted); }
.control-group select { min-width: 190px; }
.plyr { border-radius: 14px; overflow: hidden; }
video { width: 100%; background: #000; aspect-ratio: 16/9; }
video::cue { font-size: 82%; background: rgba(0,0,0,.42); color: white; text-shadow: 0 1px 2px black; }
iframe { width: 100%; height: 72vh; border: 1px solid var(--app-border); border-radius: 14px; background: #fff; }
.lesson-navigation { display: flex; justify-content: space-between; gap: 12px; }
.translation-panel { border: 1px dashed #bfdbfe; border-radius: 14px; background: #eff6ff; padding: 14px; }
.translate-progress { height: 18px; border-radius: 999px; }
.login-wrap { min-height: calc(100vh - 140px); display: grid; place-items: center; padding: 24px 0; }
.login-card { width: min(100%, 440px); background: var(--app-card); border: 1px solid var(--app-border); border-radius: 20px; padding: 28px; box-shadow: 0 18px 50px rgba(15,23,42,.10); }
.login-icon { font-size: 2rem; margin-bottom: 12px; }
.login-card h1 { font-size: 1.65rem; font-weight: 750; }
@media (max-width: 576px) {
    .lesson-card { padding: 14px; gap: 10px; }
    .lesson-open { width: 32px; height: 32px; }
    .lesson-navigation .btn { width: 100%; }
    .lesson-navigation { flex-direction: column; }
    .login-card { padding: 22px 18px; }
}
