/* ==========================================================================
   Moses Construction and Trading PLC — site stylesheet
   Design tokens live in :root. Change brand colours / fonts here only.
   ========================================================================== */

:root {
  /* Brand — navy is sampled from the Moses "M" mark; laterite echoes the
     company-profile brown and the red earth of the Assosa sites. */
  --navy: #1a2342;
  --navy-2: #253058;
  --navy-ink: #10162b;
  --laterite: #a4512f;
  --laterite-dark: #83401f;
  --laterite-tint: #f3e6dd;

  /* Neutrals */
  --white: #ffffff;
  --paper: #fbfaf8;
  --stone: #f0ece5;
  --stone-2: #e3ddd2;
  --line: #d9d3c8;
  --line-dark: rgba(255, 255, 255, 0.16);
  --ink: #161c2e;
  --text: #2c3243;
  --muted: #5d6272;
  --on-dark: #e9e6e0;
  --on-dark-muted: #a9adbb;

  /* Type */
  --font-head: "Archivo", "Arial Narrow", Arial, sans-serif;
  --font-body: "IBM Plex Sans", "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --font-mono: "IBM Plex Mono", ui-monospace, Consolas, monospace;

  --fs-xs: 0.78rem;
  --fs-sm: 0.9rem;
  --fs-base: 1.0625rem;
  --fs-lead: clamp(1.15rem, 1rem + 0.5vw, 1.35rem);
  --fs-h4: 1.2rem;
  --fs-h3: clamp(1.35rem, 1.2rem + 0.6vw, 1.7rem);
  --fs-h2: clamp(1.9rem, 1.5rem + 1.8vw, 3rem);
  --fs-h1: clamp(2.4rem, 1.7rem + 3.4vw, 4.6rem);

  /* Space scale */
  --s-1: 0.25rem;
  --s-2: 0.5rem;
  --s-3: 0.75rem;
  --s-4: 1rem;
  --s-5: 1.5rem;
  --s-6: 2rem;
  --s-7: 3rem;
  --s-8: 4.5rem;
  --s-9: 6.5rem;
  --section: clamp(4rem, 3rem + 5vw, 8rem);

  --container: 1320px;
  --gutter: clamp(1rem, 0.5rem + 2.5vw, 2.5rem);
  --header-h: 76px;
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 1rem); }
body {
  margin: 0;
  font-family: var(--font-body);
  font-size: var(--fs-base);
  line-height: 1.65;
  color: var(--text);
  background: var(--white);
  overflow-x: hidden;
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
h1, h2, h3, h4 { font-family: var(--font-head); color: var(--ink); line-height: 1.08; margin: 0 0 var(--s-4); font-weight: 700; letter-spacing: -0.015em; }
h1 { font-size: var(--fs-h1); font-weight: 800; letter-spacing: -0.03em; }
h2 { font-size: var(--fs-h2); letter-spacing: -0.025em; }
h3 { font-size: var(--fs-h3); }
h4 { font-size: var(--fs-h4); }
p { margin: 0 0 var(--s-4); }
ul, ol { margin: 0; padding: 0; }
button, input, select, textarea { font: inherit; color: inherit; }
:focus-visible { outline: 3px solid var(--laterite); outline-offset: 3px; }
::selection { background: var(--laterite); color: #fff; }

.visually-hidden {
  position: absolute !important; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap; border: 0; padding: 0; margin: -1px;
}
.skip-link {
  position: absolute; left: var(--s-4); top: -100px; z-index: 200;
  background: var(--navy); color: #fff; padding: var(--s-3) var(--s-4); text-decoration: none;
}
.skip-link:focus { top: var(--s-4); }

/* ---------- Layout ---------- */
.container { width: 100%; max-width: var(--container); margin-inline: auto; padding-inline: var(--gutter); }
.section { padding-block: var(--section); }
.section--stone { background: var(--stone); }
.section--paper { background: var(--paper); }
.section--navy { background: var(--navy); color: var(--on-dark); }
.section--navy h2, .section--navy h3, .section--navy h4 { color: #fff; }
.section--tight { padding-block: clamp(3rem, 2rem + 3vw, 5rem); }

/* Sheet label: "01 / Services" — borrowed from drawing sheet numbering */
.eyebrow {
  display: inline-flex; align-items: center; gap: var(--s-3);
  font-family: var(--font-mono); font-size: var(--fs-xs); font-weight: 500;
  letter-spacing: 0.08em; text-transform: uppercase; color: var(--laterite-dark);
  margin-bottom: var(--s-5);
}
.eyebrow::before { content: ""; width: 28px; height: 1px; background: currentColor; }
.section--navy .eyebrow, .page-hero .eyebrow, .hero .eyebrow { color: #e3a07f; }
.eyebrow .num { color: var(--muted); }
.section--navy .eyebrow .num { color: var(--on-dark-muted); }

.lead { font-size: var(--fs-lead); line-height: 1.55; color: var(--ink); }
.section--navy .lead { color: var(--on-dark); }
.measure { max-width: 62ch; }
.muted { color: var(--muted); }

.section-head { display: grid; gap: var(--s-5); margin-bottom: var(--s-8); }
.section-head h2 { margin: 0; max-width: 18ch; }
.section-head p { margin: 0; max-width: 54ch; color: var(--muted); }
@media (min-width: 900px) {
  .section-head--split { grid-template-columns: 1.1fr 1fr; align-items: end; }
}

/* ---------- Buttons & links ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: var(--s-3);
  min-height: 50px; padding: 0.8rem 1.5rem;
  font-family: var(--font-head); font-weight: 600; font-size: 0.98rem; letter-spacing: 0.01em;
  text-decoration: none; border: 1.5px solid transparent; border-radius: 0; cursor: pointer;
  transition: background-color .2s var(--ease), color .2s var(--ease), border-color .2s var(--ease);
}
.btn svg { width: 18px; height: 18px; flex: none; transition: transform .2s var(--ease); }
.btn:hover svg { transform: translateX(3px); }
.btn--primary { background: var(--laterite); color: #fff; }
.btn--primary:hover { background: var(--laterite-dark); }
.btn--navy { background: var(--navy); color: #fff; }
.btn--navy:hover { background: var(--navy-ink); }
.btn--outline { border-color: var(--ink); color: var(--ink); background: transparent; }
.btn--outline:hover { background: var(--ink); color: #fff; }
.btn--ghost-light { border-color: rgba(255,255,255,.55); color: #fff; }
.btn--ghost-light:hover { background: #fff; color: var(--navy); border-color: #fff; }
.btn-row { display: flex; flex-wrap: wrap; gap: var(--s-3); }

.text-link {
  display: inline-flex; align-items: center; gap: var(--s-2);
  font-family: var(--font-head); font-weight: 600; color: var(--ink);
  text-decoration: none; border-bottom: 1.5px solid var(--laterite); padding-bottom: 2px;
}
.text-link svg { width: 16px; height: 16px; transition: transform .2s var(--ease); }
.text-link:hover { color: var(--laterite-dark); }
.text-link:hover svg { transform: translateX(3px); }
.section--navy .text-link { color: #fff; }

/* ---------- Header ---------- */
.topbar { background: var(--navy-ink); color: var(--on-dark-muted); font-size: var(--fs-xs); font-family: var(--font-mono); letter-spacing: .04em; }
.topbar .container { display: flex; justify-content: space-between; gap: var(--s-4); padding-block: 0.5rem; }
.topbar span:last-child { display: none; }
@media (min-width: 760px) { .topbar span:last-child { display: inline; } }

.site-header { position: sticky; top: 0; z-index: 100; background: var(--white); border-bottom: 1px solid var(--line); transition: box-shadow .2s var(--ease); }
.site-header.is-scrolled { box-shadow: 0 6px 24px rgba(16, 22, 43, .08); }
.site-header .container { display: flex; align-items: center; justify-content: space-between; height: var(--header-h); gap: var(--s-5); }

.brand { display: inline-flex; align-items: center; gap: 0.7rem; text-decoration: none; color: var(--navy); flex: none; }
.brand svg { width: 44px; height: 39px; }
.brand__text { display: flex; flex-direction: column; line-height: 1; }
.brand__name { font-family: var(--font-head); font-weight: 800; font-size: 1.35rem; letter-spacing: 0.02em; color: var(--navy); }
.brand__sub { font-family: var(--font-head); font-weight: 600; font-size: 0.64rem; letter-spacing: 0.32em; color: var(--muted); margin-top: 4px; }

.nav-toggle {
  display: inline-flex; align-items: center; gap: var(--s-2); background: none; border: 1.5px solid var(--ink);
  min-height: 44px; padding: 0 0.9rem; cursor: pointer; font-family: var(--font-head); font-weight: 600; font-size: .9rem;
}
.nav-toggle__bars { position: relative; width: 18px; height: 12px; }
.nav-toggle__bars span { position: absolute; left: 0; width: 100%; height: 2px; background: currentColor; transition: transform .2s var(--ease), opacity .2s; }
.nav-toggle__bars span:nth-child(1) { top: 0; }
.nav-toggle__bars span:nth-child(2) { top: 5px; }
.nav-toggle__bars span:nth-child(3) { top: 10px; }
.nav-toggle[aria-expanded="true"] .nav-toggle__bars span:nth-child(1) { transform: translateY(5px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle__bars span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] .nav-toggle__bars span:nth-child(3) { transform: translateY(-5px) rotate(-45deg); }

.primary-nav { display: none; }
.primary-nav.is-open {
  display: block; position: fixed; inset: calc(var(--header-h) + 1px) 0 0 0; background: var(--white);
  overflow-y: auto; padding: var(--s-5) var(--gutter) var(--s-8); border-top: 1px solid var(--line);
}
.nav-list { list-style: none; display: flex; flex-direction: column; }
.nav-list > li { border-bottom: 1px solid var(--line); }
.nav-link {
  display: flex; align-items: center; justify-content: space-between; width: 100%;
  padding: 1rem 0; font-family: var(--font-head); font-weight: 600; font-size: 1.15rem;
  text-decoration: none; color: var(--ink); background: none; border: 0; cursor: pointer; text-align: left;
}
.nav-link[aria-current="page"] { color: var(--laterite-dark); }
.nav-link .chev { width: 14px; height: 14px; transition: transform .2s var(--ease); }
.has-sub > .nav-link[aria-expanded="true"] .chev { transform: rotate(180deg); }
.subnav { list-style: none; display: none; padding: 0 0 var(--s-4) var(--s-4); }
.subnav.is-open { display: block; }
.subnav a { display: block; padding: 0.55rem 0; text-decoration: none; color: var(--text); }
.subnav a:hover, .subnav a[aria-current="page"] { color: var(--laterite-dark); }
.nav-cta { margin-top: var(--s-6); }
.nav-cta .btn { width: 100%; }
.header-cta { display: none; }

@media (min-width: 1140px) {
  .nav-toggle { display: none; }
  .primary-nav, .primary-nav.is-open { display: block; position: static; padding: 0; overflow: visible; border: 0; background: none; }
  .nav-list { flex-direction: row; align-items: center; gap: clamp(0.9rem, 1.6vw, 1.75rem); }
  .nav-list > li { border: 0; position: relative; }
  .nav-link { font-size: 0.95rem; padding: 0.5rem 0; gap: 6px; position: relative; }
  .nav-link::after { content: ""; position: absolute; left: 0; right: 0; bottom: -2px; height: 2px; background: var(--laterite); transform: scaleX(0); transform-origin: left; transition: transform .25s var(--ease); }
  .nav-link:hover::after, .nav-link[aria-current="page"]::after { transform: scaleX(1); }
  .nav-link[aria-current="page"] { color: var(--ink); }
  .subnav {
    position: absolute; top: calc(100% + 18px); left: -1.25rem; min-width: 290px; padding: var(--s-3) 0;
    background: var(--white); border: 1px solid var(--line); border-top: 3px solid var(--laterite);
    box-shadow: 0 18px 40px rgba(16,22,43,.12);
  }
  .subnav a { padding: 0.6rem 1.25rem; font-size: 0.95rem; }
  .subnav a:hover { background: var(--stone); }
  .nav-cta { display: none; }
  .header-cta { display: inline-flex; min-height: 46px; padding-inline: 1.2rem; }
}

/* ---------- Home hero (asymmetric split) ---------- */
.hero { background: var(--navy); color: var(--on-dark); position: relative; }
.hero__grid { display: grid; }
.hero__copy { padding: clamp(3rem, 2rem + 4vw, 6.5rem) var(--gutter) clamp(2.5rem, 2rem + 3vw, 5rem); }
.hero h1 { color: #fff; max-width: 11ch; margin-bottom: var(--s-5); }
.hero h1 em { font-style: normal; color: #e3a07f; }
.hero__intro { font-size: var(--fs-lead); max-width: 46ch; color: var(--on-dark); margin-bottom: var(--s-6); }
.hero__media { position: relative; min-height: 320px; }
.hero__media img { width: 100%; height: 100%; object-fit: cover; position: absolute; inset: 0; }
.hero__caption {
  position: absolute; left: 0; bottom: 0; background: var(--white); color: var(--ink);
  padding: 0.85rem 1.1rem; font-family: var(--font-mono); font-size: var(--fs-xs); letter-spacing: .03em; max-width: 90%;
}
.hero__caption strong { font-family: var(--font-head); font-size: 0.92rem; letter-spacing: 0; display: block; }
@media (min-width: 980px) {
  .hero__grid { grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr); min-height: min(86vh, 760px); }
  .hero__copy { padding-left: max(var(--gutter), calc((100vw - var(--container)) / 2 + var(--gutter))); align-self: center; }
  .hero__media { min-height: 0; }
}

/* Fact strip under hero */
.factstrip { background: var(--white); border-bottom: 1px solid var(--line); }
.factstrip dl { display: grid; margin: 0; }
.factstrip dl > div { padding: var(--s-5) 0; border-bottom: 1px solid var(--line); }
.factstrip dl > div:last-child { border-bottom: 0; }
.factstrip dt { font-family: var(--font-mono); font-size: var(--fs-xs); text-transform: uppercase; letter-spacing: .08em; color: var(--muted); margin-bottom: var(--s-1); }
.factstrip dd { margin: 0; font-family: var(--font-head); font-weight: 600; font-size: 1.1rem; color: var(--ink); }
@media (min-width: 820px) {
  .factstrip dl { grid-template-columns: repeat(3, 1fr); }
  .factstrip dl > div { border-bottom: 0; border-left: 1px solid var(--line); padding: var(--s-6) var(--s-6); }
  .factstrip dl > div:first-child { border-left: 0; padding-left: 0; }
}

/* ---------- Inner page hero ---------- */
.page-hero { background: var(--navy); color: var(--on-dark); position: relative; overflow: hidden; }
.page-hero .container { position: relative; z-index: 2; padding-block: clamp(3.5rem, 2.5rem + 5vw, 7rem) clamp(3rem, 2rem + 4vw, 5.5rem); }
.page-hero h1 { color: #fff; max-width: 16ch; }
.page-hero p { max-width: 56ch; font-size: var(--fs-lead); color: var(--on-dark); margin: 0; }
.page-hero--image .page-hero__bg { position: absolute; inset: 0; }
.page-hero--image .page-hero__bg img { width: 100%; height: 100%; object-fit: cover; }
.page-hero--image .page-hero__bg::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(16,22,43,.94) 0%, rgba(16,22,43,.82) 45%, rgba(16,22,43,.45) 100%); }
.breadcrumb { list-style: none; display: flex; flex-wrap: wrap; gap: var(--s-2); font-family: var(--font-mono); font-size: var(--fs-xs); letter-spacing: .05em; margin-bottom: var(--s-6); color: var(--on-dark-muted); }
.breadcrumb li + li::before { content: "/"; margin-right: var(--s-2); opacity: .6; }
.breadcrumb a { color: var(--on-dark); text-decoration: none; }
.breadcrumb a:hover { text-decoration: underline; }

/* ---------- Home: intro ---------- */
.intro-grid { display: grid; gap: var(--s-7); }
.intro-grid h2 { max-width: 16ch; }
.pullquote { border-left: 3px solid var(--laterite); padding: var(--s-2) 0 var(--s-2) var(--s-5); margin: var(--s-6) 0 0; }
.pullquote p { font-family: var(--font-head); font-weight: 500; font-size: 1.3rem; line-height: 1.4; color: var(--ink); margin-bottom: var(--s-3); }
.pullquote cite { font-style: normal; font-family: var(--font-mono); font-size: var(--fs-xs); color: var(--muted); letter-spacing: .05em; text-transform: uppercase; }
@media (min-width: 960px) { .intro-grid { grid-template-columns: 5fr 6fr; gap: var(--s-9); } }

/* ---------- Home: service index with image preview ---------- */
.svc-index { display: grid; gap: var(--s-7); }
.svc-list { list-style: none; border-top: 1px solid var(--ink); counter-reset: svc; }
.svc-item { border-bottom: 1px solid var(--line); }
.svc-item a {
  display: grid; grid-template-columns: 3rem 1fr auto; gap: var(--s-3) var(--s-4); align-items: start;
  padding: var(--s-5) 0; text-decoration: none; color: inherit; transition: padding .25s var(--ease);
}
.svc-item .n { font-family: var(--font-mono); font-size: var(--fs-sm); color: var(--laterite-dark); padding-top: .35rem; }
.svc-item h3 { margin: 0 0 var(--s-2); font-size: clamp(1.3rem, 1.1rem + .8vw, 1.75rem); }
.svc-item p { margin: 0; color: var(--muted); max-width: 52ch; }
.svc-item .arrow { width: 22px; height: 22px; margin-top: .45rem; color: var(--ink); transition: transform .25s var(--ease), color .25s; }
.svc-item a:hover .arrow, .svc-item a:focus-visible .arrow, .svc-item.is-active .arrow { transform: translateX(4px); color: var(--laterite); }
.svc-item.is-active h3 { color: var(--laterite-dark); }
.svc-preview { display: none; }
@media (min-width: 1000px) {
  .svc-index { grid-template-columns: 1.15fr 1fr; gap: var(--s-8); align-items: start; }
  .svc-preview { display: block; position: sticky; top: calc(var(--header-h) + 2rem); }
  .svc-preview__frame { position: relative; aspect-ratio: 4 / 5; overflow: hidden; background: var(--stone-2); }
  .svc-preview__frame img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; transition: opacity .45s var(--ease); }
  .svc-preview__frame img.is-active { opacity: 1; }
  .svc-preview figcaption { font-family: var(--font-mono); font-size: var(--fs-xs); color: var(--muted); margin-top: var(--s-3); min-height: 2.6em; }
}

/* ---------- Project tiles ---------- */
.proj-feature { display: grid; gap: var(--s-6); }
.tile { position: relative; display: block; text-decoration: none; color: inherit; }
.tile__img { position: relative; overflow: hidden; background: var(--stone-2); aspect-ratio: 4 / 3; }
.tile__img img { width: 100%; height: 100%; object-fit: cover; transition: transform .7s var(--ease); }
.tile:hover .tile__img img, .tile:focus-visible .tile__img img { transform: scale(1.035); }
.tile__meta { display: flex; flex-wrap: wrap; gap: var(--s-2) var(--s-4); font-family: var(--font-mono); font-size: var(--fs-xs); letter-spacing: .05em; text-transform: uppercase; color: var(--muted); margin: var(--s-4) 0 var(--s-2); }
.tile__meta .status { color: var(--laterite-dark); }
.tile h3 { font-size: clamp(1.25rem, 1.1rem + .6vw, 1.6rem); margin: 0 0 var(--s-2); }
.tile:hover h3 { text-decoration: underline; text-decoration-color: var(--laterite); text-underline-offset: 4px; text-decoration-thickness: 2px; }
.tile p { color: var(--muted); margin: 0; max-width: 52ch; }
.tile--lg .tile__img { aspect-ratio: 16 / 10; }
.tile--tall .tile__img { aspect-ratio: 4 / 5; }
@media (min-width: 900px) {
  .proj-feature { grid-template-columns: repeat(12, 1fr); gap: var(--s-8) var(--s-6); }
  .proj-feature .tile--lg { grid-column: 1 / span 8; }
  .proj-feature .tile--side { grid-column: 9 / span 4; align-self: end; }
  .proj-feature .tile--a { grid-column: 1 / span 5; }
  .proj-feature .tile--b { grid-column: 7 / span 6; margin-top: var(--s-9); }
}

/* ---------- Process (horizontal stages) ---------- */
.stages { list-style: none; display: grid; gap: 0; counter-reset: st; border-top: 1px solid var(--ink); }
.stage { padding: var(--s-5) 0 var(--s-6); border-bottom: 1px solid var(--line); display: grid; grid-template-columns: 3.5rem 1fr; gap: var(--s-3); }
.stage .n { font-family: var(--font-mono); font-size: var(--fs-sm); color: var(--laterite-dark); }
.stage h3 { font-size: 1.2rem; margin: 0 0 var(--s-2); }
.stage p { margin: 0; color: var(--muted); font-size: 0.97rem; }
.section--navy .stages { border-top-color: rgba(255,255,255,.6); }
.section--navy .stage { border-bottom-color: var(--line-dark); }
.section--navy .stage .n { color: #e3a07f; }
.section--navy .stage p { color: var(--on-dark-muted); }
@media (min-width: 1000px) {
  .stages { grid-template-columns: repeat(5, 1fr); border-top: 0; }
  .stage { display: block; border-bottom: 0; border-top: 1px solid var(--ink); padding: var(--s-5) var(--s-5) 0 0; position: relative; }
  .stage::before { content: ""; position: absolute; top: -5px; left: 0; width: 9px; height: 9px; background: var(--laterite); }
  .section--navy .stage { border-top-color: rgba(255,255,255,.55); }
  .stage .n { display: block; margin-bottom: var(--s-5); }
}

/* ---------- Split media / text ---------- */
.split { display: grid; gap: var(--s-7); align-items: center; }
.split__media img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.split__media figcaption, .caption { font-family: var(--font-mono); font-size: var(--fs-xs); color: var(--muted); margin-top: var(--s-3); letter-spacing: .02em; }
.section--navy .caption, .section--navy .split__media figcaption { color: var(--on-dark-muted); }
@media (min-width: 960px) {
  .split { grid-template-columns: 1fr 1fr; gap: var(--s-9); }
  .split--wide-media { grid-template-columns: 1.25fr 1fr; }
  .split--reverse .split__media { order: 2; }
}

/* Ruled list (two-column definition style) */
.ruled { list-style: none; border-top: 1px solid var(--ink); }
.ruled li { padding: var(--s-4) 0; border-bottom: 1px solid var(--line); display: grid; grid-template-columns: 2.5rem 1fr; gap: var(--s-3); }
.ruled li .n { font-family: var(--font-mono); font-size: var(--fs-xs); color: var(--laterite-dark); padding-top: .3rem; }
.ruled li strong { font-family: var(--font-head); color: var(--ink); display: block; font-size: 1.08rem; margin-bottom: 2px; }
.ruled li span.d { color: var(--muted); font-size: .97rem; }
.ruled--plain li { grid-template-columns: 1fr; }
.section--navy .ruled { border-top-color: rgba(255,255,255,.6); }
.section--navy .ruled li { border-bottom-color: var(--line-dark); }
.section--navy .ruled li strong { color: #fff; }
.section--navy .ruled li span.d { color: var(--on-dark-muted); }
.ruled-cols { display: grid; gap: 0 var(--s-7); }
@media (min-width: 820px) { .ruled-cols { grid-template-columns: 1fr 1fr; } .ruled-cols .ruled + .ruled { border-top-color: var(--ink); } }

/* Simple tick list */
.ticks { list-style: none; display: grid; gap: var(--s-3); }
.ticks li { position: relative; padding-left: 1.6rem; }
.ticks li::before { content: ""; position: absolute; left: 0; top: .62em; width: 10px; height: 2px; background: var(--laterite); }

/* ---------- Credentials strip ---------- */
.licence-row { display: grid; gap: 0; border-top: 1px solid var(--line-dark); }
.licence { padding: var(--s-5) 0; border-bottom: 1px solid var(--line-dark); }
.licence .k { font-family: var(--font-mono); font-size: var(--fs-xs); letter-spacing: .08em; text-transform: uppercase; color: #e3a07f; display: block; margin-bottom: var(--s-2); }
.licence strong { font-family: var(--font-head); font-size: 1.35rem; color: #fff; display: block; margin-bottom: var(--s-2); }
.licence p { color: var(--on-dark-muted); margin: 0; font-size: .97rem; }
@media (min-width: 900px) {
  .licence-row { grid-template-columns: repeat(3, 1fr); border-top: 0; }
  .licence { border-bottom: 0; border-left: 1px solid var(--line-dark); padding: var(--s-2) var(--s-6); }
  .licence:first-child { border-left: 0; padding-left: 0; }
}

/* ---------- CTA band ---------- */
.cta-band { background: var(--laterite); color: #fff; }
.cta-band .container { display: grid; gap: var(--s-6); padding-block: clamp(3.5rem, 2.5rem + 4vw, 6rem); }
.cta-band h2 { color: #fff; max-width: 17ch; margin: 0; }
.cta-band p { margin: 0; max-width: 48ch; font-size: var(--fs-lead); color: #fbeee6; }
.cta-band .btn--light { background: #fff; color: var(--navy); }
.cta-band .btn--light:hover { background: var(--navy); color: #fff; }
@media (min-width: 960px) { .cta-band .container { grid-template-columns: 1.2fr 1fr; align-items: end; } }

/* ---------- Title block (project / data sheet) ---------- */
.titleblock { border: 1.5px solid var(--ink); background: var(--white); font-size: .95rem; }
.titleblock__head { background: var(--ink); color: #fff; padding: .7rem 1rem; font-family: var(--font-mono); font-size: var(--fs-xs); letter-spacing: .08em; text-transform: uppercase; display: flex; justify-content: space-between; gap: 1rem; }
.titleblock dl { margin: 0; display: grid; grid-template-columns: minmax(7.5rem, 38%) 1fr; }
.titleblock dt, .titleblock dd { margin: 0; padding: .8rem 1rem; border-top: 1px solid var(--line); }
.titleblock dl > dt:first-of-type, .titleblock dl > dt:first-of-type + dd { border-top: 0; }
.titleblock dt { font-family: var(--font-mono); font-size: var(--fs-xs); letter-spacing: .06em; text-transform: uppercase; color: var(--muted); border-right: 1px solid var(--line); }
.titleblock dd { color: var(--ink); font-weight: 500; }
.titleblock .note { padding: .75rem 1rem; border-top: 1px solid var(--line); font-size: var(--fs-xs); color: var(--muted); font-family: var(--font-mono); background: var(--paper); }

/* ---------- Service landing cards ---------- */
.svc-cards { display: grid; gap: var(--s-8) var(--s-6); }
.svc-card { display: grid; gap: var(--s-4); align-content: start; }
.svc-card__img { aspect-ratio: 3 / 2; overflow: hidden; background: var(--navy); position: relative; }
.svc-card__img img { width: 100%; height: 100%; object-fit: cover; transition: transform .7s var(--ease); }
.svc-card:hover .svc-card__img img { transform: scale(1.03); }
.svc-card .n { font-family: var(--font-mono); font-size: var(--fs-xs); color: var(--laterite-dark); letter-spacing: .06em; }
.svc-card h2, .svc-card h3 { font-size: clamp(1.4rem, 1.2rem + .7vw, 1.85rem); margin: 0; }
.svc-card p { margin: 0; color: var(--muted); }
.svc-card .btn-row { margin-top: var(--s-2); align-items: center; gap: var(--s-5); }
@media (min-width: 820px) {
  .svc-cards { grid-template-columns: repeat(2, 1fr); }
  .svc-card--wide { grid-column: 1 / -1; grid-template-columns: 1.3fr 1fr; gap: var(--s-7); align-items: center; }
}
/* Typographic panel used where no authentic photo exists */
.type-panel { position: absolute; inset: 0; display: flex; flex-direction: column; justify-content: space-between; padding: var(--s-5); color: var(--on-dark); background:
  repeating-linear-gradient(0deg, transparent 0 39px, rgba(255,255,255,.06) 39px 40px),
  repeating-linear-gradient(90deg, transparent 0 39px, rgba(255,255,255,.06) 39px 40px), var(--navy); }
.type-panel .big { font-family: var(--font-head); font-weight: 800; font-size: clamp(2rem, 1.5rem + 2vw, 3.2rem); line-height: 1; color: #fff; letter-spacing: -.02em; }
.type-panel .small { font-family: var(--font-mono); font-size: var(--fs-xs); letter-spacing: .08em; text-transform: uppercase; color: #e3a07f; }

/* Category grid (8 construction categories) */
.cat-grid { list-style: none; display: grid; border-top: 1px solid var(--ink); border-left: 1px solid var(--line); }
.cat-grid li { padding: var(--s-6) var(--s-5); border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); background: var(--white); }
.cat-grid .n { font-family: var(--font-mono); font-size: var(--fs-xs); color: var(--laterite-dark); display: block; margin-bottom: var(--s-5); }
.cat-grid h3 { font-size: 1.2rem; margin: 0 0 var(--s-2); }
.cat-grid p { margin: 0; color: var(--muted); font-size: .97rem; }
.cat-grid a { color: var(--ink); }
@media (min-width: 640px) { .cat-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1100px) { .cat-grid { grid-template-columns: repeat(4, 1fr); } }

/* ---------- Projects page ---------- */
.filters { display: flex; flex-wrap: wrap; gap: var(--s-2); margin-bottom: var(--s-7); }
.filters__label { font-family: var(--font-mono); font-size: var(--fs-xs); text-transform: uppercase; letter-spacing: .08em; color: var(--muted); width: 100%; margin-bottom: var(--s-2); }
.filter-btn {
  min-height: 42px; padding: .45rem 1rem; border: 1px solid var(--line); background: var(--white); cursor: pointer;
  font-family: var(--font-head); font-weight: 600; font-size: .9rem; color: var(--text);
}
.filter-btn:hover { border-color: var(--ink); }
.filter-btn[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: #fff; }
.filter-btn .c { font-family: var(--font-mono); font-weight: 400; font-size: .75rem; opacity: .7; margin-left: .35rem; }
.portfolio { display: grid; gap: var(--s-8) var(--s-6); }
.portfolio .tile[hidden] { display: none; }
@media (min-width: 720px) { .portfolio { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1100px) { .portfolio { grid-template-columns: repeat(3, 1fr); } .portfolio .tile--span2 { grid-column: span 2; } }
.portfolio .tile--span2 .tile__img { aspect-ratio: 16 / 9; }
.portfolio-empty { padding: var(--s-6); border: 1px dashed var(--line); color: var(--muted); }
.tile__kind { position: absolute; top: 0; left: 0; background: var(--white); color: var(--ink); font-family: var(--font-mono); font-size: .7rem; letter-spacing: .08em; text-transform: uppercase; padding: .35rem .6rem; z-index: 1; }

/* Text-only design row (no verified image) */
.tile--noimg .tile__img { display: flex; align-items: flex-end; }
.tile--noimg .type-panel { position: absolute; }

/* ---------- Gallery ---------- */
.gallery { display: grid; gap: var(--s-4); grid-template-columns: repeat(2, 1fr); }
.gallery figure { margin: 0; }
.gallery button { display: block; width: 100%; padding: 0; border: 0; background: var(--stone-2); cursor: zoom-in; overflow: hidden; }
.gallery img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; transition: transform .6s var(--ease); }
.gallery button:hover img { transform: scale(1.03); }
.gallery figcaption { font-family: var(--font-mono); font-size: var(--fs-xs); color: var(--muted); margin-top: var(--s-2); }
.gallery .g-wide { grid-column: 1 / -1; }
.gallery .g-wide img { aspect-ratio: 16 / 9; }
@media (min-width: 900px) { .gallery { grid-template-columns: repeat(3, 1fr); gap: var(--s-5); } .gallery .g-wide { grid-column: span 2; } .gallery .g-tall { grid-row: span 2; } .gallery .g-tall img { aspect-ratio: auto; height: 100%; } .gallery .g-tall button { height: calc(100% - 1.8rem); } }

/* Document grid (credentials, client letters) */
.docs { list-style: none; display: grid; gap: var(--s-6) var(--s-5); grid-template-columns: repeat(2, 1fr); }
.docs button { display: block; width: 100%; padding: var(--s-3); background: var(--white); border: 1px solid var(--line); cursor: zoom-in; transition: border-color .2s, transform .3s var(--ease); }
.docs button:hover { border-color: var(--ink); transform: translateY(-3px); }
.docs img { width: 100%; aspect-ratio: 3 / 4; object-fit: contain; background: var(--white); }
.docs h3 { font-size: 1rem; margin: var(--s-3) 0 2px; }
.docs p { font-family: var(--font-mono); font-size: var(--fs-xs); color: var(--muted); margin: 0; }
@media (min-width: 720px) { .docs { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 1100px) { .docs { grid-template-columns: repeat(4, 1fr); } }

/* Lightbox */
.lightbox { position: fixed; inset: 0; z-index: 300; background: rgba(10, 13, 26, .94); display: none; align-items: center; justify-content: center; padding: 4rem 1rem 3rem; }
.lightbox.is-open { display: flex; }
.lightbox img { max-width: min(1400px, 100%); max-height: 100%; object-fit: contain; width: auto; }
.lightbox__close { position: absolute; top: 1rem; right: 1rem; min-width: 48px; min-height: 48px; background: #fff; border: 0; cursor: pointer; font-family: var(--font-head); font-weight: 600; padding: 0 1rem; }
.lightbox__cap { position: absolute; bottom: 1rem; left: 1rem; right: 1rem; text-align: center; color: var(--on-dark); font-family: var(--font-mono); font-size: var(--fs-xs); }

/* ---------- Project detail ---------- */
.proj-top { display: grid; gap: var(--s-7); }
.proj-top__img img { width: 100%; aspect-ratio: 16 / 10; object-fit: cover; }
@media (min-width: 1000px) { .proj-top { grid-template-columns: 1.55fr 1fr; align-items: start; gap: var(--s-8); } .proj-top aside { position: sticky; top: calc(var(--header-h) + 1.5rem); } }
.scope-list { list-style: none; display: grid; gap: 0; border-top: 1px solid var(--ink); }
.scope-list li { padding: var(--s-4) 0; border-bottom: 1px solid var(--line); display: flex; gap: var(--s-4); font-family: var(--font-head); font-weight: 600; color: var(--ink); font-size: 1.08rem; }
.scope-list li span { font-family: var(--font-mono); font-weight: 400; font-size: var(--fs-xs); color: var(--laterite-dark); padding-top: .3rem; min-width: 2rem; }
@media (min-width: 720px) { .scope-list { grid-template-columns: 1fr 1fr; column-gap: var(--s-6); } }

.prevnext { display: grid; gap: var(--s-4); border-top: 1px solid var(--line); padding-top: var(--s-6); }
.prevnext a { text-decoration: none; display: block; padding: var(--s-4) 0; }
.prevnext small { display: block; font-family: var(--font-mono); font-size: var(--fs-xs); text-transform: uppercase; letter-spacing: .08em; color: var(--muted); }
.prevnext strong { font-family: var(--font-head); font-size: 1.3rem; color: var(--ink); }
.prevnext a:hover strong { color: var(--laterite-dark); }
@media (min-width: 720px) { .prevnext { grid-template-columns: 1fr 1fr; } .prevnext a:last-child { text-align: right; } }

/* ---------- About ---------- */
.vm-grid { display: grid; gap: var(--s-7); }
.vm-grid article h3 { font-size: 1rem; font-family: var(--font-mono); font-weight: 500; text-transform: uppercase; letter-spacing: .1em; color: var(--laterite-dark); margin-bottom: var(--s-4); }
.vm-grid article p { font-family: var(--font-head); font-size: clamp(1.3rem, 1.1rem + .8vw, 1.75rem); line-height: 1.3; color: var(--ink); font-weight: 500; letter-spacing: -.01em; }
@media (min-width: 900px) { .vm-grid { grid-template-columns: 1fr 1fr; gap: var(--s-9); } }
.values { list-style: none; display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); border-top: 1px solid var(--ink); }
.values li { padding: var(--s-5) var(--s-4) var(--s-5) 0; border-bottom: 1px solid var(--line); font-family: var(--font-head); font-weight: 600; color: var(--ink); font-size: 1.1rem; display: flex; gap: var(--s-3); }
.values li span { font-family: var(--font-mono); font-weight: 400; font-size: var(--fs-xs); color: var(--laterite-dark); padding-top: .25rem; }

.letter { display: grid; gap: var(--s-7); }
.letter__body p { font-size: 1.08rem; }
.letter__body p:first-child { font-family: var(--font-head); font-size: var(--fs-lead); color: var(--ink); font-weight: 500; }
.letter__sign { font-family: var(--font-head); font-weight: 600; color: var(--ink); border-top: 1px solid var(--line); padding-top: var(--s-4); margin-top: var(--s-6); }
.letter__sign small { display: block; font-family: var(--font-mono); font-weight: 400; color: var(--muted); font-size: var(--fs-xs); text-transform: uppercase; letter-spacing: .08em; }
@media (min-width: 960px) { .letter { grid-template-columns: 1fr 1.6fr; gap: var(--s-9); } .letter aside { position: sticky; top: calc(var(--header-h) + 2rem); align-self: start; } }

/* Org chart */
.org { --oc-line: var(--ink); font-family: var(--font-head); }
.org__node { background: var(--white); border: 1.5px solid var(--ink); padding: .7rem 1rem; text-align: center; font-weight: 600; color: var(--ink); font-size: .98rem; }
.org__node--top { background: var(--navy); color: #fff; border-color: var(--navy); }
.org__node small { display: block; font-family: var(--font-mono); font-weight: 400; font-size: .7rem; color: var(--muted); letter-spacing: .03em; margin-top: 3px; }
.org__node--top small { color: var(--on-dark-muted); }
.org__spine { display: grid; justify-items: center; gap: 0; }
.org__spine .org__node { min-width: 240px; }
.org__v { width: 1.5px; height: 24px; background: var(--oc-line); }
.org__branches { list-style: none; display: grid; gap: var(--s-4); margin-top: 0; }
.org__branch { display: grid; gap: var(--s-2); align-content: start; }
.org__sub { list-style: none; display: grid; gap: var(--s-2); padding-left: var(--s-4); border-left: 1.5px solid var(--line); }
.org__sub li { font-family: var(--font-body); font-size: .9rem; color: var(--text); padding: .35rem .6rem; background: var(--stone); }
@media (min-width: 1000px) {
  .org__branches { grid-template-columns: repeat(5, 1fr); gap: var(--s-4); position: relative; padding-top: 24px; }
  .org__branches::before { content: ""; position: absolute; top: 0; left: 10%; right: 10%; height: 1.5px; background: var(--oc-line); }
  .org__branch { position: relative; }
  .org__branch::before { content: ""; position: absolute; top: -24px; left: 50%; width: 1.5px; height: 24px; background: var(--oc-line); }
  .org__sub { padding-left: 0; border-left: 0; margin-top: var(--s-2); }
  .org__sub li { text-align: center; }
}

/* Function grid */
.fn-grid { list-style: none; display: grid; gap: 0; border-top: 1px solid var(--ink); }
.fn-grid li { padding: var(--s-5) 0; border-bottom: 1px solid var(--line); }
.fn-grid h3 { font-size: 1.12rem; margin-bottom: var(--s-2); display: flex; gap: var(--s-3); }
.fn-grid h3 span { font-family: var(--font-mono); font-weight: 400; font-size: var(--fs-xs); color: var(--laterite-dark); padding-top: .3rem; }
.fn-grid p { margin: 0; color: var(--muted); font-size: .96rem; }
@media (min-width: 760px) { .fn-grid { grid-template-columns: repeat(2, 1fr); column-gap: var(--s-7); } }
@media (min-width: 1100px) { .fn-grid { grid-template-columns: repeat(4, 1fr); column-gap: var(--s-6); } }

/* ---------- Partners ---------- */
.partner-list { list-style: none; display: grid; border-top: 1px solid var(--ink); }
.partner-list li { display: grid; grid-template-columns: 3rem 1fr; gap: var(--s-3); align-items: baseline; padding: var(--s-5) 0; border-bottom: 1px solid var(--line); }
.partner-list .n { font-family: var(--font-mono); font-size: var(--fs-xs); color: var(--laterite-dark); }
.partner-list strong { font-family: var(--font-head); font-size: clamp(1.25rem, 1.1rem + .6vw, 1.6rem); color: var(--ink); font-weight: 700; letter-spacing: -.01em; }
@media (min-width: 900px) { .partner-list { grid-template-columns: 1fr 1fr; column-gap: var(--s-7); } }

.client-rows { display: grid; gap: 0; border-top: 1px solid var(--ink); }
.client-row { display: grid; gap: var(--s-2) var(--s-6); padding: var(--s-5) 0; border-bottom: 1px solid var(--line); }
.client-row h3 { font-size: 1.2rem; margin: 0; }
.client-row p { margin: 0; color: var(--muted); }
.client-row a { font-family: var(--font-head); font-weight: 600; }
@media (min-width: 900px) { .client-row { grid-template-columns: 1.1fr 1.4fr auto; align-items: baseline; } }

/* ---------- Contact ---------- */
.contact-grid { display: grid; gap: var(--s-8); }
@media (min-width: 1000px) { .contact-grid { grid-template-columns: 1fr 1.6fr; gap: var(--s-9); } .contact-grid aside { position: sticky; top: calc(var(--header-h) + 2rem); align-self: start; } }
.contact-block { border-top: 1px solid var(--ink); }
.contact-block div { padding: var(--s-4) 0; border-bottom: 1px solid var(--line); }
.contact-block dt { font-family: var(--font-mono); font-size: var(--fs-xs); text-transform: uppercase; letter-spacing: .08em; color: var(--muted); margin-bottom: 2px; }
.contact-block dd { margin: 0; font-family: var(--font-head); font-weight: 600; color: var(--ink); font-size: 1.08rem; }
.contact-block dl { margin: 0; }

.notice { border-left: 3px solid var(--laterite); background: var(--laterite-tint); padding: var(--s-4) var(--s-5); font-size: .95rem; color: var(--ink); margin-bottom: var(--s-6); }
.notice strong { font-family: var(--font-head); }

.form { display: grid; gap: var(--s-5); }
.form-row { display: grid; gap: var(--s-5); }
@media (min-width: 680px) { .form-row--2 { grid-template-columns: 1fr 1fr; } }
.field { display: grid; gap: var(--s-2); }
.field label, .field legend { font-family: var(--font-head); font-weight: 600; color: var(--ink); font-size: .95rem; padding: 0; }
.field .req { color: var(--laterite-dark); }
.field .opt { font-family: var(--font-mono); font-weight: 400; font-size: .72rem; color: var(--muted); margin-left: .3rem; }
.field input, .field select, .field textarea {
  width: 100%; min-height: 50px; padding: .75rem .9rem; border: 1px solid #b9b2a6; border-radius: 0; background: var(--white);
  transition: border-color .15s, box-shadow .15s;
}
.field textarea { min-height: 160px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--navy); box-shadow: 0 0 0 3px rgba(26, 35, 66, .18); }
.field .hint { font-size: .85rem; color: var(--muted); }
.field .error { font-size: .88rem; color: #a3261a; font-weight: 500; display: none; }
.field.is-invalid input, .field.is-invalid select, .field.is-invalid textarea { border-color: #a3261a; }
.field.is-invalid .error { display: block; }
fieldset.field { border: 0; margin: 0; padding: 0; }
.check { display: flex; gap: var(--s-3); align-items: flex-start; font-size: .95rem; }
.check input { width: 20px; height: 20px; min-height: 0; margin-top: 3px; accent-color: var(--navy); flex: none; }
.hp { position: absolute; left: -9999px; }
.form-success { border: 1.5px solid var(--ink); padding: var(--s-6); background: var(--paper); }
.form-success h3 { margin-bottom: var(--s-3); }

/* ---------- Footer ---------- */
.site-footer { background: var(--navy-ink); color: var(--on-dark-muted); font-size: .95rem; }
.site-footer a { color: var(--on-dark); text-decoration: none; }
.site-footer a:hover { color: #fff; text-decoration: underline; text-underline-offset: 3px; }
.footer-top { display: grid; gap: var(--s-7); padding-block: var(--s-8) var(--s-7); }
.footer-brand .brand { color: #fff; margin-bottom: var(--s-5); }
.footer-brand .brand__name { color: #fff; }
.footer-brand .brand__sub { color: var(--on-dark-muted); }
.footer-brand .brand svg { color: #c9c3b8; }
.footer-brand p { max-width: 38ch; }
.site-footer h2 { font-family: var(--font-mono); font-size: var(--fs-xs); font-weight: 500; letter-spacing: .1em; text-transform: uppercase; color: #e3a07f; margin-bottom: var(--s-4); }
.site-footer ul { list-style: none; display: grid; gap: var(--s-2); }
.footer-bottom { border-top: 1px solid var(--line-dark); padding-block: var(--s-5); display: flex; flex-wrap: wrap; justify-content: space-between; gap: var(--s-3); font-size: var(--fs-xs); font-family: var(--font-mono); letter-spacing: .03em; }
@media (min-width: 760px) { .footer-top { grid-template-columns: 1.5fr 1fr 1fr; } }
@media (min-width: 1100px) { .footer-top { grid-template-columns: 1.6fr 1fr 1.1fr 1.1fr; } }

/* ---------- Prose (privacy etc.) ---------- */
.prose { max-width: 70ch; }
.prose h2 { font-size: 1.5rem; margin-top: var(--s-7); }

/* ---------- Reveal on scroll (progressive: only hidden once JS adds .js) ---------- */
.js .reveal { opacity: 0; transform: translateY(18px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
.js .reveal.is-visible { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: .01ms !important; animation-duration: .01ms !important; }
  .js .reveal { opacity: 1; transform: none; }
}

@media print {
  .topbar, .site-header, .cta-band, .site-footer, .filters { display: none; }
  .page-hero, .hero, .section--navy { background: #fff; color: #000; }
}

/* Services button shows the current-page state when on a service page */
.nav-link[data-current] { color: var(--laterite-dark); }
@media (min-width: 1140px) { .nav-link[data-current] { color: var(--ink); } .nav-link[data-current]::after { transform: scaleX(1); } }

/* ---------- Logo image ---------- */
.brand img { height: 44px; width: auto; }
@media (min-width: 480px) { .brand img { height: 56px; } }
.footer-brand .brand img { height: 64px; }

/* ---------- Hero line drawing (assets/images/hero/construction-site.svg) ---------- */
.page-hero::before, .hero__copy::before {
  content: ""; position: absolute; inset: 0; z-index: 1; pointer-events: none;
  background: url("../assets/images/hero/construction-site.svg") right bottom / auto 100% no-repeat;
}
.hero__copy { position: relative; }
.hero__copy > * { position: relative; z-index: 2; }
.page-hero--image::before { opacity: .38; }
.hero__copy::before { opacity: .42; background-size: auto 88%; }
@media (max-width: 700px) { .page-hero::before, .hero__copy::before { opacity: .55; background-size: auto 85%; } }
