/* 4T — Đăng ký & thanh toán khoá học ([t4_dang_ky_khoa_hoc]).
   Khớp phong cách trang khoá học (49-nhom-khoa-hoc.css): thẻ trắng bo 10 +
   bóng nhẹ như '.t4kh-form', ô nhập như form CF7 của trang (48px, nền #FCFBF8,
   viền #E3DED4, bo 5), nút nền '--t4-mang-la-nen' chữ không viết hoa, chip
   nhãn như '.t4-label > p'. Không có node Figma cho khối này — khớp theo trang thật.
   Luật 849/850: phần riêng từng khổ bọc @media; phần chung là chủ ý cho cả hai khổ. */

.t4dk {
  box-sizing: border-box;
  max-width: 1056px;
  margin: 0 auto;
  font-family: Manrope, -apple-system, system-ui, sans-serif;
  color: var(--t4-text, #1F1F1F);
}
.t4dk *, .t4dk *::before, .t4dk *::after { box-sizing: border-box; }
/* Cột nội dung trang khoá học là flex dọc, xếp section bằng 'order'
   (t4kh-than 1 · t4kh-than2 3 · t4kh-cta 4). Thiếu dòng này section đăng ký
   mang order 0 và nhảy lên đầu trang, trên cả phần giới thiệu. */
.t4dk-sec { order: 2; }

.t4dk .t4dk-the {
  max-width: 760px;
  margin: 0 auto;
  background: var(--t4-white, #fff);
  border-radius: 10px;
  box-shadow: 0 4px 24px rgba(0, 0, 0, .06);
}
.t4dk .t4dk-the + .t4dk-the { margin-top: 24px; }
.t4dk .t4dk-the > :last-child { margin-bottom: 0; }

.t4dk .t4dk-nhan {
  display: table;
  margin: 0 auto 16px;
  padding: 5px 9px;
  border-radius: 4px;
  background: var(--t4-mang-la-nen, #3E7959);
  color: var(--t4-white, #fff);
  font-size: 14px; line-height: 19px; font-weight: 500;
}
.t4dk .t4dk-td {
  margin: 0 0 12px;
  font-family: var(--t4-font-head, 'Playfair Display', Georgia, serif);
  font-weight: 700;
  color: var(--t4-dark-moss, #155446);
  text-align: center;
}
.t4dk .t4dk-mo {
  margin: 0 0 20px;
  font-size: 16px; line-height: 26px;
  text-align: center;
}
.t4dk .t4dk-gia { color: var(--t4-dark-moss, #155446); font-weight: 800; }
.t4dk .t4dk-mo--tien { margin-top: -8px; }
.t4dk .t4dk-dong dd.t4dk-cau-phan {
  flex-basis: 100%; margin-top: -2px;
  font-size: 13px; line-height: 20px; font-weight: 500; color: #666;
  text-transform: none; letter-spacing: 0;
}
.t4dk .t4dk-ma { color: var(--t4-nhan-manh-chu, #9E5F24); letter-spacing: .5px; font-weight: 800; }

/* Thông báo */
.t4dk .t4dk-bao {
  margin: 0 0 20px;
  padding: 12px 16px;
  border-left: 4px solid var(--t4-camel, #CF9156);
  border-radius: 5px;
  background: #FFF8EC;
  font-size: 15px; line-height: 24px;
}
.t4dk .t4dk-bao a { color: var(--t4-dark-moss, #155446); font-weight: 700; text-decoration: underline; }
.t4dk .t4dk-bao--loi { border-left-color: #C0392B; background: #FDECEC; }
.t4dk .t4dk-bao--thu { border-left-color: #C0392B; background: #FDECEC; color: #A61B1B; font-weight: 800; text-align: center; }
.t4dk .t4dk-ghi-qt { margin: 0; font-size: 13px; color: #A61B1B; }

/* Form */
.t4dk .t4dk-form { margin: 0; }
.t4dk .t4dk-luoi { display: grid; grid-template-columns: 1fr; gap: 12px 16px; }
.t4dk .t4dk-o { margin: 0; min-width: 0; }
.t4dk .t4dk-o-nhan {
  display: block; margin: 0;
  font-size: 16px; line-height: 30px; font-weight: 700;
  color: var(--t4-text, #1F1F1F);
}
.t4dk .t4dk-sao { color: #C0392B; }
.t4dk .t4dk-o input,
.t4dk .t4dk-o select {
  display: block; width: 100%; max-width: 100%;
  height: 48px; margin: 8px 0 0; padding: 13px 15px;
  border: 1px solid #E3DED4; border-radius: 5px;
  background-color: #FCFBF8; box-shadow: none;
  font-family: inherit; font-size: 14px; line-height: 22px; color: #212529;
}
.t4dk .t4dk-o select { padding-top: 0; padding-bottom: 0; }
.t4dk .t4dk-o input:focus,
.t4dk .t4dk-o select:focus {
  outline: 2px solid var(--t4-leaf, #458763); outline-offset: 1px;
  border-color: var(--t4-leaf, #458763); background-color: #fff;
}
.t4dk .t4dk-o.t4dk-o--sai input,
.t4dk .t4dk-o.t4dk-o--sai select { border-color: #C0392B; background-color: #FFF6F6; }
.t4dk .t4dk-o-loi { display: block; margin-top: 4px; font-size: 13px; line-height: 18px; color: #C0392B; }

.t4dk .t4dk-nut {
  display: flex; align-items: center; justify-content: center;
  width: 100%; min-height: 48px; margin: 24px 0 0; padding: 0 20px;
  border: 0; border-radius: 5px;
  background: var(--t4-mang-la-nen, #3E7959); color: var(--t4-white, #fff);
  font-family: inherit; font-size: 16px; line-height: 24px; font-weight: 700;
  text-transform: none; letter-spacing: 0; cursor: pointer;
}
.t4dk .t4dk-nut:hover { background: var(--t4-dark-moss, #155446); }
.t4dk .t4dk-nut[disabled] { opacity: .75; cursor: progress; }
.t4dk .t4dk-ghi { margin: 14px 0 0; font-size: 13px; line-height: 20px; color: #666; text-align: center; }
.t4dk .t4dk-ghi--trai { text-align: left; }

/* Thanh toán */
.t4dk .t4dk-tt { display: grid; grid-template-columns: 1fr; gap: 24px; align-items: start; }
.t4dk .t4dk-ds { margin: 0; padding: 0; }
.t4dk .t4dk-dong {
  display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline;
  gap: 4px 12px; padding: 10px 0; border-bottom: 1px dashed #E3DED4;
}
.t4dk .t4dk-dong:first-child { padding-top: 0; }
.t4dk .t4dk-dong dt { margin: 0; font-size: 14px; line-height: 22px; font-weight: 500; color: #666; }
.t4dk .t4dk-dong dd {
  margin: 0; font-size: 17px; line-height: 26px; font-weight: 700;
  text-align: right; overflow-wrap: anywhere;
}
.t4dk .t4dk-dong--nd { background: #FFF8EC; margin: 6px -12px 0; padding: 10px 12px; border-radius: 6px; border-bottom: 0; }
.t4dk .t4dk-chep {
  display: inline-block; vertical-align: middle;
  min-height: 0; margin: 0 0 0 6px; padding: 2px 10px;
  border: 1px solid var(--t4-mang-la-nen, #3E7959); border-radius: 4px;
  background: transparent; color: var(--t4-mang-la-nen, #3E7959);
  font-family: inherit; font-size: 13px; line-height: 20px; font-weight: 600;
  text-transform: none; letter-spacing: 0; cursor: pointer;
}
.t4dk .t4dk-chep.da-chep { background: var(--t4-mang-la-nen, #3E7959); color: #fff; }
.t4dk .t4dk-qr { margin: 0; text-align: center; }
.t4dk .t4dk-qr img {
  display: block; width: 240px; max-width: 100%; height: auto; margin: 0 auto;
  padding: 8px; border: 1px solid #E3DED4; border-radius: 8px; background: #fff;
}
.t4dk .t4dk-qr figcaption { margin-top: 8px; font-size: 13px; line-height: 18px; color: #666; }

/* Khối "Thông tin xuất hoá đơn" — chung cho cả hai khổ (chủ ý) */
.t4dk .t4dk-hd { margin: 16px 0 0; padding: 14px 16px 16px; border: 1px solid #E3DED4; border-radius: 8px; background: #FCFBF8; min-width: 0; }
.t4dk .t4dk-hd legend.t4dk-o-nhan { padding: 0 6px; margin: 0 0 0 -6px; width: auto; border: 0; font-size: 16px; line-height: 24px; }
.t4dk .t4dk-hd-loai { display: flex; flex-wrap: wrap; gap: 8px 20px; margin: 0 0 8px; }
.t4dk .t4dk-hd-chon { display: inline-flex; align-items: center; gap: 6px; margin: 0; font-size: 15px; line-height: 24px; font-weight: 600; cursor: pointer; }
.t4dk .t4dk-hd-chon input { width: 18px; height: 18px; margin: 0; accent-color: var(--t4-mang-la-nen, #3E7959); }
.t4dk .t4dk-hd-phan { margin-top: 4px; }
.t4dk .t4dk-hd-phan[hidden] { display: none; }
.t4dk .t4dk-hd-tieu { margin: 4px 0 0; font-size: 13px; line-height: 20px; color: #666; }
.t4dk.t4dk .t4dk-co-js .t4dk-hd-tieu { display: none; }
.t4dk .t4dk-o-ghi { display: block; margin-top: 4px; font-size: 13px; line-height: 18px; color: #666; }
.t4dk .t4dk-tuy { font-size: 13px; font-weight: 500; color: #888; }
.t4dk .t4dk-hd .t4dk-o input { background-color: #fff; }

/* Nút "Lưu ảnh QR" (tải PNG) — chung cho cả hai khổ */
.t4dk .t4dk-luu-qr { display: flex; align-items: center; justify-content: center; width: 100%; min-height: 44px; margin: 14px 0 0; padding: 0 16px; border: 1px solid var(--t4-mang-la-nen, #3E7959); border-radius: 5px; background: #fff; color: var(--t4-mang-la-nen, #3E7959); font-size: 15px; font-weight: 700; text-decoration: none; }
.t4dk .t4dk-luu-qr:hover { background: var(--t4-mang-la-nen, #3E7959); color: #fff; }

/* ── Máy tính ≥ 850px ── */
@media (min-width: 850px) {
  .t4dk { padding: 64px 0; }
  .t4dk .t4dk-the { padding: 48px 60px; }
  .t4dk .t4dk-td { font-size: 32px; line-height: 42px; }
  .t4dk .t4dk-luoi { grid-template-columns: 1fr 1fr; }
  .t4dk .t4dk-o--rong { grid-column: 1 / -1; }
  .t4dk .t4dk-tt { grid-template-columns: minmax(0, 1fr) 260px; gap: 32px; }
}

/* ── Điện thoại ≤ 849px ── */
@media (max-width: 849px) {
  .t4dk { padding: 40px 16px; }
  .t4dk .t4dk-the { padding: 28px 20px; }
  .t4dk .t4dk-td { font-size: 26px; line-height: 34px; }
  .t4dk .t4dk-mo { font-size: 15px; line-height: 24px; }
  .t4dk .t4dk-qr img { width: 220px; }
  .t4dk .t4dk-dong dd { font-size: 16px; }
}

/* ── Bản gọn: nằm TRONG ô form '.t4kh-form' cạnh phần giới thiệu (kieu="gon") ──
   Ô đó đã có nền trắng, bo góc, đệm riêng ⇒ bỏ thẻ/đệm của khối; cột hẹp
   (~388px chữ ở máy tính) ⇒ một cột, QR lên đầu. Chung cho cả hai khổ. */
.t4dk.t4dk--gon { max-width: none; padding: 0; }
.t4dk--gon .t4dk-the { max-width: none; padding: 0; background: transparent; border-radius: 0; box-shadow: none; }
.t4dk--gon .t4dk-the--form .t4dk-mo { font-size: 15px; line-height: 24px; }
.t4dk--gon .t4dk-luoi { grid-template-columns: 1fr; }
.t4dk--gon .t4dk-td { font-size: 24px; line-height: 32px; }
.t4dk--gon .t4dk-tt { grid-template-columns: 1fr; gap: 16px; }
.t4dk--gon .t4dk-qr { order: -1; }
.t4dk--gon .t4dk-qr img { width: 220px; }

/* Dòng nhỏ "(chưa gồm VAT 8%)" cạnh giá ở ô giá đầu trang ([t4dk_chua_vat] trong '.t4kh-hp').
   Nằm NGOÀI '.t4dk' ⇒ chọn theo lớp riêng. Chung cho cả hai khổ (chủ ý). */
.t4dk-chua-vat {
  display: inline-block; margin-left: 4px;
  font-size: 12px; line-height: 16px; font-weight: 600;
  letter-spacing: 0; color: #979797; vertical-align: baseline; white-space: nowrap;
}
