/* ============================================================
   home_redesign.css — Thiết kế lại trang chủ (hiện đại, gọn nhẹ)
   Nạp SAU style_home.css / styles.css (xem GlobalLoad.php) nên các
   luật ở đây được ưu tiên hơn CSS cũ mà không cần !important tràn lan.
   Chỉ áp dụng cho các class bắt đầu bằng "hm-" (Home Modern) — không
   đụng tới style của các trang khác.
   ============================================================ */

:root{
	--hm-primary:#2f8fd6;
	--hm-primary-dark:#1f6fac;
	--hm-accent:#ff6b47;
	--hm-accent-dark:#e6532f;
	--hm-ink:#1c2733;
	--hm-muted:#647184;
	--hm-bg-soft:#f5f9fc;
	--hm-border:#e3e9ef;
	--hm-radius:14px;
	--hm-radius-sm:8px;
	--hm-shadow:0 10px 30px rgba(20,40,60,.08);
	--hm-shadow-hover:0 16px 40px rgba(20,40,60,.14);
	--hm-container:1180px;
}

.hm-hero,.hm-trust,.hm-about,.hm-products,.hm-why,.hm-testimonials,.hm-cta,.hm-news{
	box-sizing:border-box;
}
.hm-hero *,.hm-trust *,.hm-about *,.hm-products *,.hm-why *,.hm-testimonials *,.hm-cta *,.hm-news *{
	box-sizing:border-box;
}

/* ---------- Buttons ---------- */
.hm-btn{
	display:inline-flex;align-items:center;justify-content:center;gap:6px;
	padding:13px 26px;border-radius:999px;font-weight:600;font-size:15px;
	text-decoration:none;border:2px solid transparent;transition:transform .15s ease,box-shadow .15s ease,background .15s ease;
	cursor:pointer;line-height:1.2;
}
.hm-btn--primary{background:var(--hm-accent);color:#fff;}
.hm-btn--primary:hover{background:var(--hm-accent-dark);transform:translateY(-2px);box-shadow:0 10px 22px rgba(255,107,71,.35);}
.hm-btn--ghost{background:rgba(255,255,255,.12);border-color:rgba(255,255,255,.7);color:#fff;backdrop-filter:blur(2px);}
.hm-btn--ghost:hover{background:rgba(255,255,255,.22);transform:translateY(-2px);}
.hm-btn--outline{background:transparent;border-color:var(--hm-primary);color:var(--hm-primary);}
.hm-btn--outline:hover{background:var(--hm-primary);color:#fff;transform:translateY(-2px);}

/* ---------- Section heading helpers ---------- */
.hm-section-eyebrow{
	display:inline-block;font-size:13px;font-weight:700;letter-spacing:.06em;text-transform:uppercase;
	color:var(--hm-accent);margin-bottom:8px;
}
.hm-section-title{
	font-size:30px;line-height:1.25;font-weight:800;color:var(--hm-ink);margin:0 0 6px;
}
.hm-section-head{max-width:var(--hm-container);margin:0 auto 32px;padding:0 20px;}
.hm-section-head--center{text-align:center;}
.hm-section-more{max-width:var(--hm-container);margin:32px auto 0;padding:0 20px;text-align:center;}

/* ============================================================
   HERO
   ============================================================ */
.hm-hero{
	position:relative;width:100%;height:78vh;min-height:420px;max-height:640px;
	overflow:hidden;background:#0d2436;
}
.hm-hero__slides{position:absolute;inset:0;}
.hm-hero__slide{
	position:absolute;inset:0;opacity:0;transition:opacity 1s ease;
}
.hm-hero__slide:first-child{opacity:1;} /* fallback if JS hasn't run yet (no-JS or 1 slide) */
.hm-hero__slide.is-active{opacity:1;z-index:1;}
.hm-hero__slide img{
	width:100%;height:100%;object-fit:cover;display:block;
}
.hm-hero__slide::after{
	content:"";position:absolute;inset:0;
	background:linear-gradient(180deg,rgba(10,25,40,.15) 0%,rgba(10,25,40,.55) 100%);
}
.hm-hero__caption{position:absolute;left:6%;bottom:14%;max-width:520px;color:#fff;z-index:2;}
.hm-hero__eyebrow{display:block;font-weight:700;text-transform:uppercase;font-size:13px;letter-spacing:.08em;color:var(--hm-accent);margin-bottom:6px;}

.hm-hero__overlay{
	position:absolute;inset:0;z-index:3;display:flex;align-items:center;
	background:linear-gradient(90deg,rgba(8,22,36,.62) 0%,rgba(8,22,36,.28) 55%,rgba(8,22,36,0) 100%);
}
.hm-hero__content{max-width:640px;padding:0 6%;color:#fff;}
.hm-hero__title{font-size:clamp(26px,4vw,46px);font-weight:800;line-height:1.2;margin:0 0 16px;text-shadow:0 2px 10px rgba(0,0,0,.25);}
.hm-hero__subtitle{font-size:17px;line-height:1.6;margin:0 0 26px;color:rgba(255,255,255,.92);max-width:520px;}
.hm-hero__actions{display:flex;flex-wrap:wrap;gap:14px;}

.hm-hero__dots{position:absolute;left:50%;bottom:22px;transform:translateX(-50%);display:flex;gap:8px;z-index:4;}
.hm-hero__dots button{
	width:9px;height:9px;border-radius:50%;border:none;background:rgba(255,255,255,.45);padding:0;cursor:pointer;transition:background .2s,transform .2s;
}
.hm-hero__dots button.is-active{background:#fff;transform:scale(1.3);}
.hm-hero__nav{
	position:absolute;top:50%;transform:translateY(-50%);z-index:4;
	width:42px;height:42px;border-radius:50%;border:none;background:rgba(255,255,255,.18);color:#fff;
	font-size:22px;line-height:1;cursor:pointer;transition:background .2s;
}
.hm-hero__nav:hover{background:rgba(255,255,255,.34);}
.hm-hero__nav--prev{left:18px;}
.hm-hero__nav--next{right:18px;}

@media (max-width:600px){
	.hm-hero{height:62vh;min-height:360px;}
	.hm-hero__nav{display:none;}
	.hm-hero__overlay{background:linear-gradient(180deg,rgba(8,22,36,.35) 0%,rgba(8,22,36,.75) 100%);align-items:flex-end;padding-bottom:56px;}
}

/* ============================================================
   TRUST BADGES
   ============================================================ */
.hm-trust{background:#fff;border-bottom:1px solid var(--hm-border);}
.hm-trust__inner{
	max-width:var(--hm-container);margin:0 auto;padding:22px 20px;
	display:grid;grid-template-columns:repeat(2,1fr);gap:18px;
}
.hm-trust__item{
	display:flex;align-items:center;gap:12px;font-weight:600;color:var(--hm-ink);font-size:14px;
}
.hm-trust__item svg{width:28px;height:28px;flex:none;color:var(--hm-primary);}
@media (min-width:700px){
	.hm-trust__inner{grid-template-columns:repeat(4,1fr);}
}

/* ============================================================
   ABOUT / GIỚI THIỆU
   ============================================================ */
.hm-about{
	max-width:var(--hm-container);margin:64px auto;padding:0 20px;
	display:grid;grid-template-columns:1fr;gap:36px;align-items:center;
}
.hm-about__media img{width:100%;border-radius:var(--hm-radius);box-shadow:var(--hm-shadow);display:block;}
.hm-about__video{position:relative;display:block;border-radius:var(--hm-radius);overflow:hidden;box-shadow:var(--hm-shadow);}
.hm-about__video img{width:100%;display:block;}
.hm-about__play{
	position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);
	width:64px;height:64px;border-radius:50%;background:rgba(255,255,255,.92);
	display:flex;align-items:center;justify-content:center;color:var(--hm-primary);font-size:22px;
}
.hm-about__text{color:var(--hm-muted);font-size:15.5px;line-height:1.75;margin:14px 0 22px;}
.hm-about__text p{margin:0 0 12px;}
@media (min-width:860px){
	.hm-about{grid-template-columns:1fr 1fr;}
}

/* ============================================================
   PRODUCTS / SẢN PHẨM
   ============================================================ */
.hm-products{max-width:var(--hm-container);margin:64px auto;padding:0 20px;}
.hm-products__grid{
	display:grid;grid-template-columns:repeat(2,1fr);gap:20px;
}
@media (min-width:700px){ .hm-products__grid{grid-template-columns:repeat(3,1fr);} }
@media (min-width:1000px){ .hm-products__grid{grid-template-columns:repeat(4,1fr);} }

.hm-card{
	display:block;background:#fff;border:1px solid var(--hm-border);border-radius:var(--hm-radius);
	overflow:hidden;text-decoration:none;color:inherit;transition:transform .2s ease,box-shadow .2s ease;
}
.hm-card:hover{transform:translateY(-5px);box-shadow:var(--hm-shadow-hover);}
.hm-card__image{aspect-ratio:1/1;overflow:hidden;background:var(--hm-bg-soft);}
.hm-card__image img{width:100%;height:100%;object-fit:cover;transition:transform .35s ease;}
.hm-card:hover .hm-card__image img{transform:scale(1.06);}
.hm-card__body{padding:14px 16px;}
.hm-card__title{
	font-size:15px;font-weight:700;color:var(--hm-ink);margin:0 0 8px;
	display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;min-height:2.6em;
}
.hm-card__link{font-size:13px;font-weight:700;color:var(--hm-primary);}

/* ============================================================
   WHY CHOOSE US
   ============================================================ */
.hm-why{background:var(--hm-bg-soft);padding:64px 20px;}
.hm-why__grid{
	max-width:var(--hm-container);margin:0 auto;
	display:grid;grid-template-columns:1fr;gap:24px;
}
@media (min-width:700px){ .hm-why__grid{grid-template-columns:repeat(2,1fr);} }
@media (min-width:1000px){ .hm-why__grid{grid-template-columns:repeat(4,1fr);} }

.hm-why__item{
	background:#fff;border-radius:var(--hm-radius);padding:26px 22px;text-align:center;
	box-shadow:var(--hm-shadow);
}
.hm-why__icon{
	width:64px;height:64px;margin:0 auto 14px;border-radius:50%;background:var(--hm-bg-soft);
	display:flex;align-items:center;justify-content:center;
}
.hm-why__icon img{width:32px;height:32px;object-fit:contain;}
.hm-why__title{font-size:16px;font-weight:700;color:var(--hm-ink);margin:0 0 8px;}
.hm-why__text{font-size:14px;color:var(--hm-muted);line-height:1.6;}

/* ============================================================
   TESTIMONIALS
   ============================================================ */
.hm-testimonials{max-width:var(--hm-container);margin:64px auto;padding:0 20px;}
.hm-testimonials__track{display:flex;gap:20px;overflow-x:auto;scroll-snap-type:x mandatory;padding-bottom:8px;}
.hm-testi-card{
	flex:0 0 320px;scroll-snap-align:start;background:#fff;border:1px solid var(--hm-border);
	border-radius:var(--hm-radius);padding:22px;
}
.hm-testi-card__head{display:flex;align-items:center;gap:12px;margin-bottom:12px;}
.hm-testi-card__head img{width:48px;height:48px;border-radius:50%;object-fit:cover;}
.hm-testi-card__name{font-weight:700;color:var(--hm-ink);font-size:14.5px;}
.hm-testi-card__body{font-size:14px;color:var(--hm-muted);line-height:1.65;}

/* ============================================================
   CTA / SUBSCRIBE
   ============================================================ */
.hm-cta{
	background:linear-gradient(120deg,var(--hm-primary-dark),var(--hm-primary));
	color:#fff;padding:44px 20px;
	display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:24px;
	max-width:calc(var(--hm-container) + 40px);margin:0 auto;border-radius:var(--hm-radius);
}
.hm-cta__text h2{margin:0 0 6px;font-size:22px;font-weight:800;}
.hm-cta__text p{margin:0;color:rgba(255,255,255,.85);font-size:14.5px;}
.hm-cta__form{display:flex;gap:10px;flex-wrap:wrap;flex:1 1 380px;max-width:460px;}
.hm-cta__form input{
	/* width:auto + flex ghi đè luật cũ "input,select{width:100%}" trong style_home.css
	   (luật cũ khiến input chiếm hết 1 dòng, đẩy nút Gửi xuống dòng dưới) */
	border:none;border-radius:999px;padding:13px 20px;font-size:14.5px;
	width:auto;min-width:0;flex:1 1 220px;
}
.hm-cta__form button{border:none;flex:0 0 auto;}

/* ============================================================
   NEWS
   ============================================================ */
.hm-news{max-width:var(--hm-container);margin:64px auto 80px;padding:0 20px;}
.hm-news__grid{display:grid;grid-template-columns:1fr;gap:22px;}
@media (min-width:700px){ .hm-news__grid{grid-template-columns:repeat(3,1fr);} }

.hm-news-card{
	display:block;background:#fff;border:1px solid var(--hm-border);border-radius:var(--hm-radius);
	overflow:hidden;text-decoration:none;color:inherit;transition:transform .2s ease,box-shadow .2s ease;
}
.hm-news-card:hover{transform:translateY(-5px);box-shadow:var(--hm-shadow-hover);}
.hm-news-card__image{aspect-ratio:16/10;overflow:hidden;background:var(--hm-bg-soft);}
.hm-news-card__image img{width:100%;height:100%;object-fit:cover;}
.hm-news-card__body{padding:16px 18px;}
.hm-news-card__title{font-size:15.5px;font-weight:700;color:var(--hm-ink);margin:0 0 8px;line-height:1.4;}
.hm-news-card__excerpt{font-size:13.5px;color:var(--hm-muted);line-height:1.6;margin:0 0 10px;
	display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;}