/* ============================================================
   QBIS — responsive.css (mobile ≤ 480px)
   Thêm file này SAU các CSS khác. Không sửa HTML của trang.
   Gồm:
   1. Thanh CTA dính đáy (toàn site) + drawer menu trang sản phẩm
      (markup do /assets/js/qbis-mobile.js tự chèn)
   2. Override style inline của 8 trang sản phẩm
      (pos, tour, sale, cell, gara, elearning, erp, hrm)
   3. Tinh chỉnh trang chủ (index) + các trang phụ (site.css)
   Lưu ý: các selector [style*="..."] viết 2 biến thể
   "a:b" và "a: b" vì trình duyệt chuẩn hoá style attribute
   sau khi runtime render.
   ============================================================ */

/* ---------- Ẩn phần chèn thêm trên desktop ---------- */
.qm-ctabar, .qm-toggle, .qm-scrim, .qm-drawer { display: none; }

@media (max-width: 480px) {

/* ============================================================
   1. THANH CTA DÍNH ĐÁY — toàn site
   ============================================================ */
body { padding-bottom: 78px !important; }

.qm-ctabar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 380;
  display: flex; gap: 10px;
  padding: 10px 12px calc(10px + env(safe-area-inset-bottom));
  background: rgba(13, 28, 68, .94);
  -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
  border-top: 1px solid rgba(255, 255, 255, .14);
  box-shadow: 0 -8px 28px rgba(11, 22, 54, .28);
}
.qm-ctabar a {
  flex: 1; display: inline-flex; align-items: center; justify-content: center; gap: 7px;
  font-family: var(--font-sans, 'Be Vietnam Pro', system-ui, sans-serif);
  font-size: 14px; font-weight: 600; line-height: 1;
  min-height: 46px; padding: 0 10px; border-radius: 10px; text-decoration: none;
  transition: filter .2s, transform .12s;
}
.qm-ctabar a:active { transform: scale(.97); }
.qm-cta-call { color: #fff; border: 1px solid rgba(255, 255, 255, .38); }
.qm-cta-trial {
  background: var(--qbis-yellow-500, #fcda0c);
  color: var(--qbis-navy-900, #0d1c44);
  font-weight: 700;
}

/* ============================================================
   2. NÚT MENU + DRAWER — trang sản phẩm (JS tự chèn)
   ============================================================ */
.qm-toggle {
  display: flex; align-items: center; justify-content: center;
  position: fixed; top: 8px; right: 12px; z-index: 60;
  width: 42px; height: 42px; border: none; border-radius: 10px;
  background: rgba(255, 255, 255, .12); color: #fff; cursor: pointer;
}
.qm-toggle svg { width: 22px; height: 22px; }

.qm-scrim {
  display: block; position: fixed; inset: 0; z-index: 399;
  background: rgba(6, 12, 32, .55);
  opacity: 0; visibility: hidden; transition: opacity .26s;
}
.qm-scrim.open { opacity: 1; visibility: visible; }

.qm-drawer {
  display: block; position: fixed; top: 0; right: 0; bottom: 0; z-index: 400;
  width: min(330px, 86vw);
  background: var(--qbis-navy-800, #14296b);
  transform: translateX(100%); transition: transform .28s ease;
  box-shadow: -10px 0 44px rgba(0, 0, 10, .55);
  overflow-y: auto; -webkit-overflow-scrolling: touch;
  padding: 16px 18px 30px;
  font-family: var(--font-sans, 'Be Vietnam Pro', system-ui, sans-serif);
}
.qm-drawer.open { transform: translateX(0); }
.qm-dr-top {
  display: flex; align-items: center; justify-content: space-between;
  padding: 4px 2px 14px; margin-bottom: 8px;
  border-bottom: 1px solid rgba(255, 255, 255, .1);
}
.qm-dr-top img { height: 24px; display: block; }
.qm-dr-close {
  width: 38px; height: 38px; border: none; border-radius: 9px;
  background: rgba(255, 255, 255, .08); color: #fff;
  font-size: 20px; line-height: 1; cursor: pointer;
}
.qm-drawer > a {
  display: block; color: rgba(255, 255, 255, .9); text-decoration: none;
  font-size: 15.5px; font-weight: 600; padding: 13px 10px; border-radius: 9px;
}
.qm-drawer > a:hover, .qm-drawer > a:active {
  background: rgba(250, 220, 16, .09); color: var(--qbis-yellow-500, #fcda0c);
}
.qm-dr-sec {
  font-size: 10px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase;
  color: rgba(255, 255, 255, .4); padding: 14px 10px 4px;
}
.qm-dr-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; }
.qm-dr-grid a {
  color: rgba(255, 255, 255, .9); text-decoration: none;
  font-size: 13px; font-weight: 600; padding: 10px; border-radius: 9px;
}
.qm-dr-grid a:hover, .qm-dr-grid a:active {
  background: rgba(250, 220, 16, .09); color: var(--qbis-yellow-500, #fcda0c);
}
.qm-dr-cta {
  display: flex; flex-direction: column; gap: 10px;
  margin-top: 18px; padding-top: 16px;
  border-top: 1px solid rgba(255, 255, 255, .1);
}
.qm-dr-cta .qm-dr-btn {
  display: block; text-align: center; text-decoration: none;
  background: var(--qbis-yellow-500, #fcda0c); color: var(--qbis-navy-900, #0d1c44);
  font-weight: 700; font-size: 15px; padding: 13px; border-radius: 9px;
}
.qm-dr-cta .qm-dr-phone {
  display: flex; align-items: center; justify-content: center; gap: 7px;
  color: #fff; text-decoration: none; font-size: 14px; padding: 12px;
  border: 1px solid rgba(255, 255, 255, .22); border-radius: 9px;
}

/* ============================================================
   3. TRANG SẢN PHẨM (pos, tour, sale, cell, gara,
      elearning, erp, hrm) — override style inline
   ============================================================ */

/* --- Nav cố định: chỉ giữ logo, chừa chỗ cho nút menu --- */
nav[style*="z-index:50"], nav[style*="z-index: 50"] {
  padding: 11px 64px 11px 16px !important;
  gap: 12px !important;
}
nav[style*="z-index:50"] > div[style*="flex:1"],
nav[style*="z-index: 50"] > div[style*="flex: 1"],
nav[style*="z-index:50"] > div[style*="gap:14px"],
nav[style*="z-index: 50"] > div[style*="gap: 14px"] { display: none !important; }

/* --- Hero header: bớt cao, vát nhẹ hơn --- */
header[style*="clip-path"] {
  padding: 92px 0 76px !important;
  clip-path: polygon(0 0, 100% 0, 100% 97%, 0 100%) !important;
}

/* --- Container: gutter 20px --- */
div[style*="max-width:1024px"], div[style*="max-width: 1024px"],
div[style*="max-width:1000px"], div[style*="max-width: 1000px"],
div[style*="max-width:780px"],  div[style*="max-width: 780px"],
div[style*="max-width:720px"],  div[style*="max-width: 720px"] {
  padding-left: 20px !important;
  padding-right: 20px !important;
}

/* --- Grid 2 cột lớn (hero, section chữ + hình) → 1 cột --- */
div[style*="1fr 1.05fr"],
div[style*="0.85fr 1.15fr"],
div[style*="1.08fr 1fr"] {
  grid-template-columns: 1fr !important;
  gap: 30px !important;
}

/* --- Grid 2 cột gap 24 (khối lợi ích) → 1 cột --- */
div[style*="1fr 1fr"][style*="gap:24px"],
div[style*="1fr 1fr"][style*="gap: 24px"] {
  grid-template-columns: 1fr !important;
  gap: 16px !important;
}

/* --- Grid 3 cột (card tính năng / bảng giá gói) → 1 cột --- */
div[style*="repeat(3"][style*="gap:22px"],
div[style*="repeat(3"][style*="gap: 22px"],
div[style*="repeat(3"][style*="gap:24px"],
div[style*="repeat(3"][style*="gap: 24px"],
div[style*="repeat(3"][style*="gap:20px"],
div[style*="repeat(3"][style*="gap: 20px"] {
  grid-template-columns: 1fr !important;
  gap: 16px !important;
}

/* --- Dải số liệu 4 cột → 2×2 --- */
div[style*="repeat(4"][style*="gap:22px"],
div[style*="repeat(4"][style*="gap: 22px"],
div[style*="repeat(4"][style*="gap:18px"],
div[style*="repeat(4"][style*="gap: 18px"] {
  grid-template-columns: 1fr 1fr !important;
  gap: 14px !important;
}

/* --- Bảng so sánh (1.4fr 1.3fr 1fr 1fr): thu cột, cho chữ xuống dòng --- */
div[style*="1.4fr 1.3fr"] {
  grid-template-columns: 1.3fr 1fr 1fr 1fr !important;
  font-size: 11px !important;
  word-break: break-word;
}
div[style*="1.4fr 1.3fr"] > * { min-width: 0; }

/* --- Section: bớt khoảng thở dọc --- */
section[style*="padding:96px"],  section[style*="padding: 96px"],
section[style*="padding:88px"],  section[style*="padding: 88px"],
section[style*="padding:84px"],  section[style*="padding: 84px"],
section[style*="padding:80px"],  section[style*="padding: 80px"],
section[style*="padding:78px"],  section[style*="padding: 78px"],
section[style*="padding:76px"],  section[style*="padding: 76px"],
section[style*="padding:72px"],  section[style*="padding: 72px"] {
  padding-top: 52px !important;
  padding-bottom: 52px !important;
}

/* --- Footer sản phẩm: 3 cột → 1 cột --- */
footer div[style*="1.5fr 1.5fr"] {
  grid-template-columns: 1fr !important;
  gap: 30px !important;
  padding-top: 44px !important;
  padding-bottom: 24px !important;
}

/* ============================================================
   4. TRANG CHỦ (index) — tinh chỉnh thêm dưới 480px
   ============================================================ */
.container { padding: 0 20px; }
.sec { padding: 52px 0; }
.sec-title { font-size: 24px; }
.hero { padding-bottom: 78px; clip-path: polygon(0 0, 100% 0, 100% 97%, 0 100%); }
.hero-inner { padding: 36px 20px 0; gap: 28px; }
.hero-title { font-size: 33px; }
.hero-sub { font-size: 13.5px; }
.hero-stats { gap: 20px; flex-wrap: wrap; }
.stat-num { font-size: 27px; }
.cat-strip {
  padding: 0 20px; flex-wrap: nowrap; overflow-x: auto;
  -webkit-overflow-scrolling: touch; scrollbar-width: none;
  margin-top: 26px;
}
.cat-strip::-webkit-scrollbar { display: none; }
.cat { flex: none; }
.journey-grid { gap: 14px; margin-top: 28px; }
.jcard { padding: 20px; }
.eco-inner, .ind-detail { gap: 26px; }
.eco-art img { max-width: 240px; }
.ind-orb { width: 190px; height: 190px; }
.ind-pills { gap: 8px; }

/* ============================================================
   5. TRANG PHỤ (site.css: platform, bảng giá, khách hàng…)
   ============================================================ */
.qcontainer { padding: 0 20px; }
.qsec { padding: 46px 0; }
.qhero { padding: 40px 0 78px; clip-path: polygon(0 0, 100% 0, 100% 97%, 0 100%); }
.qhero-cta { flex-direction: column; align-items: stretch; }
.qhero-cta .qbtn { width: 100%; }
.qcta { padding: 72px 22px 52px; clip-path: polygon(0 26px, 100% 0, 100% 100%, 0 100%); }
.qcard { padding: 20px; }
.qf-grid { gap: 26px; padding: 40px 0 24px; }
.qstat-num { font-size: 28px; }

} /* end @media 480px */
