:root {
  --primary: #6d28d9;
  --primary-2: #8b5cf6;
  --primary-dark: #4c1d95;
  --accent: #ff7a45;
  --green: #16a34a;
  --red: #dc2626;
  --amber: #f59e0b;
  --blue: #2563eb;
  --ink: #1f1235;
  --muted: #6b6480;
  --line: #ebe7f3;
  --bg: #f7f5fc;
  --card: #ffffff;
  --radius: 14px;
  --shadow: 0 6px 24px rgba(76, 29, 149, .08);
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; font-family: 'Poppins', system-ui, sans-serif; color: var(--ink); background: var(--bg); line-height: 1.55; font-size: 15px; }
a { color: var(--primary); text-decoration: none; }
img { max-width: 100%; }
h1, h2, h3, h4 { line-height: 1.25; margin: 0 0 .5em; }
.container { width: 100%; max-width: 1200px; margin: 0 auto; padding: 0 16px; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.center { text-align: center; }
.mt { margin-top: 24px; } .mb { margin-bottom: 24px; }
.flex { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.between { justify-content: space-between; }
.grow { flex: 1; }

/* ---------- buttons ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; padding: 10px 20px; border-radius: 10px; border: 2px solid transparent;
  font: 600 14px 'Poppins', sans-serif; cursor: pointer; transition: .15s; white-space: nowrap; background: #eee; color: var(--ink); }
.btn-primary { background: linear-gradient(135deg, var(--primary), var(--primary-2)); color: #fff; box-shadow: 0 4px 14px rgba(109, 40, 217, .35); }
.btn-primary:hover { transform: translateY(-1px); box-shadow: 0 8px 20px rgba(109, 40, 217, .4); }
.btn-accent { background: var(--accent); color: #fff; }
.btn-ghost { background: transparent; border-color: var(--primary); color: var(--primary); }
.btn-ghost:hover { background: var(--primary); color: #fff; }
.btn-light { background: #fff; color: var(--primary); }
.btn-green { background: var(--green); color: #fff; }
.btn-red { background: var(--red); color: #fff; }
.btn-sm { padding: 6px 12px; font-size: 13px; border-radius: 8px; }
.btn-lg { padding: 14px 28px; font-size: 16px; }
.btn-block { width: 100%; }
.btn[disabled] { opacity: .5; cursor: not-allowed; }

/* ---------- header ---------- */
.topbar { background: #fff; border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 50; }
.nav { display: flex; align-items: center; height: 68px; gap: 20px; }
.logo { display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 20px; color: var(--primary-dark); }
.logo small { display: block; font-size: 10px; font-weight: 500; color: var(--muted); letter-spacing: .5px; margin-top: -4px; }
.logo-mark { width: 38px; height: 38px; border-radius: 10px; display: grid; place-items: center; color: #fff; font-size: 20px;
  background: linear-gradient(135deg, var(--primary), var(--accent)); }
.logo.light { color: #fff; } .logo.light small { color: #cbbcf0; }
.menu { display: flex; align-items: center; gap: 18px; margin-left: auto; }
.menu > a, .dropdown > a { color: var(--ink); font-weight: 500; font-size: 14px; padding: 6px 0; }
.menu > a.active, .menu > a:hover, .dropdown > a.active { color: var(--primary); }
.menu .btn { padding: 8px 16px; }
.menu .btn-primary { color: #fff; }
.nav-search input { border: 1px solid var(--line); background: var(--bg); border-radius: 30px; padding: 8px 14px; width: 170px; font: inherit; font-size: 13px; }
.burger { display: none; margin-left: auto; background: none; border: 0; font-size: 26px; cursor: pointer; color: var(--primary); }
.dropdown { position: relative; }
.dropdown-menu { display: none; position: absolute; top: 100%; left: 0; background: #fff; min-width: 220px; border-radius: 12px; box-shadow: 0 14px 40px rgba(0,0,0,.12);
  padding: 8px; border: 1px solid var(--line); }
.dropdown-menu.right { left: auto; right: 0; }
.dropdown-menu a { display: block; padding: 9px 12px; border-radius: 8px; color: var(--ink); font-size: 14px; }
.dropdown-menu a:hover { background: var(--bg); color: var(--primary); }
.dropdown:hover .dropdown-menu, .dropdown:focus-within .dropdown-menu { display: block; }
.dropdown-menu.mega { min-width: 280px; }
.dm-head { padding: 8px 12px 10px; border-bottom: 1px solid var(--line); margin-bottom: 6px; }
.dm-head small { display: block; color: var(--muted); }
.avatar { width: 36px; height: 36px; border-radius: 50%; background: linear-gradient(135deg, var(--primary), var(--primary-2)); color: #fff;
  display: grid; place-items: center; font-weight: 600; font-size: 14px; }
.avatar.lg { width: 72px; height: 72px; font-size: 26px; }
.bell { position: relative; font-size: 18px; }
.bell b { position: absolute; top: -4px; right: -8px; background: var(--red); color: #fff; font-size: 10px; border-radius: 10px; padding: 1px 5px; }

/* ---------- alerts / badges ---------- */
.flash-wrap { padding-top: 16px; }
.alert { padding: 12px 16px; border-radius: 10px; margin-bottom: 10px; font-size: 14px; }
.alert-success { background: #dcfce7; color: #166534; }
.alert-error { background: #fee2e2; color: #991b1b; }
.alert-info { background: #ede9fe; color: #4c1d95; }
.alert-warning { background: #fef3c7; color: #92400e; }
.badge { display: inline-block; padding: 3px 10px; border-radius: 20px; font-size: 12px; font-weight: 600; background: #ede9fe; color: var(--primary); }
.badge.green { background: #dcfce7; color: #166534; } .badge.red { background: #fee2e2; color: #991b1b; }
.badge.amber { background: #fef3c7; color: #92400e; } .badge.blue { background: #dbeafe; color: #1e40af; }
.badge.gray { background: #f1f5f9; color: #475569; }

/* ---------- hero ---------- */
.hero { background: radial-gradient(circle at 85% 20%, #a78bfa 0, transparent 40%), linear-gradient(135deg, #4c1d95 0%, #6d28d9 55%, #8b5cf6 100%);
  color: #fff; padding: 70px 0 90px; position: relative; overflow: hidden; }
.hero::after { content: ''; position: absolute; bottom: -1px; left: 0; right: 0; height: 60px; background: var(--bg); clip-path: ellipse(60% 100% at 50% 100%); }
.hero-grid { display: grid; grid-template-columns: 1.1fr .9fr; gap: 40px; align-items: center; }
.hero h1 { font-size: 46px; font-weight: 700; }
.hero h1 span { color: #fde68a; }
.hero p { font-size: 17px; color: #e9e2ff; max-width: 540px; }
.hero-cta { display: flex; gap: 12px; margin-top: 26px; flex-wrap: wrap; }
.hero-card { background: rgba(255,255,255,.12); border: 1px solid rgba(255,255,255,.25); border-radius: 22px; padding: 26px; backdrop-filter: blur(6px); }
.hero-card h3 { margin-bottom: 14px; }
.hero-card select, .hero-card input { width: 100%; margin-bottom: 12px; }
.hero-stats { display: flex; gap: 30px; margin-top: 34px; flex-wrap: wrap; }
.hero-stats b { display: block; font-size: 26px; }
.hero-stats span { font-size: 13px; color: #d8ccff; }

/* ---------- sections ---------- */
.section { padding: 60px 0; }
.section-head { text-align: center; margin-bottom: 36px; }
.section-head h2 { font-size: 32px; }
.section-head p { color: var(--muted); max-width: 640px; margin: 0 auto; }
.page-head { background: linear-gradient(135deg, var(--primary-dark), var(--primary)); color: #fff; padding: 40px 0; }
.page-head p { color: #e2d8ff; margin: 0; }
.page-head a { color: #fde68a; }

/* ---------- cards ---------- */
.card { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); padding: 22px; border: 1px solid var(--line); }
.grid { display: grid; gap: 22px; }
.g2 { grid-template-columns: repeat(2, 1fr); } .g3 { grid-template-columns: repeat(3, 1fr); } .g4 { grid-template-columns: repeat(4, 1fr); }
.cat-card { display: flex; flex-direction: column; gap: 8px; padding: 24px; border-radius: 18px; background: #fff; border: 1px solid var(--line); color: var(--ink);
  transition: .2s; position: relative; overflow: hidden; }
.cat-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.cat-card .ic { width: 54px; height: 54px; border-radius: 14px; display: grid; place-items: center; font-size: 28px; }
.cat-card h3 { margin: 6px 0 0; font-size: 18px; }
.cat-card p { color: var(--muted); font-size: 13px; margin: 0; }
.cat-card .go { font-weight: 600; font-size: 14px; margin-top: auto; }

.course-card { background: #fff; border-radius: 16px; overflow: hidden; border: 1px solid var(--line); display: flex; flex-direction: column; transition: .2s; color: var(--ink); }
.course-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.course-thumb { height: 140px; padding: 18px; color: #fff; display: flex; flex-direction: column; justify-content: space-between; position: relative; }
.course-thumb::after { content: ''; position: absolute; right: -30px; bottom: -40px; width: 140px; height: 140px; border-radius: 50%; background: rgba(255,255,255,.15); }
.course-thumb h3 { font-size: 17px; margin: 0; position: relative; z-index: 1; }
.course-body { padding: 16px 18px; display: flex; flex-direction: column; gap: 6px; flex: 1; }
.course-body .meta { font-size: 13px; color: var(--muted); }
.price { display: flex; align-items: baseline; gap: 8px; margin-top: auto; padding-top: 10px; }
.price b { font-size: 20px; color: var(--primary-dark); }
.price s { color: var(--muted); font-size: 13px; }
.price .off { color: var(--green); font-size: 13px; font-weight: 600; }
.stars { color: #f59e0b; font-size: 13px; }

.feature { text-align: center; padding: 28px 20px; }
.feature .ic { font-size: 40px; margin-bottom: 10px; }
.feature h3 { font-size: 17px; }
.feature p { color: var(--muted); font-size: 14px; margin: 0; }

.stat-band { background: #fff; border-radius: 22px; box-shadow: var(--shadow); display: grid; grid-template-columns: repeat(4, 1fr); padding: 30px; margin-top: -50px; position: relative; z-index: 2; }
.stat-band div { text-align: center; border-right: 1px solid var(--line); }
.stat-band div:last-child { border: 0; }
.stat-band b { display: block; font-size: 30px; color: var(--primary); }
.stat-band span { color: var(--muted); font-size: 14px; }

.testimonial { background: #fff; border-radius: 18px; padding: 24px; border: 1px solid var(--line); }
.testimonial p { font-style: italic; color: #3f3557; }
.testimonial .who { display: flex; gap: 12px; align-items: center; margin-top: 14px; }
.testimonial .who small { display: block; color: var(--green); font-weight: 600; }

.cta-band { background: linear-gradient(135deg, var(--accent), #ff4d6d); color: #fff; border-radius: 24px; padding: 40px; display: flex; align-items: center; justify-content: space-between; gap: 20px; flex-wrap: wrap; }
.cta-band h2 { margin: 0; }

/* ---------- forms ---------- */
label { display: block; font-weight: 500; font-size: 14px; margin-bottom: 6px; }
input[type=text], input[type=email], input[type=password], input[type=number], input[type=tel], input[type=url], input[type=datetime-local], input[type=date], input[type=search], select, textarea {
  width: 100%; padding: 11px 14px; border: 1.5px solid var(--line); border-radius: 10px; font: inherit; font-size: 14px; background: #fff; color: var(--ink); }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--primary-2); box-shadow: 0 0 0 3px rgba(139, 92, 246, .15); }
textarea { min-height: 110px; resize: vertical; }
.form-row { margin-bottom: 16px; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0 16px; }
.auth-wrap { min-height: calc(100vh - 68px); display: grid; grid-template-columns: 1fr 1fr; }
.auth-side { background: linear-gradient(135deg, var(--primary-dark), var(--primary-2)); color: #fff; padding: 60px; display: flex; flex-direction: column; justify-content: center; }
.auth-side ul { padding-left: 18px; line-height: 2; }
.auth-form { display: flex; align-items: center; justify-content: center; padding: 40px 16px; }
.auth-form .card { width: 100%; max-width: 420px; }

/* ---------- course detail ---------- */
.course-hero { color: #fff; padding: 46px 0; }
.course-layout { display: grid; grid-template-columns: 1fr 360px; gap: 28px; align-items: start; }
.buy-box { position: sticky; top: 88px; margin-top: -120px; }
.buy-box .price b { font-size: 30px; }
.buy-box ul { padding-left: 0; list-style: none; font-size: 14px; }
.buy-box li { padding: 6px 0; }
.tabs { display: flex; gap: 6px; border-bottom: 2px solid var(--line); margin-bottom: 20px; overflow-x: auto; }
.tabs a, .tabs button { padding: 10px 18px; font-weight: 600; color: var(--muted); border: 0; background: none; cursor: pointer; font: 600 14px 'Poppins'; border-bottom: 3px solid transparent; margin-bottom: -2px; white-space: nowrap; }
.tabs .active { color: var(--primary); border-color: var(--primary); }
.acc { border: 1px solid var(--line); border-radius: 12px; margin-bottom: 10px; background: #fff; overflow: hidden; }
.acc summary { padding: 14px 18px; cursor: pointer; font-weight: 600; display: flex; justify-content: space-between; list-style: none; }
.acc summary::-webkit-details-marker { display: none; }
.acc summary::after { content: '+'; color: var(--primary); font-size: 20px; line-height: 1; }
.acc[open] summary::after { content: '−'; }
.acc .acc-body { padding: 0 18px 12px; }
.lesson-row { display: flex; align-items: center; gap: 10px; padding: 10px 0; border-top: 1px dashed var(--line); font-size: 14px; }
.lesson-row .t { flex: 1; }
.lesson-row.done .t { color: var(--green); }
.subject-title { font-size: 18px; margin: 24px 0 10px; color: var(--primary-dark); }

/* ---------- lesson player ---------- */
.player-layout { display: grid; grid-template-columns: 1fr 340px; gap: 0; min-height: calc(100vh - 68px); }
.player-main { padding: 24px; }
.player { position: relative; padding-top: 56.25%; background: #000; border-radius: 14px; overflow: hidden; }
.player iframe, .player video { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.player-side { background: #fff; border-left: 1px solid var(--line); max-height: calc(100vh - 68px); overflow-y: auto; position: sticky; top: 68px; }
.player-side h4 { padding: 16px; margin: 0; border-bottom: 1px solid var(--line); }
.side-lesson { display: flex; gap: 10px; padding: 10px 16px; font-size: 13px; color: var(--ink); border-bottom: 1px solid #f4f1fa; }
.side-lesson.current { background: #f3edff; border-left: 3px solid var(--primary); }
.side-chapter { padding: 10px 16px; font-weight: 600; font-size: 13px; background: var(--bg); color: var(--primary-dark); }
.notes { background: #fff; padding: 24px; border-radius: 14px; border: 1px solid var(--line); }
.notes blockquote { border-left: 4px solid var(--primary-2); margin: 10px 0; padding: 8px 14px; background: #f5f0ff; border-radius: 0 8px 8px 0; }

/* ---------- tables ---------- */
.table-wrap { overflow-x: auto; }
table.table { width: 100%; border-collapse: collapse; background: #fff; font-size: 14px; }
.table th, .table td { padding: 12px 14px; text-align: left; border-bottom: 1px solid var(--line); vertical-align: middle; }
.table th { background: #faf8ff; font-weight: 600; color: var(--muted); font-size: 12px; text-transform: uppercase; letter-spacing: .4px; }
.table tr:hover td { background: #fcfbff; }

/* ---------- dashboard ---------- */
.dash-grid { display: grid; grid-template-columns: 250px 1fr; gap: 24px; padding: 28px 16px; }
.side-nav { background: #fff; border-radius: var(--radius); padding: 14px; border: 1px solid var(--line); height: fit-content; position: sticky; top: 88px; }
.side-nav a { display: flex; gap: 10px; padding: 10px 12px; border-radius: 10px; color: var(--ink); font-size: 14px; }
.side-nav a.active, .side-nav a:hover { background: #f3edff; color: var(--primary); }
.kpi { display: flex; gap: 14px; align-items: center; }
.kpi .ic { width: 50px; height: 50px; border-radius: 12px; display: grid; place-items: center; font-size: 22px; background: #f3edff; }
.kpi b { font-size: 24px; display: block; line-height: 1.1; }
.kpi span { color: var(--muted); font-size: 13px; }
.progress { height: 8px; background: #eee9f8; border-radius: 10px; overflow: hidden; }
.progress > span { display: block; height: 100%; background: linear-gradient(90deg, var(--primary), var(--primary-2)); border-radius: 10px; }
.welcome { background: linear-gradient(135deg, var(--primary), var(--primary-2)); color: #fff; border-radius: 18px; padding: 26px; display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 16px; }
.welcome p { color: #ece5ff; margin: 0; }
.streak { background: rgba(255,255,255,.18); padding: 10px 18px; border-radius: 14px; text-align: center; }
.streak b { font-size: 26px; display: block; }

/* ---------- tests list ---------- */
.test-card { display: flex; flex-direction: column; gap: 10px; }
.test-card .row { display: flex; gap: 16px; font-size: 13px; color: var(--muted); flex-wrap: wrap; }
.filters { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 20px; }
.chip { padding: 7px 16px; border-radius: 30px; background: #fff; border: 1px solid var(--line); color: var(--ink); font-size: 13px; font-weight: 500; }
.chip.active, .chip:hover { background: var(--primary); color: #fff; border-color: var(--primary); }

/* ---------- exam interface ---------- */
body.exam { background: #f3f4f8; }
body.exam .topbar, body.exam .footer { display: none; }
.exam-bar { background: var(--primary-dark); color: #fff; height: 60px; display: flex; align-items: center; padding: 0 20px; gap: 16px; position: sticky; top: 0; z-index: 30; }
.exam-bar h1 { font-size: 16px; margin: 0; flex: 1; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.timer { background: #fff; color: var(--primary-dark); padding: 8px 16px; border-radius: 10px; font-weight: 700; font-size: 18px; font-variant-numeric: tabular-nums; }
.timer.warn { background: #fee2e2; color: var(--red); animation: pulse 1s infinite; }
@keyframes pulse { 50% { opacity: .6; } }
.exam-layout { display: grid; grid-template-columns: 1fr 320px; min-height: calc(100vh - 60px); }
.exam-main { padding: 20px; display: flex; flex-direction: column; }
.section-tabs { display: flex; gap: 6px; margin-bottom: 14px; flex-wrap: wrap; }
.section-tabs button { padding: 8px 18px; border-radius: 8px; border: 1px solid var(--line); background: #fff; font: 600 13px 'Poppins'; cursor: pointer; }
.section-tabs button.active { background: var(--primary); color: #fff; border-color: var(--primary); }
.q-card { background: #fff; border-radius: 14px; padding: 26px; flex: 1; border: 1px solid var(--line); }
.q-head { display: flex; justify-content: space-between; border-bottom: 1px solid var(--line); padding-bottom: 12px; margin-bottom: 16px; font-size: 13px; color: var(--muted); flex-wrap: wrap; gap: 8px; }
.q-text { font-size: 17px; font-weight: 500; margin-bottom: 20px; white-space: pre-line; }
.opt { display: flex; gap: 12px; align-items: center; padding: 13px 16px; border: 2px solid var(--line); border-radius: 12px; margin-bottom: 10px; cursor: pointer; transition: .12s; font-size: 15px; }
.opt:hover { border-color: var(--primary-2); background: #faf7ff; }
.opt input { display: none; }
.opt .k { width: 30px; height: 30px; border-radius: 50%; border: 2px solid var(--line); display: grid; place-items: center; font-weight: 600; font-size: 13px; flex-shrink: 0; }
.opt.sel { border-color: var(--primary); background: #f3edff; }
.opt.sel .k { background: var(--primary); border-color: var(--primary); color: #fff; }
.opt.multi .k { border-radius: 6px; }
.numeric-input { max-width: 260px; font-size: 18px !important; }
.exam-actions { display: flex; gap: 10px; margin-top: 16px; flex-wrap: wrap; }
.exam-actions .spacer { flex: 1; }
.palette-side { background: #fff; border-left: 1px solid var(--line); padding: 18px; display: flex; flex-direction: column; gap: 14px; position: sticky; top: 60px; height: calc(100vh - 60px); overflow-y: auto; }
.palette-user { display: flex; gap: 10px; align-items: center; padding-bottom: 12px; border-bottom: 1px solid var(--line); }
.legend { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; font-size: 12px; }
.legend span { display: flex; align-items: center; gap: 6px; }
.pal-sec { font-weight: 600; font-size: 13px; color: var(--primary-dark); margin-top: 6px; }
.palette { display: grid; grid-template-columns: repeat(5, 1fr); gap: 8px; }
.pbtn { height: 40px; border-radius: 8px; border: 1px solid #d8d3e3; background: #fff; font: 600 13px 'Poppins'; cursor: pointer; position: relative; }
.pbtn.not-answered, .dot.not-answered { background: #fee2e2; border-color: #fca5a5; color: #991b1b; }
.pbtn.answered, .dot.answered { background: var(--green); border-color: var(--green); color: #fff; }
.pbtn.marked, .dot.marked { background: #7c3aed; border-color: #7c3aed; color: #fff; border-radius: 50%; }
.pbtn.answered-marked, .dot.answered-marked { background: #7c3aed; border-color: #7c3aed; color: #fff; border-radius: 50%; }
.pbtn.answered-marked::after, .dot.answered-marked::after { content: ''; position: absolute; right: 2px; bottom: 2px; width: 9px; height: 9px; border-radius: 50%; background: #22c55e; border: 1px solid #fff; }
.pbtn.current { outline: 3px solid var(--accent); outline-offset: 1px; }
.dot { width: 22px; height: 22px; border-radius: 5px; border: 1px solid #d8d3e3; display: inline-grid; place-items: center; font-size: 10px; position: relative; flex-shrink: 0; }
.modal-bg { position: fixed; inset: 0; background: rgba(20, 10, 40, .55); display: none; align-items: center; justify-content: center; z-index: 100; padding: 16px; }
.modal-bg.show { display: flex; }
.modal { background: #fff; border-radius: 18px; padding: 28px; max-width: 520px; width: 100%; }

/* ---------- results ---------- */
.score-hero { background: linear-gradient(135deg, var(--primary-dark), var(--primary-2)); color: #fff; border-radius: 22px; padding: 30px; display: grid; grid-template-columns: auto 1fr; gap: 30px; align-items: center; }
.score-ring { width: 150px; height: 150px; border-radius: 50%; display: grid; place-items: center; background: conic-gradient(#fde68a var(--p), rgba(255,255,255,.2) 0); }
.score-ring div { width: 118px; height: 118px; border-radius: 50%; background: var(--primary); display: grid; place-items: center; text-align: center; }
.score-ring b { font-size: 28px; display: block; line-height: 1; }
.score-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.score-stats div { background: rgba(255,255,255,.14); border-radius: 12px; padding: 14px; }
.score-stats b { display: block; font-size: 22px; }
.score-stats span { font-size: 12px; color: #e2d8ff; }
.sol { border: 1px solid var(--line); border-radius: 14px; padding: 20px; margin-bottom: 14px; background: #fff; }
.sol .opt { cursor: default; }
.sol .opt.right { border-color: var(--green); background: #f0fdf4; }
.sol .opt.right .k { background: var(--green); border-color: var(--green); color: #fff; }
.sol .opt.wrong { border-color: var(--red); background: #fef2f2; }
.sol .opt.wrong .k { background: var(--red); border-color: var(--red); color: #fff; }
.explain { background: #fffbeb; border: 1px solid #fde68a; border-radius: 10px; padding: 12px 16px; font-size: 14px; margin-top: 10px; }
.bar-row { display: grid; grid-template-columns: 110px 1fr 60px; gap: 10px; align-items: center; margin-bottom: 10px; font-size: 13px; }

/* ---------- live / doubts / misc ---------- */
.live-card { display: flex; gap: 16px; align-items: center; }
.live-date { min-width: 70px; text-align: center; background: #f3edff; border-radius: 12px; padding: 10px; color: var(--primary-dark); }
.live-date b { display: block; font-size: 24px; line-height: 1; }
.live-dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--red); margin-right: 4px; animation: pulse 1s infinite; }
.doubt { border-left: 4px solid var(--primary-2); }
.doubt .ans { background: #f0fdf4; border-radius: 10px; padding: 12px 16px; margin-top: 10px; font-size: 14px; }
.empty { text-align: center; padding: 50px 20px; color: var(--muted); }
.empty .ic { font-size: 48px; }
.pricing-card { text-align: center; }
.pricing-card.hot { border: 2px solid var(--primary); transform: scale(1.03); }

/* ---------- footer ---------- */
.footer { background: #1f1235; color: #c9c0dc; padding: 50px 0 20px; margin-top: 60px; font-size: 14px; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 30px; }
.footer h4 { color: #fff; }
.footer a { display: block; color: #c9c0dc; padding: 3px 0; }
.footer a:hover { color: #fff; }
.footer .logo { display: flex; }
.copy { border-top: 1px solid #3a2a5a; margin-top: 30px; padding-top: 18px; font-size: 13px; }

/* ---------- responsive ---------- */
@media (max-width: 1000px) {
  .g4 { grid-template-columns: repeat(2, 1fr); }
  .g3 { grid-template-columns: repeat(2, 1fr); }
  .hero-grid, .course-layout, .auth-wrap, .player-layout { grid-template-columns: 1fr; }
  .buy-box { position: static; margin-top: 0; }
  .auth-side { display: none; }
  .player-side { position: static; max-height: none; border-left: 0; }
  .dash-grid { grid-template-columns: 1fr; }
  .side-nav { position: static; display: flex; overflow-x: auto; gap: 4px; }
  .side-nav a { white-space: nowrap; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .exam-layout { grid-template-columns: 1fr; }
  .palette-side { position: static; height: auto; border-left: 0; border-top: 1px solid var(--line); }
}
@media (max-width: 860px) {
  .burger { display: block; }
  .menu { display: none; position: absolute; top: 68px; left: 0; right: 0; background: #fff; flex-direction: column; align-items: stretch; padding: 16px; gap: 6px; border-bottom: 1px solid var(--line); box-shadow: 0 10px 30px rgba(0,0,0,.08); }
  .nav-open .menu { display: flex; }
  .nav-search input { width: 100%; }
  .dropdown-menu { position: static; box-shadow: none; border: 0; display: block; padding: 0 0 0 10px; }
  .stat-band { grid-template-columns: 1fr 1fr; gap: 16px; }
  .stat-band div { border: 0; }
  .score-hero { grid-template-columns: 1fr; justify-items: center; }
  .score-stats { grid-template-columns: 1fr 1fr; width: 100%; }
}
@media (max-width: 600px) {
  .g2, .g3, .g4, .form-grid { grid-template-columns: 1fr; }
  .hero h1 { font-size: 32px; }
  .section-head h2 { font-size: 24px; }
  .footer-grid { grid-template-columns: 1fr; }
  .exam-bar h1 { font-size: 14px; }
}
.checkout-grid { grid-template-columns: 1.3fr 1fr; }
@media (max-width: 760px) { .checkout-grid { grid-template-columns: 1fr; } }
