/* Trang chủ (pages/home.php). Mọi class có tiền tố hm- để không trùng Bootstrap và style.css;
   rule cho thẻ HTML đặt trong .st-home để ghi đè style.css / newstyle.css. Chỉ nạp ở trang chủ (Home::index). */

.st-home {
  --green: #29B852;
  --green-d: #1f8f40;
  --green-xd: #0f3d22;
  --green-bg: #effaf2;
  --orange: #F39C33;
  --orange-d: #d9821a;
  --ink: #1d2b22;
  --text: #3c4a41;
  --muted: #6b7a70;
  --line: #e3e8e4;
  --page: #f6f8f6;
  --radius: 12px;
  --shadow: 0 6px 24px rgba(15, 61, 34, .08);
  font-family: Roboto, system-ui, -apple-system, "Segoe UI", Arial, sans-serif;
  font-size: 16px;
  font-weight: 400;
  line-height: 1.6;
  color: var(--text);
  background: #fff;
}
/* Ghi đè style.css / newstyle.css / Bootstrap */
.st-home *, .st-home *::before, .st-home *::after { box-sizing: border-box; }
.st-home h1, .st-home h2, .st-home h3 { color: var(--ink); line-height: 1.25; margin: 0; padding: 0; font-family: inherit; }
.st-home p { margin: 0; }
.st-home a { color: inherit; }
.st-home a:hover { text-decoration: none; }
.st-home img { max-width: 100%; height: auto; display: block; }
.st-home ul, .st-home ol { margin: 0; padding: 0; list-style: none; }
.st-home blockquote { border: 0; padding: 0; margin: 0; }
.st-home figure { margin: 0; }
.st-home dl, .st-home dd { margin: 0; }
.st-home select, .st-home input { font-family: inherit; font-size: 16px; }
.st-home :focus-visible { outline: 3px solid var(--orange); outline-offset: 2px; }

.hm-wrap { max-width: 1200px; margin: 0 auto; padding: 0 20px; }

/* Nút */
.hm-btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; border-radius: 10px; padding: 13px 22px; font: inherit; font-weight: 500; font-size: 16px; text-decoration: none; cursor: pointer; border: 2px solid transparent; transition: background .2s, color .2s, border-color .2s; line-height: 1.2; }
.st-home .hm-btn-primary { background: var(--orange); color: #fff; }
.st-home .hm-btn-primary:hover { background: var(--orange-d); color: #fff; }
.st-home .hm-btn-ghost { background: rgba(255,255,255,.12); color: #fff; border-color: rgba(255,255,255,.7); }
.st-home .hm-btn-ghost:hover { background: #fff; color: var(--green-xd); }
.st-home .hm-btn-green { background: var(--green); color: #fff; }
.st-home .hm-btn-green:hover { background: var(--green-d); color: #fff; }
.st-home .hm-btn-line { background: #fff; color: var(--green-d); border-color: var(--green); }
.st-home .hm-btn-line:hover { background: var(--green-bg); color: var(--green-d); }

/* Khối và tiêu đề khối */
.hm-sec { padding: 72px 0; }
.hm-sec.hm-alt { background: var(--page); }
.hm-head { max-width: 720px; margin: 0 0 36px; }
.hm-head.hm-center { margin-left: auto; margin-right: auto; text-align: center; }
.hm-eyebrow { display: inline-block; font-size: 13px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--green-d); margin-bottom: 8px; }
.st-home .hm-head h2 { font-size: clamp(26px, 3.2vw, 36px); font-weight: 700; }
.st-home .hm-head p { margin: 12px 0 0; font-size: 17px; color: var(--muted); }

/* ===== 1. HERO ===== */
.hm-hero { position: relative; color: #fff; background: var(--green-xd); overflow: hidden; }
.hm-hero::before { content: ""; position: absolute; inset: 0; background: url("/images/pin%20mat%20troi.jpg") center / cover no-repeat; }
.hm-hero::after { content: ""; position: absolute; inset: 0; background: linear-gradient(100deg, rgba(10,45,25,.94) 0%, rgba(10,45,25,.82) 42%, rgba(10,45,25,.35) 100%); }
.hm-hero .hm-wrap { position: relative; z-index: 1; display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(320px, .85fr); gap: 48px; align-items: center; padding-top: 72px; padding-bottom: 80px; }
.hm-hero .hm-eyebrow { color: #9be3b0; }
.st-home .hm-hero h1 { color: #fff; font-size: clamp(30px, 4.4vw, 52px); font-weight: 700; letter-spacing: -.01em; }
.st-home .hm-hero h1 span { color: #ffd166; }
.st-home .hm-lead { font-size: clamp(17px, 1.6vw, 19px); color: rgba(255,255,255,.88); margin: 18px 0 28px; max-width: 560px; }
.hm-actions { display: flex; flex-wrap: wrap; gap: 12px; }
.st-home .hm-chips { display: flex; flex-wrap: wrap; gap: 10px 22px; margin: 28px 0 0; font-size: 15px; color: rgba(255,255,255,.9); }
.hm-chips i { color: #9be3b0; margin-right: 6px; }

/* Ô tính nhanh */
.hm-calc { background: #fff; color: var(--text); border-radius: 16px; padding: 26px; box-shadow: 0 20px 50px rgba(0,0,0,.25); }
.st-home .hm-calc h2 { font-size: 20px; font-weight: 700; }
.st-home .hm-calc .hm-sub { font-size: 14px; color: var(--muted); margin: 4px 0 18px; }
.hm-calc label { display: block; font-weight: 500; font-size: 14px; margin-bottom: 6px; color: var(--ink); }
.hm-money { display: flex; align-items: center; border: 2px solid var(--line); border-radius: 10px; padding: 0 14px; transition: border-color .2s; }
.hm-money:focus-within { border-color: var(--green); }
.st-home .hm-money input { flex: 1; border: 0; outline: 0; font-size: 22px; font-weight: 700; color: var(--ink); padding: 12px 0; min-width: 0; background: transparent; }
.hm-money span { color: var(--muted); font-weight: 500; }
.hm-presets { display: flex; flex-wrap: wrap; gap: 6px; margin: 10px 0 18px; }
.hm-presets button { border: 1px solid var(--line); background: var(--page); border-radius: 999px; padding: 4px 12px; font: inherit; font-size: 13px; cursor: pointer; color: var(--text); }
.hm-presets button:hover { border-color: var(--green); color: var(--green-d); }
.hm-out { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 16px; }
.hm-out div { background: var(--green-bg); border-radius: 10px; padding: 12px 14px; }
.hm-out b { display: block; font-size: 22px; color: var(--green-d); line-height: 1.2; font-variant-numeric: tabular-nums; }
.hm-out small { font-size: 13px; color: var(--muted); }
.hm-calc .hm-btn { width: 100%; }
.st-home .hm-calc .hm-note { font-size: 12px; color: var(--muted); margin: 10px 0 0; }

/* ===== 2. DẢI TIN CẬY ===== */
.hm-trust { background: #fff; border-bottom: 1px solid var(--line); }
.hm-trust .hm-wrap { display: grid; grid-template-columns: repeat(4, 1fr); }
.hm-stat { padding: 26px 18px; text-align: center; border-left: 1px solid var(--line); }
.hm-stat:first-child { border-left: 0; }
.hm-stat b { display: block; font-size: 30px; font-weight: 700; color: var(--green-d); line-height: 1.1; }
.hm-stat span { font-size: 14px; color: var(--muted); }
.hm-brands { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 10px 28px; padding: 18px 20px 26px; color: var(--muted); font-size: 14px; }
.hm-brands strong { font-size: 17px; color: #8a978e; letter-spacing: .04em; font-weight: 700; }

/* ===== 3. GIẢI PHÁP ===== */
.hm-grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.hm-grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.hm-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; box-shadow: var(--shadow); display: flex; flex-direction: column; transition: transform .2s, box-shadow .2s; }
.hm-card:hover { transform: translateY(-3px); box-shadow: 0 12px 32px rgba(15,61,34,.12); }
.hm-ico { width: 52px; height: 52px; border-radius: 14px; display: grid; place-items: center; font-size: 22px; margin-bottom: 16px; }
.hm-ico.hm-g { background: var(--green-bg); color: var(--green-d); }
.hm-ico.hm-o { background: #fff2e0; color: var(--orange-d); }
.hm-ico.hm-b { background: #eaf0fb; color: #3F55B5; }
.hm-ico.hm-t { background: #e6f6f4; color: #0f8a7e; }
.st-home .hm-card h3 { font-size: 19px; font-weight: 700; margin-bottom: 6px; }
.hm-size { font-size: 13px; font-weight: 500; color: var(--green-d); margin-bottom: 10px; }
.st-home .hm-card p { margin: 0 0 16px; font-size: 15px; }
.st-home .hm-more { margin-top: auto; font-weight: 500; color: var(--green-d); text-decoration: none; }
.st-home .hm-more:hover { text-decoration: underline; color: var(--green-d); }

/* ===== 4. CÔNG CỤ ===== */
.hm-tools { background: linear-gradient(135deg, #0f3d22 0%, #165a33 100%); color: #fff; }
.st-home .hm-tools .hm-head h2 { color: #fff; }
.st-home .hm-tools .hm-head p { color: rgba(255,255,255,.8); }
.hm-tools .hm-eyebrow { color: #9be3b0; }
.st-home .hm-tool { display: flex; gap: 16px; align-items: flex-start; background: rgba(255,255,255,.07); border: 1px solid rgba(255,255,255,.14); border-radius: var(--radius); padding: 20px; text-decoration: none; color: #fff; transition: background .2s, transform .2s; }
.st-home .hm-tool:hover { background: rgba(255,255,255,.14); transform: translateY(-2px); color: #fff; }
.hm-tool i { font-size: 22px; color: #ffd166; width: 28px; text-align: center; margin-top: 3px; }
.hm-tool b { display: block; font-size: 17px; margin-bottom: 2px; }
.hm-tool span { font-size: 14px; color: rgba(255,255,255,.78); }

/* ===== 5. QUY TRÌNH ===== */
.st-home .hm-steps { display: grid; grid-template-columns: repeat(5, 1fr); gap: 16px; position: relative; }
.hm-steps::before { content: ""; position: absolute; top: 27px; left: 10%; right: 10%; height: 2px; background: repeating-linear-gradient(90deg, var(--green) 0 8px, transparent 8px 14px); }
.hm-steps li { position: relative; text-align: center; padding: 0 6px; }
.hm-num { width: 56px; height: 56px; border-radius: 50%; background: #fff; border: 2px solid var(--green); color: var(--green-d); font-size: 20px; display: grid; place-items: center; margin: 0 auto 14px; position: relative; z-index: 1; }
.st-home .hm-steps h3 { font-size: 17px; font-weight: 700; margin-bottom: 6px; }
.st-home .hm-steps p { font-size: 14px; color: var(--muted); }
.st-home .hm-steps a { color: var(--green-d); text-decoration: underline; }

/* ===== 6. DỰ ÁN ===== */
.hm-project { background: #fff; border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); box-shadow: var(--shadow); }
.hm-ph { aspect-ratio: 4 / 3; background: #dfe8e2; position: relative; }
.st-home .hm-ph img { width: 100%; height: 100%; object-fit: cover; }
.hm-ph.hm-empty { display: grid; place-items: center; background: linear-gradient(135deg, #e3f3e8 0%, #f3f7f4 100%); color: var(--green-d); font-size: 48px; }
.hm-tag { position: absolute; left: 12px; top: 12px; background: rgba(15,61,34,.88); color: #fff; font-size: 12px; font-weight: 500; padding: 3px 10px; border-radius: 999px; }
.hm-project .hm-body { padding: 16px 18px 18px; }
.st-home .hm-project h3 { font-size: 17px; font-weight: 700; margin-bottom: 8px; }
.st-home .hm-project dl { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.hm-project dt { font-size: 12px; font-weight: 400; color: var(--muted); }
.hm-project dd { font-weight: 700; color: var(--ink); font-size: 15px; }

/* ===== 7. ĐÁNH GIÁ ===== */
.hm-review { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; box-shadow: var(--shadow); display: flex; flex-direction: column; }
.hm-stars { color: #f5b301; font-size: 15px; letter-spacing: 2px; margin-bottom: 12px; }
.st-home .hm-review blockquote { margin: 0 0 18px; font-size: 16px; color: var(--ink); }
.hm-who { margin-top: auto; display: flex; align-items: center; gap: 12px; }
.hm-avatar { width: 44px; height: 44px; border-radius: 50%; background: var(--green-bg); color: var(--green-d); display: grid; place-items: center; font-weight: 700; flex: none; }
.hm-who b { display: block; font-size: 15px; color: var(--ink); }
.hm-who span { font-size: 13px; color: var(--muted); }

/* ===== 8. SẢN PHẨM ===== */
.st-home .hm-product { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; display: flex; flex-direction: column; transition: box-shadow .2s; text-decoration: none; }
.hm-product:hover { box-shadow: var(--shadow); }
.hm-pimg { aspect-ratio: 1 / 1; background: #fff; display: grid; place-items: center; padding: 18px; border-bottom: 1px solid var(--line); }
.st-home .hm-pimg img { max-height: 100%; object-fit: contain; }
.hm-pbody { padding: 14px 16px 16px; display: flex; flex-direction: column; flex: 1; }
.hm-cat { font-size: 12px; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; }
.st-home .hm-product h3 { font-size: 16px; font-weight: 500; margin: 4px 0 10px; }
.hm-price { margin-top: auto; font-weight: 700; color: var(--orange-d); }
.hm-price.hm-contact { color: var(--green-d); }
.hm-center-act { text-align: center; margin-top: 28px; }

/* ===== 9. CHÍNH SÁCH & TIN ===== */
.hm-policy { display: flex; flex-wrap: wrap; gap: 16px 24px; align-items: center; justify-content: space-between; background: #fff; border: 2px solid var(--orange); border-radius: var(--radius); padding: 20px 24px; margin-bottom: 28px; }
.hm-pi { display: flex; gap: 16px; align-items: center; }
.hm-pi i { font-size: 26px; color: var(--orange-d); }
.hm-pi b { display: block; font-size: 18px; color: var(--ink); }
.hm-pi span { font-size: 15px; color: var(--muted); }
.st-home .hm-news { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; text-decoration: none; display: flex; flex-direction: column; transition: box-shadow .2s; }
.hm-news:hover { box-shadow: var(--shadow); }
.hm-nimg { aspect-ratio: 1200 / 630; background: #dfe8e2; }
.st-home .hm-nimg img { width: 100%; height: 100%; object-fit: cover; }
.hm-nimg.hm-empty { background: linear-gradient(135deg, #e3f3e8, #f3f7f4); display: grid; place-items: center; color: var(--green-d); font-size: 28px; }
.hm-nbody { padding: 16px 18px 18px; }
.hm-nbody time { font-size: 13px; color: var(--muted); }
.st-home .hm-news h3 { font-size: 17px; font-weight: 700; margin-top: 4px; }

/* ===== 10. HỎI ĐÁP ===== */
.hm-faq { max-width: 860px; margin: 0 auto; }
.hm-faq details { background: #fff; border: 1px solid var(--line); border-radius: 10px; margin-bottom: 10px; }
.hm-faq summary { list-style: none; cursor: pointer; padding: 16px 52px 16px 20px; font-weight: 500; font-size: 17px; color: var(--ink); position: relative; display: block; }
.hm-faq summary::-webkit-details-marker { display: none; }
.hm-faq summary::after { content: "+"; position: absolute; right: 20px; top: 50%; transform: translateY(-50%); font-size: 24px; color: var(--green-d); font-weight: 300; }
.hm-faq details[open] summary::after { content: "–"; }
.st-home .hm-faq details p { padding: 0 20px 18px; }
.st-home .hm-faq a { color: var(--green-d); text-decoration: underline; }

/* ===== 11. KÊU GỌI CUỐI TRANG ===== */
.hm-cta { background: linear-gradient(135deg, var(--green-d) 0%, #146b30 100%); color: #fff; }
.hm-cta .hm-wrap { display: grid; grid-template-columns: minmax(0, 1fr) minmax(320px, 460px); gap: 40px; align-items: center; }
.st-home .hm-cta h2 { color: #fff; font-size: clamp(26px, 3.2vw, 36px); font-weight: 700; }
.st-home .hm-cta p { color: rgba(255,255,255,.9); font-size: 17px; margin: 12px 0 0; }
.hm-contact-line { margin-top: 22px; display: flex; flex-wrap: wrap; gap: 12px 24px; font-size: 16px; }
.st-home .hm-contact-line a { color: #fff; font-weight: 500; text-decoration: none; }
.hm-contact-line i { margin-right: 6px; }
.hm-form { background: #fff; border-radius: 16px; padding: 24px; color: var(--text); box-shadow: 0 16px 40px rgba(0,0,0,.18); display: grid; gap: 12px; }
.hm-form label { font-size: 14px; font-weight: 500; color: var(--ink); display: block; margin-bottom: 4px; }
.st-home .hm-form input, .st-home .hm-form select { width: 100%; height: auto; border: 2px solid var(--line); border-radius: 10px; padding: 11px 12px; color: var(--ink); background: #fff; }
.st-home .hm-form input:focus, .st-home .hm-form select:focus { outline: 0; border-color: var(--green); }
.hm-row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.hm-form small { font-size: 12px; color: var(--muted); }

/* ===== Thanh liên hệ nhanh trên mobile (chỉ trang chủ) ===== */
.hm-mbar { display: none; }

/* ===== Responsive ===== */
@media (max-width: 1100px) {
  .hm-grid-4 { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 991px) {
  .hm-hero .hm-wrap { grid-template-columns: minmax(0, 1fr); gap: 32px; padding-top: 48px; padding-bottom: 56px; }
  .hm-hero::after { background: linear-gradient(180deg, rgba(10,45,25,.9) 0%, rgba(10,45,25,.86) 100%); }
  .hm-trust .hm-wrap { grid-template-columns: repeat(2, 1fr); }
  .hm-stat:nth-child(3) { border-left: 0; }
  .hm-stat { border-top: 1px solid var(--line); }
  .hm-stat:nth-child(-n+2) { border-top: 0; }
  .hm-grid-3 { grid-template-columns: repeat(2, 1fr); }
  .st-home .hm-steps { grid-template-columns: minmax(0, 1fr); gap: 0; }
  .hm-steps::before { top: 28px; bottom: 28px; left: 27px; right: auto; width: 2px; height: auto; background: repeating-linear-gradient(180deg, var(--green) 0 8px, transparent 8px 14px); }
  .hm-steps li { display: grid; grid-template-columns: 56px minmax(0, 1fr); gap: 0 16px; text-align: left; padding: 0 0 22px; }
  .hm-num { margin: 0; grid-row: span 2; }
  .hm-cta .hm-wrap { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 640px) {
  .hm-sec { padding: 52px 0; }
  .hm-wrap { padding: 0 16px; }
  .hm-actions .hm-btn { width: 100%; }
  .st-home .hm-chips { gap: 8px 16px; font-size: 14px; }
  .hm-grid-4, .hm-grid-3 { grid-template-columns: minmax(0, 1fr); }
  .hm-reviews { display: grid; grid-auto-flow: column; grid-auto-columns: 86%; grid-template-columns: none; overflow-x: auto; scroll-snap-type: x mandatory; gap: 14px; padding-bottom: 8px; }
  .hm-reviews .hm-review { scroll-snap-align: start; }
  .hm-products { grid-template-columns: repeat(2, 1fr); gap: 12px; }
  .st-home .hm-product h3 { font-size: 14px; }
  .hm-row2 { grid-template-columns: minmax(0, 1fr); }
  body { padding-bottom: 64px; }
  /* Thanh liên hệ nhanh thay cho các nút nổi của footer */
  .suntory-alo-phone, .zalo_url, .fixedItem { display: none !important; }
  .hm-mbar { display: grid; grid-template-columns: 1fr 1fr 1.3fr; position: fixed; left: 0; right: 0; bottom: 0; z-index: 990; /* dưới menu mobile (999) */ background: #fff; box-shadow: 0 -2px 12px rgba(0,0,0,.12); }
  .st-home .hm-mbar a { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; min-height: 60px; font-size: 13px; font-weight: 500; text-decoration: none; color: var(--ink); }
  .hm-mbar a i { font-size: 19px; color: var(--green-d); }
  .st-home .hm-mbar a.hm-quote { background: var(--orange); color: #fff; }
  .hm-mbar a.hm-quote i { color: #fff; }
}
@media (prefers-reduced-motion: reduce) {
  .st-home * { transition: none !important; }
}
