/* Hoc Cung Son — he thiet ke chung: mobile-first, chu to, nut to, chuyen nghiep. */
:root{--blue:#143a6b;--blue2:#1d6fd1;--yellow:#ffc107;--orange:#ff7a29;--green:#1a9e57;--red:#b42318;--bg:#eef3fb;--ink:#16233a;--muted:#5b6b85}
*{box-sizing:border-box}
body{font-family:system-ui,-apple-system,Arial,sans-serif;margin:0;background:var(--bg);color:var(--ink);font-size:19px;line-height:1.6}
a{color:var(--blue2);text-decoration:none}
.topbar{background:#fff;border-bottom:1px solid #e2e6ef;position:sticky;top:0;z-index:10}
.topbar-inner{max-width:1140px;margin:0 auto;padding:14px 18px;display:flex;gap:14px;align-items:center;flex-wrap:wrap}
.brand{font-weight:800;font-size:22px;color:var(--blue)}
.brand small{display:block;font-size:14px;color:var(--muted);font-weight:400}
.topbar nav{margin-left:auto;display:flex;gap:8px;flex-wrap:wrap}
.topbar nav a{padding:10px 14px;border-radius:999px;color:var(--ink)}
.topbar nav a.cta{background:var(--yellow);color:#222;font-weight:700}
.wrap{max-width:1140px;margin:0 auto;padding:18px}
.hero{background:linear-gradient(135deg,#0f2f5c,#1d6fd1);color:#fff;border-radius:24px;padding:32px}
.hero h1{font-size:40px;line-height:1.25;margin:0 0 10px}
.hero p{font-size:20px;opacity:.95}
.hero .btns{display:flex;gap:12px;flex-wrap:wrap;margin-top:18px}
.btn{display:inline-block;border:0;border-radius:14px;padding:15px 22px;background:var(--blue);color:#fff;cursor:pointer;font-size:19px;font-weight:700;min-height:56px;text-align:center}
.btn.y{background:var(--yellow);color:#222}.btn.o{background:var(--orange)}.btn.g{background:var(--green)}.btn.light{background:#fff;color:var(--blue)}
.btn.secondary{background:#e8edf5;color:var(--blue)}
.card{background:#fff;border:1px solid #e2e6ef;border-radius:20px;padding:22px;margin-bottom:16px;box-shadow:0 10px 22px rgba(20,58,107,.10)}
.grid{display:grid;grid-template-columns:repeat(3,1fr);gap:16px}
.grid2{display:grid;grid-template-columns:repeat(2,1fr);gap:16px}
@media(max-width:900px){.grid,.grid2{grid-template-columns:1fr}.hero h1{font-size:32px}}
.stat{font-size:34px;font-weight:800;color:var(--blue)}
.badge{display:inline-block;background:#e8f3ff;color:var(--blue);border-radius:999px;padding:6px 14px;font-size:16px;font-weight:700}
.badge.green{background:#e6f7ee;color:var(--green)}.badge.orange{background:#fff0e6;color:#c2570a}.badge.grey{background:#eef1f6;color:var(--muted)}
input,select,textarea{width:100%;padding:14px;border:1px solid #ccd3e0;border-radius:12px;margin:6px 0 12px;box-sizing:border-box;font-size:19px;min-height:56px;font-family:inherit}
label{font-weight:700}
.muted{color:var(--muted);font-size:17px}.bad{color:var(--red)}.ok{color:var(--green)}
.bar{height:16px;background:#e8edf5;border-radius:10px;overflow:hidden}.bar i{display:block;height:100%;background:linear-gradient(90deg,#1d6fd1,#1a9e57)}
.tabs{display:flex;gap:8px;flex-wrap:wrap;margin:14px 0}
.tabs button{background:#fff;color:var(--ink);border:1px solid #e2e6ef}
.tabs button.active{background:var(--blue);color:#fff}
.course{display:grid;grid-template-columns:1fr 340px;gap:16px;align-items:start}
@media(max-width:800px){.course{grid-template-columns:1fr}}
.lesson-btn{display:block;width:100%;text-align:left;background:#eef3fb;color:var(--blue);margin:4px 0}
.video-box{aspect-ratio:16/9;background:#111;color:#fff;display:grid;place-items:center;border-radius:16px;text-align:center;padding:16px}
.video-box iframe{width:100%;height:100%;border:0}
.q{border-top:1px solid #eee;padding:14px 0}
.q label{display:block;font-weight:400;margin:6px 0}
footer{background:#0f2f5c;color:#fff;margin-top:24px}
footer .wrap{padding:28px 18px}
footer a{color:#cfe3ff}
.student-head{display:flex;gap:16px;align-items:center;flex-wrap:wrap}
.avatar{width:72px;height:72px;border-radius:50%;background:linear-gradient(135deg,#1d6fd1,#ffc107);display:grid;place-items:center;font-size:32px;font-weight:800;color:#fff}
.table{width:100%;border-collapse:collapse;font-size:18px}
.table th,.table td{padding:12px;border-bottom:1px solid #eef1f6;text-align:left}
@media(max-width:700px){.table{font-size:16px}}

/* Mobile UX - ra soat 14:45 VN 04/11/2026: dien thoai la thiet bi chinh cua hoc sinh tieu hoc. */
@media(max-width:700px){
  body{font-size:18px}
  .topbar-inner{padding:10px 12px;gap:8px}
  .brand{font-size:20px}.brand small{font-size:13px}
  .topbar nav{flex-wrap:nowrap;overflow-x:auto;margin-left:0;width:100%;-webkit-overflow-scrolling:touch}
  .topbar nav a{white-space:nowrap;padding:10px 12px;flex:0 0 auto}
  .topbar .btn{width:auto}
  .hero{padding:22px}.hero h1{font-size:28px}.hero p{font-size:18px}
  .wrap{padding:12px}
  .card{padding:16px}
  .btn{width:100%}
  #examPalette .btn,.tabs button{width:auto}
  .table{display:block;overflow-x:auto;white-space:nowrap}
  .q label{padding:14px}
  .student-head{flex-direction:column;align-items:flex-start}
  .avatar{width:60px;height:60px;font-size:26px}
}

/* He thiet ke home da duyet - ap len khung hoc/quan tri/dang nhap 04/11/2026. */
.topbar{box-shadow:0 2px 12px rgba(20,58,107,.12)}
.brand{display:flex;align-items:center;gap:12px}
.brand .mark{width:52px;height:52px;border-radius:14px;background:var(--blue);display:grid;place-items:center;color:#fff;font-size:28px;font-weight:900;flex:0 0 auto}
.brand b{font-size:22px;line-height:1}
.brand small{display:block;font-size:14px;color:var(--muted);font-weight:600}
.site-footer{background:#143a6b;color:#fff;margin-top:24px}
.site-footer .wrap{display:flex;gap:24px;flex-wrap:wrap;justify-content:space-between}
.site-footer a{color:#cfe3ff}

/* Lời giải: mỗi bước 1 dòng, phép tính thụt vào cho học sinh tiểu học dễ đọc. */
.sol-line { margin: 5px 0; line-height: 1.65; }
.sol-calc { padding-left: 28px; }

/* --- Chrome chuẩn (port từ /assets/site.css, 09/11/2026) — header/footer dùng
   chung toàn site. Chỉ chứa selector .site-header/.site-footer/.logo__* :
   KHÔNG động vào .btn/.card/.wrap của app. Logo mark thống nhất theo trang
   chủ: ô vuông navy + "📖★". --- */
.site-header { position: sticky; top: 0; z-index: 50; background: #ffffff; border-bottom: 3px solid #dce4f0; box-shadow: 0 2px 12px rgba(20, 58, 107, 0.10); }
.site-header__inner { max-width: 1180px; margin: 0 auto; padding: 12px 20px; display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.logo { display: flex; align-items: center; gap: 12px; color: #143a6b; }
.logo:hover { text-decoration: none; }
.logo__mark { width: 52px; height: 52px; flex: none; border-radius: 14px; background: #143a6b; color: #fff; display: flex; align-items: center; justify-content: center; font-size: 22px; font-weight: 900; line-height: 1; white-space: nowrap; overflow: hidden; }
.logo__name { font-size: 24px; font-weight: 900; line-height: 1.1; display: block; }
.logo__slogan { font-size: 14px; font-weight: 700; color: #4e5e75; display: block; }
.site-nav { display: flex; gap: 4px; flex-wrap: wrap; margin-left: auto; }
.site-nav a { display: inline-block; padding: 12px 14px; font-size: 18px; font-weight: 800; color: #143a6b; border-radius: 999px; min-height: 48px; }
.site-nav a:hover { background: #eaf2fd; text-decoration: none; }
.site-nav a[aria-current="page"] { background: #143a6b; color: #fff; }
.site-nav a[aria-current="page"]:hover { background: #0e2a4e; }
.site-header .btn { margin-left: 4px; }
/* Nút Đăng nhập trong header chuẩn: y hệt .btn của site.css (nút app
   .btn.light / .btn.secondary không đổi). */
.site-header .btn:not(.light):not(.secondary) { display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 56px; min-width: 56px; padding: 14px 24px; border: 3px solid transparent; border-radius: 999px; font-family: inherit; font-size: 20px; font-weight: 800; line-height: 1.2; background: #1d6fd1; color: #fff; box-shadow: 0 4px 0 rgba(20, 58, 107, 0.18), 0 6px 16px rgba(29, 111, 209, 0.28); text-decoration: none; text-align: center; }
.site-header .btn:not(.light):not(.secondary):hover { text-decoration: none; transform: translateY(-2px); box-shadow: 0 4px 0 rgba(20, 58, 107, 0.08), 0 10px 24px rgba(20, 58, 107, 0.10); background: #155cb4; filter: none; }
.site-header .btn:not(.light):not(.secondary):active { transform: translateY(2px); box-shadow: 0 1px 0 rgba(20, 58, 107, 0.18); filter: none; }
.site-footer { background: #143a6b; color: #fff; margin-top: 40px; }
.site-footer__grid { max-width: 1180px; margin: 0 auto; padding: 36px 20px 12px; display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 28px; }
.site-footer h3 { color: #ffc107; font-size: 19px; margin-bottom: 10px; }
.site-footer p, .site-footer li { color: #fff; font-size: 17px; }
.site-footer a { color: #d6e4ff; }
.site-footer a:hover { color: #fff; }
.site-footer ul { list-style: none; padding: 0; margin: 0; }
.site-footer li { margin-bottom: 8px; }
.site-footer__brand { font-size: 21px; font-weight: 900; color: #fff; }
.site-footer__bottom { text-align: center; padding: 0 20px 24px; color: #d6e4ff; font-size: 16px; }
.site-header, .site-footer { font-family: "Nunito", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif; }

@media (max-width: 700px) {
  .site-header__inner { padding: 10px 12px; gap: 8px; }
  .site-nav { flex-wrap: nowrap; overflow-x: auto; width: 100%; margin-left: 0; -webkit-overflow-scrolling: touch; }
  .site-nav a { white-space: nowrap; flex: 0 0 auto; }
  .site-header .btn:not(.light):not(.secondary) { width: 100%; margin-left: 0; }
  .site-footer__grid { padding-top: 28px; }
}
