:root {
  --ink:#1f2933; --muted:#667085; --line:#dde2e8; --bg:#f6f8fb; --card:#fff; --accent:#2563eb;
  --ok:#15803d; --ok-bg:#ecfdf3; --mid:#b45309; --mid-bg:#fffbeb; --bad:#b91c1c; --bad-bg:#fef2f2; --new:#475467; --new-bg:#f2f4f7;
}
* { box-sizing:border-box; }
body { margin:0; font:17px/1.55 system-ui, -apple-system, "Segoe UI", sans-serif; color:var(--ink); background:var(--bg); }
header { display:flex; align-items:center; gap:10px 14px; flex-wrap:wrap; padding:10px 16px; background:var(--card); border-bottom:1px solid var(--line); }
h1 { font-size:19px; margin:0; white-space:nowrap; } h1 small { font-weight:500; color:var(--muted); font-size:14px; }
h2 { font-size:20px; margin:0 0 8px; } h3 { font-size:17px; margin:16px 0 6px; }
nav { display:flex; gap:2px; flex:1 1 100%; order:5; overflow-x:auto; }
nav button { border:0; background:none; padding:8px 10px; font:inherit; font-size:16px; cursor:pointer; border-bottom:3px solid transparent; white-space:nowrap; }
nav button.active { border-color:var(--accent); font-weight:600; }
#user-area { margin-left:auto; display:flex; gap:8px; align-items:center; }
.kid-pick { font-size:14px; color:var(--muted); } .kid-pick select { font:inherit; font-size:15px; padding:3px 6px; border-radius:6px; border:1px solid var(--line); }
main { max-width:860px; margin:0 auto; padding:16px; }
#banner { background:var(--mid-bg); border-bottom:1px solid #f0d78c; padding:8px 16px; font-size:15px; }
.muted { color:var(--muted); font-size:15px; }
button, select, input, textarea { font:inherit; }
button.primary { background:var(--accent); color:#fff; border:0; padding:10px 20px; border-radius:8px; cursor:pointer; }
button.primary:disabled { opacity:.5; cursor:default; }
button.secondary { background:#fff; color:var(--accent); border:1px solid var(--accent); padding:9px 16px; border-radius:8px; cursor:pointer; }
button.link { background:none; border:0; color:var(--accent); cursor:pointer; padding:0; text-decoration:underline; }
button.chip { font-size:14px; padding:4px 12px; border:1px solid var(--line); border-radius:16px; background:#fff; cursor:pointer; }
button.chip.on { border-color:var(--ink); background:var(--ink); color:#fff; }
button.chip.danger { color:var(--bad); }
.card { background:var(--card); border:1px solid var(--line); border-radius:10px; padding:14px 16px; margin:10px 0; }
.card.click { cursor:pointer; } .card.click:hover { border-color:var(--accent); }
.row { display:flex; gap:12px 18px; flex-wrap:wrap; align-items:center; margin:10px 0; } .row.tight { margin:6px 0; }
.err { color:var(--bad); min-height:1px; }
.tag { font-size:12.5px; background:#eef2ff; color:var(--accent); padding:1px 8px; border-radius:10px; white-space:nowrap; }
.lv { font-size:12px; border:1px solid currentColor; border-radius:10px; padding:0 7px; white-space:nowrap; } .lv-easy{color:var(--ok)} .lv-medium{color:var(--mid)} .lv-hard{color:var(--bad)}
ul.plain { margin:6px 0 0; padding-left:20px; }
.fm label { display:block; font-size:14px; font-weight:600; margin:8px 0 2px; } .fm label.chk { font-weight:400; font-size:13px; }
.fm input[type=text], .fm input[type=tel], .fm input[type=password], .fm select, textarea.in, input.in { width:100%; padding:8px 10px; border:1px solid var(--line); border-radius:8px; background:#fff; }
.fm .row label { margin:0; } .fm .row select { width:auto; }
.card.auth { max-width:460px; margin:14px auto; }
dialog { border:1px solid var(--line); border-radius:12px; padding:16px; width:min(460px, 94vw); max-height:92vh; overflow:auto; }
.child-row { display:flex; gap:8px; align-items:center; padding:6px 0; border-bottom:1px solid var(--line); } .grow { flex:1; }

/* báo cáo */
.tiles { display:grid; grid-template-columns:repeat(4, 1fr); gap:8px; margin:10px 0; }
.tile { border-radius:10px; padding:10px 8px; text-align:center; border:1px solid transparent; cursor:pointer; }
.tile b { display:block; font-size:24px; line-height:1.1; } .tile span { font-size:12.5px; }
.t-improve { background:var(--bad-bg); color:var(--bad); border-color:#f6caca; } .t-medium { background:var(--mid-bg); color:var(--mid); border-color:#f0d78c; }
.t-solid { background:var(--ok-bg); color:var(--ok); border-color:#b7e4c7; } .t-new { background:var(--new-bg); color:var(--new); border-color:var(--line); }
.sec-h { display:flex; align-items:center; gap:8px; margin:20px 0 4px; font-size:17px; font-weight:700; }
.sec-h .n { font-weight:500; color:var(--muted); font-size:14px; }
.tcard { border-left:5px solid var(--line); }
.tcard.improve { border-left-color:var(--bad); } .tcard.medium { border-left-color:#e0a100; } .tcard.solid { border-left-color:var(--ok); } .tcard.new { border-left-color:#98a2b3; }
.bar { height:8px; border-radius:4px; background:#e5e9ef; overflow:hidden; margin:6px 0 2px; } .bar i { display:block; height:100%; background:var(--accent); }
.improve .bar i { background:var(--bad); } .medium .bar i { background:#e0a100; } .solid .bar i { background:var(--ok); }
.legend { font-size:14px; color:var(--muted); background:#fff; border:1px dashed var(--line); border-radius:8px; padding:8px 12px; margin:8px 0; }
.pill { font-weight:700; font-size:14px; border-radius:12px; padding:1px 10px; } .pill.good{background:var(--ok-bg);color:var(--ok)} .pill.mid{background:var(--mid-bg);color:var(--mid)} .pill.low{background:var(--bad-bg);color:var(--bad)}
.ok-box { background:var(--ok-bg); border:1px solid #b7e4c7; border-radius:8px; padding:8px 12px; margin:8px 0; }
.warn-box { background:var(--mid-bg); border:1px solid #f0d78c; border-radius:8px; padding:8px 12px; margin:8px 0; }
.bad-box { background:var(--bad-bg); border:1px solid #f6caca; border-radius:8px; padding:8px 12px; margin:8px 0; }

/* lý thuyết */
ol.rules { padding-left:22px; } ol.rules li { margin:4px 0; }
.ex { background:#f8fafc; border-left:3px solid var(--accent); padding:6px 12px; margin:6px 0; } .ex .vi { color:var(--muted); font-size:15px; }
.mistake { color:var(--bad); }
.tip { background:var(--mid-bg); padding:8px 12px; border-radius:8px; }
.step { font-weight:700; margin:18px 0 6px; padding-bottom:4px; border-bottom:2px solid var(--ink); }

/* làm bài */
.checks label { display:flex; gap:8px; align-items:flex-start; margin:5px 0; cursor:pointer; }
.dot { display:inline-block; width:10px; height:10px; border-radius:50%; margin-right:2px; background:#98a2b3; } .dot.improve{background:var(--bad)} .dot.medium{background:#e0a100} .dot.solid{background:var(--ok)}
#timer-bar { position:sticky; top:0; background:var(--card); border-bottom:1px solid var(--line); padding:8px 0; display:flex; justify-content:space-between; font-weight:600; z-index:2; }
#timer.low { color:var(--bad); }
.q { background:var(--card); border:1px solid var(--line); border-radius:10px; padding:12px 14px; margin:10px 0; }
.q .kind { font-size:12.5px; color:var(--muted); text-transform:uppercase; letter-spacing:.03em; }
.qtext { font-weight:600; font-size:18px; margin:2px 0 6px; white-space:pre-line; }
.blank { display:inline-block; min-width:56px; border-bottom:2px solid var(--ink); }
.opt { display:flex; gap:8px; padding:8px 10px; margin:5px 0; border:1px solid var(--line); border-radius:8px; cursor:pointer; background:#fff; }
.opt:hover { background:#f1f5f9; } .opt:has(input:checked) { border-color:var(--accent); background:#eff6ff; }
.opt.ok { border-color:var(--ok); background:var(--ok-bg); } .opt.bad { border-color:var(--bad); background:var(--bad-bg); }
.words, .built { display:flex; flex-wrap:wrap; gap:8px; min-height:44px; padding:8px; border-radius:8px; }
.words { background:#f1f5f9; } .built { background:#fff; border:2px dashed var(--line); margin-bottom:8px; }
.w { font-size:17px; padding:6px 12px; border:1px solid var(--line); border-radius:8px; background:#fff; cursor:pointer; box-shadow:0 1px 0 var(--line); }
.w.used { opacity:.25; pointer-events:none; }
.explain { white-space:pre-line; background:#f8fafc; border-left:3px solid var(--accent); padding:8px 12px; margin-top:8px; font-size:16px; }
.ans-line { margin:6px 0 0; } .ans-line b.ok { color:var(--ok); } .ans-line b.bad { color:var(--bad); }
.score { font-size:26px; font-weight:700; margin:6px 0; }
.progress { height:10px; background:#e5e9ef; border-radius:5px; overflow:hidden; } .progress i { display:block; height:100%; background:var(--accent); transition:width .3s; }
details.vi summary { cursor:pointer; color:var(--muted); font-size:14px; }
.drop { border:2px dashed var(--line); border-radius:10px; padding:18px; text-align:center; background:#fff; }
img.pv { max-width:100%; max-height:260px; border:1px solid var(--line); border-radius:8px; margin:8px 0; }
@media (max-width:600px) { .tiles { grid-template-columns:repeat(2, 1fr); } h1 small { display:none; } }

.tag.st-improve { background:var(--bad-bg); color:var(--bad); } .tag.st-medium { background:var(--mid-bg); color:var(--mid); } .tag.st-solid { background:var(--ok-bg); color:var(--ok); } .tag.st-new { background:var(--new-bg); color:var(--new); }

/* ===================== Giao diện tươi vui ===================== */
:root { --accent:#4f46e5; --accent2:#06b6d4; --sun:#f59e0b; --pink:#ec4899; }
body { font-family:"Nunito", system-ui, -apple-system, "Segoe UI", sans-serif; background:linear-gradient(180deg, #eaf4ff 0%, #fff7ed 100%) fixed; }
h1, h2, h3 { font-weight:800; }
header { background:linear-gradient(120deg, #4f46e5 0%, #7c3aed 50%, #ec4899 100%); border:0; color:#fff; box-shadow:0 4px 16px rgba(79,70,229,.25); }
h1 { color:#fff; } h1 small { color:#e0e7ff; }
.logo { display:inline-block; animation:bob 2.4s ease-in-out infinite; }
.kid-pick { color:#e0e7ff; } .kid-pick select { border:0; background:#fff; color:#3730a3; font-weight:700; border-radius:10px; }
header button.chip { background:rgba(255,255,255,.2); color:#fff; border-color:rgba(255,255,255,.5); font-weight:700; }
nav { gap:6px; padding-top:4px; }
nav button { color:#e0e7ff; border:0; border-radius:999px; padding:7px 14px; font-weight:700; transition:background .15s, transform .15s; }
nav button:hover { background:rgba(255,255,255,.18); transform:translateY(-1px); }
nav button.active { background:#fff; color:#4f46e5; box-shadow:0 2px 8px rgba(0,0,0,.15); }
main { padding-top:18px; }

button.primary { background:linear-gradient(135deg, #4f46e5, #7c3aed); border-radius:14px; font-weight:800; box-shadow:0 4px 0 #3730a3; transition:transform .1s, box-shadow .1s; }
button.primary:hover:not(:disabled) { transform:translateY(-2px); box-shadow:0 6px 0 #3730a3; }
button.primary:active:not(:disabled) { transform:translateY(3px); box-shadow:0 1px 0 #3730a3; }
button.secondary { border-radius:14px; border-width:2px; font-weight:800; color:#4f46e5; border-color:#a5b4fc; background:#eef2ff; transition:transform .1s; }
button.secondary:hover { transform:translateY(-2px); }
button.chip { font-weight:700; transition:transform .1s, background .15s; } button.chip:hover { transform:translateY(-1px); background:#eef2ff; }
button.chip.on { background:linear-gradient(135deg, #4f46e5, #7c3aed); border-color:transparent; }
.card { border-radius:16px; border:2px solid #e8ecf5; box-shadow:0 2px 0 #e8ecf5; animation:fadeUp .35s ease both; }
.card.click { transition:transform .12s, border-color .12s, box-shadow .12s; } .card.click:hover { transform:translateY(-2px); border-color:var(--c, #4f46e5); box-shadow:0 5px 14px rgba(79,70,229,.12); }

/* chào hỏi + linh vật */
.hero { display:flex; align-items:center; gap:14px; padding:14px 18px; border-radius:20px; background:linear-gradient(120deg, #fde68a, #fdba74 55%, #f9a8d4); color:#7c2d12; font-weight:600; box-shadow:0 4px 0 #f59e0b55; animation:fadeUp .4s ease both; }
.hero-ic { font-size:46px; line-height:1; animation:bob 2.2s ease-in-out infinite; } .hero-ic.pop { animation:pop .6s cubic-bezier(.2,1.6,.4,1) both; font-size:56px; }
.hero-t { font-size:21px; font-weight:800; color:#7c2d12; }
.hero.result { background:linear-gradient(120deg, #bbf7d0, #a5f3fc 60%, #c7d2fe); color:#134e4a; } .hero.result .hero-t { color:#134e4a; }

/* ô thống kê */
.tiles { gap:10px; }
.tile { position:relative; border-radius:18px; padding:12px 8px 10px; border:0; color:#fff; box-shadow:0 4px 0 rgba(0,0,0,.14); transition:transform .12s; overflow:hidden; }
.tile:hover { transform:translateY(-3px) rotate(-1deg); } .tile i { display:block; font-style:normal; font-size:26px; } .tile b { font-size:28px; } .tile span { font-weight:700; opacity:.95; }
.t-improve { background:linear-gradient(135deg, #fb7185, #e11d48); } .t-medium { background:linear-gradient(135deg, #fbbf24, #f97316); }
.t-solid { background:linear-gradient(135deg, #4ade80, #16a34a); } .t-new { background:linear-gradient(135deg, #94a3b8, #64748b); }
.progress { height:12px; background:#e0e7ff; border-radius:8px; } .progress i { background:linear-gradient(90deg, #22c55e, #06b6d4, #6366f1); border-radius:8px; }
.progress.big { height:16px; margin-top:6px; }
.legend { border-radius:12px; background:#fffbeb; border:2px dashed #fcd34d; color:#92400e; }
.sec-h { font-size:19px; margin-top:24px; } #sec-improve { color:#be123c; } #sec-medium { color:#c2410c; } #sec-solid { color:#15803d; } #sec-new { color:#475569; }
.sec-h .n { color:var(--muted); font-weight:600; }

/* thẻ dạng ngữ pháp có màu chủ đề */
.th { display:flex; gap:12px; align-items:center; } .th.big { margin:6px 0; }
.cat-ic { display:inline-flex; align-items:center; justify-content:center; width:44px; height:44px; flex:none; border-radius:14px; font-size:24px; background:var(--cb, #e0e7ff); box-shadow:inset 0 -3px 0 rgba(0,0,0,.08); }
.cat-h .cat-ic { width:30px; height:30px; font-size:17px; border-radius:10px; vertical-align:middle; }
.cat-h { display:block; color:var(--c); margin:18px 0 6px; font-size:17px; }
.tag.cat { background:var(--cb, #eef2ff); color:var(--c, #4f46e5); font-weight:700; }
.stars { font-size:13px; letter-spacing:1px; }
.tcard.improve { border-left:6px solid #e11d48; } .tcard.medium { border-left:6px solid #f59e0b; } .tcard.solid { border-left:6px solid #16a34a; } .tcard.new { border-left:6px solid #94a3b8; }
.bar { height:10px; border-radius:6px; }
.checks .cat-h { margin-top:12px; }
.checks label { padding:6px 8px; border-radius:10px; transition:background .12s; } .checks label:hover { background:#f5f3ff; }
.ex { border-left-color:#7c3aed; background:#f5f3ff; border-radius:0 12px 12px 0; }
.tip { background:#fef3c7; border-radius:14px; border:2px dashed #fcd34d; }
.step { border-bottom-color:#7c3aed; }

/* làm bài */
#timer-bar { background:linear-gradient(90deg, #eef2ff, #fdf2f8); border:2px solid #e0e7ff; border-radius:14px; padding:8px 14px; margin-bottom:8px; color:#3730a3; }
#timer.low { color:#e11d48; animation:pulse .8s ease-in-out infinite; }
.q { border-radius:18px; border:2px solid #e8ecf5; border-top:6px solid #6366f1; box-shadow:0 3px 0 #e8ecf5; animation:fadeUp .35s ease both; }
.q.k-fill { border-top-color:#f59e0b; } .q.k-reorder { border-top-color:#ec4899; } .q.k-correct { border-top-color:#0891b2; }
.q.right { border-top-color:#16a34a; background:#f0fdf4; } .q.wrong { border-top-color:#e11d48; background:#fff7f7; }
.q .kind { display:flex; align-items:center; gap:6px; text-transform:none; font-size:14px; font-weight:700; color:#475569; }
.qn { display:inline-flex; align-items:center; justify-content:center; width:26px; height:26px; border-radius:50%; background:#6366f1; color:#fff; font-size:14px; }
.q.k-fill .qn { background:#f59e0b; } .q.k-reorder .qn { background:#ec4899; } .q.right .qn { background:#16a34a; } .q.wrong .qn { background:#e11d48; }
.qtext { font-size:19px; }
.blank { border-bottom:3px dashed #ec4899; }
.opt { border-radius:14px; border:2px solid #e2e8f0; align-items:center; transition:transform .1s, border-color .1s, background .1s; }
.opt:hover { background:#f5f3ff; border-color:#a5b4fc; transform:translateX(3px); }
.opt:has(input:checked) { border-color:#6366f1; background:#eef2ff; box-shadow:0 0 0 3px #c7d2fe; }
.opt input { accent-color:#6366f1; }
.ltr { display:inline-flex; align-items:center; justify-content:center; width:28px; height:28px; border-radius:50%; flex:none; background:#e0e7ff; color:#4338ca; font-size:14px; }
.opt:nth-of-type(2) .ltr { background:#fce7f3; color:#be185d; } .opt:nth-of-type(3) .ltr { background:#dcfce7; color:#15803d; } .opt:nth-of-type(4) .ltr { background:#ffedd5; color:#c2410c; }
.opt.ok { border-color:#16a34a; background:#dcfce7; } .opt.bad { border-color:#e11d48; background:#ffe4e6; }
input.in { border:2px solid #e2e8f0 !important; border-radius:14px !important; font-size:18px; padding:10px 14px !important; } input.in:focus { outline:none; border-color:#6366f1 !important; box-shadow:0 0 0 3px #c7d2fe; }
.words { background:#fdf2f8; border-radius:14px; } .built { border-color:#f9a8d4; border-radius:14px; background:#fff; }
.w { border:2px solid #f9a8d4; border-radius:12px; font-weight:700; color:#9d174d; box-shadow:0 3px 0 #f9a8d4; transition:transform .1s; } .w:hover { transform:translateY(-2px); } .w:active { transform:translateY(2px); box-shadow:none; }
.explain { background:#eef2ff; border-left-color:#6366f1; border-radius:0 12px 12px 0; }
.score { font-size:30px; font-weight:800; color:#4f46e5; margin:10px 0 4px; }
.pill { font-weight:800; } .ok-box, .warn-box, .bad-box { border-radius:14px; }
.drop { border-radius:16px; border-color:#a5b4fc; background:#eef2ff; }
.confetti { position:fixed; inset:0; pointer-events:none; z-index:50; }
.card.auth { border-top:6px solid #ec4899; }

@keyframes fadeUp { from { opacity:0; transform:translateY(10px); } to { opacity:1; transform:none; } }
@keyframes bob { 0%, 100% { transform:translateY(0) rotate(-3deg); } 50% { transform:translateY(-6px) rotate(3deg); } }
@keyframes pop { from { transform:scale(0) rotate(-30deg); } to { transform:scale(1) rotate(0); } }
@keyframes pulse { 50% { opacity:.55; transform:scale(1.06); } }
@media (prefers-reduced-motion: reduce) { * { animation:none !important; transition:none !important; } }
@media (max-width:600px) { .hero-ic { font-size:38px; } .hero-t { font-size:18px; } nav button { padding:6px 11px; font-size:15px; } }

/* ===================== Menu con, Trang chủ ===================== */
.subnav { display:flex; gap:6px; flex-wrap:wrap; margin:0 0 12px; padding:6px; background:#fff; border:2px solid #e0e7ff; border-radius:999px; width:max-content; max-width:100%; overflow-x:auto; }
.subnav button { border:0; background:none; font:inherit; font-weight:700; color:#4f46e5; padding:6px 14px; border-radius:999px; cursor:pointer; white-space:nowrap; }
.subnav button.active { background:linear-gradient(135deg, #4f46e5, #7c3aed); color:#fff; }
.tasks { display:grid; grid-template-columns:repeat(auto-fit, minmax(220px, 1fr)); gap:12px; }
.task { display:flex; flex-direction:column; align-items:flex-start; gap:2px; text-align:left; border:0; border-radius:20px; padding:16px 18px; color:#fff; font:inherit; cursor:pointer; box-shadow:0 5px 0 rgba(0,0,0,.15); transition:transform .12s; animation:fadeUp .4s ease both; }
.task:hover { transform:translateY(-3px); } .task:active { transform:translateY(2px); box-shadow:0 2px 0 rgba(0,0,0,.15); }
.task i { font-style:normal; font-size:34px; } .task b { font-size:19px; } .task span { opacity:.95; }
.t-vocab { background:linear-gradient(135deg, #22c55e, #0891b2); } .t-gram { background:linear-gradient(135deg, #6366f1, #a855f7); } .t-pron { background:linear-gradient(135deg, #f97316, #ec4899); }
.sum3 { display:grid; grid-template-columns:repeat(auto-fit, minmax(220px, 1fr)); gap:12px; }
.sum { cursor:pointer; } .sum-h { font-weight:800; } .big-n { font-size:36px; font-weight:800; color:#4f46e5; line-height:1.1; } .big-n small { font-size:18px; color:var(--muted); }
.mini { display:flex; flex-wrap:wrap; gap:4px; margin-top:6px; }

/* ===================== Từ vựng ===================== */
.vhero { background:linear-gradient(120deg, #bbf7d0, #a5f3fc); color:#134e4a; } .vhero .hero-t { color:#134e4a; }
.v-new { background:linear-gradient(135deg, #94a3b8, #64748b); } .v-learning { background:linear-gradient(135deg, #60a5fa, #2563eb); }
.v-review { background:linear-gradient(135deg, #fbbf24, #f97316); } .v-mastered { background:linear-gradient(135deg, #4ade80, #16a34a); }
.vset { border-left:6px solid #22c55e; }
.vtop { display:flex; align-items:center; gap:10px; margin-bottom:6px; } .vtop .progress { flex:1; }
.vlabel { text-align:center; font-weight:800; color:#7c3aed; margin:4px 0 8px; font-size:17px; }
.emo { font-size:64px; line-height:1.1; text-align:center; } .emo.s { font-size:34px; }
.fw { font-size:34px; font-weight:800; text-align:center; color:#1e1b4b; } .fw.vi { font-size:26px; color:#7c2d12; } .fw.sent { font-size:24px; }
.ipa { color:#7c3aed; text-align:center; font-size:18px; } .ipa.big { font-size:22px; } .witem .ipa { font-size:15px; }
.flash { position:relative; min-height:280px; perspective:900px; cursor:pointer; margin:10px auto; max-width:460px; }
.flash > div { position:absolute; inset:0; display:flex; flex-direction:column; align-items:center; justify-content:center; gap:6px; padding:18px; border-radius:24px; backface-visibility:hidden; transition:transform .5s; box-shadow:0 6px 0 rgba(0,0,0,.08); }
.f-front { background:linear-gradient(160deg, #fff, #eef2ff); border:3px solid #c7d2fe; }
.f-back { background:linear-gradient(160deg, #fff7ed, #fde68a); border:3px solid #fcd34d; transform:rotateY(180deg); text-align:center; }
.flash.flip .f-front { transform:rotateY(180deg); } .flash.flip .f-back { transform:rotateY(360deg); }
.fex { font-style:italic; font-size:18px; margin-top:8px; }
button.chip.big { font-size:16px; padding:8px 16px; }
.vex { background:#fff; border:3px solid #e0e7ff; border-radius:24px; padding:18px; max-width:560px; margin:0 auto; animation:fadeUp .3s ease both; }
.vex.right { border-color:#22c55e; background:#f0fdf4; } .vex.wrong { border-color:#f43f5e; background:#fff1f2; animation:shake .35s; }
.vopts { display:grid; grid-template-columns:1fr 1fr; gap:10px; margin-top:14px; }
.vopt { display:flex; gap:8px; align-items:center; text-align:left; font:inherit; font-size:18px; font-weight:700; padding:12px; border-radius:16px; border:2px solid #e2e8f0; background:#fff; cursor:pointer; box-shadow:0 3px 0 #e2e8f0; transition:transform .1s; }
.vopt:hover:not(:disabled) { transform:translateY(-2px); border-color:#a5b4fc; } .vopt.ok { border-color:#16a34a; background:#dcfce7; } .vopt.bad { border-color:#e11d48; background:#ffe4e6; }
.listen { display:block; margin:6px auto; font-size:56px; width:110px; height:110px; border-radius:50%; border:0; background:linear-gradient(135deg, #22c55e, #0891b2); color:#fff; cursor:pointer; box-shadow:0 6px 0 #0e7490; }
.listen:active { transform:translateY(3px); box-shadow:0 2px 0 #0e7490; }
.slots { display:flex; flex-wrap:wrap; justify-content:center; gap:6px; margin:14px 0; }
.slot { width:40px; height:48px; border-radius:10px; border:3px dashed #c7d2fe; display:flex; align-items:center; justify-content:center; font-size:24px; font-weight:800; color:#4f46e5; background:#fff; }
.slot.on { border-style:solid; border-color:#6366f1; background:#eef2ff; cursor:pointer; } .slot.fixed { border:0; width:16px; background:none; }
.tiles2 { display:flex; flex-wrap:wrap; justify-content:center; gap:8px; margin-bottom:6px; } .tiles2 .w { font-size:22px; min-width:44px; }
.fb { text-align:center; font-size:17px; margin-top:12px; }
.wgrid { display:grid; grid-template-columns:repeat(auto-fill, minmax(140px, 1fr)); gap:10px; margin:12px 0; }
.wcard { background:#fff; border:2px solid #e8ecf5; border-radius:16px; padding:10px; text-align:center; } .wcard.right { border-color:#86efac; } .wcard.wrong { border-color:#fda4af; }
.wlist { display:flex; flex-direction:column; gap:8px; margin-top:10px; }
.witem { display:flex; gap:12px; align-items:center; background:#fff; border:2px solid #e8ecf5; border-left:6px solid #94a3b8; border-radius:14px; padding:10px 12px; }
.witem.st-learning { border-left-color:#2563eb; } .witem.st-review { border-left-color:#f59e0b; } .witem.st-mastered { border-left-color:#16a34a; }
.wside { display:flex; flex-direction:column; align-items:flex-end; gap:4px; }
.pb { font-size:12.5px; font-weight:800; border-radius:10px; padding:1px 8px; } .pb.good { background:#dcfce7; color:#15803d; } .pb.ok { background:#fef3c7; color:#b45309; } .pb.bad { background:#ffe4e6; color:#be123c; }
.seg { gap:8px; }

/* ===================== Phát âm ===================== */
.pchips { display:flex; flex-wrap:wrap; gap:6px; margin:10px 0; }
.pchip { font:inherit; font-weight:700; padding:5px 12px; border-radius:999px; border:2px solid #e2e8f0; background:#fff; cursor:pointer; }
.pchip.good { border-color:#86efac; background:#f0fdf4; } .pchip.ok { border-color:#fcd34d; background:#fffbeb; } .pchip.bad { border-color:#fda4af; background:#fff1f2; }
.pchip.on { border-color:#7c3aed; box-shadow:0 0 0 3px #ddd6fe; }
.pcard { background:#fff; border:3px solid #fbcfe8; border-radius:24px; padding:18px; text-align:center; animation:fadeUp .3s ease both; }
.mic { display:flex; flex-direction:column; align-items:center; gap:2px; margin:14px auto 6px; width:150px; height:150px; border-radius:50%; border:0; cursor:pointer; color:#fff; font:inherit;
  background:radial-gradient(circle at 35% 30%, #fb7185, #e11d48); box-shadow:0 8px 0 #9f1239, 0 0 0 0 rgba(244,63,94,.5); justify-content:center; }
.mic span { font-size:52px; line-height:1; } .mic b { font-size:14px; max-width:120px; }
.mic.rec { animation:recpulse 1.1s ease-out infinite; background:radial-gradient(circle at 35% 30%, #f97316, #dc2626); }
.lvl { height:8px; max-width:240px; margin:0 auto 8px; background:#fde2e8; border-radius:4px; overflow:hidden; } .lvl i { display:block; height:100%; width:0; background:linear-gradient(90deg, #22c55e, #f59e0b, #e11d48); transition:width .08s; }
#pr-out audio { width:100%; max-width:360px; margin:6px auto; display:block; }
.pres { display:flex; gap:14px; align-items:center; justify-content:center; text-align:left; margin:10px 0; }
.ring { --c:#16a34a; width:92px; height:92px; flex:none; border-radius:50%; display:flex; align-items:center; justify-content:center; background:conic-gradient(var(--c) calc(var(--p) * 1%), #e5e7eb 0); }
.ring b { width:72px; height:72px; border-radius:50%; background:#fff; display:flex; align-items:center; justify-content:center; font-size:28px; color:var(--c); }
.pres.ok .ring { --c:#f59e0b; } .pres.bad .ring { --c:#e11d48; }
.phones, .pwords { display:flex; flex-wrap:wrap; justify-content:center; gap:6px; margin:6px 0; }
.ph, .pw { display:inline-flex; flex-direction:column; align-items:center; min-width:48px; padding:6px 8px; border-radius:12px; font-size:20px; font-weight:800; font-family:"Nunito", "Segoe UI", "Lucida Sans Unicode", sans-serif; }
.ph small, .pw small { font-size:11px; font-weight:700; opacity:.8; }
.ph.good, .pw.good { background:#dcfce7; color:#15803d; } .ph.ok, .pw.ok { background:#fef3c7; color:#b45309; } .ph.bad, .pw.bad { background:#ffe4e6; color:#be123c; }
.pw { flex-direction:row; gap:6px; font-size:17px; }
.tips { text-align:left; background:#fff7ed; border:2px dashed #fdba74; border-radius:16px; padding:10px 14px; margin-top:10px; }
.tipline { display:flex; gap:10px; align-items:flex-start; margin:8px 0; } .tipline .ph { font-size:16px; min-width:44px; flex:none; }
.small { font-size:13px; }
@keyframes recpulse { 0% { box-shadow:0 8px 0 #9f1239, 0 0 0 0 rgba(244,63,94,.55); } 100% { box-shadow:0 8px 0 #9f1239, 0 0 0 26px rgba(244,63,94,0); } }
@keyframes shake { 25% { transform:translateX(-6px); } 75% { transform:translateX(6px); } }
@media (max-width:600px) { .vopts { grid-template-columns:1fr; } .fw { font-size:28px; } .subnav { width:100%; } .mic { width:130px; height:130px; } }

[hidden] { display:none !important; }

/* ===================== Thi vào lớp 6 ===================== */
.exhero { background:linear-gradient(120deg, #c7d2fe, #fbcfe8 60%, #fde68a); color:#312e81; } .exhero .hero-t { color:#312e81; }
.t-exam { background:linear-gradient(135deg, #4f46e5, #0ea5e9); }
.info-box { background:#eff6ff; border:2px dashed #93c5fd; border-radius:14px; padding:8px 14px; margin:10px 0; font-size:15px; color:#1e3a8a; }
.school { margin:18px 0; } .sc-h { font-size:18px; margin-bottom:4px; }
.xcard { border-left:6px solid #6366f1; }
.ob { font-size:12.5px; font-weight:800; border-radius:10px; padding:1px 8px; white-space:nowrap; }
.ob-sim { background:#fef3c7; color:#92400e; } .ob-real { background:#dcfce7; color:#166534; } .ob-design { background:#ede9fe; color:#5b21b6; }
.dchips { display:flex; flex-wrap:wrap; gap:4px; margin:6px 0; } .dc { font-size:12.5px; background:#f1f5f9; border-radius:10px; padding:1px 8px; color:#475569; }
.stars { color:#f59e0b; letter-spacing:1px; }
.xintro .xstats { display:grid; grid-template-columns:repeat(4, 1fr); gap:8px; margin:12px 0; text-align:center; }
.xstats div { background:#eef2ff; border-radius:14px; padding:8px 4px; } .xstats b { display:block; font-size:22px; color:#4338ca; } .xstats span { font-size:12.5px; color:var(--muted); }
.xs-row { display:flex; gap:8px; align-items:center; padding:6px 0; border-bottom:1px solid #eef0f6; }
.xs-l { display:inline-flex; width:26px; height:26px; border-radius:8px; align-items:center; justify-content:center; background:#6366f1; color:#fff; font-weight:800; font-size:14px; flex:none; }
.xbar { top:0; } .xnav { display:flex; flex-wrap:wrap; gap:4px; margin:8px 0 14px; }
.xnav button { width:34px; height:34px; border-radius:10px; border:2px solid #e2e8f0; background:#fff; font:inherit; font-weight:700; font-size:13px; cursor:pointer; color:#475569; }
.xnav button.done { background:#6366f1; border-color:#6366f1; color:#fff; }
.xsec { margin:22px 0 8px; padding:8px 12px; border-radius:14px; background:linear-gradient(90deg, #eef2ff, #fdf2f8); border:2px solid #e0e7ff; display:flex; flex-wrap:wrap; gap:4px 10px; align-items:center; }
.xsec .muted { flex-basis:100%; font-size:14px; }
.passage { background:#fffbeb; border:2px solid #fde68a; border-radius:16px; padding:12px 16px; margin:10px 0; line-height:1.75; }
.passage .p-t { font-weight:800; color:#92400e; margin-bottom:4px; } .bl { background:#fef08a; border-radius:6px; padding:0 6px; color:#854d0e; }
.xq { scroll-margin-top:70px; } .flash-q { animation:flashq .9s ease; } @keyframes flashq { 30% { box-shadow:0 0 0 5px #a5b4fc; } }
.xq u, .q u { text-decoration-thickness:2px; text-underline-offset:3px; } .qtext sup { font-size:11px; color:#6366f1; font-weight:800; margin-left:1px; }
.qtext.pre { white-space:pre-line; } .opts2 { display:grid; grid-template-columns:1fr 1fr; gap:0 10px; }
.dbars { display:flex; flex-direction:column; gap:6px; margin:6px 0 12px; } .dbar { display:flex; align-items:center; gap:8px; } .db-n { width:170px; font-size:14px; } .dbar .bar { flex:1; margin:0; }
.step-row { display:flex; align-items:center; gap:8px; padding:5px 0; border-bottom:1px solid #f1f3f9; } .step-row .chip { width:34px; height:34px; padding:0; font-size:18px; } .sv { width:28px; text-align:center; font-size:18px; }
.xgrp b:first-child { color:#4338ca; } .sumbar { position:sticky; bottom:8px; background:#fff; border:2px solid #c7d2fe; border-radius:14px; padding:8px 14px; margin:12px 0; display:flex; gap:10px; align-items:center; box-shadow:0 4px 14px rgba(79,70,229,.15); }
.spark { display:flex; align-items:flex-end; gap:6px; height:110px; margin:10px 0 4px; } .sp { flex:1; max-width:44px; height:100%; display:flex; flex-direction:column; justify-content:flex-end; align-items:center; }
.sp i { display:block; width:100%; border-radius:8px 8px 0 0; background:#6366f1; } .sp i.good { background:#22c55e; } .sp i.mid { background:#f59e0b; } .sp i.low { background:#f43f5e; } .sp span { font-size:11px; font-weight:700; color:#475569; }
@media (max-width:600px) { .opts2 { grid-template-columns:1fr; } .db-n { width:110px; font-size:13px; } .xintro .xstats { grid-template-columns:repeat(2, 1fr); } }
