/* Đomđóm: lớp "ứng dụng trên điện thoại". Nạp sau app.css và game.css.
   Gồm: khung ứng dụng (thanh trên, thanh dưới, vùng an toàn, chặn kéo giật), bảng trượt dùng chung (.bang),
   các phần ghim theo màn, rút chiều cao từng màn. Màn rộng chỉ nhận phần bảng trượt (dạng hộp thoại giữa màn). */

/* ---------- Bảng trượt dùng chung (js/bang.js) ---------- */
.bang { padding: 0; border: 0; margin: auto; width: min(92vw, 480px); max-width: none; max-height: min(86vh, 720px); border-radius: var(--r); background: var(--surface); color: var(--ink); box-shadow: var(--sh-2); overflow: hidden; }
.bang[open] { display: flex; flex-direction: column; animation: bang-hien .18s ease-out both; }
.bang::backdrop { background: rgba(8, 16, 30, .5); animation: bang-nen .18s ease-out both; }
.bang.is-dong { animation: bang-an .18s ease-in both; } .bang.is-dong::backdrop { opacity: 0; transition: opacity .18s; }
.bang__tay { display: none; }
.bang__h { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 8px 8px 4px 20px; position: static; background: none; flex: none; }
.bang__t { font-size: var(--fs-h2); font-weight: 700; line-height: 1.3; margin: 0; min-width: 0; }
.bang__x { flex: none; }
.bang__b { padding: 4px 20px 20px; overflow: auto; overscroll-behavior: contain; -webkit-overflow-scrolling: touch; min-height: 0; display: grid; gap: 12px; align-content: start; }
.bang .fb__pb { padding: 0; }
.bang.dlg p, .bang.dlg h2 { margin-bottom: 0; } .bang .dlg__mt { color: var(--ink-2); }
.bang.dlg--pd { width: min(94vw, 480px); padding: 0; } .bang.dlg--pd .fb__ph { padding: 8px 8px 4px 20px; }
.bang--cu { position: fixed; z-index: 70; inset: 0; } /* trình duyệt không có showModal */
@keyframes bang-hien { from { opacity: 0; transform: translateY(8px) scale(.98); } }
@keyframes bang-an { to { opacity: 0; transform: translateY(8px) scale(.98); } }
@keyframes bang-nen { from { opacity: 0; } }
@keyframes bang-len { from { transform: translateY(100%); } }
@keyframes bang-xuong { to { transform: translateY(100%); } }

@media (max-width: 699px) {
  html.bang-mo { overflow: hidden; } /* khóa cuộn nền; vị trí cuộn giữ nguyên */
  .bang, .bang.dlg, .bang.dlg--pd, .bang.fb__pop { position: fixed; inset: auto 0 0 0; margin: 0; width: 100%; max-width: none; max-height: min(86vh, calc(100vh - 56px)); max-height: min(86dvh, calc(100dvh - 56px)); border-radius: 20px 20px 0 0; border: 0; padding: 0; top: auto; left: 0; overflow: hidden; z-index: auto; box-shadow: 0 -8px 30px rgba(8, 16, 30, .18); }
  .bang[open] { animation: bang-len .24s cubic-bezier(.2, .8, .2, 1) both; }
  .bang.is-dong { animation: bang-xuong .18s ease-in both; }
  .bang.is-keo { animation: none; transition: none; }
  .bang__tay { display: block; flex: none; height: 20px; touch-action: none; cursor: grab; position: relative; }
  .bang__tay::before { content: ""; position: absolute; left: 50%; top: 8px; width: 36px; height: 4px; margin-left: -18px; border-radius: 2px; background: var(--line); }
  .bang__h, .bang.dlg--pd .fb__ph { padding: 0 8px 4px 16px; touch-action: none; }
  .bang__h::before { content: none; }
  .bang__b { padding: 4px 16px calc(16px + env(safe-area-inset-bottom)); }
  .bang .row--end { justify-content: stretch; } .bang .row--end > .btn { flex: 1; min-height: 48px; }
}

/* ---------- Khung ứng dụng ---------- */
html { -webkit-tap-highlight-color: transparent; overflow-x: clip; }
body { overflow-x: clip; }
a, button, summary, label, input, select, textarea, [role="tab"], [role="radio"] { touch-action: manipulation; }
.bang:focus { outline: none; }
/* Nút nhỏ "lên đầu trang": chỉ hiện khi đã cuộn sâu (app.js bật/tắt thuộc tính hidden) */
.lendau { position: fixed; right: max(12px, env(safe-area-inset-right)); bottom: calc(var(--nav-h) + env(safe-area-inset-bottom) + 12px); z-index: 18; width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--line); background: var(--surface); color: var(--ink); box-shadow: var(--sh-2); display: grid; place-items: center; cursor: pointer; padding: 0; animation: bang-nen .2s ease-out both; }
.lendau:active { transform: scale(.94); }
body[data-man="trac-nghiem"] .lendau, body[data-man="ho-so"] .lendau, body[data-man="dang-ky"] .lendau { display: none; }
@media (min-width: 900px) { .lendau { right: 24px; bottom: 24px; } }
.sctx, .stabs, .rg__n { display: none; }
.chips--nhom .chip span span { display: inline; min-height: 0; padding: 0; border: 0; border-radius: 0; background: none; color: inherit; font: inherit; }
.chips--nhom .chip span .chip__gon { display: none; }
.ghimduoi { display: grid; gap: 8px; }
.ghimduoi:has(> .btn:only-child), .ghimduoi { justify-items: start; }
.page--form .ghimduoi { justify-items: stretch; }

/* Nhóm thu gọn được của hồ sơ. Từ 900px: luôn mở, tiêu đề là chữ thường. */
.hsg > summary { list-style: none; display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 52px; cursor: pointer; }
.hsg > summary::-webkit-details-marker { display: none; }
.hsg > summary h2 { margin: 0; }
.hsg > summary > .ic { color: var(--ink-2); transition: transform .2s; } .hsg[open] > summary > .ic { transform: rotate(180deg); }
.hsg__b { padding-bottom: 16px; }
@media (min-width: 900px) { .hsg > summary { pointer-events: none; cursor: default; min-height: 0; margin-bottom: 14px; } .hsg > summary > .ic { display: none; } .hsg__b { padding-bottom: 0; } }

@media (max-width: 899px) {
  html, body { overscroll-behavior-y: none; } /* chặn kéo giật ở hai đầu trang */
  input, select, textarea, .in, .in--sm2, .fb__diem { font-size: max(16px, 1rem); } /* không phóng to khi chạm ô nhập (iOS) */
  /* Phản hồi chạm tức thì */
  .bottom .nav__a:active .ic { transform: scale(.9); } .bottom .nav__a .ic { transition: transform .12s; }
  .fb__chip:active, .entry:active, .scard:active, .gcard:active, .saved a:active, .mrow:active, .stabs__a:active, .hs__k:active, .rc:has(.rc__link:active) { opacity: .72; }
  .hsg { border-bottom: 1px solid var(--line); }
  .hs .cols, .hs .cols > .stack, .hs form.stack { gap: 0; }
  .hs .ghimduoi { margin-top: 12px; }

  /* Thông báo nổi: luôn phía trên thanh dưới; màn có thanh ghim dưới (trắc nghiệm, biểu mẫu) thì cao hơn để không che nút chính */
  .toast { bottom: calc(var(--nav-h) + env(safe-area-inset-bottom) + 12px); width: max-content; }
  body[data-man="trac-nghiem"] .toast, body[data-man="ho-so"] .toast { bottom: calc(var(--nav-h) + env(safe-area-inset-bottom) + 84px); }

  /* Kết quả: thanh lọc và hàng tab ghim liền nhau, nền kín (không lộ nội dung qua khe) */
  .fb { top: calc(56px + env(safe-area-inset-top)); margin: -12px -16px 0; padding: 6px 16px; background: var(--bg); -webkit-backdrop-filter: none; backdrop-filter: none; }
  .tabs { top: calc(56px + 60px + env(safe-area-inset-top)); padding: 2px 0 8px; box-shadow: 0 -8px 0 var(--bg); gap: 6px; }

  /* Trang trường: thanh tiêu đề ghim thay thanh trên khi tên trường đã cuộn khuất */
  .sctx { position: fixed; top: 0; left: 0; right: 0; z-index: 24; height: calc(57px + env(safe-area-inset-top)); padding: env(safe-area-inset-top) max(12px, env(safe-area-inset-right)) 0 max(4px, env(safe-area-inset-left)); display: flex; align-items: center; gap: 4px; background: var(--surface); border-bottom: 1px solid var(--line); opacity: 0; transform: translateY(-6px); visibility: hidden; transition: opacity .18s ease-out, transform .18s ease-out, visibility 0s .18s; }
  .sctx.is-hien { opacity: 1; transform: none; visibility: visible; transition: opacity .18s ease-out, transform .18s ease-out, visibility 0s; }
  .sctx__b { flex: none; width: 44px; height: 44px; display: grid; place-items: center; color: var(--ink); border-radius: 50%; }
  .sctx__t { flex: 1; min-width: 0; display: grid; line-height: 1.25; }
  .sctx__t b { font-size: var(--fs-body); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .sctx__t span { font-size: var(--fs-nho); color: var(--ink-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .sctx__l { flex: none; min-height: 40px; }
  /* Thanh tab mục của trang trường: ghim ngay dưới thanh trên */
  .stabs { display: flex; gap: 4px; position: sticky; top: calc(56px + env(safe-area-inset-top)); z-index: 11; margin: -12px -16px -12px; padding: 6px 12px; background: var(--bg); border-bottom: 1px solid var(--line); overflow-x: auto; scrollbar-width: none; }
  .stabs::-webkit-scrollbar { display: none; }
  .stabs__a { flex: 1 0 auto; min-height: 44px; padding: 0 12px; border: 0; background: none; border-radius: 999px; font-weight: 700; font-size: var(--fs-meta); color: var(--ink-2); white-space: nowrap; cursor: pointer; }
  .stabs__a.is-on { background: var(--accent); color: var(--accent-ink); }
  /* KT5-01: html đã có scroll-padding-top 72px (app.css); cộng thêm đúng phần còn thiếu để tiêu đề mục dừng ngay dưới thanh trên 56px + thanh tab 57px */
  .smuc { scroll-margin-top: calc(48px + env(safe-area-inset-top)); }

  /* Nút lưu của biểu mẫu ghim trên thanh dưới (khi khung nhìn đủ cao, tức bàn phím không che) */
  .ghimduoi { justify-items: stretch; }
}
@media (max-width: 899px) and (min-height: 560px) {
  .ghimduoi { position: sticky; bottom: calc(var(--nav-h) + env(safe-area-inset-bottom)); z-index: 8; margin-left: -16px; margin-right: -16px; padding: 8px 16px; background: var(--bg); box-shadow: 0 -1px 0 var(--line); }
  .ghimduoi .btn { width: 100%; min-height: 48px; }
}

@media (max-width: 699px) {
  /* Bảng ngành trên điện thoại: mỗi ngành một hàng gọn (tên, điểm chuẩn gần nhất, xu hướng); chạm để mở bảng trượt chi tiết */
  .bangng .mtable tbody { gap: 0; }
  .bangng .mrow { position: relative; grid-template-columns: minmax(0, 1fr); gap: 0; padding: 0; background: none; border: 0; border-bottom: 1px solid var(--line); border-radius: 0; box-shadow: none; }
  .bangng .mrow td.mrow__ma, .bangng .mrow td[data-th="Nhóm"], .bangng .mrow td.num::before { display: none; }
  .bangng .mbtn { min-height: 0; padding: 10px 0 2px; color: var(--ink); }
  .bangng .mbtn .ic { display: none; }
  .bangng .mbtn::after { content: ""; position: absolute; inset: 0; }
  .bangng .mrow td.num { padding: 0 0 10px; }
  .bangng .mrow td.num b { color: var(--accent); }
  .bangng .mrow__xh { display: inline-block; margin: 0 0 0 8px; }
  .bangng .fbar--3 { grid-template-columns: 1fr 1fr; gap: 8px; }
  .bangng .fbar--3 .field:first-child { grid-column: 1 / -1; }
  .bangng .fbar--3 .field > label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
  .bang--nganh .mdetail { border-top: 0; padding-top: 0; }
}
@media (max-width: 699px) {
  .rg:not(.is-mo) { display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
  .rg__n { display: inline-flex; align-items: center; justify-self: start; min-height: 44px; margin: -8px 0; font-size: var(--fs-meta); }
  /* 16 nhóm ngành quan tâm ở hồ sơ: lưới chip gọn, tên ngắn (tên đủ nằm ở nhãn truy cập) */
  .chips--nhom .chip span .chip__dai { display: none; } .chips--nhom .chip span .chip__gon { display: inline; }
  .chips--nhom { gap: 6px; } .chips--nhom .chip > span { padding: 6px 12px; font-size: var(--fs-meta); }
  /* Bảng chọn vai trò: nội dung của khung nhỏ trên thanh đầu chuyển vào bảng trượt */
  .bang .vai2__p { position: static; width: auto; border: 0; box-shadow: none; padding: 0; background: none; }
  .bang .vai2__p > .meta:first-child { display: none; }
  .bang .who__b, .bang p { max-width: none; }
}

/* ---------- Rút chiều cao từng màn (điện thoại) ---------- */
@media (min-width: 390px) and (max-width: 479px) {
  /* Hàng tab mức: một dòng "An toàn 497" cao 44px thay cho hai dòng 52px (dưới 390px số bốn chữ số không vừa một dòng nên giữ hai dòng) */
  .tab { flex-direction: row; flex-wrap: wrap; align-content: center; gap: 0 6px; min-height: 44px; padding: 4px 2px; font-size: 0.9375rem; } .tab > span { white-space: nowrap; }
}
@media (max-width: 699px) {
  /* Trang trường: ba số liệu chính trên một hàng, nút Thêm nguyện vọng đủ chữ */
  .strang .stats--s { display: flex; flex-wrap: wrap; gap: 8px 20px; }
  .strang .stats--s .stat dt { max-width: 12ch; font-size: var(--fs-nho); }
  .shead .btn__dai { display: inline; }
  .strang { gap: 20px; }
  /* Dải nhắc xác minh email ở trang chủ: một dòng */
  .home2 .invite--xm { flex-wrap: nowrap; gap: 8px; padding: 2px 4px 2px 12px; min-height: 48px; }
  .home2 .invite--xm .invite__t { flex: 1 1 auto; min-width: 0; font-size: var(--fs-meta); font-weight: 400; display: flex; align-items: center; gap: 6px; }
  .home2 .invite--xm .invite__a { flex: none; }
}
@media (max-width: 899px) {
  /* Thanh trên, thanh dưới nền kín: không lộ nội dung cuộn bên dưới, cuộn nhẹ máy hơn (bỏ backdrop-filter) */
  .top { background: var(--surface); -webkit-backdrop-filter: none; backdrop-filter: none; }
  .bottom { background: var(--surface); -webkit-backdrop-filter: none; backdrop-filter: none; }
}
@media (max-width: 399px) { .home2 .invite--xm .invite__t .ic { display: none; } }
/* Tiêu điểm bàn phím không bị nút lưu ghim che (WCAG 2.4.11) */
@media (max-width: 899px) { .hs :focus-visible, .page--form :focus-visible { scroll-margin-bottom: calc(var(--nav-h) + 104px); } }
@media (max-width: 359px) { .stabs { padding: 6px 8px; gap: 2px; } .stabs__a { padding: 0 6px; font-size: var(--fs-nho); } }

/* Màn thấp (điện thoại xoay ngang, bàn phím ảo thu khung nhìn): chỉ giữ thanh trên và thanh dưới, các dải ghim khác trôi theo nội dung
   để phần ghim không chiếm quá nửa chiều cao */
@media (max-width: 899px) and (max-height: 480px) {
  .fb, .tabs, .stabs, .tickbar { position: static; }
  .tabs { box-shadow: none; }
  .bang, .bang.dlg, .bang.dlg--pd, .bang.fb__pop { max-height: calc(100vh - 16px); max-height: calc(100dvh - 16px); }
}
.mchart__h { color: var(--accent); font-size: var(--fs-body); line-height: 1.35; }

/* ===== Chỉnh chung mọi cỡ màn (11/11/2026): bỏ kiểu tô vàng nửa dòng, đếm ngược nổi hơn, lời nhắn nổi bật, lịch tuyển sinh ===== */
/* 1. Nhãn: viên thuốc vàng kín; con số: chỉ đổi màu chữ, không tô nền */
.entry__g, .gmp__lad li.is-now .gmp__ten { background: #ffd21f; color: #0d1b30; border-radius: 999px; padding: 2px 10px; font-weight: 700; }
.home2 .scope li:nth-child(2) .stat__n, .gso b + b, .gso span + b, .thap b { background: none; padding: 0; color: #b24a00; border-radius: 0; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .home2 .scope li:nth-child(2) .stat__n, :root:not([data-theme="light"]) .gso b + b, :root:not([data-theme="light"]) .gso span + b, :root:not([data-theme="light"]) .thap b { background: none; color: #ffb21f; }
  :root:not([data-theme="light"]) .entry__g, :root:not([data-theme="light"]) .gmp__lad li.is-now .gmp__ten { border-radius: 999px; }
}
:root[data-theme="dark"] .home2 .scope li:nth-child(2) .stat__n, :root[data-theme="dark"] .gso b + b, :root[data-theme="dark"] .gso span + b, :root[data-theme="dark"] .thap b { background: none; color: #ffb21f; }
:root[data-theme="dark"] .entry__g, :root[data-theme="dark"] .gmp__lad li.is-now .gmp__ten { border-radius: 999px; }
/* 2. Đếm ngược: tờ lịch nhỏ + số ngày lớn, bấm mở lịch */
.home2 .hd a.cd { display: inline-flex; align-items: center; gap: 12px; padding: 8px 14px 8px 8px; border-radius: 16px; background: rgba(255, 255, 255, .14); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .22); min-height: 56px; text-decoration: none; }
.home2 .hd a.cd:hover { background: rgba(255, 255, 255, .22); text-decoration: none; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .4); }
.cd__la { order: -1; flex: none; width: 44px; height: 46px; border-radius: 10px; background: #fff; color: #0d1b30; display: grid; grid-template-rows: 16px 1fr; overflow: hidden; text-align: center; box-shadow: 0 4px 10px rgba(7, 26, 59, .3); }
.cd__la span { background: #ff8a1f; color: #0d1b30; font-size: 0.6875rem; font-weight: 700; line-height: 16px; }
.cd__la b, .home2 .hd a.cd .cd__la b { background: none; color: #0d1b30; padding: 0; border-radius: 0; font-size: 1.25rem; font-weight: 800; line-height: 30px; }
.cd__c { display: grid; gap: 1px; min-width: 0; text-align: left; }
.cd__n { font-size: 1.125rem; font-weight: 700; line-height: 1.25; color: #fff; }
.home2 .hd a.cd .cd__n b { background: none; color: #ffd21f; padding: 0; font-size: 1.5rem; font-weight: 800; }
.cd__d { font-size: var(--fs-meta); color: rgba(255, 255, 255, .9); line-height: 1.35; }
.home2 .hd .cd__s { display: inline; color: rgba(255, 255, 255, .9); }
@media (max-width: 480px) { .home2 .hd a.cd { padding-right: 12px; max-width: calc(100% - 72px); } .home2 .hd a.cd, .home2 .hd .hd__t { padding-right: 12px; } .home2 .hd .hd__t { padding-right: 72px; } }
/* 3. Lời nhắn hôm nay: chữ có chân, nghiêng, lớn, có dấu ngoặc kép vàng */
.home2 .hd .hd__loi { position: relative; font-family: Georgia, "Noto Serif", "Times New Roman", serif; font-style: italic; font-size: 1.3125rem; line-height: 1.4; font-weight: 400; color: #fff; padding-left: 34px; max-width: 30em; }
.home2 .hd .hd__loi::before { content: "\201C"; position: absolute; left: 0; top: -6px; font-size: 3.25rem; line-height: 1; color: #ffd21f; font-style: normal; font-family: Georgia, "Times New Roman", serif; }
.home2 .hd .hd__loi:empty { display: none; }
@media (max-width: 480px) { .home2 .hd .hd__loi { font-size: 1.1875rem; padding-left: 28px; } .home2 .hd .hd__loi::before { font-size: 2.75rem; } }
/* 4. Lịch tuyển sinh */
.lich { display: grid; gap: 22px; }
.lich__thang { display: grid; gap: 10px; }
.lich__ten { margin: 0; font-size: var(--fs-h2); font-weight: 800; color: var(--accent); } .lich__ten span { color: var(--ink-2); font-weight: 400; }
.lich__luoi { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 4px; max-width: 420px; }
.lich__thu { text-align: center; font-size: var(--fs-nho); color: var(--ink-2); padding: 2px 0; }
.lich__o { display: grid; place-items: center; aspect-ratio: 1; border-radius: 50%; font-size: var(--fs-meta); font-variant-numeric: tabular-nums; color: var(--ink); }
.lich__o--khoang { background: #fff1b8; color: #0d1b30; border-radius: 10px; }
.lich__o--moc { background: #ffd21f; color: #0d1b30; font-weight: 700; }
.lich__o--thi { background: #ff8a1f; color: #0d1b30; font-weight: 800; }
.lich__o--nay { box-shadow: 0 0 0 2px var(--accent); }
.lich__ds { display: grid; gap: 8px; padding: 0; }
.lich__muc { display: grid; gap: 2px; padding: 8px 12px; border-radius: 12px; background: var(--surface-2); }
.lich__muc--thi { background: #ffe3c4; color: #0d1b30; }
.lich__muc--qua { opacity: .6; }
.lich__khi { font-size: var(--fs-meta); font-weight: 700; color: var(--accent); } .lich__muc--thi .lich__khi { color: #8a3a00; }
.lich__gi { font-size: var(--fs-body); line-height: 1.4; } .lich__muc--thi .lich__gi { color: #0d1b30; }
.lich__chu { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 8px; margin: 0; font-size: var(--fs-meta); color: var(--ink-2); }
.lich__o--mau { width: 16px; height: 16px; aspect-ratio: auto; margin-left: 8px; } .lich__o--mau:first-child { margin-left: 0; }
/* Dưới 600px: ngày dự kiến đã có trên tờ lịch nhỏ nên ẩn phần chữ lặp lại, giữ khối mở đầu thấp để ba lối vào nằm trong màn đầu */
@media (max-width: 599px) { .home2 .hd .cd__s { display: none; } .home2 .hd a.cd { min-height: 52px; padding: 6px 12px 6px 6px; } .cd__n { font-size: 1rem; } .home2 .hd a.cd .cd__n b { font-size: 1.3125rem; } .home2 .hd .hd__loi { font-size: 1.125rem; line-height: 1.35; } }
@media (min-width: 900px) { .home2 .hd .hd__loi { font-size: 1.625rem; padding-left: 44px; } .home2 .hd .hd__loi::before { font-size: 4rem; top: -8px; } }
.lich__o--hoc { background: var(--accent); color: #fff; font-weight: 700; }
.lich__muc--hoc { background: var(--accent-soft); } .lich__gc { margin: 0; font-size: var(--fs-meta); color: var(--ink-2); }
/* Khối đầu trang (trang chủ, huy hiệu, hồ sơ): bỏ chấm bi, nền chuyển màu sạch với hai vệt sáng mềm ở góc */
.home2 .hd, .gmp__hd, .hs__hd {
  background:
    radial-gradient(55% 75% at 100% 0%, rgba(255, 210, 31, .30), rgba(255, 210, 31, 0) 62%),
    radial-gradient(60% 80% at 0% 100%, rgba(64, 140, 255, .55), rgba(64, 140, 255, 0) 65%),
    linear-gradient(135deg, #1765f0 0%, #1257d6 42%, #0b3585 100%);
}
.lich__thang { scroll-margin-top: 8px; } .lich__luoi { max-width: 380px; }

/* Khi quay lại: lời chào thành dòng nhỏ, lời nhắn hôm nay là chữ chính (đậm, lớn) */
.home2 .hd .hd__t--nho { font-size: 1rem; font-weight: 600; letter-spacing: 0; line-height: 1.4; color: rgba(255, 255, 255, .88); }
.home2 .hd .hd__loi { font-family: var(--font); font-style: normal; font-weight: 700; font-size: 1.75rem; line-height: 1.25; letter-spacing: -0.015em; padding-left: 40px; max-width: 22em; text-wrap: balance; }
.home2 .hd .hd__loi::before { font-size: 4rem; top: -4px; }
@media (min-width: 900px) { .home2 .hd .hd__loi { font-size: 2rem; padding-left: 48px; } .home2 .hd .hd__loi::before { font-size: 4.5rem; top: -6px; } }
@media (max-width: 599px) { .home2 .hd .hd__loi { font-size: 1.375rem; line-height: 1.3; padding-left: 30px; } .home2 .hd .hd__loi::before { font-size: 3rem; top: -2px; } }
/* Thắng quy tắc gom thang chữ cũ (.page.home2 .hd .hd__sub) */
.page.home2 .hd .hd__loi { font-size: 1.75rem; font-weight: 700; }
@media (min-width: 900px) { .page.home2 .hd .hd__loi { font-size: 2rem; } }
@media (max-width: 599px) { .page.home2 .hd .hd__loi { font-size: 1.375rem; } }
@media (max-width: 599px) { .home2 .hd { padding-top: 14px; padding-bottom: 14px; } .home2 .hd .hd__l { gap: 6px; } .home2 .hd a.cd { min-height: 48px; } }

/* Lời nhắn: in nghiêng, có ngoặc kép đóng */
.home2 .hd .hd__loi { font-style: italic; }
.home2 .hd .hd__loi::before { font-style: normal; }
.home2 .hd .hd__loi::after { content: "\201D"; font-family: Georgia, "Times New Roman", serif; font-style: normal; color: #ffd21f; font-size: 1.6em; line-height: 0; margin-left: 6px; vertical-align: -0.28em; }

/* ===== Khối đầu trang chủ sắp lại theo thứ tự đọc (11/11/2026): chào, lời nhắn, hành trình và bước tiếp theo, rồi hai ô theo dõi ===== */
/* Hai dấu ngoặc kép cùng cỡ, đi liền với chữ */
.page.home2 .hd .hd__loi { padding-left: 0; }
.page.home2 .hd .hd__loi::before, .page.home2 .hd .hd__loi::after { position: static; display: inline; font-family: Georgia, "Times New Roman", serif; font-style: normal; font-size: 1.5em; line-height: 0; vertical-align: -0.3em; color: #ffd21f; top: auto; left: auto; }
.page.home2 .hd .hd__loi::before { content: "\201C"; margin: 0 6px 0 0; }
.page.home2 .hd .hd__loi::after { content: "\201D"; margin: 0 0 0 6px; }
/* Hai ô theo dõi cùng một kiểu: ngày thi (mở lịch) và danh hiệu (mở huy hiệu) */
.hd__tin { display: flex; flex-wrap: wrap; gap: 8px 10px; width: 100%; margin-top: 4px; }
.home2 .hd .hd__tin a.cd, .home2 .hd .hd__tin .gm { display: inline-flex; align-items: center; gap: 10px; min-height: 52px; padding: 6px 14px 6px 8px; border-radius: 16px; background: rgba(255, 255, 255, .14); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .22); text-decoration: none; color: #fff; max-width: 100%; flex-wrap: nowrap; }
.home2 .hd .hd__tin a.cd:hover, .home2 .hd .hd__tin .gm:hover { background: rgba(255, 255, 255, .22); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .4); }
.home2 .hd .hd__tin .gm:hover .gm__d { text-decoration: none; }
.home2 .hd .hd__tin .gm__em { width: 40px; height: 40px; }
.gm__hh { font-size: var(--fs-meta); color: rgba(255, 255, 255, .9); } .gm__hh b { font-weight: 800; font-size: var(--fs-body); color: #fff; }
.home2 .hd .hd__tin .gm__d { color: rgba(255, 255, 255, .9); } .home2 .hd .hd__tin .gm__d b { color: #fff; }
.home2 .hd .stp { margin-top: 2px; }
@media (max-width: 599px) {
  .home2 .hd .hd__tin a.cd, .home2 .hd .hd__tin .gm { width: 100%; min-height: 48px; padding-right: 12px; }
  .home2 .hd .hd__t { padding-right: 60px; } .home2 .hd .hd__t--nho { min-height: 40px; display: flex; align-items: center; }
  .home2 .hd__art { width: 44px; height: 44px; right: 14px; top: 12px; box-shadow: 0 0 0 5px rgba(255, 210, 31, .22); } .home2 .hd__art .dom { width: 42px; height: 42px; }
  .cd__la { width: 38px; height: 40px; grid-template-rows: 14px 1fr; } .cd__la span { font-size: 0.625rem; line-height: 14px; } .cd__la b, .home2 .hd a.cd .cd__la b { font-size: 1.0625rem; line-height: 26px; }
  .home2 .hd .hd__tin .gm { gap: 8px; } .home2 .hd .hd__tin .gm__em { width: 34px; height: 34px; }
}
/* Thanh điều hướng dưới: nội dung mờ dần khi chạm thanh, không bị cắt ngang chữ */
@media (max-width: 899px) { .bottom::before { content: ""; position: absolute; left: 0; right: 0; bottom: 100%; height: 28px; background: linear-gradient(to top, var(--bg), transparent); pointer-events: none; } }
/* Ngoặc kép dùng cùng phông chính (hai dấu đối xứng, cùng cỡ) */
.page.home2 .hd .hd__loi::before, .page.home2 .hd .hd__loi::after { font-family: var(--font); font-weight: 800; font-size: 1.35em; line-height: 0; vertical-align: -0.18em; }
/* Ô danh hiệu: chữ không rớt dòng; màn rất hẹp thì cho xuống hàng gọn */
.home2 .hd .hd__tin .gm > * { white-space: nowrap; flex: none; }
.home2 .hd .hd__tin .gm__d, .gm__hh { font-size: 0.8125rem; } .home2 .hd .hd__tin .gm__d b, .gm__hh b { font-size: 0.9375rem; }
.home2 .hd .hd__tin .gm__cap { padding: 3px 10px; }
@media (max-width: 599px) { .home2 .hd .hd__tin .gm { flex-wrap: wrap; row-gap: 2px; } }

/* Trang chủ trên màn rộng: lối vào bên trái, gợi ý bên phải (khi có gợi ý) */
.hm2 { display: grid; gap: 20px; }
.hm2__a { display: grid; gap: 14px; align-content: start; min-width: 0; } .hm2__b { min-width: 0; }
@media (min-width: 900px) {
  .hm2:has(.hm2__b .sec) { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 40px; align-items: start; }
  .hm2:has(.hm2__b .sec) .entries { grid-template-columns: minmax(0, 1fr); gap: 0; }
  .hm2:has(.hm2__b .sec) .entries .entry:nth-child(n) { flex-direction: row; align-items: center; gap: 16px; padding: 14px 0; border-top: 1px solid var(--line); }
  .hm2:has(.hm2__b .sec) .entries .entry:nth-child(1) { border-top: 0; }
  .hm2:has(.hm2__b .sec) .entries .entry:nth-child(n) .entry__i { width: 52px; height: 52px; }
  .hm2:has(.hm2__b .sec) .entries .entry__g { position: static; }
  .hm2:has(.hm2__b .sec) .hd__q { margin-top: 0; }
  .hm2__b .sec { margin-top: 0; } .hm2__b .sec > h2 { margin-top: 0; font-size: 1.25rem; color: var(--accent); }
}
@media (min-width: 900px) {
  /* Khối đầu trang thấp lại để gợi ý lọt vào màn hình đầu: chữ dùng trọn bề ngang, hai ô theo dõi nằm một hàng, hình Đomđóm nhỏ hơn */
  .home2 .hd { grid-template-columns: minmax(0, 1fr) auto; padding: 26px 36px; min-height: 0; gap: 32px; }
  .home2 .hd .hd__l { gap: 12px; }
  .home2 .hd__art { width: 176px; height: 176px; margin-right: 12px; } .home2 .hd__art .dom { width: 160px; height: 160px; }
  .home2 .hd .hd__tin { flex-wrap: nowrap; } .home2 .hd .hd__tin a.cd, .home2 .hd .hd__tin .gm { flex: 0 1 auto; }
  .page.home2 .hd .hd__loi { max-width: 26em; }
  .home2 .hm2 { margin-top: 4px; }
  .hm2__b .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* ===== Sửa sau kiểm toán vòng 5 ===== */
/* KT5-03: bảng lọc mở trên điện thoại rồi xoay ngang (từ 700px): bỏ vị trí của khung nổi cũ (.fb__pop trong app.css), đặt giữa màn như mọi bảng khác */
@media (min-width: 700px) {
  dialog.bang.fb__pop { inset: 0; top: 0; left: 0; margin: auto; width: min(92vw, 480px); height: fit-content; max-height: min(86vh, 720px); overflow: hidden; border: 0; border-radius: var(--r); animation: bang-hien .18s ease-out both; z-index: auto; }
}
@media (min-width: 700px) and (max-height: 480px) { dialog.bang, dialog.bang.fb__pop { max-height: calc(100vh - 16px); max-height: calc(100dvh - 16px); } }
/* KT5-06: cỡ chữ hệ thống lớn trên màn hẹp: chữ hai nút ở thanh trên không lớn quá bề ngang cho phép (ở cỡ chữ mặc định không đổi gì) */
@media (min-width: 360px) and (max-width: 599px) {
  .vai2 > summary { font-size: min(var(--fs-meta), 3.9vw); }
  .top__acc { font-size: min(var(--fs-body), 4.45vw); }
}
@media (max-width: 359px) { .vai2 > summary { font-size: min(var(--fs-nho), 3.75vw); } .top__acc { font-size: min(var(--fs-body), 5vw); } }
/* Soát phần mới (trang chủ, lịch) sau vòng 5 */
/* Mốc đã qua trong lịch: không làm mờ cả khối (chữ mất tương phản), chỉ đổi chữ sang màu phụ */
.lich__muc--qua { opacity: 1; }
.lich__muc--qua .lich__khi, .lich__muc--qua .lich__gi { color: var(--ink-2); font-weight: 400; }
.lich__muc--thi.lich__muc--qua .lich__khi, .lich__muc--thi.lich__muc--qua .lich__gi { color: #5a4630; }
.bang__b:focus-visible { outline-offset: -3px; }
/* Khách mới ở màn 360px: khối đầu trang và ba lối vào sát lại vài điểm ảnh để lối vào thứ ba nằm trọn trên thanh dưới (bố cục, câu chữ giữ nguyên) */
@media (max-width: 379px) {
  .home2 .hd { padding-top: 10px; padding-bottom: 10px; } .home2 .hd .hd__l { gap: 4px; }
  .home2.page { gap: 12px; } .home2 .hm2 { gap: 12px; } .home2 .hm2__a { gap: 6px; }
  .page.home2 .entries .entry:nth-child(n) { padding-top: 8px; padding-bottom: 8px; min-height: 68px; }
}

/* Lịch: khoảng ước tính (kiểm tra giữa kỳ, cuối kỳ) viền đứt để phân biệt với mốc chính thức */
.lich__o--uoc { outline: 1.5px dashed #5b8fe6; outline-offset: -2px; border-radius: 10px; color: #0d1b30; background: #eef4ff; }
.lich__muc--uoc .lich__khi { font-style: italic; }
/* Màn rộng, lối vào xếp dọc bên trái: ba hàng cao bằng nhau (hàng có nhãn "Gợi ý lúc này" không cao hơn hai hàng kia) */
@media (min-width: 900px) { .hm2:has(.hm2__b .sec) .entries .entry:nth-child(n) { box-sizing: border-box; height: 84px; min-height: 84px; padding-top: 0; padding-bottom: 0; } }
/* Tờ lịch nhỏ ở ô đếm ngược: chữ tháng không nhỏ hơn 12px */
.cd__la span { font-size: 0.75rem; }
@media (max-width: 599px) { .cd__la span { font-size: 0.75rem; line-height: 14px; } }
.lich__o--hoc { color: var(--accent-ink); } /* chế độ tối: nền xanh nhạt cần chữ tối */

/* Màn chật: thu gọn khối đầu trang để ba lối vào nằm trong màn đầu (đã duyệt 11/11/2026). Câu chữ và thứ tự giữ nguyên. */
@media (max-width: 379px) {
  .page.home2 .hd .hd__t:not(.hd__t--nho) { font-size: 1.3125rem; line-height: 1.2; }
  .page.home2 .hd .hd__loi { font-size: 1.125rem; line-height: 1.25; }
  .home2 .hd .hd__tin { gap: 6px; margin-top: 2px; } .home2 .hd .hd__tin a.cd, .home2 .hd .hd__tin .gm { min-height: 44px; padding-top: 4px; padding-bottom: 4px; }
}
@media (min-width: 900px) and (max-height: 820px) {
  .home2 .hd { padding-top: 18px; padding-bottom: 18px; } .home2 .hd .hd__l { gap: 8px; }
  .page.home2 .hd .hd__loi { font-size: 1.625rem; }
  .home2.page { gap: 16px; } .home2 .hm2 { row-gap: 12px; }
  .hm2:has(.hm2__b .sec) .entries .entry:nth-child(n) { height: 72px; min-height: 72px; }
  .hm2:has(.hm2__b .sec) .entries .entry:nth-child(n) .entry__i { width: 46px; height: 46px; }
}
