/* ==========================================================
   Tuấn Kiệt – Hệ thống quản lý khóa học
   Responsive, không phụ thuộc framework CSS
   ========================================================== */
:root {
  /* Màu chủ đạo: xanh logo Tuấn Kiệt + trắng, điểm nhấn vàng lúa */
  --brand: #1f3c88;
  --brand-dark: #0f2257;
  --brand-soft: #eaf0fb;
  --brand-600: #18306f; --brand-700: #0f2257; --brand-50: #eef3fc; --brand-100: #dbe6f8;
  --gold: #f2b53a; --gold-600: #c98f12; --gold-50: #fdf6e3;
  --ink: #16213a;
  --ink-2: #4f5b73;
  --ink-3: #8390a8;
  --line: #e2e8f2;
  --line-2: #f1f5fb;
  --bg: #f4f7fc;
  --card: #ffffff;
  --surface: #ffffff; --surface-2: #f8fafd;
  --ok: #1a7f37;
  --ok-soft: #e6f4ea;
  --warn: #9a6700;
  --warn-soft: #fff4d6;
  --danger: #b42318;
  --danger-soft: #fdecea;
  --info: #0b5cad;
  --info-soft: #e8f1fb;
  --radius: 12px;
  --shadow: 0 1px 2px rgba(15,34,87,.05), 0 4px 16px rgba(15,34,87,.06);
  --font: "Be Vietnam Pro", "Segoe UI", system-ui, -apple-system, sans-serif;
  --font-hanzi: "Noto Serif SC", "Songti SC", "SimSun", serif;
  color-scheme: light;
}

* { box-sizing: border-box; }
html, body { margin: 0; }
body { font-family: var(--font); color: var(--ink); background: var(--bg); line-height: 1.55; font-size: 15px; }
a { color: var(--brand); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; }
h1, h2, h3 { line-height: 1.25; margin: 0 0 .5em; }
h1 { font-size: clamp(1.6rem, 3vw + 1rem, 2.4rem); }
h2 { font-size: 1.35rem; }
h3 { font-size: 1.05rem; }
.muted { color: var(--ink-2); }
.small { font-size: .85rem; }
.container { width: 100%; max-width: 1180px; margin: 0 auto; padding: 0 16px; }
.hidden { display: none !important; }

/* ---------- Header ---------- */
.site-header { background: #fff; border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 50; }
.site-header .container { display: flex; align-items: center; gap: 16px; height: 62px; }
.logo { display: flex; align-items: center; gap: 10px; font-weight: 700; color: var(--ink); white-space: nowrap; }
.logo:hover { text-decoration: none; }
.logo-mark { width: 36px; height: 36px; border-radius: 9px; background: var(--brand); color: #fff; display: grid; place-items: center; font-size: 20px; }
.logo small { display: block; font-weight: 500; font-size: 11px; color: var(--ink-2); }
.nav { display: flex; gap: 4px; margin-left: auto; align-items: center; }
.nav a { color: var(--ink); padding: 8px 12px; border-radius: 8px; font-weight: 500; }
.nav a:hover, .nav a.active { background: var(--brand-soft); color: var(--brand-dark); text-decoration: none; }
.nav-toggle { display: none; margin-left: auto; background: none; border: 1px solid var(--line); border-radius: 8px; padding: 6px 10px; font-size: 20px; cursor: pointer; }
.user-chip { display: flex; align-items: center; gap: 8px; }
.avatar { width: 32px; height: 32px; border-radius: 50%; background: var(--gold); color: #fff; display: grid; place-items: center; font-weight: 700; font-size: 14px; }

@media (max-width: 1000px) {
  .nav-toggle { display: block; }
  .nav { display: none; position: absolute; top: 62px; left: 0; right: 0; background: #fff; flex-direction: column; align-items: stretch; padding: 8px 16px 16px; border-bottom: 1px solid var(--line); }
  .nav.open { display: flex; }
}

/* ---------- Buttons & form ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; border: 1px solid transparent; background: var(--brand); color: #fff; padding: 9px 16px; border-radius: 9px; font: inherit; font-weight: 600; cursor: pointer; transition: background .15s, transform .05s; white-space: nowrap; }
.btn:hover { background: var(--brand-dark); text-decoration: none; }
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: .55; cursor: not-allowed; }
.btn.secondary { background: #fff; color: var(--ink); border-color: var(--line); }
.btn.secondary:hover { background: #f1f5fb; }
.btn.ghost { background: transparent; color: var(--brand); }
.btn.ghost:hover { background: var(--brand-soft); }
.btn.danger { background: #fff; color: var(--danger); border-color: #f3c3bd; }
.btn.danger:hover { background: var(--danger-soft); }
.btn.sm { padding: 5px 10px; font-size: .85rem; border-radius: 7px; }
.btn.block { width: 100%; }

label { display: block; font-weight: 600; font-size: .88rem; margin-bottom: 4px; }
input, select, textarea { width: 100%; font: inherit; padding: 9px 11px; border: 1px solid #d0d5dd; border-radius: 9px; background: #fff; color: var(--ink); }
input:focus, select:focus, textarea:focus { outline: 2px solid rgba(31,60,136,.25); border-color: var(--brand); }
textarea { min-height: 80px; resize: vertical; }
.field { margin-bottom: 14px; }
.form-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 0 14px; }
.form-grid .full { grid-column: 1 / -1; }
@media (max-width: 600px) { .form-grid { grid-template-columns: 1fr; } }

/* ---------- Cards / layout ---------- */
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 20px; }
.section { padding: 32px 0; }
.section-head { display: flex; align-items: end; justify-content: space-between; gap: 12px; margin-bottom: 16px; flex-wrap: wrap; }
.grid { display: grid; gap: 16px; }
.grid.cols-3 { grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); }
.grid.cols-4 { grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); }
.row { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.spacer { flex: 1; }

/* ---------- Hero ---------- */
.hero { background: linear-gradient(135deg, #0f2257 0%, #1f3c88 60%, #2a5bd7 100%); color: #fff; padding: 48px 0 56px; position: relative; overflow: hidden; }
.hero::after { content: "学"; position: absolute; right: -20px; bottom: -80px; font-size: 320px; line-height: 1; opacity: .08; font-weight: 700; }
.hero p { max-width: 620px; opacity: .92; font-size: 1.05rem; }
.hero .btn.secondary { border-color: transparent; }
.hero-stats { display: flex; gap: 28px; margin-top: 24px; flex-wrap: wrap; }
.hero-stats b { display: block; font-size: 1.6rem; }

/* ---------- Course card ---------- */
.course-card { display: flex; flex-direction: column; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); transition: transform .15s, box-shadow .15s; }
.course-card:hover { transform: translateY(-2px); box-shadow: 0 8px 24px rgba(0,0,0,.08); }
.course-cover { height: 96px; display: flex; align-items: flex-end; justify-content: space-between; padding: 12px 14px; color: #fff; position: relative; }
.course-cover .hanzi { font-size: 44px; line-height: 1; font-weight: 700; opacity: .9; }
.course-body { padding: 14px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.course-body h3 { margin: 0; font-size: 1rem; }
.course-body h3 a { color: var(--ink); }
.course-meta { display: flex; gap: 10px; flex-wrap: wrap; font-size: .82rem; color: var(--ink-2); }
.course-foot { display: flex; align-items: center; justify-content: space-between; padding: 12px 14px; border-top: 1px solid var(--line); }
.price { font-weight: 700; color: var(--brand-dark); }
.tag { display: inline-block; font-size: .75rem; padding: 2px 8px; border-radius: 999px; background: #eef2f8; color: var(--ink-2); }
.badge { display: inline-block; font-size: .75rem; font-weight: 600; padding: 3px 9px; border-radius: 999px; background: #eef2f8; color: var(--ink-2); white-space: nowrap; }
.badge.ok { background: var(--ok-soft); color: var(--ok); }
.badge.warn { background: var(--warn-soft); color: var(--warn); }
.badge.danger { background: var(--danger-soft); color: var(--danger); }
.badge.info { background: var(--info-soft); color: var(--info); }
.badge.brand { background: var(--brand-soft); color: var(--brand-dark); }

/* ---------- Recommendation ---------- */
.rec-card .reasons { list-style: none; padding: 0; margin: 4px 0 0; font-size: .82rem; color: var(--ink-2); }
.rec-card .reasons li { padding-left: 18px; position: relative; margin-bottom: 3px; }
.rec-card .reasons li::before { content: "✓"; position: absolute; left: 0; color: var(--ok); font-weight: 700; }
.match { font-size: .78rem; font-weight: 700; background: rgba(255,255,255,.95); color: var(--brand-dark); padding: 3px 9px; border-radius: 999px; }
.score-bars { display: grid; grid-template-columns: auto 1fr; gap: 3px 8px; font-size: .72rem; color: var(--ink-2); margin-top: 6px; }
.score-bars .bar { height: 6px; background: #eee; border-radius: 3px; align-self: center; overflow: hidden; }
.score-bars .bar i { display: block; height: 100%; background: linear-gradient(90deg, var(--gold), var(--brand)); border-radius: 3px; }
.ai-banner { display: flex; align-items: center; gap: 10px; background: var(--brand-soft); color: var(--brand-dark); border-radius: 10px; padding: 10px 14px; font-size: .9rem; margin-bottom: 14px; }

/* ---------- Tables ---------- */
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; }
table { width: 100%; border-collapse: collapse; font-size: .9rem; }
th, td { padding: 10px 12px; text-align: left; border-bottom: 1px solid var(--line); vertical-align: middle; }
th { background: #f7f9fc; font-weight: 600; color: var(--ink-2); font-size: .8rem; text-transform: uppercase; letter-spacing: .02em; white-space: nowrap; }
tr:last-child td { border-bottom: none; }
tbody tr:hover { background: #f8fafd; }
td.actions { white-space: nowrap; text-align: right; }
td.num, th.num { text-align: right; font-variant-numeric: tabular-nums; }

/* ---------- Tabs ---------- */
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); margin-bottom: 18px; overflow-x: auto; }
.tabs button { background: none; border: none; font: inherit; padding: 10px 14px; cursor: pointer; color: var(--ink-2); font-weight: 600; border-bottom: 2px solid transparent; white-space: nowrap; }
.tabs button.active { color: var(--brand); border-bottom-color: var(--brand); }

/* ---------- Admin layout ---------- */
.admin { display: grid; grid-template-columns: 230px 1fr; min-height: calc(100vh - 62px); }
.sidebar { background: #fff; border-right: 1px solid var(--line); padding: 16px 10px; }
.sidebar button { display: flex; width: 100%; gap: 10px; align-items: center; background: none; border: none; font: inherit; padding: 10px 12px; border-radius: 8px; cursor: pointer; color: var(--ink); text-align: left; font-weight: 500; }
.sidebar button:hover { background: #f1f5fb; }
.sidebar button.active { background: var(--brand-soft); color: var(--brand-dark); font-weight: 600; }
.admin main { padding: 24px; min-width: 0; }
@media (max-width: 900px) {
  .admin { grid-template-columns: 1fr; }
  .sidebar { display: flex; overflow-x: auto; border-right: none; border-bottom: 1px solid var(--line); padding: 8px; }
  .sidebar button { width: auto; white-space: nowrap; }
  .admin main { padding: 16px; }
}
.stat-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 14px; margin-bottom: 20px; }
.stat { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; }
.stat .label { font-size: .8rem; color: var(--ink-2); }
.stat .value { font-size: 1.6rem; font-weight: 700; margin-top: 4px; font-variant-numeric: tabular-nums; }
.hbar { display: grid; grid-template-columns: minmax(90px, 160px) 1fr auto; gap: 8px; align-items: center; font-size: .85rem; margin-bottom: 8px; }
.hbar .track { height: 10px; background: #eef2f8; border-radius: 5px; overflow: hidden; }
.hbar .track i { display: block; height: 100%; background: linear-gradient(90deg, var(--brand), #3b8bf0); border-radius: 5px; }

/* ---------- Timetable ---------- */
.timetable { display: grid; grid-template-columns: repeat(7, minmax(120px, 1fr)); gap: 8px; overflow-x: auto; }
.tt-day { background: #fff; border: 1px solid var(--line); border-radius: 10px; min-height: 140px; }
.tt-day h4 { margin: 0; padding: 8px 10px; font-size: .85rem; border-bottom: 1px solid var(--line); background: #f7f9fc; border-radius: 10px 10px 0 0; }
.tt-slot { margin: 8px; padding: 8px; border-radius: 8px; background: var(--brand-soft); border-left: 3px solid var(--brand); font-size: .8rem; }
.tt-slot b { display: block; color: var(--brand-dark); }

/* ---------- Modal & toast ---------- */
.modal-backdrop { position: fixed; inset: 0; background: rgba(15,15,15,.45); display: grid; place-items: center; z-index: 100; padding: 16px; }
.modal { background: #fff; border-radius: 14px; width: 100%; max-width: 640px; max-height: calc(100vh - 32px); overflow: auto; box-shadow: 0 20px 60px rgba(0,0,0,.25); }
.modal header { display: flex; align-items: center; justify-content: space-between; padding: 16px 20px; border-bottom: 1px solid var(--line); }
.modal header h3 { margin: 0; }
.modal .body { padding: 20px; }
.modal footer { display: flex; justify-content: flex-end; gap: 8px; padding: 14px 20px; border-top: 1px solid var(--line); }
.close-x { background: none; border: none; font-size: 22px; cursor: pointer; color: var(--ink-2); }
#toasts { position: fixed; right: 16px; bottom: 16px; display: flex; flex-direction: column; gap: 8px; z-index: 200; }
.toast { background: var(--ink); color: #fff; padding: 11px 16px; border-radius: 10px; box-shadow: var(--shadow); max-width: 360px; font-size: .9rem; animation: slidein .2s ease-out; }
.toast.ok { background: var(--ok); }
.toast.err { background: var(--danger); }
@keyframes slidein { from { transform: translateY(10px); opacity: 0; } }

.empty { text-align: center; padding: 36px 16px; color: var(--ink-2); }
.skeleton { background: linear-gradient(90deg, #eee 25%, #f5f5f5 50%, #eee 75%); background-size: 200% 100%; animation: sk 1.2s infinite; border-radius: 10px; min-height: 220px; }
@keyframes sk { to { background-position: -200% 0; } }

.auth-wrap { min-height: calc(100vh - 62px); display: grid; place-items: center; padding: 32px 16px; }
.auth-card { width: 100%; max-width: 460px; }
.pager { display: flex; gap: 6px; justify-content: center; margin-top: 18px; }
.filters { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 10px; margin-bottom: 18px; }
@media (max-width: 700px) { .filters { grid-template-columns: 1fr 1fr; } .filters > :first-child { grid-column: 1 / -1; } }
.detail-grid { display: grid; grid-template-columns: 2fr 1fr; gap: 20px; }
@media (max-width: 860px) { .detail-grid { grid-template-columns: 1fr; } }
.class-item { border: 1px solid var(--line); border-radius: 10px; padding: 14px; margin-bottom: 10px; background: #fff; }
.site-footer { border-top: 1px solid var(--line); padding: 24px 0; margin-top: 32px; color: var(--ink-2); font-size: .85rem; background: #fff; }

/* ==========================================================
   GLASSMORPHISM – THEME XANH / TRẮNG (màu logo Tuấn Kiệt)
   Dùng tiền tố "html body" để ưu tiên hơn home.css / auth.css
   Luôn hiển thị giao diện sáng, kể cả khi máy bật chế độ tối
   ========================================================== */
:root, html body.home, html body .auth-page {
  --brand: #1f3c88; --brand-dark: #0f2257; --brand-soft: #eaf0fb;
  --brand-600: #18306f; --brand-700: #0f2257; --brand-50: #eef3fc; --brand-100: #dbe6f8;
  --gold: #f2b53a; --gold-600: #c98f12; --gold-50: #fdf6e3;
  --ink: #16213a; --ink-2: #4f5b73; --ink-3: #8390a8;
  --line: #e2e8f2; --line-2: #f1f5fb; --bg: #f4f7fc; --surface: #ffffff;
  --glass-bg: rgba(255, 255, 255, .55);
  --glass-bg-strong: rgba(255, 255, 255, .72);
  --glass-border: rgba(255, 255, 255, .65);
  --glass-blur: saturate(170%) blur(18px);
  --glass-shadow: 0 8px 32px -8px rgba(15, 34, 87, .18), inset 0 1px 0 rgba(255, 255, 255, .7);
}
html { color-scheme: light; }

/* ---------- Nền: các khối màu mờ cố định phía sau kính ---------- */
html body, html body.home { background: #f3f7fd; color: var(--ink); }
html body::before {
  content: ""; position: fixed; inset: -10%; z-index: -1; pointer-events: none;
  background:
    radial-gradient(38% 42% at 8% 12%, rgba(31, 60, 136, .26), transparent 70%),
    radial-gradient(34% 40% at 92% 8%, rgba(242, 181, 58, .28), transparent 70%),
    radial-gradient(40% 45% at 85% 78%, rgba(56, 132, 255, .22), transparent 70%),
    radial-gradient(38% 42% at 12% 88%, rgba(14, 165, 233, .16), transparent 70%),
    radial-gradient(30% 30% at 50% 50%, rgba(255, 255, 255, .7), transparent 70%);
  filter: blur(20px);
}

/* ---------- Bề mặt kính dùng chung ---------- */
html body .card, html body .course-card, html body .table-wrap, html body .stat, html body .class-item,
html body .tt-day, html body .filters, html body .tabs, html body .auth-card,
html body .hcourse, html body .hcat, html body .hclass, html body .hexam, html body .hrank, html body .hdoc,
html body .hstep, html body .hteacher, html body .htesti, html body .auth-shell, html body .auth-form {
  background: var(--glass-bg);
  -webkit-backdrop-filter: var(--glass-blur); backdrop-filter: var(--glass-blur);
  border: 1px solid var(--glass-border);
  box-shadow: var(--glass-shadow);
}
html body .card:hover, html body .course-card:hover, html body .hcourse:hover, html body .hcat:hover,
html body .hdoc:hover, html body .hteacher:hover, html body .htesti:hover, html body .hstep:hover {
  background: var(--glass-bg-strong);
  box-shadow: 0 18px 44px -14px rgba(15, 34, 87, .30), inset 0 1px 0 rgba(255, 255, 255, .8);
}

/* ---------- Header & thanh điều hướng ---------- */
html body .site-header, html body .hhead {
  background: rgba(255, 255, 255, .45);
  -webkit-backdrop-filter: saturate(180%) blur(20px); backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid var(--glass-border);
  box-shadow: 0 4px 24px -12px rgba(15, 34, 87, .25);
}
html body .hburger, html body .nav-toggle { background: var(--glass-bg); -webkit-backdrop-filter: var(--glass-blur); backdrop-filter: var(--glass-blur); }
html body .logo-mark { background: linear-gradient(145deg, var(--brand), var(--brand-dark)); box-shadow: inset 0 -2px 0 rgba(0,0,0,.18), 0 4px 12px -4px rgba(31, 60, 136, .55); }
@media (max-width: 1000px) { html body .nav { background: rgba(255, 255, 255, .92); -webkit-backdrop-filter: var(--glass-blur); backdrop-filter: var(--glass-blur); } }

/* ---------- Trang chủ: cho nền kính lộ ra giữa các section ---------- */
html body .hsec, html body .hsec.alt { background: transparent; }
html body .hstatbar { background: rgba(255, 255, 255, .4); -webkit-backdrop-filter: var(--glass-blur); backdrop-filter: var(--glass-blur); border-bottom: 1px solid var(--glass-border); }
html body .hstatbar .ic, html body .hcat .ic { background: rgba(255, 255, 255, .7); box-shadow: inset 0 1px 0 #fff, 0 4px 12px -6px rgba(31, 60, 136, .4); }
html body .hcat { background: linear-gradient(135deg, rgba(255,255,255,.7), color-mix(in srgb, var(--t) 60%, transparent)); }
html body .hclass, html body .hexam { background: rgba(232, 239, 251, .6); border-color: #d6e2f7; }
html body .hclass.alt, html body .hexam.alt { background: rgba(230, 244, 238, .55); border-color: #cfe7de; }
html body .hcourse .body, html body .hdoc .body { background: transparent; }
html body .course-foot { background: rgba(255, 255, 255, .35); }

/* Hero xanh kính */
html body .hhero {
  background: radial-gradient(900px 420px at 15% 0%, rgba(255,255,255,.14), transparent 60%),
              linear-gradient(120deg, rgba(11, 29, 77, .94) 0%, rgba(22, 48, 122, .92) 45%, rgba(42, 79, 184, .9) 100%);
}
html body .hform { background: rgba(255, 255, 255, .14); border: 1px solid rgba(255, 255, 255, .38); -webkit-backdrop-filter: saturate(160%) blur(22px); backdrop-filter: saturate(160%) blur(22px); box-shadow: 0 30px 60px -30px rgba(0,0,0,.5), inset 0 1px 0 rgba(255,255,255,.35); }
html body .hform input, html body .hform select { background-color: rgba(238, 243, 252, .92); }
html body .hbadge, html body .hstats > div, html body .hero-stats > div { -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); }

/* Chi tiết các khối trang chủ */
html body .hbtn-white:hover { background: #f1f6ff; }
html body .hstep .lv { box-shadow: 0 8px 18px -8px rgba(31, 60, 136, .7); }
html body .hteacher .ph { background: radial-gradient(circle at 30% 25%, #4a7be6, var(--brand-700)); box-shadow: 0 10px 24px -10px rgba(31, 60, 136, .7); }
html body .hdoc .cover.c0 { background: linear-gradient(135deg, #e6eefc, #c3d5f5); }
html body .hdoc .cover.c3 { background: linear-gradient(135deg, #2a4fb8, #0f2257); }
html body .htesti .q { color: #b9cdf2; }

/* Vinh danh: nền xanh kính, thẻ kính trắng */
html body .hsec.hhonor-sec {
  background: radial-gradient(600px 300px at 90% 0%, rgba(255,255,255,.14), transparent 60%),
              linear-gradient(120deg, rgba(12, 30, 80, .93), rgba(31, 60, 136, .9));
  -webkit-backdrop-filter: var(--glass-blur); backdrop-filter: var(--glass-blur);
}
html body .hhonor { background: rgba(255, 255, 255, .8); -webkit-backdrop-filter: var(--glass-blur); backdrop-filter: var(--glass-blur); border: 1px solid rgba(255, 255, 255, .7); }
html body .hhonor .who .av { background: radial-gradient(circle at 30% 25%, #4a7be6, #0f2257); }
html body .htabs button { -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); background: rgba(255, 255, 255, .1); }
html body .htabs button.active { background: #fff; }

/* Nút mũi tên + nút nổi */
html body .harrow { background: var(--glass-bg-strong); -webkit-backdrop-filter: var(--glass-blur); backdrop-filter: var(--glass-blur); border: 1px solid var(--glass-border); }
html body .harrow:hover { background: var(--brand); color: #fff; }
html body .hfloat a { -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); box-shadow: 0 10px 30px -8px rgba(0,0,0,.45), inset 0 1px 0 rgba(255,255,255,.35); }

/* CTA + Footer: xanh kính */
html body .hcta { background: rgba(15, 34, 87, .9); -webkit-backdrop-filter: var(--glass-blur); backdrop-filter: var(--glass-blur); }
html body .hfoot { background: rgba(22, 45, 110, .94); -webkit-backdrop-filter: var(--glass-blur); backdrop-filter: var(--glass-blur); }
html body .site-footer { background: var(--glass-bg); -webkit-backdrop-filter: var(--glass-blur); backdrop-filter: var(--glass-blur); border-top: 1px solid var(--glass-border); }

/* ---------- Nút bấm: phản chiếu kính ---------- */
html body .btn:not(.secondary):not(.ghost):not(.danger), html body .hbtn-primary {
  background-image: linear-gradient(180deg, rgba(255,255,255,.18), rgba(255,255,255,0) 55%);
  box-shadow: 0 8px 20px -8px rgba(31, 60, 136, .7), inset 0 1px 0 rgba(255, 255, 255, .35);
}
html body .btn.secondary, html body .hbtn-outline { background: var(--glass-bg-strong); -webkit-backdrop-filter: var(--glass-blur); backdrop-filter: var(--glass-blur); border-color: var(--glass-border); }

/* ---------- Form ---------- */
html body input:not([type=checkbox]):not([type=radio]), html body select, html body textarea {
  background-color: rgba(255, 255, 255, .7); color: var(--ink);
  border-color: rgba(31, 60, 136, .14);
  -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px);
}
html body input:focus, html body select:focus, html body textarea:focus { background-color: rgba(255, 255, 255, .92); }

/* ---------- Bảng ---------- */
html body th { background: rgba(255, 255, 255, .6); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); }
html body tbody tr:hover { background: rgba(255, 255, 255, .45); }
html body td, html body th { border-bottom-color: rgba(31, 60, 136, .07); }

/* ---------- Tabs, modal, toast ---------- */
html body .tabs button.active { box-shadow: 0 6px 16px -6px rgba(31, 60, 136, .6), inset 0 1px 0 rgba(255,255,255,.35); }
html body .modal, html body .hquiz { background: var(--glass-bg-strong); -webkit-backdrop-filter: saturate(180%) blur(24px); backdrop-filter: saturate(180%) blur(24px); border: 1px solid var(--glass-border); }
html body .modal header, html body .modal footer { background: rgba(255, 255, 255, .35); }
html body .modal-backdrop, html body .hquiz-backdrop { background: rgba(10, 20, 45, .38); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }
html body .hquiz header { background: linear-gradient(120deg, #0f2257, #2a4fb8); }
html body .hquiz .qbody { background: transparent; }
html body .qitem { background: rgba(255, 255, 255, .5); }
html body .qitem.ok { border-color: #9fd3b8; background: #f2faf5; }
html body .qitem.bad { border-color: #f1b3bd; background: #fff5f6; } /* câu sai vẫn giữ đỏ nhạt */
html body .toast { -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px); background: rgba(22, 33, 58, .86); }
html body .toast.ok { background: rgba(19, 97, 59, .88); }
html body .toast.err { background: rgba(161, 32, 26, .88); }

/* ---------- Quản trị ---------- */
html body .sidebar { background: rgba(12, 26, 66, .82); -webkit-backdrop-filter: saturate(160%) blur(20px); backdrop-filter: saturate(160%) blur(20px); border-right: 1px solid rgba(255,255,255,.08); }
html body .sidebar button { color: rgba(255, 255, 255, .82); }
html body .sidebar button:hover { background: rgba(255, 255, 255, .08); color: #fff; }
html body .sidebar button.active { background: linear-gradient(90deg, rgba(56, 100, 220, .95), rgba(56, 100, 220, .6)); color: #fff; box-shadow: 0 6px 16px -8px rgba(56, 100, 220, .9); }
html body .admin main { background: transparent; }
html body .tt-slot { -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }

/* ---------- Đăng nhập / Đăng ký ---------- */
html body .auth-page { background: transparent; }
html body .auth-shell { background: rgba(255, 255, 255, .42); }
html body .auth-brand { background: linear-gradient(160deg, rgba(226, 236, 252, .8), rgba(226, 236, 252, .35)); border-color: var(--glass-border); }
html body .auth-brand::before { background: radial-gradient(circle, rgba(31, 60, 136, .16), transparent 65%); }
html body .auth-brand::after { color: rgba(31, 60, 136, .06); }
html body .auth-form { background: rgba(255, 255, 255, .5); border: none; box-shadow: none; }
html body .auth-features .ic { background: rgba(255, 255, 255, .75); -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); box-shadow: 0 4px 12px -6px rgba(31, 60, 136, .45); }
html body .input-icon input, html body .input-icon select { background-color: rgba(255, 255, 255, .78); }
html body .input-icon input:focus, html body .input-icon select:focus { box-shadow: 0 0 0 3px rgba(31, 60, 136, .15); }

/* Trình duyệt không hỗ trợ backdrop-filter: dùng nền đặc hơn để vẫn dễ đọc */
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  :root { --glass-bg: rgba(255, 255, 255, .92); --glass-bg-strong: rgba(255, 255, 255, .97); }
}

/* ==========================================================
   MENU TÀI KHOẢN (avatar + dropdown) – dùng cho mọi trang
   ========================================================== */
.umenu { position: relative; }
.umenu-btn { display: inline-flex; align-items: center; gap: 8px; padding: 4px 10px 4px 4px; border-radius: 999px; border: 1px solid var(--line); background: rgba(255, 255, 255, .75); font: inherit; font-weight: 700; font-size: .92rem; color: var(--ink); cursor: pointer; max-width: 220px; }
.umenu-btn:hover, .umenu.open .umenu-btn { border-color: var(--brand); }
.umenu-btn > svg { width: 16px; height: 16px; color: var(--ink-2); flex-shrink: 0; transition: transform .15s; }
.umenu.open .umenu-btn > svg { transform: rotate(180deg); }
.uname { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.uav { width: 32px; height: 32px; border-radius: 50%; overflow: hidden; flex-shrink: 0; display: grid; place-items: center; color: #fff; font-weight: 800; font-size: .9rem; background: radial-gradient(circle at 30% 25%, #4a7be6, var(--brand-dark, #0f2257)); }
.uav img { width: 100%; height: 100%; object-fit: cover; display: block; }
.umenu-pop { position: absolute; right: 0; top: calc(100% + 10px); width: 260px; z-index: 90; padding: 8px; border-radius: 14px; display: none;
  background: rgba(255, 255, 255, .96); border: 1px solid var(--line); box-shadow: 0 20px 50px -16px rgba(15, 34, 87, .35);
  -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px); }
.umenu.open .umenu-pop { display: block; animation: umIn .14s ease-out; }
@keyframes umIn { from { opacity: 0; transform: translateY(-6px); } }
.umenu-head { padding: 10px 10px 12px; border-bottom: 1px solid var(--line); margin-bottom: 6px; display: grid; gap: 2px; justify-items: start; }
.umenu-head b { font-size: .98rem; }
.umenu-head small { color: var(--ink-2); font-size: .8rem; margin-bottom: 6px; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
.umenu .lvchip { display: inline-flex; align-items: center; gap: 4px; font-size: .74rem; font-weight: 700; padding: 3px 10px; border-radius: 999px;
  color: var(--lv, var(--brand)); background: color-mix(in srgb, var(--lv, var(--brand)) 12%, #fff); border: 1px solid color-mix(in srgb, var(--lv, var(--brand)) 25%, transparent); }
.umenu-pop a, .umenu-pop button { display: flex; align-items: center; gap: 10px; width: 100%; padding: 9px 10px; border-radius: 9px; border: none; background: none; font: inherit; font-size: .92rem; font-weight: 500; color: var(--ink); cursor: pointer; text-align: left; text-decoration: none; }
.umenu-pop a:hover, .umenu-pop button:hover { background: var(--brand-soft, #eaf0fb); color: var(--brand); text-decoration: none; }
.umenu-pop svg { width: 18px; height: 18px; flex-shrink: 0; }
.umenu-pop .out { color: #d92d20; }
.umenu-pop .out:hover { background: #fdecea; color: #d92d20; }
.umenu-pop .cnt { margin-left: auto; min-width: 20px; height: 20px; padding: 0 6px; border-radius: 999px; background: var(--brand); color: #fff; font-size: .72rem; font-weight: 800; display: inline-grid; place-items: center; }
.umenu-pop .cnt[hidden] { display: none; }
.nav .umenu { margin-left: 4px; }
@media (max-width: 1000px) {
  .hhead.open .hactions .umenu { flex: 1; }
  .hhead.open .hactions .umenu-btn { width: 100%; max-width: none; }
  .hhead.open .hactions .umenu-pop { position: static; width: auto; margin-top: 8px; box-shadow: none; }
}
@media (max-width: 1000px) {
  .nav .umenu { margin: 6px 0 0; }
  .nav .umenu-btn { width: 100%; max-width: none; }
  .nav .umenu-pop { position: static; width: auto; margin-top: 8px; box-shadow: none; }
}
.site-footer .branches { display: flex; flex-wrap: wrap; gap: 4px 14px; }
html body .hnav a { white-space: nowrap; }

/* ==========================================================
   HỌC PHÍ & CHI TIẾT KHÓA HỌC (dữ liệu từ file "Thông tin khóa học")
   ========================================================== */
.price-old { color: var(--ink-3); font-size: .82rem; font-weight: 500; margin-left: 4px; }
.home .hprice s { white-space: nowrap; color: var(--ink-3, #8390a8); font-size: .82rem; font-weight: 500; margin-left: 6px; }
.cd-aside { display: grid; gap: 16px; align-content: start; }
@media (min-width: 861px) { .cd-price { position: sticky; top: 84px; } }
.cd-facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; margin: 16px 0 6px; }
.cd-facts > div { padding: 10px 12px; border-radius: 10px; background: var(--brand-soft, #eaf0fb); }
.cd-facts small { display: block; color: var(--ink-2); font-size: .76rem; }
.cd-facts b { font-size: .95rem; color: var(--brand-dark, #0f2257); }
.cd-book { margin: 10px 0 0; font-size: .92rem; }
.cd-block { margin-top: 16px; }
.cd-block h3 { margin: 0 0 12px; }
.cd-syl { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; counter-reset: q; }
.cd-syl li { display: grid; grid-template-columns: 92px minmax(0, 1fr); gap: 10px; align-items: start; padding-bottom: 12px; border-bottom: 1px dashed var(--line); }
.cd-syl li:last-child { border-bottom: none; padding-bottom: 0; }
.cd-syl li > b { color: var(--brand); font-size: .9rem; padding-top: 3px; }
.cd-syl li > div { display: flex; flex-wrap: wrap; gap: 6px; }
.cd-syl li > div span { font-size: .84rem; padding: 4px 10px; border-radius: 999px; background: rgba(255, 255, 255, .7); border: 1px solid var(--line); }
.cd-syl li:not(:has(> b)) { grid-template-columns: 1fr; }
.cd-promo ul { margin: 0 0 8px; padding-left: 0; list-style: none; display: grid; gap: 8px; }
.cd-promo li { position: relative; padding-left: 26px; font-size: .92rem; }
.cd-promo li::before { content: "✓"; position: absolute; left: 0; top: 0; width: 18px; height: 18px; border-radius: 50%; background: var(--ok-soft); color: var(--ok); font-size: .72rem; font-weight: 800; display: grid; place-items: center; }
.p-seg { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 4px; padding: 4px; border-radius: 10px; background: var(--brand-soft, #eaf0fb); margin-bottom: 14px; }
.p-seg button { border: none; background: transparent; font: inherit; font-size: .88rem; font-weight: 700; color: var(--ink-2); padding: 8px; border-radius: 8px; cursor: pointer; }
.p-seg button.on { background: #fff; color: var(--brand); box-shadow: 0 2px 8px -3px rgba(15, 34, 87, .3); }
.p-old { display: flex; justify-content: space-between; color: var(--ink-2); font-size: .88rem; }
.p-old s { color: var(--ink-3); }
.p-main { margin: 6px 0 12px; }
.p-main small { display: block; color: var(--ink-2); font-size: .8rem; }
.p-main b { display: block; font-size: 1.7rem; font-weight: 800; color: var(--brand); line-height: 1.2; font-variant-numeric: tabular-nums; }
.p-main .save { display: inline-block; margin-top: 4px; font-size: .76rem; font-weight: 700; color: var(--ok); background: var(--ok-soft); padding: 2px 8px; border-radius: 999px; }
.p-inst { border: 1px dashed var(--line); border-radius: 10px; padding: 10px 12px; font-size: .88rem; display: grid; gap: 4px; font-variant-numeric: tabular-nums; }
.p-inst .h { display: flex; justify-content: space-between; font-weight: 700; }
.p-inst .r { display: flex; justify-content: space-between; color: var(--ink-2); }
/* Nhập Excel (quản trị) */
.imp-drop { border: 2px dashed var(--line); border-radius: 12px; padding: 22px; text-align: center; color: var(--ink-2); background: rgba(255, 255, 255, .6); }
.imp-drop.over { border-color: var(--brand); background: var(--brand-soft, #eaf0fb); }
.imp-warn { background: var(--warn-soft); color: var(--warn); border-radius: 10px; padding: 10px 14px; font-size: .86rem; margin: 12px 0; }
.imp-warn ul { margin: 4px 0 0; padding-left: 18px; }
.imp-table td, .imp-table th { font-size: .82rem; padding: 7px 8px; }
.imp-table .new { color: var(--ok); font-weight: 700; }
html body td.num { white-space: nowrap; }

/* ==========================================================
   FORM GIÁO VIÊN (quản trị) – chia nhóm như mẫu
   ========================================================== */
html body .modal.tform { max-width: 1280px; width: 100%; padding: 0; overflow: hidden; display: flex; flex-direction: column; background: #f4f6fa; }
.tform .tform-head { background: linear-gradient(100deg, #0f2257, #2f5fd0); color: #fff; padding: 14px 20px; border: none; }
.tform .tform-head h3 { color: #fff; font-size: 1rem; display: flex; align-items: center; gap: 8px; margin: 0; }
.tform .tform-head h3 svg { width: 20px; height: 20px; }
.tform .tform-head .close-x { color: rgba(255,255,255,.85); }
.tform .body { overflow-y: auto; padding: 14px 16px; display: grid; gap: 12px; }
.tsec { background: #fff; border: 1px solid #e3e8f0; border-radius: 8px; padding: 12px 14px 14px; }
.tsec h4 { margin: 0 0 12px; padding-bottom: 10px; border-bottom: 1px solid #edf0f5; font-size: .88rem; font-weight: 700; display: flex; align-items: center; gap: 7px; color: #1c2536; }
.tsec h4 svg { width: 15px; height: 15px; color: #2f5fd0; flex-shrink: 0; }
.tsec h4.tog { cursor: pointer; user-select: none; }
.tsec h4 .chev { display: inline-flex; transition: transform .2s; }
.tsec h4 .chev svg { color: #64748b; width: 14px; height: 14px; }
.tsec:not(.open) h4 .chev { transform: rotate(180deg); }
.tsec:not(.open) h4.tog { margin-bottom: 0; padding-bottom: 0; border-bottom: none; }
.tsec:not(.open) .tmore { display: none; }
.tgrid { display: grid; gap: 12px 12px; }
.tgrid.c3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.tgrid.c4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.tf { min-width: 0; }
.tf.full { margin-top: 12px; }
.tf label { display: block; font-size: .78rem; font-weight: 500; color: #334155; margin-bottom: 5px; }
.tf .req { color: #dc2626; font-weight: 700; }
html body .tform .tf input:not([type=checkbox]), html body .tform .tf select, html body .tform .tf textarea {
  width: 100%; height: 36px; padding: 6px 10px; font: inherit; font-size: .84rem; color: #1c2536; background: #fff;
  border: 1px solid #d5dbe5; border-radius: 6px; -webkit-backdrop-filter: none; backdrop-filter: none; box-shadow: none; }
html body .tform .tf textarea { height: auto; min-height: 64px; resize: vertical; }
html body .tform .tf input::placeholder, html body .tform .tf textarea::placeholder { color: #9aa4b2; }
html body .tform .tf input:focus, html body .tform .tf select:focus, html body .tform .tf textarea:focus { outline: none; border-color: #2f5fd0; box-shadow: 0 0 0 3px rgba(47, 95, 208, .15); }
html body .tform .tf input[readonly] { background: #f5f7fa; color: #475569; }
.tcopy { display: flex; }
html body .tform .tcopy input { border-radius: 6px 0 0 6px !important; }
.tcopy button { width: 38px; flex-shrink: 0; border: 1px solid #d5dbe5; border-left: none; border-radius: 0 6px 6px 0; background: #f8fafc; color: #64748b; cursor: pointer; display: grid; place-items: center; }
.tcopy button:hover { color: #2f5fd0; }
.tcopy button svg { width: 15px; height: 15px; }
.tchk { display: flex !important; align-items: center; gap: 6px; margin: 6px 0 0 !important; font-size: .76rem !important; color: #64748b !important; cursor: pointer; }
.tchk input { width: 14px; height: 14px; margin: 0; }
.tform .tform-foot { background: #f4f6fa; border-top: 1px solid #e3e8f0; padding: 12px 16px; display: flex; justify-content: flex-end; gap: 10px; }
.tform .tform-foot .btn { font-size: .84rem; padding: 8px 16px; border-radius: 6px; }
.tform .tform-foot .btn svg { width: 15px; height: 15px; }
html body .tform .tform-foot .btn:not(.tbtn-cancel) { background: #2f5fd0; }
html body .tform .tform-foot .tbtn-cancel { background: #64748b; color: #fff; border: none; box-shadow: none; }
.cred { display: grid; gap: 8px; background: var(--brand-soft, #eaf0fb); border-radius: 10px; padding: 12px 14px; }
.cred small { display: block; color: var(--ink-2); font-size: .76rem; }
.cred b { font-size: 1rem; word-break: break-all; }
@media (max-width: 900px) { .tgrid.c3, .tgrid.c4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .tgrid.c3, .tgrid.c4 { grid-template-columns: 1fr; } html body .modal.tform { max-height: 100vh; border-radius: 0; } }

/* ==========================================================
   QUẢN LÝ NGƯỜI DÙNG (quản trị)
   ========================================================== */
.um-page { display: grid; gap: 16px; }
.um-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.um-title { display: flex; align-items: center; gap: 14px; }
.um-title .ic { width: 52px; height: 52px; border-radius: 14px; background: linear-gradient(135deg, #2f5fd0, #0f2257); color: #fff; display: grid; place-items: center; flex-shrink: 0; }
.um-title .ic svg { width: 26px; height: 26px; }
.um-title h2 { margin: 0; font-size: 1.5rem; }
.um-title p { margin: 2px 0 0; color: var(--ink-2); font-size: .9rem; }
.um-add, .um-go { display: inline-flex; align-items: center; justify-content: center; gap: 8px; border: none; border-radius: 10px; background: #1f3c88; color: #fff; font: inherit; font-weight: 700; padding: 11px 20px; cursor: pointer; }
.um-add:hover, .um-go:hover { background: #0f2257; }
.um-add svg, .um-go svg { width: 17px; height: 17px; }
.um-stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.um-stat, .um-card { background: #fff; border: 1px solid #e5e9f0; border-radius: 14px; }
.um-stat { display: flex; align-items: center; gap: 16px; padding: 20px 24px; }
.um-stat .i { width: 48px; height: 48px; border-radius: 12px; display: grid; place-items: center; flex-shrink: 0; }
.um-stat .i svg { width: 24px; height: 24px; }
.um-stat .i.b { background: #eef2ff; color: #4f46e5; } .um-stat .i.g { background: #e7f7ee; color: #16a34a; } .um-stat .i.r { background: #fdecec; color: #dc2626; }
.um-stat b { display: block; font-size: 1.6rem; line-height: 1.1; }
.um-stat small { color: var(--ink-2); font-size: .9rem; }
.um-tabs { display: flex; gap: 6px; padding: 14px 18px; flex-wrap: wrap; }
.um-tabs button { border: none; background: transparent; font: inherit; font-weight: 600; color: #475569; padding: 8px 14px; border-radius: 8px; cursor: pointer; display: inline-flex; align-items: center; gap: 6px; }
.um-tabs button:hover { background: #f1f5fb; }
.um-tabs button .n { background: #eef1f5; color: #475569; font-size: .74rem; padding: 1px 8px; border-radius: 999px; }
.um-tabs button.on { background: #1f3c88; color: #fff; }
.um-tabs button.on .n { background: rgba(255,255,255,.22); color: #fff; }
.um-filter { display: grid; grid-template-columns: 2.2fr 1fr 1.6fr auto auto; gap: 14px; align-items: end; padding: 18px 20px; }
.um-filter label { display: block; font-size: .86rem; font-weight: 500; margin-bottom: 6px; color: #1c2536; }
html body .um-filter input, html body .um-filter select { height: 40px; border-radius: 8px; border: 1px solid #d5dbe5; background: #fff; font-size: .92rem; -webkit-backdrop-filter: none; backdrop-filter: none; }
.um-search { position: relative; }
.um-search svg { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); width: 17px; height: 17px; color: #64748b; }
html body .um-search input { padding-left: 38px; }
.um-go { height: 40px; min-width: 150px; }
.um-x { height: 40px; width: 48px; border: 1px solid #d5dbe5; background: #fff; border-radius: 8px; font-size: 1.3rem; color: #64748b; cursor: pointer; }
.um-table { background: #fff; border: 1px solid #e5e9f0; border-radius: 12px; overflow-x: auto; }
.um-table table { width: 100%; border-collapse: collapse; min-width: 980px; }
html body .um-table th { background: linear-gradient(90deg, #0f2257, #1f3c88); color: #fff; text-align: left; font-size: .78rem; font-weight: 700; letter-spacing: .03em; text-transform: uppercase; padding: 14px 16px; border: none; -webkit-backdrop-filter: none; backdrop-filter: none; }
.um-table td { padding: 14px 16px; border-bottom: 1px solid #edf0f5; vertical-align: middle; }
html body .um-table tbody tr:hover { background: #f5f8ff; }
.um-table tr.off td { opacity: .6; }
.um-id { color: #64748b; font-variant-numeric: tabular-nums; }
.um-who { display: flex; align-items: center; gap: 14px; }
.um-who b { display: block; font-size: .98rem; font-weight: 600; }
.um-mail { display: inline-flex; align-items: center; gap: 6px; color: #64748b; font-size: .86rem; }
.um-cp { border: none; background: none; padding: 0; color: #94a3b8; cursor: pointer; display: inline-grid; }
.um-cp:hover { color: #2f5fd0; }
.um-cp svg { width: 14px; height: 14px; }
.um-me { font-size: .7rem; background: #e0e7ff; color: #3730a3; padding: 1px 7px; border-radius: 999px; vertical-align: middle; }
.uav-img { border-radius: 10px; display: grid; place-items: center; font-weight: 700; overflow: hidden; flex-shrink: 0; }
.uav-img img { width: 100%; height: 100%; object-fit: cover; }
.ubadge { display: inline-flex; align-items: center; gap: 4px; font-size: .76rem; font-weight: 700; padding: 3px 9px; border-radius: 6px; white-space: nowrap; }
.r-sa { background: #fee2e2; color: #b91c1c; } .r-ad { background: #dbe6f8; color: #2a4fb8; } .r-mg { background: #e0f2fe; color: #0369a1; }
.r-sl { background: #dcfce7; color: #15803d; } .r-ac { background: #fef3c7; color: #b45309; } .r-tc { background: #ede9fe; color: #6d28d9; }
.um-br { display: flex; flex-wrap: wrap; gap: 6px; }
.um-br span { font-size: .76rem; font-weight: 600; color: #2a4fb8; background: #eef3fc; padding: 3px 9px; border-radius: 6px; white-space: nowrap; }
.um-st { display: inline-flex; align-items: center; gap: 7px; color: #64748b; white-space: nowrap; }
.um-st::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: #94a3b8; }
.um-st.on { color: #1c2536; } .um-st.on::before { background: #16a34a; }
.um-last { color: #64748b; white-space: nowrap; font-size: .9rem; }
.um-last svg { width: 14px; height: 14px; vertical-align: -2px; }
.um-dots { display: inline-flex; align-items: center; gap: 4px; border: 1px solid #d5dbe5; background: #fff; border-radius: 8px; padding: 6px 12px; cursor: pointer; color: #475569; }
.um-dots svg { width: 14px; height: 14px; }
.um-dots svg + svg { width: 11px; height: 11px; }
.um-pop { position: absolute; z-index: 300; min-width: 200px; background: #fff; border: 1px solid #e5e9f0; border-radius: 10px; box-shadow: 0 16px 40px -12px rgba(15, 34, 87, .35); padding: 6px; }
.um-pop button { display: block; width: 100%; text-align: left; border: none; background: none; font: inherit; font-size: .9rem; padding: 9px 12px; border-radius: 7px; cursor: pointer; color: #1c2536; }
.um-pop button:hover { background: #f1f5fb; }
.um-pop button.danger { color: #dc2626; }
/* Form thêm / sửa */
.uf-grid { display: grid; grid-template-columns: minmax(0, 2fr) minmax(280px, 1fr); gap: 22px; align-items: start; }
.uf { display: grid; gap: 16px; }
.uf-card { background: #fff; border: 1px solid #edf0f5; border-radius: 14px; padding: 20px 22px; }
.uf-card h4 { display: flex; align-items: center; gap: 10px; margin: 0 0 14px; font-size: 1rem; }
.uf-card h4 small { font-weight: 400; }
.hic { width: 32px; height: 32px; border-radius: 8px; display: grid; place-items: center; flex-shrink: 0; }
.hic svg { width: 16px; height: 16px; }
.hic.b { background: #e0ecff; color: #2f5fd0; } .hic.g { background: #e7f7ee; color: #16a34a; } .hic.y { background: #fdf2dc; color: #d97706; }
.uf-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px 16px; }
.uf-f label { display: block; font-size: .88rem; font-weight: 500; color: #475569; margin-bottom: 6px; }
.uf-f .req { color: #dc2626; }
.uf-lbl2 { display: flex !important; justify-content: space-between; gap: 8px; }
.uf-lbl2 a { color: #2f5fd0; font-weight: 500; }
html body .uf input:not([type=checkbox]), html body .uf select { height: 42px; width: 100%; border: 1px solid #d5dbe5; border-radius: 8px; padding: 8px 14px; font: inherit; font-size: .95rem; background: #fff; color: #1c2536; -webkit-backdrop-filter: none; backdrop-filter: none; }
html body .uf input:focus, html body .uf select:focus { outline: none; border-color: #2f5fd0; box-shadow: 0 0 0 3px rgba(47, 95, 208, .15); }
html body .uf select:disabled { background: #f5f7fa; color: #64748b; }
.uf-hint { display: block; margin-top: 6px; color: #64748b; font-size: .8rem; }
.uf-grp { display: flex; }
html body .uf-grp input { border-radius: 8px 0 0 8px !important; }
.uf-grp button { width: 46px; flex-shrink: 0; border: 1px solid #d5dbe5; border-left: none; background: #fff; color: #64748b; cursor: pointer; display: grid; place-items: center; }
.uf-grp button:last-child { border-radius: 0 8px 8px 0; }
.uf-grp button[data-gen] { color: #2f5fd0; border-color: #93b4f5; }
.uf-grp button svg { width: 17px; height: 17px; }
.msel { position: relative; }
.msel-box { width: 100%; min-height: 42px; border: 1px solid #d5dbe5; border-radius: 8px; background: #fff; padding: 6px 12px; display: flex; flex-wrap: wrap; gap: 6px; align-items: center; text-align: left; cursor: pointer; font: inherit; }
.msel.open .msel-box { border-color: #2f5fd0; box-shadow: 0 0 0 3px rgba(47, 95, 208, .15); }
.msel-box .ph { color: #94a3b8; font-size: .95rem; }
.msel-box .chip { font-size: .8rem; font-weight: 600; color: #2a4fb8; background: #eef3fc; padding: 3px 9px; border-radius: 6px; }
.msel-pop { display: none; position: absolute; left: 0; right: 0; top: calc(100% + 4px); z-index: 20; background: #fff; border: 1px solid #e5e9f0; border-radius: 10px; box-shadow: 0 14px 36px -12px rgba(15, 34, 87, .3); padding: 6px; max-height: 260px; overflow-y: auto; }
.msel.open .msel-pop { display: block; }
.msel-pop label { display: flex !important; align-items: center; gap: 10px; padding: 8px 10px; margin: 0 !important; border-radius: 7px; cursor: pointer; color: #1c2536 !important; }
.msel-pop label:hover { background: #f1f5fb; }
.msel-pop input { width: 16px; height: 16px; margin: 0; }
.uf-ava { display: flex; align-items: center; gap: 18px; }
.uf-ava .uav-img { border-radius: 50%; font-size: 1.8rem; }
.uf-pick { display: inline-flex; align-items: center; gap: 6px; border: 1px solid #2f5fd0; color: #2f5fd0; background: #fff; border-radius: 999px; padding: 5px 12px; font: inherit; font-size: .88rem; font-weight: 600; cursor: pointer; }
.uf-pick svg { width: 15px; height: 15px; }
.uf-rm { border: none; background: none; color: #dc2626; font: inherit; font-size: .84rem; cursor: pointer; margin-left: 6px; }
.uf-actions { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.uf-back { display: inline-flex; align-items: center; gap: 6px; border: none; background: #eef1f5; border-radius: 8px; padding: 10px 18px; font: inherit; font-weight: 600; cursor: pointer; color: #1c2536; }
.uf-back svg, .uf-submit svg { width: 18px; height: 18px; }
.uf-submit { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-width: 220px; border: none; background: #2a4fb8; color: #fff; border-radius: 999px; padding: 12px 28px; font: inherit; font-weight: 700; cursor: pointer; }
.uf-submit:hover { background: #1f3c88; }
.uf-submit:disabled { opacity: .6; }
.uf-guide { position: sticky; top: 84px; }
.uf-cap { font-size: .74rem; font-weight: 700; letter-spacing: .05em; color: #64748b; margin: 4px 0 10px; }
.uf-role { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 8px; margin-bottom: 8px; font-size: .9rem; color: #475569; }
.uf-role .pill { font-size: .76rem; font-weight: 700; padding: 3px 12px; border-radius: 999px; color: #fff; min-width: 90px; text-align: center; }
.uf-role.r-sa .pill { background: #dc2626; } .uf-role.r-ad .pill { background: #2f5fd0; } .uf-role.r-mg .pill { background: #0284c7; }
.uf-role.r-sl .pill { background: #16a34a; } .uf-role.r-ac .pill { background: #f5b301; color: #3b2a00; }
.uf-note { margin-top: 16px; border: 1px dashed #cbd5e1; border-radius: 10px; padding: 12px 16px; font-size: .88rem; color: #475569; }
.uf-note b:first-child { display: flex; align-items: center; gap: 6px; color: #1c2536; }
.uf-note b:first-child svg { width: 16px; height: 16px; color: #d97706; }
.uf-note ul { margin: 8px 0 0; padding-left: 20px; display: grid; gap: 4px; }
@media (max-width: 1100px) { .uf-grid { grid-template-columns: 1fr; } .uf-guide { position: static; } .um-filter { grid-template-columns: 1fr 1fr; } }
@media (max-width: 640px) { .um-stats, .uf-row, .um-filter { grid-template-columns: 1fr; } .uf-actions { flex-direction: column-reverse; align-items: stretch; } .uf-submit { min-width: 0; } }

/* ==========================================================
   KHUNG TRANG QUẢN TRỊ – sidebar xanh + thanh trên, nền phẳng
   (tắt hiệu ứng kính trong khu quản trị)
   ========================================================== */
html body.admin-app { background: #f3f5f9; color: #1c2536; }
html body.admin-app::before { display: none; }
html body.admin-app .card, html body.admin-app .table-wrap, html body.admin-app .stat, html body.admin-app .class-item,
html body.admin-app .tt-day, html body.admin-app .filters, html body.admin-app .tabs {
  background: #fff; border: 1px solid #e5e9f0; box-shadow: 0 1px 2px rgba(16, 24, 40, .04); -webkit-backdrop-filter: none; backdrop-filter: none; }
html body.admin-app .card:hover { background: #fff; box-shadow: 0 1px 2px rgba(16, 24, 40, .04); }
html body.admin-app .btn:not(.secondary):not(.ghost):not(.danger) { background-image: none; box-shadow: none; background-color: #1f3c88; }
html body.admin-app .btn:not(.secondary):not(.ghost):not(.danger):hover { background-color: #0f2257; }
html body.admin-app .btn.secondary { background: #fff; border-color: #d5dbe5; -webkit-backdrop-filter: none; backdrop-filter: none; }
html body.admin-app input:not([type=checkbox]):not([type=radio]), html body.admin-app select, html body.admin-app textarea {
  background-color: #fff; border-color: #d5dbe5; -webkit-backdrop-filter: none; backdrop-filter: none; }
html body.admin-app th { background: #f7f9fc; -webkit-backdrop-filter: none; backdrop-filter: none; }
html body.admin-app tbody tr:hover { background: #f7f9fc; }
html body.admin-app .modal { background: #fff; -webkit-backdrop-filter: none; backdrop-filter: none; }
html body.admin-app .modal header, html body.admin-app .modal footer { background: #fff; }
html body.admin-app .modal-backdrop { background: rgba(15, 23, 42, .45); -webkit-backdrop-filter: none; backdrop-filter: none; }
html body.admin-app .toast { -webkit-backdrop-filter: none; backdrop-filter: none; }

.adm { --side-w: 250px; display: grid; grid-template-columns: var(--side-w) minmax(0, 1fr); min-height: 100vh; }
.adm.collapsed { --side-w: 68px; }
/* ----- Sidebar ----- */
.adm-side { position: sticky; top: 0; height: 100vh; overflow-y: auto; background: linear-gradient(180deg, #1f3c88 0%, #0f2257 100%); color: #fff; display: flex; flex-direction: column; scrollbar-width: thin; scrollbar-color: rgba(255,255,255,.25) transparent; z-index: 60; }
.adm-brand { display: flex; align-items: center; gap: 8px; padding: 16px 14px 14px 18px; }
.adm-logo { flex: 1; min-width: 0; display: flex; align-items: center; gap: 10px; color: #fff; text-decoration: none; }
.adm-logo:hover { text-decoration: none; }
.adm-logo svg { width: 26px; height: 26px; flex-shrink: 0; }
.adm-logo b { font-size: 1.08rem; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.adm-collapse { width: 32px; height: 28px; border-radius: 7px; border: 1px solid rgba(255,255,255,.35); background: rgba(255,255,255,.1); color: #fff; display: grid; place-items: center; cursor: pointer; flex-shrink: 0; }
.adm-collapse svg { width: 16px; height: 16px; }
.adm-nav { padding: 6px 10px 20px; }
.adm-grp { margin-top: 10px; }
.adm-grp-h { width: 100%; display: flex; align-items: center; justify-content: space-between; border: none; background: none; color: rgba(255,255,255,.72); font: inherit; font-size: .72rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; padding: 10px 8px 6px; cursor: pointer; }
.adm-grp-h:hover { color: #fff; }
.adm-grp-h .caret { width: 14px; height: 14px; transition: transform .15s; }
.adm-grp.closed .adm-grp-h .caret { transform: rotate(-90deg); }
.adm-grp.closed .adm-grp-b { display: none; }
.adm-grp-b button { width: 100%; display: flex; align-items: center; gap: 11px; border: none; background: none; color: #fff; font: inherit; font-size: .9rem; font-weight: 600; padding: 10px 10px; border-radius: 8px; cursor: pointer; text-align: left; }
.adm-grp-b button svg { width: 18px; height: 18px; flex-shrink: 0; opacity: .92; }
.adm-grp-b button span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.adm-grp-b button:hover { background: rgba(255,255,255,.1); }
.adm-grp-b button.active { background: rgba(255,255,255,.18); box-shadow: inset 3px 0 0 #fff; }
.adm.collapsed .adm-logo b, .adm.collapsed .adm-grp-h span, .adm.collapsed .adm-grp-b button span { display: none; }
.adm.collapsed .adm-brand { flex-direction: column; padding: 14px 8px; }
.adm.collapsed .adm-logo { flex: none; }
.adm.collapsed .adm-grp-h { justify-content: center; padding: 8px 0; border-top: 1px solid rgba(255,255,255,.15); }
.adm.collapsed .adm-grp-h .caret { display: none; }
.adm.collapsed .adm-grp.closed .adm-grp-b { display: block; }
.adm.collapsed .adm-grp-b button { justify-content: center; padding: 11px 0; }
.adm-shade { display: none; }
/* ----- Thanh trên ----- */
.adm-main { display: flex; flex-direction: column; min-width: 0; }
.adm-top { position: sticky; top: 0; z-index: 50; display: flex; align-items: center; gap: 12px; height: 62px; padding: 0 20px; background: #fff; border-bottom: 1px solid #e5e9f0; }
.adm-spacer { flex: 1; }
.adm-burger { display: none !important; }
.adm-icon-btn { position: relative; width: 38px; height: 38px; border: none; background: none; border-radius: 9px; color: #475569; display: grid; place-items: center; cursor: pointer; }
.adm-icon-btn:hover { background: #f1f5f9; }
.adm-icon-btn svg { width: 21px; height: 21px; }
.adm-icon-btn .cnt { position: absolute; top: 3px; right: 2px; min-width: 17px; height: 17px; padding: 0 4px; border-radius: 999px; background: #ef4444; color: #fff; font-size: .66rem; font-weight: 700; display: grid; place-items: center; }
.adm-dd { position: relative; }
.adm-drop-btn { display: inline-flex; align-items: center; gap: 8px; border: none; background: none; font: inherit; color: #1c2536; cursor: pointer; padding: 6px 8px; border-radius: 9px; }
.adm-drop-btn:hover { background: #f1f5f9; }
.adm-drop-btn svg { width: 17px; height: 17px; color: #475569; flex-shrink: 0; }
.adm-drop-btn .caret { width: 14px; height: 14px; }
.adm-branch .adm-drop-btn b { font-weight: 700; font-size: .95rem; white-space: nowrap; }
.adm-drop { display: none; position: absolute; top: calc(100% + 6px); left: 0; min-width: 220px; background: #fff; border: 1px solid #e5e9f0; border-radius: 10px; box-shadow: 0 16px 40px -12px rgba(15, 23, 42, .28); padding: 6px; z-index: 80; }
.adm-drop.right { left: auto; right: 0; }
.adm-dd.open > .adm-drop { display: block; }
.adm-drop > button, .adm-drop > a { width: 100%; display: flex; align-items: center; gap: 10px; border: none; background: none; font: inherit; font-size: .9rem; color: #1c2536; padding: 9px 10px; border-radius: 7px; cursor: pointer; text-align: left; text-decoration: none; }
.adm-drop > button:hover, .adm-drop > a:hover, .adm-drop > button.on { background: #f1f5fb; }
.adm-drop > button.on { color: #1f3c88; font-weight: 600; }
.adm-drop > button svg, .adm-drop > a svg { width: 17px; height: 17px; color: #64748b; flex-shrink: 0; }
.adm-drop > button span small { display: block; color: #64748b; font-size: .76rem; }
.adm-drop .danger { color: #dc2626 !important; } .adm-drop .danger svg { color: #dc2626; }
.adm-drop-head { padding: 8px 10px 10px; border-bottom: 1px solid #eef1f5; margin-bottom: 4px; }
.adm-drop-head b { display: block; } .adm-drop-head small { color: #64748b; font-size: .8rem; }
.adm-drop-empty { padding: 14px 10px; color: #64748b; font-size: .88rem; text-align: center; }
.adm-clock { display: flex; align-items: center; gap: 9px; border: 1px solid #e5e9f0; border-radius: 999px; padding: 4px 16px 4px 6px; background: #fff; }
.adm-clock .ic { width: 30px; height: 30px; padding: 5px; border-radius: 50%; background: #2f5fd0; color: #fff; }
.adm-clock small { display: block; font-size: .68rem; color: #475569; line-height: 1.2; }
.adm-clock small b { color: #2f5fd0; margin-right: 6px; }
.adm-clock span { font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace; font-size: .9rem; font-weight: 600; color: #1f3c88; letter-spacing: .03em; display: inline-flex; align-items: center; gap: 6px; }
.adm-clock .live { width: 7px; height: 7px; border-radius: 50%; background: #22c55e; animation: admPulse 1.6s infinite; }
@keyframes admPulse { 50% { opacity: .35; } }
.adm-search { display: flex; align-items: center; gap: 8px; border: 1px solid #e5e9f0; border-radius: 9px; padding: 0 8px 0 10px; height: 38px; width: 230px; background: #fff; }
.adm-search .ic { width: 16px; height: 16px; color: #64748b; flex-shrink: 0; }
html body.admin-app .adm-search input { border: none !important; box-shadow: none !important; padding: 0; height: 100%; font-size: .88rem; background: transparent; min-width: 0; flex: 1; }
.adm-search kbd { font: inherit; font-size: .72rem; color: #64748b; border: 1px solid #e5e9f0; border-radius: 5px; padding: 0 6px; }
.adm-search .adm-drop { left: 0; right: 0; min-width: 280px; }
.adm-me .av { width: 34px; height: 34px; border-radius: 50%; background: #fce7f3; color: #be185d; display: grid; place-items: center; font-weight: 700; }
.adm-me .who { display: grid; justify-items: start; gap: 2px; text-align: left; }
.adm-me .who b { font-size: .88rem; line-height: 1.1; max-width: 180px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.adm-me .ubadge { font-size: .66rem; padding: 1px 7px; }
.adm-me .ubadge svg, .ubadge svg { width: 12px; height: 12px; color: currentColor; }
.adm-user .adm-drop { min-width: 240px; }
/* ----- Nội dung & footer ----- */
.adm-content { flex: 1; padding: 20px 24px 28px; min-width: 0; }
.adm-content > .section-head h2, .adm-content h2 { font-size: 1.4rem; }
.adm-foot { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin: 0 24px 16px; padding: 14px 18px; border-radius: 10px; background: #e9edf4; color: #475569; font-size: .84rem; }
.um-tabs button svg { width: 16px; height: 16px; }
.um-pop button svg { width: 16px; height: 16px; vertical-align: -3px; margin-right: 6px; color: #64748b; }
.um-pop button.danger svg { color: #dc2626; }
/* ----- Màn hình nhỏ ----- */
@media (max-width: 1100px) { .adm-search { width: 180px; } .adm-clock small { display: none; } }
@media (max-width: 900px) {
  .adm, .adm.collapsed { grid-template-columns: minmax(0, 1fr); }
  .adm-side { position: fixed; left: 0; top: 0; bottom: 0; width: 260px; transform: translateX(-100%); transition: transform .2s; }
  .adm.open .adm-side { transform: none; }
  .adm.open .adm-shade { display: block; position: fixed; inset: 0; background: rgba(15, 23, 42, .4); z-index: 55; }
  .adm.collapsed .adm-logo b, .adm.collapsed .adm-grp-h span, .adm.collapsed .adm-grp-b button span { display: inline; }
  .adm-collapse { display: none; }
  .adm-burger { display: grid !important; }
  .adm-clock, .adm-search kbd { display: none; }
  .adm-top { padding: 0 12px; gap: 6px; }
  .adm-search { width: auto; flex: 1; max-width: 220px; }
  .adm-spacer { display: none; }
  .adm-me .who { display: none; }
  .adm-content { padding: 16px 12px 24px; }
  .adm-foot { margin: 0 12px 12px; }
}
@media (max-width: 560px) { .adm-branch .adm-drop-btn b { max-width: 110px; overflow: hidden; text-overflow: ellipsis; } .adm-search { display: none; } }

/* Khu quản trị: tiêu đề mọi bảng nền xanh, chữ trắng (đồng bộ với bảng Người dùng) */
html body.admin-app .adm-content table th,
html body.admin-app .modal table th {
  background: linear-gradient(90deg, #0f2257, #1f3c88);
  color: #fff;
  font-size: .78rem;
  font-weight: 700;
  letter-spacing: .03em;
  text-transform: uppercase;
  white-space: nowrap;
  padding: 13px 14px;
  border-bottom: none;
}
html body.admin-app .adm-content .table-wrap,
html body.admin-app .modal .table-wrap { overflow: auto; border-radius: 12px; }

/* Phân trang bảng (khu quản trị) */
.tpager { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin: 12px 2px 4px; font-size: .88rem; color: #475569; }
.tpager .btns { display: flex; align-items: center; gap: 6px; }
.tpager button { min-width: 36px; height: 36px; padding: 0 10px; border: 1px solid #d5dbe5; background: #fff; border-radius: 8px; font: inherit; font-weight: 600; color: #1c2536; cursor: pointer; }
.tpager button:hover:not(:disabled) { border-color: #1f3c88; color: #1f3c88; }
.tpager button.on { background: #1f3c88; border-color: #1f3c88; color: #fff; }
.tpager button:disabled { opacity: .4; cursor: default; }
.tpager .gap { padding: 0 4px; color: #94a3b8; }

/* ==========================================================
   QUẢN LÝ LỚP HỌC – danh sách + form tạo / sửa lớp
   ========================================================== */
.cl-page { display: grid; gap: 16px; }
.cl-page svg { flex-shrink: 0; }
.cl-hero { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; padding: 22px 26px; border-radius: 18px; color: #fff; background: linear-gradient(100deg, #2a4fb8, #2f5fd0 55%, #4a7be6); box-shadow: 0 10px 30px -12px rgba(42, 79, 184, .55); }
.cl-hero .ic { width: 52px; height: 52px; border-radius: 14px; background: rgba(255,255,255,.18); display: grid; place-items: center; }
.cl-hero .ic svg { width: 26px; height: 26px; }
.cl-hero h2 { margin: 0; font-size: 1.45rem; color: #fff; }
.cl-hero p { margin: 3px 0 0; font-size: .9rem; opacity: .9; }
.cl-hero .acts { margin-left: auto; display: flex; gap: 10px; flex-wrap: wrap; }
.cl-hbtn { display: inline-flex; align-items: center; gap: 7px; border: 1px solid rgba(255,255,255,.45); background: rgba(255,255,255,.12); color: #fff; font: inherit; font-weight: 600; font-size: .9rem; padding: 10px 16px; border-radius: 10px; cursor: pointer; }
.cl-hbtn:hover, .cl-hbtn.on { background: rgba(255,255,255,.26); }
.cl-hbtn.solid { background: #fff; color: #2a4fb8; border-color: #fff; }
.cl-hbtn.solid:hover { background: #eef3fc; }
.cl-hbtn svg { width: 17px; height: 17px; }
.cl-card { background: #fff; border: 1px solid #e5e9f0; border-radius: 14px; }
.cl-stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
.cl-stat { display: flex; align-items: center; gap: 16px; padding: 18px 20px; background: #fff; border: 1px solid #e5e9f0; border-left: 4px solid #2f5fd0; border-radius: 14px; }
.cl-stat.g { border-left-color: #16a34a; } .cl-stat.y { border-left-color: #f59e0b; } .cl-stat.p { border-left-color: #2a4fb8; }
.cl-stat .i { width: 46px; height: 46px; border-radius: 12px; display: grid; place-items: center; background: #eef2ff; color: #2a4fb8; }
.cl-stat.g .i { background: #e7f7ee; color: #16a34a; } .cl-stat.y .i { background: #fef3c7; color: #d97706; } .cl-stat.p .i { background: #e0ecff; color: #2a4fb8; }
.cl-stat .i svg { width: 22px; height: 22px; }
.cl-stat small { display: block; font-size: .74rem; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: #475569; }
.cl-stat b { display: block; font-size: 1.7rem; line-height: 1.2; color: #0f172a; }
.cl-stat em { display: flex; align-items: center; gap: 5px; font-style: normal; font-size: .8rem; color: #64748b; }
.cl-stat em svg { width: 13px; height: 13px; }
.cl-bar { display: flex; align-items: center; gap: 14px; padding: 12px 14px; flex-wrap: wrap; }
.cl-search { position: relative; flex: 1 1 320px; max-width: 460px; }
.cl-search svg { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); width: 17px; height: 17px; color: #64748b; }
html body.admin-app .cl-search input { padding-left: 38px; height: 40px; width: 100%; }
.cl-tabs { display: flex; gap: 8px; flex-wrap: wrap; margin-left: auto; }
.cl-tabs button { display: inline-flex; align-items: center; gap: 6px; border: 1px solid #e2e8f0; background: #fff; border-radius: 999px; padding: 7px 14px; font: inherit; font-size: .86rem; font-weight: 600; color: #334155; cursor: pointer; }
.cl-tabs button svg { width: 15px; height: 15px; }
.cl-tabs button .n { background: #eef1f5; color: #475569; font-size: .72rem; padding: 1px 8px; border-radius: 999px; }
.cl-tabs button.zero { color: #94a3b8; }
.cl-tabs button.on { background: #2a4fb8; border-color: #2a4fb8; color: #fff; box-shadow: 0 6px 16px -6px rgba(42, 79, 184, .6); }
.cl-tabs button.on .n { background: rgba(255,255,255,.25); color: #fff; }
.cl-rev { padding: 16px 18px; }
.cl-rev-top { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; padding-bottom: 14px; border-bottom: 1px solid #edf0f5; }
.cl-rev-h { display: flex; align-items: center; gap: 12px; }
.cl-rev-h .i { width: 40px; height: 40px; border-radius: 10px; background: #e7f7ee; color: #16a34a; display: grid; place-items: center; }
.cl-rev-h .i svg { width: 20px; height: 20px; }
.cl-rev-h b { display: block; }
.cl-rev-h small { color: #64748b; font-size: .78rem; }
.cl-chip { display: inline-flex; align-items: center; gap: 5px; border: 1px solid #d5dbe5; background: #fff; border-radius: 8px; padding: 6px 10px; font: inherit; font-size: .8rem; font-weight: 600; color: #334155; cursor: pointer; margin-left: 8px; }
.cl-chip svg { width: 13px; height: 13px; }
.cl-rev-dates { display: flex; align-items: flex-end; gap: 10px; flex-wrap: wrap; }
.cl-rev-dates label { display: grid; gap: 4px; font-size: .74rem; font-weight: 600; color: #475569; }
html body.admin-app .cl-rev-dates input { height: 40px; width: 150px; }
.cl-quick { display: flex; gap: 6px; flex-wrap: wrap; }
.cl-quick button { height: 40px; border: 1px solid #bfd3fb; background: #fff; color: #2a4fb8; border-radius: 8px; padding: 0 12px; font: inherit; font-size: .8rem; font-weight: 700; cursor: pointer; }
.cl-quick button:hover { background: #eef3fc; }
.cl-rev-bot { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; padding-top: 12px; font-size: .84rem; }
.cl-rev-bot small { display: inline-flex; align-items: center; gap: 5px; }
.cl-rev-bot small svg { width: 13px; height: 13px; }
html body.admin-app .cl-rev-bot select { height: 38px; width: 240px; }
.cl-sortlbl { display: inline-flex; align-items: center; gap: 5px; color: #475569; font-weight: 600; }
.cl-sortlbl svg { width: 14px; height: 14px; }
.cl-switch { display: inline-flex; align-items: center; gap: 8px; cursor: pointer; font-weight: 600; color: #334155; user-select: none; }
.cl-switch { position: relative; }
html body .cl-switch input, html body .cl-days input { position: absolute; opacity: 0; pointer-events: none; width: 1px !important; height: 1px !important; padding: 0 !important; left: 0; top: 0; }
.cl-switch i { width: 36px; height: 20px; border-radius: 999px; background: #cbd5e1; position: relative; transition: background .2s; flex-shrink: 0; }
.cl-switch i::after { content: ""; position: absolute; top: 2px; left: 2px; width: 16px; height: 16px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.25); transition: transform .2s; }
.cl-switch input:checked + i { background: #2f5fd0; }
.cl-switch input:checked + i::after { transform: translateX(16px); }
.cl-switch input:focus-visible + i { outline: 2px solid #93b4f5; outline-offset: 2px; }
.cl-switch svg { width: 15px; height: 15px; color: #dc2626; }
.cl-kpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
.cl-kpi { position: relative; background: #fff; border: 1px solid #e5e9f0; border-radius: 14px; padding: 14px 16px; }
.cl-kpi small { display: flex; align-items: center; gap: 5px; font-size: .8rem; font-weight: 600; color: #475569; }
.cl-kpi small svg { width: 14px; height: 14px; }
.cl-kpi small.g svg { color: #16a34a; } .cl-kpi small.b svg { color: #2f5fd0; } .cl-kpi small.r svg { color: #dc2626; }
.cl-kpi > span { position: absolute; top: 14px; right: 16px; font-size: .78rem; color: #64748b; }
.cl-kpi b { display: block; font-size: 1.35rem; margin: 8px 0 4px; }
.cl-kpi b.g { color: #16a34a; } .cl-kpi b.b { color: #2a4fb8; } .cl-kpi b.r { color: #dc2626; }
.cl-kpi em { font-style: normal; font-size: .8rem; color: #64748b; }
.cl-listcard { overflow: hidden; }
.cl-list-h { display: flex; align-items: center; justify-content: space-between; padding: 16px 20px; border-bottom: 1px solid #edf0f5; }
.cl-list-h b { display: inline-flex; align-items: center; gap: 8px; }
.cl-list-h b svg { width: 18px; height: 18px; color: #2f5fd0; }
.cl-count { font-size: .78rem; font-weight: 700; color: #2a4fb8; background: #eef3fc; border: 1px solid #bfd3fb; padding: 4px 10px; border-radius: 8px; white-space: nowrap; }
.cl-list-tools { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; padding: 14px 20px; }
.cl-list-tools label { display: inline-flex; align-items: center; gap: 8px; color: #334155; }
html body.admin-app .cl-list-tools select { width: 76px; height: 38px; }
html body.admin-app .cl-list-tools input { width: 220px; height: 38px; }
html body.admin-app .cl-table { border: none; border-top: 1px solid #edf0f5; border-radius: 0; }
.cl-table table { min-width: 1020px; }
.cl-table th svg { width: 14px; height: 14px; vertical-align: -2px; margin-right: 4px; }
.cl-table td { vertical-align: middle; padding: 14px 16px; }
.cl-table + .tpager { padding: 0 18px 14px; }
.cl-info { display: flex; gap: 14px; align-items: center; }
.cl-info .av { width: 42px; height: 42px; border-radius: 50%; background: #2a4fb8; color: #fff; display: grid; place-items: center; flex-shrink: 0; }
.cl-info .av svg { width: 19px; height: 19px; }
.cl-info .nm { font-weight: 700; color: #2a4fb8; text-decoration: none; }
.cl-info .nm:hover { text-decoration: underline; }
.cl-info .ln { display: flex; align-items: center; gap: 4px; font-size: .8rem; color: #475569; margin-top: 2px; }
.cl-info .ln.b { font-weight: 600; color: #1c2536; }
.cl-info .ln svg { width: 13px; height: 13px; color: #64748b; }
.cl-fee-tag { font-size: .72rem; font-weight: 700; color: #15803d; background: #e7f7ee; border: 1px solid #bbe5c9; padding: 1px 8px; border-radius: 999px; margin-left: 4px; white-space: nowrap; }
.cl-tch { display: flex; flex-wrap: wrap; gap: 4px 6px; }
.cl-tch span { font-weight: 600; font-size: .88rem; }
.cl-tch span + span::before { content: "· "; color: #94a3b8; }
.cl-asst { font-size: .78rem; color: #64748b; margin-top: 3px; }
.cl-size { display: flex; justify-content: space-between; gap: 8px; font-weight: 600; font-size: .9rem; min-width: 130px; }
.cl-prog { height: 6px; border-radius: 999px; background: #e8edf4; margin-top: 6px; overflow: hidden; }
.cl-prog i { display: block; height: 100%; background: linear-gradient(90deg, #4a7be6, #2a4fb8); border-radius: inherit; }
.cl-prog.full i { background: #16a34a; }
.cl-pend { display: block; margin-top: 4px; font-size: .74rem; color: #b45309; font-weight: 600; }
.cl-money { display: block; color: #15803d; }
.cl-table td small.muted { display: block; font-size: .76rem; }
.cl-nomoney { display: inline-flex; align-items: center; gap: 5px; font-size: .86rem; }
.cl-nomoney svg { width: 14px; height: 14px; }
.cl-dots { display: inline-flex; align-items: center; gap: 4px; border: 1px solid #cbd5e1; background: #fff; border-radius: 8px; padding: 7px 12px; cursor: pointer; color: #334155; }
.cl-dots:hover { border-color: #2f5fd0; color: #2f5fd0; }
.cl-dots svg { width: 15px; height: 15px; } .cl-dots svg + svg { width: 12px; height: 12px; }
.um-pop button svg { width: 15px; height: 15px; vertical-align: -3px; margin-right: 6px; }
.cl-modal-wide { max-width: 1180px !important; }
.cl-cal { display: grid; grid-template-columns: repeat(7, minmax(140px, 1fr)); gap: 10px; overflow-x: auto; }
.cl-cal-col { background: #f7f9fc; border: 1px solid #e5e9f0; border-radius: 12px; padding: 8px; display: flex; flex-direction: column; gap: 8px; min-height: 160px; }
.cl-cal-col .h { display: flex; justify-content: space-between; font-weight: 700; font-size: .86rem; color: #0f2257; padding: 2px 4px 6px; border-bottom: 1px solid #e5e9f0; }
.cl-cal-col .h span { font-size: .72rem; background: #e0ecff; color: #2a4fb8; padding: 1px 7px; border-radius: 999px; }
.cl-cal-it { background: #fff; border: 1px solid #e5e9f0; border-left: 3px solid #f59e0b; border-radius: 8px; padding: 7px 9px; font-size: .78rem; display: grid; gap: 1px; }
.cl-cal-it.on { border-left-color: #16a34a; }
.cl-cal-it b { color: #0f172a; }
.cl-cal-it .nm { font-weight: 600; color: #2a4fb8; }
.cl-cal-it small { color: #64748b; }
.cl-cal-none { color: #94a3b8; font-size: .8rem; text-align: center; padding: 12px 0; }

/* Form tạo / sửa lớp */
.cl-crumb { display: flex; align-items: center; gap: 6px; font-size: .84rem; color: #64748b; }
.cl-crumb a { display: inline-flex; align-items: center; gap: 4px; color: #2f5fd0; text-decoration: none; }
.cl-crumb svg { width: 13px; height: 13px; }
.cl-crumb b { color: #1c2536; font-weight: 600; }
.cl-form { overflow: visible; }
.cl-form-h { display: flex; align-items: center; gap: 10px; padding: 18px 22px; font-weight: 700; border-bottom: 1px solid #edf0f5; background: #f8fafd; border-radius: 14px 14px 0 0; }
.cl-form-h svg { width: 18px; height: 18px; color: #2f5fd0; }
.cl-form-b { padding: 22px; display: grid; gap: 20px; }
.cl-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px 22px; }
.cl-f label { display: flex; align-items: center; gap: 6px; font-size: .86rem; font-weight: 600; color: #1c2536; margin-bottom: 7px; }
.cl-f label svg { width: 14px; height: 14px; color: #64748b; }
.cl-f .req { color: #dc2626; }
.cl-f .uf-hint { display: flex; align-items: center; gap: 5px; }
.cl-f .uf-hint svg { width: 13px; height: 13px; }
html body .uf textarea { width: 100%; border: 1px solid #d5dbe5; border-radius: 8px; padding: 10px 14px; font: inherit; font-size: .95rem; background: #fff; resize: vertical; -webkit-backdrop-filter: none; backdrop-filter: none; }
html body .uf textarea:focus { outline: none; border-color: #2f5fd0; box-shadow: 0 0 0 3px rgba(47, 95, 208, .15); }
.cl-grp { display: flex; }
html body .cl-grp select { border-radius: 8px 0 0 8px; }
.cl-grp button { width: 44px; flex-shrink: 0; border: 1px solid #2f5fd0; background: #fff; color: #2f5fd0; border-radius: 0 8px 8px 0; cursor: pointer; display: grid; place-items: center; }
.cl-grp button:hover { background: #eef3fc; }
.cl-grp button svg { width: 17px; height: 17px; }
.cl-fees { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
.cl-fee { display: flex !important; align-items: flex-start; gap: 10px; border: 1px solid #d5dbe5; border-radius: 12px; padding: 14px 16px; cursor: pointer; margin: 0 !important; font-weight: 400 !important; }
.cl-fee:hover { border-color: #93b4f5; }
html body .uf .cl-fee input { width: 18px; height: 18px; padding: 0; margin: 2px 0 0; accent-color: #2a4fb8; flex-shrink: 0; }
.cl-fee b { display: block; font-size: .95rem; color: #1c2536; }
.cl-fee small { display: block; font-size: .8rem; color: #64748b; margin-top: 3px; }
.cl-fee:has(input:checked) { border: 2px solid #2a4fb8; background: #f5f8ff; padding: 13px 15px; }
.cl-fee:has(input:checked) b { color: #2a4fb8; }
.cl-feehelp { border: 1px solid #dbe4f3; background: #f7f9fd; border-radius: 12px; padding: 14px 18px; font-size: .86rem; color: #334155; margin-top: -8px; }
.cl-feehelp > b { display: flex; align-items: center; gap: 6px; color: #2a4fb8; }
.cl-feehelp > b svg { width: 16px; height: 16px; }
.cl-feehelp ul { margin: 8px 0; padding-left: 22px; display: grid; gap: 3px; }
.cl-feehelp em { display: block; border-top: 1px dashed #d5dbe5; padding-top: 8px; color: #64748b; font-size: .8rem; }
.cl-feecfg { background: #f5f8ff; border: 1px solid #dbe4f3; border-radius: 12px; padding: 14px 18px 18px; }
.cl-feecfg .cap { display: flex; align-items: center; gap: 6px; font-size: .76rem; font-weight: 700; letter-spacing: .05em; color: #2a4fb8; margin-bottom: 12px; }
.cl-feecfg .cap svg { width: 15px; height: 15px; }
.cl-feecfg .cl-row { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.cl-charge { background: #fffbeb; border: 1px solid #fde68a; border-radius: 12px; padding: 16px 18px; margin-bottom: 16px; }
.cl-charge:last-child { margin-bottom: 0; }
.cl-charge .cl-switch svg { color: #d97706; }
.cl-charge-opts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; margin-top: 12px; }
.cl-charge .opt { border: 1px solid #f1e7c8; background: #fffdf6; border-radius: 10px; padding: 10px 14px; font-size: .82rem; color: #94a3b8; opacity: .75; }
.cl-charge .opt > b { font-weight: 700; } .cl-charge .opt svg { width: 14px; height: 14px; vertical-align: -2px; }
.cl-charge .opt ul { margin: 6px 0 0; padding-left: 18px; display: grid; gap: 2px; }
.cl-charge.is-on .on-opt, .cl-charge.is-off .off-opt { opacity: 1; color: #334155; background: #fff; border-color: #93b4f5; box-shadow: 0 0 0 2px rgba(147, 180, 245, .35); }
.cl-charge.is-on .on-opt > b, .cl-charge.is-on .on-opt svg { color: #dc2626; }
.cl-charge.is-off .off-opt > b, .cl-charge.is-off .off-opt svg { color: #2a4fb8; }
.cl-sch { border: 1px solid #dbe4f3; border-radius: 14px; overflow: hidden; }
.cl-sch-h { display: flex; align-items: center; gap: 12px; padding: 14px 18px; background: #f5f8ff; border-bottom: 1px solid #dbe4f3; }
.cl-sch-h .i { width: 36px; height: 36px; border-radius: 10px; background: #2a4fb8; color: #fff; display: grid; place-items: center; }
.cl-sch-h .i svg { width: 18px; height: 18px; }
.cl-sch-h b { display: block; } .cl-sch-h small { color: #64748b; font-size: .78rem; }
.cl-sch-h .cl-count { margin-left: auto; border-radius: 999px; background: #fff; }
.cl-sch-b { padding: 16px 18px; display: grid; gap: 14px; }
.cl-alert { display: flex; gap: 8px; align-items: flex-start; background: #eef4ff; border: 1px solid #cddcfb; border-radius: 10px; padding: 10px 14px; font-size: .84rem; color: #0f2257; }
.cl-alert svg { width: 16px; height: 16px; margin-top: 1px; }
.cl-empty { display: grid; justify-items: center; gap: 4px; padding: 28px 16px; border: 1.5px dashed #d5dbe5; border-radius: 12px; color: #64748b; text-align: center; font-size: .82rem; }
.cl-empty svg { width: 36px; height: 36px; color: #94a3b8; margin-bottom: 4px; }
.cl-empty b { color: #1c2536; font-size: .92rem; }
.cl-slots { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 10px; }
.cl-slot { display: flex; align-items: center; gap: 12px; border: 1px solid #e5e9f0; border-radius: 10px; padding: 10px 12px; background: #fff; }
.cl-slot.new { border-style: dashed; border-color: #93b4f5; background: #f8fbff; }
.cl-slot .d { width: 38px; height: 38px; border-radius: 10px; background: #e0ecff; color: #2a4fb8; font-weight: 800; display: grid; place-items: center; font-size: .85rem; flex-shrink: 0; }
.cl-slot b { display: block; font-size: .88rem; } .cl-slot small { color: #64748b; font-size: .78rem; }
.cl-slot button { margin-left: auto; border: none; background: none; color: #94a3b8; cursor: pointer; padding: 6px; border-radius: 6px; }
.cl-slot button:hover { color: #dc2626; background: #fdecec; }
.cl-slot button svg { width: 16px; height: 16px; }
.cl-slot-form { border: 1px solid #e5e9f0; background: #f8fafd; border-radius: 12px; padding: 14px; display: grid; gap: 10px; }
.cl-slot-row { display: flex; align-items: flex-end; gap: 10px; flex-wrap: wrap; }
.cl-slot-row label { display: grid; gap: 4px; font-size: .78rem; font-weight: 600; color: #475569; }
html body .cl-slot-row input, html body .cl-slot-row select { height: 40px !important; width: 150px !important; }
.cl-days { display: flex; gap: 8px; flex-wrap: wrap; }
.cl-days label { cursor: pointer; position: relative; }
.cl-days span { display: inline-block; border: 1px solid #d5dbe5; background: #fff; border-radius: 999px; padding: 7px 14px; font-size: .84rem; font-weight: 600; color: #334155; }
.cl-days input:checked + span { background: #16a34a; border-color: #16a34a; color: #fff; }
.cl-sch-acts { display: flex; gap: 10px; flex-wrap: wrap; }
.cl-btn { display: inline-flex; align-items: center; gap: 7px; height: 40px; border: none; border-radius: 10px; padding: 0 16px; font: inherit; font-size: .88rem; font-weight: 700; cursor: pointer; color: #fff; }
.cl-btn svg { width: 16px; height: 16px; }
.cl-btn.blue { background: #2a4fb8; box-shadow: 0 6px 14px -6px rgba(42, 79, 184, .6); } .cl-btn.blue:hover { background: #1f3c88; }
.cl-btn.green { background: #16a34a; box-shadow: 0 6px 14px -6px rgba(22, 163, 74, .6); } .cl-btn.green:hover { background: #15803d; }
.cl-btn.ghost { background: #eef1f5; color: #334155; }
.cl-form-foot { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 16px 22px; border-top: 1px solid #edf0f5; }
.cl-cancel { display: inline-flex; align-items: center; gap: 6px; border: 1px solid #d5dbe5; background: #fff; border-radius: 10px; padding: 10px 18px; font: inherit; font-weight: 600; cursor: pointer; color: #1c2536; }
.cl-cancel svg, .cl-submit svg, .cl-fab svg { width: 17px; height: 17px; }
.cl-submit, .cl-fab { display: inline-flex; align-items: center; gap: 8px; border: none; background: #2a4fb8; color: #fff; border-radius: 12px; padding: 12px 22px; font: inherit; font-weight: 700; cursor: pointer; box-shadow: 0 10px 22px -10px rgba(42, 79, 184, .8); }
.cl-submit:hover, .cl-fab:hover { background: #1f3c88; }
.cl-submit:disabled, .cl-fab:disabled { opacity: .6; cursor: default; }
.cl-fab { position: fixed; right: 28px; bottom: 24px; z-index: 50; }
@media (max-width: 1200px) { .cl-fees { grid-template-columns: repeat(2, minmax(0, 1fr)); } .cl-stats, .cl-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); } .cl-tabs { margin-left: 0; } }
@media (max-width: 720px) {
  .cl-row, .cl-feecfg .cl-row, .cl-fees, .cl-charge-opts, .cl-stats, .cl-kpis { grid-template-columns: minmax(0, 1fr); }
  .cl-list-tools label:last-child { flex: 1 1 100%; } html body.admin-app .cl-list-tools input { width: 100%; min-width: 0; }
  html body .cl-form input[type=date] { min-width: 0; }
  .cl-hero .acts { margin-left: 0; width: 100%; } .cl-hero { padding: 18px; }
  .cl-fab { right: 16px; bottom: 16px; }
  html body.admin-app .cl-rev-dates input, html body.admin-app .cl-rev-bot select { width: 100%; }
  .cl-rev-dates label { flex: 1 1 140px; }
}

/* Tạo buổi học hàng loạt (popup) */
html body .modal.cl-bulk { max-width: 820px; background: #fff; overflow: visible; }
.cl-bulk header { background: #6a9f3c !important; color: #fff; border-radius: 14px 14px 0 0; border-bottom: none; }
.cl-bulk header h3 { display: flex; align-items: center; gap: 8px; color: #fff; font-size: 1.1rem; }
.cl-bulk header h3 svg { width: 20px; height: 20px; }
.cl-bulk .close-x { color: #fff; opacity: .85; background: none; border: none; font-size: 1.6rem; cursor: pointer; }
.cl-bulk .body { display: grid; gap: 16px; }
.cl-bk-grid2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.cl-bk-grid4 { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.cl-bk-f, .cl-bk-f .lbl, .cl-bk-mode .lbl { display: grid; gap: 7px; font-weight: 600; font-size: .92rem; color: #1c2536; }
.cl-bk-f small { font-weight: 400; font-size: .8rem; color: #64748b; }
.cl-bk-f[hidden] { display: none; }
html body .cl-bulk input:not([type=checkbox]), html body .cl-bulk select { height: 40px; width: 100%; border: 1px solid #d5dbe5; border-radius: 6px; padding: 6px 12px; font: inherit; font-weight: 400; background: #fff; -webkit-backdrop-filter: none; backdrop-filter: none; }
html body .cl-bulk input:focus, html body .cl-bulk select:focus { outline: none; border-color: #6a9f3c; box-shadow: 0 0 0 3px rgba(106, 159, 60, .18); }
.cl-ig { display: flex; }
.cl-ig i { width: 40px; flex-shrink: 0; display: grid; place-items: center; background: #f1f4f8; border: 1px solid #d5dbe5; border-right: none; border-radius: 6px 0 0 6px; font-style: normal; color: #475569; font-weight: 600; }
.cl-ig i svg { width: 16px; height: 16px; }
html body .cl-bulk .cl-ig input { border-radius: 0 6px 6px 0; }
.cl-bk-days { display: flex; flex-wrap: wrap; gap: 8px 18px; font-weight: 400; }
.cl-bk-days label { display: inline-flex; align-items: center; gap: 7px; cursor: pointer; }
.cl-bk-days input { width: 16px; height: 16px; accent-color: #6a9f3c; margin: 0; }
.cl-bk-mode { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.cl-seg { display: inline-flex; border: 1px solid #2f5fd0; border-radius: 6px; overflow: hidden; }
.cl-seg button { display: inline-flex; align-items: center; gap: 5px; border: none; background: #fff; color: #2f5fd0; font: inherit; font-size: .84rem; font-weight: 700; padding: 6px 10px; cursor: pointer; }
.cl-seg button + button { border-left: 1px solid #2f5fd0; }
.cl-seg button.on { background: #2f5fd0; color: #fff; }
.cl-seg svg { width: 14px; height: 14px; }
.cl-bk-custom { display: grid; gap: 8px; background: #f8fafd; border: 1px solid #e5e9f0; border-radius: 10px; padding: 12px; }
.cl-bk-custom[hidden] { display: none; }
.cl-bk-dayrow { display: grid; grid-template-columns: 110px 1fr 1fr; gap: 12px; align-items: end; }
.cl-bk-dayrow b { padding-bottom: 10px; }
.cl-bk-dayrow label { display: grid; gap: 4px; font-size: .78rem; font-weight: 600; color: #475569; }
.cl-bk-sum { display: flex; align-items: flex-start; gap: 6px; background: #f1f8ea; border: 1px solid #cfe5b8; border-radius: 8px; padding: 10px 12px; font-size: .86rem; color: #3f6212; }
.cl-bk-sum svg { width: 15px; height: 15px; margin-top: 2px; flex-shrink: 0; }
.cl-bulk footer { gap: 10px; }
.cl-bk-cancel, .cl-bk-ok { display: inline-flex; align-items: center; gap: 6px; border: none; border-radius: 6px; padding: 10px 16px; font: inherit; font-weight: 700; color: #fff; cursor: pointer; }
.cl-bk-cancel { background: #4b5563; } .cl-bk-cancel:hover { background: #374151; }
.cl-bk-ok { background: #6a9f3c; } .cl-bk-ok:hover { background: #5a8a32; }
.cl-bk-cancel svg, .cl-bk-ok svg { width: 17px; height: 17px; }
@media (max-width: 720px) { .cl-bk-grid2, .cl-bk-grid4 { grid-template-columns: minmax(0, 1fr); } .cl-bk-dayrow { grid-template-columns: 1fr 1fr; } .cl-bk-dayrow b { grid-column: 1 / -1; padding: 0; } }

/* Ô nhập giờ 24h */
html body input.t24 { font-variant-numeric: tabular-nums; letter-spacing: .02em; }
html body input.t24:invalid { border-color: #dc2626 !important; }

/* Ô chọn ngày dùng chung (lịch tiếng Việt) */
html body input.dp-input { font-variant-numeric: tabular-nums; cursor: pointer; }
html body input.dp-input:invalid { border-color: #dc2626 !important; }
.dp-pop { position: fixed; z-index: 1000; width: 312px; background: #fff; border: 1px solid #e5e9f0; border-radius: 14px; box-shadow: 0 18px 44px -14px rgba(15, 34, 87, .35); padding: 12px 12px 10px; font-family: inherit; color: #1c2536; }
.dp-pop[hidden] { display: none; }
.dp-head { display: flex; align-items: center; gap: 4px; margin-bottom: 8px; }
.dp-nav { width: 32px; height: 32px; flex-shrink: 0; border: none; background: none; border-radius: 8px; font-size: 1.5rem; line-height: 1; color: #334155; cursor: pointer; }
.dp-nav:hover { background: #f1f5fb; color: #1f3c88; }
html body .dp-pop select { height: 34px; border: none !important; box-shadow: none !important; background-color: transparent !important; font: inherit; font-weight: 800; font-size: 1.12rem; color: #0f172a; cursor: pointer; padding: 0 22px 0 6px; width: auto !important; -webkit-backdrop-filter: none; backdrop-filter: none; }
html body .dp-pop select:focus { outline: 2px solid #bfd3fb; border-radius: 6px; }
.dp-pop .dp-m { flex: 1; min-width: 0; }
.dp-week, .dp-days { display: grid; grid-template-columns: repeat(7, 1fr); gap: 2px; text-align: center; }
.dp-week span { font-size: .8rem; font-weight: 700; color: #64748b; padding: 6px 0; }
.dp-days button { width: 38px; height: 38px; margin: 1px auto; border: none; background: none; border-radius: 50%; font: inherit; font-size: .95rem; color: #1c2536; cursor: pointer; display: grid; place-items: center; font-variant-numeric: tabular-nums; }
.dp-days button:hover { background: #eef3ff; color: #1f3c88; }
.dp-days button.out { color: #b6bfcc; }
.dp-days button.today { box-shadow: inset 0 0 0 1.5px #93b4f5; font-weight: 700; color: #1f3c88; }
.dp-days button.on { background: #1f3c88; color: #fff; font-weight: 800; box-shadow: 0 6px 14px -6px rgba(31, 60, 136, .7); }

/* ==========================================================
   VẬN HÀNH LỚP HỌC – chi tiết lớp, học viên, điểm danh, chương trình
   ========================================================== */
.cd-page, .cp-page { display: grid; gap: 16px; }
.cd-page svg, .aw-page svg, .cp-page svg, .att-menu svg, .att-ok svg { flex-shrink: 0; }
.cd-hero { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; padding: 18px 22px; border-radius: 16px; color: #fff; background: linear-gradient(100deg, #0f2257, #2a4fb8 55%, #4a7be6); box-shadow: 0 10px 30px -12px rgba(42, 79, 184, .55); }
.cd-back { width: 40px; height: 40px; border-radius: 10px; border: 1px solid rgba(255,255,255,.4); background: rgba(255,255,255,.14); color: #fff; display: grid; place-items: center; cursor: pointer; }
.cd-back:hover { background: rgba(255,255,255,.26); }
.cd-back svg { width: 18px; height: 18px; }
.cd-title small { display: flex; align-items: center; gap: 5px; font-size: .68rem; font-weight: 800; letter-spacing: .06em; opacity: .85; }
.cd-title small svg { width: 13px; height: 13px; }
.cd-title h2 { margin: 2px 0; font-size: 1.45rem; color: #fff; display: flex; align-items: center; gap: 10px; flex-wrap: wrap; text-transform: uppercase; }
.cd-title h2 .badge { font-size: .72rem; text-transform: none; }
.cd-title p { margin: 0; display: flex; align-items: center; gap: 6px; flex-wrap: wrap; font-size: .84rem; opacity: .92; }
.cd-title p svg { width: 14px; height: 14px; }
.cd-acts { margin-left: auto; display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.cd-cap { border: 1px solid rgba(255,255,255,.45); background: rgba(255,255,255,.12); border-radius: 10px; padding: 6px 14px; line-height: 1.15; }
.cd-cap b { display: block; font-size: 1.05rem; } .cd-cap small { font-size: .72rem; opacity: .85; }
.cd-grid { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 16px; align-items: start; }
.cd-main, .cd-side { display: grid; gap: 16px; min-width: 0; }
.cd-card { background: #fff; border: 1px solid #e5e9f0; border-radius: 14px; padding: 16px 18px; }
.cd-card > h4 { display: flex; align-items: center; gap: 8px; margin: 0 0 14px; font-size: .98rem; }
.cd-card > h4 > svg { width: 18px; height: 18px; color: #2f5fd0; }
.cd-quick { border-top: 3px solid transparent; border-image: linear-gradient(90deg, #6366f1, #22c55e, #f59e0b, #ec4899) 1; border-radius: 0 0 14px 14px; }
.cd-info { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.cd-info > div { border: 1px solid #edf0f5; background: #fbfcfe; border-radius: 10px; padding: 10px 14px; display: grid; gap: 4px; align-content: start; }
.cd-info > div.full { grid-column: 1 / -1; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; border-style: dashed; }
.cd-info small { display: inline-flex; align-items: center; gap: 5px; font-size: .74rem; color: #64748b; }
.cd-info small svg { width: 13px; height: 13px; }
.cd-info b { font-size: .95rem; } .cd-info b.g { color: #15803d; }
.cd-info em { font-style: normal; font-size: .76rem; color: #64748b; }
.cd-pill { display: inline-block; font-size: .74rem; font-weight: 700; padding: 2px 10px; border-radius: 6px; justify-self: start; }
.cd-pill.g { background: #6a9f3c; color: #fff; }
.cd-stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.cd-stats > div { position: relative; border: 1px solid #e5e9f0; border-left: 4px solid #2f5fd0; border-radius: 12px; padding: 12px 14px; background: #fbfcfe; overflow: hidden; }
.cd-stats > div.n { border-left-color: #94a3b8; } .cd-stats > div.g { border-left-color: #16a34a; } .cd-stats > div.t { border-left-color: #0d9488; }
.cd-stats small { font-size: .7rem; font-weight: 800; letter-spacing: .04em; color: #475569; }
.cd-stats b { display: block; font-size: 1.6rem; line-height: 1.25; }
.cd-stats em { font-style: normal; font-size: .76rem; color: #64748b; }
.cd-stats .ic { position: absolute; top: 10px; right: 10px; width: 30px; height: 30px; border-radius: 8px; background: #e0ecff; color: #2a4fb8; display: grid; place-items: center; }
.cd-stats .g .ic { background: #e7f7ee; color: #16a34a; } .cd-stats .t .ic { background: #dcfce7; color: #059669; } .cd-stats .n .ic { background: #eef1f5; color: #475569; }
.cd-stats .ic svg { width: 16px; height: 16px; }
.bar { display: block; height: 5px; border-radius: 99px; background: #e8edf4; margin-top: 8px; overflow: hidden; }
.bar > i { display: block; height: 100%; background: linear-gradient(90deg, #4a7be6, #2a4fb8); border-radius: inherit; }
.cd-outline, .cd-mini { margin-left: auto; display: inline-flex; align-items: center; gap: 5px; border: 1px solid #2a4fb8; background: #fff; color: #2a4fb8; border-radius: 8px; padding: 6px 12px; font: inherit; font-size: .8rem; font-weight: 700; cursor: pointer; }
.cd-outline svg, .cd-mini svg { width: 14px; height: 14px; }
.cd-mini { border: none; padding: 4px; }
.cd-years { display: inline-flex; gap: 6px; border: 1px solid #e5e9f0; border-radius: 10px; padding: 4px; margin-bottom: 14px; flex-wrap: wrap; }
.cd-years button { display: inline-flex; align-items: center; gap: 6px; border: none; background: none; border-radius: 8px; padding: 6px 12px; font: inherit; font-size: .84rem; font-weight: 700; color: #334155; cursor: pointer; }
.cd-years button svg { width: 14px; height: 14px; }
.cd-years button span { font-size: .7rem; background: #e0ecff; color: #2a4fb8; padding: 1px 7px; border-radius: 6px; }
.cd-years button.on { background: #2a4fb8; color: #fff; } .cd-years button.on span { background: rgba(255,255,255,.25); color: #fff; }
.cd-months { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 8px; margin-bottom: 14px; }
.cd-months button { border: 1px solid #e5e9f0; background: #f8fafc; border-radius: 8px; padding: 7px 4px; font: inherit; cursor: pointer; color: #94a3b8; display: grid; }
.cd-months button b { font-size: .86rem; } .cd-months button small { font-size: .72rem; }
.cd-months button.has { color: #1c2536; background: #fff; }
.cd-months button.on { background: #2a4fb8; border-color: #2a4fb8; color: #fff; box-shadow: 0 6px 16px -8px rgba(42, 79, 184, .8); }
.cd-mhead { display: flex; justify-content: space-between; font-size: .88rem; margin-bottom: 10px; } .cd-mhead span { color: #64748b; font-size: .8rem; }
.cd-sess { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.cd-s { position: relative; text-align: left; display: grid; gap: 5px; border: 1px solid #e5e9f0; background: #fff; border-radius: 12px; padding: 12px 14px; font: inherit; font-size: .82rem; color: #334155; cursor: pointer; }
.cd-s:hover { border-color: #93b4f5; box-shadow: 0 8px 20px -14px rgba(42, 79, 184, .6); }
.cd-s.done { border-left: 4px solid #16a34a; } .cd-s.today { border-left: 4px solid #2f5fd0; } .cd-s.past { border-left: 4px solid #dc2626; }
.cd-s small { font-weight: 800; font-size: .7rem; letter-spacing: .04em; color: #475569; display: flex; align-items: center; gap: 5px; }
.cd-s span { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.cd-s svg { width: 13px; height: 13px; color: #64748b; }
.cd-s .go { position: absolute; top: 12px; right: 12px; width: 16px; height: 16px; }
.cd-s .badge { font-size: .68rem; padding: 1px 8px; }
.cd-s .pg { color: #2a4fb8; font-weight: 600; }
.cd-cnt { font-style: normal; font-size: .72rem; color: #15803d; font-weight: 700; }
.cd-qgrid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.cd-qgrid button { display: flex; align-items: center; gap: 10px; border: 1px solid #e5e9f0; background: #fff; border-radius: 10px; padding: 10px; font: inherit; font-size: .86rem; font-weight: 600; color: #1c2536; cursor: pointer; text-align: left; }
.cd-qgrid button:hover { border-color: #93b4f5; background: #f8fbff; }
.cd-qgrid .i { width: 32px; height: 32px; border-radius: 8px; display: grid; place-items: center; color: #fff; }
.cd-qgrid .i svg { width: 16px; height: 16px; }
.cd-qgrid .i.v { background: #6366f1; } .cd-qgrid .i.g { background: #10b981; } .cd-qgrid .i.c { background: #0ea5e9; } .cd-qgrid .i.p { background: #8b5cf6; }
.cd-qgrid .ar { margin-left: auto; width: 14px; height: 14px; color: #cbd5e1; }
.cd-dl { margin: 0; display: grid; }
.cd-dl > div { display: flex; justify-content: space-between; gap: 12px; padding: 9px 0; border-bottom: 1px dashed #e5e9f0; font-size: .84rem; }
.cd-dl > div:last-child { border-bottom: none; }
.cd-dl dt { font-size: .72rem; font-weight: 700; color: #64748b; letter-spacing: .03em; } .cd-dl dd { margin: 0; font-weight: 700; text-align: right; }
.cd-id { background: #64748b; color: #fff; border-radius: 6px; padding: 1px 8px; font-size: .76rem; }
.cd-empty { display: grid; justify-items: center; gap: 6px; padding: 22px 10px; color: #64748b; text-align: center; font-size: .84rem; }
.cd-empty svg { width: 30px; height: 30px; color: #94a3b8; }
.cd-hist { display: grid; gap: 8px; }
.cd-hist button { display: grid; grid-template-columns: 1fr auto; gap: 2px 10px; text-align: left; border: 1px solid #edf0f5; background: #fbfcfe; border-radius: 10px; padding: 8px 12px; font: inherit; font-size: .82rem; cursor: pointer; }
.cd-hist button:hover { border-color: #93b4f5; }
.cd-hist small { color: #64748b; font-size: .74rem; grid-column: 1; }
.cd-hist span { grid-row: 1 / 3; grid-column: 2; display: flex; gap: 4px; align-items: center; }
.cd-hist i, .att-n { font-style: normal; font-size: .72rem; font-weight: 800; min-width: 22px; text-align: center; padding: 1px 5px; border-radius: 6px; display: inline-block; }
.cd-hist i.p, .att-n.p { background: #dcfce7; color: #15803d; } .cd-hist i.a, .att-n.a { background: #fee2e2; color: #b91c1c; }
.cd-hist i.l, .att-n.l { background: #fef3c7; color: #b45309; } .cd-hist i.e, .att-n.e { background: #dbe6f8; color: #2a4fb8; }

/* Popup điểm danh */
html body .modal.att-modal { max-width: 500px; }
.att-modal header { border-bottom: none; padding-bottom: 0; }
.att-menu, .att-ok { display: grid; gap: 12px; text-align: center; padding: 0 8px 8px; }
.att-menu h3, .att-ok h3 { margin: 0; font-size: 1.6rem; color: #334155; }
.att-menu p { margin: 0 0 6px; text-align: left; color: #475569; }
.att-menu button { display: grid; justify-items: center; gap: 2px; border-radius: 8px; padding: 12px; font: inherit; cursor: pointer; }
.att-menu button svg { width: 20px; height: 20px; }
.att-menu button b { font-size: 1rem; } .att-menu button small { font-size: .86rem; }
.att-menu .new { background: #0864d6; color: #fff; border: 1px solid #0864d6; } .att-menu .new:hover { background: #0656b8; }
.att-menu .his { background: #fff; color: #2f5fd0; border: 1px solid #2f5fd0; } .att-menu .his small { color: #64748b; }
.att-menu .close { justify-self: center; margin-top: 10px; background: #6b7280; color: #fff; border: none; padding: 10px 24px; font-weight: 700; }
.att-ok > span { justify-self: center; width: 64px; height: 64px; border-radius: 50%; background: #dcfce7; color: #16a34a; display: grid; place-items: center; }
.att-ok > span svg { width: 36px; height: 36px; }
.att-ok p { margin: 0; color: #475569; } .att-ok .aw-next { justify-self: center; }

/* Điểm danh 4 bước */
.aw-page .cl-hero .ic { margin-left: -4px; }
.aw-steps { position: relative; display: grid; grid-template-columns: repeat(4, 1fr); padding: 20px 10px 16px; }
.aw-line { position: absolute; left: 12.5%; right: 12.5%; top: 40px; height: 3px; background: #e2e8f0; }
.aw-line i { display: block; height: 100%; background: #2a4fb8; transition: width .3s; }
.aw-st { position: relative; display: grid; justify-items: center; gap: 8px; text-align: center; }
.aw-st span { width: 42px; height: 42px; border-radius: 50%; display: grid; place-items: center; background: #fff; border: 2px solid #cbd5e1; color: #64748b; font-weight: 800; }
.aw-st span svg { width: 22px; height: 22px; }
.aw-st b { font-size: .84rem; font-weight: 600; color: #64748b; }
.aw-st.done span { background: #16a34a; border-color: #bbf7d0; color: #fff; box-shadow: 0 0 0 4px #dcfce7; } .aw-st.done b { color: #16a34a; }
.aw-st.cur span { background: #2a4fb8; border-color: #c3d5f5; color: #fff; box-shadow: 0 0 0 5px #dbe6f8; } .aw-st.cur b { color: #2a4fb8; font-weight: 700; }
.aw-card { max-width: 1060px; width: 100%; margin: 0 auto; }
.aw-card-h { display: flex; align-items: center; gap: 10px; padding: 16px 20px; font-weight: 700; font-size: 1.02rem; border-bottom: 1px solid #edf0f5; background: #f8fafd; border-radius: 14px 14px 0 0; }
.aw-card-h svg { width: 20px; height: 20px; color: #2a4fb8; }
.aw-card-b { padding: 18px 20px; display: grid; gap: 16px; }
html body .aw-page select, html body .aw-page textarea, html body .aw-page input:not([type=checkbox]) { width: 100%; border: 1px solid #d5dbe5; border-radius: 8px; padding: 9px 12px; font: inherit; background: #fff; -webkit-backdrop-filter: none; backdrop-filter: none; }
html body .aw-page select { height: 42px; }
.aw-prog { border: 1px solid #e5e9f0; border-radius: 8px; padding: 12px 14px; min-height: 56px; background: #fbfcfe; white-space: pre-wrap; font-size: .9rem; }
.aw-prog em { color: #64748b; }
.aw-nav { display: flex; justify-content: space-between; align-items: center; gap: 12px; border-top: 1px solid #edf0f5; padding-top: 16px; }
.aw-prev { display: inline-flex; align-items: center; gap: 8px; border: 1px solid #d5dbe5; background: #f8fafc; border-radius: 10px; padding: 10px 18px; font: inherit; font-weight: 600; cursor: pointer; }
.aw-next { display: inline-flex; align-items: center; gap: 8px; border: none; background: #2a4fb8; color: #fff; border-radius: 10px; padding: 11px 20px; font: inherit; font-weight: 700; cursor: pointer; box-shadow: 0 8px 18px -8px rgba(42, 79, 184, .8); }
.aw-next:hover { background: #1f3c88; } .aw-next:disabled { opacity: .55; cursor: default; }
.aw-next.green { background: #16a34a; box-shadow: 0 8px 18px -8px rgba(22, 163, 74, .8); } .aw-next.green:hover { background: #15803d; }
.aw-prev svg, .aw-next svg { width: 17px; height: 17px; }
.aw-att { padding: 16px 18px; display: grid; gap: 16px; }
.aw-bar { display: flex; gap: 8px; flex-wrap: wrap; background: #eff8ff; border: 1px solid #cfe3f7; border-radius: 10px; padding: 10px 12px; }
.aw-bar span { display: inline-flex; align-items: center; gap: 5px; font-size: .84rem; font-weight: 700; padding: 3px 10px; border-radius: 6px; }
.aw-bar span svg { width: 14px; height: 14px; }
.aw-bar .b { background: #dbe6f8; color: #2a4fb8; } .aw-bar .y { background: #fef3c7; color: #b45309; } .aw-bar .g { background: #dcfce7; color: #15803d; } .aw-bar .r { background: #fee2e2; color: #b91c1c; }
.aw-att-h { display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; }
.aw-att-h b { display: inline-flex; align-items: center; gap: 8px; } .aw-att-h b svg { width: 18px; height: 18px; color: #2a4fb8; }
.aw-att-h > div { display: flex; gap: 8px; flex-wrap: wrap; }
.aw-sm { display: inline-flex; align-items: center; gap: 5px; border: 1px solid #d5dbe5; background: #fff; border-radius: 8px; padding: 6px 12px; font: inherit; font-size: .8rem; font-weight: 600; cursor: pointer; color: #334155; }
.aw-sm svg { width: 14px; height: 14px; }
.aw-tiles { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.aw-tile { border-radius: 10px; color: #fff; text-align: center; padding: 12px 8px; }
.aw-tile b { display: block; font-size: 1.7rem; line-height: 1.1; } .aw-tile small { font-size: .74rem; font-weight: 800; letter-spacing: .04em; }
.aw-tile.p { background: linear-gradient(135deg, #16a34a, #15803d); } .aw-tile.a { background: linear-gradient(135deg, #dc2626, #b91c1c); }
.aw-tile.l { background: linear-gradient(135deg, #f59e0b, #d97706); } .aw-tile.e { background: linear-gradient(135deg, #2f5fd0, #2a4fb8); }
.aw-tools { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
html body .aw-tools input { width: 220px; height: 38px; }
.aw-seg { display: inline-flex; gap: 6px; }
.aw-seg button { display: inline-flex; align-items: center; gap: 6px; border: 1px solid #bfd3fb; background: #f5f8ff; color: #2a4fb8; border-radius: 8px; padding: 7px 12px; font: inherit; font-size: .82rem; font-weight: 700; cursor: pointer; }
.aw-seg button svg { width: 14px; height: 14px; }
.aw-seg button.on { background: #2a4fb8; border-color: #2a4fb8; color: #fff; }
.aw-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 12px; }
.aw-c { border: 1px solid #e5e9f0; border-top: 3px solid #16a34a; border-radius: 10px; padding: 12px; display: grid; gap: 6px; background: #fff; }
.aw-c.a { border-top-color: #dc2626; background: #fffafa; } .aw-c.l { border-top-color: #f59e0b; } .aw-c.e { border-top-color: #2f5fd0; }
.aw-c > b { font-size: .88rem; text-transform: uppercase; } .aw-c > small { color: #64748b; font-size: .78rem; }
html body .aw-c textarea { min-height: 52px; font-size: .84rem; resize: vertical; }
.aw-bs { display: flex; gap: 4px; flex-wrap: wrap; }
.aw-b { display: inline-flex; align-items: center; gap: 3px; border: 1px solid transparent; border-radius: 6px; padding: 3px 7px; font: inherit; font-size: .74rem; font-weight: 600; cursor: pointer; }
.aw-b svg { width: 11px; height: 11px; }
.aw-b.p { background: #ecfdf3; color: #15803d; } .aw-b.a { background: #fef2f2; color: #b91c1c; } .aw-b.l { background: #fffbeb; color: #b45309; } .aw-b.e { background: #eef3fc; color: #2a4fb8; }
.aw-b.p.on { background: #16a34a; color: #fff; } .aw-b.a.on { background: #dc2626; color: #fff; } .aw-b.l.on { background: #f59e0b; color: #fff; } .aw-b.e.on { background: #2f5fd0; color: #fff; }
.aw-sum { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.aw-sum h5 { margin: 0 0 12px; font-size: 1rem; } .aw-sum p { margin: 0 0 10px; }
.aw-chips { display: flex; gap: 6px; flex-wrap: wrap; }
.aw-chips span { color: #fff; font-weight: 700; font-size: .82rem; padding: 3px 9px; border-radius: 6px; }
.aw-chips .p { background: #6a9f3c; } .aw-chips .a { background: #e2541d; } .aw-chips .l { background: #e0a100; } .aw-chips .e { background: #2b7bd8; }
.aw-absent { font-size: .86rem; color: #b91c1c; }

/* Học viên của lớp */
.cs-hero { padding: 18px 20px; border-radius: 16px; color: #fff; background: linear-gradient(100deg, #2a4fb8, #4a7be6); display: grid; gap: 16px; }
.cs-hero .top { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.cs-hero h2 { margin: 0; color: #fff; text-transform: uppercase; font-size: 1.4rem; }
.cs-hero p { margin: 4px 0 0; display: flex; align-items: center; gap: 6px; flex-wrap: wrap; font-size: .84rem; opacity: .92; }
.cs-hero p svg { width: 14px; height: 14px; }
.cs-tiles { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 12px; }
.cs-tiles > div { border: 1px solid rgba(255,255,255,.35); background: rgba(255,255,255,.12); border-radius: 12px; padding: 12px 14px; }
.cs-tiles b { display: block; font-size: 1.5rem; } .cs-tiles small { font-size: .72rem; font-weight: 800; letter-spacing: .04em; }
.cs-tiles .bar { background: rgba(255,255,255,.3); } .cs-tiles .bar > i { background: #f59e0b; }
.cs-filter { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; padding: 12px 14px; }
html body.admin-app .cs-filter select { width: 260px; height: 40px; }
.cs-listh { display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; }
.cs-listh > b { display: inline-flex; align-items: center; gap: 8px; } .cs-listh > b svg { width: 18px; height: 18px; color: #2a4fb8; }
.cs-listh > div { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.cs-listh .cl-chip { margin: 0; padding: 9px 12px; }
.cs-table table { min-width: 900px; }
.cs-table th svg { width: 14px; height: 14px; vertical-align: -2px; margin-right: 4px; }
.cs-who { display: grid; gap: 3px; }
.cs-who b { font-size: .92rem; } .cs-who .badge { font-size: .66rem; padding: 1px 7px; }
.cs-who small { display: flex; align-items: center; gap: 4px; flex-wrap: wrap; font-size: .76rem; color: #64748b; }
.cs-who small svg { width: 12px; height: 12px; }
.cs-who .b { color: #2f5fd0; font-weight: 600; } .cs-who small.g { color: #15803d; font-weight: 600; }
.cs-who a { color: #2f5fd0; display: inline-flex; align-items: center; gap: 3px; }
.cs-att { display: flex; justify-content: space-between; font-size: .86rem; min-width: 200px; } .cs-att span { color: #64748b; }
.cs-table td small { display: block; margin-top: 5px; font-size: .74rem; color: #64748b; }
.cs-note { font-size: .84rem; background: #fffbeb; border: 1px solid #fde68a; border-radius: 8px; padding: 6px 10px; margin-bottom: 6px; white-space: pre-wrap; }
.cs-addnote { display: flex; align-items: center; justify-content: center; gap: 5px; width: 100%; margin-top: 6px; border: 1px dashed #93b4f5; background: #f5f8ff; color: #2a4fb8; border-radius: 8px; padding: 6px; font: inherit; font-size: .78rem; font-weight: 600; cursor: pointer; }
.cs-addnote svg { width: 13px; height: 13px; }
.as-list { max-height: 360px; overflow-y: auto; display: grid; gap: 6px; margin: 12px 0; }
.as-list label { display: flex; align-items: center; gap: 10px; border: 1px solid #e5e9f0; border-radius: 8px; padding: 8px 12px; cursor: pointer; }
.as-list label:hover { background: #f8fbff; } .as-list label.in { opacity: .6; cursor: default; }
.as-list input { width: 16px; height: 16px; }
.as-list b { display: block; font-size: .88rem; } .as-list small { color: #64748b; font-size: .76rem; }
.as-list em { margin-left: auto; font-style: normal; font-size: .74rem; color: #15803d; font-weight: 700; }
.as-foot { display: flex; justify-content: space-between; align-items: center; gap: 10px; }

/* Chương trình học */
.cp-page { max-width: 1240px; width: 100%; margin: 0 auto; }
.cp-title h2 { margin: 0; display: flex; align-items: center; gap: 10px; text-transform: uppercase; font-size: 1.5rem; }
.cp-title h2 svg { width: 26px; height: 26px; color: #7c3aed; }
.cp-title p { margin: 4px 0 0; display: flex; align-items: center; gap: 6px; color: #475569; font-size: .88rem; }
.cp-title p svg { width: 14px; height: 14px; }
.cp-stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
.cp-stats > div { display: grid; grid-template-columns: auto 1fr; gap: 0 14px; align-items: center; background: #fff; border: 1px solid #edf0f5; border-radius: 14px; padding: 16px 18px; box-shadow: 0 4px 14px -10px rgba(15, 34, 87, .2); }
.cp-stats .i { grid-row: 1 / 3; width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; }
.cp-stats .i svg { width: 22px; height: 22px; }
.cp-stats .i.g { background: #dcfce7; color: #16a34a; } .cp-stats .i.v { background: #ede9fe; color: #7c3aed; } .cp-stats .i.b { background: #dbe6f8; color: #2f5fd0; } .cp-stats .i.y { background: #fef3c7; color: #d97706; }
.cp-stats small { color: #475569; font-size: .84rem; } .cp-stats b { font-size: 1.4rem; }
.cp-prog { background: #fff; border: 1px solid #edf0f5; border-radius: 14px; padding: 16px 20px; }
.cp-prog > div { display: flex; justify-content: space-between; align-items: center; }
.cp-prog span { display: inline-flex; align-items: center; gap: 6px; } .cp-prog span svg { width: 16px; height: 16px; }
.cp-prog b { color: #7c3aed; font-size: 1.1rem; }
.cp-prog .bar { height: 8px; } .cp-prog .bar > i { background: linear-gradient(90deg, #8b5cf6, #6366f1); }
.cp-next { position: relative; overflow: hidden; border-radius: 16px; padding: 22px 26px; color: #fff; background: linear-gradient(100deg, #7c3aed, #6366f1 55%, #4a7be6); box-shadow: 0 14px 30px -14px rgba(124, 58, 237, .7); }
.cp-next::after { content: ""; position: absolute; right: -30px; top: -30px; width: 130px; height: 130px; border-radius: 50%; background: rgba(255,255,255,.12); }
.cp-next small { display: flex; align-items: center; gap: 5px; font-size: .74rem; font-weight: 800; letter-spacing: .06em; opacity: .9; }
.cp-next small svg { width: 13px; height: 13px; }
.cp-next h3 { margin: 6px 0; color: #fff; font-size: 1.3rem; }
.cp-next p { margin: 0; display: flex; align-items: center; gap: 5px; font-weight: 600; } .cp-next p svg { width: 15px; height: 15px; }
.cp-list { background: #fff; border: 1px solid #edf0f5; border-radius: 14px; padding: 8px; display: grid; gap: 4px; }
.cp-item { display: flex; gap: 14px; border: 1px solid transparent; border-left: 3px solid #e2e8f0; border-radius: 12px; padding: 14px; }
.cp-item.cur { border-color: #c4b5fd; border-left-color: #7c3aed; box-shadow: 0 0 0 2px #ede9fe; }
.cp-item.done { border-left-color: #16a34a; }
.cp-item .no { width: 42px; height: 42px; border-radius: 10px; background: #f1f5f9; display: grid; place-items: center; font-weight: 800; flex-shrink: 0; }
.cp-item.done .no { background: #dcfce7; color: #15803d; }
.cp-item .bd { flex: 1; min-width: 0; display: grid; gap: 6px; }
.cp-item .hd { display: flex; justify-content: space-between; gap: 10px; align-items: flex-start; }
.cp-item .hd em { font-style: normal; color: #1c2536; } .cp-item .hd em.none { font-style: italic; color: #94a3b8; font-weight: 400; }
.cp-item .hd .badge { font-size: .7rem; white-space: nowrap; }
.cp-item small { display: flex; align-items: center; gap: 4px; color: #475569; font-size: .8rem; } .cp-item small svg { width: 13px; height: 13px; }
html body .cp-item textarea { width: 100%; border: 1px solid #d5dbe5; border-radius: 8px; padding: 10px 12px; font: inherit; font-size: .88rem; resize: vertical; background: #fff; -webkit-backdrop-filter: none; backdrop-filter: none; }
.cp-item .ft { display: flex; justify-content: flex-end; }
.cp-save { display: inline-flex; align-items: center; gap: 5px; border: none; background: #7c3aed; color: #fff; border-radius: 8px; padding: 7px 14px; font: inherit; font-size: .84rem; font-weight: 700; cursor: pointer; }
.cp-save:hover { background: #6d28d9; } .cp-save:disabled { opacity: .6; } .cp-save svg { width: 14px; height: 14px; }
@media (max-width: 1200px) { .cd-grid { grid-template-columns: minmax(0, 1fr); } .cd-stats, .cp-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); } .cs-tiles { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 720px) {
  .cd-info, .cd-sess, .aw-sum { grid-template-columns: minmax(0, 1fr); } .cd-months { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .cd-stats, .cp-stats, .aw-tiles, .cs-tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cd-acts { margin-left: 0; } .aw-st b { font-size: .7rem; } .aw-st span { width: 34px; height: 34px; } .aw-line { top: 36px; }
  html body .aw-tools input, html body.admin-app .cs-filter select { width: 100%; }
}

/* ==========================================================
   QUẢN LÝ HỌC VIÊN – danh sách, chi tiết, thêm / sửa
   ========================================================== */
.sv-page, .sd-page, .sf-page { display: grid; gap: 16px; }
.sv-page svg, .sd-page svg, .sf-page svg, .sv-rowpop svg { flex-shrink: 0; }
.sv-av { border-radius: 50%; display: inline-grid; place-items: center; overflow: hidden; font-weight: 800; flex-shrink: 0; }
.sv-av img { width: 100%; height: 100%; object-fit: cover; }
.sv-stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.sv-stat { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 18px 20px; border-radius: 14px; color: #fff; cursor: default; box-shadow: 0 10px 24px -14px rgba(15, 34, 87, .6); }
.sv-stat[data-st], .sv-stat[data-bday] { cursor: pointer; } .sv-stat[data-st]:hover, .sv-stat[data-bday]:hover { filter: brightness(1.05); }
.sv-stat.b { background: linear-gradient(120deg, #0f2257, #2a4fb8); } .sv-stat.g { background: linear-gradient(120deg, #059669, #10b981); }
.sv-stat.c { background: linear-gradient(120deg, #2f5fd0, #4a7be6); } .sv-stat.o { background: linear-gradient(120deg, #f59e0b, #d97706); }
.sv-stat small { font-size: .74rem; font-weight: 800; letter-spacing: .04em; }
.sv-stat b { display: block; font-size: 1.8rem; line-height: 1.2; }
.sv-stat em { display: flex; align-items: center; gap: 5px; font-style: normal; font-size: .76rem; opacity: .92; }
.sv-stat em svg { width: 12px; height: 12px; }
.sv-stat > span { width: 46px; height: 46px; border-radius: 12px; background: rgba(255,255,255,.2); display: grid; place-items: center; }
.sv-stat > span svg { width: 24px; height: 24px; }
.sv-filter { overflow: visible; }
.sv-filter-h { display: flex; align-items: center; gap: 8px; padding: 14px 18px; font-weight: 700; border-bottom: 1px solid #edf0f5; }
.sv-filter-h svg { width: 16px; height: 16px; color: #2f5fd0; }
.sv-filter-b { padding: 16px 18px; display: grid; gap: 14px; }
.sv-frow { display: grid; grid-template-columns: 1.6fr repeat(4, minmax(0, 1fr)); gap: 12px; align-items: end; }
.sv-frow .cl-search { max-width: none; }
.sv-fl { display: grid; gap: 4px; font-size: .74rem; font-weight: 600; color: #475569; }
html body.admin-app .sv-fl select, html body.admin-app .sv-frow input { height: 40px; width: 100%; }
.sv-fbtn { display: flex; gap: 10px; }
.sv-fbtn .aw-next, .sv-fbtn .aw-prev { padding: 9px 18px; font-size: .86rem; }
.sv-tagfilter { border: 1px solid #e5e9f0; border-radius: 10px; padding: 10px 14px; background: #fbfcfe; display: grid; gap: 8px; }
.sv-tagfilter small { display: flex; align-items: center; gap: 5px; color: #475569; font-weight: 600; } .sv-tagfilter small svg { width: 13px; height: 13px; }
.sv-tagfilter em { font-size: .84rem; color: #64748b; }
#svTags { display: flex; flex-wrap: wrap; gap: 6px; }
#svTags button { display: inline-flex; align-items: center; gap: 5px; border: 1px solid #d5dbe5; background: #fff; border-radius: 999px; padding: 4px 10px; font: inherit; font-size: .8rem; font-weight: 600; color: #334155; cursor: pointer; }
#svTags button svg { width: 12px; height: 12px; }
#svTags button span { font-size: .7rem; background: #eef1f5; padding: 0 6px; border-radius: 99px; }
#svTags button.on { background: #7c3aed; border-color: #7c3aed; color: #fff; } #svTags button.on span { background: rgba(255,255,255,.25); }
.sv-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }
.sv-head h2 { margin: 0; font-size: 1.25rem; }
.sv-head > div { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.sv-more { position: relative; }
.sv-more .cl-chip { margin: 0; padding: 9px 12px; }
.sv-more .sv-more-pop { display: none; right: 0; top: calc(100% + 4px); }
.sv-more.open .sv-more-pop { display: block; }
.sv-table table { min-width: 980px; }
.sv-table th svg { width: 14px; height: 14px; vertical-align: -2px; margin-right: 4px; }
.sv-table td { vertical-align: middle; padding: 12px 14px; }
.sv-who { display: flex; gap: 12px; align-items: flex-start; }
.sv-name { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.sv-name a { font-weight: 700; font-size: 1rem; color: #2a4fb8; text-decoration: none; } .sv-name a:hover { text-decoration: underline; }
.sv-br { display: inline-flex; align-items: center; gap: 4px; font-size: .72rem; font-weight: 700; color: #2a4fb8; background: #eef3fc; border: 1px solid #bfd3fb; padding: 1px 8px; border-radius: 6px; }
.sv-br[data-br] { cursor: pointer; } .sv-br svg { width: 11px; height: 11px; }
.sv-sub { display: flex; align-items: center; gap: 4px; flex-wrap: wrap; font-size: .8rem; color: #64748b; margin: 3px 0 5px; }
.sv-dob { display: inline-flex; align-items: center; gap: 3px; } .sv-dob svg { width: 13px; height: 13px; color: #f59e0b; }
.sv-chips { display: flex; align-items: center; gap: 5px; flex-wrap: wrap; }
.sv-st, .sv-lv { display: inline-flex; align-items: center; gap: 4px; font-size: .72rem; font-weight: 700; padding: 2px 8px; border-radius: 6px; border: 1px solid; }
.sv-st svg, .sv-lv svg { width: 11px; height: 11px; }
.sv-st.g { color: #15803d; background: #ecfdf3; border-color: #bbf7d0; } .sv-st.y { color: #b45309; background: #fffbeb; border-color: #fde68a; }
.sv-st.o { color: #c2410c; background: #fff7ed; border-color: #fed7aa; } .sv-st.b { color: #2a4fb8; background: #eef3fc; border-color: #c3d5f5; }
.sv-lv { color: #334155; background: #f8fafc; border-color: #e2e8f0; }
.sv-tag { display: inline-flex; align-items: center; gap: 4px; font-size: .8rem; font-weight: 600; color: #6d28d9; background: #f5f3ff; border: 1px solid #ddd6fe; padding: 2px 10px; border-radius: 999px; }
.sv-tag.sm { font-size: .7rem; padding: 1px 8px; }
.sv-tag button { border: none; background: none; color: #7c3aed; font-size: 1rem; line-height: 1; cursor: pointer; padding: 0 0 0 2px; }
.sv-addtag { display: inline-flex; align-items: center; gap: 3px; border: none; background: none; color: #2f5fd0; font: inherit; font-size: .74rem; cursor: pointer; padding: 2px 4px; }
.sv-addtag svg { width: 11px; height: 11px; } .sv-addtag:hover { text-decoration: underline; }
.sv-contact { font-size: .84rem; } .sv-contact > * { display: flex; align-items: center; gap: 5px; margin: 2px 0; color: #475569; }
.sv-contact a { color: #1c2536; font-weight: 600; } .sv-contact svg { width: 13px; height: 13px; color: #64748b; }
.sv-cls { display: flex; flex-wrap: wrap; gap: 5px; }
.sv-cls a { font-size: .76rem; font-weight: 700; color: #15803d; background: #ecfdf3; border: 1px solid #bbf7d0; padding: 2px 8px; border-radius: 6px; text-decoration: none; }
.sv-cls a.p { color: #b45309; background: #fffbeb; border-color: #fde68a; } .sv-cls a.f { color: #64748b; background: #f1f5f9; border-color: #e2e8f0; }
.sv-act { display: inline-flex; align-items: center; gap: 6px; border: none; background: #2a4fb8; color: #fff; border-radius: 8px; padding: 7px 12px; font: inherit; font-size: .82rem; font-weight: 700; cursor: pointer; white-space: nowrap; }
.sv-act:hover { background: #1f3c88; } .sv-act svg { width: 14px; height: 14px; } .sv-act svg + svg { width: 11px; height: 11px; }
.sv-rowpop { min-width: 230px; }
.sv-rowpop hr { border: none; border-top: 1px solid #edf0f5; margin: 4px 0; }
.sv-rowpop button small { display: block; margin-left: 27px; font-size: .74rem; color: #64748b; }
.sv-tagbox { display: flex; flex-wrap: wrap; gap: 6px; min-height: 34px; padding: 8px; border: 1px dashed #d5dbe5; border-radius: 10px; margin-bottom: 10px; }
.sv-tagin { display: flex; gap: 8px; } html body .sv-tagin input { flex: 1; height: 40px; }
.sv-tagsug { display: flex; flex-wrap: wrap; gap: 6px; margin: 10px 0; }
.sv-tagsug button { border: 1px solid #ddd6fe; background: #fff; color: #6d28d9; border-radius: 999px; padding: 3px 10px; font: inherit; font-size: .78rem; cursor: pointer; }
.sv-cred-act { display: flex; justify-content: flex-end; margin-top: 12px; }

/* Chi tiết học viên */
.sd-hero { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; padding: 18px 22px; border-radius: 16px; color: #fff; background: linear-gradient(100deg, #16213a, #1f3c88 55%, #4a7be6); }
.sd-hero .sv-av { border: 3px solid rgba(255,255,255,.6); }
.sd-title h2 { margin: 0; color: #fff; text-transform: uppercase; font-size: 1.35rem; }
.sd-title h2 small { text-transform: none; font-weight: 500; opacity: .85; font-size: .9rem; }
.sd-title p { margin: 4px 0 0; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; font-size: .86rem; }
.sd-title p svg { width: 14px; height: 14px; }
.sd-st { font-size: .76rem; font-weight: 700; padding: 3px 10px; border-radius: 999px; background: #6a9f3c; }
.sd-st.y { background: #d97706; } .sd-st.o { background: #ea580c; } .sd-st.b { background: #2f5fd0; }
.sd-code { font-size: .76rem; font-weight: 700; padding: 3px 10px; border-radius: 999px; background: rgba(255,255,255,.18); }
.sd-acts { margin-left: auto; display: flex; gap: 8px; flex-wrap: wrap; }
.sd-grid { display: grid; grid-template-columns: 360px minmax(0, 1fr); gap: 16px; align-items: start; }
.sd-info { display: grid; }
.sd-info > div { display: flex; gap: 12px; align-items: center; padding: 10px 0; border-bottom: 1px solid #f1f4f8; }
.sd-info .i { width: 32px; height: 32px; border-radius: 8px; display: grid; place-items: center; flex-shrink: 0; }
.sd-info .i svg { width: 15px; height: 15px; }
.sd-info .i.b { background: #e0ecff; color: #2f5fd0; } .sd-info .i.g { background: #dcfce7; color: #16a34a; } .sd-info .i.c { background: #e0f2fe; color: #0284c7; }
.sd-info .i.v { background: #ede9fe; color: #7c3aed; } .sd-info .i.y { background: #fef3c7; color: #d97706; } .sd-info .i.p { background: #fce7f3; color: #db2777; }
.sd-info small { display: block; font-size: .7rem; font-weight: 700; color: #64748b; letter-spacing: .03em; }
.sd-info b { font-size: .92rem; } .sd-info em { font-size: .86rem; color: #94a3b8; }
.sd-tags, .sd-note { display: grid !important; gap: 6px; align-items: start !important; }
.sd-tags small, .sd-note small { display: flex; align-items: center; gap: 4px; } .sd-tags small svg, .sd-note small svg { width: 12px; height: 12px; }
.sd-tags > div { display: flex; flex-wrap: wrap; gap: 5px; align-items: center; }
.sd-note p { margin: 0; font-size: .86rem; white-space: pre-wrap; background: #fffbeb; border: 1px solid #fde68a; border-radius: 8px; padding: 8px 10px; }
.sd-main { display: grid; gap: 14px; min-width: 0; }
.sd-tabs { display: flex; gap: 4px; overflow-x: auto; border-bottom: 1px solid #e5e9f0; }
.sd-tabs button { display: inline-flex; align-items: center; gap: 6px; border: none; background: none; padding: 10px 14px; font: inherit; font-size: .88rem; font-weight: 600; color: #334155; cursor: pointer; white-space: nowrap; border-bottom: 2px solid transparent; margin-bottom: -1px; border-radius: 8px 8px 0 0; }
.sd-tabs button svg { width: 15px; height: 15px; }
.sd-tabs button span { font-size: .7rem; background: #ec4899; color: #fff; padding: 0 6px; border-radius: 99px; }
.sd-tabs button:hover { background: #f5f8ff; } .sd-tabs button.on { color: #2a4fb8; border-bottom-color: #2a4fb8; background: #eef3fc; }
.sd-sec { background: #fff; border: 1px solid #e5e9f0; border-radius: 14px; overflow: hidden; }
.sd-sec-h { display: flex; align-items: center; gap: 8px; padding: 13px 18px; font-weight: 700; background: #f8fafd; border-bottom: 1px solid #edf0f5; }
.sd-sec-h svg { width: 16px; height: 16px; } .sd-sec-h > span { margin-left: auto; font-size: .76rem; font-weight: 700; padding: 3px 10px; border-radius: 999px; background: #e0ecff; color: #2a4fb8; }
.sd-sec-h.g { background: linear-gradient(90deg, #15803d, #16a34a); color: #fff; } .sd-sec-h.g > span { background: rgba(255,255,255,.22); color: #fff; }
.sd-sec-h.s { background: linear-gradient(90deg, #475569, #64748b); color: #fff; }
.sd-sec-h .sd-btn { margin-left: auto; }
.sd-sec-b { padding: 16px 18px; display: grid; gap: 14px; }
.sd-order { border: 1px solid #e5e9f0; border-radius: 12px; padding: 14px 16px; display: grid; gap: 12px; }
.sd-order .hd { display: flex; justify-content: space-between; gap: 10px; align-items: flex-start; }
.sd-order .hd b { display: inline-flex; align-items: center; gap: 6px; font-size: 1rem; } .sd-order .hd b svg { width: 16px; height: 16px; }
.sd-order .hd small { display: flex; align-items: center; gap: 4px; color: #475569; font-size: .8rem; margin-top: 3px; } .sd-order .hd small svg { width: 13px; height: 13px; }
.sd-order .hd .badge { font-size: .68rem; }
.sd-tiles { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.sd-tiles > div { background: #f8fafc; border-radius: 10px; padding: 12px; text-align: center; }
.sd-tiles b { display: block; font-size: 1.02rem; } .sd-tiles small { font-size: .7rem; color: #64748b; font-weight: 600; letter-spacing: .03em; }
.sd-tiles .b { color: #2a4fb8; } .sd-tiles .g { color: #15803d; } .sd-tiles .v { color: #7c3aed; } .sd-tiles .muted { color: #94a3b8; }
.sd-acc { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.sd-acc > div { position: relative; border: 1px solid #e5e9f0; border-radius: 10px; padding: 10px 52px 10px 12px; background: #fbfcfe; display: grid; gap: 6px; min-width: 0; }
.sd-acc small { display: flex; align-items: center; gap: 4px; font-size: .78rem; font-weight: 700; } .sd-acc small svg { width: 13px; height: 13px; }
.sd-acc small.b { color: #2a4fb8; } .sd-acc small.g { color: #15803d; } .sd-acc small.c { color: #0284c7; }
.sd-acc code { font-size: .84rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sd-acc button { position: absolute; right: 10px; top: 50%; transform: translateY(-50%); width: 34px; height: 34px; border: 1px solid #93b4f5; background: #fff; color: #2f5fd0; border-radius: 8px; display: grid; place-items: center; cursor: pointer; }
.sd-acc button svg { width: 15px; height: 15px; }
.sd-acc-act { display: flex; gap: 8px; flex-wrap: wrap; }
.sd-btn { display: inline-flex; align-items: center; gap: 6px; border: none; border-radius: 8px; padding: 8px 14px; font: inherit; font-size: .84rem; font-weight: 700; cursor: pointer; color: #fff; }
.sd-btn svg { width: 14px; height: 14px; }
.sd-btn.y { background: #d97706; } .sd-btn.y:hover { background: #b45309; } .sd-btn.b { background: #2f5fd0; } .sd-btn.b:hover { background: #2a4fb8; }
.cd-empty .aw-next { margin-top: 6px; }

/* Thêm / sửa học viên */
.sf-page { max-width: 1100px; width: 100%; margin: 0 auto; gap: 18px; padding-bottom: 80px; }
.sf-hero { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; padding: 20px 24px; border-radius: 16px; color: #fff; background: linear-gradient(100deg, #1f3c88, #2f5fd0 60%, #4a7be6); }
.sf-hero h2 { margin: 0; display: flex; align-items: center; gap: 8px; color: #fff; font-size: 1.25rem; } .sf-hero h2 svg { width: 20px; height: 20px; }
.sf-hero p { margin: 4px 0 0; font-size: .84rem; font-weight: 600; opacity: .9; text-transform: uppercase; }
.sf-badge { display: inline-flex; align-items: center; gap: 5px; background: #16a34a; border: 2px solid rgba(255,255,255,.6); border-radius: 999px; padding: 5px 12px; font-size: .8rem; font-weight: 700; }
.sf-badge svg { width: 14px; height: 14px; }
.sf-form { display: grid; gap: 18px; }
.sf-card { background: #fff; border: 1px solid #e5e9f0; border-left: 4px solid #2f5fd0; border-radius: 14px; overflow: hidden; }
.sf-card.c { border-left-color: #06b6d4; }
.sf-card h4 { display: flex; align-items: center; gap: 10px; margin: 0; padding: 14px 18px; font-size: .98rem; background: #f8fafd; border-bottom: 1px solid #edf0f5; }
.sf-card h4 svg { width: 16px; height: 16px; color: #2f5fd0; } .sf-card.c h4 svg { color: #0891b2; }
.sf-body { padding: 18px; display: grid; gap: 16px; }
.sf-row3 { display: grid; grid-template-columns: 1.3fr 1fr 1.5fr; gap: 14px; }
.sf-row2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.sf-body .cl-f label { font-weight: 600; }
.sf-body .dob .uf-hint { color: #16a34a; }
.sf-ava { display: flex; align-items: center; gap: 16px; }
.sf-ava > button { border: none; background: none; padding: 0; cursor: pointer; border-radius: 50%; }
.sf-ava > button:hover .sv-av { box-shadow: 0 0 0 4px #dbe6f8; }
.sf-ava .sv-av { background: #a855f7 !important; color: #fff !important; }
.sf-ava .sv-av:has(img) { background: #fff !important; }
.sf-bar { position: fixed; left: 50%; bottom: 16px; transform: translateX(-50%); z-index: 40; display: flex; gap: 10px; background: #fff; border: 1px solid #e5e9f0; border-radius: 14px; padding: 10px 12px; box-shadow: 0 16px 40px -16px rgba(15, 34, 87, .45); }
.sf-bar .sf-list { background: #fff; border: 1.5px solid #1c2536; }
@media (min-width: 901px) { body.admin-app .sf-bar { left: calc(50% + 125px); } body.admin-app .adm.collapsed .sf-bar { left: calc(50% + 34px); } }
@media (max-width: 1200px) { .sv-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); } .sv-frow { grid-template-columns: repeat(2, minmax(0, 1fr)); } .sv-frow .cl-search { grid-column: 1 / -1; } .sd-grid { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 720px) {
  .sv-stats, .sv-frow, .sf-row3, .sf-row2, .sd-acc { grid-template-columns: minmax(0, 1fr); } .sd-tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .sd-acts { margin-left: 0; } .sf-bar { left: 8px; right: 8px; transform: none; flex-wrap: wrap; justify-content: center; }
}

/* ==========================================================
   KHU GIẢNG VIÊN – lịch giảng dạy, điểm danh, hướng dẫn
   ========================================================== */
.tp-page svg { flex-shrink: 0; }
.tp-week { padding: 14px 16px; display: grid; gap: 12px; }
.tp-week-h { display: flex; align-items: center; justify-content: center; gap: 10px; flex-wrap: wrap; }
.tp-week-h b { display: inline-flex; align-items: center; gap: 6px; font-size: 1rem; } .tp-week-h b svg { width: 16px; height: 16px; color: #2a4fb8; }
.tp-cal .cl-cal-col .h { align-items: center; gap: 6px; } .tp-cal .cl-cal-col .h small { font-weight: 500; color: #64748b; margin-right: auto; }
.cl-cal-col.today { background: #eef4ff; border-color: #93b4f5; } .cl-cal-col.today .h { color: #2a4fb8; }
.tp-s { display: grid; gap: 3px; text-align: left; width: 100%; border: 1px solid #e5e9f0; border-left: 3px solid #f59e0b; border-radius: 10px; background: #fff; padding: 8px 10px; font: inherit; font-size: .78rem; color: #334155; cursor: pointer; }
.tp-s:hover { border-color: #93b4f5; box-shadow: 0 8px 18px -14px rgba(42, 79, 184, .7); }
.tp-s.done { border-left-color: #16a34a; } .tp-s.today { border-left-color: #2f5fd0; } .tp-s.past { border-left-color: #dc2626; }
.tp-s .t { font-weight: 800; color: #0f172a; font-size: .84rem; } .tp-s b { color: #2a4fb8; font-size: .84rem; }
.tp-s small { display: flex; align-items: center; gap: 4px; color: #64748b; } .tp-s small svg { width: 12px; height: 12px; }
.tp-s .badge { justify-self: start; font-size: .66rem; padding: 1px 8px; }
.tp-todo { overflow: hidden; }
.tp-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 10px; padding: 14px 16px; }
.tp-grid .cd-empty { grid-column: 1 / -1; }
.tp-guide { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.tp-guide > div { position: relative; display: flex; gap: 14px; padding: 18px 18px 18px 20px; }
.tp-guide .n { position: absolute; top: 12px; right: 14px; font-size: 1.6rem; font-weight: 800; color: #e2e8f0; }
.tp-guide .i { width: 42px; height: 42px; border-radius: 12px; background: #e0ecff; color: #2a4fb8; display: grid; place-items: center; flex-shrink: 0; }
.tp-guide .i svg { width: 20px; height: 20px; }
.tp-guide b { font-size: 1rem; } .tp-guide p { margin: 6px 0 0; color: #475569; font-size: .88rem; line-height: 1.55; }
.tpf-head { display: flex; align-items: center; gap: 14px; margin-bottom: 10px; }
.tpf-head b { display: block; font-size: 1.1rem; } .tpf-head small { color: #64748b; }
@media (max-width: 720px) { .tp-guide { grid-template-columns: minmax(0, 1fr); } }

/* ==========================================================
   HƯỚNG DẪN SỬ DỤNG – tài liệu trong hệ thống
   ========================================================== */
.gd-page { display: grid; gap: 16px; }
.gd-page svg { flex-shrink: 0; }
.gd-grid { display: grid; grid-template-columns: 290px minmax(0, 1fr); gap: 16px; align-items: start; }
.gd-side { position: sticky; top: 76px; max-height: calc(100vh - 96px); overflow-y: auto; padding: 12px; display: grid; gap: 10px; align-content: start; }
.gd-side .cl-search { max-width: none; } html body.admin-app .gd-side .cl-search input { height: 38px; width: 100%; }
.gd-grp-h { display: flex; align-items: center; gap: 8px; width: 100%; border: none; background: none; padding: 9px 8px; border-radius: 8px; font: inherit; font-size: .88rem; font-weight: 700; color: #1c2536; cursor: pointer; text-align: left; }
.gd-grp-h:hover { background: #f1f5fb; }
.gd-grp-h svg { width: 16px; height: 16px; color: #2a4fb8; }
.gd-grp-h span { flex: 1; }
.gd-grp-h em { font-style: normal; font-size: .66rem; font-weight: 700; background: #dcfce7; color: #15803d; padding: 1px 6px; border-radius: 99px; }
.gd-grp-h .car { width: 13px; height: 13px; color: #94a3b8; transition: transform .2s; }
.gd-grp.open .gd-grp-h .car { transform: rotate(180deg); }
.gd-grp-b { display: none; padding: 2px 0 6px 18px; border-left: 2px solid #e5e9f0; margin-left: 15px; }
.gd-grp.open .gd-grp-b { display: grid; gap: 2px; }
.gd-grp-b button { border: none; background: none; text-align: left; padding: 7px 10px; border-radius: 7px; font: inherit; font-size: .86rem; color: #475569; cursor: pointer; }
.gd-grp-b button:hover { background: #f5f8ff; color: #2a4fb8; }
.gd-grp-b button.on { background: #eef3fc; color: #2a4fb8; font-weight: 700; box-shadow: inset 3px 0 0 #2a4fb8; }
.gd-doc { padding: 24px 30px 20px; min-width: 0; }
.gd-crumb { display: flex; align-items: center; gap: 6px; font-size: .8rem; color: #64748b; } .gd-crumb svg { width: 13px; height: 13px; }
.gd-doc h1 { margin: 8px 0 16px; font-size: 1.6rem; color: #0f172a; }
.gd-body { font-size: .95rem; line-height: 1.7; color: #334155; }
.gd-body h3 { margin: 22px 0 8px; font-size: 1.08rem; color: #0f172a; }
.gd-body p { margin: 0 0 12px; }
.gd-body code { background: #f1f5f9; border: 1px solid #e2e8f0; border-radius: 5px; padding: 0 5px; font-size: .86em; }
.gd-steps { counter-reset: st; list-style: none; padding: 0; margin: 8px 0 14px; display: grid; gap: 10px; }
.gd-steps li { counter-increment: st; position: relative; padding: 10px 14px 10px 50px; background: #f8fafd; border: 1px solid #e8edf4; border-radius: 10px; }
.gd-steps li::before { content: counter(st); position: absolute; left: 12px; top: 9px; width: 26px; height: 26px; border-radius: 50%; background: #2a4fb8; color: #fff; font-weight: 800; font-size: .82rem; display: grid; place-items: center; }
.gd-ul { margin: 6px 0 14px; padding-left: 22px; display: grid; gap: 6px; }
.gd-call { border-radius: 10px; padding: 12px 16px; margin: 12px 0; border: 1px solid; font-size: .9rem; }
.gd-call > b { display: block; margin-bottom: 4px; }
.gd-call.tip { background: #f0fdf4; border-color: #bbf7d0; } .gd-call.tip > b { color: #15803d; }
.gd-call.warn { background: #fffbeb; border-color: #fde68a; } .gd-call.warn > b { color: #b45309; }
.gd-call.note { background: #eef3fc; border-color: #c3d5f5; } .gd-call.note > b { color: #2a4fb8; }
.gd-tbl { margin: 10px 0 14px; } .gd-tbl table { min-width: 560px; } .gd-tbl td { font-size: .88rem; vertical-align: top; }
.gd-go { display: inline-flex; align-items: center; gap: 6px; margin-top: 10px; border: none; background: #2a4fb8; color: #fff; border-radius: 9px; padding: 9px 16px; font: inherit; font-weight: 700; font-size: .88rem; cursor: pointer; }
.gd-go:hover { background: #1f3c88; }
.gd-pn { display: flex; justify-content: space-between; gap: 12px; margin-top: 28px; padding-top: 16px; border-top: 1px solid #edf0f5; }
.gd-pn button { border: 1px solid #e5e9f0; background: #fff; border-radius: 10px; padding: 10px 16px; font: inherit; text-align: left; cursor: pointer; max-width: 48%; }
.gd-pn button:hover { border-color: #93b4f5; } .gd-pn button.nx { text-align: right; margin-left: auto; }
.gd-pn small { display: block; color: #64748b; font-size: .76rem; } .gd-pn b { color: #2a4fb8; font-size: .9rem; }
@media (max-width: 900px) { .gd-grid { grid-template-columns: minmax(0, 1fr); } .gd-side { position: static; max-height: none; } .gd-doc { padding: 18px; } }

/* ==========================================================
   TỔNG QUAN (dashboard)
   ========================================================== */
.db-page { display: grid; gap: 16px; }
.db-page svg { flex-shrink: 0; }
.db-ver { display: flex; align-items: center; justify-content: flex-end; gap: 5px; font-size: .78rem; color: #64748b; margin-bottom: -8px; } .db-ver svg { width: 13px; height: 13px; }
.db-kpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
.db-kpi { position: relative; overflow: hidden; border-radius: 14px; padding: 18px 20px; color: #fff; min-height: 112px; box-shadow: 0 12px 26px -16px rgba(15, 34, 87, .7); }
.db-kpi.b { background: linear-gradient(120deg, #0f2257, #2a4fb8); } .db-kpi.g { background: linear-gradient(120deg, #0d9488, #22c55e); }
.db-kpi.c { background: linear-gradient(120deg, #1f3c88, #2f5fd0); } .db-kpi.o { background: linear-gradient(120deg, #ec4899, #f97316 60%, #facc15); }
.db-kpi[data-goview] { cursor: pointer; }
.db-kpi > small { font-size: .7rem; font-weight: 800; letter-spacing: .04em; opacity: .9; }
.db-kpi > b { display: block; font-size: 1.7rem; line-height: 1.3; margin: 6px 0 2px; }
.db-kpi > em { font-style: normal; font-size: .78rem; display: flex; align-items: center; gap: 4px; opacity: .92; } .db-kpi > em svg { width: 12px; height: 12px; }
.db-kpi > span { position: absolute; right: 16px; top: 50%; transform: translateY(-50%); opacity: .35; } .db-kpi > span svg { width: 40px; height: 40px; }
.db-ring-row { display: flex; align-items: center; gap: 12px; margin-top: 8px; }
.db-ring { --p: 0; width: 62px; height: 62px; border-radius: 50%; flex-shrink: 0; display: grid; place-content: center; text-align: center; background: radial-gradient(closest-side, #1f3c88 78%, transparent 80% 100%), conic-gradient(#fff calc(var(--p) * 1%), rgba(255,255,255,.25) 0); }
.db-ring b { font-size: .86rem; line-height: 1; } .db-ring small { font-size: .56rem; opacity: .85; }
.db-ring-row ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; font-size: .72rem; }
.db-ring-row li { display: flex; align-items: center; gap: 5px; } .db-ring-row li i { width: 7px; height: 7px; border-radius: 50%; } .db-ring-row i.g { background: #4ade80; } .db-ring-row i.y { background: #facc15; }
.db-grid { display: grid; grid-template-columns: minmax(0, 1.9fr) minmax(300px, 1fr); gap: 16px; align-items: start; }
.db-main, .db-side { display: grid; gap: 16px; min-width: 0; }
.db-card { background: #fff; border: 1px solid #e5e9f0; border-radius: 14px; overflow: hidden; }
.db-card-h { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 12px 16px; color: #fff; }
.db-card-h > b { display: inline-flex; align-items: center; gap: 7px; font-size: .92rem; } .db-card-h > b svg { width: 16px; height: 16px; }
.db-card-h.blue { background: linear-gradient(100deg, #1f3c88, #2f5fd0 60%, #4a7be6); } .db-card-h.purple { background: linear-gradient(100deg, #6d28d9, #7c3aed); }
.db-card-h.orange { background: linear-gradient(100deg, #b45309, #d97706); } .db-card-h.green { background: linear-gradient(100deg, #047857, #10b981); }
.db-card-h.light { background: linear-gradient(100deg, #fff1f2, #fff); color: #1c2536; border-bottom: 1px solid #fde2e4; }
.db-date { margin-left: auto; font-size: .72rem; font-weight: 700; background: rgba(255,255,255,.2); padding: 2px 10px; border-radius: 999px; }
.db-seg { flex-basis: 100%; display: inline-flex; gap: 4px; background: rgba(255,255,255,.15); padding: 3px; border-radius: 999px; width: max-content; }
.db-seg button { border: none; background: none; color: #fff; font: inherit; font-size: .76rem; font-weight: 700; padding: 4px 12px; border-radius: 999px; cursor: pointer; display: inline-flex; gap: 5px; align-items: center; }
.db-seg button span { background: rgba(255,255,255,.25); padding: 0 6px; border-radius: 99px; font-size: .68rem; }
.db-seg button.on { background: #fff; color: #2a4fb8; } .db-seg button.on span { background: #e0ecff; }
.db-today-list { max-height: 320px; overflow-y: auto; }
.db-ts { display: flex; align-items: center; gap: 12px; padding: 12px 16px; border-bottom: 1px solid #f1f4f8; }
.db-ts .ic { width: 38px; height: 38px; border-radius: 10px; background: #2a4fb8; color: #fff; display: grid; place-items: center; flex-shrink: 0; } .db-ts .ic svg { width: 18px; height: 18px; }
.db-ts .bd { flex: 1; min-width: 0; display: grid; gap: 2px; } .db-ts .bd b { font-size: .9rem; }
.db-ts .bd small { display: flex; align-items: center; gap: 4px; font-size: .76rem; color: #64748b; } .db-ts .bd small svg { width: 12px; height: 12px; }
.db-time { font-size: .7rem; font-weight: 700; color: #fff; background: #dc2626; padding: 1px 8px; border-radius: 6px; margin-left: 6px; }
.db-time.ok { background: #16a34a; } .db-time.late { background: #b91c1c; box-shadow: 0 0 0 2px #fecaca; }
.db-ts .ac { display: grid; gap: 6px; justify-items: end; } .db-ts .ac > div { display: flex; gap: 4px; }
.db-hsb { font-size: .7rem; font-weight: 700; color: #fff; background: #2f5fd0; padding: 1px 8px; border-radius: 6px; }
.db-btn { display: inline-flex; align-items: center; gap: 4px; border: 1px solid #2a4fb8; background: #fff; color: #2a4fb8; border-radius: 6px; padding: 4px 9px; font: inherit; font-size: .74rem; font-weight: 700; cursor: pointer; white-space: nowrap; }
.db-btn svg { width: 12px; height: 12px; } .db-btn.g { background: #6a9f3c; border-color: #6a9f3c; color: #fff; } .db-btn:hover { filter: brightness(.95); }
.db-all { margin-left: auto; border: 1px solid rgba(255,255,255,.6); background: rgba(255,255,255,.12); color: #fff; border-radius: 999px; padding: 3px 12px; font: inherit; font-size: .74rem; font-weight: 700; cursor: pointer; }
.db-recent { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; padding: 14px 16px; }
.db-rc { border: 1px solid #e5e9f0; border-radius: 10px; padding: 12px 14px; display: grid; gap: 6px; }
.db-rc .hd { display: flex; justify-content: space-between; gap: 8px; align-items: flex-start; } .db-rc .hd b { font-size: .88rem; } .db-rc .hd .badge { font-size: .66rem; white-space: nowrap; }
.db-rc small { display: flex; align-items: center; gap: 4px; flex-wrap: wrap; font-size: .76rem; color: #64748b; } .db-rc small svg { width: 12px; height: 12px; }
.db-rc .ft { display: flex; justify-content: space-between; align-items: center; }
.db-hs { display: inline-flex; align-items: center; gap: 4px; font-size: .7rem; font-weight: 700; color: #fff; background: #ea580c; padding: 2px 8px; border-radius: 6px; } .db-hs svg { width: 11px; height: 11px; }
.db-ach { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; padding: 14px; }
.db-ach > div { border: 1px solid #edf0f5; border-radius: 10px; padding: 12px; display: grid; gap: 3px; background: #fbfcfe; }
.db-ach .i { width: 30px; height: 30px; border-radius: 8px; display: grid; place-items: center; color: #fff; margin-bottom: 4px; } .db-ach .i svg { width: 15px; height: 15px; }
.db-ach .i.g { background: #10b981; } .db-ach .i.b { background: #4a7be6; } .db-ach .i.v { background: #8b5cf6; } .db-ach .i.y { background: #f59e0b; }
.db-ach b { font-size: 1.3rem; } .db-ach small { font-size: .66rem; font-weight: 800; color: #475569; letter-spacing: .03em; } .db-ach em { font-style: normal; font-size: .7rem; color: #94a3b8; }
.db-ach .bar { margin-top: 4px; } .db-ach .bar.y > i { background: #f59e0b; }
.db-tr { font-size: .66rem; font-weight: 800; padding: 0 5px; border-radius: 4px; } .db-tr.up { background: #dcfce7; color: #15803d; } .db-tr.down { background: #fee2e2; color: #b91c1c; }
.db-notice .db-card-h .bell { width: 34px; height: 34px; border-radius: 10px; background: #f97316; color: #fff; display: grid; place-items: center; } .db-notice .db-card-h .bell svg { width: 17px; height: 17px; }
.db-notice .db-card-h small { display: block; font-size: .62rem; font-weight: 800; color: #f97316; } .db-notice .db-card-h div b { font-size: .92rem; }
.db-ntc { padding: 12px 14px; display: grid; gap: 8px; min-height: 110px; align-content: start; }
.db-ntc button { text-align: left; border: 1px solid; border-radius: 10px; padding: 9px 12px; font: inherit; background: #fff; cursor: default; display: grid; gap: 2px; }
.db-ntc button[data-goview] { cursor: pointer; }
.db-ntc b { font-size: .84rem; } .db-ntc small { font-size: .74rem; color: #64748b; }
.db-ntc .warn { border-color: #fde68a; background: #fffbeb; } .db-ntc .danger { border-color: #fecaca; background: #fef2f2; } .db-ntc .info { border-color: #c3d5f5; background: #eef3fc; }
.db-quick { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; padding: 14px; }
.db-quick button { display: flex; align-items: center; gap: 8px; border: none; border-radius: 10px; padding: 14px 12px; color: #fff; font: inherit; font-size: .84rem; font-weight: 700; cursor: pointer; text-align: left; }
.db-quick button svg { width: 18px; height: 18px; padding: 6px; box-sizing: content-box; background: rgba(255,255,255,.2); border-radius: 8px; }
.db-quick .b { background: linear-gradient(120deg, #0f2257, #2a4fb8); } .db-quick .g { background: linear-gradient(120deg, #047857, #10b981); } .db-quick .o { background: linear-gradient(120deg, #92400e, #d97706); }
.db-quick button:hover { filter: brightness(1.08); }
.db-count-b { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; padding: 14px 18px; }
.db-count-b > div { display: flex; justify-content: space-between; align-items: center; gap: 10px; border-right: 1px solid #edf0f5; padding-right: 12px; }
.db-count-b > div:last-child { border-right: none; }
.db-count-b small { color: #475569; font-size: .84rem; } .db-count-b b { font-size: 1.5rem; color: #d97706; } .db-count-b b.g { color: #16a34a; } .db-count-b b.b { color: #2a4fb8; }
@media (max-width: 1200px) { .db-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); } .db-grid { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 720px) { .db-kpis, .db-recent, .db-count-b { grid-template-columns: minmax(0, 1fr); } .db-count-b > div { border-right: none; padding-right: 0; } .db-ts { flex-wrap: wrap; } .db-ts .ac { justify-items: start; width: 100%; } }

/* ---------- Chân trang: link nhanh ---------- */
.site-footer .foot-links { display: flex; flex-wrap: wrap; gap: 4px 16px; margin-top: 8px; }
.site-footer .foot-links a { color: var(--brand); font-weight: 600; }

/* ---------- Lịch khai giảng (/lich-khai-giang) ---------- */
.filters.ks-filters { grid-template-columns: 1fr 1fr 2fr; }
@media (max-width: 700px) { .filters.ks-filters { grid-template-columns: 1fr 1fr; } .filters.ks-filters > :first-child { grid-column: auto; } .filters.ks-filters > :last-child { grid-column: 1 / -1; } }
.ks-list { display: grid; gap: 22px; }
.ks-month h2 { font-size: 1.1rem; margin: 0 0 10px; display: flex; align-items: center; gap: 10px; }
.ks-month h2 span { font-size: .8rem; font-weight: 600; color: var(--ink-2); background: var(--brand-50); border-radius: 999px; padding: 2px 10px; }
.ks-row { display: grid; grid-template-columns: 96px minmax(0, 1fr) 200px; gap: 16px; align-items: center; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 14px 16px; margin-bottom: 10px; }
.ks-row.full { opacity: .7; }
.ks-date { display: grid; justify-items: center; gap: 1px; padding: 8px 4px; border-radius: 10px; background: linear-gradient(160deg, var(--brand), var(--brand-dark)); color: #fff; text-align: center; }
.ks-date small { font-size: .62rem; text-transform: uppercase; letter-spacing: .05em; opacity: .85; }
.ks-date b { font-size: 1.8rem; line-height: 1.05; }
.ks-date span { font-size: .78rem; font-weight: 600; }
.ks-date em { font-style: normal; font-size: .7rem; background: rgba(255,255,255,.18); border-radius: 999px; padding: 0 8px; margin-top: 2px; }
.ks-main h3 { margin: 0 0 6px; font-size: 1.05rem; }
.ks-main h3 a { color: var(--ink); }
.ks-meta { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.ks-slots { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.ks-slots span { font-size: .8rem; font-weight: 600; color: var(--brand); background: var(--brand-50); border: 1px solid var(--brand-100); border-radius: 8px; padding: 3px 9px; }
.ks-side { display: grid; justify-items: end; gap: 6px; text-align: right; }
.ks-seat { font-size: .82rem; font-weight: 700; color: var(--ok); }
.ks-seat.few { color: var(--warn); }
.ks-seat.full { color: var(--danger); }
.ks-fee { font-weight: 800; color: var(--brand); }
.ks-acts { display: flex; gap: 6px; flex-wrap: wrap; justify-content: flex-end; }
@media (max-width: 760px) {
  .ks-row { grid-template-columns: 76px minmax(0, 1fr); }
  .ks-side { grid-column: 1 / -1; grid-template-columns: 1fr auto; justify-items: start; align-items: center; text-align: left; border-top: 1px dashed var(--line); padding-top: 10px; }
  .ks-acts { grid-column: 1 / -1; justify-content: stretch; }
  .ks-acts .btn { flex: 1; }
  .ks-date b { font-size: 1.5rem; }
}

/* ---------- Liên hệ (/lien-he) ---------- */
.lh-wrap { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 520px); gap: 32px; align-items: start; }
.lh-kicker { display: inline-block; font-size: .78rem; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; color: var(--gold-600); background: var(--gold-50); border-radius: 999px; padding: 4px 12px; }
.lh-intro h1 { font-size: 1.9rem; line-height: 1.25; margin: 12px 0 10px; }
.lh-points { list-style: none; padding: 0; margin: 20px 0; display: grid; gap: 12px; }
.lh-points li { display: grid; gap: 2px; padding-left: 34px; position: relative; }
.lh-points li::before { content: "✓"; position: absolute; left: 0; top: 0; width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; background: var(--ok-soft); color: var(--ok); font-weight: 800; font-size: .8rem; }
.lh-points span { color: var(--ink-2); font-size: .9rem; }
.lh-links { display: flex; flex-wrap: wrap; gap: 10px; margin: 16px 0; }
.lh-branches h3 { font-size: .95rem; margin: 18px 0 8px; }
.lh-branches div { display: flex; flex-wrap: wrap; gap: 8px; }
.lh-branches span { background: var(--card); border: 1px solid var(--line); border-radius: 999px; padding: 5px 12px; font-size: .85rem; font-weight: 600; }
.lh-card { padding: 24px; }
.lh-card h2 { margin: 0 0 16px; font-size: 1.25rem; }
.lh-hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.lh-ok { text-align: center; padding: 20px 4px; }
.lh-ok .ic { width: 64px; height: 64px; margin: 0 auto 12px; border-radius: 50%; display: grid; place-items: center; background: var(--ok-soft); color: var(--ok); font-size: 2rem; font-weight: 800; }
.lh-ok .lh-links { justify-content: center; }
@media (max-width: 900px) { .lh-wrap { grid-template-columns: minmax(0, 1fr); } .lh-intro h1 { font-size: 1.5rem; } }
@media (max-width: 560px) { .lh-card .form-grid { grid-template-columns: minmax(0, 1fr); } }/* Ảnh bìa khóa học */
/* Thẻ có ảnh bìa: khung đúng tỉ lệ 16:9 → hiện trọn ảnh, không lẹm chữ; nhãn danh mục thu nhỏ ở góc phải trên */
.course-cover.has-img { height: auto; aspect-ratio: 16 / 9; padding: 0; }
.course-cover.has-img .badge { position: absolute; top: 8px; right: 8px; font-size: .68rem; padding: 2px 8px; box-shadow: 0 2px 6px rgba(0,0,0,.15); }
.course-cover.has-img .match { position: absolute; right: 8px; bottom: 8px; }
.cd-cover { display: block; width: calc(100% + 40px); max-width: none; margin: -20px -20px 16px; aspect-ratio: 16 / 9; object-fit: cover; border-radius: var(--radius) var(--radius) 0 0; }

/* ===== Logo TK (ảnh tròn) thay ô chữ 汉 ===== */
html body img.tk-logo.tk-logo.tk-logo { display: block; flex: 0 0 auto; object-fit: contain; border-radius: 50%; background: none; box-shadow: none; padding: 0; }
html body .site-header img.logo-mark { width: 44px; height: 44px; }
html body .hlogo img.mark { width: 52px; height: 52px; }
html body .hfoot img.brand-mark { width: 84px; height: 84px; background: #fff; padding: 3px; box-shadow: 0 6px 18px -6px rgba(0,0,0,.35); }
html body .auth-logo img.logo-mark { width: 96px; height: 96px; filter: drop-shadow(0 8px 16px rgba(31,60,136,.25)); }
html body .xp-bar img.logo-mark { width: 34px; height: 34px; }
@media (max-width: 560px) { html body .auth-logo img.logo-mark { width: 72px; height: 72px; } }

/* Thanh đầu trang phụ: logo + "Trung tâm Ngoại ngữ / Tuấn Kiệt" */
html body .site-header .logo { gap: 12px; }
html body .site-header .logo-txt { display: flex; flex-direction: column; line-height: 1.2; }
html body .site-header .logo-txt small { font-family: "Montserrat", "Be Vietnam Pro", sans-serif; font-size: 10.5px; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; color: #4a5f99; margin: 0 0 3px; }
html body .site-header .logo-txt b { font-family: "Montserrat", "Be Vietnam Pro", sans-serif; font-size: 19px; font-weight: 800; letter-spacing: .03em; text-transform: uppercase; color: #1f3c88; }
@media (max-width: 420px) { html body .site-header .logo-txt small { font-size: 9px; letter-spacing: .08em; } html body .site-header .logo-txt b { font-size: 16px; } }

/* Lịch khai giảng – phân trang 10 lớp / trang */
.ks-pager { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; padding-top: 4px; }
.ks-pager .btns { display: flex; align-items: center; gap: 6px; }
.ks-pager button { min-width: 38px; height: 38px; padding: 0 10px; border: 1px solid var(--brand-100); background: #fff; color: var(--ink); border-radius: 10px; font: inherit; font-weight: 600; cursor: pointer; transition: all .15s; }
.ks-pager button:hover:not(:disabled) { border-color: var(--brand); color: var(--brand); }
.ks-pager button.on { background: var(--brand); border-color: var(--brand); color: #fff; }
.ks-pager button:disabled { opacity: .4; cursor: default; }
.ks-pager .gap { padding: 0 2px; color: var(--ink-3); }
@media (max-width: 560px) { .ks-pager { justify-content: center; } }

/* ===================== Trang Tài liệu (/tai-lieu) ===================== */
.dl-head h1 { font-size: 1.6rem; margin: 2px 0 4px; }
.dl-head .eyebrow { color: var(--brand); font-weight: 800; font-size: .78rem; letter-spacing: .12em; text-transform: uppercase; }
.dl-bar { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; justify-content: space-between; margin: 6px 0 20px; scroll-margin-top: 90px; }
.dl-cats { display: flex; gap: 8px; flex-wrap: wrap; }
.dl-cats button { border: 1px solid var(--brand-100); background: #fff; color: var(--ink); border-radius: 999px; padding: 8px 14px; font: inherit; font-size: .88rem; font-weight: 600; cursor: pointer; display: inline-flex; align-items: center; gap: 6px; transition: all .15s; }
.dl-cats button span { font-size: .74rem; background: var(--brand-50); color: var(--brand); border-radius: 999px; padding: 1px 7px; }
.dl-cats button:hover { border-color: var(--brand); color: var(--brand); }
.dl-cats button.on { background: var(--brand); border-color: var(--brand); color: #fff; }
.dl-cats button.on span { background: rgba(255,255,255,.2); color: #fff; }
.dl-search { flex: 0 1 340px; display: flex; align-items: center; gap: 8px; background: #fff; border: 1px solid var(--brand-100); border-radius: 12px; padding: 0 12px; }
.dl-search svg { width: 18px; height: 18px; color: var(--ink-3); flex: 0 0 auto; }
.dl-search input { border: 0; outline: none; background: transparent; flex: 1; min-height: 42px; font: inherit; font-size: .92rem; }
.dl-search:focus-within { border-color: var(--brand); box-shadow: 0 0 0 3px rgba(31, 60, 136, .12); }
.dl-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 20px; margin-bottom: 18px; }
.dl-card { background: #fff; border: 1px solid var(--line); border-radius: 16px; overflow: hidden; display: flex; flex-direction: column; transition: transform .18s, box-shadow .18s; }
.dl-card:hover { transform: translateY(-4px); box-shadow: 0 22px 44px -24px rgba(15, 23, 42, .35); }
.dl-cover { all: unset; box-sizing: border-box; position: relative; display: block; aspect-ratio: 4 / 3; overflow: hidden; cursor: pointer; background: #eef3fc; }
.dl-cover img, .dl-pop-cover img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .35s; }
.dl-card:hover .dl-cover img { transform: scale(1.04); }
.dl-ph { position: absolute; inset: 0; display: grid; place-items: center; }
.dl-ph.c0 { background: linear-gradient(135deg, #e8f0fc, #bcd3f5); } .dl-ph.c1 { background: linear-gradient(135deg, #fff6e0, #ffe0a3); }
.dl-ph.c2 { background: linear-gradient(135deg, #e6f4ee, #b8e0cc); } .dl-ph.c3 { background: linear-gradient(135deg, #2a4fae, #0f2257); }
.dl-ph .hz { font-family: var(--font-hanzi, serif); font-size: 76px; font-weight: 700; color: var(--brand); line-height: 1; }
.dl-ph.c3 .hz, .dl-ph.c3 .brand { color: #fff; }
.dl-ph .brand { position: absolute; bottom: 10px; font-size: .7rem; font-weight: 900; letter-spacing: .12em; color: var(--brand); }
.dl-hot { position: absolute; top: 10px; left: 10px; background: #f59e0b; color: #fff; font-size: .72rem; font-weight: 800; padding: 3px 9px; border-radius: 999px; box-shadow: 0 4px 10px -4px rgba(245, 158, 11, .7); }
.dl-body { padding: 14px 16px 16px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.dl-tags { display: flex; gap: 6px; flex-wrap: wrap; }
.dl-tag { background: var(--brand-50); color: var(--brand); font-size: .74rem; font-weight: 800; padding: 3px 8px; border-radius: 6px; }
.dl-lv { background: #fef3c7; color: #92400e; font-size: .74rem; font-weight: 700; padding: 3px 8px; border-radius: 6px; }
.dl-body h3 { margin: 0; font-size: 1rem; line-height: 1.4; }
.dl-body h3 button { all: unset; cursor: pointer; color: var(--ink); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.dl-body h3 button:hover { color: var(--brand); }
.dl-body p { margin: 0; color: var(--ink-2); font-size: .86rem; line-height: 1.5; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.dl-meta { display: flex; gap: 12px; flex-wrap: wrap; font-size: .8rem; color: var(--ink-2); }
.dl-meta span { display: inline-flex; align-items: center; gap: 4px; }
.dl-meta svg { width: 14px; height: 14px; }
.dl-meta .ft { color: var(--brand); font-weight: 700; }
.dl-btn { margin-top: auto; display: inline-flex; align-items: center; justify-content: center; gap: 6px; width: 100%; }
.dl-btn svg { width: 16px; height: 16px; }
.dl-empty { padding: 40px 20px; text-align: center; }
.dl-pop { position: fixed; inset: 0; z-index: 1000; background: rgba(15, 23, 42, .5); -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px); display: grid; place-items: center; padding: 16px; animation: dlFade .18s ease-out; }
.dl-pop-box { position: relative; width: 100%; max-width: 760px; max-height: calc(100vh - 32px); overflow: auto; background: #fff; border-radius: 20px; display: grid; grid-template-columns: 300px minmax(0, 1fr); box-shadow: 0 30px 80px -20px rgba(15, 23, 42, .5); animation: dlPop .25s cubic-bezier(.2, .9, .3, 1.2); }
.dl-pop-cover { position: relative; min-height: 260px; background: #eef3fc; }
.dl-pop-body { padding: 26px 24px 22px; display: flex; flex-direction: column; gap: 12px; }
.dl-pop-body h2 { margin: 0; font-size: 1.25rem; line-height: 1.35; }
.dl-pop-body p { margin: 0; color: var(--ink-2); line-height: 1.6; white-space: pre-line; }
.dl-x { position: absolute; top: 10px; right: 10px; z-index: 2; width: 34px; height: 34px; border-radius: 50%; border: 0; background: rgba(255,255,255,.92); color: var(--ink); font-size: 1.4rem; line-height: 1; cursor: pointer; box-shadow: 0 2px 8px rgba(0,0,0,.15); }
@keyframes dlFade { from { opacity: 0; } }
@keyframes dlPop { from { opacity: 0; transform: translateY(10px) scale(.96); } }
@media (max-width: 640px) { .dl-search { flex: 1 1 100%; } .dl-pop-box { grid-template-columns: 1fr; } .dl-pop-cover { aspect-ratio: 4 / 3; min-height: 0; } .dl-cats { overflow-x: auto; flex-wrap: nowrap; padding-bottom: 4px; } .dl-cats button { flex: 0 0 auto; } }

/* Tài liệu – nút Xem + Tải về */
.doc-btns { display: flex; gap: 8px; margin-top: auto; }
.doc-btns > * { flex: 1 1 0; min-width: 0; display: inline-flex; align-items: center; justify-content: center; gap: 6px; white-space: nowrap; margin: 0; }
.doc-btns svg { width: 16px; height: 16px; flex: 0 0 auto; }
.dl-body .doc-btns .dl-btn { width: auto; }

/* ===== Menu "Giới thiệu" thả xuống (thanh menu trang chủ + trang phụ) ===== */
.nav-dd { position: relative; display: flex; align-items: center; }
.nav-dd[hidden] { display: none; }
html body .nav-dd .nav-dd-t { display: inline-flex; align-items: center; gap: 4px; }
.nav-dd-c { width: 14px; height: 14px; transition: transform .2s; }
.nav-dd-m { position: absolute; top: calc(100% + 6px); left: 0; min-width: 270px; z-index: 60; background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 6px;
  box-shadow: 0 22px 48px -18px rgba(15, 23, 42, .35); display: flex; flex-direction: column; opacity: 0; visibility: hidden; transform: translateY(6px); transition: opacity .18s, transform .18s, visibility .18s; }
.nav-dd-m::before { content: ""; position: absolute; left: 0; right: 0; top: -10px; height: 10px; }   /* cầu nối để rê chuột không bị mất menu */
html body .nav-dd-m a { display: block; padding: 10px 14px; border-radius: 10px; color: var(--ink); font-weight: 500; font-size: .92rem; white-space: nowrap; background: none; }
html body .nav-dd-m a:hover { background: var(--brand-50); color: var(--brand); text-decoration: none; }
@media (hover: hover) and (min-width: 1001px) {
  .nav-dd:hover .nav-dd-m, .nav-dd:focus-within .nav-dd-m { opacity: 1; visibility: visible; transform: none; }
  .nav-dd:hover .nav-dd-c { transform: rotate(180deg); }
}
.nav-dd.open .nav-dd-m { opacity: 1; visibility: visible; transform: none; }
.nav-dd.open .nav-dd-c { transform: rotate(180deg); }
/* Menu thu gọn (điện thoại): danh sách hiện ngay bên dưới, thụt lề */
@media (max-width: 1000px) {
  .hhead .nav-dd { flex-direction: column; align-items: stretch; }
  .hhead .nav-dd-m { position: static; box-shadow: none; border: 0; padding: 0 0 0 12px; min-width: 0; display: none; opacity: 1; visibility: visible; transform: none; }
  .hhead .nav-dd.open .nav-dd-m { display: flex; }
}
@media (max-width: 1000px) {
  .site-header .nav-dd { flex-direction: column; align-items: stretch; }
  .site-header .nav-dd-m { position: static; box-shadow: none; border: 0; padding: 0 0 0 12px; min-width: 0; display: none; opacity: 1; visibility: visible; transform: none; }
  .site-header .nav-dd.open .nav-dd-m { display: flex; }
  html body .nav-dd-m a { white-space: normal; }
}
/* Thanh menu trang phụ: không xuống dòng chữ */
@media (min-width: 1001px) {
  html body .site-header .nav { gap: 2px; }
  html body .site-header .nav > a, html body .site-header .nav-dd-t { white-space: nowrap; padding: 8px 10px; font-size: .94rem; }
}
@media (min-width: 1001px) and (max-width: 1240px) {
  html body .site-header .logo-txt small { display: none; }
  html body .site-header .nav > a, html body .site-header .nav-dd-t { padding: 8px 7px; font-size: .9rem; }
}
html body .nav-dd-m a.on { color: var(--brand); font-weight: 700; background: var(--brand-50); }

/* ==========================================================
   ĐỒNG BỘ GIAO DIỆN TOÀN HỆ THỐNG – lấy ngôn ngữ thiết kế trang chủ làm gốc
   Màu: xanh logo #1f3c88 → #0f2257, điểm nhấn vàng lúa #f2b53a
   Hero: nền xanh đậm + quầng sáng; Nút: phản chiếu kính; Thẻ: bo 14px, nổi nhẹ khi rê chuột
   ========================================================== */
:root {
  --hero-grad: radial-gradient(900px 420px at 12% 0%, rgba(255,255,255,.14), transparent 60%),
               radial-gradient(420px 260px at 100% 100%, rgba(242,181,58,.20), transparent 70%),
               linear-gradient(120deg, #0b1d4d 0%, #16307a 45%, #2a4fb8 100%);
  --hero-shadow: 0 14px 34px -16px rgba(15, 34, 87, .6);
  --lift-shadow: 0 16px 36px -18px rgba(15, 34, 87, .32);
  --ease-out: cubic-bezier(.22, .8, .3, 1);
}
/* Biểu tượng nét mảnh (tkIcon) đặt cạnh chữ */
.tki { width: 1.1em; height: 1.1em; display: inline-block; vertical-align: -.2em; flex: none; }
.gd-dot { display: inline-block; width: .7em; height: .7em; border-radius: 50%; margin-right: 5px; vertical-align: .02em; }
.gd-dot.g { background: #16a34a; } .gd-dot.y { background: #eab308; } .gd-dot.r { background: #dc2626; } .gd-dot.b { background: #2f5fd0; }

/* Nút bấm: chuyển động mượt, nhấc nhẹ khi rê chuột (như trang chủ) */
html body .btn, html body .bk-btn, html body .aw-next { transition: transform .18s var(--ease-out), box-shadow .18s, background-color .15s, border-color .15s, color .15s; }
html body .btn:not(:disabled):hover { transform: translateY(-1px); }
html body .btn:not(:disabled):active { transform: translateY(0); }
html body .btn.secondary:hover { border-color: rgba(31, 60, 136, .35); color: var(--brand); }

/* Ô nhập: viền sáng xanh logo khi chọn */
html body input:not([type=checkbox]):not([type=radio]):focus, html body select:focus, html body textarea:focus {
  border-color: var(--brand); box-shadow: 0 0 0 3px rgba(31, 60, 136, .12); outline: none; }
html body input[type=checkbox], html body input[type=radio] { accent-color: var(--brand); }

/* ---------- Khu quản trị ---------- */
html body.admin-app { background: #f2f5fb; }
html body.admin-app .adm-side {
  background: radial-gradient(420px 300px at 0% 0%, rgba(255,255,255,.12), transparent 60%),
              radial-gradient(300px 260px at 100% 100%, rgba(242,181,58,.12), transparent 70%),
              linear-gradient(180deg, #13296b 0%, #1f3c88 60%, #22428f 100%); }
html body.admin-app .adm-grp-b button { transition: background-color .15s, transform .15s var(--ease-out); }
html body.admin-app .adm-grp-b button:hover { background: rgba(255,255,255,.1); transform: translateX(2px); }
html body.admin-app .adm-grp-b button.active { background: rgba(255,255,255,.16); box-shadow: inset 3px 0 0 var(--gold); }
html body.admin-app .adm-grp-b button.active svg { color: var(--gold); opacity: 1; }
html body.admin-app .adm-top { background: rgba(255,255,255,.82); -webkit-backdrop-filter: saturate(180%) blur(16px); backdrop-filter: saturate(180%) blur(16px);
  border-bottom: 1px solid #e3e9f3; box-shadow: 0 4px 20px -14px rgba(15, 34, 87, .3); }
html body.admin-app .card, html body.admin-app .cl-card, html body.admin-app .stat { border-radius: 14px; border-color: #e3e9f3; }
html body.admin-app .card, html body.admin-app .cl-card { transition: box-shadow .2s, border-color .2s; }
html body.admin-app .card:hover, html body.admin-app .cl-card:hover { box-shadow: var(--lift-shadow); border-color: #d6e0f0; }
html body.admin-app .btn:not(.secondary):not(.ghost):not(.danger) {
  background-color: var(--brand); background-image: linear-gradient(180deg, rgba(255,255,255,.16), rgba(255,255,255,0) 55%);
  box-shadow: 0 6px 16px -8px rgba(31, 60, 136, .7), inset 0 1px 0 rgba(255,255,255,.3); }
html body.admin-app .btn:not(.secondary):not(.ghost):not(.danger):hover { background-color: var(--brand-dark); box-shadow: 0 10px 22px -10px rgba(15, 34, 87, .75), inset 0 1px 0 rgba(255,255,255,.3); }
html body.admin-app .tabs button.active { background: var(--brand); color: #fff; }
html body.admin-app th { color: var(--ink-2); }
html body.admin-app tbody tr { transition: background-color .12s; }
html body.admin-app tbody tr:hover { background: #f5f8fe; }
html body.admin-app .modal { border-radius: 16px; box-shadow: 0 30px 70px -24px rgba(15, 34, 87, .45); }

/* Hero đầu mỗi phân hệ: cùng 1 nền xanh kính như hero trang chủ (thay cho mỗi mục 1 màu) */
html body .cl-hero, html body .cl-hero.cb-hero, html body .cl-hero.cr-hero, html body .cl-hero.ex-hero, html body .cl-hero.fn-hero,
html body .cl-hero.pm-hero, html body .cl-hero.rp-hero, html body .cl-hero.tc-hero, html body .cl-hero.tr-hero, html body .pl-hero {
  position: relative; overflow: hidden; isolation: isolate; background: var(--hero-grad); box-shadow: var(--hero-shadow); }
html body .cl-hero::after { content: "俊杰"; position: absolute; right: 18px; bottom: -22px; z-index: -1; font-family: "Noto Serif SC", serif; font-weight: 700;
  font-size: 6.5rem; line-height: 1; color: rgba(255,255,255,.06); pointer-events: none; }
html body .cl-hero .ic { background: rgba(255,255,255,.14); border: 1px solid rgba(255,255,255,.22); box-shadow: inset 0 1px 0 rgba(255,255,255,.25); }
html body .cl-hero .ic svg { color: var(--gold); }

/* ---------- Trang học viên / thi thử / giảng viên ---------- */
html body .acc-stat, html body .acc-card, html body .acc-course, html body .acc-test, html body .tp-card, html body .xp-card { transition: transform .2s var(--ease-out), box-shadow .2s; }
html body .acc-stat:hover, html body .acc-course:hover, html body .tp-card:hover { transform: translateY(-3px); box-shadow: var(--lift-shadow); }

/* Lưới an toàn: biểu tượng nằm trong dòng chữ (gợi ý, nhãn, tiêu đề, nút…) mà chưa có cỡ riêng → cỡ theo chữ.
   :where() = độ ưu tiên 0, mọi quy tắc đặt cỡ riêng vẫn thắng. */
:where(svg[viewBox="0 0 24 24"]:not([width])) { width: 1.15em; height: 1.15em; flex: none; vertical-align: -.2em; }
.uf-hint svg { width: 13px; height: 13px; flex: none; }
.uf-hint:has(> svg) { display: flex; align-items: center; gap: 5px; }

/* ==========================================================
   BÀI HỌC – danh sách bài, chi tiết bài (giới thiệu · bài giảng · giáo trình · bài tập), khung xem trực tiếp
   Dùng ở trang học viên (Lớp học của tôi → Bài học) và trang quản trị (xem thử)
   ========================================================== */
.lsn-list { display: grid; gap: 10px; }
.lsn-item { display: flex; align-items: center; gap: 14px; width: 100%; text-align: left; font: inherit; color: var(--ink); cursor: pointer;
  background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 14px 16px; transition: transform .2s var(--ease-out, ease), box-shadow .2s, border-color .2s; }
.lsn-item:hover { transform: translateY(-2px); border-color: #c9d7f2; box-shadow: var(--lift-shadow, 0 12px 28px -16px rgba(15,34,87,.3)); }
.lsn-no { flex: none; width: 52px; height: 52px; border-radius: 14px; display: grid; place-content: center; text-align: center; color: #fff; line-height: 1;
  background: linear-gradient(145deg, var(--brand), var(--brand-dark)); box-shadow: 0 8px 18px -10px rgba(31,60,136,.8); }
.lsn-no small { font-size: .62rem; text-transform: uppercase; letter-spacing: .08em; opacity: .8; }
.lsn-no b { font-size: 1.35rem; font-weight: 800; }
.lsn-it { flex: 1; min-width: 0; display: grid; gap: 4px; }
.lsn-it > b { font-size: 1rem; }
.lsn-it > small { color: var(--ink-2); font-size: .85rem; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.lsn-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 2px; }
.lsn-chips em { font-style: normal; font-size: .74rem; font-weight: 600; color: var(--brand); background: var(--brand-50); border-radius: 999px; padding: 3px 9px; display: inline-flex; align-items: center; gap: 4px; }
.lsn-go { font-size: 1.6rem; color: var(--ink-3); flex: none; }

.lsn { display: grid; gap: 14px; }
.lsn-back { justify-self: start; border: none; background: none; color: var(--brand); font: inherit; font-weight: 600; cursor: pointer; padding: 2px 0; }
.lsn-back:hover { text-decoration: underline; }
.lsn-head { display: flex; align-items: center; gap: 14px; padding: 18px 20px; border-radius: 16px; color: #fff; background: var(--hero-grad, linear-gradient(120deg, #0b1d4d, #2a4fb8)); box-shadow: var(--hero-shadow, none); }
.lsn-head .lsn-no { background: rgba(255,255,255,.14); border: 1px solid rgba(255,255,255,.25); box-shadow: inset 0 1px 0 rgba(255,255,255,.25); }
.lsn-head .lsn-no b { color: var(--gold); }
.lsn-head small { opacity: .8; font-size: .8rem; }
.lsn-head h2 { margin: 2px 0 0; color: #fff; font-size: 1.3rem; line-height: 1.3; }
.lsn-tabs { display: grid; grid-template-columns: repeat(2, 1fr); gap: 6px; padding: 5px; border-radius: 14px; background: var(--brand-50); }
.lsn-tabs button { display: flex; align-items: center; justify-content: center; gap: 7px; border: none; border-radius: 10px; padding: 10px 8px; background: none; color: var(--ink-2); font: inherit; font-weight: 600; font-size: .9rem; cursor: pointer; transition: background .15s, color .15s; }
.lsn-tabs button:hover { background: rgba(255,255,255,.7); color: var(--brand); }
.lsn-tabs button.on { background: #fff; color: var(--brand); box-shadow: 0 4px 12px -6px rgba(31,60,136,.45); }
.lsn-tabs button.dim:not(.on) { opacity: .6; }
.lsn-tabs em { font-style: normal; font-size: .7rem; background: var(--brand); color: #fff; border-radius: 999px; padding: 1px 7px; }
.lsn-intro { background: #fff; border: 1px solid var(--line); border-left: 4px solid var(--gold); border-radius: 14px; padding: 14px 18px; }
.lsn-intro p:last-child, .lsn-intro ul:last-child { margin-bottom: 0; }
.lsn-panel { background: #fff; border: 1px solid var(--line); border-radius: 16px; padding: 20px; min-height: 160px; }
.lsn-rich { line-height: 1.75; color: var(--ink); font-size: .97rem; }
.lsn-rich p { margin: 0 0 10px; } .lsn-rich ul, .lsn-rich ol { margin: 0 0 10px; padding-left: 22px; } .lsn-rich li { margin: 3px 0; }
.lsn-hw { border-left: 4px solid var(--gold); padding-left: 14px; }
.lsn-hwfile, .lsn-alt { margin-top: 16px; display: grid; gap: 8px; }
.lsn-hwfile > small, .lsn-alt > small { font-weight: 700; color: var(--ink-2); text-transform: uppercase; font-size: .72rem; letter-spacing: .05em; }
.lsn-nav { display: flex; justify-content: space-between; gap: 10px; }

.lv { display: grid; gap: 10px; }
.lv-frame { position: relative; width: 100%; aspect-ratio: 16 / 10; border-radius: 12px; overflow: hidden; background: #0f172a; border: 1px solid var(--line); }
.lv-frame.sm { aspect-ratio: 16 / 9; }
.lv-frame iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; background: #fff; }
.lv-frame:fullscreen { border-radius: 0; border: 0; }
.lv-img img { max-width: 100%; border-radius: 12px; display: block; margin: 0 auto; }
.lv-video { width: 100%; border-radius: 12px; background: #000; } .lv-audio { width: 100%; }
.lv-acts { display: flex; flex-wrap: wrap; gap: 8px; justify-content: flex-end; }
.lv-acts small { opacity: .8; font-weight: 500; }
.lv-empty { display: grid; justify-items: center; gap: 6px; text-align: center; padding: 28px 16px; color: var(--ink-2); }
.lv-empty > svg { width: 42px; height: 42px; color: var(--brand); opacity: .55; }
.lv-empty p { margin: 0; max-width: 460px; font-size: .9rem; }

.ld-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; }
.ld-card { display: flex; gap: 12px; padding: 12px; border: 1px solid var(--line); border-radius: 14px; background: #fff; transition: box-shadow .2s, transform .2s var(--ease-out, ease); }
.ld-card:hover { transform: translateY(-2px); box-shadow: var(--lift-shadow, 0 12px 28px -16px rgba(15,34,87,.3)); }
.ld-cover { flex: none; width: 76px; height: 96px; border-radius: 10px; overflow: hidden; display: grid; place-items: center; background: linear-gradient(135deg, var(--brand-50), var(--brand-100)); color: var(--brand); }
.ld-cover img { width: 100%; height: 100%; object-fit: cover; } .ld-cover svg { width: 30px; height: 30px; }
.ld-body { min-width: 0; display: grid; gap: 3px; align-content: start; }
.ld-body b { font-size: .95rem; line-height: 1.35; }
.ld-body small { color: var(--ink-3); font-size: .78rem; }
.ld-body p { margin: 2px 0 0; color: var(--ink-2); font-size: .83rem; }
.ld-acts { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 6px; }

.lv-pop { position: fixed; inset: 0; z-index: 4000; background: rgba(8, 16, 40, .7); -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px); display: grid; place-items: center; padding: 16px; }
.lv-pop-box { width: min(1100px, 100%); max-height: calc(100vh - 32px); overflow: auto; background: #fff; border-radius: 16px; padding: 14px 16px 16px; display: grid; gap: 10px; box-shadow: 0 30px 70px -20px rgba(0,0,0,.5); }
.lv-pop-box header { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.lv-pop-box header button { width: 34px; height: 34px; border-radius: 50%; border: 1px solid var(--line); background: #fff; font-size: 1.3rem; cursor: pointer; }
@media (max-width: 640px) {
  .lsn-tabs { grid-template-columns: repeat(2, 1fr); }
  .lsn-panel { padding: 14px; } .lv-frame { aspect-ratio: 4 / 3; }
  .lsn-head { padding: 14px; } .lsn-head h2 { font-size: 1.1rem; }
}
.lsn, #clsBody { scroll-margin-top: 84px; }
/* Bài học nhóm theo cấp HSK */
.lsn-grp { display: grid; gap: 10px; margin-bottom: 18px; }
.lsn-grp h3 { display: flex; align-items: center; gap: 10px; margin: 4px 0 0; font-size: 1rem; }
.lsn-grp h3 span { display: inline-flex; align-items: center; gap: 6px; color: #fff; background: linear-gradient(145deg, var(--brand), var(--brand-dark)); padding: 4px 12px; border-radius: 999px; font-size: .86rem; }
.lsn-grp h3 em { font-style: normal; font-size: .72rem; font-weight: 700; color: #92400e; background: var(--gold-50); border: 1px solid #f6d58b; padding: 2px 8px; border-radius: 999px; }
.lsn-grp h3 small { color: var(--ink-3); font-weight: 600; font-size: .8rem; }
.lsn-grp h3::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.lsn-item.locked { cursor: default; background: #f8fafc; border-style: dashed; }
.lsn-item.locked:hover { transform: none; box-shadow: none; border-color: var(--line); }
.lsn-item.locked .lsn-no { background: #cbd5e1; box-shadow: none; }
.lsn-item.locked .lsn-it > b { color: var(--ink-2); }
.lsn-item.locked .lsn-it > small { color: #b45309; font-weight: 600; display: inline-flex; align-items: center; gap: 4px; }
.lsn-item.locked .lsn-go svg { width: 18px; height: 18px; color: var(--ink-3); }