/* Homepage layout aligned with the approved SANITECH mockup. */
:root{--hr-navy:#071b4a;--hr-teal:#007c70;--hr-green:#00956f;--hr-muted:#445467;--hr-surface:#f2f6f7;--hr-line:#dce7e8}
.home-product-groups>.container.custom,.home-solutions>.container.custom,.home-why-sanitech>.container.custom,.home-contact__stage>.container.custom{width:min(100% - 40px,1200px);max-width:1200px;margin-inline:auto;padding-inline:0}

/*
 * Hero typography / order only.
 * ห้ามทับ min/max-height หรือ aspect-ratio ที่นี่
 * (ไฟล์นี้โหลดท้ายหน้าจาก section-home-contact จะทับ home-hero-v2-critical.css
 * แล้วทำให้สไลด์แบน/เพี้ยน)
 */
@media (min-width:992px){
 #rs-slider.home-hero-v2 .content-part .container{width:min(100% - 40px,1200px);max-width:1200px;padding-inline:0}
 #rs-slider.home-hero-v2 .home-hero-v2__inner{width:min(47%,555px);max-width:555px}
 #rs-slider.home-hero-v2 .home-hero-v2__copy{display:flex;flex-direction:column;width:100%;max-width:none;min-width:0;gap:0}
 #rs-slider.home-hero-v2 .home-hero-v2__head{order:1;gap:0}
 #rs-slider.home-hero-v2 .home-hero-v2__features-row{order:2}
 #rs-slider.home-hero-v2 .home-hero-v2__actions{order:3}
 #rs-slider.home-hero-v2 .home-hero-v2__title{width:100%;max-width:540px;margin-bottom:22px;font-size:clamp(36px,3vw,48px);line-height:1.08;letter-spacing:-.025em;word-break:normal;overflow-wrap:normal}
 #rs-slider.home-hero-v2 .home-hero-v2__subtitle{margin-bottom:18px;font-size:16px;line-height:1.45}
 #rs-slider.home-hero-v2 .home-hero-v2__desc{max-width:520px;margin:0;font-size:15px;line-height:1.6}
 #rs-slider.home-hero-v2 .home-hero-v2__actions,#rs-slider.home-hero-v2 .content-part .home-hero-v2__actions{margin:0}
 #rs-slider.home-hero-v2 .home-hero-v2__features-row{width:100%;max-width:520px;margin:24px 0 26px;padding:0}
 #rs-slider.home-hero-v2 .home-hero-v2__features{display:flex;align-items:stretch;justify-content:flex-start;gap:0;width:100%;padding:0}
 #rs-slider.home-hero-v2 .home-hero-v2__feature{flex:1 1 0;flex-direction:column;align-items:center;justify-content:flex-start;gap:4px;min-width:0;max-width:none;padding:0 14px;text-align:center;border-right:1px solid rgba(0,124,112,.24)}
 #rs-slider.home-hero-v2 .home-hero-v2__feature:first-child{padding-left:0}
 #rs-slider.home-hero-v2 .home-hero-v2__feature:last-child{padding-right:0;border-right:0}
 #rs-slider.home-hero-v2 .home-hero-v2__feature-icon{width:34px;height:34px;margin:0}
 #rs-slider.home-hero-v2 .home-hero-v2__feature-icon i{font-size:27px}
 #rs-slider.home-hero-v2 .home-hero-v2__feature-text{align-items:center;width:100%}
 #rs-slider.home-hero-v2 .home-hero-v2__feature-en{display:block;color:#082b46;font-size:13px;font-weight:800;line-height:1.2;text-align:center;white-space:normal}
 #rs-slider.home-hero-v2 .home-hero-v2__feature-th{color:#405261;font-size:13px;font-weight:500;line-height:1.25;text-align:center;white-space:normal}
}

/* Product groups */
.home-product-groups{padding:48px 0 0}
.home-product-groups__head{max-width:780px;margin:0 auto 24px;text-align:center}
.home-product-groups__head h2{display:flex;align-items:center;justify-content:center;gap:24px;font-size:clamp(27px,2.6vw,35px)}
.home-product-groups__head h2::before,.home-product-groups__head h2::after{content:"";display:block;width:54px;height:2px;margin:0;border-radius:999px;background:var(--hr-teal)}
.home-product-groups__head p{margin-top:8px;color:#263749;font-size:15px;line-height:1.5}
.home-product-groups__grid{grid-template-columns:repeat(6,minmax(0,1fr));gap:12px}
.home-product-groups__card{border-color:#e3eaeb;border-radius:14px;background:linear-gradient(180deg,#f7f9f9,#edf2f3);box-shadow:0 4px 10px rgba(7,27,74,.08)}
.home-product-groups__media{
    display:flex;
    align-items:center;
    justify-content:center;
    width:100%;
    height:clamp(132px,11.5vw,154px);
    aspect-ratio:auto;
    padding:10px 12px 6px;
    overflow:hidden;
    background:transparent;
}
.home-product-groups__media img{
    display:block;
    width:84%;
    height:84%;
    max-width:none;
    max-height:none;
    aspect-ratio:auto;
    object-fit:contain;
    object-position:center;
    padding:0;
    transition:transform .35s ease;
}
.home-product-groups__card:hover .home-product-groups__media img{
    transform:scale(1.12);
}
.home-product-groups__card:hover{
    transform:none;
}
.home-product-groups__body{
    position:relative;
    z-index:2;
    min-height:72px;
    margin-top:-12px;
    padding:13px 11px 12px;
    align-items:center;
    border-top:1px solid rgba(255,255,255,.92);
    border-radius:0;
    background:rgba(255,255,255,.96);
    box-shadow:
        0 -7px 18px rgba(7,27,74,.08),
        0 -1px 4px rgba(7,27,74,.05);
    backdrop-filter:blur(4px);
    -webkit-backdrop-filter:blur(4px);
}
.home-product-groups__body h3{font-size:13px;line-height:1.3}
.home-product-groups__arrow{flex-basis:24px;width:24px;height:24px;font-size:14px}

/* Sanitary solution */
.home-solutions{padding:40px 0 0;background:#fff}
.home-solutions__layout{grid-template-columns:minmax(0,1fr) minmax(0,1.08fr);gap:30px}
.home-solutions__media{
    position:relative;
    width:min(90%,500px);
    height:auto;
    min-height:0;
    aspect-ratio:auto;
    justify-self:center;
    margin-inline:auto;
    overflow:hidden;
    border:0;
    border-radius:0;
    background:transparent;
    box-shadow:none;
    clip-path:none;
}
.home-solutions__media::before{
    display:none;
    content:none;
}
.home-solutions__media img{
    display:block;
    width:100%;
    height:auto;
    min-height:0;
    max-height:none;
    object-fit:contain;
    object-position:center;
}
.home-solutions__kicker{margin-bottom:6px;color:var(--hr-teal);font-size:13px;letter-spacing:.15em}
.home-solutions__head h2{font-size:clamp(26px,2.35vw,34px)}
.home-solutions__head h2::after{display:none}
.home-solutions__lead{margin-top:8px;color:#263749;font-size:14px;line-height:1.55}
.home-solutions__grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;margin-top:19px}
.home-solutions__item{display:flex;flex-direction:row;align-items:flex-start;gap:10px;min-width:0;padding:13px 12px;text-align:left;border:1px solid var(--hr-line);border-radius:12px;background:#f7fafb;box-shadow:0 6px 18px rgba(5,45,61,.045)}
.home-solutions__item:last-child{border-right:1px solid var(--hr-line)}
.home-solutions__icon{width:38px;height:38px;flex:0 0 38px;border-radius:9px;color:var(--hr-teal);font-size:25px;background:#e9f6f3}
.home-solutions__item h3{margin:0 0 3px;font-size:14px;line-height:1.3}
.home-solutions__item p{display:block;margin:0;color:#526270;font-size:13px;line-height:1.4}

/* Why SANITECH */
.home-why-sanitech{padding:24px 0 0;color:var(--hr-navy);background:#fff}
.home-why-sanitech>.container.custom{display:grid;grid-template-columns:260px minmax(0,1fr);align-items:center;padding:22px 25px;border-radius:15px;background:linear-gradient(100deg,#f3f7f8,#eaf1f2)}
.home-why-sanitech__head{margin:0;padding-right:22px;text-align:left;border-right:1px solid #ccd9da}
.home-why-sanitech__kicker{display:block;margin-bottom:5px;color:var(--hr-teal);font-size:13px;font-weight:800;letter-spacing:.12em}
.home-why-sanitech__head h2{color:var(--hr-navy);font-size:25px;line-height:1.13}
.home-why-sanitech__head h2::after{content:"";display:block;width:48px;height:3px;margin-top:9px;background:var(--hr-teal)}
.home-why-sanitech__lead{margin:10px 0 0;color:#4e5f6d;font-size:13px;line-height:1.45}
.home-why-sanitech__grid{grid-template-columns:repeat(4,minmax(0,1fr));gap:0}
.home-why-sanitech__item{min-width:0;padding:0 15px;border-right:1px solid #ccd9da}
.home-why-sanitech__item:last-child{border-right:0}
.home-why-sanitech__icon{width:48px;height:48px;margin-bottom:7px;border-radius:50%;color:var(--hr-teal);font-size:27px;background:#fff;box-shadow:0 5px 15px rgba(7,49,65,.08)}
.home-why-sanitech__item h3{color:var(--hr-navy);font-size:14px;line-height:1.3}
.home-why-sanitech__item p{margin-top:4px;color:#3c4c5c;font-size:13px;line-height:1.42}

/* Knowledge cards */
.home-blog-v2.home-blog-v2--compact{--hbv2-primary:var(--hr-teal);--hbv2-primary-deep:#005d58;--hbv2-heading:var(--hr-navy);padding:36px 0 0!important}
.home-blog-v2__decor{display:none}
.home-blog-v2__stage{width:min(100% - 40px,1200px);max-width:1200px;padding-inline:0}
.home-blog-v2__head{align-items:center;margin-bottom:12px}
.home-blog-v2__head-main{max-width:none}
.home-blog-v2__kicker,.home-blog-v2__lead{display:none}
.home-blog-v2__title{margin:0;font-size:25px;line-height:1.25}
.home-blog-v2__title::after{content:"";display:block;width:48px;height:3px;margin-top:7px;background:var(--hr-teal)}
.home-blog-v2__view-all{padding:6px 0;color:var(--hr-teal);font-size:14px;background:transparent;box-shadow:none}
.home-blog-v2__view-all:hover{color:#005d58;transform:none;box-shadow:none}
.home-blog-v2__grid--equal{grid-template-columns:repeat(3,minmax(0,1fr));gap:14px}
.home-blog-v2__card--standard{display:grid;grid-template-columns:44% minmax(0,1fr);min-height:122px;border-radius:14px;box-shadow:0 4px 12px rgba(7,27,74,.07)}
.home-blog-v2__card-media{height:100%;min-height:122px;aspect-ratio:auto}
.home-blog-v2__card--standard .home-blog-v2__card-body{gap:4px;padding:11px 12px}
.home-blog-v2__cat{display:none}
.home-blog-v2__card-title{display:-webkit-box;overflow:hidden;font-size:14px;line-height:1.35;-webkit-box-orient:vertical;-webkit-line-clamp:3}
.home-blog-v2__card-excerpt,.home-blog-v2__meta-item:first-child,.home-blog-v2__card-arrow{display:none}
.home-blog-v2__card-foot{margin-top:auto;padding-top:4px;border:0}
.home-blog-v2__meta-item{color:#263749;font-size:13px}

/* Compact CTA */
.home-contact{padding:24px 0 32px}
.home-contact__stage{width:min(100% - 40px,1200px);margin-inline:auto;border-radius:17px;background:linear-gradient(105deg,#00635f,#008e76)}
.home-contact__bg{opacity:.16}
.home-contact__overlay{background:linear-gradient(90deg,rgba(0,90,86,.98),rgba(0,121,105,.9))}
.home-contact__stage>.container.custom{width:100%;max-width:none}
.home-contact__inner{min-height:0;padding:16px 28px}
.home-contact__content{display:grid;grid-template-columns:58px minmax(0,1fr) auto;align-items:center;gap:18px;max-width:none}
.home-contact__main-icon{display:grid;place-items:center;width:58px;height:58px;color:#fff;font-size:42px}
.home-contact .sec-title.home-contact__header{min-width:0}
.home-contact .sec-title .sub-text.home-contact__kicker{display:none}
.home-contact .sec-title .title.title2.home-contact__heading{display:flex;flex-wrap:wrap;gap:0 .3em;margin:0 0 2px;padding:0;font-size:clamp(20px,2vw,27px);line-height:1.2}
.home-contact .sec-title .title.title2.home-contact__heading .home-contact__title-line{display:inline}
.home-contact .sec-title .desc.home-contact__lead{max-width:600px;font-size:13px;line-height:1.4}
.home-contact__actions{flex-wrap:nowrap;gap:12px}
.home-contact__btn{min-width:178px;min-height:42px;padding:0 20px;border-radius:8px;font-size:14px;font-weight:700}
.home-contact__btn--primary{color:#006e64;background:#fff;border-color:#fff}
.home-contact__btn--primary:hover,.home-contact__btn--primary:focus-visible{color:#005c55;background:#eef9f7}
.home-contact__btn--secondary{color:#fff;background:transparent;border-color:rgba(255,255,255,.85)}

@media (max-width:991.98px){
 .home-product-groups__grid{grid-template-columns:repeat(3,minmax(0,1fr))}
 .home-solutions__layout{grid-template-columns:1fr}
 .home-solutions__media{width:min(100%,620px)}
 .home-solutions__media,.home-solutions__media img{min-height:0}
 .home-why-sanitech>.container.custom{grid-template-columns:1fr}
 .home-why-sanitech__head{padding:0 0 14px;border-right:0;text-align:center}
 .home-why-sanitech__head h2::after{margin-inline:auto}
 .home-contact__content{grid-template-columns:52px minmax(0,1fr)}
 .home-contact__actions{grid-column:1/-1;width:100%}
 .home-contact__btn{flex:1 1 0}
}

@media (max-width:767.98px){
 .home-product-groups{padding-top:36px}
 .home-solutions{padding-top:32px}
 .home-why-sanitech{padding-top:20px}
 .home-blog-v2.home-blog-v2--compact{padding-top:28px!important}
 .home-contact{padding:20px 0 24px}
 .home-product-groups>.container.custom,.home-solutions>.container.custom,.home-why-sanitech>.container.custom,.home-blog-v2__stage,.home-contact__stage{width:min(100% - 32px,1200px)}
 .home-product-groups__head h2{gap:12px}
 .home-product-groups__head h2::before,.home-product-groups__head h2::after{width:28px}
 .home-product-groups__grid{grid-template-columns:repeat(2,minmax(0,1fr))}
 .home-product-groups__media{height:150px}
 .home-solutions__grid{grid-template-columns:1fr;row-gap:10px}
 .home-why-sanitech__grid{grid-template-columns:repeat(2,minmax(0,1fr))}
 .home-why-sanitech__item:nth-child(2){border-right:0}
 .home-blog-v2__grid--equal{grid-template-columns:1fr}
 .home-contact__inner{padding:18px}
 .home-contact__content{grid-template-columns:44px minmax(0,1fr);gap:12px}
 .home-contact__main-icon{width:44px;height:44px;font-size:34px}
 .home-contact__actions{flex-direction:column}
 .home-contact__btn{width:100%;min-width:0;font-size:14px}
}

@media (max-width:399.98px){
 .home-product-groups__grid{grid-template-columns:1fr}
 .home-product-groups__media{height:190px}
 .home-why-sanitech__grid{grid-template-columns:1fr}
 .home-why-sanitech__item{border-right:0;border-bottom:1px solid #ccd9da;padding-block:12px}
 .home-why-sanitech__item:last-child{border-bottom:0}
}
