:root {
  --bg: #f5f7f5; --surface: #fff; --text: #1d2621; --muted: #5d6b63; --line: #e1e7e3;
  --brand: #0b6b3a; --brand-2: #138a4d; --brand-soft: #e7f3ec; --accent: #c8a03a; --link: #0a5f9e;
  --radius: 12px; --shadow: 0 1px 2px rgba(16,40,26,.06), 0 4px 16px rgba(16,40,26,.05);
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #111613; --surface: #182019; --text: #e3ebe5; --muted: #9db0a4; --line: #2a362e;
    --brand: #3fb874; --brand-2: #5ccb8b; --brand-soft: #1d3326; --link: #79b8ef;
    --shadow: 0 1px 2px rgba(0,0,0,.4);
  }
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--text); font: 16px/1.6 "Be Vietnam Pro", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif; }
a { color: var(--link); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; height: auto; }
.wrap { max-width: 1180px; margin: 0 auto; padding: 0 16px; }
.narrow { max-width: 720px; }
.btn, .btn-sm { display: inline-block; background: var(--brand); color: #fff !important; border-radius: 999px; padding: 9px 18px; font-weight: 600; border: 0; cursor: pointer; font: inherit; font-weight: 600; }
.btn-sm { padding: 6px 14px; font-size: 14px; }
.btn:hover, .btn-sm:hover { background: var(--brand-2); text-decoration: none; }

/* Thanh trên */
.topbar { background: var(--surface); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 30; }
.topbar-in { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 60px; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--text); min-width: 0; }
.brand:hover { text-decoration: none; }
.brand span { display: flex; flex-direction: column; line-height: 1.2; min-width: 0; }
.brand b { color: var(--brand); font-size: 16px; }
.brand small { color: var(--muted); font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.toplinks { display: flex; align-items: center; gap: 14px; font-size: 14px; flex-shrink: 0; }
.toplinks > a:not(.btn-sm) { color: var(--text); }
.lng { display: inline-flex; border: 1px solid var(--line); border-radius: 999px; overflow: hidden; }
.lng a { padding: 3px 9px; color: var(--muted); font-size: 12px; font-weight: 600; }
.lng a.on { background: var(--brand-soft); color: var(--brand); }
.toplinks .tl { padding: 4px 2px; border-bottom: 2px solid transparent; }
.toplinks .tl.on { color: var(--brand); border-bottom-color: var(--brand); font-weight: 600; }
@media (max-width: 760px) { .brand small { display: none; } .toplinks { gap: 10px; } }
@media (max-width: 520px) { .brand span { display: none; } .toplinks .btn-sm { display: none; } }

/* Đầu trang giảng viên */
.hero { position: relative; color: #fff; background: linear-gradient(120deg, #07502b, #0f7a43 55%, #2c8f57); overflow: hidden; }
.hero::before { content: ""; position: absolute; inset: 0; background: var(--hero-img, none) center/cover no-repeat; opacity: .22; }
.hero > .wrap { position: relative; }
.hero-in { display: flex; align-items: center; gap: 22px; padding-top: 34px; padding-bottom: 30px; }
.hero h1 { margin: 0; font-size: clamp(24px, 4vw, 34px); line-height: 1.2; }
.hero h1 a { color: #fff; }
.hero .tagline { margin: 6px 0 0; opacity: .92; }
.hero .meta { margin: 10px 0 0; display: flex; flex-wrap: wrap; gap: 6px 14px; font-size: 14px; }
.hero .meta span { background: rgba(255,255,255,.16); padding: 2px 10px; border-radius: 999px; }
.hero .meta a { color: #e2f7ea; }
.hero-dir { padding: 40px 0 34px; }
.avatar { flex: none; width: 84px; height: 84px; border-radius: 50%; display: grid; place-items: center; font-size: 34px; font-weight: 700; background: rgba(255,255,255,.18); border: 2px solid rgba(255,255,255,.5); color: #fff; }
.avatar.sm { width: 40px; height: 40px; font-size: 16px; background: var(--brand-soft); color: var(--brand); border: 0; }
.filter { margin-top: 18px; width: 100%; max-width: 560px; padding: 12px 18px; border-radius: 999px; border: 0; font: inherit; box-shadow: var(--shadow); }
@media (max-width: 560px) { .hero-in { flex-direction: column; align-items: flex-start; gap: 12px; } .avatar { width: 64px; height: 64px; font-size: 26px; } }

/* Menu giảng viên */
.sitenav-bar { background: var(--surface); border-bottom: 1px solid var(--line); position: sticky; top: 60px; z-index: 20; }
.sitenav { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 2px; }
.sitenav > li > a, .nav-item > button { display: block; padding: 12px 14px; color: var(--text); font: inherit; font-size: 15px; font-weight: 500; background: none; border: 0; cursor: pointer; border-bottom: 3px solid transparent; }
.sitenav > li > a.on, .nav-item > button.on { border-bottom-color: var(--brand); color: var(--brand); }
.sitenav > li > a:hover, .nav-item > button:hover { color: var(--brand); text-decoration: none; }
.nav-item { position: relative; }
.car { font-size: 11px; opacity: .7; }
.drop { display: none; position: absolute; left: 0; top: 100%; min-width: 240px; max-width: 340px; background: var(--surface); border: 1px solid var(--line); border-radius: 10px; box-shadow: var(--shadow); list-style: none; margin: 0; padding: 6px; z-index: 40; }
.nav-item.open .drop { display: block; }
.drop a { display: block; padding: 8px 12px; border-radius: 6px; color: var(--text); font-size: 14px; }
.drop a:hover, .drop a.on { background: var(--brand-soft); color: var(--brand); text-decoration: none; }
.nav-toggle { display: none; margin: 8px 0; padding: 8px 14px; border: 1px solid var(--line); background: var(--surface); color: var(--text); border-radius: 8px; font: inherit; }
@media (max-width: 760px) {
  .nav-toggle { display: inline-block; }
  .sitenav { display: none; flex-direction: column; padding-bottom: 8px; }
  .sitenav.show { display: flex; }
  .drop { position: static; box-shadow: none; border: 0; padding-left: 14px; max-width: none; }
}

/* Bố cục */
.grid { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 28px; padding-top: 24px; padding-bottom: 40px; }
@media (max-width: 900px) { .grid { grid-template-columns: minmax(0, 1fr); } }
.block { margin-bottom: 26px; }
.block-h { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; border-bottom: 2px solid var(--brand); margin-bottom: 12px; }
.block-h h2, .block > h2 { margin: 0 0 6px; font-size: 19px; color: var(--brand); }
.block-h a { font-size: 14px; white-space: nowrap; }
.h1 { font-size: 26px; margin: 4px 0 6px; line-height: 1.3; }
.intro { color: var(--muted); margin: 0 0 6px; }
.count { color: var(--muted); font-size: 14px; margin: 0 0 12px; }
.crumbs { font-size: 14px; color: var(--muted); margin-bottom: 8px; }

.card { display: grid; gap: 14px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; margin-bottom: 10px; box-shadow: var(--shadow); }
.card.has-thumb { grid-template-columns: 132px minmax(0, 1fr); }
.card .thumb img { width: 132px; height: 92px; object-fit: cover; border-radius: 8px; display: block; background: var(--brand-soft); }
.card h3 { margin: 0; font-size: 16.5px; line-height: 1.4; }
.card h3 a { color: var(--text); }
.card h3 a:hover { color: var(--brand); }
.card p { margin: 4px 0 0; color: var(--muted); font-size: 14.5px; }
.sub { color: var(--muted); font-size: 13px; margin-top: 4px; }
@media (max-width: 520px) { .card.has-thumb { grid-template-columns: 88px minmax(0, 1fr); } .card .thumb img { width: 88px; height: 66px; } }

.side .box, .search { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; margin-bottom: 16px; box-shadow: var(--shadow); }
.side h3 { margin: 0 0 8px; font-size: 16px; color: var(--brand); }
.side p { margin: 0 0 6px; font-size: 14.5px; overflow-wrap: anywhere; }
.search { display: flex; gap: 8px; padding: 10px; }
.search input { flex: 1; min-width: 0; padding: 8px 12px; border: 1px solid var(--line); border-radius: 8px; font: inherit; background: var(--bg); color: var(--text); }
.search button { border: 0; background: var(--brand); color: #fff; border-radius: 8px; padding: 0 14px; font: inherit; font-weight: 600; cursor: pointer; }
.links, .pop { margin: 0; padding-left: 18px; font-size: 14.5px; }
.links li, .pop li { margin-bottom: 8px; }
.links small { display: block; color: var(--muted); font-size: 12.5px; }
.side .links { list-style: none; padding: 0; }

/* Bài viết */
.post { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px 26px; box-shadow: var(--shadow); }
.post h1 { margin: 0; font-size: clamp(22px, 3vw, 28px); line-height: 1.3; }
.post .lead { font-weight: 500; color: var(--muted); margin-top: 14px; }
@media (max-width: 560px) { .post { padding: 16px; } }
.content { margin-top: 16px; overflow-wrap: anywhere; }
.content img { max-width: 100% !important; height: auto !important; }
.content table { max-width: 100%; border-collapse: collapse; display: block; overflow-x: auto; }
.content td, .content th { padding: 4px 8px; }
.content table[border] td, .content table[border] th { border: 1px solid var(--line); }
.content iframe { max-width: 100%; border: 0; }
.content iframe[src*="youtube"] { width: 100%; height: auto; aspect-ratio: 16/9; }
.content pre { white-space: pre-wrap; }
.content font, .content span { font-family: inherit !important; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .content * { color: inherit !important; background-color: transparent !important; } }

/* Danh bạ */
.unit { margin-bottom: 22px; }
.unit h2 { font-size: 17px; color: var(--brand); border-bottom: 1px solid var(--line); padding-bottom: 6px; margin: 0 0 10px; }
.unit h2 small { color: var(--muted); font-weight: 500; font-size: 13px; }
.people { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 8px; }
.people a { display: flex; align-items: center; gap: 10px; background: var(--surface); border: 1px solid var(--line); border-radius: 10px; padding: 9px 12px; color: var(--text); }
.people a:hover { border-color: var(--brand); text-decoration: none; }
.people b { display: block; font-weight: 600; font-size: 15px; line-height: 1.3; }
.people small { color: var(--muted); font-size: 12.5px; }

.pager { display: flex; flex-wrap: wrap; gap: 6px; margin: 18px 0; }
.pager a, .pager b, .pager span { padding: 6px 12px; border-radius: 8px; border: 1px solid var(--line); background: var(--surface); font-size: 14px; }
.pager b { background: var(--brand); color: #fff; border-color: var(--brand); }
.empty { background: var(--surface); border: 1px dashed var(--line); border-radius: var(--radius); padding: 30px; text-align: center; color: var(--muted); margin: 20px 0; }
.empty h1 { color: var(--brand); margin: 0; font-size: 48px; }

.foot { border-top: 1px solid var(--line); background: var(--surface); color: var(--muted); font-size: 14px; padding: 18px 0; }
.foot p { margin: 4px 0; }
.foot-own { margin-bottom: 8px; }
.foot-own * { color: inherit !important; font-size: inherit !important; background: none !important; }

/* ===== Bảng tin (mạng xã hội nội bộ) ===== */
.feed-grid { display: grid; grid-template-columns: 240px minmax(0, 1fr) 300px; gap: 20px; padding-top: 20px; padding-bottom: 40px; align-items: start; }
.feed-left, .feed-right { position: sticky; top: 76px; max-height: calc(100vh - 90px); overflow-y: auto; scrollbar-width: thin; }
@media (max-width: 1100px) { .feed-grid { grid-template-columns: 220px minmax(0, 1fr); } .feed-right { grid-column: 2; position: static; max-height: none; } }
@media (max-width: 760px) {
  .feed-grid { grid-template-columns: minmax(0, 1fr); }
  .feed-left, .feed-right { position: static; max-height: none; grid-column: auto; }
  .feed-left { order: 2; } .feed-main { order: 1; } .feed-right { order: 3; }
}
.box { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; margin-bottom: 14px; box-shadow: var(--shadow); }
.box h3 { margin: 0 0 10px; font-size: 15.5px; }
.box h2 { margin: 0 0 8px; font-size: 18px; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.menu-topics { padding: 8px; }
.menu-topics a { display: flex; align-items: center; gap: 10px; padding: 9px 10px; border-radius: 8px; color: var(--text); font-weight: 500; font-size: 15px; }
.menu-topics a span { width: 24px; text-align: center; }
.menu-topics a:hover { background: var(--bg); text-decoration: none; }
.menu-topics a.on { background: var(--brand-soft); color: var(--brand); }
.stat-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.stat { background: var(--bg); border-radius: 10px; padding: 8px 10px; }
.stat b { display: block; font-size: 19px; color: var(--brand); line-height: 1.2; font-variant-numeric: tabular-nums; }
.stat small { color: var(--muted); font-size: 12px; }
@media (max-width: 760px) { .stat-grid { grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); } }

.searchbox { padding: 12px; }
.searchbox .tabs { display: flex; gap: 6px; overflow-x: auto; padding-bottom: 10px; scrollbar-width: none; }
.searchbox .tabs label { flex: none; padding: 6px 12px; border-radius: 999px; border: 1px solid var(--line); font-size: 14px; cursor: pointer; white-space: nowrap; color: var(--muted); }
.searchbox .tabs label.on { background: var(--brand); color: #fff; border-color: var(--brand); }
.searchbox .tabs input { display: none; }
.sb-row { display: flex; gap: 8px; flex-wrap: wrap; }
.sb-row input[type=search] { flex: 1 1 220px; min-width: 0; padding: 10px 14px; border: 1px solid var(--line); border-radius: 10px; font: inherit; background: var(--bg); color: var(--text); }
.sb-row select { flex: 0 1 200px; min-width: 0; padding: 9px 10px; border: 1px solid var(--line); border-radius: 10px; font: inherit; background: var(--bg); color: var(--text); }
.sb-row button { border: 0; background: var(--brand); color: #fff; border-radius: 10px; padding: 0 18px; font: inherit; font-weight: 600; cursor: pointer; min-height: 42px; }

.post-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); margin-bottom: 14px; box-shadow: var(--shadow); overflow: hidden; }
.post-card.is-job { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent) inset, var(--shadow); }
.post-card header { display: flex; align-items: center; gap: 10px; padding: 12px 16px 0; }
.post-card .who { flex: 1; min-width: 0; line-height: 1.3; }
.post-card .who a { color: var(--text); }
.post-card .who small { display: block; color: var(--muted); font-size: 12.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.avatar.md { width: 42px; height: 42px; font-size: 17px; background: var(--brand-soft); color: var(--brand); border: 0; flex: none; }
a.avatar:hover { text-decoration: none; }
.chip { display: inline-block; font-size: 12px; padding: 2px 9px; border-radius: 999px; background: var(--bg); color: var(--muted); border: 1px solid var(--line); white-space: nowrap; max-width: 46%; overflow: hidden; text-overflow: ellipsis; }
.chips .chip { max-width: none; margin: 2px 4px 2px 0; }
.chip.t-baigiang { background: #e8f1fd; color: #1d5fa8; border-color: #c9ddf7; }
.chip.t-baibao { background: #f2ebfd; color: #6a3fb5; border-color: #ddd0f5; }
.chip.t-lylich { background: #fdf3e6; color: #a35b00; border-color: #f4dcb8; }
.chip.t-job { background: #fff6dc; color: #8a6200; border-color: #f0d98a; }
.chip.t-share { background: var(--brand-soft); color: var(--brand); border-color: transparent; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .chip[class*="t-"] { background: var(--bg); color: var(--text); border-color: var(--line); } }
.post-body { display: block; padding: 10px 16px 4px; color: var(--text); }
.post-body:hover { text-decoration: none; }
.post-body:hover b { color: var(--brand); }
.post-body b { display: block; font-size: 17px; line-height: 1.4; }
.post-body .ex { display: block; color: var(--muted); margin-top: 4px; font-size: 15px; }
.post-body.with-img { display: grid; grid-template-columns: minmax(0, 1fr); }
.post-body.with-img img { width: 100%; max-height: 340px; object-fit: cover; border-radius: 10px; margin-bottom: 10px; background: var(--bg); order: 2; }
.post-body.with-img > span { order: 1; margin-bottom: 8px; }
.post-text { padding: 10px 16px 4px; font-size: 15.5px; overflow-wrap: anywhere; }
.post-img { display: block; width: calc(100% - 32px); margin: 8px 16px; border-radius: 10px; max-height: 420px; object-fit: cover; }
.link-prev { display: block; margin: 8px 16px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; background: var(--bg); color: var(--text); }
.link-prev small { display: block; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.post-card footer { display: flex; align-items: center; gap: 16px; padding: 8px 16px 12px; font-size: 14px; flex-wrap: wrap; border-top: 1px solid var(--line); margin-top: 8px; }
.post-card footer a, .post-card footer button.share { color: var(--muted); font-weight: 500; background: none; border: 0; font: inherit; cursor: pointer; padding: 0; }
.post-card footer a:hover, .post-card footer button.share:hover { color: var(--brand); text-decoration: none; }
.views { color: var(--muted); }
.heart { display: inline-flex; align-items: center; gap: 5px; background: var(--bg); border: 1px solid var(--line); border-radius: 999px; padding: 4px 12px; font: inherit; font-weight: 600; color: var(--muted); cursor: pointer; transition: transform .15s; }
.heart .h { font-size: 16px; line-height: 1; }
.heart.on { color: #e0245e; background: #fdeef3; border-color: #f7c6d6; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .heart.on { background: #3a1822; border-color: #6b2a3e; } }
.heart.pop { transform: scale(1.18); }
.heart:disabled { opacity: .6; }
.more { display: block; text-align: center; padding: 12px; border: 1px dashed var(--line); border-radius: var(--radius); background: var(--surface); font-weight: 600; }

.toplist { margin: 0; padding-left: 20px; }
.toplist li { margin-bottom: 10px; font-size: 14.5px; line-height: 1.4; }
.toplist small, .qa-mini small { display: block; color: var(--muted); font-size: 12.5px; }
.who-list { list-style: none; margin: 0; padding: 0; }
.who-list a { display: flex; align-items: center; gap: 10px; padding: 6px 0; color: var(--text); }
.who-list b { display: block; font-size: 14.5px; font-weight: 600; line-height: 1.3; }
.who-list small { color: var(--muted); font-size: 12.5px; }
.who-list a:hover { text-decoration: none; } .who-list a:hover b { color: var(--brand); }
.qa-mini { display: block; padding: 8px 0; border-bottom: 1px solid var(--line); color: var(--text); font-size: 14px; }
.qa-mini:hover { text-decoration: none; color: var(--brand); }
.feed-right .btn-sm, .feed-left .btn-sm { margin-top: 10px; }
.join { border-color: var(--accent); background: linear-gradient(180deg, #fffaf0, var(--surface)); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .join { background: var(--surface); } }
.join ul { margin: 8px 0 0; padding-left: 20px; }
.join-mini { border-top: 3px solid var(--accent); }
.people-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 10px; }
.pcard { display: flex; gap: 10px; padding: 10px; border: 1px solid var(--line); border-radius: 10px; }
.pcard h3 { margin: 0; font-size: 15px; }
.pcard p { margin: 2px 0 0; font-size: 13px; color: var(--muted); }

/* Tư vấn */
.qa { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); margin-bottom: 14px; box-shadow: var(--shadow); overflow: hidden; }
.qa-q, .qa-a { display: flex; gap: 12px; padding: 14px 16px; }
.qa-q { background: var(--bg); }
.qa-q .content, .qa-a .content { margin-top: 0; }
.qa-q small { color: var(--muted); font-size: 12.5px; }
.qa-ic { flex: none; width: 42px; height: 42px; border-radius: 50%; display: grid; place-items: center; background: #fff3d6; color: #9a6b00; font-weight: 700; font-size: 20px; }
.qa-who { margin: 0 0 4px; }
.qa-who small { color: var(--muted); }
.qa .content > :first-child { margin-top: 0; }
.ask label { display: block; font-size: 14px; font-weight: 500; margin-bottom: 10px; }
.ask input, .ask select, .ask textarea { display: block; width: 100%; margin-top: 4px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 8px; font: inherit; background: var(--bg); color: var(--text); }
.ask .hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.note { padding: 10px 12px; border-radius: 8px; margin-bottom: 10px; font-size: 14px; }
.note.ok { background: #ecfdf3; color: #067647; }
.note.err { background: #fef3f2; color: #b42318; }
.side .ask { position: sticky; top: 76px; }
@media (max-width: 900px) { .side .ask { position: static; } }
.stat { min-width: 0; }
.stat b { overflow-wrap: anywhere; }
@media (max-width: 560px) {
  .post-card header { flex-wrap: wrap; }
  .post-card header .chip { order: 3; max-width: 100%; margin-left: 52px; }
  .post-card .who small { white-space: normal; }
  .post-card footer { gap: 12px; font-size: 13.5px; }
}
.more-posts { margin: 6px 16px 0; padding: 10px 12px; background: var(--bg); border-radius: 10px; font-size: 14px; }
.more-posts p { margin: 0 0 6px; color: var(--muted); }
.more-posts ul { margin: 0 0 4px; padding-left: 18px; }
.more-posts li { margin-bottom: 4px; }
.more-posts small { color: var(--muted); }

/* Ảnh đại diện */
.avatar.gen { color: #fff; border: 0; letter-spacing: .5px; font-weight: 700; text-shadow: 0 1px 2px rgba(0,0,0,.15); }
.avatar.has-img { padding: 0; overflow: hidden; background: var(--brand-soft); }
.avatar.has-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.avatar.sm { font-size: 14px; }
.avatar.md { font-size: 16px; }
.avatar.xl { width: 112px; height: 112px; font-size: 38px; border: 4px solid rgba(255,255,255,.85); box-shadow: 0 6px 24px rgba(0,0,0,.25); border-radius: 50%; display: grid; place-items: center; flex: none; }
@media (max-width: 560px) { .avatar.xl { width: 84px; height: 84px; font-size: 28px; } }
.avatar.md, .avatar.sm { box-shadow: 0 0 0 2px var(--surface), 0 0 0 3px var(--line); }
.content iframe.pdf-view { width: 100%; height: 80vh; min-height: 480px; border: 1px solid var(--line); border-radius: 8px; }
.content video, .content audio { width: 100%; max-width: 100%; }
.content .attach a { display: inline-block; padding: 8px 14px; border: 1px solid var(--line); border-radius: 8px; background: var(--bg); font-weight: 600; }
.more-posts ul { margin-top: 0; }
.all-posts { font-weight: 600; font-size: 13.5px; }
@media (max-width: 560px) {
  .post-card .who { flex: 1 1 calc(100% - 56px); }
  .post-card header .chip { margin-left: 52px; max-width: calc(100% - 52px); }
}
/* Menu giảng viên có nhiều mục tên dài: rút gọn trên một dòng */
@media (min-width: 761px) {
  .sitenav > li > a, .nav-item > button { max-width: 240px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; padding: 11px 12px; font-size: 14.5px; }
  .drop a { white-space: normal; }
}
/* Tiêu đề trên bảng tin: cùng cỡ chữ, không in hoa */
.post-body b { font-size: 17px; font-weight: 600; text-transform: none; }
.more-posts li a, .toplist a { font-size: 14.5px; font-weight: 500; text-transform: none; }

/* ===== Trang chủ: thang chữ thống nhất ===== */
.feed-grid {
  --fs-xs: 12.5px;   /* chú thích, thời gian */
  --fs-sm: 13.5px;   /* nút, nhãn */
  --fs-md: 14.5px;   /* danh sách trong box, tóm tắt */
  --fs-lg: 16.5px;   /* tiêu đề bài */
  --fs-h: 15px;      /* tiêu đề box */
  font-size: var(--fs-md);
}
.feed-grid .box h3, .feed-grid .block-h h2, .feed-grid .join h2 {
  font-size: var(--fs-h); font-weight: 700; line-height: 1.35; margin: 0 0 12px; color: var(--text);
  display: flex; align-items: center; gap: 6px;
}
.feed-grid .join h2 { font-size: var(--fs-lg); }
.feed-grid small, .feed-grid .small { font-size: var(--fs-xs); }
.clamp2, .clamp3 { display: -webkit-box; -webkit-box-orient: vertical; overflow: hidden; }
.clamp2 { -webkit-line-clamp: 2; }
.clamp3 { -webkit-line-clamp: 3; }

/* Cột trái */
.feed-grid .menu-topics a { font-size: var(--fs-md); font-weight: 500; padding: 8px 10px; }
.feed-grid .stat-grid { display: block; }
.feed-grid .stat { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; background: none; border-radius: 0; padding: 7px 0; border-bottom: 1px solid var(--line); }
.feed-grid .stat:last-child { border-bottom: 0; padding-bottom: 0; }
.feed-grid .stat small { font-size: var(--fs-sm); color: var(--muted); }
.feed-grid .stat b { display: inline; font-size: var(--fs-md); font-weight: 700; color: var(--brand); white-space: nowrap; line-height: 1.3; }

/* Ô tìm kiếm */
.feed-grid .searchbox .tabs label { font-size: var(--fs-sm); }
.feed-grid .sb-row input[type=search], .feed-grid .sb-row select, .feed-grid .sb-row button { font-size: var(--fs-md); }

/* Thẻ bài */
.feed-grid .post-card .who b { font-size: 15px; font-weight: 600; }
.feed-grid .post-card .who small { font-size: var(--fs-xs); }
.feed-grid .chip { font-size: 12px; }
.feed-grid .post-body b { font-size: var(--fs-lg); font-weight: 600; line-height: 1.45; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 3; overflow: hidden; }
.feed-grid .post-body .ex { font-size: var(--fs-md); line-height: 1.6; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 3; overflow: hidden; }
.feed-grid .post-text { font-size: var(--fs-md); }
.feed-grid .more-posts { font-size: var(--fs-md); }
.feed-grid .more-posts li a { font-size: var(--fs-md); font-weight: 500; }
.feed-grid .more-posts small, .feed-grid .all-posts { font-size: var(--fs-xs); }
.feed-grid .all-posts { font-weight: 600; }
.feed-grid .post-card footer, .feed-grid .post-card footer a, .feed-grid .post-card footer button.share, .feed-grid .heart { font-size: var(--fs-sm); }

/* Cột phải: danh sách cùng kiểu */
.feed-grid .toplist { padding-left: 0; list-style: none; counter-reset: top; }
.feed-grid .toplist li { counter-increment: top; display: grid; grid-template-columns: 22px 1fr; column-gap: 6px; margin-bottom: 12px; font-size: var(--fs-md); line-height: 1.45; }
.feed-grid .toplist li::before { content: counter(top); grid-row: span 2; font-weight: 700; color: var(--brand); font-size: var(--fs-md); }
.feed-grid .toplist a, .feed-grid .qa-mini { color: var(--text); font-weight: 500; font-size: var(--fs-md); line-height: 1.45; }
.feed-grid .toplist a { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; }
.feed-grid .toplist a:hover, .feed-grid .qa-mini:hover { color: var(--brand); text-decoration: none; }
.feed-grid .toplist small, .feed-grid .qa-mini small, .feed-grid .who-list small { font-size: var(--fs-xs); color: var(--muted); font-weight: 400; margin-top: 2px; }
.feed-grid .qa-mini { padding: 10px 0; font-weight: 400; }
.feed-grid .qa-mini:first-of-type { padding-top: 0; }
.feed-grid .who-list b { font-size: var(--fs-md); font-weight: 600; }
.feed-grid .who-list a { padding: 7px 0; }
.feed-grid .box p { font-size: var(--fs-md); line-height: 1.55; margin: 0 0 10px; }
.feed-grid .box p:last-child { margin-bottom: 0; }
.feed-grid .btn-sm { font-size: var(--fs-sm); padding: 7px 16px; }
.feed-grid .join ul { font-size: var(--fs-md); line-height: 1.6; }
.feed-grid .count { font-size: var(--fs-sm); }
.feed-grid .pcard h3 { font-size: 15px; }
.feed-grid .pcard p { font-size: var(--fs-xs); }
.feed-grid .more-posts li a { color: var(--text); }
.feed-grid .more-posts li a:hover { color: var(--brand); text-decoration: none; }
.feed-grid .more-posts li::marker { color: var(--brand); }
/* "Xem nhiều" trên trang giảng viên: cùng kiểu với danh sách ở trang chủ */
.side ol.pop { list-style: none; padding: 0; margin: 0; counter-reset: pop; }
.side ol.pop li { counter-increment: pop; display: grid; grid-template-columns: 22px 1fr; column-gap: 6px; margin-bottom: 12px; font-size: 14.5px; line-height: 1.45; }
.side ol.pop li:last-child { margin-bottom: 0; }
.side ol.pop li::before { content: counter(pop); grid-row: span 2; font-weight: 700; color: var(--brand); }
.side ol.pop a { color: var(--text); font-weight: 500; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; }
.side ol.pop a:hover { color: var(--brand); text-decoration: none; }
.side ol.pop small { color: var(--muted); font-size: 12.5px; margin-top: 2px; }
.side h3 { font-size: 15px; font-weight: 700; color: var(--text); }
.side p { font-size: 14.5px; }
.class-box { border-top: 3px solid var(--accent); }
.cls-list { list-style: none; margin: 0 0 12px; padding: 0; }
.cls-list li { padding: 7px 0; border-bottom: 1px dashed var(--line); font-size: 14.5px; }
.cls-list li:last-child { border-bottom: 0; }
.cls-list small { display: block; color: var(--muted); font-size: 12.5px; }
.class-box .btn { width: 100%; text-align: center; margin-bottom: 6px; }
