/* ============================================================
   MARBOX — Clean rebuild
   Fonts · Tokens · Base · Components · Sections · Responsive
   ============================================================ */

/* ---------- Fonts ---------- */
@font-face {
    font-family: "Inter";
    src: url("../fonts/InterVariable.woff2") format("woff2");
    font-weight: 100 900;
    font-style: normal;
    font-display: swap;
}

/* ---------- Design tokens ---------- */
:root {
    /* Brand greens */
    --green-900: #061d13; /* darkest — dark sections, ink */
    --green-800: #0b2a1b;
    --green-700: #1a3127; /* dark card / input */
    --green-600: #1c4c36; /* primary button */
    --green-500: #2e7d53;
    --green-300: #73c69c; /* light accent / soft button */
    --green-200: #a6ddc0;
    --green-50: #edfdf6; /* mint tint */

    /* Neutrals */
    --ink: #061d13;
    --body: #3e3e3e;
    --muted: #5e5e5e;
    --muted-2: #6f6f6f;
    --line: #e7e7e7;
    --line-dark: rgba(255, 255, 255, 0.12);
    --surface: #f3f3f3;
    --white: #ffffff;

    /* Typography */
    --font:
        "Inter", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;

    /* Scale (fluid) */
    --fs-h1: clamp(2.6rem, 1.6rem + 4.2vw, 4.75rem); /* ~42 → 76 */
    --fs-h2: clamp(2rem, 1.2rem + 3.2vw, 4rem); /* ~32 → 64 */
    --fs-h3: clamp(1.35rem, 1.1rem + 0.8vw, 1.75rem); /* ~22 → 28 */
    --fs-lead: clamp(1rem, 0.95rem + 0.35vw, 1.25rem); /* ~16 → 20 */

    /* Layout */
    --container: 1280px;
    --gutter: clamp(1.25rem, 4vw, 5rem);
    --nav-h: 80px;
    --radius: 16px;
    --radius-sm: 8px;
    --radius-pill: 999px;
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.06);
    --shadow-md: 0 24px 60px -24px rgba(6, 29, 19, 0.25);
}

/* ---------- Reset / base ---------- */
*,
*::before,
*::after {
    box-sizing: border-box;
}
* {
    margin: 0;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: calc(var(--nav-h) + 16px);
}

body {
    font-family: var(--font);
    font-optical-sizing: auto;
    font-size: 1.125rem;
    line-height: 1.6;
    color: var(--body);
    background: var(--white);
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

img,
svg,
video {
    display: block;
    max-width: 100%;
}
img {
    height: auto;
}
a {
    color: inherit;
    text-decoration: none;
}
ul,
ol {
    list-style: none;
    padding: 0;
}
button,
input,
textarea {
    font: inherit;
    color: inherit;
}
h1,
h2,
h3,
h4 {
    color: var(--ink);
    line-height: 1.12;
    letter-spacing: -0.02em;
    font-weight: 600;
}
.icon {
    display: inline-block;
    vertical-align: middle;
    flex: none;
}

/* ---------- Layout helpers ---------- */
.container {
    width: 100%;
    max-width: calc(var(--container) + var(--gutter) * 2);
    margin-inline: auto;
    padding-inline: var(--gutter);
}

.badge {
    display: inline-block;
    width: fit-content; /* never stretch inside grid parents */
    padding: 8px 16px;
    border-radius: var(--radius-pill);
    background: var(--surface);
    color: var(--ink);
    font-size: 0.95rem;
    font-weight: 500;
    letter-spacing: -0.01em;
}
.section-head--center .badge {
    margin-inline: auto;
}
.badge--ondark {
    background: rgba(255, 255, 255, 0.08);
    color: #fff;
}

.section-title {
    font-size: var(--fs-h2);
    font-weight: 600;
}
.section-title--light {
    color: #fff;
}
.section-lead {
    font-size: var(--fs-lead);
    color: var(--muted);
    max-width: 46ch;
}
.section-lead--light {
    color: rgba(255, 255, 255, 0.72);
}

.section-head {
    display: grid;
    gap: 18px;
    margin-bottom: 56px;
}
.section-head--center {
    justify-items: center;
    text-align: center;
}
.section-head--center .section-lead {
    max-width: 62ch;
}
.section-head--split {
    grid-template-columns: 1fr auto;
    align-items: end;
    gap: 24px;
}

/* ---------- Buttons ---------- */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 14px 26px;
    border: 0;
    border-radius: var(--radius-sm);
    font-size: 1rem;
    font-weight: 600;
    letter-spacing: -0.01em;
    cursor: pointer;
    transition:
        transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1),
        background-color 0.2s ease,
        box-shadow 0.3s ease;
    white-space: nowrap;
}
.btn:hover {
    transform: scale(1.04);
    box-shadow: 0 12px 26px -10px rgba(6, 29, 19, 0.4);
}
.btn:active {
    transform: scale(0.98);
}
.btn--primary {
    background: var(--green-600);
    color: #fff;
}
.btn--primary:hover {
    background: #16402d;
}
.btn--soft {
    background: var(--green-300);
    color: var(--green-900);
}
.btn--soft:hover {
    background: var(--green-200);
}
.btn--block {
    width: 100%;
    justify-content: center;
    margin-top: 6px;
}

/* ============================================================
   HEADER
   ============================================================ */
.site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: saturate(1.2) blur(8px);
    border-bottom: 1px solid transparent;
    transition:
        box-shadow 0.25s ease,
        border-color 0.25s ease;
    box-shadow: 0 1px 2px #00000026;
}
.site-header.is-scrolled {
    box-shadow: var(--shadow-sm);
    border-color: var(--line);
}
.site-header__inner {
    display: flex;
    align-items: center;
    gap: 24px;
    height: var(--nav-h);
}
.logo img {
    height: 34px;
    width: auto;
}
.nav {
    margin-inline: auto;
}
.nav__list {
    display: flex;
    gap: clamp(14px, 2vw, 34px);
}
.nav__list a {
    font-size: 1.0625rem;
    font-weight: 500;
    color: var(--ink);
    padding: 6px 2px;
    position: relative;
    transition: color 0.2s ease;
}
.nav__list a:hover {
    color: var(--green-600);
}
.site-header__cta {
    padding: 12px 22px;
}

.nav-toggle {
    display: none;
    background: none;
    border: 0;
    padding: 6px;
    color: var(--ink);
    cursor: pointer;
}

/* ============================================================
   HERO
   ============================================================ */
.hero {
    position: relative;
    overflow: hidden;
    background-color: #fff;
    /* layers (top → bottom): mint glow · white wash (fades marble to ~50%) · fixed marble */
    background-image:
        radial-gradient(
            120% 90% at 82% 10%,
            var(--green-50) 0%,
            rgba(237, 253, 246, 0) 55%
        ),
        linear-gradient(rgba(255, 255, 255, 0.55), rgba(255, 255, 255, 0.55)),
        url("../images/XQeoEqW1mKNCDfoUZmATDn3qFQs.png");
    background-attachment:
        scroll, scroll, fixed; /* marble stays fixed → parallax */
    background-position:
        center,
        center,
        center top;
    background-size: cover, cover, cover;
    background-repeat: no-repeat;
}
.hero__inner {
    display: grid;
    grid-template-columns: 1.15fr 1fr;
    align-items: center;
    gap: 40px;
    /* height driven by content (not 100vh) → gap under header stays consistent on any screen */
    padding-block: clamp(28px, 3.5vw, 56px);
}
.hero__title {
    font-size: var(--fs-h1);
    font-weight: 700;
}
.hero__lead {
    font-size: var(--fs-lead);
    color: var(--muted);
    margin-top: 22px;
    max-width: 40ch;
}
.hero__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    margin-top: 30px;
}

.stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
    margin-top: 52px;
}
.stat__icon {
    color: var(--green-600);
    margin-bottom: 12px;
}
.stat__value {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--ink);
}
.stat__label {
    font-size: 0.95rem;
    color: var(--muted);
    margin-top: 2px;
}

/* Hero media composition */
.hero__media {
    position: relative;
    align-self: stretch;
    min-height: 520px;
}
.hero__arch {
    position: absolute;
    top: 50%;
    left: 52%;
    width: 78%;
    transform: translate(-50%, -50%);
    z-index: 1;
}
.hero__cart {
    position: absolute;
    bottom: 0;
    right: -4%;
    width: 46%;
    z-index: 3;
}
.hero__person {
    position: absolute;
    bottom: 0;
    left: 48%;
    width: 74%;
    transform: translateX(-50%);
    z-index: 2;
    filter: drop-shadow(0 24px 40px rgba(6, 29, 19, 0.18));
}
.hero__leaf {
    position: absolute;
    z-index: 4;
    width: 74px;
    opacity: 0.95;
    animation: float 6s ease-in-out infinite;
}
.hero__leaf--1 {
    top: 12%;
    left: 6%;
    width: 96px;
    animation-delay: 0s;
}
.hero__leaf--2 {
    top: 40%;
    right: 2%;
    width: 64px;
    animation-delay: 1.2s;
}
.hero__leaf--3 {
    bottom: 16%;
    left: 2%;
    width: 58px;
    animation-delay: 2.4s;
}
@keyframes float {
    0%,
    100% {
        transform: translateY(0) rotate(0);
    }
    50% {
        transform: translateY(-14px) rotate(6deg);
    }
}

/* Hero entrance — plays once on page load, staggered */
@keyframes heroIn {
    from {
        opacity: 0;
        transform: translateY(28px);
    }
    to {
        opacity: 1;
        transform: none;
    }
}
.hero__title,
.hero__lead,
.hero__actions,
.stats,
.hero__media {
    animation: heroIn 0.8s cubic-bezier(0.22, 0.61, 0.36, 1) both;
}
.hero__title {
    animation-delay: 0.05s;
}
.hero__media {
    animation-delay: 0.12s;
}
.hero__lead {
    animation-delay: 0.2s;
}
.hero__actions {
    animation-delay: 0.32s;
}
.stats {
    animation-delay: 0.44s;
}

/* ============================================================
   PROCESS
   ============================================================ */
.process {
    padding-block: clamp(64px, 8vw, 64px);
}
.process__head {
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: center;
    gap: clamp(24px, 4vw, 64px);
    margin-bottom: clamp(10px, 1.3vw, 18px);
}
.process__intro {
    display: grid;
    gap: 18px;
    align-content: start;
}
.process__intro .section-title {
    margin-top: 6px;
}
.process__figure img,
.process__figure video {
    display: block;
    width: 100%;
    border-radius: var(--radius);
    aspect-ratio: 16 / 9;
    object-fit: cover;
}
.steps {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: clamp(20px, 3vw, 40px);
}
.step {
    position: relative;
    padding-top: 18px;
}
.step__num {
    display: block;
    font-size: clamp(3rem, 5vw, 4.25rem);
    font-weight: 700;
    line-height: 1;
    color: rgba(6, 29, 19, 0.08);
    letter-spacing: -0.04em;
    margin-bottom: -40px;
}
.step__title {
    font-size: clamp(1.5rem, 2vw, 1.75rem);
    font-weight: 600;
    margin-bottom: 10px;
}
.step__text {
    font-size: 1rem;
    color: var(--muted);
}

/* ============================================================
   CAPABILITIES
   ============================================================ */
.capabilities {
    padding-block: clamp(30px, 7vw, 30px);
}
.capabilities__inner {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: clamp(32px, 5vw, 80px);
    align-items: start;
}
.capabilities__aside {
    position: sticky;
    top: calc(var(--nav-h) + 40px);
    display: grid;
    gap: 26px;
    align-content: start;
}
.capabilities__aside .section-title {
    max-width: 12ch;
}
.capabilities__aside .btn {
    justify-self: start;
}

/* Sticky stacked cards: each card sticks at the same top and the next
   opaque card slides up to cover it — a CSS-only "deck of cards" scroll. */
.capabilities__list {
    display: block;
}
.feature {
    position: sticky;
    top: calc(var(--nav-h) + 24px);
    background: var(--white);
    border-radius: var(--radius) var(--radius) 0 0;
    display: grid;
    gap: 18px;
    padding-bottom: 40px;
    border-bottom: 1px solid var(--line);
}
.feature:last-child {
    border-bottom: 0;
}
.feature + .feature {
    margin-top: 40px;
}
.feature__media img {
    width: 100%;
    border-radius: var(--radius);
    aspect-ratio: 16 / 10;
    object-fit: cover;
}
.feature__title {
    font-size: 1.5rem;
}
.feature__text {
    color: var(--muted);
    max-width: 48ch;
}

/* ============================================================
   PRODUCTS (carousel)
   ============================================================ */
.products {
    padding-block: clamp(56px, 7vw, 70px) 0;
    position: relative;
    z-index: 2; /* cards float above the benefits section below */
}
.products__carousel {
    position: relative;
}
.products__track {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: calc((100% - 2 * 32px) / 3);
    gap: 32px;
    overflow-x: auto;
    overflow-y: hidden; /* stop the implicit vertical scrollbar (overflow-x:auto forces y:auto) */
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
}
.products__track::-webkit-scrollbar {
    display: none;
}
/* white rounded card that floats over the dark benefits section below */
.product-card {
    scroll-snap-align: start;
    background: var(--white);
    border-radius: var(--radius);
    overflow: hidden; /* clip flush image to card corners */
    display: flex;
    flex-direction: column;
    position: relative;
    z-index: 1;
}
.product-card__media {
    overflow: hidden;
}
.product-card__media img {
    width: 100%;
    aspect-ratio: 16 / 10;
    object-fit: cover;
    transition: transform 0.6s cubic-bezier(0.22, 0.61, 0.36, 1);
}
.product-card:hover .product-card__media img {
    transform: scale(1.06);
}
.product-card__title {
    font-size: 1.5rem;
    padding: 24px 24px 0;
}
.product-card__text {
    font-size: 1rem;
    color: var(--muted);
    padding: 10px 24px 0;
}
.product-card__link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-weight: 600;
    color: var(--green-600);
    margin-top: auto;
    padding: 18px 24px 26px;
}
.product-card__link .link-circle {
    display: grid;
    place-items: center;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: var(--green-600);
    color: #fff;
    transition:
        transform 0.25s ease,
        background-color 0.2s ease;
}
.product-card__link:hover .link-circle {
    transform: translateX(4px);
    background: var(--green-900);
}

.carousel-arrow {
    position: absolute;
    top: clamp(90px, 12vw, 130px);
    z-index: 6;
    width: 44px;
    height: 44px;
    padding: 0;
    border: 0;
    background: none;
    cursor: pointer;
    transition: transform 0.15s ease;
    filter: drop-shadow(0 6px 16px rgba(6, 29, 19, 0.18));
}
.carousel-arrow img {
    width: 100%;
    height: 100%;
    display: block;
}
.carousel-arrow:hover {
    transform: scale(1.09);
}
.carousel-arrow--prev {
    left: max(12px, calc((100vw - var(--container)) / 2 - 24px));
}
.carousel-arrow--next {
    right: max(12px, calc((100vw - var(--container)) / 2 - 24px));
}

/* ============================================================
   BENEFITS (dark)
   ============================================================ */
.benefits {
    --overlap: clamp(
        180px,
        23vw,
        340px
    ); /* how far the product cards sit over the dark bg */
    background: var(--green-900);
    color: rgba(255, 255, 255, 0.8);
    padding-block: calc(clamp(64px, 8vw, 120px) + var(--overlap))
        clamp(64px, 8vw, 120px);
    border-radius: var(--radius) var(--radius) 0 0;
    position: relative;
    z-index: 1;
    margin-top: calc(var(--overlap) * -1); /* pull up behind the cards */
}
.benefits__top {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: clamp(32px, 5vw, 72px);
    align-items: center;
    margin-bottom: clamp(56px, 7vw, 96px);
}
.benefits__figure img {
    width: 100%;
    border-radius: var(--radius);
    filter: drop-shadow(0 30px 60px rgba(0, 0, 0, 0.4));
}
.benefits__content {
    display: grid;
    gap: 22px;
    align-content: start;
}
.benefits__content .section-title {
    margin-top: 4px;
}
.benefits__content .btn {
    justify-self: start;
}

.metrics {
    display: grid;
    grid-template-columns: repeat(3, auto);
    gap: clamp(24px, 4vw, 56px);
    margin-top: 12px;
    justify-content: start;
}
.metric__value {
    font-size: clamp(2.25rem, 3vw, 2.75rem);
    font-weight: 600;
    color: #fff;
    line-height: 1;
}
.metric__label {
    font-size: 0.95rem;
    color: rgba(255, 255, 255, 0.6);
    margin-top: 8px;
}

.certs {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: clamp(28px, 4vw, 56px);
}
.cert {
    display: grid;
    gap: 14px;
    align-content: start;
}
.cert__badge {
    width: 72px;
    height: 72px;
    object-fit: contain;
}
.cert__title {
    font-size: 1.375rem;
    color: #fff;
}
.cert__text {
    font-size: 1rem;
    color: rgba(255, 255, 255, 0.62);
}

/* ============================================================
   PROJECTS
   ============================================================ */
.projects {
    padding-block: clamp(64px, 8vw, 120px);
}
.project--featured {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: clamp(24px, 3vw, 48px);
    align-items: center;
    background: var(--green-300);
    border-radius: var(--radius);
    padding: clamp(20px, 2.2vw, 32px);
    margin-bottom: 32px;
}
.project--featured .project__media img {
    width: 100%;
    border-radius: 12px;
    aspect-ratio: 4 / 3;
    object-fit: cover;
}
.project__body {
    display: grid;
    gap: 16px;
    align-content: center;
    padding-right: clamp(0px, 2vw, 32px);
}
.project__brand {
    height: 44px;
    width: auto;
    object-fit: contain;
    object-position: left;
}
.project--featured .project__desc {
    font-size: clamp(1.5rem, 2.2vw, 2rem);
    font-weight: 600;
    color: var(--green-900);
    line-height: 1.35;
}
.project__meta {
    display: flex;
    gap: 12px;
    font-size: 0.95rem;
    color: var(--green-800);
    opacity: 0.75;
}
.project__meta span {
    opacity: 0.8;
}
.project__stat {
    margin-top: 6px;
}
.project__stat-value {
    display: block;
    font-size: clamp(2rem, 3vw, 2.75rem);
    font-weight: 600;
    color: var(--green-900);
    line-height: 1;
}
.project__stat-label {
    font-size: 0.95rem;
    color: var(--green-800);
    opacity: 0.75;
}

.projects__grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
}
.projects__grid .project {
    background: var(--surface);
    border-radius: var(--radius);
    padding: clamp(24px, 2.4vw, 36px);
    display: grid;
    gap: 14px;
    align-content: start;
}
.projects__grid .project__desc {
    font-size: clamp(1.125rem, 1.5vw, 1.5rem);
    font-weight: 600;
    color: var(--ink);
    line-height: 1.35;
}
.projects__grid .project__meta {
    color: var(--muted);
}
.projects__more {
    display: block;
    width: fit-content;
    margin: clamp(28px, 3.5vw, 44px) auto 0;
    font-weight: 600;
    color: var(--ink);
    transition: color 0.2s ease;
}
.projects__more:hover {
    color: var(--green-600);
}

/* ============================================================
   NEWS (dark)
   ============================================================ */
.news {
    background: var(--green-900);
    color: #fff;
    padding-block: clamp(64px, 8vw, 110px);
}
.news .link-more {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-weight: 600;
    color: #fff;
}
.news .link-more:hover {
    color: var(--green-300);
}
.news__grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 28px;
    align-items: start;
}
.post {
    border-radius: var(--radius);
    overflow: hidden;
}
.post__media {
    display: block;
    overflow: hidden;
    border-radius: var(--radius);
}
.post__img {
    width: 100%;
    aspect-ratio: 1.86; /* ~630×339 — card thường (16/9-ish) */
    object-fit: cover;
    border-radius: var(--radius);
    transition: transform 0.6s cubic-bezier(0.22, 0.61, 0.36, 1);
}
.post:hover .post__img {
    transform: scale(1.06);
}
.post__body {
    padding-top: 22px;
    display: grid;
    gap: 12px;
}
.post__meta {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.95rem;
    color: rgba(255, 255, 255, 0.62);
}
.post__meta .dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--green-300);
}
.post__title {
    font-size: clamp(1.35rem, 1.8vw, 1.75rem);
    color: #fff;
    max-width: 22ch;
}
.post__title a {
    color: inherit;
    transition: color 0.2s ease;
}
.post__title a:hover {
    color: var(--green-300);
}

/* Featured overlay variant */
.post--overlay {
    position: relative;
}
.post--overlay .post__img {
    aspect-ratio: 1.3; /* ~630×486 — card overlay (4/3-ish, cao hơn) */
}
.post--overlay .post__body {
    position: absolute;
    inset: auto 0 0 0;
    padding: 28px;
    background: linear-gradient(
        to top,
        rgba(6, 29, 19, 0.92) 8%,
        rgba(6, 29, 19, 0) 78%
    );
}

/* ============================================================
   CONTACT
   ============================================================ */
.contact {
    position: relative;
    background: var(--white);
    padding-block: 0 clamp(30px, 7vw, 30px);
}
/* dark band at the top continues the News section; the white panel rises over it */
.contact::before {
    content: "";
    position: absolute;
    inset: 0 0 auto 0;
    height: clamp(170px, 22vw, 290px);
    background: var(--green-900);
    z-index: 0;
}
.contact > .container {
    position: relative;
    z-index: 1;
    padding-top: clamp(36px, 4.5vw, 52px);
}
.contact__panel {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: clamp(28px, 4vw, 64px);
    align-items: start;
    background: var(--white);
    border-radius: 30px;
    padding: clamp(24px, 3.2vw, 48px);
}
.contact__info {
    display: grid;
    gap: 18px;
    align-content: start;
}
.contact-list {
    display: grid;
    gap: 4px;
    margin-top: 22px;
}
.contact-item {
    padding: 22px 0;
    border-bottom: 1px solid var(--line);
}
.contact-item:first-child {
    padding-top: 0;
}
.contact-item__label {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--ink);
}
.contact-item__label .icon {
    color: var(--green-600);
}
.contact-item__value {
    color: var(--muted);
    margin-top: 8px;
    padding-left: 30px;
}
.contact-item__value a:hover {
    color: var(--green-600);
}

.contact-form {
    background: var(--green-900);
    border-radius: var(--radius);
    padding: clamp(24px, 3vw, 40px);
    display: grid;
    gap: 18px;
}
.field {
    display: grid;
    gap: 8px;
}
.field label {
    color: #fff;
    font-weight: 600;
    font-size: 1.0625rem;
}
.field input,
.field textarea {
    background: var(--green-700);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 10px;
    padding: 14px 16px;
    color: #fff;
    transition:
        border-color 0.2s ease,
        background-color 0.2s ease;
}
.field input::placeholder,
.field textarea::placeholder {
    color: rgba(255, 255, 255, 0.4);
}
.field input:focus,
.field textarea:focus {
    outline: none;
    border-color: var(--green-300);
    background: #21402f;
}
.field textarea {
    resize: vertical;
    min-height: 120px;
}
.contact-form__status {
    color: var(--green-300);
    font-size: 0.95rem;
    min-height: 1.2em;
    text-align: center;
}

/* ============================================================
   FOOTER
   ============================================================ */
.site-footer {
    padding-block: clamp(15px, 6vw, 88px) 28px;
    border-top: 1px solid var(--line);
}
.site-footer__inner {
    display: grid;
    grid-template-columns: 1.7fr 1fr 1fr;
    column-gap: clamp(28px, 4vw, 64px);
    row-gap: clamp(36px, 4.5vw, 60px);
}
/* Let every footer grid track shrink below its content's min-content so no
   column (esp. the newsletter form) can push the grid past the viewport. */
.site-footer__inner > * {
    min-width: 0;
}
.site-footer__brand {
    grid-row: span 2; /* brand fills the left, links + newsletter stack on the right */
}
.site-footer__newsletter {
    grid-column: 2 / -1; /* newsletter sits under both link columns */
    max-width: 460px;
}
.site-footer__logo {
    height: 34px;
    width: auto;
    margin-bottom: 22px;
}
.site-footer__about {
    color: var(--muted);
    max-width: 34ch;
}
.site-footer__office {
    margin-top: 22px;
}
.site-footer__office-label {
    font-weight: 600;
    color: var(--ink);
    margin-bottom: 4px;
}
.site-footer__office p:last-child {
    color: var(--muted);
    max-width: 30ch;
}
.site-footer__contact {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 14px;
    color: var(--ink);
    font-weight: 500;
}
.site-footer__contact .icon {
    color: var(--green-600);
}
.site-footer__contact a {
    transition: color 0.2s ease;
}
.site-footer__contact a:hover {
    color: var(--green-600);
}

.site-footer__heading {
    font-size: 1.25rem;
    margin-bottom: 22px;
}
.site-footer__col ul {
    display: grid;
    gap: 14px;
}
.site-footer__col a {
    display: inline-block;
    color: var(--ink);
    font-size: 1rem;
    font-weight: 500;
    transition:
        color 0.2s ease,
        transform 0.2s ease;
}
.site-footer__col a:hover {
    color: var(--green-600);
    transform: translateX(5px);
}

.newsletter {
    display: flex;
    gap: 8px;
    background: var(--surface);
    border-radius: 10px;
    padding: 6px;
}
.newsletter input {
    flex: 1;
    min-width: 0; /* allow the email input to shrink; without this its intrinsic
                     min-width forces the footer grid track wider than mobile viewport */
    background: none;
    border: 0;
    padding: 10px 12px;
}
.newsletter input:focus {
    outline: none;
}
.newsletter button {
    border: 0;
    border-radius: var(--radius-sm);
    padding: 10px 20px;
    background: var(--green-900);
    color: #fff;
    font-weight: 600;
    cursor: pointer;
    transition:
        background-color 0.2s ease,
        transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.newsletter button:hover {
    background: var(--green-600);
    transform: scale(1.05);
}

.site-footer__bottom {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: clamp(40px, 5vw, 64px);
    padding-top: 26px;
    border-top: 1px solid var(--line);
    color: var(--muted);
    font-size: 0.95rem;
}
.site-footer__legal {
    display: flex;
    gap: 28px;
}
.site-footer__legal a:hover {
    color: var(--green-600);
}

/* ============================================================
   SCROLL REVEAL
   ============================================================ */
.reveal {
    opacity: 0;
    transform: translateY(24px);
    transition:
        opacity 0.7s ease,
        transform 0.7s ease;
}
.reveal.is-visible {
    opacity: 1;
    transform: none;
}
@media (prefers-reduced-motion: reduce) {
    .reveal {
        opacity: 1;
        transform: none;
        transition: none;
    }
    .hero__leaf,
    .hero__title,
    .hero__lead,
    .hero__actions,
    .stats,
    .hero__media {
        animation: none;
    }
    html {
        scroll-behavior: auto;
    }
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 1024px) {
    .hero__inner {
        min-height: 0;
    }
    .steps {
        grid-template-columns: repeat(2, 1fr);
        row-gap: 40px;
    }
    .certs {
        grid-template-columns: 1fr;
        gap: 32px;
    }
    .products__track {
        grid-auto-columns: calc((100% - 32px) / 2);
    }
    .carousel-arrow--prev {
        left: 8px;
    }
    .carousel-arrow--next {
        right: 8px;
    }
    .site-footer__inner {
        grid-template-columns: 1fr 1fr;
    }
    .site-footer__brand {
        grid-column: 1 / -1;
        grid-row: auto;
    }
    .site-footer__newsletter {
        grid-column: 1 / -1;
    }
}

@media (max-width: 860px) {
    .nav,
    .site-header__cta {
        display: none;
    }
    .nav-toggle {
        display: inline-flex;
        margin-left: auto; /* push toggle to the right (nav's auto-margin is gone when hidden) */
    }

    /* Mobile nav panel */
    .nav.is-open {
        display: block;
        position: fixed;
        inset: var(--nav-h) 0 auto 0;
        margin: 0;
        background: #fff;
        border-bottom: 1px solid var(--line);
        box-shadow: var(--shadow-md);
        padding: 12px var(--gutter) 24px;
    }
    .nav.is-open .nav__list {
        flex-direction: column;
        gap: 4px;
    }
    .nav.is-open .nav__list a {
        display: block;
        padding: 12px 0;
        border-bottom: 1px solid var(--line);
        font-size: 1.125rem;
    }

    .hero__inner,
    .process__head,
    .capabilities__inner,
    .benefits__top,
    .project--featured,
    .contact__panel {
        grid-template-columns: 1fr;
    }

    .hero {
        background-attachment: scroll, scroll, scroll;
    } /* fixed bg is janky on iOS */
    .hero__content {
        order: 1;
    }
    .hero__media {
        order: 2;
        min-height: 420px;
    }
    .benefits {
        --overlap: 70px;
    } /* gentler card overlap on small screens */
    .capabilities__aside {
        position: static;
    }
    /* keep the sticky stacked-cards effect on mobile too (matches design) */
    .feature {
        top: calc(var(--nav-h) + 12px);
    }
    .benefits__figure {
        order: 2;
    }
    .metrics {
        grid-template-columns: repeat(3, auto);
    }
    .projects__grid,
    .news__grid {
        grid-template-columns: 1fr;
    }
    .products__track {
        grid-auto-columns: 78%;
    }
    .post--overlay .post__img {
        aspect-ratio: 16 / 11;
    }
}

@media (max-width: 560px) {
    .step__num {
        font-size: clamp(5rem, 5vw, 4.25rem);
        color: #061d131c;
    }
    .stats {
        grid-template-columns: 1fr 1fr;
        column-gap: 16px;
        row-gap: 34px;
    }
    .stat {
        text-align: center;
    }
    .stat__icon {
        margin-inline: auto;
    }
    .steps {
        grid-template-columns: 1fr;
    }
    .metrics {
        grid-template-columns: 1fr 1fr;
    }
    .section-head--split {
        grid-template-columns: 1fr;
        align-items: start;
    }
    .site-footer__inner {
        grid-template-columns: 1fr;
    }
    .site-footer__bottom {
        flex-direction: column;
        align-items: flex-start;
    }
    .btn {
        width: 100%;
        justify-content: center;
    }
    .hero__actions {
        flex-direction: column;
    }
}

/* ============================================================
   MOBILE OVERFLOW GUARDS
   ------------------------------------------------------------
   Grid & flex items default to min-width:auto, which refuses to
   shrink below their content's intrinsic size. On narrow screens
   that pushes a track wider than the viewport → a sideways shift.
   Let the known offenders shrink so content REFLOWS to fit, cap
   form controls to their box, then clip any residual so no page
   can ever scroll horizontally (safe for sticky header + the
   nested products carousel, both verified).
   ============================================================ */
input,
textarea,
select {
    max-width: 100%;
}
.contact__panel > * {
    min-width: 0;
}
.contact-form input,
.contact-form textarea,
.contact-form select {
    min-width: 0;
}
html {
    overflow-x: clip;
}
