:root {
  --brand: #1d4ed8;
  --brand-dark: #1e3a8a;
  --accent: #f59e0b;
  --teal: #0d9488;
  --teal-light: #2dd4bf;
  --ink: #0f172a;
  --ink-soft: #334155;
  --muted: #64748b;
  --bg: #f8fafc;
  --surface: #ffffff;
  --border: #e2e8f0;

  --hero-bg-1: #060d24;
  --hero-bg-2: #0f2557;
  --hero-bg-3: #143a6b;

  --qlbh2: #2563eb;
  --qlbh2-bg: #eff6ff;
  --qlbhsoft: #059669;
  --qlbhsoft-bg: #ecfdf5;
  --qlcv: #7c3aed;
  --qlcv-bg: #f5f3ff;
  --ketoan: #d97706;
  --ketoan-bg: #fffbeb;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: 'Inter', -apple-system, Segoe UI, Roboto, sans-serif;
  line-height: 1.6;
}
h1, h2, h3, h4 {
  font-family: 'Be Vietnam Pro', 'Inter', sans-serif;
  color: var(--ink);
  margin: 0;
  text-wrap: balance;
}
a { color: var(--brand); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; display: block; }
.container { max-width: 1120px; margin: 0 auto; padding: 0 24px; }
.muted { color: var(--muted); }

/* Header */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255,255,255,.85);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}
.site-header .bar { display: flex; align-items: center; justify-content: space-between; height: 68px; }
.brand { display: flex; align-items: center; gap: 10px; font-family: 'Be Vietnam Pro', sans-serif; font-weight: 700; font-size: 19px; color: var(--ink); }
.brand:hover { text-decoration: none; }
.brand .logo-mark {
  width: 34px; height: 34px; border-radius: 10px;
  background: linear-gradient(135deg, var(--teal-light), var(--brand));
  display: flex; align-items: center; justify-content: center; color: #fff; font-weight: 800; font-size: 15px;
  box-shadow: 0 4px 14px -4px rgba(29,78,216,.55);
}
.nav { display: flex; align-items: center; gap: 28px; }
.nav a { position: relative; color: var(--ink-soft); font-weight: 500; font-size: 15px; padding: 4px 0; }
.nav a:hover { color: var(--brand); text-decoration: none; }
.nav a::after {
  content: ''; position: absolute; left: 0; right: 100%; bottom: -4px; height: 2px;
  background: linear-gradient(90deg, var(--teal-light), var(--brand)); border-radius: 2px;
  transition: right .18s ease;
}
.nav a:hover::after { right: 0; }
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  background: var(--brand); color: #fff; border: none; border-radius: 999px;
  padding: 12px 22px; font-size: 15px; font-weight: 600; cursor: pointer; white-space: nowrap;
  box-shadow: 0 8px 20px -8px rgba(29,78,216,.55);
  transition: transform .15s ease, box-shadow .15s ease, background .15s ease;
}
.btn:hover { background: var(--brand-dark); text-decoration: none; transform: translateY(-1px); box-shadow: 0 10px 24px -8px rgba(29,78,216,.6); }
.btn-ghost { background: transparent; color: var(--brand); border: 1.5px solid var(--border); box-shadow: none; }
.btn-ghost:hover { background: var(--qlbh2-bg); border-color: var(--brand); transform: none; box-shadow: none; }
.btn-accent { background: var(--accent); color: #1c1206; }
.btn-accent:hover { background: #d97706; }
.btn-sm { padding: 9px 18px; font-size: 14px; }

/* Menu mobile */
.nav-toggle { display: none; flex-direction: column; justify-content: center; gap: 4px; width: 38px; height: 38px; background: none; border: none; cursor: pointer; padding: 0; }
.nav-toggle span { display: block; width: 22px; height: 2px; background: var(--ink); border-radius: 2px; transition: transform .2s, opacity .2s; }
.nav-toggle.open span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.nav-toggle.open span:nth-child(2) { opacity: 0; }
.nav-toggle.open span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }
.nav-cta-mobile { display: none; }

/* Hero */
.hero {
  position: relative; overflow: hidden; padding: 88px 0 72px;
  background: radial-gradient(1100px 520px at 12% -10%, var(--hero-bg-3), transparent 60%),
              radial-gradient(900px 480px at 100% 0%, #0a2a52, transparent 55%),
              linear-gradient(180deg, var(--hero-bg-1), var(--hero-bg-2) 70%, var(--hero-bg-1));
  color: #fff;
}
.hero::before {
  content: ''; position: absolute; inset: 0; pointer-events: none; opacity: .5;
  background-image: radial-gradient(circle, rgba(45,212,191,.35) 0, transparent 2px);
  background-size: 26px 26px;
  mask-image: radial-gradient(560px 320px at 78% 22%, #000, transparent 72%);
}
.hero .container { position: relative; }
.hero .eyebrow {
  display: inline-block; font-size: 13px; font-weight: 600; letter-spacing: .04em;
  color: #ccfbf1; background: rgba(45,212,191,.14); border: 1px solid rgba(45,212,191,.35);
  padding: 6px 14px; border-radius: 999px; margin-bottom: 22px;
}
.hero h1 { color: #fff; font-size: 46px; font-weight: 800; line-height: 1.16; max-width: 780px; }
.hero h1 .hl { background: linear-gradient(90deg, var(--teal-light), #93c5fd); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero p.lead { font-size: 18px; color: #b9c5e0; max-width: 620px; margin-top: 18px; }
.hero .cta-row { display: flex; gap: 12px; margin-top: 30px; flex-wrap: wrap; }
.hero .btn-ghost { color: #e2e8f0; border-color: rgba(226,232,240,.35); }
.hero .btn-ghost:hover { background: rgba(226,232,240,.08); border-color: rgba(226,232,240,.6); }

/* Product pill tabs (hero quick nav) */
.pill-tabs { display: flex; gap: 10px; margin-top: 38px; flex-wrap: wrap; }
.pill-tab {
  display: inline-flex; align-items: center; gap: 9px;
  background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.14); color: #e2e8f0;
  border-radius: 999px; padding: 10px 18px 10px 12px; font-size: 14px; font-weight: 600;
  transition: background .15s ease, border-color .15s ease, transform .15s ease;
}
.pill-tab .ico {
  width: 26px; height: 26px; border-radius: 999px; display: flex; align-items: center; justify-content: center;
  font-size: 13px; background: var(--pill-accent, var(--teal-light)); color: #06251f; flex-shrink: 0;
}
.pill-tab:hover { background: rgba(255,255,255,.12); border-color: rgba(255,255,255,.32); text-decoration: none; transform: translateY(-1px); }

.hero .stats { display: flex; gap: 40px; margin-top: 56px; flex-wrap: wrap; }
.hero .stat b { display: block; font-size: 28px; font-family: 'Be Vietnam Pro', sans-serif; font-weight: 800; color: #fff; }
.hero .stat span { font-size: 13px; color: #94a3b8; }

/* Product grid (overview) */
.section { padding: 64px 0; }
.section-head { max-width: 620px; margin-bottom: 40px; }
.section-head .kicker { font-size: 13px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--accent); }
.section-head h2 { font-size: 30px; font-weight: 800; margin-top: 8px; }
.section-head p { color: var(--muted); margin-top: 10px; font-size: 16px; }

.product-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 22px; }
.product-card {
  position: relative; overflow: hidden;
  background: var(--surface); border: 1px solid var(--border); border-radius: 18px;
  padding: 30px 28px 26px; display: flex; flex-direction: column; gap: 14px;
  transition: border-color .18s, transform .18s, box-shadow .18s;
}
.product-card::before {
  content: ''; position: absolute; top: 0; left: 0; right: 0; height: 4px;
  background: linear-gradient(90deg, var(--card-accent, var(--brand)), transparent 140%);
  opacity: 0; transition: opacity .18s;
}
.product-card:hover {
  border-color: transparent; transform: translateY(-4px);
  box-shadow: 0 20px 40px -20px rgba(15,23,42,.28);
}
.product-card:hover::before { opacity: 1; }
.product-card .icon-blob {
  width: 46px; height: 46px; border-radius: 13px; display: flex; align-items: center; justify-content: center;
  font-size: 21px; background: var(--card-bg, var(--qlbh2-bg)); color: var(--card-accent, var(--qlbh2));
}
.product-card .tag {
  display: inline-flex; align-items: center; gap: 8px; width: fit-content;
  font-size: 12px; font-weight: 700; padding: 5px 12px; border-radius: 999px;
  background: var(--card-bg, var(--qlbh2-bg)); color: var(--card-accent, var(--qlbh2));
}
.product-card h3 { font-size: 19px; font-weight: 700; }
.product-card p { color: var(--muted); font-size: 14.5px; margin: 0; }
.product-card .status { font-size: 12.5px; color: var(--muted); margin-top: auto; padding-top: 10px; border-top: 1px solid var(--border); }
.product-card .status b { color: var(--ink-soft); }
.product-card a.card-link { font-size: 14px; font-weight: 600; color: var(--card-accent, var(--brand)); }

/* Product detail sections */
.product-detail { padding: 72px 0; border-top: 1px solid var(--border); }
.product-detail:nth-child(even) { background: var(--surface); }
.product-detail .grid { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: center; }
.product-detail.reverse .grid { direction: rtl; }
.product-detail.reverse .grid > * { direction: ltr; }
.product-detail .tag {
  display: inline-flex; width: fit-content; font-size: 12px; font-weight: 700; padding: 6px 14px; border-radius: 999px;
  background: var(--card-bg); color: var(--card-accent); margin-bottom: 16px;
}
.product-detail h2 { font-size: 28px; font-weight: 800; }
.product-detail p.desc { color: var(--muted); font-size: 16px; margin-top: 12px; }
.feature-list { list-style: none; margin: 24px 0 0; padding: 0; display: grid; gap: 11px; }
.feature-list li { display: flex; gap: 10px; font-size: 14.5px; color: var(--ink-soft); }
.feature-list li::before { content: "✓"; color: var(--card-accent); font-weight: 700; flex-shrink: 0; }
.product-detail .cta-row { margin-top: 26px; display: flex; gap: 12px; flex-wrap: wrap; }
.mock {
  background: var(--card-bg); border: 1px solid var(--border); border-radius: 16px;
  padding: 22px; min-height: 300px; display: flex; flex-direction: column; gap: 12px; justify-content: center;
}
.mock .mock-title { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; color: var(--card-accent); }
.mock .mock-row { background: var(--surface); border: 1px solid var(--border); border-radius: 8px; padding: 12px 14px; display: flex; justify-content: space-between; align-items: center; font-size: 13.5px; }
.mock .mock-row b { color: var(--ink); }
.mock .mock-row .badge { font-size: 11px; font-weight: 700; padding: 3px 9px; border-radius: 999px; background: var(--card-bg); color: var(--card-accent); }

/* Trust section */
.trust-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }
.trust-item { text-align: left; }
.trust-item .num {
  width: 44px; height: 44px; border-radius: 13px; margin-bottom: 14px;
  display: flex; align-items: center; justify-content: center;
  font-family: 'Be Vietnam Pro', sans-serif; font-weight: 800; font-size: 17px; color: #fff;
  background: linear-gradient(135deg, var(--teal-light), var(--brand));
  box-shadow: 0 8px 18px -8px rgba(29,78,216,.5);
}
.trust-item h4 { font-size: 16px; font-weight: 700; margin-bottom: 6px; }
.trust-item p { font-size: 14px; color: var(--muted); margin: 0; }

/* CTA band */
.cta-band {
  position: relative; overflow: hidden;
  background: linear-gradient(135deg, var(--hero-bg-1), var(--brand-dark) 55%, var(--brand));
  border-radius: 24px; padding: 54px 48px; color: #fff;
  display: flex; align-items: center; justify-content: space-between; gap: 32px; flex-wrap: wrap;
}
.cta-band::before {
  content: ''; position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(420px 220px at 88% 20%, rgba(45,212,191,.35), transparent 70%);
}
.cta-band > * { position: relative; }
.cta-band h2 { color: #fff; font-size: 26px; }
.cta-band p { color: #cbd5e1; margin-top: 8px; font-size: 15px; }
.cta-band .btn { background: #fff; color: var(--brand-dark); box-shadow: 0 10px 24px -10px rgba(0,0,0,.4); }
.cta-band .btn:hover { background: #e2e8f0; }

/* Contact page */
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; }
.contact-card { background: var(--surface); border: 1px solid var(--border); border-radius: 14px; padding: 28px; }
.contact-card h3 { font-size: 16px; margin-bottom: 6px; }
.contact-list { list-style: none; padding: 0; margin: 18px 0 0; display: grid; gap: 16px; }
.contact-list li { display: flex; gap: 12px; align-items: flex-start; font-size: 14.5px; }
.contact-list .icon { width: 36px; height: 36px; border-radius: 9px; background: var(--qlbh2-bg); color: var(--brand); display: flex; align-items: center; justify-content: center; flex-shrink: 0; font-size: 16px; }
.form-field { margin-bottom: 16px; }
.form-field label { display: block; font-size: 13.5px; font-weight: 600; color: var(--ink-soft); margin-bottom: 6px; }
.form-field input, .form-field textarea, .form-field select {
  width: 100%; border: 1px solid var(--border); border-radius: 8px; padding: 10px 13px;
  font-size: 14.5px; font-family: inherit; background: var(--bg);
}
.form-field textarea { resize: vertical; min-height: 100px; }
.alert { padding: 12px 16px; border-radius: 8px; font-size: 14px; margin-bottom: 18px; }
.alert-success { background: #f0fdf4; border: 1px solid #bbf7d0; color: #15803d; }
.alert-error { background: #fef2f2; border: 1px solid #fecaca; color: #b91c1c; }

/* Danh gia sao + luot tai */
.rating-block { display: flex; flex-wrap: wrap; align-items: center; gap: 18px; margin-top: 18px; padding-top: 18px; border-top: 1px solid var(--border); }
.rating-summary { display: flex; align-items: center; gap: 8px; font-size: 14px; color: var(--ink-soft); }
.rating-summary .stars { color: var(--accent); font-size: 17px; letter-spacing: 1px; }
.rating-summary .muted { font-size: 13px; }
.download-count { font-size: 13px; color: var(--muted); display: flex; align-items: center; gap: 6px; }
.rate-form { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.rate-form .rate-label { font-size: 13px; color: var(--muted); margin-right: 4px; }
.rate-form button {
  background: var(--surface); border: 1px solid var(--border); border-radius: 8px;
  padding: 6px 10px; font-size: 14px; color: var(--accent); cursor: pointer; letter-spacing: 1px;
}
.rate-form button:hover { background: var(--ketoan-bg); border-color: var(--accent); }
.rated-thanks { font-size: 13.5px; color: #059669; font-weight: 600; }

/* Footer */
.site-footer { position: relative; border-top: 1px solid var(--border); background: var(--surface); padding: 48px 0 28px; margin-top: 40px; }
.site-footer::before { content: ''; position: absolute; top: -1px; left: 0; right: 0; height: 3px; background: linear-gradient(90deg, var(--teal-light), var(--brand), var(--qlcv)); }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 32px; }
.footer-grid h4 { font-size: 13.5px; margin-bottom: 14px; color: var(--ink); }
.footer-grid ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 9px; }
.footer-grid a { color: var(--muted); font-size: 14px; }
.footer-grid a:hover { color: var(--brand); }
.footer-bottom { border-top: 1px solid var(--border); margin-top: 36px; padding-top: 20px; display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 12px; font-size: 13px; color: var(--muted); }

/* Responsive */
@media (max-width: 860px) {
  .nav {
    display: none; position: absolute; top: 68px; left: 0; right: 0; background: var(--surface);
    border-bottom: 1px solid var(--border); flex-direction: column; align-items: stretch; gap: 0;
    padding: 8px 24px 16px; box-shadow: 0 12px 24px -12px rgba(15,23,42,.2);
  }
  .nav.open { display: flex; }
  .nav a { padding: 12px 0; border-bottom: 1px solid var(--border); }
  .nav a:last-of-type { border-bottom: none; }
  .nav a::after { display: none; }
  .nav-toggle { display: flex; }
  .nav-cta-mobile { display: inline-flex; margin-top: 12px; justify-content: center; }
  .cta-desktop { display: none; }
  .hero h1 { font-size: 32px; }
  .product-grid { grid-template-columns: 1fr; }
  .product-detail .grid { grid-template-columns: 1fr; gap: 32px; }
  .product-detail.reverse .grid { direction: ltr; }
  .trust-grid { grid-template-columns: repeat(2, 1fr); }
  .cta-band { flex-direction: column; align-items: flex-start; }
  .contact-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
