/* ============================================================
   mobile.css — giao diện điện thoại (≤ 768px).
   Nạp SAU cùng để ghi đè layout cố định 1000px của bản desktop.
   ============================================================ */
@media (max-width: 768px) {

  /* ---------- bỏ khung cố định 1000px ---------- */
  html, body { min-width: 0 !important; overflow-x: hidden; }
  .box, .site-footer { min-width: 0 !important; }
  .wrap { height: auto; }
  .wrap_main { width: 100%; height: auto; }

  /* ---------- HEADER ---------- */
  .header_bg { height: 60px; }
  .header_main { width: 100%; height: 60px; padding: 0 10px; box-sizing: border-box; }
  .logo img { height: 48px; margin-top: 0; }
  .header_log { margin-left: auto; display: flex; align-items: center; gap: 10px; }
  .login_btn { font-size: 15px; }
  .btn-download { height: 34px; padding: 0 12px; font-size: 15px; }
  .nav-toggle { order: 3; margin: 0 0 0 10px; width: 40px; height: 40px; }
  .nav-simple { top: 60px; }
  .nav-simple a { font-size: 18px; }

  /* ---------- HERO (wrap1) ---------- */
  .wrap1 { background-size: cover; }
  .wrap1 .wrap_main {
    background-size: 150vw auto;
    background-position: center top;
    padding-bottom: 36px;
  }
  .wrap1 .wrap_main > p {
    width: 94vw;
    height: calc(94vw * 187 / 806);
    margin: calc(150vw * 0.37) auto 0;
    background-size: contain;
    background-position: center;
  }
  .w1_m_con {
    width: auto; height: auto;
    margin: 14px 16px 0;
    display: flex; flex-direction: column; align-items: center; gap: 14px;
  }
  .w1_m_flash.fl, .w1_m_bgn.fl { float: none; }
  .w1_m_flash { width: 100%; max-width: 360px; height: auto; box-sizing: border-box; }
  .w1_m_flash #player { width: 100%; height: auto; aspect-ratio: 305 / 207; }
  .w1_m_flash #player img { width: 100%; height: 100%; }
  /* hàng nút rộng đúng bằng khung video phía trên */
  .w1_m_bgn {
    margin: 0;
    width: 100%; max-width: 360px;
    display: flex; gap: 10px;
  }
  /* nút sprite co giãn: mỗi nút 1/2 hàng, giữ tỉ lệ 288x98.
     Sprite 701x1000 => size theo % của nút; vị trí % tính sẵn:
     x: 0 | 69.735% (hover)   y: 19.845% (iOS) | 30.82% (Android) */
  .w1_m_bgn a {
    flex: 1 1 0;
    width: auto; height: auto;
    aspect-ratio: 288 / 98;
    margin: 0;
    background-size: 243.403% 1020.408%;
  }
  .w1_m_bgn a.w1_b1       { background-position: 0 19.845%; }
  .w1_m_bgn a.w1_b1:hover { background-position: 69.735% 19.845%; }
  .w1_m_bgn a.w1_b2       { background-position: 0 30.82%; }
  .w1_m_bgn a.w1_b2:hover { background-position: 69.735% 30.82%; }

  /* ---------- TÍNH NĂNG (wrap2): chữ trên, nhân vật dưới ---------- */
  .wrap2 { background-size: cover; }
  .wrap2 .wrap_main {
    background-size: auto 560px;
    background-position: calc(50% - 140px) bottom;
    padding: 1px 0 520px;
    box-sizing: border-box;
  }
  .w2_h1 {
    width: 94vw;
    height: calc(94vw * 199 / 618);
    margin: 44px auto 16px;
    background-size: contain;
    background-position: center;
  }
  .w2_m_main {
    width: auto; height: auto;
    margin: 0 16px;
    padding: 12px 22px 14px;
    background-size: 100% 100%;
  }
  .w2_m_main ul li { font-size: 17px; line-height: 44px; }

  /* ---------- TIN TỨC (wrap3) ---------- */
  .wrap3 { background-size: cover; }
  .wrap3 .wrap_main { background-size: cover; background-position: center top; }
  .news2 { width: 100%; padding: 44px 16px 48px; }
  .news2_head { flex-wrap: wrap; gap: 14px; align-items: flex-end; margin-bottom: 18px; }
  .news2_title { font-size: 38px; }
  .news2_eyebrow { font-size: 13px; }
  .news2_tabs { flex-wrap: wrap; gap: 8px; }
  .news2_tabs button { font-size: 14px; }
  .news2_more { font-size: 14px; }
  .news2_grid { grid-template-columns: 1fr; gap: 14px; }
  .news2_feat { min-height: 250px; }
  .news2_feat_body { padding: 16px 18px; }
  .news2_feat_title { font-size: 25px; }
  .news2_feat_desc { font-size: 13px; }
  .news2_item { gap: 12px; }
  .news2_item_img { flex-basis: 96px; height: 66px; }
  .news2_item_title { font-size: 17px; }
  .news2_item:hover { transform: none; }

  /* ---------- CHỨC NGHIỆP (wrap4) ---------- */
  .wrap4 { background-size: cover; }
  .wrap4 .wrap_main { background-size: cover; background-position: center top; padding-bottom: 32px; }
  .w4_head.poa { position: static; margin: 40px 16px 0; }
  .w4_head .w4_h_h1 { font-size: 30px; }
  .w4_head ul { margin: 18px 0 0; display: flex; justify-content: space-between; }
  .w4_head ul li { float: none; margin: 0; width: 19%; }
  .w4_head ul li span { font-size: 13px; line-height: 18px; margin-top: 4px; }
  .w4_head ul li i {
    --k: .62;
    width: calc(90px * var(--k));
    height: calc(99px * var(--k));
    margin: 0 auto;
    background-size: calc(701px * var(--k)) calc(1000px * var(--k));
  }
  .w4_head ul li.role_1 i { background-position: 0 calc(-498px * var(--k)); }
  .w4_head ul li.role_2 i { background-position: calc(-112px * var(--k)) calc(-498px * var(--k)); }
  .w4_head ul li.role_3 i { background-position: calc(-224px * var(--k)) calc(-498px * var(--k)); }
  .w4_head ul li.role_4 i { background-position: calc(-336px * var(--k)) calc(-498px * var(--k)); }
  .w4_head ul li.role_5 i { background-position: calc(-448px * var(--k)) calc(-498px * var(--k)); }
  .w4_head ul li.role_1.w4_on i { background-position: 0 calc(-603px * var(--k)); }
  .w4_head ul li.role_2.w4_on i { background-position: calc(-112px * var(--k)) calc(-603px * var(--k)); }
  .w4_head ul li.role_3.w4_on i { background-position: calc(-224px * var(--k)) calc(-603px * var(--k)); }
  .w4_head ul li.role_4.w4_on i { background-position: calc(-336px * var(--k)) calc(-603px * var(--k)); }
  .w4_head ul li.role_5.w4_on i,
  .w4_head ul li.role_5:hover i { background-position: calc(-448px * var(--k)) calc(-603px * var(--k)); }

  /* panel nhân vật: ảnh nhân vật ở trên, thông tin ở dưới */
  .w4_change.poa {
    position: static;
    width: 100%; height: auto;
    background-size: auto 380px !important;
    background-position: center 10px !important;
    padding-top: 390px;
    box-sizing: border-box;
  }
  .w4_c_main {
    width: auto; height: auto;
    margin: 0 16px;
    padding: 18px 18px 16px;
    background: rgba(255, 255, 255, .86) !important;   /* bỏ chữ Hán lớn, thay bằng thẻ nền sáng */
    border-radius: 14px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, .12);
    overflow: hidden;
  }
  .w4_c_main .w4_m_h1 { margin-bottom: 12px; }
  .w4_c_m_Attributes { font-size: 15px; margin-bottom: 8px; }
  .w4_c_m_Attributes .w4_Attributes_left { width: 50%; }

  /* ---------- FOOTER ---------- */
  .site-footer { padding: 32px 0 36px; }
  .sf-inner { width: 100%; flex-direction: column; gap: 22px; padding: 0 16px; box-sizing: border-box; }
  .sf-logo { flex: none; }
  .sf-logo img { height: 70px; }
  .sf-nav { font-size: 15px; letter-spacing: .1em; }
  .sf-health, .sf-email { font-size: 11px; }
  .sf-age { max-width: 280px; }
}

/* trang tính năng: banner thấp nên ẩn dòng mô tả để không đè lên chữ trong ảnh */
@media (max-width: 768px) {
  .feat-hero__desc { display: none; }
}
