/* src/css/tai-khoan.css – trang Tài khoản (tai-khoan.js). Desktop: trang phủ dưới menubar · mobile: dưới thanh trên cùng
   Màu theo theme: dùng chung bảng --hp-* của Trang chủ + --tk-*, --ui-ok / --ui-err (theme.css). */
.acc-page { display: none; }
body[data-layout="desktop"].mb-page-acc .acc-page,
body[data-layout="mobile"].acc-open .acc-page {
  display: block;
  position: fixed; left: 0; right: 0;
  overflow-y: auto; overscroll-behavior: contain;
  box-sizing: border-box;
  background: var(--hp-nen);   /* cùng nền Trang chủ */
  color: var(--hp-chu); font: 15px/1.5 Arial, 'Helvetica Neue', sans-serif;
}
body[data-layout="desktop"].mb-page-acc .acc-page { top: 44px; bottom: 0; z-index: 940; }               /* dưới menubar (950) */
body[data-layout="mobile"].acc-open .acc-page {
  top: calc(48px + env(safe-area-inset-top)); bottom: 0; z-index: 8970;                                  /* trên Học / Ôn tập, dưới thanh trên cùng */
  padding-bottom: env(safe-area-inset-bottom);
}
body[data-layout="mobile"].acc-open { overflow: hidden; }

.acc-wrap { max-width: 720px; margin: 0 auto; padding: 40px 24px 56px; display: flex; flex-direction: column; gap: 18px; }
.acc-dau { display: flex; align-items: center; gap: 16px; }
.acc-kicker { font: 22px "Noto Serif CJK SC", "Songti SC", "SimSun", serif; color: var(--hp-vang-chu); letter-spacing: .2em; }
.acc-av {
  flex: 0 0 auto; display: flex; align-items: center; justify-content: center;
  width: 64px; height: 64px; border-radius: 50%;
  background: var(--tk-av); color: var(--tk-av-chu); font: bold 28px Arial, sans-serif;
}
.acc-dau-chu { min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.acc-ten { margin: 0; font: italic 700 30px/1.2 'Playfair Display', Georgia, serif; color: var(--hp-tieu); overflow-wrap: anywhere; }
.acc-email { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; color: var(--hp-p); overflow-wrap: anywhere; }
.acc-nhan-xm { padding: 2px 8px; border-radius: 999px; font-size: 12px; font-weight: bold; color: var(--tk-canh); border: 1px solid currentColor; }
.acc-nhan-xm.ok { color: var(--hp-c-moc); }

.acc-the {
  padding: 18px 20px; border-radius: 16px;
  background: var(--hp-the); border: 1px solid var(--hp-vien);
}
.acc-the h2 { margin: 0 0 6px; font: 700 18px 'Playfair Display', Georgia, serif; color: var(--hp-tieu); }
.acc-the p { margin: 0 0 12px; color: var(--hp-p); }
.acc-canh { border-color: var(--tk-canh); }
.acc-dong { display: flex; justify-content: space-between; gap: 16px; padding: 10px 0; border-bottom: 1px solid var(--hp-ke); }
.acc-dong:last-of-type { border-bottom: 0; }
.acc-nhan { flex: 0 0 auto; color: var(--hp-chan-mo); }
.acc-gt { min-width: 0; text-align: right; color: var(--hp-tieu); font-weight: bold; overflow-wrap: anywhere; }
.acc-mo { display: block; font-weight: normal; font-size: 13px; color: var(--hp-chan-mo); }
.acc-nut-hoc { margin-top: 10px; }
.acc-cuoi { display: flex; justify-content: center; padding-top: 6px; }
.acc-thoat { color: var(--ui-err); border-color: currentColor; }

/* ── Ví xu: số dư, nút Nạp xu, lịch sử giao dịch ── */
.acc-vi-dau { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; padding-bottom: 14px; margin-bottom: 8px; border-bottom: 1px solid var(--hp-ke); }
.acc-vi-so { display: flex; align-items: center; gap: 12px; }
.acc-vi-so > div { display: flex; flex-direction: column; }
.acc-vi-so b { font: 700 28px/1.15 'Playfair Display', Georgia, serif; color: var(--hp-tieu); font-variant-numeric: tabular-nums; }
.acc-vi-so small { font: 600 14px Arial, sans-serif; color: var(--hp-p); }
.acc-nap {
  display: inline-flex; align-items: center; height: 40px; padding: 0 18px;
  border: 0; border-radius: 12px; cursor: pointer;
  background: var(--tk-av); color: var(--tk-av-chu); font: 700 14px Arial, sans-serif;
  transition: filter .15s, transform .15s;
}
.acc-nap:hover { filter: brightness(1.05); transform: translateY(-1px); }
.acc-nap:focus-visible { outline: 2px solid var(--hp-nhan); outline-offset: 2px; }
.acc-gd-ds { margin: 0; padding: 0; list-style: none; }
.acc-gd { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--hp-ke); }
.acc-gd:last-child { border-bottom: 0; }
.acc-gd-chu, .acc-gd-so { display: flex; flex-direction: column; min-width: 0; }
.acc-gd-chu b { font-weight: 600; color: var(--hp-tieu); overflow-wrap: anywhere; }
.acc-gd-chu span, .acc-gd-so span { font-size: 12px; color: var(--hp-chan-mo); }
.acc-gd-so { flex: 0 0 auto; align-items: flex-end; text-align: right; font-variant-numeric: tabular-nums; }
.acc-gd-so b { font-size: 15px; color: var(--hp-p); }
.acc-gd-so b.cong { color: var(--ui-ok); }
.acc-gd-so b.tru { color: var(--ui-err); }
.acc-them { display: flex; justify-content: center; padding-top: 10px; }

body[data-layout="mobile"] .acc-wrap { padding: 24px 16px 40px; gap: 14px; }
body[data-layout="mobile"] .acc-av { width: 52px; height: 52px; font-size: 22px; }
body[data-layout="mobile"] .acc-ten { font-size: 24px; }
body[data-layout="mobile"] .acc-the { padding: 14px 16px; }
body[data-layout="mobile"] .acc-dong { flex-direction: column; gap: 2px; padding: 9px 0; }
body[data-layout="mobile"] .acc-gt { text-align: left; }
body[data-layout="mobile"] .acc-vi-so b { font-size: 24px; }
body[data-layout="mobile"] .acc-nap { flex: 1 1 auto; justify-content: center; }
