/* EduDesk LMS — additions on top of the KiAdmin theme. Uses the theme's --primary / --dark / --white tokens. */
.lms-thumb { width:100%; aspect-ratio:16/9; border-radius:10px; background-size:cover; background-position:center; background-color:rgba(var(--dark),.06); }
.lms-thumb-ph { display:flex; align-items:center; justify-content:center; }
.lms-thumb-ph span { color:#fff; font-weight:800; font-size:clamp(20px,4vw,34px); letter-spacing:1px; opacity:.92; }
.lms-thumb-sm { width:64px; min-width:64px; aspect-ratio:16/10; border-radius:8px; background-size:cover; background-position:center; }
.lms-thumb-sm.lms-thumb-ph span { font-size:14px; }
.course-card { border-radius:14px; overflow:hidden; height:100%; display:flex; flex-direction:column; transition:box-shadow .15s, transform .15s; }
.course-card:hover { box-shadow:0 8px 24px rgba(var(--dark),.10); transform:translateY(-2px); }
.course-card .lms-thumb { border-radius:0; }
.course-card .card-body { display:flex; flex-direction:column; gap:6px; }
.course-card .course-title { font-weight:600; font-size:15px; line-height:1.3; color:rgba(var(--dark),1); text-decoration:none; }
.course-card .course-meta { font-size:12px; color:rgba(var(--dark),.6); display:flex; flex-wrap:wrap; gap:10px; }
.stretched-link-wrap { position:relative; }
.lms-chip { display:inline-flex; align-items:center; gap:4px; font-size:11px; padding:2px 8px; border-radius:999px; background:rgba(var(--primary),.08); color:rgb(var(--primary)); font-weight:600; }
.lms-hero { border-radius:16px; padding:22px; background:linear-gradient(135deg, rgba(var(--primary),.12), rgba(var(--primary),.03)); }
.lms-hero h3 { margin:0 0 6px; }

/* Curriculum lists */
.curr-module { border:1px solid rgba(var(--dark),.08); border-radius:12px; margin-bottom:10px; overflow:hidden; }
.curr-module > .curr-head { padding:10px 14px; background:rgba(var(--dark),.03); display:flex; justify-content:space-between; align-items:center; gap:8px; font-weight:600; }
.curr-lesson { display:flex; align-items:center; gap:10px; padding:9px 14px; border-top:1px solid rgba(var(--dark),.06); font-size:14px; color:inherit; text-decoration:none; }
a.curr-lesson:hover { background:rgba(var(--primary),.05); }
.curr-lesson.active { background:rgba(var(--primary),.10); font-weight:600; }
.curr-lesson .curr-ico { width:28px; height:28px; border-radius:8px; display:flex; align-items:center; justify-content:center; background:rgba(var(--dark),.05); flex-shrink:0; font-size:16px; }
.curr-lesson.done .curr-ico { background:#2e7d32; color:#fff; }
.curr-lesson.locked { opacity:.55; }

/* Lesson player */
.player-wrap { display:grid; grid-template-columns:minmax(0,1fr) 340px; gap:16px; align-items:start; }
@media (max-width: 1199px) { .player-wrap { grid-template-columns:1fr; } }
.player-stage { background:#000; border-radius:12px; overflow:hidden; aspect-ratio:16/9; }
.player-stage iframe, .player-stage video { width:100%; height:100%; border:0; display:block; }
.player-doc { border:1px solid rgba(var(--dark),.1); border-radius:12px; min-height:70vh; width:100%; }
.player-side { position:sticky; top:80px; max-height:calc(100vh - 100px); overflow:auto; }
.lesson-content { font-size:15px; line-height:1.7; }
.note-item { border-left:3px solid rgb(var(--primary)); padding:6px 10px; margin-bottom:8px; background:rgba(var(--primary),.04); border-radius:0 8px 8px 0; font-size:13px; }

/* Exam */
.exam-bar { position:sticky; top:64px; z-index:20; background:rgba(var(--white),1); border:1px solid rgba(var(--dark),.08); border-radius:12px; padding:10px 14px; display:flex; justify-content:space-between; align-items:center; gap:10px; flex-wrap:wrap; }
.exam-timer { font-size:22px; font-weight:700; font-variant-numeric:tabular-nums; }
.exam-timer.low { color:#d32f2f; }
.qnav { display:flex; flex-wrap:wrap; gap:6px; }
.qnav button { width:36px; height:36px; border-radius:8px; border:1px solid rgba(var(--dark),.15); background:transparent; font-weight:600; font-size:13px; color:inherit; }
.qnav button.answered { background:rgb(var(--primary)); border-color:rgb(var(--primary)); color:#fff; }
.qnav button.flagged { box-shadow:inset 0 -3px 0 #f0a500; }
.qnav button.current { outline:2px solid rgb(var(--primary)); outline-offset:1px; }
.q-card { display:none; }
.q-card.show { display:block; }
.q-option { display:flex; gap:10px; align-items:flex-start; padding:10px 12px; border:1px solid rgba(var(--dark),.12); border-radius:10px; margin-bottom:8px; cursor:pointer; }
.q-option:hover { border-color:rgba(var(--primary),.5); }
.q-option input { margin-top:3px; }
.ans-right { border-color:#2e7d32 !important; background:rgba(46,125,50,.08); }
.ans-wrong { border-color:#d32f2f !important; background:rgba(211,47,47,.06); }

/* Calendar */
.cal-grid { display:grid; grid-template-columns:repeat(7, minmax(0,1fr)); border-top:1px solid rgba(var(--dark),.08); border-left:1px solid rgba(var(--dark),.08); }
.cal-grid > div { border-right:1px solid rgba(var(--dark),.08); border-bottom:1px solid rgba(var(--dark),.08); min-height:104px; padding:4px; font-size:12px; }
.cal-grid .cal-dow { min-height:0; font-weight:600; text-align:center; background:rgba(var(--dark),.03); padding:6px 4px; }
.cal-grid .cal-out { background:rgba(var(--dark),.02); color:rgba(var(--dark),.4); }
.cal-grid .cal-today { background:rgba(var(--primary),.06); }
.cal-day-num { font-weight:600; margin-bottom:2px; }
.cal-ev { display:block; border-radius:5px; padding:1px 5px; margin-bottom:2px; font-size:11px; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; text-decoration:none; }
.cal-ev.ev-class { background:rgba(var(--primary),.14); color:rgb(var(--primary)); }
.cal-ev.ev-due { background:rgba(240,165,0,.18); color:#8a5b00; }
.cal-ev.ev-exam { background:rgba(211,47,47,.12); color:#b71c1c; }
.cal-ev.ev-holiday { background:rgba(46,125,50,.14); color:#1b5e20; }
.cal-ev.ev-cancelled { text-decoration:line-through; opacity:.6; }
@media (max-width: 767px) { .cal-grid > div { min-height:64px; } .cal-ev { font-size:9px; padding:0 3px; } }

/* Certificate */
.cert-sheet { width:100%; max-width:1050px; aspect-ratio:1.414/1; margin:0 auto; background:#fff; color:#1f2937; position:relative; padding:5% 7%; box-shadow:0 10px 40px rgba(0,0,0,.12); display:flex; flex-direction:column; justify-content:space-between; font-family:Georgia, 'Times New Roman', serif; }
.cert-sheet.classic { border:14px solid var(--cert); outline:2px solid var(--cert); outline-offset:-26px; }
.cert-sheet.modern { border-left:28px solid var(--cert); }
.cert-sheet.minimal { border:1px solid #e5e7eb; }
.cert-sheet h1 { font-size:clamp(20px,3.6vw,44px); color:var(--cert); letter-spacing:2px; text-transform:uppercase; margin:0; }
.cert-name { font-size:clamp(22px,4vw,48px); font-style:italic; border-bottom:1px solid #d1d5db; display:inline-block; padding:0 30px 6px; margin:8px 0; }
.cert-body { font-size:clamp(12px,1.6vw,18px); line-height:1.6; max-width:80%; margin:0 auto; }
.cert-foot { display:flex; justify-content:space-between; align-items:flex-end; gap:20px; font-family:Rubik, sans-serif; font-size:clamp(9px,1.1vw,13px); }
.cert-sign { text-align:center; min-width:30%; }
.cert-sign .line { border-top:1px solid #374151; padding-top:4px; margin-top:28px; }
.cert-qr canvas, .cert-qr img { width:clamp(60px,9vw,110px) !important; height:auto !important; }
@media print {
    body * { visibility:hidden !important; }
    .cert-print, .cert-print * { visibility:visible !important; }
    .cert-print { position:fixed; inset:0; margin:0; }
    .cert-sheet { box-shadow:none; max-width:none; width:100vw; height:100vh; aspect-ratio:auto; }
    @page { size:A4 landscape; margin:0; }
    .no-print { display:none !important; }
}
.invoice-sheet { max-width:820px; margin:0 auto; background:#fff; color:#1f2937; padding:36px; border-radius:12px; box-shadow:0 6px 24px rgba(0,0,0,.08); }
@media print { .invoice-print, .invoice-print * { visibility:visible !important; } .invoice-print { position:absolute; inset:0; } .invoice-sheet { box-shadow:none; } }

/* Misc */
.kpi-ring { --p:0; width:58px; height:58px; border-radius:50%; background:conic-gradient(rgb(var(--primary)) calc(var(--p)*1%), rgba(var(--dark),.08) 0); display:flex; align-items:center; justify-content:center; }
.kpi-ring span { background:rgba(var(--white),1); width:46px; height:46px; border-radius:50%; display:flex; align-items:center; justify-content:center; font-size:12px; font-weight:700; }
.att-btns .btn-check + .btn { padding:.15rem .5rem; font-size:12px; }
.empty-state { text-align:center; padding:40px 16px; color:rgba(var(--dark),.55); }
.empty-state i { font-size:44px; display:block; margin-bottom:8px; opacity:.6; }
.disc-post { border-left:2px solid rgba(var(--dark),.08); padding-left:12px; margin-left:6px; }
.mini-bar { display:flex; align-items:center; gap:6px; }
.mini-bar .bar { flex:1; height:6px; background:rgba(var(--dark),.08); border-radius:4px; overflow:hidden; }
.mini-bar .bar > i { display:block; height:100%; background:rgb(var(--primary)); }
.public-wrap { max-width:1180px; margin:0 auto; padding:24px 16px; }
.min-w-0{min-width:0!important}
