/*====================================== HOMEPAGE (filtered for front-page.php) =====================================*/
html { scroll-behavior: smooth; }

html, body { height: 100%; }

body {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    background: #0f1b2d;
}

main { flex: 1; }

/* HERO */
.hero { background-color: #f6f9f9; display: flex; align-items: center; height: auto; padding: 36px 0; }
.hero-wrapper { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr); align-items: center; gap: 48px; }
.hero-content { max-width: 560px; }
.hero-image { width: 100%; max-width: 700px; margin-left: auto; display: flex; align-items: center; justify-content: center; }
.hero-image img { width: 100%; height: auto; object-fit: contain; display: block; max-width: 100%; }

.badge { background: rgba(63, 130, 116, 0.1); color: #3f8274; padding: 8px 15px; border-radius: 50px; font-size: 13px; display: inline-block; margin-bottom: 25px; }
.hero .badge { background: linear-gradient(135deg, #3f8274, #3f7d68); color: white; padding: 6px 18px; font-weight: 700; font-size: 14px; box-shadow: 0 4px 15px rgba(63,130,116,0.3); letter-spacing: 0.5px; margin-bottom: 25px; }

.main-title { font-size: 65px; font-weight: 800; line-height: 1.1; }
.sub-title { font-size: 28px; font-weight: 100; text-transform: none; margin-bottom: 25px; color: #3f8274; }
.description { font-size: 16px; color: var(--gray-color); margin-bottom: 35px; max-width: 500px; }

.cta-group { display: flex; gap: 10px; }
.btn { display: inline-flex; padding: 14px 30px; border-radius: 8px; font-weight: 600; transition: 0.3s; gap: 12px; flex-wrap: wrap; }
.btn-primary { background-color: #3f8274; color: white !important; font-weight: 20; }
.btn-outline { border: 1px solid #ddd; background: white; color: var(--text-color); font-weight: 20; text-transform: none; }

/* CATEGORY */
.category { padding-top: 40px; padding-bottom: 40px; background: #fff; }
.category-header { margin-bottom: 30px; text-align: center; } 
.category-header .category-description { text-align: center; color: #666; font-size: 16px; }
.category-grid { width: 1100px; margin: 0 auto 10px auto; display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; box-sizing: border-box; }
.category .section-heading { text-align: center; font-size: 36px; font-weight: 700; color: #333; margin-bottom: 10px; }
.category-grid .card { position: relative; border-radius: 12px; overflow: hidden; width: 100%; height: 175px; } 
.category-grid .card img { width: 100%; height: 100%; object-fit: cover; transition: 0.4s; display: block; position: relative; z-index: 1; }
.category-grid .overlay { position: absolute; inset: 0; transition: 0.3s; z-index: 2; pointer-events: none; }
.category-grid .content {position: absolute;top: 15px;left: 15px; right: 15px; bottom: 15px; display: flex; flex-direction: column; align-items: flex-start; z-index: 2; }
.badge-water { display: inline-block; font-size: 13px; padding: 4px 8px; border-radius: 10px; margin-bottom: 12px; font-weight: 600; text-transform: capitalize; background: #3f8274; color: #f6f9f9; word-spacing: 0.1em; }
.title-box { display: inline-block; color: #fff; font-size: 22px; font-weight: 1000; margin-bottom: 10px; margin-bottom: 20px; -webkit-text-stroke: 1px #000; }
.category-grid .card:hover img { transform: scale(1.05); }
.category-grid .card:hover .overlay { background: rgba(255, 255, 255, 0.35); }
.category-grid .card:nth-child(3n+2) .badge-water { background: #D2801D;}

/* SOLUTION */
.solution { padding: 40px 0; background: #f6f9f9; }
.container { width: 1200px; max-width: 90%; margin: auto; }
.section-title { text-align: center; font-size: 36px; margin-bottom: 10px}
.section-subtitle { text-align: center; color: #666; font-size: 16px; margin-bottom: 30px; }
.tabs { display: flex; justify-content: center; gap: 20px; margin-bottom: 40px; }
.tab { padding: 12px 25px; border: none; cursor: pointer; background: #fff; border-radius: 30px; transition: 0.3s; font-weight: 600; box-shadow: 0 4px 10px rgba(0, 0, 0, 0.08); }
.tab.active { background: #3f8274;color: #fff; }
.tab:hover { transform: translateY(-3px); }
.solution .grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 25px; }
.card { position: relative; border-radius: 12px; overflow: hidden; width: 100%; transition: 0.3s; box-shadow: 0 6px 20px rgba(0, 0, 0, 0.08); }
.card img { width: 100%; height: 175px; object-fit: cover; }
.card h3 { padding: 15px 15px 10px 15px; font-size: 18px; color: #333; }
.card p { padding: 0 15px 20px; color: #666; font-size: 14px; }
.solution .card:hover { transform: translateY(-8px); box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15); }
.tab-content { display: none; }
.tab-content.active { display: block; }

/* CERTIFICATE SECTION */
.certificate-section { padding: 40px 20px; background: #fff; }
.certificate-section .section-title { text-align: center; font-size: 36px; font-weight: 700; color: #333; margin-bottom: 10px; margin-top: 0; }
.certificate-section .section-sub { text-align: center; color: #666; font-size: 15px; margin-bottom: 40px; }
.certificate-swiper {
    max-width: 1100px;
    margin: 0 auto;
    padding: 10px 40px 50px 40px;
    position: relative;
}

.certificate-swiper .swiper-button-next,
.certificate-swiper .swiper-button-prev {
    color: #3f8274;
    transform: scale(0.7); 
}

.certificate-swiper .swiper-pagination-bullet-active {
    background-color: #3f8274;
}
.cert-item { border-radius: 5px; overflow: hidden; transition: all 0.3s ease; background: #ffffff; }
.cert-item:hover { transform: translateY(-8px); }
.cert-item img { width: 100%; height: auto; display: block; cursor: pointer; transition: opacity 0.3s ease; color: #ffffff; }
.cert-item img:hover { opacity: 0.8; }

/* SERVICE CARDS */
.service-cards { padding: 40px 20px; background: #f6f9f9; }
.service-cards .section-heading { text-align: center; font-size: 36px; font-weight: 700; color: #333; margin-bottom: 10px; }
.service-cards .service-description { text-align: center; color: #666; font-size: 16px; margin: 0 0 20px 0; }
.grid { display: grid; grid-template-columns: repeat(2,1fr); gap: 30px; }

.card-item { background: #fff; padding: 35px; border-radius: 18px; box-shadow: 0 4px 16px rgba(0,0,0,0.08); transition: all 0.3s ease; position: relative; border-left: 6px solid transparent; }
.card-item:hover { transform: translateY(-8px); box-shadow: 0 12px 28px rgba(0,0,0,0.12); }
.card-item.green { border-left: 6px solid #3f8274; }
.card-item.orange { border-left: 6px solid #D2801D; }
.badge { display: inline-block; font-size: 12px; padding: 6px 12px; border-radius: 16px; margin-bottom: 12px; font-weight: 700; text-transform: capitalize; }
.green .badge { background: none; color: #3f8274; font-size: 22px; padding: 0;}
.orange .badge { background: none; color: #D2801D; font-size: 22px; padding: 0;}
.card-item h3 { margin-bottom: 12px; font-size: 22px; color: #333; font-weight: 700; }
.card-item p { font-size: 14px; color: #666; line-height: 1.6; }
.card-item:nth-child(3), .card-item:nth-child(4) { background: #fff; padding: 35px; border-radius: 18px; box-shadow: 0 4px 16px rgba(0,0,0,0.08); transition: all 0.3s ease; transform: translateX(30px); }
.card-item:nth-child(3):hover, .card-item:nth-child(4):hover { transform: translateX(30px) translateY(-8px); box-shadow: 0 12px 28px rgba(0,0,0,0.12); }

/* RESPONSIVE */
@media (max-width: 1120px) {
    .category-grid {
        width: 100%;
        max-width: 100%;
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }

    .category { padding: 0 15px; }
}

@media (max-width: 1080px) {
    .hero { padding: 30px 0; }
    .hero-wrapper { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 28px; }
    .cta-group { gap: 12px; }
    .btn-primary, .btn-outline { width: fit-content; }
    .solution .card { width: 100%; }
    .solution .grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 25px; }
}

@media (max-width: 925px) {
    .hero {
        padding: 28px 16px;
    }

    .hero-wrapper {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 24px;
    }

    .hero-content {
        max-width: 680px;
        margin: 0 auto;
    }

    .hero-image {
        max-width: min(680px, 100%);
        margin: 0 auto;
    }

    .cta-group {
        justify-content: center;
    }
}

@media (max-width: 1024px) {
    .hero-wrapper { gap: 30px; }
    .main-title { font-size: 56px; line-height: 1.1; }
    .sub-title { font-size: 24px; margin-bottom: 20px; }
    .description { font-size: 15px; max-width: 450px; }
    .btn { padding: 12px 24px; font-size: 14px; }
    .category-grid .card { height: 200px; }
    .category-grid .card img { height: 100%; width: 100%; object-fit: cover; }
    .solution .grid { gap: 15px; }
    .solution .grid img { width: 100%; height: 175px; object-fit: cover; }
}

@media (max-width: 820px) {
    .main-title { font-size: 60px; line-height: 1.15; }
    .sub-title { font-size: 26px; margin-bottom: 20px; }
    .description { font-size: 15px; margin-bottom: 30px; }
    .cta-group { display:flex; gap:10px; }
}

@media (max-width: 768px) {
    .hero-content { width:100%; }
    .main-title { font-size: 42px; line-height: 1.2; margin-bottom: 10px; }
    .sub-title { font-size: 20px; margin-bottom: 18px; line-height: 1.35; }
    .description { font-size: 14px; line-height: 1.65; margin: 0 auto 30px; max-width: 90%; }
    .badge { font-size: 12px; padding: 6px 12px; margin-bottom: 16px; }
    .cta-group { justify-content: center; gap: 12px; }
    .btn { justify-content: center; }
    .btn-outline { margin-left: 0; }
    .grid { grid-template-columns: 1fr; }
    .card-item { min-height: 100px; }
    .card-item:nth-child(3), .card-item:nth-child(4) { transform: translateX(0px); }
    .card-item p { text-align: justify; }
    .category-grid { grid-template-columns: 1fr; }
    .category { padding: 20px 15px; }
    .category-header { margin-bottom: 30px; }
    .category-header .section-heading { font-size: 28px; margin-top: 20px; }
    .category-header .category-description { font-size: 14px; }
    .category-grid { width: 100%; max-width: 100%; margin: 20px auto; grid-template-columns: 1fr; gap: 15px; padding: 0; }
    .category-grid .card { height: 200px; width: 100%;}
    .category-grid .card img { height: 100%; width: 100%; object-fit: cover; }
    .category-grid .badge-water { font-size: 12px; padding: 5px 10px; }
    .category-grid .title-box { font-size: 20px; margin-bottom: 8px; }
    .solution .grid { width: auto; max-width: 100%; grid-template-columns: repeat(1, 1fr); gap: 25px; }
    .solution .card h3 { text-align: center; }
    .solution .card p { text-align: justify; }
    .certificate-section { padding: 40px 20px; }
    .certificate-section .section-title { font-size: 28px; margin-bottom: 8px; }
    .certificate-section .section-sub { font-size: 13px; margin-bottom: 30px; }
    .certificate-swiper {
        padding: 10px 0 40px 0;
    }
    .certificate-swiper .swiper-button-next,
    .certificate-swiper .swiper-button-prev {
        display: none;
    }
    .cert-item img { width: 100%; }
}

@media (max-width: 480px) {
    .category-grid { width: 100%;  max-width: 100%; grid-template-columns: 1fr; gap: 12px; margin: 15px 0; padding: 0; }
    .category-grid .card { height: 180px; width: 100%; }
    .category-grid .card img { height: 100%; width: 100%; object-fit: cover; }
    .category .section-heading { font-size: 24px; margin-top: 15px; }
    .category-header .category-description { font-size: 13px; margin: 0 0 15px 0; }
    .category-grid .badge-water { padding: 4px 10px; }
}