/* ==========================================================================
   EduViet Theme — Main CSS
   Bán khoá học trực tuyến · Vanilla CSS · Mobile-first
   ========================================================================== */

/* === Reset & Base === */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
	margin: 0;
	font-family: 'Be Vietnam Pro', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
	font-size: 16px;
	line-height: 1.65;
	color: #1f2937;
	background: #fff;
	-webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: #2563eb; text-decoration: none; transition: color .15s; }
a:hover { color: #1d4ed8; }
h1,h2,h3,h4,h5,h6 { font-weight: 700; line-height: 1.25; color: #0f172a; margin: 0 0 .5em; }
h1 { font-size: clamp(28px, 4vw, 44px); }
h2 { font-size: clamp(22px, 2.6vw, 32px); }
h3 { font-size: 18px; }
p { margin: 0 0 1em; }
button { font-family: inherit; cursor: pointer; }
input, select, textarea { font-family: inherit; font-size: inherit; }

/* === Tokens === */
:root {
	--brand: #2563eb;
	--brand-dark: #1d4ed8;
	--brand-light: #dbeafe;
	--accent: #f59e0b;
	--success: #16a34a;
	--danger: #dc2626;
	--bg: #ffffff;
	--bg-soft: #f8fafc;
	--bg-muted: #f1f5f9;
	--border: #e5e7eb;
	--text: #1f2937;
	--muted: #64748b;
	--radius: 12px;
	--radius-sm: 8px;
	--shadow: 0 2px 8px rgba(15, 23, 42, .06);
	--shadow-lg: 0 10px 40px rgba(15, 23, 42, .1);
}

/* === Container Hệ Thống Chuẩn UX/UI Toàn Trang === */
.container {
	max-width: 1320px;
	margin-left: auto;
	margin-right: auto;
	padding-left: 24px;
	padding-right: 24px;
	width: 100%;
	box-sizing: border-box;
}
.container-narrow {
	max-width: 780px;
	margin-left: auto;
	margin-right: auto;
	padding-left: 24px;
	padding-right: 24px;
	width: 100%;
	box-sizing: border-box;
}
.muted { color: var(--muted); }
.gradient-text {
	background: linear-gradient(135deg, var(--brand), #7c3aed);
	-webkit-background-clip: text;
	background-clip: text;
	color: transparent;
}

/* === Buttons === */
.btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	padding: 10px 18px;
	border-radius: var(--radius-sm);
	font-weight: 600;
	font-size: 15px;
	border: 1px solid transparent;
	transition: all .15s;
	cursor: pointer;
	line-height: 1.2;
	text-decoration: none;
}
.btn-primary { background: var(--brand); color: #fff; }
.btn-primary:hover { background: var(--brand-dark); color: #fff; transform: translateY(-1px); box-shadow: 0 4px 12px rgba(37, 99, 235, .35); }
.btn-ghost { background: transparent; color: var(--text); border-color: var(--border); }
.btn-ghost:hover { background: var(--bg-soft); }
.btn-white { background: #fff; color: var(--brand); }
.btn-white:hover { background: var(--bg-soft); color: var(--brand-dark); }
.btn-lg { padding: 14px 24px; font-size: 16px; border-radius: 10px; }
.btn-block { width: 100%; }
.btn:disabled { opacity: .6; cursor: not-allowed; }

/* === Header === */
.site-header {
	position: sticky; top: 0; z-index: 100;
	background: rgba(255,255,255,.95);
	backdrop-filter: blur(10px);
	border-bottom: 1px solid var(--border);
}
.header-inner {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 20px;
	padding-top: 14px;
	padding-bottom: 14px;
}
.site-logo {
	flex: 0 0 auto;
	display: flex;
	align-items: center;
	gap: 10px;
	font-weight: 800;
	font-size: 20px;
	color: var(--text);
	min-width: 0;
}
.logo-mark {
	display: inline-grid; place-items: center;
	width: 36px; height: 36px; border-radius: 10px;
	background: linear-gradient(135deg, var(--brand), #7c3aed);
	color: #fff; font-weight: 800; font-size: 18px;
}
.site-nav {
	flex: 1 1 auto;
	display: flex;
	justify-content: center;
	align-items: center;
	min-width: 0;
}
.nav-menu {
	display: flex;
	justify-content: center;
	align-items: center;
	gap: 28px;
	list-style: none;
	margin: 0;
	padding: 0;
}
.nav-menu a {
	color: var(--text);
	font-size: 13px;
	text-transform: uppercase;
	font-weight: 700;
	letter-spacing: 0.03em;
	transition: color 0.15s ease;
	white-space: nowrap;
}
.nav-menu a:hover,
.nav-menu .current-menu-item > a,
.nav-menu .current_page_item > a {
	color: var(--brand);
}

.header-actions {
	flex: 0 0 auto;
	display: flex;
	align-items: center;
	justify-content: flex-end;
	gap: 12px;
	min-width: 0;
}

@media (max-width: 1280px) {
	.nav-menu { gap: 20px; }
	.nav-menu a { font-size: 12.5px; }
}
@media (max-width: 1080px) {
	.nav-menu { gap: 14px; }
	.nav-menu a { font-size: 12px; }
}
.search-form { display: flex; background: var(--bg-soft); border: 1px solid var(--border); border-radius: 999px; overflow: hidden; }
.search-form input { border: 0; background: transparent; padding: 8px 14px; min-width: 220px; outline: none; }
.search-form button { border: 0; background: transparent; padding: 0 14px; color: var(--muted); cursor: pointer; display: grid; place-items: center; }
.search-form button:hover { color: var(--brand); }

.user-menu { position: relative; }
.user-avatar {
	width: 38px; height: 38px; border-radius: 50%;
	background: linear-gradient(135deg, var(--brand), #7c3aed);
	color: #fff; font-weight: 700; border: 0; display: grid; place-items: center;
	cursor: pointer;
	transition: transform .15s ease, box-shadow .15s ease;
}
.user-avatar:hover {
	transform: scale(1.05);
	box-shadow: 0 2px 10px rgba(37, 99, 235, 0.3);
}
.user-dropdown {
	position: absolute; right: 0; top: 100%; margin-top: 6px;
	background: #fff; border: 1px solid var(--border); border-radius: var(--radius);
	box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.06);
	min-width: 230px; padding: 8px;
	opacity: 0; pointer-events: none; transform: translateY(-4px);
	transition: opacity .15s ease, transform .15s ease;
	z-index: 1000;
}
/* Cầu nối vô hình chống rớt hover khi lia chuột từ avatar xuống menu */
.user-dropdown::before {
	content: '';
	position: absolute;
	top: -12px;
	left: 0;
	right: 0;
	height: 12px;
	background: transparent;
}
.user-menu:hover .user-dropdown,
.user-menu.open .user-dropdown {
	opacity: 1; pointer-events: auto; transform: translateY(0);
}
.user-dropdown a {
	display: flex; align-items: center; padding: 9px 12px;
	border-radius: 6px; color: var(--text); font-size: 13.5px;
	font-weight: 500; text-decoration: none;
	transition: background .15s ease, color .15s ease;
}
.user-dropdown a:hover {
	background: var(--bg-soft);
	color: var(--brand);
}
.user-info { padding: 10px 12px 12px; border-bottom: 1px solid var(--border); margin-bottom: 4px; }
.user-info strong { display: block; font-size: 14px; color: #0f172a; margin-bottom: 2px; }
.user-info small { color: var(--muted); font-size: 12px; word-break: break-all; }

.mobile-toggle { display: none; background: 0; border: 0; padding: 4px; flex-direction: column; gap: 4px; }
.mobile-toggle span { display: block; width: 22px; height: 2px; background: var(--text); }

/* === Hero === */
.hero { padding: 60px 0 80px; background: linear-gradient(180deg, #f0f7ff 0%, #fff 100%); overflow: hidden; }
.hero-grid { display: grid; grid-template-columns: 1.1fr 1fr; gap: 56px; align-items: center; }
.badge {
	display: inline-block; padding: 6px 12px; background: #fff;
	border: 1px solid var(--border); border-radius: 999px;
	font-size: 13px; font-weight: 600; color: var(--muted); margin-bottom: 16px;
	box-shadow: var(--shadow);
}
.hero-title { font-size: clamp(32px, 4.5vw, 56px); margin-bottom: 16px; letter-spacing: -.02em; }
.hero-sub { font-size: 18px; color: var(--muted); margin-bottom: 28px; max-width: 540px; }
.hero-cta { display: flex; gap: 12px; margin-bottom: 36px; flex-wrap: wrap; }
.hero-stats { display: flex; gap: 32px; }
.hero-stats div { display: flex; flex-direction: column; }
.hero-stats strong { font-size: 24px; color: var(--text); font-weight: 800; }
.hero-stats span { color: var(--muted); font-size: 14px; }

.hero-visual { position: relative; min-height: 480px; }
.hero-card {
	position: absolute; background: #fff; border-radius: var(--radius); padding: 16px;
	box-shadow: var(--shadow-lg); display: flex; gap: 12px; align-items: center;
	min-width: 260px; border: 1px solid rgba(15,23,42,.04);
}
.hero-card strong { display: block; font-size: 15px; }
.hero-card small { color: var(--muted); }
.hero-card-icon { width: 48px; height: 48px; border-radius: 12px; display: grid; place-items: center; font-size: 24px; flex-shrink: 0; }
.hero-card-1 { top: 0; left: 20px; animation: float 6s ease-in-out infinite; }
.hero-card-2 { top: 140px; right: 0; animation: float 6s ease-in-out infinite .8s; }
.hero-card-3 { bottom: 40px; left: 60px; animation: float 6s ease-in-out infinite 1.6s; }
.hero-blob {
	position: absolute; top: 40%; left: 50%; transform: translate(-50%, -50%);
	width: 360px; height: 360px; border-radius: 50%;
	background: radial-gradient(circle, var(--brand-light), transparent 70%);
	z-index: -1; filter: blur(20px);
}
@keyframes float { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-12px); } }

/* === Benefits === */
.benefits { padding: 60px 16px; }
.benefits-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }
.benefit { text-align: center; padding: 24px; }
.benefit-icon { font-size: 40px; margin-bottom: 12px; }
.benefit h3 { font-size: 17px; margin-bottom: 8px; }
.benefit p { color: var(--muted); font-size: 14px; margin: 0; }

/* === Section heads (homepage / archive blocks) === */
.section-head { display: flex; justify-content: space-between; align-items: end; margin-bottom: 24px; }
.section-head.center { flex-direction: column; align-items: center; text-align: center; gap: 8px; }
.link-more { font-weight: 600; }

/* === Categories === */
.categories { padding: 40px 16px; }
.cat-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.cat-card {
	display: flex; flex-direction: column; gap: 4px; padding: 24px;
	border: 1px solid var(--border); border-radius: var(--radius);
	background: #fff; color: var(--text); transition: all .2s;
}
.cat-card:hover { border-color: var(--brand); transform: translateY(-4px); box-shadow: var(--shadow-lg); color: var(--text); }
.cat-icon { font-size: 32px; margin-bottom: 4px; }
.cat-card small { color: var(--muted); }

/* === Course grid & card === */
.popular { padding: 40px 16px 80px; }
.course-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }

.course-card {
	background: #fff; border: 1px solid var(--border); border-radius: var(--radius);
	overflow: hidden; transition: all .2s; display: flex; flex-direction: column;
}
.course-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); border-color: transparent; }
.course-thumb { display: block; position: relative; aspect-ratio: 16/9; overflow: hidden; background: var(--bg-muted); }
.course-thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .3s; }
.course-card:hover .course-thumb img { transform: scale(1.05); }
.course-thumb-placeholder {
	width: 100%; height: 100%; display: grid; place-items: center;
	background: linear-gradient(135deg, var(--brand), #7c3aed); color: #fff;
}
.course-thumb-placeholder span { font-size: 56px; font-weight: 800; }
.badge-discount, .badge-free {
	position: absolute; top: 10px; left: 10px;
	background: var(--danger); color: #fff;
	padding: 4px 10px; border-radius: 999px;
	font-size: 12px; font-weight: 700;
}
.badge-free { background: var(--success); }

.course-body { padding: 16px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.course-cat {
	font-size: 12px; color: var(--brand); font-weight: 600; text-transform: uppercase;
	letter-spacing: .04em;
}
.course-title { font-size: 16px; margin: 0; line-height: 1.4; }
.course-title a { color: var(--text); }
.course-title a:hover { color: var(--brand); }
.course-instructor { color: var(--muted); font-size: 13px; }
.course-meta { display: flex; gap: 12px; font-size: 13px; color: var(--muted); flex-wrap: wrap; }
.course-price { margin-top: auto; display: flex; gap: 8px; align-items: baseline; padding-top: 8px; border-top: 1px solid var(--border); }
.course-price strong { font-size: 18px; color: var(--text); }
.course-price del { color: var(--muted); font-size: 14px; }
.price-free { color: var(--success) !important; }

/* === Testimonials === */
.testimonials { padding: 80px 0; background: var(--bg-soft); }
.testi-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; margin-top: 40px; }
.testi-card { background: #fff; padding: 28px; border-radius: var(--radius); box-shadow: var(--shadow); }
.stars { color: #f59e0b; font-size: 18px; margin-bottom: 12px; letter-spacing: 2px; }
.testi-card blockquote { font-size: 15px; line-height: 1.7; color: var(--text); margin: 0 0 20px; }
.testi-author { display: flex; gap: 12px; align-items: center; }
.testi-avatar { width: 48px; height: 48px; border-radius: 50%; background: var(--brand-light); display: grid; place-items: center; font-size: 24px; }
.testi-author strong { display: block; }
.testi-author small { color: var(--muted); }

/* === CTA banner === */
.cta-banner { padding: 80px 16px; text-align: center; background: linear-gradient(135deg, var(--brand), #7c3aed); color: #fff; }
.cta-banner h2 { color: #fff; }
.cta-banner p { color: rgba(255,255,255,.85); font-size: 18px; margin-bottom: 32px; max-width: 600px; margin-left: auto; margin-right: auto; }

/* === Footer === */
.site-footer { background: #0f172a; color: #cbd5e1; padding: 60px 16px 24px; margin-top: 80px; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 40px; padding-bottom: 40px; border-bottom: 1px solid #1e293b; }
.footer-col h4 { color: #fff; font-size: 15px; margin-bottom: 16px; text-transform: uppercase; letter-spacing: .04em; }
.footer-col ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.footer-col a { color: #cbd5e1; }
.footer-col a:hover { color: #fff; }
.site-footer .site-logo { color: #fff; margin-bottom: 12px; }
.footer-bottom { padding-top: 20px; color: #64748b; }

/* === Archive page === */
.archive-hero { padding: 48px 16px; background: var(--bg-soft); border-bottom: 1px solid var(--border); }
.archive-hero h1 { margin: 0 0 8px; }
.archive-body { display: grid; grid-template-columns: 240px 1fr; gap: 32px; padding-top: 32px; padding-bottom: 64px; }
.archive-sidebar { position: sticky; top: 80px; align-self: start; }
.filter-box { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 20px; margin-bottom: 16px; }
.filter-box h3 { font-size: 14px; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); margin-bottom: 12px; }
.filter-box ul { list-style: none; padding: 0; margin: 0; }
.filter-box li a {
	display: flex; justify-content: space-between; padding: 8px 10px;
	border-radius: 6px; color: var(--text); font-size: 14px;
}
.filter-box li a:hover, .filter-box li a.active { background: var(--brand-light); color: var(--brand); font-weight: 600; }
.filter-box li a span { color: var(--muted); font-size: 12px; }

.archive-toolbar { display: flex; justify-content: space-between; align-items: center; margin-bottom: 20px; }
.archive-toolbar select { padding: 8px 12px; border: 1px solid var(--border); border-radius: 6px; background: #fff; }
.pagination { display: flex; justify-content: center; gap: 8px; margin-top: 32px; }
.pagination .page-numbers { padding: 8px 14px; border: 1px solid var(--border); border-radius: 6px; color: var(--text); }
.pagination .current { background: var(--brand); color: #fff; border-color: var(--brand); }

/* === Single course === */
.course-hero { padding: 40px 0; background: linear-gradient(180deg, #0f172a 0%, #1e293b 100%); color: #fff; }
.course-hero .course-title { color: #fff; font-size: clamp(26px, 3.5vw, 38px); }
.course-hero-grid { display: grid; grid-template-columns: 1.4fr 1fr; gap: 40px; }
.breadcrumb { color: #94a3b8; font-size: 14px; margin-bottom: 16px; }
.breadcrumb a { color: #94a3b8; }
.breadcrumb a:hover { color: #fff; }
.course-excerpt { color: #cbd5e1; font-size: 17px; }
.course-hero-meta { display: flex; gap: 16px; flex-wrap: wrap; font-size: 14px; color: #cbd5e1; margin-top: 20px; }
.course-hero-meta strong { color: #fff; }

.course-buy-card {
	background: #fff; color: var(--text); border-radius: var(--radius);
	box-shadow: var(--shadow-lg); overflow: hidden;
	position: sticky; top: 80px; align-self: start;
}
.buy-card-preview { aspect-ratio: 16/9; background: #000; position: relative; }
.buy-card-preview iframe, .buy-card-preview img { width: 100%; height: 100%; border: 0; object-fit: cover; }
.buy-card-placeholder { width: 100%; height: 100%; display: grid; place-items: center; color: #fff; background: linear-gradient(135deg, var(--brand), #7c3aed); }
.buy-card-body { padding: 24px; }
.buy-price { display: flex; gap: 10px; align-items: baseline; margin-bottom: 8px; }
.buy-price strong { font-size: 28px; }
.buy-price del { color: var(--muted); font-size: 18px; }
.discount-pct { background: var(--danger); color: #fff; padding: 2px 8px; border-radius: 4px; font-size: 12px; font-weight: 700; }
.urgency { background: #fef3c7; color: #92400e; padding: 8px 12px; border-radius: 6px; font-size: 13px; margin-bottom: 16px; font-weight: 500; }

.btn-block + .btn-block { margin-top: 8px; }
.enrolled-badge { text-align: center; color: var(--success); font-weight: 600; padding: 12px; background: #dcfce7; border-radius: 8px; margin-top: 12px; }
.guarantee { padding: 12px 0; text-align: center; border-bottom: 1px solid var(--border); margin: 16px 0; }
.course-includes { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 8px; font-size: 14px; }

/* Course body sections */
.course-body { padding: 48px 16px; }
.course-main { max-width: 820px; }
.course-box { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 28px; margin-bottom: 24px; }
.outcomes-box { background: linear-gradient(135deg, #f0f7ff 0%, #fff 100%); }
.check-list { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.check-list li { position: relative; padding-left: 28px; }
.check-list li::before { content: "✓"; position: absolute; left: 0; top: 0; color: var(--success); font-weight: 700; font-size: 18px; }
.bullet-list { padding-left: 20px; margin: 0; }
.bullet-list li { margin-bottom: 6px; }

.curr-head { display: flex; justify-content: space-between; align-items: end; margin-bottom: 20px; }
.curr-stats { font-size: 14px; }
.curriculum .section { border: 1px solid var(--border); border-radius: 8px; margin-bottom: 10px; overflow: hidden; }
.curr-section-head {
	width: 100%; display: flex; gap: 12px; align-items: center; padding: 14px 16px;
	background: var(--bg-soft); border: 0; cursor: pointer; text-align: left;
}
.curr-section-head strong { flex: 1; }
.curr-section-head small { color: var(--muted); font-size: 13px; }
.section-toggle { transition: transform .15s; }
.section.open .section-toggle { transform: rotate(0deg); }
.section:not(.open) .section-toggle { transform: rotate(-90deg); }
.lesson-list { list-style: none; padding: 0; margin: 0; display: none; }
.section.open .lesson-list { display: block; }
.lesson-list li {
	display: flex; gap: 12px; align-items: center;
	padding: 12px 16px; border-top: 1px solid var(--border); font-size: 14px;
}
.lesson-list a { color: var(--text); flex: 1; }
.lesson-list a:hover { color: var(--brand); }
.lesson-icon { width: 24px; text-align: center; color: var(--muted); }
.lesson-dur { color: var(--muted); font-size: 13px; }
.lesson-preview-badge { background: var(--brand-light); color: var(--brand); padding: 2px 8px; border-radius: 4px; font-size: 11px; font-weight: 600; }
.lesson-locked span:not(.lesson-icon):not(.lesson-dur):not(.lesson-preview-badge) { color: var(--muted); flex: 1; }

.instructor { display: flex; gap: 20px; align-items: start; }
.instructor-avatar {
	width: 72px; height: 72px; border-radius: 50%;
	background: linear-gradient(135deg, var(--brand), #7c3aed);
	color: #fff; display: grid; place-items: center; font-size: 28px; font-weight: 700;
	flex-shrink: 0;
}
.instructor h3 { margin-bottom: 4px; }

/* === Lesson player page (Bố cục 2 Khung Riêng Biệt) === */
.lesson-page-wrapper {
	background: #f1f5f9;
	min-height: calc(100vh - 70px);
	padding: 24px 0 48px;
}
.lesson-container {
	width: 100%;
}
.lesson-grid {
	display: grid;
	grid-template-columns: 1fr 370px;
	gap: 24px;
	align-items: start;
}

/* --- KHUNG TRÁI: Card Nội Dung Bài Học --- */
.lesson-main-card,
.lesson-main {
	background: #ffffff;
	border: 1px solid var(--border);
	border-radius: 18px;
	box-shadow: 0 4px 20px rgba(15, 23, 42, 0.05);
	overflow: hidden;
	display: flex;
	flex-direction: column;
	min-width: 0;
}

.lesson-topbar {
	padding: 14px 32px;
	background: #f8fafc;
	border-bottom: 1px solid var(--border);
	display: flex;
	justify-content: space-between;
	align-items: center;
	font-size: 13.5px;
	gap: 16px;
	flex-wrap: wrap;
}
.lesson-breadcrumb {
	display: flex;
	align-items: center;
	gap: 6px;
	flex-wrap: wrap;
	color: var(--muted);
}
.lesson-breadcrumb a {
	color: var(--muted);
	text-decoration: none;
}
.lesson-breadcrumb a:hover {
	color: var(--brand);
}
.current-lesson-crumb {
	color: #0f172a;
	font-weight: 600;
}
.topbar-back-link {
	color: var(--brand);
	font-weight: 600;
	text-decoration: none;
	font-size: 13px;
	padding: 5px 12px;
	background: #ffffff;
	border: 1px solid #cbd5e1;
	border-radius: 6px;
	transition: all 0.15s;
	display: inline-flex;
	align-items: center;
	gap: 6px;
}
.topbar-back-link:hover {
	background: var(--brand);
	color: #ffffff;
	border-color: var(--brand);
}

.lesson-player-wrap {
	width: 100%;
	background: #000000;
}
.lesson-player {
	aspect-ratio: 16/9;
	background: #000000;
	max-height: 72vh;
	width: 100%;
}
.lesson-player iframe {
	width: 100%;
	height: 100%;
	border: 0;
	display: block;
}
.lesson-no-video {
	padding: 36px 24px;
	background: linear-gradient(135deg, #1e293b, #0f172a);
	color: #ffffff;
	text-align: center;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: 10px;
}
.no-video-icon {
	font-size: 36px;
}
.no-video-text {
	font-size: 15px;
	font-weight: 600;
	color: #e2e8f0;
}

.lesson-content {
	padding: 36px 48px 64px;
	max-width: 1020px;
	width: 100%;
	margin-left: auto;
	margin-right: auto;
	flex: 1;
}
.lesson-header-row {
	display: flex;
	justify-content: space-between;
	align-items: flex-start;
	gap: 20px;
	margin-bottom: 24px;
	padding-bottom: 18px;
	border-bottom: 1px solid #f1f5f9;
}
.lesson-title {
	font-size: clamp(22px, 2.5vw, 28px);
	font-weight: 800;
	color: #0f172a;
	line-height: 1.35;
	margin: 0;
	flex: 1;
}
.lesson-status-badge-wrap {
	flex-shrink: 0;
	margin-top: 4px;
}

.lesson-body {
	font-size: 16px;
	line-height: 1.8;
	color: #334155;
}
.lesson-body p {
	margin-bottom: 1.25em;
}
.lesson-body iframe {
	max-width: 100%;
	border-radius: 8px;
}
.lesson-body audio {
	width: 100%;
	margin: 14px 0;
}

.lesson-actions {
	margin-top: auto;
	padding: 24px 48px 32px;
	border-top: 1px solid var(--border);
	background: #fafafa;
	display: flex;
	justify-content: space-between;
	align-items: center;
	gap: 16px;
	flex-wrap: wrap;
	box-sizing: border-box;
}
.lesson-actions-left {
	display: flex;
	align-items: center;
	gap: 10px;
}
.lesson-actions-right {
	display: flex;
	align-items: center;
	gap: 12px;
}
.btn-nav-prev {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	height: 44px;
	padding: 0 20px;
	font-size: 14px;
	font-weight: 600;
	background: #ffffff;
	border: 1px solid #cbd5e1;
	color: #334155;
	border-radius: 10px;
	text-decoration: none;
	transition: all 0.15s;
	box-sizing: border-box;
	line-height: 1;
}
.btn-nav-prev:hover {
	background: #f8fafc;
	border-color: var(--brand);
	color: var(--brand);
}
.btn-complete-action,
.btn-next-action {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	height: 44px;
	padding: 0 24px;
	font-size: 14.5px;
	font-weight: 600;
	border-radius: 10px;
	border: 0;
	cursor: pointer;
	background: var(--brand);
	color: #ffffff;
	text-decoration: none;
	transition: all 0.15s;
	box-shadow: 0 2px 8px rgba(37, 99, 235, 0.25);
	box-sizing: border-box;
	line-height: 1;
}
.btn-complete-action:hover,
.btn-next-action:hover {
	background: var(--brand-dark);
	box-shadow: 0 4px 14px rgba(37, 99, 235, 0.35);
}

/* --- KHUNG PHẢI: Card Sidebar Danh Sách Bài Học --- */
.lesson-sidebar-card,
.lesson-sidebar {
	background: #ffffff;
	border: 1px solid var(--border);
	border-radius: 18px;
	box-shadow: 0 4px 20px rgba(15, 23, 42, 0.05);
	overflow: hidden;
	display: flex;
	flex-direction: column;
	position: sticky;
	top: 88px;
	max-height: calc(100vh - 110px);
}
.lesson-sidebar-head {
	padding: 20px 22px;
	border-bottom: 1px solid var(--border);
	background: #f8fafc;
	flex-shrink: 0;
}
.lesson-sidebar-head .back-link {
	font-size: 13px;
	color: var(--brand);
	font-weight: 600;
	text-decoration: none;
	display: inline-flex;
	align-items: center;
	gap: 4px;
	margin-bottom: 8px;
}
.lesson-sidebar-head .back-link:hover {
	text-decoration: underline;
}
.sidebar-course-title {
	font-size: 15.5px;
	font-weight: 700;
	margin: 0 0 10px;
	color: #0f172a;
	line-height: 1.4;
}
.sidebar-progress-meta {
	display: flex;
	justify-content: space-between;
	align-items: center;
	font-size: 12px;
	color: var(--muted);
	margin-top: 6px;
}

.lesson-list-wrap {
	flex: 1;
	overflow-y: auto;
}
.sb-section {
	border-bottom: 1px solid var(--border);
}
.sb-section:last-child {
	border-bottom: 0;
}
.sb-section-head {
	width: 100%;
	display: flex;
	justify-content: space-between;
	align-items: center;
	gap: 8px;
	padding: 13px 18px;
	border: 0;
	background: #f8fafc;
	cursor: pointer;
	text-align: left;
	color: #0f172a;
	transition: background 0.15s;
}
.sb-section-head:hover {
	background: #f1f5f9;
}
.sb-sec-title-wrap {
	display: flex;
	align-items: center;
	gap: 8px;
	min-width: 0;
	flex: 1;
}
.sb-sec-chevron {
	font-size: 13px;
	color: #64748b;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 18px;
	height: 18px;
	transition: transform 0.2s cubic-bezier(0.4, 0, 0.2, 1), color 0.15s ease;
	transform: rotate(0deg);
	transform-origin: center center;
	flex-shrink: 0;
	line-height: 1;
}
.sb-section.open .sb-sec-chevron {
	transform: rotate(90deg);
	color: var(--brand, #2563eb);
}
.sb-sec-title {
	font-size: 13.5px;
	font-weight: 700;
	line-height: 1.35;
	color: #1e293b;
}
.sb-sec-badge {
	color: var(--muted);
	font-weight: 600;
	font-size: 11.5px;
	background: #ffffff;
	border: 1px solid #e2e8f0;
	padding: 2px 8px;
	border-radius: 999px;
	flex-shrink: 0;
}

.sb-lesson-list {
	display: none;
	list-style: none;
	padding: 0;
	margin: 0;
	background: #ffffff;
}
.sb-section.open .sb-lesson-list {
	display: block;
}

.sb-subgroup-label {
	padding: 7px 18px;
	font-size: 12px;
	font-weight: 700;
	color: #475569;
	background: #f8fafc;
	border-top: 1px solid #f1f5f9;
	border-bottom: 1px solid #f1f5f9;
	display: flex;
	align-items: center;
	gap: 6px;
}

.sb-lesson-row {
	border-bottom: 1px solid #f8fafc;
}
.sb-lesson-row:last-child {
	border-bottom: 0;
}
.sb-lesson-link {
	display: flex;
	gap: 10px;
	align-items: center;
	padding: 10px 18px 10px 24px;
	color: #334155;
	font-size: 13.5px;
	border-left: 3px solid transparent;
	text-decoration: none;
	transition: all 0.15s;
}
.sb-lesson-row:hover .sb-lesson-link {
	background: #f8fafc;
	color: var(--brand);
}
.sb-lesson-row.current .sb-lesson-link {
	background: #eff6ff;
	border-left-color: var(--brand);
	color: var(--brand);
	font-weight: 700;
}
.sb-icon {
	font-size: 14px;
	width: 20px;
	height: 20px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	flex-shrink: 0;
	color: #64748b;
	line-height: 1;
}
.sb-icon .icon-chk {
	color: #10b981;
	font-size: 15px;
}
.sb-icon .icon-type {
	display: inline-flex;
	align-items: center;
	justify-content: center;
}
.sb-icon .icon-type.type-video {
	color: #2563eb;
	font-size: 15px;
}
.sb-icon .icon-type.type-text {
	color: #64748b;
	font-size: 15px;
}
.sb-icon .icon-type.type-quiz {
	color: #7c3aed;
	font-size: 15px;
}
.sb-lesson-row.current .sb-icon {
	color: var(--brand);
}
.sb-lesson-row.done .sb-icon .icon-chk {
	color: #10b981;
}
.sb-title {
	flex: 1;
	line-height: 1.35;
}
.sb-time {
	color: #94a3b8;
	font-size: 11.5px;
	flex-shrink: 0;
}

/* === Checkout === */
.checkout { padding: 48px 16px; }
.checkout-grid { display: grid; grid-template-columns: 1fr 320px; gap: 32px; margin-top: 24px; }
.checkout-summary { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 28px; }
.cs-item { display: flex; gap: 16px; padding-bottom: 20px; margin-bottom: 20px; border-bottom: 1px solid var(--border); }
.cs-item img { width: 120px; aspect-ratio: 16/9; object-fit: cover; border-radius: 8px; }
.cs-item strong { display: block; margin-bottom: 4px; }
.cs-item small { color: var(--muted); }
.cs-row { display: flex; justify-content: space-between; padding: 8px 0; font-size: 15px; }
.cs-total { border-top: 1px solid var(--border); padding-top: 16px; margin-top: 12px; font-size: 18px; }
.cs-total strong { font-size: 22px; color: var(--brand); }
.cs-coupon { margin: 20px 0; padding: 16px 0; border-top: 1px dashed var(--border); border-bottom: 1px dashed var(--border); }
.cs-coupon label { display: block; font-weight: 600; margin-bottom: 8px; font-size: 14px; }
.cs-coupon-row { display: flex; gap: 8px; }
.cs-coupon-row input { flex: 1; padding: 10px 14px; border: 1px solid var(--border); border-radius: 6px; }
.eduviet-coupon-msg { font-size: 13px; margin-top: 8px; min-height: 1em; }
.eduviet-coupon-msg.success { color: var(--success); }
.eduviet-coupon-msg.error { color: var(--danger); }
.cs-payments { text-align: center; margin-top: 16px; color: var(--muted); font-size: 13px; }

.checkout-trust { display: flex; flex-direction: column; gap: 16px; }
.trust-item { display: flex; gap: 12px; padding: 16px; background: var(--bg-soft); border-radius: 8px; }
.trust-item span { font-size: 28px; }
.trust-item strong { display: block; }
.trust-item small { color: var(--muted); }

/* Checkout result */
.checkout-result { padding: 80px 16px; }
.result-card { background: #fff; border-radius: var(--radius); padding: 48px 32px; text-align: center; box-shadow: var(--shadow-lg); border: 1px solid var(--border); }
.result-icon { width: 80px; height: 80px; border-radius: 50%; display: grid; place-items: center; font-size: 40px; margin: 0 auto 20px; color: #fff; font-weight: 700; }
.result-card.success .result-icon { background: var(--success); }
.result-card.error .result-icon { background: var(--danger); }
.result-card.pending .result-icon { background: var(--accent); }
.result-info { display: inline-flex; flex-direction: column; gap: 8px; background: var(--bg-soft); padding: 16px 24px; border-radius: 8px; margin: 16px 0 24px; text-align: left; }
.result-info span { color: var(--muted); margin-right: 8px; }
.result-actions { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }

/* === Dashboard === */
.dashboard { padding: 40px 16px 80px; background: var(--bg-soft); min-height: 60vh; }
.dash-head { display: flex; justify-content: space-between; align-items: center; gap: 32px; margin-bottom: 32px; flex-wrap: wrap; }
.dash-head h1 { margin: 0; font-size: 28px; }
.dash-stats { display: flex; gap: 24px; }
.dash-stats > div { background: #fff; padding: 16px 24px; border-radius: 10px; text-align: center; box-shadow: var(--shadow); }
.dash-stats strong { display: block; font-size: 22px; color: var(--brand); }
.dash-stats span { color: var(--muted); font-size: 13px; }

.dash-tabs { display: flex; gap: 4px; margin-bottom: 24px; }
.dash-tabs button { padding: 10px 20px; border: 0; background: transparent; border-radius: 8px; font-weight: 600; color: var(--muted); cursor: pointer; }
.dash-tabs button.active { background: #fff; color: var(--brand); box-shadow: var(--shadow); }

.dash-courses { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.dash-card { background: #fff; border-radius: var(--radius); overflow: hidden; color: var(--text); transition: all .2s; box-shadow: var(--shadow); }
.dash-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); color: var(--text); }
.dash-card-thumb { aspect-ratio: 16/9; background: var(--bg-muted); }
.dash-card-thumb img { width: 100%; height: 100%; object-fit: cover; }
.dash-card-body { padding: 16px; }
.dash-card-body h3 { font-size: 16px; margin-bottom: 12px; min-height: 44px; }
.dash-card-meta { display: flex; justify-content: space-between; font-size: 13px; color: var(--muted); margin-top: 8px; }

/* === Auth page === */
.auth-page {
	min-height: calc(100vh - 70px); display: grid;
	grid-template-columns: 1fr 1fr; align-items: stretch;
}
.auth-card { padding: 64px 48px; max-width: 480px; width: 100%; justify-self: end; margin: auto 0; }
.auth-tabs { display: flex; border-bottom: 1px solid var(--border); margin-bottom: 32px; }
.auth-tabs a { flex: 1; text-align: center; padding: 14px; color: var(--muted); font-weight: 600; border-bottom: 2px solid transparent; }
.auth-tabs a.active { color: var(--brand); border-bottom-color: var(--brand); }
.auth-form h1 { font-size: 28px; }
.auth-form label { display: block; font-weight: 600; font-size: 14px; margin: 16px 0 6px; }
.auth-form input { width: 100%; padding: 12px 14px; border: 1px solid var(--border); border-radius: 8px; outline: none; transition: border-color .15s; }
.auth-form input:focus { border-color: var(--brand); box-shadow: 0 0 0 3px var(--brand-light); }
.auth-form button { margin-top: 24px; }
.auth-msg { min-height: 1em; margin-top: 8px; font-size: 13px; }
.auth-msg.error { color: var(--danger); }
.auth-foot { text-align: center; margin: 16px 0 0; color: var(--muted); font-size: 14px; }
.auth-visual {
	background: linear-gradient(135deg, var(--brand) 0%, #7c3aed 100%);
	color: #fff; padding: 80px 64px; display: flex; flex-direction: column; justify-content: center;
}
.auth-visual h2 { color: #fff; font-size: 36px; line-height: 1.3; margin-bottom: 32px; }
.auth-visual .check-list { display: flex; flex-direction: column; gap: 12px; font-size: 17px; }
.auth-visual .check-list li::before { color: #fff; background: rgba(255,255,255,.2); border-radius: 50%; width: 20px; height: 20px; display: grid; place-items: center; font-size: 12px; }

/* === Alerts & empty === */
.alert { padding: 14px 18px; border-radius: 8px; margin: 12px 0; font-weight: 500; }
.alert-warning { background: #fef3c7; color: #92400e; border: 1px solid #fde68a; }
.empty-state { text-align: center; padding: 64px 24px; color: var(--muted); grid-column: 1 / -1; }
.empty-state h3 { color: var(--text); }

/* === Mobile === */
@media (max-width: 1024px) {
	.container,
	.container-narrow {
		padding-left: 20px;
		padding-right: 20px;
	}
	.hero-grid { grid-template-columns: 1fr; }
	.hero-visual { min-height: 380px; }
	.benefits-grid, .cat-grid, .course-grid, .testi-grid, .dash-courses { grid-template-columns: repeat(2, 1fr); }
	.footer-grid { grid-template-columns: 1fr 1fr; }
	.archive-body { grid-template-columns: 1fr; }
	.archive-sidebar { position: static; }
	.course-hero-grid { grid-template-columns: 1fr; }
	.course-buy-card { position: static; }
	.checkout-grid { grid-template-columns: 1fr; }
	.auth-page { grid-template-columns: 1fr; }
	.auth-visual { display: none; }
	.auth-card { justify-self: center; }
	.lesson-page-wrapper { padding: 16px 0 32px; }
	.lesson-container { padding: 0 16px; }
	.lesson-grid, .lesson-page { grid-template-columns: 1fr; gap: 20px; }
	.lesson-sidebar-card, .lesson-sidebar { position: static; max-height: none; }
	.lesson-content { padding: 24px 20px 40px; }
	.lesson-topbar { padding: 14px 20px; }
	.lesson-actions { padding: 20px 20px 24px; flex-direction: column; align-items: stretch; gap: 12px; }
	.lesson-actions-left, .lesson-actions-right { width: 100%; }
	.lesson-actions-left .btn, .lesson-actions-right .btn { width: 100%; justify-content: center; text-align: center; }
}
@media (max-width: 960px) {
	.nav-menu, .search-form, .header-actions .btn { display: none; }
	.mobile-toggle { display: flex; }
	body.nav-open .nav-menu { display: flex; position: absolute; top: 100%; left: 0; right: 0; background: #fff; flex-direction: column; padding: 16px; gap: 8px; border-bottom: 1px solid var(--border); box-shadow: var(--shadow-lg); z-index: 99; }
}
@media (max-width: 640px) {
	.container,
	.container-narrow {
		padding-left: 16px;
		padding-right: 16px;
	}
	.benefits-grid, .cat-grid, .course-grid, .testi-grid, .dash-courses { grid-template-columns: 1fr; }
	.footer-grid { grid-template-columns: 1fr; }
	.check-list { grid-template-columns: 1fr; }
	.hero { padding: 40px 0 60px; }
	.dash-stats { width: 100%; flex-wrap: wrap; gap: 12px; }
	.dash-stats > div { flex: 1; min-width: calc(50% - 6px); padding: 12px; }
}


/* ==========================================================================
   EduViet Theme — Cổng Đào Tạo & Khoá Học Nội Bộ
   ========================================================================== */

.internal-portal-wrapper {
	background: #f8fafc;
	min-height: calc(100vh - 70px);
}

/* === 1. Top Banner / Welcome Hero === */
.portal-welcome-hero {
	background: #ffffff;
	border-bottom: 1px solid var(--border);
	padding: 44px 0 40px;
}
.welcome-box {
	display: grid;
	grid-template-columns: 1.25fr 0.95fr;
	gap: 48px;
	align-items: center;
}
.welcome-info {
	display: flex;
	flex-direction: column;
	gap: 12px;
}
.welcome-badge {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	padding: 6px 14px;
	background: #f0fdf4;
	border: 1px solid #bbf7d0;
	border-radius: 999px;
	font-size: 13px;
	font-weight: 600;
	color: #166534;
	width: fit-content;
}
.badge-dot {
	width: 8px;
	height: 8px;
	border-radius: 50%;
	background: #22c55e;
	box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.25);
	animation: pulse-dot 2s infinite;
}
@keyframes pulse-dot {
	0%, 100% { opacity: 1; transform: scale(1); }
	50% { opacity: 0.6; transform: scale(1.15); }
}

.welcome-title {
	font-size: clamp(26px, 3.2vw, 36px);
	font-weight: 800;
	color: #0f172a;
	line-height: 1.25;
	margin: 0;
	letter-spacing: -0.02em;
}
.user-highlight {
	color: var(--brand);
}
.welcome-desc {
	font-size: 15.5px;
	color: var(--muted);
	line-height: 1.6;
	margin: 0;
	max-width: 580px;
}

/* Thống kê học viên */
.student-quick-stats {
	display: grid;
	grid-template-columns: repeat(4, 1fr);
	gap: 12px;
	margin-top: 8px;
}
.stat-pill {
	display: flex;
	align-items: center;
	gap: 10px;
	background: #f8fafc;
	border: 1px solid var(--border);
	border-radius: 10px;
	padding: 10px 12px;
	transition: all 0.15s;
}
.stat-pill:hover {
	border-color: #cbd5e1;
	background: #ffffff;
	box-shadow: var(--shadow);
}
.stat-icon {
	font-size: 20px;
	flex-shrink: 0;
}
.stat-detail {
	display: flex;
	flex-direction: column;
	min-width: 0;
}
.stat-num {
	font-size: 17px;
	font-weight: 800;
	color: #0f172a;
	line-height: 1.1;
}
.stat-label {
	font-size: 11.5px;
	color: var(--muted);
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

/* Guest bar */
.guest-login-bar {
	display: flex;
	align-items: center;
	gap: 16px;
	margin-top: 10px;
	flex-wrap: wrap;
}
.guest-note {
	font-size: 13.5px;
	color: var(--muted);
}

/* Ô tìm kiếm trực tiếp */
.welcome-search-panel {
	background: #ffffff;
	border: 1px solid #cbd5e1;
	border-radius: 16px;
	padding: 22px 24px;
	box-shadow: 0 4px 20px rgba(15, 23, 42, 0.05);
	display: flex;
	flex-direction: column;
	gap: 10px;
}
.search-title {
	font-size: 14px;
	font-weight: 700;
	color: #1e293b;
	text-transform: uppercase;
	letter-spacing: 0.04em;
}
.search-field-wrap {
	position: relative;
	display: flex;
	align-items: center;
}
.search-field-icon {
	position: absolute;
	left: 14px;
	color: #94a3b8;
	pointer-events: none;
}
#course-search-input {
	width: 100%;
	padding: 13px 40px 13px 44px;
	border: 1.5px solid var(--border);
	border-radius: 10px;
	background: #f8fafc;
	font-size: 15px;
	color: var(--text);
	outline: none;
	transition: all 0.2s;
}
#course-search-input:focus {
	background: #ffffff;
	border-color: var(--brand);
	box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15);
}
.search-clear-btn {
	position: absolute;
	right: 12px;
	top: 50%;
	transform: translateY(-50%);
	background: #e2e8f0;
	color: #475569;
	border: 0;
	border-radius: 50%;
	width: 22px;
	height: 22px;
	font-size: 12px;
	line-height: 1;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: all 0.15s;
}
.search-clear-btn:hover {
	background: #cbd5e1;
	color: #0f172a;
}
.search-counter-bar {
	font-size: 13px;
	color: var(--muted);
	margin-top: 2px;
}
.search-counter-bar strong {
	color: var(--brand);
}

/* === 2. Continue Learning Section === */
.continue-learning-section {
	background: #f0f7ff;
	border-bottom: 1px solid #dbeafe;
	padding: 32px 0 36px;
}
.section-header-row {
	display: flex;
	justify-content: space-between;
	align-items: flex-end;
	margin-bottom: 20px;
	gap: 16px;
	flex-wrap: wrap;
}
.section-title-group {
	display: flex;
	flex-direction: column;
	gap: 4px;
}
.kicker-tag {
	font-size: 12px;
	font-weight: 700;
	color: var(--brand);
	letter-spacing: 0.06em;
}
.section-heading {
	font-size: 22px;
	font-weight: 800;
	color: #0f172a;
	margin: 0;
}
.section-action-link {
	font-size: 14px;
	font-weight: 600;
	color: var(--brand);
	text-decoration: none;
}
.section-action-link:hover {
	text-decoration: underline;
}

.continue-learning-grid {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
	gap: 16px;
}
.continue-card {
	background: #ffffff;
	border: 1px solid #bfdbfe;
	border-radius: 12px;
	padding: 16px;
	display: flex;
	gap: 16px;
	align-items: center;
	box-shadow: 0 2px 8px rgba(37, 99, 235, 0.05);
	transition: all 0.2s;
}
.continue-card:hover {
	border-color: var(--brand);
	box-shadow: 0 6px 20px rgba(37, 99, 235, 0.12);
	transform: translateY(-2px);
}
.continue-card-thumb {
	width: 88px;
	height: 66px;
	border-radius: 8px;
	overflow: hidden;
	flex-shrink: 0;
	background: #e2e8f0;
}
.continue-card-thumb img {
	width: 100%;
	height: 100%;
	object-fit: cover;
}
.continue-placeholder {
	width: 100%;
	height: 100%;
	display: grid;
	place-items: center;
	font-size: 28px;
	background: linear-gradient(135deg, var(--brand), #1d4ed8);
	color: #fff;
}
.continue-card-content {
	flex: 1;
	min-width: 0;
	display: flex;
	flex-direction: column;
	gap: 6px;
}
.continue-card-title {
	font-size: 15px;
	font-weight: 700;
	margin: 0;
	line-height: 1.35;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}
.continue-card-title a {
	color: #0f172a;
}
.continue-card-title a:hover {
	color: var(--brand);
}
.continue-progress-wrap {
	display: flex;
	flex-direction: column;
	gap: 4px;
}
.continue-progress-bar {
	height: 6px;
	background: #e2e8f0;
	border-radius: 999px;
	overflow: hidden;
}
.continue-progress-fill {
	height: 100%;
	background: linear-gradient(90deg, #2563eb, #38bdf8);
	border-radius: 999px;
}
.continue-progress-labels {
	display: flex;
	justify-content: space-between;
	font-size: 12px;
	color: var(--muted);
}
.continue-progress-labels strong {
	color: var(--brand);
}
.continue-action-row {
	margin-top: 4px;
}
.btn-continue-play {
	font-size: 13px;
	padding: 6px 14px;
	border-radius: 6px;
}

/* === 3. Course Catalog Section === */
.catalog-section {
	padding: 44px 0 80px;
}
.catalog-control-bar {
	display: flex;
	justify-content: space-between;
	align-items: center;
	gap: 16px;
	margin-bottom: 20px;
	flex-wrap: wrap;
}
.catalog-heading-wrap {
	display: flex;
	flex-direction: column;
	gap: 4px;
}
.catalog-title {
	font-size: 24px;
	font-weight: 800;
	color: #0f172a;
	margin: 0;
}
.catalog-subtitle {
	font-size: 14px;
	color: var(--muted);
}
.catalog-view-switcher {
	display: inline-flex;
	background: #e2e8f0;
	border-radius: 8px;
	padding: 3px;
	gap: 2px;
}
.view-btn {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 6px 12px;
	border: 0;
	background: transparent;
	border-radius: 6px;
	font-size: 13px;
	font-weight: 600;
	color: #64748b;
	cursor: pointer;
	transition: all 0.15s;
}
.view-btn:hover {
	color: #0f172a;
}
.view-btn.active {
	background: #ffffff;
	color: var(--brand);
	box-shadow: 0 1px 3px rgba(0,0,0,0.08);
}

/* Thanh điều hướng filter tabs */
.portal-filter-nav {
	display: flex;
	justify-content: space-between;
	align-items: center;
	gap: 16px;
	margin-bottom: 28px;
	padding-bottom: 18px;
	border-bottom: 1px solid var(--border);
	flex-wrap: wrap;
}
.category-tabs {
	display: flex;
	gap: 8px;
	flex-wrap: wrap;
	flex: 1;
}
.cat-pill-tab {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 8px 16px;
	border-radius: 999px;
	border: 1px solid #cbd5e1;
	background: #ffffff;
	font-size: 13.5px;
	font-weight: 600;
	color: #334155;
	cursor: pointer;
	transition: all 0.15s;
}
.cat-pill-tab:hover {
	border-color: var(--brand);
	color: var(--brand);
	background: #f0f7ff;
}
.cat-pill-tab.active {
	background: var(--brand);
	color: #ffffff;
	border-color: var(--brand);
	box-shadow: 0 2px 8px rgba(37, 99, 235, 0.25);
}
.tab-count {
	font-size: 12px;
	opacity: 0.8;
}
.cat-pill-tab.active .tab-count {
	opacity: 0.95;
}

.status-filter-wrap {
	display: flex;
	align-items: center;
	gap: 8px;
}
.filter-label {
	font-size: 13.5px;
	font-weight: 600;
	color: #475569;
}
.status-select {
	padding: 7px 12px;
	border: 1px solid #cbd5e1;
	border-radius: 8px;
	background: #ffffff;
	font-size: 13.5px;
	color: #1e293b;
	outline: none;
	cursor: pointer;
}
.status-select:focus {
	border-color: var(--brand);
}

/* === 4. Internal Course Grid & Card === */
.internal-course-grid {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 24px;
	transition: opacity 0.2s;
}

@media (max-width: 991px) {
	.internal-course-grid {
		grid-template-columns: repeat(2, 1fr);
		gap: 20px;
	}
}

@media (max-width: 640px) {
	.internal-course-grid {
		grid-template-columns: 1fr;
		gap: 16px;
	}
}

.internal-course-card {
	background: #ffffff;
	border: 1px solid var(--border);
	border-radius: 14px;
	overflow: hidden;
	display: flex;
	flex-direction: column;
	box-shadow: var(--shadow);
	transition: transform 0.2s, box-shadow 0.2s, border-color 0.2s;
}
.internal-course-card:hover {
	transform: translateY(-4px);
	box-shadow: 0 10px 30px rgba(15, 23, 42, 0.08);
	border-color: #cbd5e1;
}

/* Thumbnail */
.card-thumb-wrap {
	position: relative;
	aspect-ratio: 16/9;
	background: #e2e8f0;
	overflow: hidden;
}
.card-thumb-link {
	display: block;
	width: 100%;
	height: 100%;
}
.card-thumb-img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform 0.35s ease;
}
.internal-course-card:hover .card-thumb-img {
	transform: scale(1.05);
}
.card-thumb-placeholder {
	width: 100%;
	height: 100%;
	background: linear-gradient(135deg, #1e3a8a 0%, #2563eb 60%, #60a5fa 100%);
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	color: #ffffff;
	gap: 4px;
}
.placeholder-icon {
	font-size: 42px;
	filter: drop-shadow(0 2px 4px rgba(0,0,0,0.2));
}
.placeholder-code {
	font-size: 11px;
	font-weight: 800;
	letter-spacing: 0.12em;
	opacity: 0.85;
}

/* Badges */
.card-badges {
	position: absolute;
	top: 10px;
	left: 10px;
	display: flex;
	gap: 6px;
	z-index: 2;
}
.badge-status {
	padding: 4px 10px;
	border-radius: 999px;
	font-size: 11.5px;
	font-weight: 700;
	line-height: 1.2;
	box-shadow: 0 2px 6px rgba(0, 0, 0, 0.18);
}
.badge-success {
	background: #16a34a;
	color: #ffffff;
}
.badge-learning {
	background: #2563eb;
	color: #ffffff;
}
.badge-internal {
	background: rgba(15, 23, 42, 0.8);
	color: #ffffff;
	backdrop-filter: blur(4px);
}

/* Card Content */
.card-content {
	padding: 18px;
	display: flex;
	flex-direction: column;
	gap: 10px;
	flex: 1;
}
.card-header-meta {
	display: flex;
	justify-content: space-between;
	align-items: center;
	font-size: 12px;
	gap: 8px;
}
.card-category-tag {
	color: var(--brand);
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.04em;
	background: #eff6ff;
	padding: 3px 8px;
	border-radius: 6px;
}
.card-instructor {
	color: var(--muted);
	font-size: 12px;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}
.card-title {
	font-size: 16.5px;
	font-weight: 700;
	line-height: 1.4;
	margin: 0;
	min-height: 44px;
}
.card-title a {
	color: #0f172a;
	transition: color 0.15s;
}
.card-title a:hover {
	color: var(--brand);
}
.card-excerpt {
	color: var(--muted);
	font-size: 13.5px;
	line-height: 1.55;
	margin: 0;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

/* Metrics */
.card-info-metrics {
	display: flex;
	gap: 14px;
	font-size: 13px;
	color: var(--muted);
	padding-top: 4px;
	flex-wrap: wrap;
}
.metric-item {
	display: inline-flex;
	align-items: center;
	gap: 5px;
}
.metric-item svg {
	color: #64748b;
}

/* Tiến độ */
.card-progress-wrap {
	margin-top: auto;
	padding-top: 8px;
	display: flex;
	flex-direction: column;
	gap: 4px;
}
.card-progress-bar {
	height: 6px;
	background: #e2e8f0;
	border-radius: 999px;
	overflow: hidden;
}
.card-progress-fill {
	height: 100%;
	background: linear-gradient(90deg, #2563eb, #38bdf8);
	border-radius: 999px;
}
.card-progress-text {
	font-size: 12px;
	color: var(--muted);
}
.card-progress-text strong {
	color: var(--brand);
}

/* Footer & Buttons */
.card-footer {
	margin-top: auto;
	padding-top: 14px;
	border-top: 1px solid var(--border);
}
.btn-card-action {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	padding: 10px 16px;
	border-radius: 8px;
	font-size: 14px;
	font-weight: 600;
	text-decoration: none;
	transition: all 0.15s;
	text-align: center;
}
.btn-action-continue {
	background: var(--brand);
	color: #ffffff;
}
.btn-action-continue:hover {
	background: var(--brand-dark);
	box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
	color: #ffffff;
}
.btn-action-start {
	background: #f8fafc;
	color: #1e293b;
	border: 1px solid #cbd5e1;
}
.btn-action-start:hover {
	background: var(--brand);
	color: #ffffff;
	border-color: var(--brand);
}

/* === Chế độ hiển thị Danh sách (List View) === */
.internal-course-grid.list-view {
	display: flex;
	flex-direction: column;
	gap: 16px;
}
.internal-course-grid.list-view .internal-course-card {
	flex-direction: row;
	align-items: stretch;
}
.internal-course-grid.list-view .card-thumb-wrap {
	width: 260px;
	flex-shrink: 0;
	aspect-ratio: auto;
}
.internal-course-grid.list-view .card-content {
	display: grid;
	grid-template-columns: 1fr 200px;
	gap: 16px;
	align-items: center;
	width: 100%;
}
.internal-course-grid.list-view .card-footer {
	margin-top: 0;
	padding-top: 0;
	border-top: 0;
	border-left: 1px solid var(--border);
	padding-left: 20px;
	display: flex;
	flex-direction: column;
	justify-content: center;
	height: 100%;
}
.internal-course-grid.list-view .card-title {
	min-height: auto;
}

/* === 5. Empty States === */
.empty-state-card {
	grid-column: 1 / -1;
	text-align: center;
	padding: 64px 24px;
	background: #ffffff;
	border-radius: 16px;
	border: 1px solid var(--border);
}
.empty-icon {
	font-size: 48px;
	margin-bottom: 12px;
}
.empty-search-state {
	text-align: center;
	padding: 56px 24px;
	background: #ffffff;
	border-radius: 16px;
	border: 2px dashed #cbd5e1;
	margin: 20px 0;
}
.empty-search-icon {
	font-size: 44px;
	margin-bottom: 12px;
	opacity: 0.6;
}
.empty-search-desc {
	color: var(--muted);
	font-size: 14.5px;
	margin-bottom: 18px;
}

/* === Responsive cho Cổng Đào Tạo Nội Bộ === */
@media (max-width: 1024px) {
	.welcome-box {
		grid-template-columns: 1fr;
		gap: 32px;
	}
	.student-quick-stats {
		grid-template-columns: repeat(2, 1fr);
	}
	.internal-course-grid.list-view .card-content {
		grid-template-columns: 1fr;
	}
	.internal-course-grid.list-view .card-footer {
		border-left: 0;
		border-top: 1px solid var(--border);
		padding-left: 0;
		padding-top: 12px;
	}
}

@media (max-width: 768px) {
	.portal-welcome-hero {
		padding: 30px 0;
	}
	.internal-course-grid.list-view .internal-course-card {
		flex-direction: column;
	}
	.internal-course-grid.list-view .card-thumb-wrap {
		width: 100%;
		aspect-ratio: 16/9;
	}
	.continue-learning-grid {
		grid-template-columns: 1fr;
	}
	.catalog-control-bar {
		flex-direction: column;
		align-items: flex-start;
	}
	.portal-filter-nav {
		flex-direction: column;
		align-items: flex-start;
	}
	.status-filter-wrap {
		width: 100%;
		justify-content: space-between;
	}
}

@media (max-width: 480px) {
	.student-quick-stats {
		grid-template-columns: 1fr;
	}
}


/* ==========================================================================
   Chi tiết Khoá học — Bố cục 2 cột & Danh sách bài học đa tầng (2/3 tầng)
   ========================================================================== */

.internal-course-detail-wrapper {
	background: #f8fafc;
	min-height: calc(100vh - 70px);
	padding-bottom: 80px;
}

/* === Header trang chi tiết === */
.course-detail-header {
	background: #ffffff;
	border-bottom: 1px solid var(--border);
	padding: 28px 0 24px;
}
.course-breadcrumb {
	font-size: 13.5px;
	color: var(--muted);
	margin-bottom: 14px;
	display: flex;
	align-items: center;
	gap: 6px;
	flex-wrap: wrap;
}
.course-breadcrumb a {
	color: var(--muted);
	text-decoration: none;
}
.course-breadcrumb a:hover {
	color: var(--brand);
}

.course-header-badges {
	display: flex;
	gap: 8px;
	margin-bottom: 10px;
	flex-wrap: wrap;
}
.badge-cat {
	background: #eff6ff;
	color: var(--brand);
	font-size: 12px;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.04em;
	padding: 3px 10px;
	border-radius: 6px;
}
.badge-tag-internal {
	background: #f1f5f9;
	color: #475569;
	font-size: 12px;
	font-weight: 600;
	padding: 3px 10px;
	border-radius: 6px;
	border: 1px solid #cbd5e1;
}
.badge-tag-status {
	font-size: 12px;
	font-weight: 700;
	padding: 3px 10px;
	border-radius: 6px;
}
.badge-tag-status.success {
	background: #dcfce7;
	color: #166534;
}
.badge-tag-status.learning {
	background: #dbeafe;
	color: #1e40af;
}

.course-main-title {
	font-size: clamp(24px, 3vw, 34px);
	font-weight: 800;
	color: #0f172a;
	line-height: 1.3;
	margin: 0 0 10px;
	letter-spacing: -0.015em;
}
.course-main-desc {
	font-size: 15.5px;
	color: #475569;
	line-height: 1.6;
	margin: 0 0 16px;
	max-width: 860px;
}

.course-meta-inline {
	display: flex;
	gap: 20px;
	flex-wrap: wrap;
	font-size: 13.5px;
	color: var(--muted);
	padding-top: 6px;
	border-top: 1px solid #f1f5f9;
}
.meta-item {
	display: inline-flex;
	align-items: center;
	gap: 6px;
}
.meta-icon {
	font-size: 15px;
}

/* === Course Hero Grid & Layout === */
.course-hero-grid {
	display: grid;
	grid-template-columns: 460px 1fr;
	gap: 32px;
	align-items: center;
	margin-top: 16px;
}

.course-hero-visual {
	position: relative;
	border-radius: 14px;
	overflow: hidden;
	box-shadow: 0 4px 16px rgba(15, 23, 42, 0.08);
}
.course-hero-visual .course-cover-box,
.course-hero-visual .course-video-box {
	aspect-ratio: 16/9;
	background: #0f172a;
	border-radius: 14px;
	overflow: hidden;
}
.course-hero-visual .course-cover-img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

.video-responsive-wrap {
	position: relative;
	padding-bottom: 56.25%; /* 16:9 */
	height: 0;
	overflow: hidden;
}
.video-responsive-wrap iframe {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	border: 0;
}

.course-hero-info {
	display: flex;
	flex-direction: column;
	gap: 10px;
}
.course-hero-info .course-header-badges {
	margin-bottom: 2px;
}
.course-hero-info .course-main-title {
	margin: 0;
	font-size: clamp(22px, 2.5vw, 28px);
}
.course-hero-info .course-main-desc {
	margin: 0;
	font-size: 14.5px;
}
.course-hero-info .course-meta-inline {
	border-top: 0;
	padding-top: 0;
	gap: 16px;
	margin-bottom: 2px;
}

.hero-action-card {
	background: #ffffff;
	border: 1px solid #bfdbfe;
	border-radius: 14px;
	padding: 18px 20px;
	box-shadow: 0 4px 16px rgba(37, 99, 235, 0.06);
	display: flex;
	flex-direction: column;
	gap: 12px;
}

.course-hero-cta {
	margin-top: 8px;
	display: flex;
	align-items: center;
}
.btn-course-continue {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: auto !important;
	padding: 12px 28px;
	font-size: 15px;
	font-weight: 600;
	border-radius: 10px;
	box-shadow: 0 4px 14px rgba(37, 99, 235, 0.22);
	transition: all 0.18s ease;
}
.btn-course-continue:hover {
	transform: translateY(-1px);
	box-shadow: 0 6px 18px rgba(37, 99, 235, 0.32);
	color: #fff;
}

/* === Course Body Container & Curriculum === */
.course-body-container {
	padding-top: 32px;
	padding-bottom: 60px;
}

.detail-box {
	background: #ffffff;
	border: 1px solid var(--border);
	border-radius: 14px;
	padding: 24px 26px;
	box-shadow: 0 1px 4px rgba(15, 23, 42, 0.04);
}
.box-heading {
	font-size: 18px;
	font-weight: 700;
	color: #0f172a;
	margin: 0 0 12px;
	display: flex;
	align-items: center;
	gap: 8px;
}
.course-prose {
	font-size: 15px;
	line-height: 1.75;
	color: #334155;
}
.course-prose p {
	margin-bottom: 1em;
}

/* Khối Danh Sách Bài Học (Curriculum Tree Chính) */
.course-curriculum-main {
	background: #ffffff;
	border: 1px solid var(--border);
	border-radius: 14px;
	box-shadow: 0 4px 16px rgba(15, 23, 42, 0.05);
	overflow: hidden;
}
.course-curriculum-main .curriculum-card-header {
	padding: 18px 24px;
	background: #ffffff;
	border-bottom: 1px solid var(--border);
}
.course-curriculum-main .curriculum-title {
	font-size: 18px;
	font-weight: 800;
	color: #0f172a;
}
.course-curriculum-main .tree-l1-header {
	padding: 14px 22px;
}
.course-curriculum-main .tree-l1-title {
	font-size: 15px;
}
.course-curriculum-main .tree-lesson-item {
	padding: 12px 20px 12px 32px;
}
.course-curriculum-main .tree-lesson-item.direct-item {
	padding: 12px 20px 12px 36px;
}
.course-curriculum-main .lesson-link {
	font-size: 14.5px;
	font-weight: 500;
}

/* Card Hành Động & Trạng Thái */
.action-card {
	background: #ffffff;
	border: 1px solid #bfdbfe;
	border-radius: 14px;
	padding: 20px;
	box-shadow: 0 4px 16px rgba(37, 99, 235, 0.06);
	display: flex;
	flex-direction: column;
	gap: 14px;
}
.enrolled-status-header {
	display: flex;
	flex-direction: column;
	gap: 10px;
}
.status-title-row {
	display: flex;
	align-items: center;
	gap: 8px;
	font-size: 14px;
	color: #1e3a8a;
}
.status-dot {
	width: 8px;
	height: 8px;
	border-radius: 50%;
	background: #2563eb;
}
.status-progress-wrap {
	display: flex;
	flex-direction: column;
	gap: 4px;
}
.status-progress-bar {
	height: 8px;
	background: #e2e8f0;
	border-radius: 999px;
	overflow: hidden;
}
.status-progress-fill {
	height: 100%;
	background: linear-gradient(90deg, #2563eb, #38bdf8);
	border-radius: 999px;
}
.status-progress-meta {
	display: flex;
	justify-content: space-between;
	font-size: 12.5px;
	color: var(--muted);
}
.status-progress-meta strong {
	color: var(--brand);
}

.guest-action-header {
	display: flex;
	flex-direction: column;
	gap: 6px;
}
.badge-internal-pill {
	display: inline-block;
	background: #f0fdf4;
	color: #166534;
	border: 1px solid #bbf7d0;
	font-size: 12px;
	font-weight: 700;
	padding: 3px 10px;
	border-radius: 999px;
	width: fit-content;
}
.action-heading {
	font-size: 17px;
	font-weight: 700;
	color: #0f172a;
	margin: 0;
}
.action-desc {
	font-size: 13.5px;
	color: var(--muted);
	margin: 0;
	line-height: 1.5;
}
.action-sub-tip {
	font-size: 12px;
	color: var(--muted);
	text-align: center;
	margin: 0;
}
.btn-action-cta {
	font-weight: 700;
	letter-spacing: -0.01em;
	padding: 12px 18px;
	border-radius: 10px;
	box-shadow: 0 4px 12px rgba(37, 99, 235, 0.25);
}

/* === Box Danh Sách Bài Học (Curriculum Card) === */
.curriculum-card {
	background: #ffffff;
	border: 1px solid var(--border);
	border-radius: 14px;
	overflow: hidden;
	box-shadow: 0 2px 8px rgba(15, 23, 42, 0.05);
}
.curriculum-card-header {
	display: flex;
	justify-content: space-between;
	align-items: center;
	padding: 16px 18px;
	background: #ffffff;
	border-bottom: 1px solid var(--border);
}
.curriculum-title {
	font-size: 16px;
	font-weight: 800;
	color: #0f172a;
	margin: 0;
}
.curriculum-counts {
	font-size: 12px;
	color: var(--muted);
	display: block;
	margin-top: 2px;
}
.btn-toggle-all-tree {
	border: 1px solid #cbd5e1;
	background: #f8fafc;
	color: #475569;
	font-size: 12px;
	font-weight: 600;
	padding: 5px 10px;
	border-radius: 6px;
	cursor: pointer;
	transition: all 0.15s;
}
.btn-toggle-all-tree:hover {
	background: #ffffff;
	border-color: var(--brand);
	color: var(--brand);
}

.curriculum-tree-body {
	display: flex;
	flex-direction: column;
}
.curriculum-empty {
	padding: 32px 20px;
	text-align: center;
}

/* ==========================================================================
   Cấu Trúc Bài Học Đa Tầng (Level 1, Level 2, Level 3)
   ========================================================================== */

/* --- TẦNG 1: Section / Bài lớn (Ví dụ: Bài 1, Bài 2) --- */
.tree-node-level-1 {
	border-bottom: 1px solid #e2e8f0;
}
.tree-node-level-1:last-child {
	border-bottom: 0;
}

.tree-l1-header {
	width: 100%;
	display: flex;
	justify-content: space-between;
	align-items: center;
	padding: 13px 18px;
	background: #f8fafc;
	border: 0;
	cursor: pointer;
	text-align: left;
	transition: background 0.15s;
	gap: 10px;
}
.tree-l1-header:hover {
	background: #f1f5f9;
}
.l1-title-wrap {
	display: flex;
	align-items: center;
	gap: 8px;
	min-width: 0;
	flex: 1;
}
.tree-chevron {
	font-size: 13px;
	color: #64748b;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 20px;
	height: 20px;
	transition: transform 0.2s cubic-bezier(0.4, 0, 0.2, 1), color 0.15s ease;
	transform: rotate(0deg);
	transform-origin: center center;
	flex-shrink: 0;
	line-height: 1;
}
.tree-node-level-1.open > .tree-l1-header .tree-chevron {
	transform: rotate(90deg);
	color: var(--brand, #2563eb);
}
.tree-l1-title {
	font-size: 14.5px;
	font-weight: 700;
	color: #0f172a;
	line-height: 1.35;
}
.tree-l1-badge {
	font-size: 12px;
	font-weight: 600;
	color: var(--muted);
	background: #ffffff;
	border: 1px solid #e2e8f0;
	padding: 2px 8px;
	border-radius: 999px;
	flex-shrink: 0;
}

/* Nội dung Tầng 1 */
.tree-l1-content {
	display: none;
	padding: 6px 0;
	background: #ffffff;
}
.tree-node-level-1.open > .tree-l1-content {
	display: block;
}

/* --- TẦNG 2: Nhóm con (3 tầng: Phần 1) --- */
.tree-node-level-2 {
	margin: 6px 12px 8px 16px;
	border: 1px solid #e2e8f0;
	border-radius: 8px;
	background: #ffffff;
	overflow: hidden;
}
.tree-l2-header {
	width: 100%;
	display: flex;
	justify-content: space-between;
	align-items: center;
	padding: 9px 12px;
	background: #f8fafc;
	border: 0;
	border-bottom: 1px solid transparent;
	cursor: pointer;
	text-align: left;
	transition: all 0.15s;
	gap: 8px;
}
.tree-node-level-2.open .tree-l2-header {
	border-bottom-color: #e2e8f0;
	background: #f1f5f9;
}
.l2-title-wrap {
	display: flex;
	align-items: center;
	gap: 6px;
	min-width: 0;
	flex: 1;
}
.l2-folder-icon {
	font-size: 14px;
	flex-shrink: 0;
}
.tree-l2-title {
	font-size: 13.5px;
	font-weight: 600;
	color: #1e293b;
	line-height: 1.3;
}
.tree-l2-badge {
	font-size: 11.5px;
	color: var(--muted);
	display: flex;
	align-items: center;
	gap: 4px;
	flex-shrink: 0;
}
.l2-chevron {
	font-size: 11px;
	color: #64748b;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 16px;
	height: 16px;
	transition: transform 0.2s cubic-bezier(0.4, 0, 0.2, 1), color 0.15s ease;
	transform: rotate(0deg);
	transform-origin: center center;
	flex-shrink: 0;
	line-height: 1;
}
.tree-node-level-2.open .l2-chevron {
	transform: rotate(90deg);
	color: var(--brand, #2563eb);
}

/* --- TẦNG 3: Danh sách bài học chi tiết (Phần 1-1, Phần 1-2) --- */
.tree-l3-list {
	list-style: none;
	margin: 0;
	padding: 4px 0;
	display: none;
	background: #ffffff;
}
.tree-node-level-2.open .tree-l3-list {
	display: block;
}

/* --- TẦNG 2 TRỰC TIẾP (Dành cho bài chỉ có 2 tầng) --- */
.tree-node-level-2-direct {
	display: block;
}

/* Item bài học (Dùng chung cho Tầng 3 và Tầng 2 trực tiếp) */
.tree-lesson-item {
	display: flex;
	align-items: center;
	gap: 10px;
	padding: 8px 12px 8px 24px;
	position: relative;
	transition: background 0.15s;
	border-bottom: 1px solid #f8fafc;
}
.tree-lesson-item:last-child {
	border-bottom: 0;
}
.tree-lesson-item.direct-item {
	padding: 10px 18px 10px 32px;
	border-bottom: 1px solid #f1f5f9;
}
.tree-lesson-item:hover {
	background: #eff6ff;
}
.tree-lesson-item.done {
	background: #fcfdfc;
}

.lesson-state-icon {
	width: 20px;
	height: 20px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	font-size: 14px;
	flex-shrink: 0;
	line-height: 1;
}
.lesson-state-icon .icon-done {
	color: #10b981;
	font-size: 15px;
}
.lesson-state-icon .icon-locked {
	color: #94a3b8;
	font-size: 13px;
}
.lesson-state-icon .icon-type {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	color: #64748b;
	font-size: 14px;
}
.lesson-state-icon .icon-type.type-video {
	color: #2563eb;
	font-size: 15px;
}
.lesson-state-icon .icon-type.type-text {
	color: #64748b;
	font-size: 15px;
}
.lesson-state-icon .icon-type.type-quiz {
	color: #7c3aed;
	font-size: 15px;
}

.lesson-name-col {
	flex: 1;
	min-width: 0;
	display: flex;
	align-items: center;
	gap: 6px;
	flex-wrap: wrap;
}
.lesson-link {
	color: #334155;
	font-size: 13px;
	font-weight: 500;
	line-height: 1.4;
	text-decoration: none;
	transition: color 0.15s;
}
.lesson-link:hover {
	color: var(--brand);
}
.tree-lesson-item.done .lesson-link {
	color: #1e293b;
}
.lesson-locked-title {
	color: #94a3b8;
	font-size: 13px;
	line-height: 1.4;
}

.badge-preview-tag {
	background: #fef3c7;
	color: #b45309;
	font-size: 10.5px;
	font-weight: 700;
	padding: 1px 6px;
	border-radius: 4px;
	white-space: nowrap;
}

.lesson-time {
	font-size: 11.5px;
	color: #94a3b8;
	flex-shrink: 0;
}

/* === Responsive cho Single Course Layout === */
@media (max-width: 991px) {
	.course-hero-grid {
		grid-template-columns: 1fr;
		gap: 20px;
	}
	.course-body-container {
		padding-top: 24px;
		padding-bottom: 40px;
	}
	.course-curriculum-main .curriculum-card-header {
		padding: 16px 18px;
	}
	.course-curriculum-main .tree-l1-header {
		padding: 13px 18px;
	}
}

@media (max-width: 768px) {
	.course-main-title {
		font-size: 22px;
	}
	.detail-box {
		padding: 20px 18px;
	}
	.course-curriculum-main .tree-lesson-item {
		padding: 10px 14px 10px 24px;
	}
	.course-curriculum-main .tree-lesson-item.direct-item {
		padding: 10px 14px 10px 24px;
	}
}


/* ==========================================================================
   Giao diện Trang chủ Tinh Gọn (Bỏ Search, Bỏ Stats, Card 4 thành phần)
   ========================================================================== */

.portal-welcome-hero.minimal-hero {
	padding: 36px 0 32px;
	background: #ffffff;
	border-bottom: 1px solid var(--border);
}
.welcome-box.single-box {
	display: block;
	max-width: 800px;
}
.welcome-box.single-box .welcome-title {
	font-size: clamp(24px, 3.2vw, 32px);
	margin: 8px 0 10px;
}
.welcome-box.single-box .welcome-desc {
	font-size: 15.5px;
	color: var(--muted);
	margin-bottom: 0;
	line-height: 1.6;
}

/* Thẻ Khoá Học Tối Giản */
.internal-course-card.minimal-card {
	border-radius: 12px;
	border: 1px solid var(--border);
	background: #ffffff;
	display: flex;
	flex-direction: column;
	overflow: hidden;
	box-shadow: var(--shadow);
	transition: transform 0.2s, box-shadow 0.2s, border-color 0.2s;
}
.internal-course-card.minimal-card:hover {
	transform: translateY(-4px);
	box-shadow: 0 10px 24px rgba(15, 23, 42, 0.08);
	border-color: #cbd5e1;
}

.internal-course-card.minimal-card .card-thumb-link {
	display: block;
	position: relative;
	aspect-ratio: 16/9;
	overflow: hidden;
	background: #e2e8f0;
}
.internal-course-card.minimal-card .card-thumb-img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform 0.3s ease;
}
.internal-course-card.minimal-card:hover .card-thumb-img {
	transform: scale(1.05);
}
.internal-course-card.minimal-card .card-thumb-placeholder {
	width: 100%;
	height: 100%;
	background: linear-gradient(135deg, #1e3a8a 0%, #2563eb 100%);
	display: grid;
	place-items: center;
	color: #ffffff;
}
.internal-course-card.minimal-card .placeholder-icon {
	font-size: 42px;
}

.internal-course-card.minimal-card .card-content {
	padding: 16px 18px 18px;
	display: flex;
	flex-direction: column;
	flex: 1;
	gap: 10px;
}
.internal-course-card.minimal-card .card-title {
	font-size: 16.5px;
	font-weight: 700;
	line-height: 1.4;
	margin: 0;
	min-height: 44px;
}
.internal-course-card.minimal-card .card-title a {
	color: #0f172a;
	text-decoration: none;
	transition: color 0.15s;
}
.internal-course-card.minimal-card .card-title a:hover {
	color: var(--brand);
}

.card-lesson-count {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	font-size: 13.5px;
	color: #64748b;
	font-weight: 500;
}
.card-lesson-count svg {
	color: var(--brand);
}

.internal-course-card.minimal-card .card-footer {
	margin-top: auto;
	padding-top: 12px;
	border-top: 1px solid var(--border);
}
.btn-start-course {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	padding: 10px 16px;
	border-radius: 8px;
	font-size: 14px;
	font-weight: 600;
	background: var(--brand);
	color: #ffffff;
	text-decoration: none;
	transition: all 0.15s;
	text-align: center;
}
.btn-start-course:hover {
	background: var(--brand-dark);
	box-shadow: 0 4px 12px rgba(37, 99, 235, 0.28);
	color: #ffffff;
}

/* List view cho Minimal Card */
.internal-course-grid.list-view .internal-course-card.minimal-card {
	flex-direction: row;
	align-items: stretch;
}
.internal-course-grid.list-view .internal-course-card.minimal-card .card-thumb-link {
	width: 240px;
	flex-shrink: 0;
	aspect-ratio: auto;
}
.internal-course-grid.list-view .internal-course-card.minimal-card .card-content {
	display: grid;
	grid-template-columns: 1fr 180px;
	align-items: center;
	gap: 16px;
}
.internal-course-grid.list-view .internal-course-card.minimal-card .card-title {
	min-height: auto;
}
.internal-course-grid.list-view .internal-course-card.minimal-card .card-footer {
	margin-top: 0;
	padding-top: 0;
	border-top: 0;
	border-left: 1px solid var(--border);
	padding-left: 18px;
	height: 100%;
	display: flex;
	align-items: center;
}

@media (max-width: 768px) {
	.internal-course-grid.list-view .internal-course-card.minimal-card {
		flex-direction: column;
	}
	.internal-course-grid.list-view .internal-course-card.minimal-card .card-thumb-link {
		width: 100%;
		aspect-ratio: 16/9;
	}
	.internal-course-grid.list-view .internal-course-card.minimal-card .card-content {
		grid-template-columns: 1fr;
	}
	.internal-course-grid.list-view .internal-course-card.minimal-card .card-footer {
		border-left: 0;
		border-top: 1px solid var(--border);
		padding-left: 0;
		padding-top: 12px;
	}
}

/* =========================================================================
   POPUP ĐĂNG NHẬP HỌC VIÊN (LOGIN MODAL)
   ========================================================================= */
body.lms-modal-open {
	overflow: hidden;
}

.lms-modal {
	position: fixed;
	inset: 0;
	z-index: 99999;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 20px;
	opacity: 0;
	visibility: hidden;
	transition: opacity 0.25s ease, visibility 0.25s ease;
}

.lms-modal.show {
	opacity: 1;
	visibility: visible;
}

.lms-modal-backdrop {
	position: absolute;
	inset: 0;
	background: rgba(15, 23, 42, 0.68);
	backdrop-filter: blur(4px);
	-webkit-backdrop-filter: blur(4px);
}

.lms-modal-dialog {
	position: relative;
	z-index: 2;
	background: #ffffff;
	width: 100%;
	max-width: 440px;
	border-radius: 16px;
	padding: 32px 28px;
	box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.28);
	transform: translateY(20px) scale(0.96);
	transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.lms-modal.show .lms-modal-dialog {
	transform: translateY(0) scale(1);
}

.lms-modal-close {
	position: absolute;
	top: 16px;
	right: 16px;
	width: 34px;
	height: 34px;
	border-radius: 50%;
	border: none;
	background: #f1f5f9;
	color: #64748b;
	font-size: 24px;
	line-height: 1;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: all 0.15s ease;
}

.lms-modal-close:hover {
	background: #e2e8f0;
	color: #0f172a;
}

.lms-modal-header {
	text-align: center;
	margin-bottom: 22px;
}

.lms-modal-icon {
	font-size: 34px;
	line-height: 1;
	margin-bottom: 8px;
}

.lms-modal-title {
	font-size: 22px;
	font-weight: 700;
	color: #0f172a;
	margin: 0 0 6px;
}

.lms-modal-subtitle {
	font-size: 13.5px;
	color: #64748b;
	margin: 0;
	line-height: 1.5;
}

.lms-modal-form {
	display: flex;
	flex-direction: column;
	gap: 16px;
}

.modal-form-group {
	text-align: left;
}

.modal-form-group label {
	display: block;
	font-size: 13px;
	font-weight: 600;
	color: #334155;
	margin-bottom: 6px;
}

.modal-label-row {
	display: flex;
	justify-content: space-between;
	align-items: center;
	margin-bottom: 6px;
}

.modal-label-row label {
	margin-bottom: 0;
}

.modal-forgot-link {
	font-size: 12.5px;
	color: #2563eb;
	text-decoration: none;
}

.modal-forgot-link:hover {
	text-decoration: underline;
}

.modal-form-group input[type="text"],
.modal-form-group input[type="password"] {
	width: 100%;
	padding: 11px 14px;
	border: 1.5px solid #cbd5e1;
	border-radius: 8px;
	font-size: 14.5px;
	outline: none;
	background: #ffffff;
	color: #1e293b;
	transition: border-color 0.15s, box-shadow 0.15s;
	box-sizing: border-box;
}

.modal-form-group input[type="text"]:focus,
.modal-form-group input[type="password"]:focus {
	border-color: #2563eb;
	box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15);
}

.modal-form-row {
	display: flex;
	align-items: center;
	justify-content: space-between;
	font-size: 13px;
	color: #475569;
}

.modal-remember-label {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	cursor: pointer;
	user-select: none;
}

.btn-modal-submit {
	width: 100%;
	padding: 12px 16px;
	font-size: 15px;
	font-weight: 600;
	border-radius: 8px;
	background: #2563eb;
	color: #ffffff;
	border: none;
	cursor: pointer;
	transition: all 0.15s ease;
	display: flex;
	align-items: center;
	justify-content: center;
}

.btn-modal-submit:hover {
	background: #1d4ed8;
	box-shadow: 0 4px 12px rgba(37, 99, 235, 0.25);
}

.btn-modal-submit:disabled {
	opacity: 0.65;
	cursor: not-allowed;
	box-shadow: none;
}

.modal-feedback-msg {
	padding: 10px 14px;
	border-radius: 8px;
	font-size: 13.5px;
	line-height: 1.45;
	text-align: center;
}

.modal-feedback-msg.error {
	background: #fef2f2;
	border: 1px solid #fecaca;
	color: #b91c1c;
}

.modal-feedback-msg.success {
	background: #f0fdf4;
	border: 1px solid #bbf7d0;
	color: #15803d;
}

.lms-modal-footer {
	margin-top: 20px;
	padding-top: 16px;
	border-top: 1px solid #f1f5f9;
	text-align: center;
}

.modal-internal-tip {
	font-size: 12.5px;
	color: #94a3b8;
	margin: 0;
	line-height: 1.5;
}

/* =========================================================================
   TRÌNH ĐỌC & HIỂN THỊ TÀI LIỆU HỌC TẬP (DOCX, PDF, DOC, XLS)
   ========================================================================= */
.eduviet-doc-box {
	margin: 24px 0;
	border: 1px solid #e2e8f0;
	border-radius: 12px;
	overflow: hidden;
	background: #ffffff;
	box-shadow: 0 4px 16px rgba(15, 23, 42, 0.05);
	transition: box-shadow 0.2s, border-color 0.2s;
}
.eduviet-doc-box:hover {
	box-shadow: 0 6px 20px rgba(15, 23, 42, 0.08);
	border-color: #cbd5e1;
}

.eduviet-doc-topbar {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 14px 18px;
	background: #f8fafc;
	border-bottom: 1px solid #e2e8f0;
	flex-wrap: wrap;
	gap: 12px;
}
.eduviet-doc-meta {
	display: flex;
	align-items: center;
	gap: 12px;
	min-width: 240px;
}
.eduviet-doc-actions {
	display: flex;
	align-items: center;
	gap: 10px;
	flex-wrap: wrap;
}

.eduviet-doc-actions .btn,
.btn-toggle-fullscreen,
.btn-doc-tab,
.btn-doc-download {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 6px;
	height: 36px;
	padding: 0 15px;
	font-size: 13px;
	font-weight: 600;
	border-radius: 7px;
	line-height: 1;
	transition: all 0.15s ease;
	box-sizing: border-box;
	text-decoration: none;
	white-space: nowrap;
}

.btn-toggle-fullscreen {
	background: #ffffff;
	border: 1px solid #cbd5e1;
	color: #334155;
	cursor: pointer;
}
.btn-toggle-fullscreen:hover {
	background: #f1f5f9;
	border-color: #94a3b8;
	color: #0f172a;
}

.btn-doc-tab {
	background: #ffffff;
	border: 1px solid #3b82f6;
	color: #2563eb;
}
.btn-doc-tab:hover {
	background: #eff6ff;
	border-color: #1d4ed8;
	color: #1d4ed8;
}

.btn-doc-download {
	background: #2563eb;
	border: 1px solid #2563eb;
	color: #ffffff;
}
.btn-doc-download:hover {
	background: #1d4ed8;
	border-color: #1d4ed8;
	color: #ffffff;
}

/* Fullscreen mode */
.eduviet-doc-box:fullscreen,
.eduviet-doc-box:-webkit-full-screen {
	border-radius: 0 !important;
	border: 0 !important;
	margin: 0 !important;
	width: 100vw !important;
	height: 100vh !important;
	display: flex !important;
	flex-direction: column !important;
	background: #0f172a !important;
	z-index: 9999999 !important;
}
.eduviet-doc-box:fullscreen .eduviet-doc-topbar,
.eduviet-doc-box:-webkit-full-screen .eduviet-doc-topbar {
	background: #0f172a !important;
	border-bottom: 1px solid #334155 !important;
}
.eduviet-doc-box:fullscreen .eduviet-doc-meta div,
.eduviet-doc-box:-webkit-full-screen .eduviet-doc-meta div {
	color: #ffffff !important;
}
.eduviet-doc-box:fullscreen .eduviet-doc-meta small,
.eduviet-doc-box:-webkit-full-screen .eduviet-doc-meta small {
	color: #94a3b8 !important;
}
.eduviet-doc-box:fullscreen .docx-render-container,
.eduviet-doc-box:-webkit-full-screen .docx-render-container {
	flex: 1 !important;
	max-height: none !important;
	height: calc(100vh - 65px) !important;
	background: #1e293b !important;
}
.eduviet-doc-box:fullscreen .pdf-viewer,
.eduviet-doc-box:-webkit-full-screen .pdf-viewer {
	flex: 1 !important;
	height: calc(100vh - 65px) !important;
}
.eduviet-doc-box:fullscreen .pdf-viewer iframe,
.eduviet-doc-box:-webkit-full-screen .pdf-viewer iframe {
	height: 100% !important;
}

/* DOCX Viewer styles & Paper container */
.docx-render-container {
	background: #f1f5f9;
	padding: 28px 16px;
	max-height: 750px;
	overflow-y: auto;
	box-sizing: border-box;
}
.docx-render-container .docx-wrapper {
	background: transparent !important;
	padding: 0 !important;
	display: flex !important;
	flex-direction: column !important;
	align-items: center !important;
	gap: 24px !important;
}
.docx-render-container .docx-wrapper > section.docx {
	background: #ffffff !important;
	box-shadow: 0 4px 20px rgba(15, 23, 42, 0.08), 0 1px 4px rgba(15, 23, 42, 0.04) !important;
	border-radius: 4px !important;
	margin: 0 auto !important;
	max-width: 840px !important;
	width: 100% !important;
	box-sizing: border-box !important;
	color: #0f172a !important;
	line-height: 1.65 !important;
	font-family: inherit !important;
}

/* Document Loading State */
.doc-loading-state {
	padding: 56px 24px;
	text-align: center;
	color: #64748b;
	background: #f8fafc;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: 12px;
}
.doc-loading-spinner {
	width: 36px;
	height: 36px;
	border: 3px solid #e2e8f0;
	border-top-color: var(--brand);
	border-radius: 50%;
	animation: docSpin 0.8s linear infinite;
}

@keyframes docSpin {
	to { transform: rotate(360deg); }
}


/* ==========================================================================
   Internal Simple Portal Layout & Course List (Homepage)
   ========================================================================== */
.simple-portal-layout {
	background: #f8fafc;
	min-height: calc(100vh - 160px);
	padding-bottom: 60px;
}

.portal-header-simple {
	padding: 36px 0 20px;
}

.portal-header-card {
	background: #ffffff;
	border: 1px solid #e2e8f0;
	border-radius: 16px;
	padding: 32px 36px;
	box-shadow: 0 1px 3px rgba(15, 23, 42, 0.04);
}

.portal-header-badge {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	background: #ecfdf5;
	color: #047857;
	font-size: 13px;
	font-weight: 600;
	padding: 4px 12px;
	border-radius: 9999px;
	margin-bottom: 14px;
	border: 1px solid #a7f3d0;
}

.portal-header-badge .badge-dot {
	width: 8px;
	height: 8px;
	background: #10b981;
	border-radius: 50%;
	box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.2);
}

.portal-simple-title {
	font-size: 26px;
	font-weight: 700;
	color: #0f172a;
	margin: 0 0 10px;
	line-height: 1.3;
}

.portal-simple-title .user-highlight {
	color: var(--brand, #2563eb);
}

.portal-simple-desc {
	font-size: 15px;
	color: #64748b;
	margin: 0;
	line-height: 1.6;
	max-width: 680px;
}

.portal-login-action {
	margin-top: 20px;
}

.portal-course-section {
	padding-top: 16px;
}

.course-list-header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	margin-bottom: 20px;
	padding: 0 4px;
}

.course-list-title {
	font-size: 20px;
	font-weight: 700;
	color: #1e293b;
	margin: 0;
}

.course-list-count {
	font-size: 13px;
	font-weight: 600;
	color: #64748b;
	background: #e2e8f0;
	padding: 4px 12px;
	border-radius: 999px;
}

.internal-course-list {
	display: flex;
	flex-direction: column;
	gap: 12px;
}

.course-list-item {
	display: flex;
	align-items: center;
	gap: 20px;
	background: #ffffff;
	border: 1px solid #e2e8f0;
	border-radius: 14px;
	padding: 16px 20px;
	transition: all 0.2s ease;
	box-shadow: 0 1px 2px rgba(15, 23, 42, 0.02);
}

.course-list-item:hover {
	border-color: #cbd5e1;
	box-shadow: 0 6px 16px rgba(15, 23, 42, 0.06);
	transform: translateY(-1px);
}

.cli-index {
	font-size: 18px;
	font-weight: 800;
	color: #cbd5e1;
	width: 32px;
	text-align: center;
	flex-shrink: 0;
	font-variant-numeric: tabular-nums;
	transition: color 0.2s ease;
}

.course-list-item:hover .cli-index {
	color: var(--brand, #2563eb);
}

.cli-thumb {
	width: 96px;
	height: 60px;
	border-radius: 8px;
	overflow: hidden;
	flex-shrink: 0;
	background: #f1f5f9;
	display: flex;
	align-items: center;
	justify-content: center;
	border: 1px solid #e2e8f0;
}

.cli-thumb a {
	display: block;
	width: 100%;
	height: 100%;
}

.cli-thumb img.cli-img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

.cli-thumb-placeholder {
	font-size: 24px;
}

.cli-content {
	flex: 1;
	min-width: 0;
}

.cli-title {
	margin: 0 0 6px;
	font-size: 16px;
	font-weight: 700;
	line-height: 1.4;
}

.cli-title a {
	color: #1e293b;
	text-decoration: none;
	transition: color 0.15s ease;
}

.cli-title a:hover {
	color: var(--brand, #2563eb);
}

.cli-meta-row {
	display: flex;
	align-items: center;
	gap: 14px;
	flex-wrap: wrap;
	font-size: 13px;
	color: #64748b;
}

.cli-meta-item {
	display: inline-flex;
	align-items: center;
	gap: 6px;
}

.cli-badge-enrolled {
	display: inline-flex;
	align-items: center;
	font-size: 12px;
	font-weight: 600;
	padding: 2px 10px;
	border-radius: 999px;
}

.cli-badge-enrolled.learning {
	background: #eff6ff;
	color: #2563eb;
	border: 1px solid #bfdbfe;
}

.cli-badge-enrolled.done {
	background: #ecfdf5;
	color: #059669;
	border: 1px solid #a7f3d0;
}

.cli-action {
	flex-shrink: 0;
}

.btn-cli {
	padding: 9px 20px;
	font-size: 14px;
	font-weight: 600;
	border-radius: 8px;
	white-space: nowrap;
	transition: all 0.15s ease;
}

@media (max-width: 768px) {
	.portal-header-card {
		padding: 24px 20px;
	}
	.portal-simple-title {
		font-size: 20px;
	}
	.course-list-item {
		flex-wrap: wrap;
		gap: 14px;
		padding: 14px 16px;
	}
	.cli-index {
		display: none;
	}
	.cli-thumb {
		width: 72px;
		height: 48px;
	}
	.cli-action {
		width: 100%;
		margin-top: 4px;
	}
	.btn-cli {
		width: 100%;
		text-align: center;
		justify-content: center;
	}
}

/* ==========================================================================
   Internal Simple Footer
   ========================================================================== */
.site-footer.internal-simple-footer {
	background: #f8fafc !important;
	color: #64748b !important;
	padding: 24px 16px !important;
	margin-top: 48px !important;
	border-top: 1px solid #e2e8f0 !important;
}

.footer-simple-inner {
	display: flex;
	align-items: center;
	justify-content: space-between;
	flex-wrap: wrap;
	gap: 16px;
	font-size: 14px;
	color: #64748b;
}

.footer-simple-copy {
	color: #64748b;
}

.footer-simple-copy a {
	color: #0284c7 !important;
	text-decoration: none;
	font-weight: 500;
	transition: color 0.15s ease;
}

.footer-simple-copy a:hover {
	text-decoration: underline !important;
	color: #0369a1 !important;
}

.footer-simple-links a {
	color: #64748b !important;
	text-decoration: none;
	font-size: 14px;
	transition: color 0.15s ease;
}

.footer-simple-links a:hover {
	color: #0f172a !important;
	text-decoration: underline !important;
}

@media (max-width: 640px) {
	.footer-simple-inner {
		flex-direction: column;
		text-align: center;
		justify-content: center;
		gap: 10px;
	}
}


/* ==========================================================================
   Bootstrap Icons & Alignment Harmonization
   ========================================================================== */
.me-1 { margin-right: 4px !important; }
.me-2 { margin-right: 8px !important; }
.ms-1 { margin-left: 4px !important; }
.ms-2 { margin-left: 8px !important; }

/* Base icon sizing & vertical alignment */
i.bi {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	vertical-align: -0.125em;
	line-height: 1;
}

/* Specific button icons */
.btn i.bi {
	vertical-align: -0.08em;
	transition: transform 0.15s ease;
}

.btn-primary:hover i.bi-arrow-right,
.btn-cli:hover i.bi-arrow-right,
.btn-next-action:hover i.bi-arrow-right,
.btn-complete-action:hover i.bi-arrow-right {
	transform: translateX(3px);
}

.btn-nav-prev:hover i.bi-arrow-left,
.topbar-back-link:hover i.bi-arrow-left,
.back-link:hover i.bi-arrow-left {
	transform: translateX(-3px);
}

.cli-thumb-placeholder i.bi {
	font-size: 28px;
	color: #94a3b8;
}

.cli-meta-item i.bi {
	font-size: 14px;
	color: #64748b;
}

.cli-badge-enrolled i.bi {
	font-size: 13px;
	margin-right: 3px;
}

.lms-modal-icon i.bi {
	font-size: 38px;
	color: var(--brand, #2563eb);
}


/* ==========================================================================
   Dashboard Modernization & Quiz Results Integration
   ========================================================================== */
.dash-welcome h1 {
	font-size: 26px;
	font-weight: 800;
	color: #0f172a;
	margin: 0 0 6px;
}
.dash-welcome .user-highlight {
	color: var(--brand, #2563eb);
}
.dash-badge-student {
	display: inline-flex;
	align-items: center;
	background: #ecfdf5;
	color: #047857;
	border: 1px solid #a7f3d0;
	font-size: 12px;
	font-weight: 700;
	padding: 3px 10px;
	border-radius: 999px;
	margin-bottom: 8px;
}

/* Main Nav Tabs */
.dash-main-nav {
	display: flex;
	gap: 12px;
	margin-bottom: 24px;
	border-bottom: 2px solid #e2e8f0;
	padding-bottom: 12px;
	flex-wrap: wrap;
}
.dash-nav-tab {
	display: inline-flex;
	align-items: center;
	padding: 10px 22px;
	border: 1px solid transparent;
	background: #f1f5f9;
	color: #64748b;
	font-size: 14.5px;
	font-weight: 700;
	border-radius: 10px;
	cursor: pointer;
	transition: all 0.2s ease;
}
.dash-nav-tab:hover {
	background: #e2e8f0;
	color: #0f172a;
}
.dash-nav-tab.active {
	background: var(--brand, #2563eb);
	color: #ffffff;
	box-shadow: 0 4px 12px rgba(37, 99, 235, 0.25);
}

/* Sub Filters */
.dash-sub-filters {
	display: flex;
	gap: 8px;
	margin-bottom: 20px;
}
.dash-sub-tab {
	padding: 6px 16px;
	border: 1px solid #e2e8f0;
	background: #ffffff;
	color: #64748b;
	font-size: 13px;
	font-weight: 600;
	border-radius: 8px;
	cursor: pointer;
	transition: all 0.15s ease;
}
.dash-sub-tab:hover {
	border-color: #cbd5e1;
	color: #0f172a;
}
.dash-sub-tab.active {
	background: #0f172a;
	border-color: #0f172a;
	color: #ffffff;
}

/* Courses Simple List View */
.dash-courses-list {
	display: flex;
	flex-direction: column;
	gap: 12px;
}
.dash-course-row {
	background: #ffffff;
	border: 1px solid #e2e8f0;
	border-radius: 12px;
	padding: 14px 18px;
	display: flex;
	align-items: center;
	gap: 18px;
	transition: all 0.15s ease;
	box-shadow: 0 1px 3px rgba(15, 23, 42, 0.02);
}
.dash-course-row:hover {
	border-color: #cbd5e1;
	box-shadow: 0 4px 16px rgba(15, 23, 42, 0.06);
	transform: translateY(-1px);
}
.dcr-thumb {
	width: 96px;
	height: 60px;
	border-radius: 8px;
	overflow: hidden;
	background: #f1f5f9;
	flex-shrink: 0;
	display: block;
}
.dcr-thumb img,
.dcr-img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}
.dcr-placeholder {
	width: 100%;
	height: 100%;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 24px;
	color: #94a3b8;
}
.dcr-main {
	flex: 1;
	min-width: 0;
}
.dcr-title {
	font-size: 15px;
	font-weight: 700;
	margin: 0 0 6px;
	line-height: 1.35;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}
.dcr-title a {
	color: #0f172a;
	text-decoration: none;
	transition: color 0.15s;
}
.dcr-title a:hover {
	color: var(--brand, #2563eb);
}
.dcr-progress-wrap {
	display: flex;
	align-items: center;
	gap: 14px;
	max-width: 360px;
}
.dcr-progress-bar {
	flex: 1;
	height: 6px;
	background: #f1f5f9;
	border-radius: 999px;
	overflow: hidden;
}
.dcr-progress-fill {
	height: 100%;
	background: var(--brand, #2563eb);
	border-radius: 999px;
}
.dcr-progress-meta {
	font-size: 12.5px;
	color: #64748b;
	white-space: nowrap;
	display: flex;
	align-items: center;
	gap: 8px;
}
.dcr-action {
	flex-shrink: 0;
}
.dcr-action .btn {
	white-space: nowrap;
	padding: 7px 16px;
	font-size: 13px;
	font-weight: 600;
}
@media (max-width: 640px) {
	.dash-course-row {
		flex-direction: column;
		align-items: stretch;
		gap: 12px;
	}
	.dcr-thumb {
		width: 100%;
		height: 120px;
	}
	.dcr-title {
		white-space: normal;
	}
	.dcr-progress-wrap {
		max-width: 100%;
	}
	.dcr-action .btn {
		width: 100%;
		justify-content: center;
	}
}

/* Courses Grid */
.dash-courses-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
	gap: 20px;
}
.dash-course-card {
	background: #ffffff;
	border: 1px solid #e2e8f0;
	border-radius: 14px;
	overflow: hidden;
	box-shadow: 0 1px 3px rgba(15, 23, 42, 0.04);
	transition: all 0.2s ease;
	display: flex;
	flex-direction: column;
}
.dash-course-card:hover {
	transform: translateY(-2px);
	border-color: #cbd5e1;
	box-shadow: 0 8px 24px rgba(15, 23, 42, 0.08);
}
.dcc-thumb-link {
	display: block;
	aspect-ratio: 16/9;
	background: #f1f5f9;
	overflow: hidden;
}
.dcc-thumb-link img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
	transition: transform 0.3s ease;
}
.dash-course-card:hover .dcc-thumb-link img {
	transform: scale(1.03);
}
.dcc-placeholder {
	width: 100%;
	height: 100%;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 36px;
	color: #94a3b8;
}
.dcc-body {
	padding: 18px 20px 20px;
	display: flex;
	flex-direction: column;
	flex: 1;
}
.dcc-title {
	font-size: 16px;
	font-weight: 700;
	color: #0f172a;
	margin: 0 0 14px;
	line-height: 1.4;
	min-height: 44px;
}
.dcc-title a {
	color: inherit;
	text-decoration: none;
	transition: color 0.15s ease;
}
.dcc-title a:hover {
	color: var(--brand, #2563eb);
}
.dcc-progress-wrap {
	margin-top: auto;
	margin-bottom: 14px;
}
.dcc-progress-bar {
	height: 6px;
	background: #f1f5f9;
	border-radius: 999px;
	overflow: hidden;
	margin-bottom: 6px;
}
.dcc-progress-fill {
	height: 100%;
	background: var(--brand, #2563eb);
	border-radius: 999px;
}
.dcc-progress-meta {
	display: flex;
	justify-content: space-between;
	font-size: 12.5px;
	color: #64748b;
}
.text-done { color: #059669 !important; font-weight: 700; }
.text-learning { color: var(--brand, #2563eb) !important; font-weight: 600; }
.text-fail { color: #dc2626 !important; font-weight: 700; }

/* Empty state */
.dash-empty-card {
	background: #ffffff;
	border: 1px solid #e2e8f0;
	border-radius: 14px;
	padding: 56px 24px;
	text-align: center;
}
.dash-empty-card .empty-icon {
	font-size: 44px;
	color: #94a3b8;
	margin-bottom: 12px;
}

/* Quiz Dash Stats Grid */
.quiz-dash-stats-grid {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
	gap: 16px;
	margin-bottom: 24px;
}
.qd-stat-card {
	background: #ffffff;
	border: 1px solid #e2e8f0;
	border-radius: 14px;
	padding: 18px 20px;
	display: flex;
	align-items: center;
	gap: 16px;
	box-shadow: 0 1px 3px rgba(15, 23, 42, 0.03);
}
.qd-stat-icon {
	width: 46px;
	height: 46px;
	border-radius: 12px;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 22px;
	flex-shrink: 0;
}
.qd-stat-icon.icon-total { background: #eff6ff; color: #2563eb; }
.qd-stat-icon.icon-pass  { background: #ecfdf5; color: #059669; }
.qd-stat-icon.icon-avg   { background: #faf5ff; color: #7c3aed; }
.qd-stat-icon.icon-rate  { background: #fff7ed; color: #ea580c; }

.qd-stat-info strong {
	display: block;
	font-size: 20px;
	font-weight: 800;
	color: #0f172a;
	line-height: 1.2;
}
.qd-stat-info span {
	font-size: 13px;
	color: #64748b;
}

/* Quiz Results Card */
.quiz-results-card {
	background: #ffffff;
	border: 1px solid #e2e8f0;
	border-radius: 14px;
	overflow: hidden;
	box-shadow: 0 1px 4px rgba(15, 23, 42, 0.04);
}
.qrc-header {
	padding: 20px 24px;
	border-bottom: 1px solid #e2e8f0;
	display: flex;
	align-items: center;
	justify-content: space-between;
	flex-wrap: wrap;
	gap: 14px;
}
.qrc-title-row {
	display: flex;
	align-items: center;
	gap: 12px;
}
.qrc-title-row h2 {
	font-size: 18px;
	font-weight: 700;
	color: #0f172a;
	margin: 0;
}
.qrc-count {
	font-size: 12.5px;
	color: #64748b;
	background: #f1f5f9;
	padding: 3px 10px;
	border-radius: 999px;
	font-weight: 600;
}
.qrc-filter-tabs {
	display: flex;
	gap: 6px;
}
.qrc-filter-btn {
	padding: 5px 14px;
	border: 1px solid #e2e8f0;
	background: #ffffff;
	color: #64748b;
	font-size: 13px;
	font-weight: 600;
	border-radius: 7px;
	cursor: pointer;
	transition: all 0.15s ease;
}
.qrc-filter-btn:hover {
	border-color: #cbd5e1;
	color: #0f172a;
}
.qrc-filter-btn.active {
	background: #0f172a;
	border-color: #0f172a;
	color: #ffffff;
}

/* Quiz History Table */
.quiz-history-table {
	width: 100%;
	border-collapse: collapse;
	font-size: 14px;
}
.quiz-history-table th {
	background: #f8fafc;
	color: #475569;
	font-weight: 700;
	font-size: 13px;
	text-transform: uppercase;
	letter-spacing: 0.04em;
	padding: 12px 20px;
	border-bottom: 1px solid #e2e8f0;
	text-align: left;
}
.quiz-history-table td {
	padding: 14px 20px;
	border-bottom: 1px solid #f1f5f9;
	color: #1e293b;
	vertical-align: middle;
}
.quiz-history-table tr:hover td {
	background: #f8fafc;
}
.qr-title strong {
	display: block;
	color: #0f172a;
	font-weight: 700;
}
.qr-lesson-sub {
	display: block;
	color: #64748b;
	font-size: 12px;
	margin-top: 3px;
}
.qr-course-badge {
	display: inline-block;
	background: #f1f5f9;
	color: #475569;
	font-size: 12px;
	font-weight: 600;
	padding: 3px 8px;
	border-radius: 6px;
}
.qr-score-val strong {
	font-size: 15px;
	color: #0f172a;
}
.qr-time {
	font-size: 13px;
	color: #64748b;
}

.badge-status-pill {
	display: inline-flex;
	align-items: center;
	font-size: 12px;
	font-weight: 700;
	padding: 3px 10px;
	border-radius: 999px;
}
.badge-status-pill.pass {
	background: #ecfdf5;
	color: #059669;
	border: 1px solid #a7f3d0;
}
.badge-status-pill.fail {
	background: #fef2f2;
	color: #dc2626;
	border: 1px solid #fecaca;
}

.qr-actions-cell {
	display: inline-flex;
	align-items: center;
	gap: 6px;
}
.btn-retake-quiz-action {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	white-space: nowrap;
	font-weight: 600;
	padding: 6px 14px;
	border-radius: 8px;
	font-size: 13px;
}

/* Quiz Modal */
.quiz-modal-dialog {
	max-width: 780px !important;
	width: 95% !important;
	max-height: 85vh !important;
	display: flex;
	flex-direction: column;
	overflow: hidden;
}
.quiz-modal-header {
	padding: 20px 24px;
	border-bottom: 1px solid #e2e8f0;
	background: #f8fafc;
	flex-shrink: 0;
}
.qmh-info-row {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
}
.qmh-title {
	font-size: 18px;
	font-weight: 800;
	color: #0f172a;
	margin: 6px 0 2px;
}
.qmh-score-box {
	text-align: right;
	padding: 8px 16px;
	border-radius: 10px;
	border: 1px solid;
}
.qmh-score-box.pass { background: #ecfdf5; border-color: #a7f3d0; color: #065f46; }
.qmh-score-box.fail { background: #fef2f2; border-color: #fecaca; color: #991b1b; }
.qmh-score-num { font-size: 22px; font-weight: 800; display: block; line-height: 1; }
.qmh-score-sub { font-size: 12px; font-weight: 600; opacity: 0.85; }

.quiz-modal-body {
	padding: 24px;
	overflow-y: auto;
	flex: 1;
}

@media (max-width: 768px) {
	.dash-head {
		flex-direction: column;
		align-items: flex-start;
		gap: 20px;
	}
	.dash-stats {
		width: 100%;
		display: grid;
		grid-template-columns: repeat(2, 1fr);
		gap: 10px;
	}
	.dash-stat-item {
		width: auto !important;
	}
	.qrc-header {
		flex-direction: column;
		align-items: flex-start;
	}
	.quiz-history-table th:nth-child(2),
	.quiz-history-table td:nth-child(2),
	.quiz-history-table th:nth-child(6),
	.quiz-history-table td:nth-child(6) {
		display: none;
	}
}

/* ==========================================================================
   Trang Chính sách & Quyền riêng tư (Privacy Policy Page)
   ========================================================================== */
.policy-page-wrapper {
	font-size: 15px;
	color: #334155;
	line-height: 1.75;
}

.policy-summary-grid {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 16px;
	margin-bottom: 28px;
}

.policy-summary-item {
	background: #ffffff;
	border: 1px solid #e2e8f0;
	border-radius: 14px;
	padding: 20px;
	box-shadow: 0 2px 8px rgba(15, 23, 42, 0.04);
	display: flex;
	flex-direction: column;
	gap: 8px;
	transition: transform 0.2s, box-shadow 0.2s;
}
.policy-summary-item:hover {
	transform: translateY(-2px);
	box-shadow: 0 6px 16px rgba(15, 23, 42, 0.08);
}
.policy-summary-icon {
	width: 42px;
	height: 42px;
	border-radius: 10px;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 20px;
	margin-bottom: 4px;
}
.policy-summary-icon.blue { background: #eff6ff; color: #2563eb; }
.policy-summary-icon.green { background: #ecfdf5; color: #059669; }
.policy-summary-icon.purple { background: #f5f3ff; color: #7c3aed; }

.policy-summary-title {
	font-size: 16px;
	font-weight: 700;
	color: #0f172a;
	margin: 0;
}
.policy-summary-desc {
	font-size: 13.5px;
	color: #64748b;
	line-height: 1.55;
	margin: 0;
}

.policy-card {
	background: #ffffff;
	border: 1px solid #e2e8f0;
	border-radius: 16px;
	padding: 28px 32px;
	margin-bottom: 24px;
	box-shadow: 0 2px 12px rgba(15, 23, 42, 0.04);
}

.policy-header-row {
	display: flex;
	align-items: center;
	gap: 14px;
	margin-bottom: 18px;
	padding-bottom: 14px;
	border-bottom: 1px solid #f1f5f9;
}
.policy-num-badge {
	width: 38px;
	height: 38px;
	border-radius: 10px;
	background: #eff6ff;
	color: #2563eb;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 16px;
	font-weight: 700;
	flex-shrink: 0;
}
.policy-header-title {
	font-size: 18px;
	font-weight: 700;
	color: #0f172a;
	margin: 0;
	line-height: 1.4;
}

.policy-list-clean {
	list-style: none;
	padding-left: 0;
	margin: 12px 0;
}
.policy-list-clean li {
	position: relative;
	padding-left: 26px;
	margin-bottom: 10px;
	line-height: 1.65;
}
.policy-list-clean li::before {
	content: "\F272";
	font-family: "bootstrap-icons";
	position: absolute;
	left: 0;
	top: 0;
	color: #2563eb;
	font-size: 15px;
}

.policy-callout {
	border-radius: 12px;
	padding: 16px 20px;
	margin: 18px 0;
	display: flex;
	gap: 14px;
	align-items: flex-start;
}
.policy-callout.blue {
	background: #eff6ff;
	border: 1px solid #bfdbfe;
	color: #1e40af;
}
.policy-callout.amber {
	background: #fffbeb;
	border: 1px solid #fde68a;
	color: #92400e;
}
.policy-callout i {
	font-size: 20px;
	flex-shrink: 0;
	line-height: 1.4;
}
.policy-callout-text {
	font-size: 14px;
	line-height: 1.6;
}

.policy-contact-box {
	background: #f8fafc;
	border: 1px solid #e2e8f0;
	border-radius: 14px;
	padding: 22px 24px;
	margin-top: 16px;
}
.policy-contact-grid {
	display: grid;
	grid-template-columns: repeat(2, 1fr);
	gap: 16px;
	margin-top: 14px;
}
.policy-contact-item {
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 10px 14px;
	background: #ffffff;
	border: 1px solid #e2e8f0;
	border-radius: 10px;
}
.policy-contact-item i {
	font-size: 18px;
	color: #2563eb;
}
.policy-contact-item a {
	color: #0f172a;
	font-weight: 600;
	text-decoration: none;
	font-size: 14px;
	word-break: break-all;
}
.policy-contact-item a:hover {
	color: #2563eb;
	text-decoration: underline;
}

.policy-footer-note {
	text-align: center;
	padding: 24px;
	color: #64748b;
	font-size: 13.5px;
}

@media (max-width: 768px) {
	.policy-summary-grid {
		grid-template-columns: 1fr;
	}
	.policy-card {
		padding: 20px 18px;
	}
	.policy-header-title {
		font-size: 16.5px;
	}
	.policy-contact-grid {
		grid-template-columns: 1fr;
	}
}

