/**
 * Thư viện đề HSK (/thi-hsk/) + TOEIC (/thi-toeic/) — dựng trên khung thư viện IELTS (public/css/pages/library.css, lớp .lib-*).
 * Tệp này chỉ thêm phần riêng (tiền tố .tvd-): ô 田字格 một chữ, hàng nút «Thi thử / Luyện tập», dòng lượt thi của bạn, khối kết quả.
 * Nền tối + giao diện khối (skeuo) của .lib-* đã có sẵn trong dark-mode.css / site-skeuo.css (bám theo tên lớp) ⇒ ăn theo.
 * Nạp ở hsk/hsk-main.php + toeic/toeic-main.php (wp_enqueue_scripts, priority 100 — in SAU dark-mode + site-skeuo).
 */

/* ── nhóm đề: mỗi nhóm một khối .lib-skills, khoảng cách gọn hơn trang IELTS ── */
.tvd-trang .lib-skills { padding: 26px 0 18px; }
.tvd-trang .lib-skills + .lib-skills { padding-top: 6px; }
.tvd-trang .lib-skills:last-of-type { padding-bottom: 56px; }
.tvd-trang .lib-section-head { margin-bottom: 26px; }
.tvd-trang .lib-section-title { scroll-margin-top: 140px; }
.tvd-trang .lib-stat { text-decoration: none; }
.tvd-trang .lib-stats--5 { grid-template-columns: repeat(5, minmax(0, 1fr)); }
@media (max-width: 1199px) { .tvd-trang .lib-stats--5 { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 575px) { .tvd-trang .lib-stats--5 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* ── ô giấy tập viết 田字格 một chữ (đã duyệt 12/10: thay ô đỏ / tím) ── */
.tvd-o {
    position: relative;
    background: var(--lib-card, #fff) !important;
    border: 1px solid color-mix(in srgb, var(--skill-color, #1d1d1f) 34%, var(--lib-border, #d2d2d7));
    border-radius: 8px !important;
    color: var(--lib-text, #1d1d1f) !important;
}
.tvd-o::before, .tvd-o::after {
    content: "";
    position: absolute;
    pointer-events: none;
    border: 0 dashed color-mix(in srgb, var(--skill-color, #1d1d1f) 30%, transparent);
}
.tvd-o::before { left: 50%; top: 4px; bottom: 4px; border-left-width: 1px; }
.tvd-o::after { top: 50%; left: 4px; right: 4px; border-top-width: 1px; }
.tvd-han {
    position: relative;
    font-family: "Noto Serif SC", "Songti SC", "STSong", "SimSun", serif;
    font-weight: 700;
    line-height: 1;
    font-size: 30px;
    color: var(--lib-text, #1d1d1f);
}
.lib-hero-icon.tvd-o { width: 84px; height: 84px; }
.lib-hero-icon.tvd-o .tvd-han { font-size: 46px; }
.lib-hero-icon.tvd-o::before { top: 6px; bottom: 6px; }
.lib-hero-icon.tvd-o::after { left: 6px; right: 6px; }
/* ô chữ Latin (TOEIC: «L&R»): không kẻ chữ thập */
.tvd-o--chu::before, .tvd-o--chu::after { display: none; }
.tvd-o--chu .tvd-han { font-family: inherit; font-size: 17px; font-weight: 800; letter-spacing: -.01em; }

/* ── thẻ đề ── */
.tvd-the .lib-skill-count { font-weight: 600; }
.tvd-the .lib-skill-desc { margin-bottom: 14px; color: var(--lib-text); }
.tvd-the .lib-skill-desc span { color: var(--lib-muted); }
.tvd-han-nho { font-family: "PingFang SC", "Noto Sans SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif; }
/* chip phần thi: cùng dáng .lib-skill-parts li a nhưng không bấm */
.tvd-the .lib-skill-parts li > span {
    display: inline-block;
    padding: 6px 12px;
    background: color-mix(in srgb, var(--skill-color, var(--lib-primary)) 8%, transparent);
    color: var(--skill-color, var(--lib-primary));
    border-radius: 999px;
    font-size: 13px;
    font-weight: 600;
}
.tvd-the .lib-skill-parts li > span b { font-weight: 800; }

/* lượt thi của bạn trong thẻ */
.tvd-the .lib-skill-preview { margin-bottom: 16px; }
.tvd-luot li { display: flex; align-items: baseline; gap: 8px; }
.tvd-luot li a { flex: 1 1 auto; display: flex !important; align-items: baseline; gap: 8px; min-width: 0; }
.tvd-ngay { color: var(--lib-muted); font-size: 13px; font-variant-numeric: tabular-nums; flex: 0 0 auto; }
.tvd-diem { font-weight: 800; font-variant-numeric: tabular-nums; }
.tvd-diem small { font-weight: 600; color: var(--lib-muted); font-size: 12px; }
.tvd-kl { margin-left: auto; flex: 0 0 auto; padding: 2px 9px; border-radius: 999px; font-size: 12px; font-weight: 700; background: color-mix(in srgb, var(--lib-muted) 14%, transparent); color: var(--lib-muted); }
.tvd-kl--dat { background: #e3f6ea; color: #157a3e; }
.tvd-kl--cho, .tvd-kl--tuy { background: #fff3d6; color: #8a5a00; }
.tvd-chua { color: var(--lib-muted); font-size: 14px; margin: 0; }
.tvd-them { display: inline-block; margin-top: 6px; font-size: 13px; color: var(--lib-muted); }

/* hàng nút: «Thi thử →» (nút đen như IELTS) + «Luyện tập» (viền) */
.tvd-nut { margin-top: auto; display: flex; gap: 8px; }
.tvd-nut .lib-skill-cta { flex: 1 1 auto; margin-top: 0; }
.tvd-phu {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 16px;
    border-radius: 20px;
    border: 1px solid var(--lib-border);
    background: var(--lib-card);
    color: var(--lib-text) !important;
    font-weight: 600;
    font-size: 15px;
    text-decoration: none;
    transition: border-color .2s ease, transform .2s ease;
}
.tvd-phu:hover { border-color: var(--skill-color, var(--lib-text)); transform: translateY(-1px); }

/* thẻ thông tin (cách tính điểm…) — không có nút, danh sách gạch đầu dòng bằng dấu ✓ */
.tvd-the--tt .lib-skill-preview li { display: flex; gap: 8px; align-items: flex-start; color: var(--lib-text); }
.tvd-the--tt .lib-skill-preview li i { color: var(--skill-color); margin-top: 4px; }
.tvd-the--tt .lib-skill-preview li b { font-variant-numeric: tabular-nums; }

/* ── khối «Kết quả của bạn»: một thẻ rộng, mỗi lượt một hàng ── */
.tvd-kq { grid-column: 1 / -1; }
.tvd-kq-ds { list-style: none; margin: 0 0 18px; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 28px; }
.tvd-kq-ds li { border-bottom: 1px dashed var(--lib-border); }
.tvd-kq-ds a { display: flex; align-items: center; gap: 12px; padding: 11px 0; text-decoration: none; color: var(--lib-text); min-width: 0; }
.tvd-kq-ds a:hover .tvd-kq-ten { color: var(--skill-color, var(--lib-primary)); }
.tvd-kq-ds .tvd-o { flex: 0 0 auto; width: 40px; height: 40px; display: grid; place-items: center; }
.tvd-kq-ds .tvd-o .tvd-han { font-size: 21px; }
.tvd-kq-ds .tvd-o--chu .tvd-han { font-size: 12px; }
.tvd-kq-ten { flex: 1 1 auto; min-width: 0; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; transition: color .2s ease; }
.tvd-kq-ten small { display: block; font-weight: 500; color: var(--lib-muted); font-size: 13px; }
.tvd-kq .tvd-nut { justify-content: flex-start; }
.tvd-kq .tvd-nut .lib-skill-cta { flex: 0 0 auto; padding-left: 26px; padding-right: 26px; }
/* soát 13/10: «1fr» = minmax(auto, 1fr) ⇒ tên lượt nowrap đẩy cột rộng hơn thẻ (390: hàng TOEIC 406 px, nhãn «L · R» bị cắt) ⇒ minmax(0, 1fr) */
@media (max-width: 767px) { .tvd-kq-ds { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 575px) { .tvd-kq-ten small { white-space: normal; } }   /* điểm 3 chữ số ⇒ ngày giờ xuống dòng thay vì bị cắt «19:» */

/* tờ ghi chú ghim (dùng lại .lib-classic của IELTS): chỉ đổi con tem */
.tvd-trang .lib-classic-stamp-emoji { font-family: "Noto Serif SC", "Songti SC", serif; font-weight: 700; }

/* trống: tài khoản chưa được mở đề nào */
.tvd-trong { text-align: center; padding: 28px 22px; }
.tvd-trong p { color: var(--lib-muted); margin: 0 auto 16px; max-width: 520px; }

/* ── nền tối ── */
html.ae-dark-mode .tvd-o { background: #1c1d21 !important; }
html.ae-dark-mode .tvd-han { color: #f2f2f4; }
html.ae-dark-mode .tvd-phu { background: transparent; border-color: rgba(255, 255, 255, .18); color: #f2f2f4 !important; }
html.ae-dark-mode .tvd-kl--dat { background: rgba(52, 199, 89, .16); color: #6ee08f; }
html.ae-dark-mode .tvd-kl--cho, html.ae-dark-mode .tvd-kl--tuy { background: rgba(255, 196, 0, .14); color: #ffd36b; }
html.ae-dark-mode .tvd-kq-ds a, html.ae-dark-mode .tvd-the .lib-skill-desc { color: #e9e9ec; }
html.ae-dark-mode .tvd-the--tt .lib-skill-preview li { color: #e9e9ec; }

/* ── giao diện khối (skeuo): ô 田字格 thành giấy kem như trang lịch sử HSK ── */
html.theme-skeuo .tvd-o { background: linear-gradient(180deg, #fffefb, #f6efdd) !important; border-color: #d9c9a3; box-shadow: inset 0 1px 0 #fff, 0 1px 2px rgba(80, 60, 20, .15); }
html.theme-skeuo.ae-dark-mode .tvd-o { background: linear-gradient(180deg, #3a3127, #2c241b) !important; border-color: rgba(255, 214, 150, .22); box-shadow: inset 0 1px 0 rgba(255, 236, 200, .08); }
html.theme-skeuo .tvd-phu { background: linear-gradient(180deg, #fffefb, #f3ecdb); border-color: #d6c59c; }
html.theme-skeuo.ae-dark-mode .tvd-phu { background: linear-gradient(180deg, #3a3127, #2c241b); border-color: rgba(255, 214, 150, .22); }

/* ── điện thoại ── */
@media (max-width: 575px) {
    .tvd-trang .lib-skill-card { padding: 22px 18px; }
    .tvd-nut { flex-wrap: wrap; }
    .tvd-nut .lib-skill-cta, .tvd-phu { flex: 1 1 140px; }
    .lib-hero-icon.tvd-o { width: 72px; height: 72px; }
    .lib-hero-icon.tvd-o .tvd-han { font-size: 40px; }
}

/* ── dark-mode.css có luật chung «html.ae-dark-mode a[href*="tai-khoan"]» (cho nút trên header) xoá nền + viền + bóng của MỌI link
   tới /tai-khoan/… ⇒ ô số liệu, tờ ghi chú ghim, nút đen trỏ sang lịch sử thi (/tai-khoan/lich-su-hsk|toeic/) mất nền.
   Trả lại đúng giá trị dark-mode.css đặt cho .lib-stat / .lib-classic / .lib-skill-cta (độ ưu tiên cao hơn luật chung). ── */
html.ae-dark-mode:not(.theme-skeuo) .tvd-trang a.lib-stat[href*="tai-khoan"] {
    background: var(--dm-bg-card) !important;
    border: 1px solid var(--dm-border) !important;
}
html.ae-dark-mode:not(.theme-skeuo) .tvd-trang a.lib-stat[href*="tai-khoan"]:hover {
    background: var(--dm-bg-hover) !important;
    border-color: var(--skill-color, var(--lib-primary)) !important;
}
html.ae-dark-mode .tvd-trang a.lib-classic[href*="tai-khoan"] {
    border: 1px solid #3a3128 !important;
    color: #f5e6c4 !important;
    background-image: linear-gradient(rgba(252, 211, 77, .045) 1px, transparent 1px) !important;
    background-size: 100% 14px !important;
    box-shadow: 0 1px 2px rgba(0, 0, 0, .4), 0 8px 20px -4px rgba(0, 0, 0, .55), 0 22px 38px -10px rgba(0, 0, 0, .45), inset 0 1px 0 rgba(252, 211, 77, .05) !important;
}
html.ae-dark-mode .tvd-trang a.lib-skill-cta[href*="tai-khoan"] { background: #fff !important; }
html.ae-dark-mode .tvd-trang a.lib-skill-cta[href*="tai-khoan"],
html.ae-dark-mode .tvd-trang a.lib-skill-cta[href*="tai-khoan"] span,
html.ae-dark-mode .tvd-trang a.lib-skill-cta[href*="tai-khoan"] i { color: #000 !important; }
html.ae-dark-mode .tvd-trang a.lib-skill-cta[href*="tai-khoan"]:hover { background: #e0e0e0 !important; }
html.theme-skeuo.ae-dark-mode .tvd-trang a.lib-skill-cta[href*="tai-khoan"] { box-shadow: inset 0 1px 0 rgba(255, 255, 255, .18), 0 2px 6px rgba(0, 0, 0, .32) !important; }

/* ── 13/10: nền SKEUO dùng kiểu A «ô mực» (anh: «kiểu C nhưng A cho skeuo») — ô sơn mài đen bóng, chữ kem «五级»; nền phẳng giữ 田字格 ── */
html.theme-skeuo .tvd-o{ background:linear-gradient(180deg,#45454a 0%,#1d1d21 49%,#0b0b0d 50%,#17171a 100%) !important; border:1px solid #050506 !important; border-radius:12px !important;
  box-shadow:inset 0 1px 0 rgba(255,255,255,.3),inset 0 -1px 0 rgba(255,255,255,.06),0 1px 1px rgba(0,0,0,.35),0 3px 6px -2px rgba(40,25,10,.45) !important; }
html.theme-skeuo.ae-dark-mode .tvd-o{ border-color:rgba(214,170,98,.55) !important; box-shadow:inset 0 1px 0 rgba(255,255,255,.22),0 2px 6px rgba(0,0,0,.6) !important; }
html.theme-skeuo .tvd-o::before, html.theme-skeuo .tvd-o::after{ display:none !important; }
html.theme-skeuo .tvd-o .tvd-han{ color:#FFF8EA !important; text-shadow:0 -1px 0 rgba(0,0,0,.7); font-family:"PingFang SC","Noto Sans SC","Hiragino Sans GB","Microsoft YaHei",sans-serif !important; font-weight:700; letter-spacing:.02em; }
html.theme-skeuo.ae-dark-mode .tvd-o .tvd-han{ color:#F3DDB0 !important; }
html.theme-skeuo .tvd-o .tvd-han{ font-size:19px; }
html.theme-skeuo .tvd-o--cap .tvd-han::after{ content:"级"; }
html.theme-skeuo .lib-hero-icon.tvd-o .tvd-han{ font-size:38px; }
html.theme-skeuo .tvd-o--chu .tvd-han{ font-family:inherit !important; font-size:16px; font-weight:800; }
html.theme-skeuo .tvd-kq-ds .tvd-o .tvd-han{ font-size:12px; }

/* ═══════════════════════════════════════════════════════════════════════════
   13/10 — PHÂN LOẠI THEO CẤP + BỘ ĐỀ (cùng cách dùng trang kỹ năng IELTS /de-reading/)
   Markup: partials/thu-vien-hsk-toeic/class-tvd-loc.php (thanh lọc) + hsk|toeic/templates/danh-sach.php (thẻ cấp, bộ đề,
   thẻ đề gọn). Bảng màu = đúng token của bộ lọc IELTS (public/css/alpha-loc-de.css, --l-*): phẳng mực đen, tối, skeuo
   giấy kem + gel xanh Aqua, skeuo tối gỗ + gel đồng. Nhấn = tô đặc ô đang chọn, không khung tô màu + viền màu.
   ═══════════════════════════════════════════════════════════════════════════ */
.tvd-trang{
  --l-chu:#15191e; --l-chu-2:#3f4650; --l-nhat:#646c77;
  --l-vien:#cfd4da; --l-vien-2:#e6e8ec;
  --l-nen:#ffffff; --l-nen-2:#f2f3f5; --l-ray:#eceef1;
  --l-bat:#15191e; --l-bat-chu:#ffffff;
  --l-bong:0 1px 2px rgba(21,25,30,.05), 0 12px 32px -20px rgba(21,25,30,.38);
  --l-vong:0 0 0 2px var(--l-nen), 0 0 0 4px #2f6bd8;
}
html.ae-dark-mode .tvd-trang{
  --l-chu:#eef0f3; --l-chu-2:#c9ced5; --l-nhat:#9aa2ad;
  --l-vien:#3a4048; --l-vien-2:#272b31;
  --l-nen:#15171b; --l-nen-2:#1e2126; --l-ray:#0f1114;
  --l-bat:#eef0f3; --l-bat-chu:#111316;
  --l-bong:0 0 0 1px rgba(255,255,255,.02), 0 14px 34px -20px rgba(0,0,0,.9);
  --l-vong:0 0 0 2px var(--l-nen), 0 0 0 4px #6ea2ff;
}
html.theme-skeuo .tvd-trang{
  --l-chu:#3d2f16; --l-chu-2:#5a4726; --l-nhat:#7a6844;
  --l-vien:#cdbf98; --l-vien-2:#e3d8b8;
  --l-nen:#fffdf7; --l-nen-2:#f5eedd; --l-ray:#ece2c7;
  --l-bat:#2f76d2; --l-bat-chu:#ffffff;
  --l-vong:0 0 0 3px rgba(76,145,230,.55);
  --l-gel:linear-gradient(180deg,#ffffff 0%,#f7f2e5 48%,#ece3cb 52%,#f4eedd 100%);
  --l-gel-bat:linear-gradient(180deg,#9cc6f8 0%,#4c91e6 48%,#2f76d2 52%,#4a90e2 100%);
  --l-gel-vien-bat:#255da6;
  --l-giay:linear-gradient(180deg,#fffefb 0%,#f7f0de 100%);
}
html.theme-skeuo.ae-dark-mode .tvd-trang{
  --l-chu:#f1e6d0; --l-chu-2:#dccbaa; --l-nhat:#b9a582;
  --l-vien:rgba(255,214,150,.26); --l-vien-2:rgba(255,214,150,.14);
  --l-nen:#2b241c; --l-nen-2:#211b14; --l-ray:#1a150f;
  --l-bat:#d6a64c; --l-bat-chu:#3a2a08;
  --l-vong:0 0 0 3px rgba(232,190,100,.55);
  --l-gel:linear-gradient(180deg,#4a3d2e 0%,#3b3024 48%,#30271d 52%,#382e23 100%);
  --l-gel-bat:linear-gradient(180deg,#f8e2a4 0%,#e0b85e 48%,#c8983c 52%,#dbad52 100%);
  --l-gel-vien-bat:#8a6424;
  --l-giay:linear-gradient(180deg,#3a3026 0%,#2c241b 100%);
}

/* ── thanh lọc: một tấm (ô tìm + hàng Cấp + hàng Bộ đề + «N đề · chip») ngay dưới hero ── */
.tvd-thanh-sec{ padding:26px 0 4px; }
.tvd-thanh{ display:flex; flex-direction:column; gap:12px; padding:14px 18px; border-radius:18px; background:var(--l-nen); color:var(--l-chu);
  border:1px solid var(--l-vien-2); box-shadow:var(--l-bong); max-width:100%; box-sizing:border-box; }
.tvd-thanh *, .tvd-thanh *::before, .tvd-thanh *::after{ box-sizing:border-box; }
.tvd-thanh svg{ width:20px; height:20px; flex:none; fill:none; stroke:currentColor; stroke-width:1.9; stroke-linecap:round; stroke-linejoin:round; }
.tvd-thanh p{ margin:0; }
.tvd-thanh-vung{ display:flex; flex-direction:column; gap:12px; min-width:0; }
.tvd-thanh-vung:empty{ display:none; }

/* ô tìm (mã đề) — cùng dáng ô «Tìm theo tên đề» của IELTS */
.tvd-tim{ display:flex; gap:10px; margin:0; min-width:0; }
.tvd-tim-o{ flex:1 1 auto; min-width:0; display:flex !important; align-items:center; gap:10px; height:46px; margin:0; padding:0 16px; border-radius:999px;
  background:var(--l-nen-2); border:1.5px solid transparent; color:var(--l-nhat); cursor:text; transition:border-color .15s, background-color .15s; }
.tvd-tim-o:focus-within{ border-color:var(--l-chu); background:var(--l-nen); color:var(--l-chu); }
/* dark-mode.css + site-skeuo.css ép nền/viền/bóng mọi input bằng luật rất đặc ⇒ dùng ID để thắng (giống input#locdeTim) */
input#tvdTim{ flex:1; min-width:0; width:100%; height:100% !important; min-height:0 !important; margin:0 !important; padding:0 !important;
  border:0 !important; border-radius:0 !important; outline:0 !important; box-shadow:none !important; background:transparent !important;
  font-size:15px; font-weight:500; line-height:1.2; color:var(--l-chu) !important; -webkit-text-fill-color:var(--l-chu); -webkit-appearance:none; appearance:none; }
input#tvdTim::placeholder{ color:var(--l-nhat) !important; -webkit-text-fill-color:var(--l-nhat); opacity:1; }
input#tvdTim::-webkit-search-cancel-button{ -webkit-appearance:none; }
.tvd-tim-gui{ position:absolute !important; width:1px !important; height:1px !important; overflow:hidden !important; clip:rect(0 0 0 0) !important; white-space:nowrap !important; padding:0 !important; border:0 !important; }

/* hàng lọc: [nhãn] [nhóm: rãnh bong bóng] … */
.tvd-hang{ display:flex; align-items:flex-start; gap:14px; padding-top:12px; border-top:1px solid var(--l-vien-2); min-width:0; }
.tvd-hang-ten{ flex:0 0 64px; padding-top:9px; font-weight:700; font-size:15px; color:var(--l-chu); }
.tvd-hang-ds{ flex:1 1 auto; min-width:0; display:flex; flex-wrap:wrap; align-items:center; gap:12px 22px; }
.tvd-hang-nhom{ display:flex; align-items:center; gap:10px; min-width:0; flex-wrap:wrap; }
.tvd-hang-nhom-ten{ font-size:13px; font-weight:700; color:var(--l-nhat); white-space:nowrap; }
.tvd-ray{ display:inline-flex; flex-wrap:wrap; align-items:center; gap:6px; padding:4px; border-radius:999px; background:var(--l-ray); box-shadow:inset 0 0 0 1px var(--l-vien-2); max-width:100%; }
.tvd-hang--vien .tvd-ray{ background:none; box-shadow:none; padding:0; gap:8px; border-radius:0; }

/* ô chọn: bong bóng số (ô tô trên phiếu trả lời) + số đề ở góc; viên chữ có số đề bên trong */
.tvd-bong{ position:relative; display:inline-flex; align-items:center; text-decoration:none !important; color:var(--l-chu-2); -webkit-tap-highlight-color:transparent; }
.tvd-bong:not(.tvd-bong--chu) .tvd-bong-o{ display:grid; place-items:center; width:38px; height:38px; border-radius:50%; border:1.5px solid var(--l-vien);
  background:var(--l-nen); font-weight:700; font-size:14.5px; line-height:1; font-variant-numeric:tabular-nums; transition:background-color .15s, border-color .15s, color .15s; }
.tvd-bong:not(.tvd-bong--chu) .tvd-bong-sl{ position:absolute; top:-6px; right:-7px; z-index:1; display:grid; place-items:center; min-width:19px; height:19px; padding:0 5px;
  border-radius:999px; background:var(--l-nen); box-shadow:0 0 0 1px var(--l-vien); color:var(--l-nhat); font-size:10.5px; font-weight:800; line-height:1; font-variant-numeric:tabular-nums; }
.tvd-bong--chu{ gap:8px; height:38px; padding:0 6px 0 14px; border-radius:999px; border:1.5px solid var(--l-vien); background:var(--l-nen);
  transition:background-color .15s, border-color .15s, color .15s; }
.tvd-bong--chu .tvd-bong-o{ font-weight:600; font-size:14px; white-space:nowrap; }
.tvd-bong--chu .tvd-bong-sl{ display:grid; place-items:center; min-width:24px; height:26px; padding:0 8px; border-radius:999px; background:var(--l-nen-2); color:var(--l-nhat);
  font-size:12.5px; font-weight:800; font-variant-numeric:tabular-nums; }
a.tvd-bong:hover .tvd-bong-o, a.tvd-bong--chu:hover{ border-color:var(--l-chu); color:var(--l-chu); }
.tvd-bong.is-bat:not(.tvd-bong--chu) .tvd-bong-o{ background:var(--l-bat); border-color:var(--l-bat); color:var(--l-bat-chu); }
.tvd-bong--chu.is-bat{ background:var(--l-bat); border-color:var(--l-bat); color:var(--l-bat-chu); }
.tvd-bong--chu.is-bat .tvd-bong-o{ color:var(--l-bat-chu); }
.tvd-bong--chu.is-bat .tvd-bong-sl{ background:rgba(255,255,255,.2); color:var(--l-bat-chu); }
html.ae-dark-mode .tvd-bong--chu.is-bat .tvd-bong-sl{ background:rgba(0,0,0,.14); }
.tvd-bong.is-0{ opacity:.38; cursor:not-allowed; }
.tvd-bong.is-0 .tvd-bong-o, .tvd-bong--chu.is-0{ border-style:dashed; }
a.tvd-bong:focus-visible{ outline:0; }
a.tvd-bong:not(.tvd-bong--chu):focus-visible .tvd-bong-o, a.tvd-bong--chu:focus-visible{ box-shadow:var(--l-vong); }

/* «N đề · chip · Xoá bộ lọc» */
.tvd-chan{ display:flex; flex-wrap:wrap; align-items:center; gap:8px 12px; padding-top:12px; border-top:1px solid var(--l-vien-2); min-width:0; }
.tvd-chan--goc{ border-top:0; padding-top:0; }
.tvd-dem{ color:var(--l-chu-2); font-size:15px; white-space:nowrap; }
.tvd-dem b{ font-size:22px; font-weight:800; color:var(--l-chu); font-variant-numeric:tabular-nums; margin-right:2px; }
.tvd-dem span{ color:var(--l-nhat); }
.tvd-chan--goc .tvd-dem{ white-space:normal; color:var(--l-nhat); }
.tvd-chip-ds{ display:flex; flex-wrap:wrap; gap:8px; min-width:0; }
.tvd-chip{ display:inline-flex; align-items:center; gap:6px; max-width:100%; height:34px; padding:0 10px 0 14px; border-radius:999px; border:1.5px solid var(--l-vien);
  background:var(--l-nen-2); color:var(--l-chu) !important; font-size:14px; font-weight:600; text-decoration:none !important; }
.tvd-chip span{ overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.tvd-chip svg{ width:16px; height:16px; stroke-width:2.2; color:var(--l-nhat); }
.tvd-chip--tk span{ font-style:italic; }
.tvd-chip:hover{ border-color:var(--l-chu); }
.tvd-chip:hover svg{ color:var(--l-chu); }
.tvd-xoa, .tvd-xem-het{ font-size:14px; font-weight:600; color:var(--l-chu-2) !important; text-decoration:underline !important; text-underline-offset:3px; text-decoration-thickness:1px; white-space:nowrap; }
.tvd-xoa:hover, .tvd-xem-het:hover{ color:var(--l-chu) !important; }
.tvd-xem-het{ margin-left:auto; }
.tvd-chip:focus-visible, .tvd-xoa:focus-visible, .tvd-xem-het:focus-visible{ outline:0; box-shadow:var(--l-vong); border-radius:999px; }

/* đang tải vùng (JS) */
.tvd-loc.is-tai #tvdVung, .tvd-loc.is-tai #tvdThanh{ opacity:.55; transition:opacity .15s; pointer-events:none; }

/* ── trang thư viện: nhóm thẻ cấp + bộ đề ── */
.tvd-trang .tvd-chon-cap{ padding-top:30px; }
.tvd-nhom + .tvd-nhom{ margin-top:34px; }
.tvd-nhom-dau{ margin:0 0 16px; }
.tvd-nhom-dau h3{ margin:0; font-size:21px; font-weight:800; color:var(--lib-text); }
.tvd-nhom-dau h3 span{ margin-left:6px; font-size:14px; font-weight:600; color:var(--lib-muted); }
.tvd-nhom-dau p{ margin:4px 0 0; font-size:14.5px; color:var(--lib-muted); max-width:760px; }
.tvd-cap .lib-skill-head{ margin-bottom:12px; }
.tvd-cap .lib-skill-name{ font-size:21px; }
.tvd-cap .lib-skill-desc{ margin-bottom:12px; font-size:14px; }
.tvd-cap .lib-skill-parts{ margin-bottom:14px; }
.tvd-cap .lib-skill-parts li a b{ font-weight:800; margin-left:2px; }
.tvd-cap .lib-skill-preview{ margin-bottom:16px; }
.tvd-cap-da{ margin:0 0 6px; font-size:14px; color:var(--lib-text); }
.tvd-cap-da b{ font-variant-numeric:tabular-nums; }
.tvd-cap .tvd-luot ul{ margin:0; padding:0; list-style:none; }
.tvd-cap .lib-skill-cta{ margin-top:auto; }
.tvd-o.lib-skill-icon{ width:56px; height:56px; display:grid; place-items:center; }

.tvd-bo-luoi{ display:grid; grid-template-columns:repeat(auto-fill, minmax(230px, 1fr)); gap:16px; }
.tvd-bo{ display:flex; flex-direction:column; gap:8px; padding:18px 20px; border-radius:20px; background:var(--lib-card); border:1px solid var(--lib-border);
  color:var(--lib-text) !important; text-decoration:none !important; transition:transform .2s ease, border-color .2s ease, box-shadow .2s ease; }
.tvd-bo:hover{ transform:translateY(-2px); border-color:var(--lib-text); box-shadow:0 14px 30px -18px rgba(0,0,0,.35); }
.tvd-bo:focus-visible{ outline:0; box-shadow:var(--l-vong); }
.tvd-bo-dau{ display:flex; align-items:baseline; justify-content:space-between; gap:10px; }
.tvd-bo-ten{ font-size:17px; font-weight:800; line-height:1.25; }
.tvd-bo-so{ flex:none; font-size:13px; font-weight:700; color:var(--lib-muted); font-variant-numeric:tabular-nums; }
.tvd-bo-mo{ font-size:14px; line-height:1.5; color:var(--lib-muted); }
.tvd-bo-cap{ margin-top:auto; font-size:12.5px; font-weight:700; letter-spacing:.02em; color:var(--lib-text); opacity:.75; }

/* ── trang lọc: kết quả chia theo cấp ── */
.tvd-trang .tvd-kq-sec{ padding-top:22px; }
.tvd-kq-nhom + .tvd-kq-nhom{ margin-top:36px; }
.tvd-kq-dau{ display:flex; align-items:center; gap:14px; margin:0 0 16px; min-width:0; }
.tvd-kq-dau > .tvd-o{ flex:none; width:50px; height:50px; display:grid; place-items:center; }
.tvd-kq-dau > .tvd-o .tvd-han{ font-size:26px; }
.tvd-kq-dau-chu{ flex:1 1 0; min-width:0; }
.tvd-kq-ten-cap{ margin:0; font-size:22px; font-weight:800; line-height:1.25; color:var(--lib-text); }
.tvd-kq-ten-cap span{ margin-left:6px; font-size:14px; font-weight:600; color:var(--lib-muted); white-space:nowrap; }
.tvd-kq-dau p{ margin:2px 0 0; font-size:14px; color:var(--lib-muted); }
.tvd-kq-chi{ margin-left:auto; flex:none; font-size:14px; font-weight:600; color:var(--lib-text) !important; text-decoration:underline !important; text-underline-offset:3px; }

/* thẻ đề gọn */
.tvd-de.lib-skill-card{ padding:18px 18px 16px; }
.tvd-de-dau{ display:flex; align-items:center; gap:12px; margin-bottom:10px; min-width:0; }
.tvd-de-dau > .tvd-o{ flex:none; width:46px; height:46px; display:grid; place-items:center; }
.tvd-de-dau > .tvd-o .tvd-han{ font-size:24px; }
.tvd-de-ten{ min-width:0; }
.tvd-de .lib-skill-name{ font-size:18px; margin:0; overflow-wrap:anywhere; }
.tvd-de-phu{ margin:2px 0 0; font-size:13px; font-weight:600; color:var(--lib-muted); }
.tvd-de-so{ display:flex; flex-wrap:wrap; align-items:center; gap:6px 8px; margin:0 0 12px; font-size:14px; color:var(--lib-muted); }
.tvd-de-so b{ color:var(--lib-text); font-weight:800; }
.tvd-de-kn{ padding:2px 9px; border-radius:999px; font-size:12.5px; font-weight:700; color:var(--skill-color, var(--lib-primary));
  background:color-mix(in srgb, var(--skill-color, var(--lib-primary)) 9%, transparent); }
.tvd-de .tvd-luot{ border-top:1px dashed var(--lib-border); padding-top:10px; margin:0 0 14px; }
.tvd-de .tvd-luot ul{ margin:0; padding:0; list-style:none; }
.tvd-de .tvd-chua{ font-size:13.5px; }
.tvd-de .tvd-them{ margin-top:4px; }
.tvd-de .tvd-nut .lib-skill-cta{ padding-top:10px; padding-bottom:10px; }
.tvd-de .tvd-phu{ padding:10px 14px; }
.tvd-de:hover{ transform:translateY(-3px); }

/* ── nền tối ── */
html.ae-dark-mode .tvd-bo{ background:#1c1d21; border-color:rgba(255,255,255,.1); color:#f2f2f4 !important; }
html.ae-dark-mode .tvd-bo:hover{ border-color:rgba(255,255,255,.4); }
html.ae-dark-mode .tvd-bo-mo, html.ae-dark-mode .tvd-bo-so{ color:#a1a1a8; }
html.ae-dark-mode .tvd-bo-cap{ color:#f2f2f4; }
html.ae-dark-mode .tvd-nhom-dau h3, html.ae-dark-mode .tvd-kq-ten-cap, html.ae-dark-mode .tvd-cap-da, html.ae-dark-mode .tvd-de-so b{ color:#f2f2f4; }
html.ae-dark-mode .tvd-kq-chi{ color:#f2f2f4 !important; }

/* ── skeuo: tấm giấy kem, ô tìm = rãnh lõm, nút gel; ô chọn = gel xanh Aqua (tối: gel đồng) ── */
html.theme-skeuo .tvd-thanh{ background:var(--l-giay); border:1px solid #dccda2; box-shadow:inset 0 1px 0 #fff, 0 12px 26px -16px rgba(70,48,14,.55); }
html.theme-skeuo.ae-dark-mode .tvd-thanh{ border-color:rgba(255,214,150,.3); box-shadow:inset 0 1px 0 rgba(255,236,200,.08), 0 16px 34px -16px rgba(0,0,0,.75); }
html.theme-skeuo .tvd-hang, html.theme-skeuo .tvd-chan:not(.tvd-chan--goc){ border-top-color:#e6dbbb; box-shadow:inset 0 1px 0 rgba(255,255,255,.7); }
html.theme-skeuo.ae-dark-mode .tvd-hang, html.theme-skeuo.ae-dark-mode .tvd-chan:not(.tvd-chan--goc){ border-top-color:rgba(255,214,150,.14); box-shadow:inset 0 1px 0 rgba(0,0,0,.25); }
html.theme-skeuo .tvd-tim-o{ background:linear-gradient(180deg,#efe6cf,#faf6ea); border:1px solid #c9ba90; box-shadow:inset 0 2px 3px rgba(90,66,24,.2), 0 1px 0 rgba(255,255,255,.85); }
html.theme-skeuo .tvd-tim-o:focus-within{ border-color:#4c91e6; box-shadow:inset 0 2px 3px rgba(90,66,24,.16), 0 0 0 3px rgba(76,145,230,.35); }
html.theme-skeuo.ae-dark-mode .tvd-tim-o{ background:linear-gradient(180deg,#17120d,#211a13); border-color:rgba(255,214,150,.22); box-shadow:inset 0 2px 4px rgba(0,0,0,.55), 0 1px 0 rgba(255,236,200,.06); }
html.theme-skeuo.ae-dark-mode .tvd-tim-o:focus-within{ border-color:#c8983c; box-shadow:inset 0 2px 4px rgba(0,0,0,.5), 0 0 0 3px rgba(232,190,100,.3); }
html.theme-skeuo .tvd-ray{ background:linear-gradient(180deg,#e9dfc4,#f4eddb); box-shadow:inset 0 1px 3px rgba(90,66,24,.25), 0 1px 0 rgba(255,255,255,.9); }
html.theme-skeuo.ae-dark-mode .tvd-ray{ background:linear-gradient(180deg,#17120d,#211a13); box-shadow:inset 0 2px 4px rgba(0,0,0,.6), 0 1px 0 rgba(255,236,200,.06); }
html.theme-skeuo .tvd-hang--vien .tvd-ray{ background:none; box-shadow:none; }
html.theme-skeuo .tvd-bong:not(.tvd-bong--chu) .tvd-bong-o, html.theme-skeuo .tvd-bong--chu, html.theme-skeuo .tvd-chip{
  background:var(--l-gel); border:1px solid #bfae83; color:var(--l-chu); box-shadow:inset 0 1px 0 rgba(255,255,255,.95), 0 1px 2px rgba(90,66,24,.28); text-shadow:0 1px 0 rgba(255,255,255,.85); }
html.theme-skeuo .tvd-bong.is-bat:not(.tvd-bong--chu) .tvd-bong-o, html.theme-skeuo .tvd-bong--chu.is-bat{
  background:var(--l-gel-bat); border-color:var(--l-gel-vien-bat); color:#fff;
  box-shadow:inset 0 1px 0 rgba(255,255,255,.55), inset 0 -3px 6px rgba(10,50,120,.25), 0 1px 2px rgba(20,50,100,.35); text-shadow:0 -1px 0 rgba(0,35,90,.55); }
html.theme-skeuo .tvd-bong--chu.is-bat .tvd-bong-o{ color:#fff; }
html.theme-skeuo .tvd-bong.is-0 .tvd-bong-o, html.theme-skeuo .tvd-bong--chu.is-0{ box-shadow:none; background:transparent; }
html.theme-skeuo .tvd-bong:not(.tvd-bong--chu) .tvd-bong-sl{ background:linear-gradient(180deg,#fffefb,#f1e8d2); box-shadow:0 0 0 1px #c9ba90, 0 1px 1px rgba(90,66,24,.2); color:#5a4726; }
html.theme-skeuo .tvd-bong--chu .tvd-bong-sl{ background:rgba(214,190,130,.28); color:#5a4726; text-shadow:none; }
html.theme-skeuo .tvd-bong--chu.is-bat .tvd-bong-sl{ background:rgba(255,255,255,.22); color:#fff; }
html.theme-skeuo a.tvd-bong:hover .tvd-bong-o, html.theme-skeuo a.tvd-bong--chu:hover, html.theme-skeuo .tvd-chip:hover{ border-color:#9f8d5f; }
html.theme-skeuo .tvd-xoa, html.theme-skeuo .tvd-xem-het{ color:#6a5428 !important; text-shadow:0 1px 0 rgba(255,255,255,.7); }
html.theme-skeuo:not(.ae-dark-mode) .tvd-dem b{ color:#2a1d08; text-shadow:0 1px 0 rgba(255,240,205,.55); }
html.theme-skeuo .tvd-bo{ background:linear-gradient(180deg,#fffefb,#f7f0de); border-color:#dccda2; box-shadow:inset 0 1px 0 #fff, 0 10px 22px -16px rgba(70,48,14,.55); }
html.theme-skeuo .tvd-bo:hover{ border-color:#a8966a; }
/* skeuo tối: gỗ + đồng thau */
html.theme-skeuo.ae-dark-mode .tvd-bong:not(.tvd-bong--chu) .tvd-bong-o, html.theme-skeuo.ae-dark-mode .tvd-bong--chu, html.theme-skeuo.ae-dark-mode .tvd-chip{
  border-color:rgba(255,214,150,.28); color:var(--l-chu); text-shadow:0 -1px 0 rgba(0,0,0,.55); box-shadow:inset 0 1px 0 rgba(255,236,200,.14), 0 1px 2px rgba(0,0,0,.5); }
html.theme-skeuo.ae-dark-mode .tvd-bong.is-bat:not(.tvd-bong--chu) .tvd-bong-o, html.theme-skeuo.ae-dark-mode .tvd-bong--chu.is-bat{
  background:var(--l-gel-bat); border-color:var(--l-gel-vien-bat); color:#3a2a08; text-shadow:0 1px 0 rgba(255,240,200,.6);
  box-shadow:inset 0 1px 0 rgba(255,250,225,.7), inset 0 -3px 6px rgba(120,80,10,.25), 0 1px 3px rgba(0,0,0,.5); }
html.theme-skeuo.ae-dark-mode .tvd-bong--chu.is-bat .tvd-bong-o, html.theme-skeuo.ae-dark-mode .tvd-bong--chu.is-bat .tvd-bong-sl{ color:#3a2a08; }
html.theme-skeuo.ae-dark-mode .tvd-bong:not(.tvd-bong--chu) .tvd-bong-sl{ background:linear-gradient(180deg,#3a3026,#2c241b); box-shadow:0 0 0 1px rgba(255,214,150,.3); color:#e2c98f; }
html.theme-skeuo.ae-dark-mode .tvd-bong--chu .tvd-bong-sl{ background:rgba(0,0,0,.28); color:#e2c98f; }
html.theme-skeuo.ae-dark-mode a.tvd-bong:hover .tvd-bong-o, html.theme-skeuo.ae-dark-mode a.tvd-bong--chu:hover, html.theme-skeuo.ae-dark-mode .tvd-chip:hover{ border-color:rgba(255,214,150,.5); }
html.theme-skeuo.ae-dark-mode .tvd-xoa, html.theme-skeuo.ae-dark-mode .tvd-xem-het{ color:#e2c98f !important; text-shadow:0 -1px 0 rgba(0,0,0,.5); }
html.theme-skeuo.ae-dark-mode .tvd-bo{ background:linear-gradient(180deg,#3a3026,#2c241b); border-color:rgba(255,214,150,.22); color:#f1e6d0 !important; box-shadow:inset 0 1px 0 rgba(255,236,200,.08), 0 12px 26px -16px rgba(0,0,0,.7); }
html.theme-skeuo.ae-dark-mode .tvd-bo-mo, html.theme-skeuo.ae-dark-mode .tvd-bo-so{ color:#b9a582; }
html.theme-skeuo.ae-dark-mode .tvd-bo-cap{ color:#f1e6d0; }
/* ô mực «五级» trong thẻ gọn / tiêu đề nhóm: chữ nhỏ hơn cho vừa ô 46–50 px */
html.theme-skeuo .tvd-de-dau > .tvd-o .tvd-han, html.theme-skeuo .tvd-kq-dau > .tvd-o .tvd-han{ font-size:15px; }
html.theme-skeuo .tvd-o.lib-skill-icon .tvd-han{ font-size:18px; }

/* ── máy tính bảng / điện thoại ── */
@media (max-width: 991px){
  .tvd-hang{ flex-direction:column; gap:8px; }
  .tvd-hang-ten{ flex:none; padding-top:0; font-size:14px; }
  .tvd-hang-ds{ gap:10px 16px; }
}
@media (max-width: 575px){
  .tvd-thanh-sec{ padding-top:18px; }
  .tvd-thanh{ padding:12px; border-radius:16px; gap:10px; }
  .tvd-tim-o{ height:44px; padding:0 14px; }
  input#tvdTim{ font-size:16px; }   /* iOS không phóng to khi chạm */
  .tvd-hang-nhom{ gap:6px 8px; }
  .tvd-ray{ gap:5px; padding:3px; }
  .tvd-bong:not(.tvd-bong--chu) .tvd-bong-o{ width:36px; height:36px; font-size:14px; }
  .tvd-bong--chu{ height:36px; padding-left:12px; }
  .tvd-bong--chu .tvd-bong-o{ font-size:13.5px; }
  .tvd-xem-het{ margin-left:0; }
  .tvd-dem b{ font-size:20px; }
  .tvd-kq-dau{ flex-wrap:wrap; gap:10px 12px; }
  .tvd-kq-ten-cap{ font-size:19px; }
  .tvd-kq-chi{ flex:0 0 calc(100% - 64px); margin-left:64px; }   /* basis 100% + lề 64 từng tràn ngang 48px ở 390 */
  .tvd-nhom-dau h3{ font-size:19px; }
  .tvd-bo-luoi{ grid-template-columns:1fr; gap:12px; }
  .tvd-de.lib-skill-card{ padding:16px 16px 14px; }
}

/* nhóm chỉ có viên chữ (HSKK Sơ / Trung / Cao, Bộ đề): không rãnh chung — xuống dòng gọn trên điện thoại */
.tvd-ray--chu, html.theme-skeuo .tvd-ray--chu, html.theme-skeuo.ae-dark-mode .tvd-ray--chu,
html.theme-skeuo.ae-dark-mode .tvd-hang--vien .tvd-ray{ background:none; box-shadow:none; padding:0; gap:8px; border-radius:0; }

/* trang lọc: hero gọn như trang kỹ năng IELTS (ô chữ + tiêu đề + câu phụ; ô số + tờ ghi chú chỉ ở trang thư viện) */
.tvd-trang[data-kieu="loc"] .lib-hero{ padding:12px 0 6px; }
.tvd-trang[data-kieu="loc"] .lib-hero .lib-stats, .tvd-trang[data-kieu="loc"] .lib-hero .lib-classic{ display:none !important; }
.tvd-trang[data-kieu="loc"] .lib-hero-icon.tvd-o{ width:60px; height:60px; margin-bottom:10px; }
.tvd-trang[data-kieu="loc"] .lib-hero-icon.tvd-o .tvd-han{ font-size:32px; }
html.theme-skeuo .tvd-trang[data-kieu="loc"] .lib-hero-icon.tvd-o .tvd-han{ font-size:26px; }
.tvd-trang[data-kieu="loc"] .lib-hero-title{ font-size:clamp(26px, 3vw, 34px); margin-bottom:8px; }
.tvd-trang[data-kieu="loc"] .lib-hero-sub{ margin-bottom:8px; font-size:15px; }

/* chữ tiêu đề nhóm nằm thẳng trên nền trang: skeuo = gỗ sồi (sáng) / óc chó (tối) ⇒ mực nâu đậm + gờ sáng, giống «N đề» của IELTS */
html.theme-skeuo:not(.ae-dark-mode) .tvd-kq-ten-cap, html.theme-skeuo:not(.ae-dark-mode) .tvd-nhom-dau h3{ color:#2a1d08; text-shadow:0 1px 0 rgba(255,240,205,.55); }
html.theme-skeuo:not(.ae-dark-mode) .tvd-kq-ten-cap span, html.theme-skeuo:not(.ae-dark-mode) .tvd-kq-dau p,
html.theme-skeuo:not(.ae-dark-mode) .tvd-nhom-dau h3 span, html.theme-skeuo:not(.ae-dark-mode) .tvd-nhom-dau p{ color:#4a3818; text-shadow:0 1px 0 rgba(255,240,205,.45); }
html.theme-skeuo:not(.ae-dark-mode) .tvd-kq-chi{ color:#3d2c10 !important; text-shadow:0 1px 0 rgba(255,240,205,.55); }
html.theme-skeuo.ae-dark-mode .tvd-kq-ten-cap, html.theme-skeuo.ae-dark-mode .tvd-nhom-dau h3, html.theme-skeuo.ae-dark-mode .tvd-kq-chi{ color:#f1e6d0 !important; text-shadow:0 -1px 0 rgba(0,0,0,.6); }
html.theme-skeuo.ae-dark-mode .tvd-kq-ten-cap span, html.theme-skeuo.ae-dark-mode .tvd-kq-dau p,
html.theme-skeuo.ae-dark-mode .tvd-nhom-dau h3 span, html.theme-skeuo.ae-dark-mode .tvd-nhom-dau p{ color:#d9c7a2; text-shadow:0 -1px 0 rgba(0,0,0,.5); }

/* điện thoại: thẻ cấp 2 cột gọn (ô chữ · tên · số đề · đã thi · nút) — chip bộ đề và dòng lượt ở trang lọc */
@media (max-width: 575px){
  .tvd-trang[data-kieu="loc"] .lib-hero-sub{ display:none; }
  .tvd-chon-cap .lib-skills-grid--static{ grid-template-columns:repeat(2, minmax(0, 1fr)); gap:10px; }
  .tvd-cap.lib-skill-card{ padding:14px 12px 12px; border-radius:16px; }
  .tvd-cap .lib-skill-head{ flex-direction:column; align-items:flex-start; gap:8px; margin-bottom:8px; }
  .tvd-cap .lib-skill-name{ font-size:16px; margin:0; }
  .tvd-cap .lib-skill-count{ font-size:13px; }
  .tvd-cap .lib-skill-desc, .tvd-cap .lib-skill-parts, .tvd-cap .tvd-luot ul, .tvd-cap .lib-skill-preview-label, .tvd-cap .tvd-chua{ display:none; }
  .tvd-cap .lib-skill-preview{ border-top:0; padding-top:0; margin-bottom:10px; }
  .tvd-cap-da{ font-size:12.5px; color:var(--lib-muted); margin:0; }
  .tvd-cap .lib-skill-cta{ padding:9px 10px; font-size:14px; }
  .tvd-o.lib-skill-icon{ width:46px; height:46px; }
  .tvd-o.lib-skill-icon .tvd-han{ font-size:24px; }
  html.theme-skeuo .tvd-o.lib-skill-icon .tvd-han{ font-size:15px; }
  .tvd-nhom + .tvd-nhom{ margin-top:26px; }
}

/* ô chữ Latin («L&R», «S&W») trong thẻ gọn / tiêu đề nhóm TOEIC */
.tvd-de-dau > .tvd-o--chu .tvd-han, .tvd-kq-dau > .tvd-o--chu .tvd-han{ font-size:14px; }
html.theme-skeuo .tvd-de-dau > .tvd-o--chu .tvd-han, html.theme-skeuo .tvd-kq-dau > .tvd-o--chu .tvd-han{ font-size:13px; }
.tvd-de-so > span:not(.tvd-de-kn){ color:var(--lib-muted); }
.tvd-tt-sec{ padding-top:8px; }

/* ═══════════════════════════════════════════════════════════════════════════
   15/10 — BÌA BỘ ĐỀ (anh duyệt bản mẫu _harness/thiet-ke-thu-vien-bia): «Bộ đề nổi bật» dưới hero (khuôn .lib-featured của IELTS),
   hàng bìa trong thẻ cấp, trang một cấp chia theo bộ (hàng chọn bộ + khối bìa lớn), khối bộ TOEIC. Ảnh: public/images/bia-de/*.webp
   (480×720); chưa có ảnh ⇒ .tvd-bia--ve vẽ bằng CSS. Màu nền / chữ dùng --lib-* (tự đổi ở nền tối) + --l-* (bảng màu bộ lọc).
   ═══════════════════════════════════════════════════════════════════════════ */
.tvd-bia{ display:block; width:100%; height:auto; aspect-ratio:2/3; object-fit:cover; border-radius:8px; background:#0f172a; }
/* bìa vẽ CSS (bộ / cấp mới nạp sau, chưa sinh ảnh) — cỡ chữ theo em của từng biến thể */
.tvd-bia--ve{ position:relative; display:flex; flex-direction:column; align-items:center; justify-content:center; gap:.5em; overflow:hidden;
  font-size:14px; color:#fff; text-align:center;
  background:radial-gradient(120% 70% at 50% 38%, color-mix(in srgb, var(--m) 55%, #000) 0%, color-mix(in srgb, var(--m) 22%, #07070c) 46%, #07070c 100%); }
.tvd-bia--ve .tvd-bia-o{ display:grid; place-items:center; width:3.4em; height:3.4em; border:2px solid rgba(255,217,138,.7); border-radius:.4em;
  font:900 2.2em/1 "Noto Serif SC","PingFang SC","Hiragino Sans GB",serif; color:#fff7e3; text-shadow:0 0 .4em color-mix(in srgb, var(--m) 90%, transparent); }
.tvd-bia--ve .tvd-bia-o{ width:1.6em; height:1.6em; }
.tvd-bia--ve .tvd-bia-dau{ position:absolute; top:7%; right:7%; padding:.25em .3em; border-radius:.3em; background:#c81e2e; writing-mode:vertical-rl;
  font:900 .8em/1.05 "Noto Serif SC","PingFang SC",serif; color:#fff4e6; }
.tvd-bia--ve .tvd-bia-ten{ font-weight:800; font-size:1.3em; color:#ffe2a6; }
.tvd-bia--ve .tvd-bia-phu{ padding:0 8%; font-weight:700; font-size:.62em; letter-spacing:.12em; text-transform:uppercase; opacity:.9; }
.tvd-bia--nho.tvd-bia--ve{ font-size:5px; }
.tvd-bia--dau.tvd-bia--ve{ font-size:4.5px; }
.tvd-bia--lon.tvd-bia--ve{ font-size:11px; }

/* ── «Bộ đề nổi bật»: khuôn .lib-featured của IELTS; ẩn ở trang lọc / tài khoản chưa mở đề (JS đổi main[data-kieu]) ── */
.tvd-trang[data-kieu="loc"] .tvd-noi-bat, .tvd-trang[data-kieu="trong"] .tvd-noi-bat{ display:none; }
.tvd-noi-bat-bia > .tvd-bia{ border-radius:0; background:transparent; }
.tvd-noi-bat-bia > .tvd-bia--ve{ position:relative; z-index:1; width:100%; height:100%; aspect-ratio:auto; }
.tvd-trang .tvd-noi-bat + .tvd-loc .tvd-thanh-sec{ padding-top:8px; }
.tvd-khach{ max-width:640px; margin:4px auto 10px; font-size:14px; line-height:1.5; color:var(--lib-muted); }
.tvd-khach b{ color:var(--lib-text); }

/* ── thẻ cấp: hàng bìa bộ đề (thay chip chữ) ── */
.tvd-bo-bia{ display:grid; grid-template-columns:repeat(4, minmax(0, 1fr)); gap:10px; margin:0 0 16px; }
.tvd-bo-bia a{ display:flex; flex-direction:column; align-items:center; min-width:0; text-align:center; color:var(--lib-text) !important; text-decoration:none !important; }
.tvd-bo-bia .tvd-bia{ box-shadow:0 3px 10px rgba(0,0,0,.18); transition:transform .15s ease, box-shadow .15s ease; }
.tvd-bo-bia a:hover .tvd-bia{ transform:translateY(-3px) rotate(-1deg); box-shadow:0 8px 18px rgba(0,0,0,.24); }
.tvd-bo-bia a:focus-visible{ outline:0; }
.tvd-bo-bia a:focus-visible .tvd-bia{ box-shadow:var(--l-vong); }
.tvd-bo-bia-ten{ display:block; margin-top:7px; font-size:12px; font-weight:700; line-height:1.25; }
.tvd-bo-bia em{ display:inline-block; margin-top:3px; padding:1px 8px; border-radius:999px; font-style:normal; font-size:11.5px; font-weight:800;
  color:var(--skill-color, var(--lib-text)); background:color-mix(in srgb, var(--skill-color, var(--lib-text)) 12%, transparent); }

/* ── trang một cấp: hàng chọn bộ (bìa + số đề + tiến độ) ── */
.tvd-bo-chon{ display:grid; grid-template-columns:repeat(auto-fill, minmax(230px, 1fr)); gap:14px; margin:0 0 28px; }
.tvd-bo-the{ display:grid; grid-template-columns:60px minmax(0, 1fr); gap:12px; align-items:center; padding:10px 12px; border-radius:14px;
  background:var(--lib-card); border:1px solid var(--lib-border); color:var(--lib-text) !important; text-decoration:none !important;
  transition:transform .15s ease, border-color .15s ease, box-shadow .15s ease; }
.tvd-bo-the:hover{ transform:translateY(-2px); border-color:var(--skill-color); box-shadow:0 12px 26px -18px rgba(0,0,0,.4); }
.tvd-bo-the:focus-visible{ outline:0; box-shadow:var(--l-vong); }
.tvd-bo-the .tvd-bia{ border-radius:6px; box-shadow:0 2px 8px rgba(0,0,0,.2); }
.tvd-bo-the-chu{ min-width:0; }
.tvd-bo-the-chu b{ display:block; font-size:15px; font-weight:800; line-height:1.25; }
.tvd-bo-the-chu small{ display:block; margin-top:2px; font-size:12.5px; color:var(--lib-muted); }
.tvd-tien{ display:block; height:6px; margin-top:8px; border-radius:9px; background:var(--l-ray); overflow:hidden; }
.tvd-tien i{ display:block; height:100%; border-radius:inherit; background:var(--skill-color); }

/* ── khối một bộ: bìa lớn trái + mô tả + lưới đề (HSK trang cấp, TOEIC mọi bộ) ── */
.tvd-bo-nhom{ display:grid; grid-template-columns:200px minmax(0, 1fr); gap:26px; margin:0 0 24px; padding:22px; border-radius:20px;
  background:var(--lib-card); border:1px solid var(--lib-border); scroll-margin-top:110px; }
.tvd-kq-nhom.tvd-bo-nhom + .tvd-kq-nhom.tvd-bo-nhom{ margin-top:0; }
.tvd-bo-nhom-bia .tvd-bia{ position:sticky; top:100px; border-radius:12px; box-shadow:0 10px 24px rgba(0,0,0,.22); }
.tvd-bo-nhom-than{ min-width:0; }
.tvd-bo-nhom-than .tvd-kq-ten-cap{ font-size:22px; }
.tvd-bo-nhom-mo{ max-width:720px; margin:4px 0 16px; font-size:14.5px; line-height:1.5; color:var(--lib-muted); }
.tvd-bo-nhom .lib-skills-grid.tvd-luoi{ grid-template-columns:repeat(4, minmax(0, 1fr)); gap:16px; }   /* 8 đề đầu = 2 hàng chẵn */
@media (max-width: 1399px){ .tvd-bo-nhom .lib-skills-grid.tvd-luoi{ grid-template-columns:repeat(3, minmax(0, 1fr)); } }
@media (max-width: 1099px){ .tvd-bo-nhom .lib-skills-grid.tvd-luoi{ grid-template-columns:repeat(2, minmax(0, 1fr)); } }
@media (max-width: 575px){ .tvd-bo-nhom .lib-skills-grid.tvd-luoi{ grid-template-columns:minmax(0, 1fr); } }
.tvd-bo-them{ display:inline-flex; align-items:center; gap:8px; margin-top:16px; font-size:14.5px; font-weight:700; color:var(--lib-text) !important;
  text-decoration:underline !important; text-underline-offset:3px; }
/* tiêu đề nhóm khi đã chọn bộ: bìa nhỏ thay ô chữ */
.tvd-kq-dau > .tvd-bia--dau{ flex:none; width:48px; border-radius:6px; box-shadow:0 2px 8px rgba(0,0,0,.2); }

/* ── skeuo: giấy kem (sáng) / gỗ (tối) như .tvd-bo ── */
html.theme-skeuo .tvd-bo-the, html.theme-skeuo .tvd-bo-nhom{ background:linear-gradient(180deg,#fffefb,#f7f0de); border-color:#dccda2;
  box-shadow:inset 0 1px 0 #fff, 0 10px 22px -16px rgba(70,48,14,.55); }
html.theme-skeuo .tvd-bo-the:hover{ border-color:#a8966a; }
html.theme-skeuo.ae-dark-mode .tvd-bo-the, html.theme-skeuo.ae-dark-mode .tvd-bo-nhom{ background:linear-gradient(180deg,#3a3026,#2c241b);
  border-color:rgba(255,214,150,.22); color:#f1e6d0 !important; box-shadow:inset 0 1px 0 rgba(255,236,200,.08), 0 12px 26px -16px rgba(0,0,0,.7); }
html.theme-skeuo.ae-dark-mode .tvd-bo-the-chu small, html.theme-skeuo.ae-dark-mode .tvd-bo-nhom-mo{ color:#b9a582; }
html.theme-skeuo .tvd-bo-nhom .tvd-kq-ten-cap{ color:#2a1d08; text-shadow:0 1px 0 rgba(255,240,205,.55); }
html.theme-skeuo.ae-dark-mode .tvd-bo-nhom .tvd-kq-ten-cap{ color:#f1e6d0 !important; }
html.theme-skeuo:not(.ae-dark-mode) .tvd-khach{ color:#4a3818; }

/* ── máy tính bảng / điện thoại ── */
@media (max-width: 767px){
  .tvd-bo-nhom{ grid-template-columns:minmax(0, 1fr); gap:14px; padding:16px; border-radius:16px; }
  .tvd-bo-nhom-bia{ display:none; }
  .tvd-bo-chon{ grid-template-columns:repeat(2, minmax(0, 1fr)); gap:10px; margin-bottom:20px; }
  .tvd-bo-the{ grid-template-columns:44px minmax(0, 1fr); gap:10px; padding:8px 10px; }
  .tvd-bo-the-chu b{ font-size:13.5px; }
  .tvd-bo-the-chu small{ font-size:12px; }
}
@media (max-width: 575px){
  /* thẻ cấp: một cột để hàng bìa đủ lớn để bấm (trước 2 cột + ẩn chip) */
  .tvd-chon-cap .lib-skills-grid--static{ grid-template-columns:minmax(0, 1fr); gap:12px; }
  .tvd-cap .lib-skill-head{ flex-direction:row; align-items:center; gap:12px; }
  .tvd-bo-bia{ gap:8px; margin-bottom:12px; }
  .tvd-bo-bia-ten{ font-size:11px; }
  .tvd-bo-bia em{ font-size:10.5px; padding:1px 6px; }
}
