.ab-page { max-width: 1100px; margin: 0 auto; padding: 0 16px 20px; }

.ab-loading { display: flex; justify-content: center; padding: 60px 20px; }
.ab-loading p { font-size: 13.5px; color: var(--text-2); margin: 0; }

/* ═══════════════════════════════════════════════════════════
   HERO — ảnh chân dung + tên + chức danh + giới thiệu ngắn. Có lớp trang trí (blob mờ + lưới
   chấm nhạt + vòng hào quang xoay quanh ảnh) để nền không bị trơ, "có hồn" hơn 1 gradient phẳng.
   ═══════════════════════════════════════════════════════════ */
.ab-hero {
  position: relative; overflow: hidden;
  /* Thanh nav trên mobile là position:fixed (không đẩy body qua padding như ở desktop) — phải tự
     chừa chỗ bằng --nav-h, giống hệt cách .pg-hero làm (xem style.css). Thiếu dòng này thì phần
     đầu hero (badge/ảnh) bị nav che mất trên mobile (--nav-h=60px), dù desktop (--nav-h=0px, body
     đã tự chừa chỗ topbar riêng) vẫn nhìn bình thường nên dễ bỏ sót khi chỉ test trên desktop. */
  padding: calc(var(--nav-h, 60px) + 34px) 20px 78px; text-align: center;
  background: linear-gradient(160deg, var(--primary-light) 0%, var(--bg) 65%);
  border-bottom: 1.5px solid var(--border);
}
.ab-hero::before, .ab-hero::after {
  content: ''; position: absolute; border-radius: 50%; filter: blur(70px); pointer-events: none;
}
.ab-hero::before { width: 360px; height: 360px; background: var(--primary-mid); opacity: .22; top: -170px; left: -110px; }
.ab-hero::after  { width: 300px; height: 300px; background: var(--gold);       opacity: .16; bottom: -150px; right: -90px; }

/* Lưới chấm nhạt phủ toàn hero, mờ dần ra rìa (mask) — tạo kết cấu mà không rối mắt. */
.ab-hero-pattern {
  position: absolute; inset: 0; pointer-events: none;
  background-image: radial-gradient(var(--border) 1.4px, transparent 1.4px);
  background-size: 26px 26px; opacity: .5;
  -webkit-mask-image: radial-gradient(ellipse 70% 60% at 50% 40%, black 0%, transparent 75%);
  mask-image: radial-gradient(ellipse 70% 60% at 50% 40%, black 0%, transparent 75%);
}

.ab-hero-inner { position: relative; max-width: 720px; margin: 0 auto; display: flex; flex-direction: column; align-items: center; }

.ab-hero-photo-wrap { position: relative; margin-bottom: 26px; }
.ab-hero-photo-wrap::before {
  content: ''; position: absolute; inset: -13px; border-radius: 50%; z-index: 0;
  background: conic-gradient(from 0deg, var(--primary), var(--gold), var(--primary-mid), var(--primary));
  opacity: .4; filter: blur(3px);
  animation: abHaloSpin 12s linear infinite;
}
@keyframes abHaloSpin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .ab-hero-photo-wrap::before { animation: none; } }

.ab-hero-photo {
  position: relative; z-index: 1;
  width: 160px; height: 160px; border-radius: 50%; object-fit: cover; display: block;
  border: 5px solid var(--bg-card); box-shadow: 0 16px 38px -10px rgba(29,111,242,.4), var(--shadow-md);
}
.ab-hero-photo-fallback {
  display: flex; align-items: center; justify-content: center; color: var(--text-3);
  background: linear-gradient(135deg, var(--bg-hover), var(--bg-card));
}

.ab-hero-badge {
  display: inline-flex; align-items: center; gap: 6px; margin-bottom: 12px;
  font-size: 12px; font-weight: 800; letter-spacing: .3px; color: var(--primary-dark);
  background: var(--bg-card); border: 1px solid var(--primary-light);
  padding: 5px 14px; border-radius: var(--radius-pill); box-shadow: var(--shadow-sm);
}
.ab-hero-name { font-size: 32px; font-weight: 800; color: var(--text); margin: 0 0 16px; text-wrap: balance; }

/* Câu giới thiệu ngắn ("Mình tự học đạt 985 TOEIC"...) — chữ đậm màu thương hiệu, không viền/nền/
   icon (thử pill+icon lấp lánh trước đó, user thấy "tô quá, ra vẻ khoe khoang", bỏ hẳn). Chỉ còn
   plain text nhưng vẫn có màu + độ đậm riêng để không lẫn vào chữ mô tả thường. Có margin-bottom
   RIÊNG (thay vì để .ab-hero-text tự kết thúc ngay sau nó) — .ab-stats-row bên dưới có margin-top
   ÂM cố định (-47px desktop/-39px mobile) để thẻ đè lên viền dưới hero, khoảng cách thật giữa
   dòng chữ này và thẻ = padding-bottom hero trừ đi số âm đó, LUÔN cố định bất kể nội dung dài hay
   ngắn — nên phải cộng thêm margin-bottom ở đây mới nới được khoảng cách, sửa ở nơi khác không ăn
   thua (đã từng nhầm khi tưởng bỏ chip là đủ).
   ═══════════════════════════════════════════════════════════ */
.ab-hero-intro {
  font-size: 15px; font-weight: 600; line-height: 1.7; color: var(--primary-dark);
  margin: 0 0 22px; max-width: 520px; text-wrap: balance;
}

@media (max-width: 560px) {
  .ab-hero { padding: calc(var(--nav-h, 60px) + 26px) 18px 52px; }
  .ab-hero-photo { width: 128px; height: 128px; }
  .ab-hero-photo-wrap::before { inset: -10px; }
  .ab-hero-name { font-size: 24px; }
  .ab-hero-intro { font-size: 13.5px; margin-bottom: 18px; }
}

/* ═══════════════════════════════════════════════════════════
   CON SỐ ẤN TƯỢNG
   ═══════════════════════════════════════════════════════════ */
/* margin-top âm = -1/2 chiều cao thẻ (~93px), để đường viền dưới hero (.ab-hero border-bottom)
   cắt NGAY GIỮA mỗi thẻ theo chiều dọc, thay vì lệch lên gần đỉnh thẻ như trước. */
.ab-stats-row {
  display: flex; flex-wrap: wrap; justify-content: center; gap: 16px;
  margin: -47px 0 48px; position: relative; z-index: 1;
}
.ab-stat {
  flex: 1; min-width: 140px; max-width: 220px; text-align: center;
  background: var(--bg-card); border: 1.5px solid var(--border); border-radius: var(--radius);
  padding: 20px 16px; box-shadow: var(--shadow-md);
}
.ab-stat-value { font-size: 27px; font-weight: 800; color: var(--primary); line-height: 1.2; }
.ab-stat-label { font-size: 12px; font-weight: 600; color: var(--text-2); margin-top: 4px; line-height: 1.4; }

@media (max-width: 560px) {
  .ab-stats-row { margin-top: -39px; gap: 10px; }
  .ab-stat { min-width: 104px; padding: 15px 10px; }
  .ab-stat-value { font-size: 22px; }
}

/* ═══════════════════════════════════════════════════════════
   TIMELINE — bọc trong 1 "khung nền" riêng (gradient nhạt + blob mờ ở góc) để không trơ trọi
   nền trắng; đường nối dọc chính giữa (desktop), xen kẽ trái/phải; mobile dồn về 1 cột bên trái.
   ═══════════════════════════════════════════════════════════ */
.ab-timeline-section {
  position: relative; overflow: hidden;
  margin: 30px 0 44px; padding: 52px 40px 26px; border-radius: 28px;
  background: linear-gradient(180deg, var(--bg-hover) 0%, var(--bg) 100%);
  border: 1.5px solid var(--border);
}
.ab-timeline-section::before, .ab-timeline-section::after {
  content: ''; position: absolute; border-radius: 50%; filter: blur(80px); pointer-events: none;
}
.ab-timeline-section::before { width: 320px; height: 320px; background: var(--primary-mid); opacity: .10; top: -120px; right: -70px; }
.ab-timeline-section::after  { width: 280px; height: 280px; background: var(--gold);        opacity: .10; bottom: -120px; left: -70px; }

.ab-timeline-title {
  position: relative;
  font-size: 23px; font-weight: 800; color: var(--text); text-align: center;
  margin: 0 0 38px; text-wrap: balance;
}

.ab-timeline { position: relative; padding: 6px 0 26px; }
/* Đường kẻ mờ dần ở cuối (thay vì cắt cụt) + 1 chấm nhỏ nhấp nháy ngay dưới đó — gợi ý nhẹ nhàng
   "hành trình còn tiếp diễn", không dùng mũi tên to dễ bị hiểu lầm thành nút cuộn trang. */
.ab-timeline::before {
  content: ''; position: absolute; left: 50%; top: 8px; bottom: 22px; width: 2px;
  background: linear-gradient(to bottom, var(--border) 0%, var(--border) 75%, transparent 100%);
  transform: translateX(-50%);
}
.ab-timeline::after {
  content: ''; position: absolute; left: 50%; bottom: 4px; width: 7px; height: 7px;
  border-radius: 50%; background: var(--primary);
  transform: translateX(-50%); opacity: .4;
  animation: abTimelineDotPulse 2.2s ease-in-out infinite;
}
@keyframes abTimelineDotPulse {
  0%, 100% { opacity: .3; transform: translateX(-50%) scale(1); }
  50%      { opacity: .8; transform: translateX(-50%) scale(1.5); }
}
@media (prefers-reduced-motion: reduce) { .ab-timeline::after { animation: none; opacity: .5; } }

.ab-ms {
  position: relative; width: 50%; padding: 0 0 48px 0;
  opacity: 0; animation: abMsIn .5s ease forwards;
}
.ab-ms:nth-child(odd)  { left: 0; padding-right: 48px; text-align: right; }
.ab-ms:nth-child(even) { left: 50%; padding-left: 48px; text-align: left; }
@keyframes abMsIn { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }

/* Chấm tròn đơn giản trên trục — luôn 1 kích thước cố định bất kể nội dung mốc, không phụ thuộc
   độ dài nhãn thời gian (tránh lặp lại lỗi lệch layout của bản badge-trên-trục trước đó). */
.ab-ms-dot {
  position: absolute; top: 6px; width: 14px; height: 14px; border-radius: 50%;
  background: var(--primary); box-shadow: 0 0 0 4px var(--bg), 0 0 0 5.5px var(--primary-light);
  z-index: 2;
}
.ab-ms:nth-child(odd)  .ab-ms-dot { right: -8px; }
.ab-ms:nth-child(even) .ab-ms-dot { left: -8px; }

.ab-ms-card {
  display: inline-block; text-align: left; max-width: 100%;
  background: var(--bg-card); border: 1.5px solid var(--border); border-radius: var(--radius);
  padding: 22px 24px; box-shadow: var(--shadow-sm);
}

/* Nhãn thời gian — TỰ DO độ dài (VD "2019", "2022-2025", "Từ đầu năm 2026") nên đặt HẲN bên
   trong thẻ, co giãn theo độ rộng thẻ, không bao giờ tràn ra ngoài đè lên phần tử khác. To/đậm/
   nổi bật rõ hơn hẳn 1 dòng chữ thường để vẫn là điểm neo mắt nhìn đầu tiên của mỗi mốc. */
.ab-ms-year-badge {
  display: inline-block; margin-bottom: 10px; padding: 6px 14px; border-radius: 10px;
  background: linear-gradient(135deg, var(--primary), var(--primary-mid));
  color: #fff; font-size: 14.5px; font-weight: 800; letter-spacing: .2px; line-height: 1.3;
  box-shadow: 0 6px 14px -4px rgba(29,111,242,.5);
}
.ab-ms-title { font-size: 16px; font-weight: 800; color: var(--text); margin-bottom: 8px; line-height: 1.35; }

.ab-ms-desc { font-size: 13.5px; line-height: 1.65; color: var(--text-2); margin: 0; }

/* Mô tả nhiều dòng — gạch đầu dòng tròn, thụt lề đều (cùng ngôn ngữ hình ảnh với .kh-content-list
   bên khoa-hoc.css) — chỉ áp dụng khi admin xuống hàng từ 2 dòng trở lên. */
.ab-ms-desc-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 7px; }
.ab-ms-desc-list li {
  position: relative; padding-left: 18px;
  font-size: 13.5px; line-height: 1.6; color: var(--text-2);
}
.ab-ms-desc-list li::before {
  content: ''; position: absolute; left: 0; top: 8px; width: 6px; height: 6px;
  border-radius: 50%; background: var(--primary);
}

/* Lưới ảnh minh hoạ — 1 ảnh hiện NGUYÊN kích thước tự nhiên (không ép khung, không bao giờ bị
   cắt); 2+ ảnh xếp lưới 2 cột nhưng dùng object-fit:contain (không phải cover) + nền nhạt lấp
   khoảng trống — đảm bảo ảnh luôn hiện ĐỦ dù dọc hay ngang. Bấm 1 ảnh mở lightbox xem full. */
.ab-ms-gallery { margin-top: 14px; max-width: 460px; display: grid; gap: 8px; }
.ab-ms-gallery[data-count="1"] { grid-template-columns: 1fr; }
.ab-ms-gallery[data-count="2"] { grid-template-columns: repeat(2, 1fr); }

.ab-ms-img {
  display: block; border: 1px solid var(--border);
  cursor: zoom-in; transition: transform .15s ease, box-shadow .15s ease;
}
.ab-ms-gallery[data-count="1"] .ab-ms-img { width: 100%; height: auto; border-radius: 14px; }
.ab-ms-gallery[data-count="2"] .ab-ms-img {
  width: 100%; aspect-ratio: 4 / 3; object-fit: contain;
  background: var(--bg-hover); padding: 5px; border-radius: 12px; box-sizing: border-box;
}
.ab-ms-img:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); }

.ab-lightbox-overlay {
  position: fixed; inset: 0; z-index: 10001; background: rgba(15,23,42,.85);
  display: flex; align-items: center; justify-content: center; padding: 24px;
  cursor: zoom-out; animation: abFadeIn .15s ease;
}
.ab-lightbox-img {
  max-width: 100%; max-height: 100%; border-radius: 12px; display: block;
  box-shadow: 0 20px 60px rgba(0,0,0,.5);
}
@keyframes abFadeIn { from { opacity: 0; } to { opacity: 1; } }

.ab-ms-link {
  display: inline-flex; align-items: center; gap: 6px; margin-top: 14px;
  font-size: 12.5px; font-weight: 700; color: var(--primary); text-decoration: none;
}
.ab-ms-link:hover { text-decoration: underline; }

@media (max-width: 760px) {
  .ab-timeline-section { padding: 42px 20px 18px; border-radius: 22px; }
  .ab-timeline::before, .ab-timeline::after { left: 8px; }
  .ab-ms, .ab-ms:nth-child(odd), .ab-ms:nth-child(even) {
    width: 100%; left: 0; padding: 0 0 40px 34px; text-align: left;
  }
  .ab-ms:nth-child(odd) .ab-ms-dot, .ab-ms:nth-child(even) .ab-ms-dot { left: 2px; right: auto; }
  .ab-ms-card { display: block; }
  .ab-ms-gallery { max-width: 100%; }
}

/* ═══════════════════════════════════════════════════════════
   LỜI KẾT CUỐI TRANG — chủ ý KHÔNG quảng cáo/CTA khóa học ở đây (xem outroHtml() trong
   gioi-thieu.js), chỉ 1 lời chúc ấm áp, trang trí nhẹ nhàng cùng ngôn ngữ hình ảnh với hero.
   ═══════════════════════════════════════════════════════════ */
.ab-outro-section {
  position: relative; overflow: hidden;
  margin: 8px 0 24px; padding: 46px 24px; border-radius: 24px; text-align: center;
  background: linear-gradient(160deg, var(--primary-light) 0%, var(--bg-card) 68%);
  border: 1.5px solid var(--border);
}
.ab-outro-pattern {
  position: absolute; inset: 0; pointer-events: none;
  background-image: radial-gradient(var(--primary) 1.4px, transparent 1.4px);
  background-size: 24px 24px; opacity: .08;
  -webkit-mask-image: radial-gradient(ellipse 80% 100% at 50% 0%, black 0%, transparent 80%);
  mask-image: radial-gradient(ellipse 80% 100% at 50% 0%, black 0%, transparent 80%);
}
.ab-outro-icon {
  position: relative; width: 52px; height: 52px; margin: 0 auto 18px; border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), var(--primary-mid));
  color: #fff; display: flex; align-items: center; justify-content: center;
  box-shadow: 0 10px 26px -8px rgba(29,111,242,.5);
}
.ab-outro-text {
  position: relative; font-size: 18px; font-weight: 700; color: var(--text);
  line-height: 1.7; margin: 0; text-wrap: balance;
}

@media (max-width: 560px) {
  .ab-outro-section { padding: 36px 20px; }
  .ab-outro-text { font-size: 16px; }
}
