/* ==========================================================================
   Helix Engineering: site styles
   Layout and interaction patterns modelled on barr.com; brand colours from
   the Helix PDF (olive #788A35, orange #F4A019, mint #F0F7EF).
   ========================================================================== */

@font-face { font-family: "Inter"; src: url("../fonts/inter-var.woff2") format("woff2"); font-weight: 400 700; font-display: swap; }
@font-face { font-family: "Barlow Condensed"; src: url("../fonts/barlow-condensed-600.woff2") format("woff2"); font-weight: 600; font-display: swap; }
@font-face { font-family: "Barlow Condensed"; src: url("../fonts/barlow-condensed-700.woff2") format("woff2"); font-weight: 700; font-display: swap; }

:root {
  --black: #000;
  --ink: #1C3417;        /* headings: deep tea green */
  --text: #37452F;       /* body copy */
  --muted: #56624F;      /* secondary copy (AA on mint) */
  --green: #5D7026;      /* links, small green text (AA on white) */
  --olive: #788A35;      /* brand olive: rules, large text */
  --lime: #A6C24B;       /* green on black */
  --orange: #F4A019;     /* brand orange */
  --orange-num: #D47F00; /* counter numerals */
  --mint: #EEF5E9;
  --mint-2: #DCE9D1;
  --stripe: #C5DBB1;
  --line: #D7E2CF;
  --wrap: 1280px;
  --gutter: clamp(20px, 4vw, 48px);
  --header-h: 84px;
  --ease: cubic-bezier(.2, .7, .1, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body { margin: 0; font-family: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; font-size: 17px; line-height: 1.6; color: var(--text); background: #fff; -webkit-font-smoothing: antialiased; overflow-x: clip; }
img, video { max-width: 100%; display: block; }
a { color: inherit; }
button { font: inherit; }
:focus-visible { outline: 3px solid var(--orange); outline-offset: 3px; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.skip { position: absolute; left: 12px; top: -60px; z-index: 100; background: #fff; color: var(--ink); padding: 10px 14px; font-weight: 600; }
.skip:focus { top: 12px; }

.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gutter); }
.section { padding: clamp(72px, 9vw, 120px) 0; }
section[id] { scroll-margin-top: 20px; }

/* Shared stripe texture (Barr's diagonal hatch) */
.hatch { background: repeating-linear-gradient(-45deg, var(--stripe) 0 2px, transparent 2px 12px); }

/* ---------- Type ---------- */
.eyebrow { display: flex; align-items: center; gap: 10px; margin: 0 0 10px; font-size: 16px; font-weight: 600; color: var(--green); }
.eyebrow::before { content: ""; width: 15px; height: 11px; flex: none; background: linear-gradient(var(--olive) 0 4px, transparent 4px 7px, var(--olive) 7px 11px); }
.h2 { margin: 0; font-size: clamp(30px, 3.3vw, 44px); line-height: 1.15; font-weight: 650; letter-spacing: -.015em; color: var(--ink); text-wrap: balance; }
.lede { margin: 0; max-width: 36em; }
.display { font-family: "Barlow Condensed", "Arial Narrow", sans-serif; font-weight: 700; text-transform: uppercase; letter-spacing: .01em; line-height: .92; }

/* ---------- Buttons & links ---------- */
.btn { display: inline-flex; align-items: center; gap: 8px; padding: 9px 16px; border: 1.5px solid var(--green); border-radius: 2px; background: transparent; color: var(--green); font-size: 16px; font-weight: 500; line-height: 1.3; text-decoration: none; cursor: pointer; transition: background-color .2s, color .2s, border-color .2s; }
.btn:hover { background: var(--green); color: #fff; }
.btn--light { border-color: #fff; color: #fff; }
.btn--light:hover { background: #fff; color: #000; }
.btn--solid { background: var(--green); color: #fff; }
.btn--solid:hover { background: var(--ink); border-color: var(--ink); }
.btn svg { width: 18px; height: 18px; flex: none; }
.arrow-link { display: inline-flex; align-items: center; gap: 6px; font-weight: 600; font-size: 15px; color: var(--ink); text-decoration: none; }
.arrow-link svg { width: 14px; height: 14px; color: var(--orange); transition: transform .2s var(--ease); }
.arrow-link:hover svg { transform: translate(2px, -2px); }
.arrow-link:hover { color: var(--green); }

/* ---------- Header ---------- */
.site-header { position: fixed; inset: 0 0 auto; z-index: 70; height: var(--header-h); display: flex; align-items: center; transition: background-color .3s, transform .35s var(--ease); }
.site-header::before { content: ""; position: absolute; inset: 0 0 -30px; background: linear-gradient(180deg, rgba(0,0,0,.72) 0%, rgba(0,0,0,.45) 55%, rgba(0,0,0,0) 100%); pointer-events: none; transition: opacity .3s; }
.site-header.is-solid::before, .menu-open .site-header::before { opacity: 0; }
.site-header .wrap { position: relative; }
.site-header.is-solid, .menu-open .site-header { background: #000; }
.site-header.is-hidden { transform: translateY(-100%); }
.site-header .wrap { width: 100%; display: flex; align-items: center; justify-content: space-between; }
.brand { display: inline-flex; align-items: center; gap: clamp(10px, 1.4vw, 20px); text-decoration: none; }
.brand__mark { width: auto; height: clamp(30px, 3vw, 42px); }
.brand__rule { width: 1px; height: clamp(26px, 2.6vw, 38px); background: rgba(255,255,255,.45); }
.foot-logos { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 26px; }
.foot-logos img { width: auto; height: 44px; }
.icon-btn { width: 42px; height: 42px; display: grid; place-items: center; padding: 0; border: 1.5px solid #fff; border-radius: 2px; background: transparent; color: #fff; cursor: pointer; transition: background-color .2s, color .2s; }
.icon-btn:hover { background: #fff; color: #000; }
.icon-btn.menu-toggle { flex: none; display: none; }
@media (max-width: 1040px) { .icon-btn.menu-toggle { display: grid; } }
.menu-toggle .bars, .menu-toggle .bars::before, .menu-toggle .bars::after { display: block; width: 18px; height: 2px; background: currentColor; transition: transform .3s var(--ease), opacity .2s; }
.menu-toggle .bars { position: relative; }
.menu-toggle .bars::before, .menu-toggle .bars::after { content: ""; position: absolute; left: 0; }
.menu-toggle .bars::before { top: -6px; }
.menu-toggle .bars::after { top: 6px; }
.menu-open .menu-toggle .bars { background: transparent; }
.menu-open .menu-toggle .bars::before { transform: translateY(6px) rotate(45deg); }
.menu-open .menu-toggle .bars::after { transform: translateY(-6px) rotate(-45deg); }


/* ---------- Primary nav (desktop) ---------- */
.nav { margin-left: auto; }
.nav ul { list-style: none; display: flex; align-items: center; gap: clamp(16px, 2.2vw, 34px); margin: 0; padding: 0; }
.nav a { position: relative; display: block; padding: 6px 0; color: #fff; font-size: 16px; font-weight: 500; text-decoration: none; white-space: nowrap; }
.nav a::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 2px; background: currentColor; transform: scaleX(0); transform-origin: left; transition: transform .25s var(--ease); }
.nav a:hover::after, .nav a[aria-current="page"]::after { transform: scaleX(1); }
.nav a[aria-current="page"] { font-weight: 650; }
.menu__links a[aria-current="page"] { color: var(--lime); }

/* ---------- Page banner (inner pages) ---------- */
.pbanner { position: relative; display: flex; align-items: center; min-height: clamp(300px, 42vw, 430px); overflow: hidden; background: var(--ink); }
.pbanner img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.pbanner::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(17,68,11,.96) 0%, rgba(17,68,11,.78) 42%, rgba(17,68,11,.42) 100%); }
.pbanner .wrap { position: relative; z-index: 1; width: 100%; padding-top: var(--header-h); }
.pbanner h1 { margin: 0; font-size: clamp(40px, 5.6vw, 82px); color: #fff; }
.js .pbanner h1 { opacity: 0; transform: translateY(14px); transition: opacity .7s ease .1s, transform .7s var(--ease) .1s; }
.js .pbanner.is-in h1 { opacity: 1; transform: none; }
.pbanner + .section { padding-top: clamp(56px, 7vw, 96px); }

/* ---------- Menu overlay ---------- */
.menu { position: fixed; inset: 0; z-index: 60; background: #000; color: #fff; overflow-y: auto; visibility: hidden; opacity: 0; transition: opacity .35s, visibility .35s; }
.menu.is-open { visibility: visible; opacity: 1; }
.menu__inner { min-height: 100%; padding-top: calc(var(--header-h) + 48px); padding-bottom: 64px; display: grid; grid-template-columns: 1.3fr 1fr; gap: 48px; }
.menu__links { list-style: none; margin: 0; padding: 0; }
.menu__links a { display: inline-block; padding: 6px 0; font-size: clamp(28px, 3.6vw, 46px); font-weight: 600; letter-spacing: -.01em; text-decoration: none; transform: translateY(14px); opacity: 0; transition: color .2s, transform .5s var(--ease), opacity .5s; }
.menu.is-open .menu__links a { transform: none; opacity: 1; }
.menu.is-open .menu__links li:nth-child(2) a { transition-delay: .04s; }
.menu.is-open .menu__links li:nth-child(3) a { transition-delay: .08s; }
.menu.is-open .menu__links li:nth-child(4) a { transition-delay: .12s; }
.menu.is-open .menu__links li:nth-child(5) a { transition-delay: .16s; }
.menu.is-open .menu__links li:nth-child(6) a { transition-delay: .2s; }
.menu.is-open .menu__links li:nth-child(7) a { transition-delay: .24s; }
.menu__links a:hover { color: var(--lime); }
.menu__aside { font-size: 16px; color: rgba(255,255,255,.8); }
.menu__aside h2 { margin: 0 0 6px; font-size: 14px; font-weight: 600; color: var(--lime); }
.menu__aside p { margin: 0 0 28px; }
.menu__aside a { text-decoration: none; }
.menu__aside a:hover { color: #fff; text-decoration: underline; }

/* ---------- Hero ---------- */
.hero { position: relative; min-height: max(620px, 88vh); display: flex; align-items: center; overflow: hidden; background: #000; color: #fff; }
.hero__video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.hero::after { content: ""; position: absolute; inset: 0; z-index: 1; background:
  linear-gradient(90deg, rgba(0,0,0,.94) 0%, rgba(0,0,0,.82) 34%, rgba(0,0,0,.35) 66%, rgba(0,0,0,.18) 100%),
  linear-gradient(0deg, rgba(0,0,0,.55) 0%, rgba(0,0,0,0) 30%); }
.hero__chevrons { position: absolute; left: 0; bottom: 0; z-index: 2; width: min(52vw, 700px); height: auto; pointer-events: none; }
.hero.is-in .hero__chevrons { animation: slideIn 1.2s var(--ease) .35s both; }
.hero__content { position: relative; z-index: 2; width: 100%; padding-top: var(--header-h); padding-bottom: 56px; }
.hero h1 { margin: 0; font-size: clamp(52px, 7.4vw, 116px); }
.hero h1 .line { display: block; overflow: hidden; padding-bottom: .04em; }
.hero h1 .line > span { display: block; }
.hero.is-in h1 .line > span { animation: rise 1s var(--ease) both; }
.hero.is-in h1 .line:nth-child(2) > span { animation-delay: .12s; }
.hero h1 .accent { color: var(--lime); }
.hero__pause { position: absolute; right: var(--gutter); bottom: 28px; z-index: 2; width: 36px; height: 36px; display: grid; place-items: center; padding: 0; border: 0; background: transparent; color: #fff; cursor: pointer; opacity: .85; }
.hero__pause:hover { opacity: 1; }
.hero__pause .i-play { display: none; }
.hero__pause.is-paused .i-play { display: block; }
.hero__pause.is-paused .i-pause { display: none; }

.js .hero:not(.is-in) h1 .line > span { transform: translateY(105%); }
.js .hero:not(.is-in) .hero__chevrons { opacity: 0; }
@keyframes rise { from { transform: translateY(105%); } to { transform: none; } }
@keyframes fadeUp { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
@keyframes slideIn { from { opacity: 0; transform: translateX(-60px); } to { opacity: 1; transform: none; } }

/* ---------- About + counters ---------- */
.about { position: relative; overflow: hidden; }
.about__grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); gap: clamp(40px, 6vw, 88px); align-items: center; }
.about__copy .lede { margin-top: 20px; }
.about__btns { display: flex; flex-direction: column; align-items: flex-start; gap: 12px; margin-top: 28px; }
.stats { position: relative; isolation: isolate; display: grid; grid-template-columns: 1fr 1fr; gap: 44px 40px; padding: 48px 0; }
.stats::before, .stats::after { content: ""; position: absolute; z-index: -1; background: repeating-linear-gradient(-45deg, var(--stripe) 0 2px, transparent 2px 13px); }
.stats::before { top: -70px; bottom: -70px; left: 8%; width: 58%; clip-path: polygon(0 0, 42% 0, 100% 50%, 42% 100%, 0 100%, 58% 50%); }
.stats::after { top: -70px; bottom: -70px; left: 52%; width: 70%; clip-path: polygon(0 0, 42% 0, 100% 50%, 42% 100%, 0 100%, 58% 50%); opacity: .75; }
.stat { padding: 4px 0; }
.stat__num { margin: 0; font-size: clamp(56px, 6vw, 86px); font-weight: 500; line-height: 1; letter-spacing: -.025em; color: var(--orange-num); font-variant-numeric: tabular-nums; }
.stat__label { margin: 10px 0 0; font-size: 20px; font-weight: 600; line-height: 1.3; color: var(--ink); }
.stat__desc { margin: 4px 0 0; max-width: 21em; font-size: 14.5px; line-height: 1.5; color: var(--muted); }

/* ---------- Expertise cards ---------- */
.cards { display: grid; gap: 22px; margin-top: 36px; }
.cards--grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.card { display: flex; flex-direction: column; background: var(--mint); }
.card__media { overflow: hidden; aspect-ratio: 16 / 9; }
.card__media img { width: 100%; height: 100%; object-fit: cover; transition: transform .8s var(--ease); }
.card:hover .card__media img { transform: scale(1.04); }
.card__body { display: flex; flex-direction: column; gap: 10px; padding: 24px clamp(20px, 2.2vw, 30px) 28px; }
.card h3 { margin: 0; font-size: clamp(20px, 1.9vw, 25px); line-height: 1.28; font-weight: 600; color: var(--ink); }
.card p { margin: 0; font-size: 15.5px; line-height: 1.55; }

/* ---------- Split (text + video) ---------- */
.split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr); gap: clamp(40px, 6vw, 88px); align-items: center; }
.split .lede { margin: 20px 0 28px; }
.media { position: relative; isolation: isolate; }
.media::before { content: ""; position: absolute; z-index: -1; inset: -34px -34px -34px 22%; background: repeating-linear-gradient(-45deg, var(--stripe) 0 2px, transparent 2px 12px); clip-path: polygon(0 0, 100% 0, 100% 36%, 76% 36%, 76% 64%, 100% 64%, 100% 100%, 0 100%); }
.media__frame { position: relative; aspect-ratio: 16 / 9; overflow: hidden; background: #000; box-shadow: 0 20px 40px rgba(28, 52, 23, .18); }
.media__frame--img { background: #fff; }
.media__frame--img img { width: 100%; height: 100%; object-fit: cover; }
.media { margin: 0; }
.media__frame video { width: 100%; height: 100%; object-fit: cover; }
.media__toggle { position: absolute; right: 12px; bottom: 12px; z-index: 2; width: 38px; height: 38px; display: grid; place-items: center; padding: 0; border: 0; border-radius: 2px; background: rgba(0,0,0,.55); color: #fff; cursor: pointer; transition: background-color .2s; }
.media__toggle:hover { background: #000; }
.media__toggle .i-play { display: none; }
.media__toggle.is-paused .i-play { display: block; }
.media__toggle.is-paused .i-pause { display: none; }
.media__cap { margin: 14px 0 0; font-size: 14px; color: var(--muted); }

/* ---------- Clients ---------- */
.clients__panel { margin-top: 36px; padding: clamp(18px, 3vw, 32px); background: var(--mint); }
.clients__grid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 14px; }
.logo-tile { position: relative; aspect-ratio: 3 / 2; background: #fff; }
.logo-tile img { position: absolute; inset: 12%; width: 76%; height: 76%; object-fit: contain; }

/* ---------- Milestones timeline (chevron format) ---------- */
.ms { display: grid; gap: 40px; margin-top: 48px; }
.ms__row { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); grid-template-rows: auto 40px auto; }
.ms__row--rev { direction: rtl; }
.ms__item { position: relative; display: grid; grid-row: 1 / span 3; grid-template-rows: subgrid; direction: ltr; --c: #11440B; --t: #11440B; }
.ms--o { --c: var(--orange); --t: var(--orange-num); }
.ms__cell { position: relative; padding: 0 12px; }
.ms__item--down .ms__cell--year, .ms__item--up .ms__cell--card { align-self: end; }
.ms__item--down .ms__cell--card, .ms__item--up .ms__cell--year { align-self: start; }
.ms__arrow { position: relative; z-index: 1; margin-right: -13px; background: var(--c); clip-path: polygon(0 0, calc(100% - 18px) 0, 100% 50%, calc(100% - 18px) 100%, 0 100%, 18px 50%); transform-origin: left center; }
.ms__row--rev .ms__arrow { margin-right: 0; margin-left: -13px; clip-path: polygon(18px 0, 100% 0, calc(100% - 18px) 50%, 100% 100%, 18px 100%, 0 50%); transform-origin: right center; }
.ms__year { margin: 14px 0; font-size: clamp(24px, 2.3vw, 34px); font-weight: 700; line-height: 1; letter-spacing: -.01em; text-align: center; color: var(--t); }
.ms__card h3 { margin: 0 0 7px; font-size: 16px; line-height: 1.28; font-weight: 650; color: var(--t); }
.ms__card p { margin: 0; font-size: 14px; line-height: 1.45; color: var(--muted); }
.ms__item--up .ms__card { padding-bottom: 12px; margin-bottom: 30px; border-bottom: 3px solid var(--c); }
.ms__item--down .ms__card { padding-top: 12px; margin-top: 30px; border-top: 3px solid var(--c); }
.ms__item--up .ms__cell--card::after, .ms__item--down .ms__cell--card::before { content: ""; position: absolute; left: 50%; width: 2px; height: 30px; margin-left: -1px; background: var(--c); }
.ms__item--up .ms__cell--card::after { bottom: 0; }
.ms__item--down .ms__cell--card::before { top: 0; }
.ms__card--badge { padding: 10px 12px !important; border: 3px solid var(--orange) !important; border-radius: 6px; background: #fff; }
.ms__card--badge img { width: 100%; max-width: 150px; height: auto; margin: 5px 0 2px; }
.ms__est { margin: 0 !important; font-size: 13px !important; font-weight: 700; font-style: italic; color: var(--green) !important; }
/* Draw-in: replays every time a row (desktop) or item (mobile) re-enters the viewport; .is-in is toggled in main.js */
.js .ms__arrow { transform: scaleX(0); transition: transform .45s var(--ease) calc(var(--i) * 75ms); }
.js .ms__cell { opacity: 0; transform: translateY(10px); transition: opacity .45s ease calc(var(--i) * 75ms + 160ms), transform .45s var(--ease) calc(var(--i) * 75ms + 160ms); }
.js .is-in .ms__arrow { transform: none; }
.js .is-in .ms__cell { opacity: 1; transform: none; }

/* ---------- Machinery ---------- */
.mach-head { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(32px, 6vw, 88px); align-items: start; }
.mach-head--stack { display: block; }
.mach-head--stack .lede { max-width: 70ch; margin: 20px 0 26px; }
.mach-head--stack .services { columns: 3; column-gap: 34px; }
.mach-head .lede { margin-bottom: 14px; }
.services { list-style: none; margin: 0; padding: 0; columns: 2; column-gap: 32px; }
.services li { position: relative; break-inside: avoid; padding: 8px 0 8px 20px; border-bottom: 1px solid var(--line); font-size: 15.5px; line-height: 1.4; color: var(--ink); }
.services li::before { content: ""; position: absolute; left: 1px; top: 15px; width: 7px; height: 7px; border-top: 2px solid var(--olive); border-right: 2px solid var(--olive); transform: rotate(45deg); }
.mach-lead { margin: 48px 0 0; font-size: 17px; color: var(--ink); }
.mpanel { display: grid; grid-template-columns: 200px minmax(0, 1fr) minmax(0, .88fr); margin-top: 20px; min-height: 580px; background: var(--mint); }
.mtabs { display: flex; flex-direction: column; align-self: start; padding: 48px 0 48px 28px; }
.mtab { position: relative; display: flex; align-items: baseline; justify-content: space-between; gap: 10px; padding: 9px 18px 9px 0; border: 0; border-right: 2px solid #C9DABB; background: none; color: var(--muted); font-size: 18px; text-align: left; cursor: pointer; transition: color .2s; }
.mtab:hover { color: var(--ink); }
.mtab[aria-selected="true"] { color: var(--green); font-weight: 600; }
.mtab[aria-selected="true"]::after { content: ""; position: absolute; top: 0; bottom: 0; right: -2.5px; width: 3px; background: var(--green); }
.mtab__n { font-size: 13px; font-weight: 500; color: var(--muted); }
.mlist { padding: 48px 36px; }
.mlist[hidden] { display: none; }
.mlist__title { margin: 0; font-size: clamp(24px, 2.2vw, 30px); line-height: 1.2; font-weight: 600; color: var(--ink); }
.mlist__hint { display: flex; align-items: center; gap: 8px; margin: 8px 0 24px; font-size: 14px; color: var(--muted); }
.mlist__hint::before { content: ""; width: 7px; height: 7px; flex: none; background: var(--orange); }
.mgroups { columns: 2; column-gap: 28px; }
.mgroup { margin: 0 0 20px; }
.mgroup h4 { break-after: avoid; }
.mgroup li { break-inside: avoid; }
.mgroup h3 { margin: 0 0 6px; font-size: 13px; font-weight: 600; color: var(--green); }
.mgroup ul { list-style: none; margin: 0; padding: 0; }
.mach { position: relative; display: block; width: 100%; padding: 5px 0 5px 15px; border: 0; background: none; color: var(--muted); font-size: 15px; line-height: 1.38; text-align: left; }
.mach.has-photo { color: var(--ink); font-weight: 500; cursor: pointer; transition: color .15s; }
.mach.has-photo::before { content: ""; position: absolute; left: 0; top: calc(5px + .52em); width: 7px; height: 7px; background: var(--orange); transition: transform .2s var(--ease), background-color .2s; }
.mach.has-photo:hover { color: var(--green); }
.mach.is-active { color: var(--green); font-weight: 650; }
.mach.is-active::before { background: var(--green); transform: scale(1.3); }
.mstage { position: relative; overflow: hidden; min-height: 440px; margin: 0; background: #fff; }
.mstage img { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; transform: scale(1.03); transition: opacity .5s ease, transform .8s var(--ease); }
.mstage img.is-on { opacity: 1; transform: none; }
.mstage img[data-fit="cutout"] { object-fit: contain; padding: 9% 8% 17%; }
.mstage img[data-fit="photo"] { object-fit: cover; }
.mstage__cap { position: absolute; left: 0; bottom: 0; z-index: 2; max-width: 92%; margin: 0; padding: 12px 18px; background: var(--ink); color: #fff; font-size: 15px; font-weight: 500; line-height: 1.35; }

/* ---------- Project gallery ---------- */
.gallery { list-style: none; margin: 32px 0 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); grid-auto-rows: clamp(150px, 15vw, 215px); gap: 12px; }
.gallery li { overflow: hidden; background: var(--mint); }
.gallery li.g--wide { grid-column: span 2; }
.gallery img { width: 100%; height: 100%; object-fit: cover; transition: transform .8s var(--ease); }
.gallery li:hover img { transform: scale(1.05); }

/* ---------- Mindset ---------- */
.mindset__grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(28px, 4vw, 56px); margin-top: 44px; }
.mindset__icon { width: 66px; height: 84px; margin-bottom: 18px; }
.mindset h3 { margin: 0 0 10px; font-size: 24px; line-height: 1.25; font-weight: 600; color: var(--ink); }
.mindset p { margin: 0; font-size: 16px; }

/* ---------- Recommendations ---------- */
.rec { position: relative; padding: clamp(28px, 4vw, 52px) clamp(20px, 4vw, 52px) clamp(36px, 4vw, 52px); background: var(--mint); border-bottom: 3px solid var(--olive); }
.rec .lede { margin-top: 14px; max-width: 52em; }
.rec__viewport { overflow: hidden; margin-top: 36px; touch-action: pan-y; }
.rec__track { display: flex; transition: transform .65s var(--ease); }
.rec__slide { flex: 0 0 100%; display: grid; grid-template-columns: auto minmax(0, 1fr); gap: clamp(28px, 4vw, 56px); align-items: center; padding: 0 clamp(36px, 5vw, 64px); }
.rec__doc { display: block; padding: 12px; border: 0; background: #fff; box-shadow: 0 14px 34px rgba(28, 52, 23, .14); cursor: zoom-in; transition: transform .3s var(--ease); }
.rec__doc:hover { transform: translateY(-3px); }
.rec__doc img { width: auto; height: min(500px, 62vh); aspect-ratio: 706 / 1000; object-fit: contain; }
.rec__mark { width: 40px; height: 40px; display: grid; place-items: center; border: 1.5px solid var(--green); color: var(--green); }
.rec__mark svg { width: 18px; height: 18px; }
.rec blockquote { margin: 18px 0 0; font-size: clamp(19px, 1.85vw, 25px); line-height: 1.42; font-weight: 600; color: var(--ink); }
.rec__who { margin: 22px 0 0; font-size: 16px; line-height: 1.5; }
.rec__who strong { color: var(--ink); }
.rec__who span { display: block; margin-top: 6px; font-size: 14px; font-weight: 600; color: var(--green); }
.rec__arrow { position: absolute; top: 50%; z-index: 2; width: 46px; height: 64px; display: grid; place-items: center; padding: 0; border: 0; background: var(--ink); color: #fff; cursor: pointer; transform: translateY(-50%); transition: background-color .2s; }
.rec__arrow:hover { background: var(--green); }
.rec__arrow--prev { left: 0; }
.rec__arrow--next { right: 0; }
.rec__arrow svg { width: 20px; height: 20px; }
.rec__dots { display: flex; justify-content: center; align-items: center; gap: 10px; margin-top: 22px; }
.rec__dots button { width: 10px; height: 10px; padding: 0; border: 0; border-radius: 50%; background: #C8D5BF; cursor: pointer; transition: all .25s; }
.rec__dots button[aria-current="true"] { width: 14px; height: 14px; background: var(--green); }

.lightbox { max-width: min(92vw, 860px); max-height: 94vh; padding: 0; border: 0; background: #fff; overflow: visible; }
.lightbox::backdrop { background: rgba(0, 0, 0, .82); }
.lightbox img { width: auto; height: auto; max-width: 100%; max-height: 90vh; margin: auto; }
.lightbox__close { position: absolute; top: 10px; right: 10px; background: #000; border-color: #000; }

/* ---------- Locations ---------- */
.loc-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; margin-top: 36px; }
.loc { display: flex; flex-direction: column; border: 1px solid var(--line); background: #fff; }
.loc__head { position: relative; height: 150px; display: flex; align-items: flex-end; padding: 20px 24px; overflow: hidden; background: var(--ink); color: #fff; }
.loc__head::before { content: ""; position: absolute; inset: 0 0 0 42%; background: repeating-linear-gradient(-45deg, rgba(166, 194, 75, .35) 0 2px, transparent 2px 12px); clip-path: polygon(30% 0, 100% 0, 100% 100%, 30% 100%, 62% 50%); }
.loc__head .display { position: relative; font-size: clamp(40px, 4.4vw, 58px); }
.loc__body { display: flex; flex-direction: column; gap: 16px; flex: 1; padding: 24px; }
.loc__body .chip { background: var(--mint); }
.loc h3 { margin: 0; font-size: 20px; line-height: 1.3; font-weight: 600; color: var(--ink); }
.loc address { font-style: normal; font-size: 15.5px; line-height: 1.55; }
.loc__lines { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; font-size: 15.5px; }
.loc__lines a { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ink); }
.loc__lines a:hover { color: var(--green); text-decoration: underline; }
.loc__lines svg { width: 17px; height: 17px; color: var(--olive); flex: none; }
.loc .arrow-link { margin-top: auto; }

/* ---------- CTA band ---------- */
.cta { position: relative; overflow: hidden; padding: clamp(64px, 8vw, 104px) 0; background: var(--mint); }
.cta::before, .cta::after { content: ""; position: absolute; background: repeating-linear-gradient(-45deg, var(--stripe) 0 2px, transparent 2px 13px); }
.cta::before { top: 0; bottom: 0; right: 16%; width: 38%; clip-path: polygon(0 0, 42% 0, 100% 50%, 42% 100%, 0 100%, 58% 50%); }
.cta::after { top: 12%; bottom: -10%; right: -8%; width: 34%; clip-path: polygon(0 0, 42% 0, 100% 50%, 42% 100%, 0 100%, 58% 50%); opacity: .7; }
.cta .wrap { position: relative; z-index: 1; }
.cta h2 { margin: 0 0 24px; font-size: clamp(48px, 6.6vw, 100px); color: var(--ink); }
.cta h2 .accent { display: block; color: var(--olive); }
.cta p { max-width: 30em; margin: 0 0 28px; }
.cta__btns { display: flex; flex-wrap: wrap; gap: 12px; }

/* ---------- Footer ---------- */
.site-footer { padding: 64px 0 28px; }
.foot-grid { display: grid; grid-template-columns: 1.25fr repeat(4, minmax(0, 1fr)); gap: 32px; }
.foot-brand p { max-width: 17em; margin: 18px 0 0; font-size: 14.5px; color: var(--muted); }
.foot-col h2 { margin: 0 0 12px; padding-bottom: 7px; border-bottom: 1.5px solid var(--olive); font-size: 15px; font-weight: 600; color: var(--green); }
.foot-col ul { list-style: none; margin: 0; padding: 0; }
.foot-col a { display: block; padding: 4px 0; font-size: 15.5px; line-height: 1.4; color: var(--ink); text-decoration: none; }
.foot-col a:hover { color: var(--green); text-decoration: underline; }
.foot-bottom { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; margin-top: 52px; padding-top: 20px; border-top: 1px solid var(--line); font-size: 13.5px; color: var(--muted); }

/* ---------- Responsive ---------- */
@media (max-width: 1040px) {
  .nav { display: none; }
}
@media (max-width: 1100px) {
  .mpanel { grid-template-columns: 180px minmax(0, 1fr); }
  .mstage { grid-column: 2; grid-row: 1; min-height: 360px; }
  .mlist { grid-column: 2; }
  .mtabs { grid-row: 1 / span 2; }
  .clients__grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .foot-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .foot-brand { grid-column: 1 / -1; }
  .ms__card h3 { font-size: 14px; }
  .ms__card p { font-size: 12.5px; }
  .ms__cell { padding: 0 8px; }
}
@media (max-width: 900px) {
  .about__grid, .split, .mach-head { grid-template-columns: 1fr; }
  .stats { padding: 24px 0; }
  .stats::before, .stats::after { top: 0; bottom: 0; }
  .media { margin-top: 12px; }
  .media::before { inset: -18px -12px -18px 30%; }
  .mpanel { grid-template-columns: 1fr; min-height: 0; }
  .mtabs { grid-row: auto; flex-direction: row; gap: 22px; overflow-x: auto; padding: 8px 20px 0; border-bottom: 2px solid #C9DABB; scrollbar-width: none; }
  .mtab { flex: none; padding: 12px 0; border-right: 0; white-space: nowrap; }
  .mtab[aria-selected="true"]::after { top: auto; bottom: -2px; left: 0; right: 0; width: auto; height: 3px; }
  .mtab__n { display: none; }
  .mstage, .mlist { grid-column: 1; grid-row: auto; }
  .mtabs { order: 0; }
  .mstage { order: 1; position: sticky; top: 0; z-index: 3; min-height: 0; height: min(40vh, 75vw); box-shadow: 0 6px 16px rgba(28,52,23,.12); }
  .mlist { order: 2; }
  .mstage__cap { font-size: 14px; padding: 9px 14px; }
  .mlist { padding: 28px 20px 32px; }
  .mach-head--stack .services { columns: 2; }
  .gallery { grid-template-columns: repeat(2, minmax(0, 1fr)); grid-auto-rows: 130px; grid-auto-flow: dense; }
  .gallery li.g--wide { grid-column: span 2; }
  .mindset__grid { grid-template-columns: 1fr; gap: 36px; }
  .rec__slide { grid-template-columns: 1fr; padding: 0 4px; }
  .rec__doc { justify-self: center; }
  .rec__doc img { height: min(420px, 55vh); }
  .rec__arrow { top: auto; bottom: 0; transform: none; height: 46px; }
  .rec { padding-bottom: 80px; }
  .loc-grid { grid-template-columns: 1fr; }
  .menu__inner { grid-template-columns: 1fr; }
  .ms { gap: 0; }
  .ms__row, .ms__row--rev { display: block; direction: ltr; }
  .ms__item { display: grid; grid-template-columns: 58px 26px minmax(0, 1fr); grid-template-rows: auto; column-gap: 14px; }
  .ms__cell--year { grid-column: 1; grid-row: 1; align-self: start !important; padding: 0; }
  .ms__arrow, .ms__row--rev .ms__arrow { grid-column: 2; grid-row: 1; margin: 0 0 -9px; min-height: 64px; clip-path: polygon(0 0, 50% 12px, 100% 0, 100% calc(100% - 12px), 50% 100%, 0 calc(100% - 12px)); transform-origin: top center; }
  .ms__cell--card { grid-column: 3; grid-row: 1; align-self: start !important; padding: 0 0 26px; }
  .ms__year { margin: 14px 0 0; font-size: 20px; text-align: right; }
  .ms__item--up .ms__card, .ms__item--down .ms__card { margin: 12px 0 0; padding: 0; border: 0; }
  .ms__item--up .ms__cell--card::after, .ms__item--down .ms__cell--card::before { display: none; }
  .js .ms__arrow { transform: scaleY(0); }
  .ms__item { --i: 0 !important; }
}
@media (max-width: 760px) {
  .cards--grid { grid-template-columns: 1fr; }
}
@media (max-width: 600px) {
  .brand { gap: 8px; }
  .brand__mark { height: 26px; }
  .foot-logos img { height: 34px; }
  body { font-size: 16px; }

  .hero { min-height: 92vh; align-items: flex-end; }
  .stats { grid-template-columns: 1fr 1fr; gap: 32px 20px; }
  .stat__label { font-size: 17px; }
  .services, .mgroups, .mach-head--stack .services { columns: 1; }
  .clients__grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
  .logo-tile { padding: 10px; }
  .foot-grid { grid-template-columns: 1fr 1fr; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; animation-delay: 0s !important; transition-duration: .01ms !important; transition-delay: 0s !important; }
}
