/* IRTech Renewables. Light first: warm paper, logo navy and blue, serif headings.
   One 12-column board with 8px gaps and flat square tiles. Shared by every page.
   Dark mode is not shipped; to add it, override the colour tokens below inside a dark block. */

:root {
  color-scheme: light;
  --bg: #faf8f5;
  --surface: #f1ede6;
  --mid: #e2ddd2;
  --ink: #1c2140;
  --muted: #5a6075;
  --accent: #1a559c;
  --accent-ink: #ffffff;
  --navy: #2e365e;
  --tint: #d9e7f6;

  --serif: "Fraunces", "Times New Roman", serif;
  --font: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --step-small: clamp(0.8125rem, 0.79rem + 0.1vw, 0.875rem);
  --step-body: clamp(1rem, 0.7rem + 0.7vw, 1.1875rem);
  --step-lead: clamp(1.25rem, 1.1rem + 0.7vw, 1.625rem);
  --step-head: clamp(2.25rem, 1.1rem + 3.6vw, 4.25rem);
  --step-display: clamp(3.5rem, 2rem + 4.5vw, 6rem);

  --m: clamp(12px, 2.4vw, 32px);
  --maxw: 1320px;
  --pad: max(var(--m), calc((100vw - var(--maxw)) / 2));
  --gap: 8px;
  --u: clamp(88px, 8.4vw, 124px);
  --section: clamp(4.75rem, 7vw, 6.25rem);

  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-in-out: cubic-bezier(0.76, 0, 0.24, 1);
  --ease-soft: cubic-bezier(0.33, 1, 0.68, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  overflow-anchor: none; /* the filter handler restores scroll position itself */
  margin: 0; background: var(--bg); color: var(--ink);
  font-family: var(--font); font-size: var(--step-body); font-weight: 400; line-height: 1.55;
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
}
h1, h2, h3, h4, p, figure, ul, ol, dl, dd { margin: 0; }
ul, ol { padding: 0; list-style: none; }
img, svg { display: block; max-width: 100%; }
button, input { font: inherit; color: inherit; }
button { background: none; border: 0; padding: 0; cursor: pointer; }
a { color: inherit; }
[hidden] { display: none !important; }
::selection { background: var(--accent); color: var(--accent-ink); }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }
:target { scroll-margin-top: 24px; }

.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.skip { position: absolute; left: 12px; top: -60px; z-index: 50; background: var(--accent); color: var(--accent-ink); padding: 12px 18px; text-decoration: none; }
.skip:focus { top: 12px; }

/* ---------- type ---------- */
h1, h2, h3 { font-family: var(--serif); font-weight: 500; text-wrap: balance; hyphens: none; }
.head { font-size: var(--step-head); line-height: 1; letter-spacing: -0.025em; }
.lead { font-size: var(--step-lead); line-height: 1.3; max-width: 38ch; text-wrap: pretty; }
.small { font-size: var(--step-small); }
.muted { color: var(--muted); }
p { max-width: 64ch; text-wrap: pretty; }
p + p { margin-top: 0.8em; }

/* ---------- controls ---------- */
.button {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 3rem; padding: 0 1.4rem; background: var(--accent); color: var(--accent-ink);
  font-weight: 500; text-decoration: none; white-space: nowrap;
  transition: transform 140ms var(--ease-out), background-color 180ms ease, color 180ms ease;
}
.button:active { transform: scale(0.97); }
.button--light { background: #fff; color: var(--navy); }
.button--small { min-height: 2.75rem; padding: 0 1.1rem; font-size: var(--step-small); }
.link { text-decoration: underline; text-decoration-color: transparent; text-underline-offset: 0.22em; text-decoration-thickness: 0.07em; transition: text-decoration-color 180ms ease; }
@media (hover: hover) and (pointer: fine) {
  .button:hover { background: var(--navy); }
  .button--light:hover { background: var(--tint); color: var(--navy); }
  .link:hover { text-decoration-color: currentColor; }
}

/* ---------- header ---------- */
.site-header { display: flex; align-items: center; gap: 24px; padding: 18px var(--pad); }
.brand img { height: 60px; width: auto; margin-block: -8px; }
.site-header nav { display: flex; gap: 28px; margin-left: auto; font-size: var(--step-small); }
.site-header nav a { text-decoration: none; padding: 12px 0; }
.site-header nav a[aria-current="page"] { text-decoration: underline; text-decoration-thickness: 0.09em; text-underline-offset: 0.3em; }
@media (hover: hover) and (pointer: fine) { .site-header nav a:hover { text-decoration: underline; text-underline-offset: 0.3em; } }
.nav-toggle, .contact-icon { display: none; }
@media (max-width: 760px) {
  .site-header { position: relative; display: grid; grid-template-columns: 48px minmax(0, 1fr) 48px; gap: 8px; padding-block: 10px; }
  .brand { grid-column: 2; justify-self: center; }
  .nav-toggle { grid-column: 1; grid-row: 1; justify-self: start; display: block; position: relative; width: 48px; height: 48px; }
  .nav-toggle i { position: absolute; left: 12px; right: 12px; height: 2px; background: var(--ink); transition: transform 200ms var(--ease-out), opacity 150ms ease; }
  .nav-toggle i:nth-child(1) { top: 16px; } .nav-toggle i:nth-child(2) { top: 23px; } .nav-toggle i:nth-child(3) { top: 30px; }
  .nav-toggle[aria-expanded="true"] i:nth-child(1) { transform: translateY(7px) rotate(45deg); }
  .nav-toggle[aria-expanded="true"] i:nth-child(2) { opacity: 0; }
  .nav-toggle[aria-expanded="true"] i:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
  .site-header .contact-btn { grid-column: 3; grid-row: 1; justify-self: end; width: 48px; height: 48px; min-height: 0; padding: 0; margin: 0; }
  .contact-text { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
  .contact-icon { display: block; }
  .site-header nav { position: absolute; top: 100%; left: 0; right: 0; z-index: 40; margin: 0; padding: 8px var(--pad) 16px; flex-direction: column; gap: 0; background: var(--bg); border-bottom: 1px solid var(--mid); font-size: 1.125rem; }
  .js .site-header nav { display: none; }
  .js .site-header.nav-open nav { display: flex; }
  .site-header nav a { display: flex; align-items: center; min-height: 52px; padding: 0; border-bottom: 1px solid var(--mid); }
  .site-header nav .has-menu { display: block; }
  .site-header nav .menu { position: static; display: grid; min-width: 0; padding: 0 0 0 16px; background: none; }
  .site-header nav .menu a { color: var(--ink); min-height: 46px; padding: 0 !important; font-size: var(--step-body); }
  .site-header nav .menu a:hover, .site-header nav .menu a:focus-visible { background: none; }
}

/* services dropdown: opens on hover or keyboard focus; on touch the Services link goes to the page that lists them */
.has-menu { position: relative; display: flex; align-items: center; }
.menu { position: absolute; top: 100%; left: -14px; z-index: 30; min-width: 250px; padding: 6px; display: none; background: var(--navy); }
.has-menu:hover .menu, .has-menu:focus-within .menu { display: grid; }
.menu a { padding: 12px 14px !important; color: #fff; text-decoration: none; transition: background-color 180ms ease; }
.menu a:hover, .menu a:focus-visible { background: var(--accent); text-decoration: none !important; }

/* ---------- board ---------- */
.page { padding-inline: var(--pad); }
.board { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); grid-auto-rows: minmax(var(--u), auto); gap: var(--gap); }
.tile { position: relative; overflow: hidden; background: var(--surface); padding: 24px; min-width: 0; display: flex; flex-direction: column; }
.tile--navy { background: var(--navy); color: #fff; }
.tile--accent { background: var(--accent); color: var(--accent-ink); }
.tile--tint { background: var(--tint); }
.tile--photo { padding: 0; background: var(--mid); }
.tile--photo img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.c3 { grid-column: span 3; } .c4 { grid-column: span 4; } .c6 { grid-column: span 6; } .c8 { grid-column: span 8; } .c12 { grid-column: 1 / -1; }
.r2 { grid-row: span 2; } .r3 { grid-row: span 3; } .r4 { grid-row: span 4; } .r6 { grid-row: span 6; }

.shot { filter: grayscale(0.25); transition: filter 400ms ease, transform 900ms var(--ease-soft); }
@media (hover: hover) and (pointer: fine) { a:hover > .shot, button:hover > .shot, .tile--photo:hover .shot { filter: none; transform: scale(1.025); } }

.section { padding-block: var(--section) 0; }

/* ---------- inner page banner (sky + turbine strip, mounted by scene.js) ---------- */
.page-hero {
  position: relative; overflow: hidden; isolation: isolate; color: #fff;
  padding: clamp(48px, 8vh, 96px) var(--pad) clamp(130px, 15vw, 210px);
  background: linear-gradient(180deg, var(--sky-top), var(--sky-bot)); /* taste-skill-ignore: the live sky from the previous design */
}
.page-hero h1 { font-size: var(--step-display); line-height: 0.98; letter-spacing: -0.03em; }
.crumbs { padding: 16px var(--pad) 0; font-size: var(--step-small); color: var(--muted); }
.crumbs a { text-decoration: underline; text-underline-offset: 0.2em; }

/* ---------- home: about ---------- */
.about-head { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gap); row-gap: 24px; }
.about-head h2 { grid-column: 1 / 7; }
.about-head p { grid-column: 7 / 13; align-self: end; }
.about-grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: var(--gap); margin-top: 56px; align-items: stretch; }
.about-photo { grid-column: 1 / 8; position: relative; aspect-ratio: 16 / 10; overflow: hidden; background: var(--mid); }
.about-photo img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.paper { padding: 28px; background: var(--navy); color: #fff; font-size: var(--step-body); line-height: 1.45; }
.about-side { grid-column: 8 / 13; display: grid; grid-template-rows: auto 1fr; gap: var(--gap); }
.facts { display: grid; grid-template-columns: 1fr 1fr; align-content: space-between; gap: 24px 16px; padding: 28px; background: var(--tint); font-size: var(--step-small); }
.facts dt { color: var(--muted); margin-bottom: 4px; }
.facts dd { font-family: var(--serif); font-size: var(--step-lead); line-height: 1.15; letter-spacing: -0.02em; }

/* ---------- where we work: big region map ---------- */
.map-big { background: var(--tint); margin-top: 40px; overflow: hidden; }
.region { width: 100%; height: auto; }
.region .land path { fill: var(--surface); }
.region .hit { fill: #3b7fc9; stroke: #eaf1fa; stroke-width: 1.5; }
.region .home { fill: var(--navy); stroke: #eaf1fa; stroke-width: 1.5; }
.region .pin { fill: #fff; }
.region .lbl text { font: 500 22px var(--font); fill: var(--ink); paint-order: stroke; stroke: #fff; stroke-width: 5px; stroke-linejoin: round; }
.countries { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }
.countries li { background: var(--surface); padding: 10px 16px; font-size: var(--step-small); }
.countries li.base { background: var(--navy); color: #fff; }
@media (max-width: 760px) { .region .lbl text { display: none; } }

/* ---------- service tiles (home + services page) ---------- */
.svc, .pj-index { background: var(--navy); }
.svc { color: #fff; text-decoration: none; justify-content: flex-end; padding: 20px; }
.svc .scrim { position: absolute; inset: 0; background: linear-gradient(180deg, rgba(20, 26, 52, 0) 30%, rgba(20, 26, 52, 0.86)); } /* taste-skill-ignore: neutral scrim under text on a photo */
.svc h3, .svc p { position: relative; }
.svc h3 { font-size: var(--step-lead); line-height: 1.05; letter-spacing: -0.02em; }
.svc p { font-size: var(--step-small); max-width: 34ch; margin-top: 6px; color: rgba(255, 255, 255, 0.92); }
.svc.big h3 { font-size: var(--step-head); }
.svc.big p { font-size: var(--step-body); }

/* ---------- work strips ---------- */
.work { display: grid; grid-template-columns: 13% minmax(0, 1fr); gap: 24px; }
.work-rail { position: sticky; top: 24px; align-self: start; display: flex; flex-direction: column; gap: 16px; padding-right: 8px; }
.work-rail h2 { font-size: var(--step-lead); line-height: 1; letter-spacing: -0.02em; }
.filters { display: flex; flex-direction: column; align-items: flex-start; gap: 4px; }
.filters button { font-size: var(--step-body); padding: 8px 0; color: var(--muted); text-align: left; min-height: 40px; }
.filters button[aria-pressed="true"] { color: var(--ink); text-decoration: underline; text-decoration-thickness: 0.09em; text-underline-offset: 0.3em; }
@media (hover: hover) and (pointer: fine) { .filters button:hover { color: var(--ink); } }
.work-list { display: flex; flex-direction: column; gap: 45px; min-width: 0; }
.strip-row { display: block; text-decoration: none; }
.strip-imgs { display: flex; gap: 8px; overflow: hidden; transition: opacity 300ms ease; }
.strip-imgs img { height: 190px; width: auto; flex: none; background: var(--mid); }
.strip-cap { display: flex; justify-content: space-between; gap: 12px; margin-top: 12px; font-size: var(--step-small); }
.strip-cap span:nth-child(2) { color: var(--muted); }
@media (hover: hover) and (pointer: fine) {
  .work-list:hover .strip-imgs { opacity: 0.45; }
  .work-list .strip-row:hover .strip-imgs, .work-list .strip-row:focus-visible .strip-imgs { opacity: 1; }
}

/* ---------- cold to live ---------- */
.flow-head { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gap); row-gap: 20px; }
.flow-head h2 { grid-column: 1 / 7; }
.flow-head p { grid-column: 7 / 13; align-self: end; }
.flow-art { margin-top: 56px; }
.flow-art svg { width: 100%; height: auto; }
.flow-art .sq-a { fill: #a9a59b; }
.flow-art .sq-b { fill: #d2cdc1; }
.flow-art .sq-n { fill: var(--navy); }
.flow-art .sq-c { fill: var(--accent); }
.step-icon { display: none; }
.step-icon .sq-a { fill: #a9a59b; } .step-icon .sq-n { fill: var(--navy); } .step-icon .sq-c { fill: var(--accent); }
.flow-art .vertical { display: none; }
.flow-steps { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--gap); margin-top: 24px; }
.flow-steps h3 { font-size: var(--step-lead); letter-spacing: -0.02em; margin-bottom: 8px; }

/* ---------- stats ---------- */
.stats { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: var(--gap); align-items: start; }
.stat { padding: 28px; display: flex; flex-direction: column; justify-content: space-between; }
.stat b { font-family: var(--serif); font-size: var(--step-display); font-weight: 500; line-height: 0.9; letter-spacing: -0.03em; font-variant-numeric: tabular-nums; }
.stat--2 b, .stat--3 b { font-size: var(--step-head); }
.stat--1 { grid-column: 1 / 7; grid-row: 1 / span 2; min-height: clamp(380px, 38vw, 520px); background: var(--accent); color: #fff; }
.stat--2 { grid-column: 7 / 10; grid-row: 1; margin-top: clamp(130px, 11vw, 160px); min-height: clamp(220px, 20vw, 280px); background: var(--tint); }
.stat--3 { grid-column: 10 / 13; grid-row: 1; margin-top: clamp(200px, 17vw, 250px); min-height: clamp(170px, 15vw, 210px); background: var(--navy); color: #fff; }
.stats-head { grid-column: 7 / 13; grid-row: 1; align-self: start; z-index: 1; }
.stats-head h2 { font-size: var(--step-head); line-height: 1; letter-spacing: -0.025em; max-width: 12ch; }

/* ---------- calculator ---------- */
.calc { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: var(--gap); }
.calc-in { grid-column: 1 / 6; padding: 28px; display: flex; flex-direction: column; gap: 22px; }
.calc-out { grid-column: 6 / 13; padding: 28px; display: flex; flex-direction: column; gap: 22px; }
.calc h2 { font-size: var(--step-head); line-height: 1; letter-spacing: -0.025em; max-width: 11ch; }
.calc-field label { display: flex; justify-content: space-between; gap: 12px; margin-bottom: 8px; }
.calc-field output { color: var(--accent); font-weight: 500; font-variant-numeric: tabular-nums; }
.calc-field input[type="range"] { width: 100%; height: 32px; accent-color: var(--accent); }
.calc-field input[type="number"] { width: 7rem; min-height: 3rem; padding: 0 12px; background: #fff; border: 0; font-size: 1rem; }
.calc-field--inline { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.calc-note { font-size: 1rem; color: var(--muted); max-width: 52ch; }
.calc-panels { display: grid; grid-template-columns: repeat(15, minmax(0, 1fr)); gap: 4px; }
.calc-panels i { aspect-ratio: 1; background: var(--mid); transition: background-color 250ms ease; }
.calc-panels i.on { background: var(--accent); }
.calc-count { font-size: var(--step-small); color: var(--muted); }
.calc-stats { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.calc-stats div { background: #fff; padding: 18px; }
.calc-stats dt { font-size: var(--step-small); color: var(--muted); }
.calc-stats dd { font-family: var(--serif); font-size: var(--step-lead); letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.calc-stats small { font-family: var(--font); font-size: var(--step-small); color: var(--muted); }

/* ---------- close row ---------- */
.close { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 8fr) minmax(0, 2fr); gap: 12px; margin-top: var(--section); }
.close-side { min-height: 360px; position: relative; overflow: hidden; background: var(--tint); }
.close-side img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.close-main { background: var(--navy); color: #fff; min-height: 360px; padding: 40px; display: flex; flex-direction: column; justify-content: center; gap: 18px; align-items: flex-start; }
.close-main h2 { font-size: var(--step-head); line-height: 1; letter-spacing: -0.025em; max-width: 14ch; }
.close-main p { max-width: 40ch; }
.close-main .row { display: flex; gap: 20px; align-items: center; flex-wrap: wrap; }

/* ---------- footer ---------- */
.foot { margin-top: var(--section); padding-bottom: 24px; }
.mark { display: flex; gap: 4px; align-items: flex-end; height: 34svh; min-height: 240px; }
.mark span { flex: 1; display: grid; place-items: center; font-family: var(--serif); font-size: min(14vw, 26svh); font-weight: 500; line-height: 1; letter-spacing: -0.04em; height: var(--h); }
.mark span:first-child { flex: 0.6; }
.mark span:last-child { flex: 1.1; }
.foot-brand { display: grid; grid-template-columns: auto minmax(0, 46ch); justify-content: start; gap: 32px; align-items: center; margin-top: 56px; }
.foot-brand img { height: 96px; width: auto; }
@media (max-width: 760px) { .foot-brand { grid-template-columns: minmax(0, 1fr); } }
.foot-grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 24px var(--gap); margin-top: 40px; font-size: 1rem; }
.foot-grid .cols { grid-column: 1 / 9; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
.foot-grid ul { display: grid; gap: 2px; }
.foot-grid a { display: inline-block; padding: 7px 0; }
.foot-grid .contact { grid-column: 9 / 13; display: grid; gap: 14px; align-content: start; }
.foot-grid h3 { font-family: var(--font); font-size: var(--step-small); font-weight: 400; color: var(--muted); margin-bottom: 6px; }
.foot-base { display: flex; justify-content: space-between; align-items: center; gap: 16px; margin-top: 40px; font-size: var(--step-small); flex-wrap: wrap; }

/* ---------- projects page ---------- */
.pj-title { background: var(--surface); padding: 28px; display: flex; flex-direction: column; justify-content: space-between; grid-column: span 6; grid-row: span 2; }
.pj-title h2 { font-size: var(--step-head); line-height: 1; letter-spacing: -0.025em; }
.pj-index { color: #fff; text-decoration: none; display: block; }
.pj-index .scrim { position: absolute; inset: 0; background: linear-gradient(180deg, rgba(20, 26, 52, 0) 35%, rgba(20, 26, 52, 0.85)); } /* taste-skill-ignore: neutral scrim under caption text on a photo */
.pj-index .cap { position: absolute; left: 14px; right: 14px; bottom: 12px; display: grid; gap: 2px; font-size: var(--step-small); line-height: 1.25; }
.pj-index .cap b { font-weight: 500; font-size: 1rem; }
.pj-intro { padding-top: calc(var(--section) / 2); }
.pj-block { margin-top: calc(var(--section) / 2); }
.pj-text { grid-column: span 3; grid-row: span 6; padding: 24px; display: flex; flex-direction: column; gap: 14px; overflow: visible; }
.pj-text h2 { font-size: 2rem; line-height: 1; letter-spacing: -0.025em; }
.pj-meta { color: var(--muted); font-size: var(--step-small); }
.pj-text .lead { font-size: var(--step-body); line-height: 1.3; }
.pj-text p { font-size: 1rem; }
.pj-scope { display: flex; flex-wrap: wrap; gap: 6px; margin-top: auto; }
.pj-scope li { background: #fff; padding: 5px 10px; font-size: var(--step-small); }
.pj-tag { color: var(--accent); font-family: var(--serif); font-size: 1.125rem; line-height: 1.3; }
.ph { padding: 0; border: 0; cursor: zoom-in; position: relative; overflow: hidden; background: var(--mid); display: block; min-width: 0; }
.ph img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.ph .count { position: absolute; left: 12px; bottom: 12px; background: var(--bg); color: var(--ink); padding: 6px 10px; font-size: var(--step-small); }
.ph.k-hero { grid-column: span 6; grid-row: span 6; }
.ph.k-tall { grid-column: span 3; grid-row: span 6; }
.ph.k-big { grid-column: span 6; grid-row: span 2; }
.ph.k-small { grid-column: span 3; grid-row: span 2; }
.pj-block.flip .pj-text { order: 3; }
.pj-block.flip .k-hero { order: 1; }
.pj-block.flip .k-tall { order: 2; }
.pj-block.flip .ph:not(.k-hero):not(.k-tall) { order: 4; }

/* ---------- about / contact ---------- */
.two { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--gap); }
.two .tile { padding: 28px; gap: 14px; min-height: 280px; }
.two h2, .three h2 { font-size: var(--step-lead); letter-spacing: -0.02em; line-height: 1.1; }
.three { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--gap); }
.three .tile { padding: 28px; gap: 12px; min-height: 260px; justify-content: space-between; text-decoration: none; }
.three .big { font-family: var(--serif); font-size: var(--step-lead); line-height: 1.15; letter-spacing: -0.02em; overflow-wrap: anywhere; }
.head-block { display: grid; gap: 20px; max-width: 70ch; }
.head-block:has(.lead) { max-width: none; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 48px; align-items: end; }

/* ---------- figures and process rows ---------- */
.figs { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--gap); }
.figs .tile { padding: 28px; min-height: 240px; gap: 10px; justify-content: space-between; }
.figs b { font-family: var(--serif); font-size: var(--step-head); font-weight: 500; line-height: 1; letter-spacing: -0.025em; font-variant-numeric: tabular-nums; }
.figs h3 { font-size: var(--step-lead); letter-spacing: -0.02em; }
@media (max-width: 1100px) { .figs { grid-template-columns: repeat(2, minmax(0, 1fr)); } .figs .tile { justify-content: flex-start; gap: 14px; min-height: 180px; } }
@media (max-width: 520px) { .figs { grid-template-columns: minmax(0, 1fr); } .figs .tile { min-height: 160px; } }

/* ---------- service pages ---------- */
.service-layout { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 9fr); gap: 48px; align-items: start; }
.side-nav { position: sticky; top: 24px; display: grid; gap: 2px; }
.side-nav h2 { font-family: var(--font); font-size: var(--step-small); font-weight: 400; color: var(--muted); margin-bottom: 8px; }
.side-nav > a { padding: 12px 14px; text-decoration: none; background: var(--surface); transition: background-color 180ms ease, color 180ms ease; }
.side-nav > a[aria-current="page"] { background: var(--navy); color: #fff; }
@media (hover: hover) and (pointer: fine) { .side-nav > a:hover:not([aria-current]) { background: var(--tint); } }
.side-cta { margin-top: 16px; padding: 20px; background: var(--tint); display: grid; gap: 12px; justify-items: start; }
.service-body { display: grid; gap: 22px; max-width: 900px; }
.service-body h2 { font-size: var(--step-head); line-height: 1; letter-spacing: -0.025em; }
.service-body h3 { font-size: var(--step-lead); letter-spacing: -0.02em; margin-top: 12px; }
.service-body p { color: var(--ink); }
.service-body > img, .service-body .gallery-row img { width: 100%; height: auto; max-height: 360px; object-fit: cover; }
.num-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--gap); counter-reset: n; }
.num-list li { background: var(--surface); padding: 20px; }
.num-list strong { display: block; font-family: var(--serif); font-weight: 500; font-size: 1.25rem; margin-bottom: 4px; }
.gallery-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: var(--gap); align-items: stretch; }
.gallery-row img { height: 100%; min-height: 170px; }
.gallery-row--split { grid-template-columns: minmax(0, 1fr) minmax(0, 1.4fr); align-items: center; gap: 24px; }
.feature-tile { background: var(--tint); padding: 20px; }
.feature-tile .card-icon { display: none; }
.feature-tile h4 { font-family: var(--serif); font-weight: 500; font-size: 1.25rem; margin: 0 0 6px; }
.bar-row { display: grid; gap: 8px; }
.bar-label { display: flex; justify-content: space-between; gap: 12px; }
.bar-track { background: var(--mid); height: 14px; overflow: hidden; }
.bar-fill { height: 100%; background: var(--accent); transform: scaleX(0); transform-origin: left; }
.faq-item { background: var(--surface); margin-bottom: var(--gap); }
.faq-q { display: flex; justify-content: space-between; gap: 16px; width: 100%; text-align: left; padding: 18px 20px; font-weight: 500; min-height: 56px; }
.faq-q .plus { font-family: var(--serif); font-size: 1.5rem; line-height: 1; transition: transform 200ms var(--ease-out); }
.faq-item.open .plus { transform: rotate(45deg); }
.faq-a { display: none; padding: 0 20px 20px; }
.faq-item.open .faq-a { display: block; }

/* ---------- lightbox ---------- */
.lightbox { position: fixed; inset: 0; z-index: 100; background: rgba(250, 248, 245, 0.97); display: grid; grid-template-columns: 72px minmax(0, 1fr) 72px; align-items: center; padding: 24px; }
.lightbox[hidden] { display: none; }
.lightbox figure { display: grid; gap: 12px; justify-items: center; min-width: 0; }
.lightbox img { max-width: 100%; max-height: 80dvh; object-fit: contain; }
.lightbox figcaption { color: var(--muted); font-size: var(--step-small); text-align: center; }
.lb-btn { width: 48px; height: 48px; background: var(--navy); color: #fff; font-size: 1.4rem; justify-self: center; transition: background-color 180ms ease, transform 140ms var(--ease-out); }
.lb-btn:active { transform: scale(0.95); }
.lb-btn:hover { background: var(--accent); }
.lb-close { position: absolute; top: 20px; right: 20px; }

/* ---------- tablet ---------- */
@media (max-width: 1100px) {
  .work { grid-template-columns: minmax(0, 1fr); }
  .work-rail { position: static; flex-direction: row; justify-content: space-between; align-items: center; }
  .filters { flex-direction: row; gap: 18px; }
  .about-photo { grid-column: 1 / -1; }
  .about-side { grid-column: 1 / -1; grid-template-columns: 1fr 1fr; grid-template-rows: none; }
  .calc-in, .calc-out { grid-column: 1 / -1; }
  .service-layout { grid-template-columns: minmax(0, 1fr); gap: 24px; }
  .side-nav { position: static; order: 2; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); }
  .side-nav h2 { grid-column: 1 / -1; }
  .side-cta { display: none; }
  .pj-title { grid-column: 1 / -1; grid-row: auto; min-height: 220px; }
  .board > .pj-index { grid-column: span 6; grid-row: span 3; }
  .pj-text { grid-column: 1 / -1; grid-row: auto; }
  .pj-text h2 { font-size: var(--step-head); }
  .ph.k-hero { grid-column: 1 / -1; grid-row: span 4; }
  .ph.k-tall, .ph.k-small, .ph.k-big { grid-column: span 6; grid-row: span 3; }
  .ph.m-wide { grid-column: 1 / -1; }
  .pj-block.flip .pj-text, .pj-block.flip .k-hero, .pj-block.flip .k-tall, .pj-block.flip .ph:not(.k-hero):not(.k-tall) { order: 0; }
  .svc { grid-column: span 6; grid-row: span 3; }
  .svc.big { grid-column: 1 / -1; grid-row: span 4; }
}

/* ---------- phone: its own board of two columns ---------- */
@media (max-width: 760px) {
  :root { --u: 22vw; }
  .c3, .c4, .c6, .c8 { grid-column: 1 / -1; }
  .head-block:has(.lead) { grid-template-columns: minmax(0, 1fr); }
  .flow-head p, .about-head p { grid-column: 1 / -1; }
  .about-head h2, .about-head p { grid-column: 1 / -1; }
  .about-grid { margin-top: 40px; }
  .about-photo { aspect-ratio: 4 / 3; }
  .about-side { grid-template-columns: 1fr; }

  .strip-imgs { flex-wrap: wrap; }
  .strip-imgs img { height: 120px; width: calc(50% - 4px) !important; object-fit: cover; flex: none; }
  .strip-imgs img:nth-child(n+5) { display: none; }
  .strip-cap span:nth-child(2) { display: none; }

  .flow-head h2, .flow-head p { grid-column: 1 / -1; }
  .flow-art { display: block; }
  .flow-art .horizontal { display: none; }
  .flow-steps { grid-template-columns: minmax(0, 1fr); margin-top: 0; }
  .flow-steps > div { display: grid; grid-template-columns: 56px minmax(0, 1fr); column-gap: 16px; align-items: start; padding: 20px; background: var(--surface); }
  .flow-steps > div:nth-child(2) { background: var(--tint); }
  .flow-steps > div:nth-child(3) { background: var(--navy); color: #fff; }
  .step-icon { display: grid; place-items: center; width: 56px; height: 56px; grid-row: 1 / span 2; background: var(--bg); }

  .stats { grid-template-columns: 1fr 1fr; gap: 6px; }
  .stats-head { grid-column: 1 / -1; grid-row: 1; }
  .stats-head h2 { max-width: none; }
  .stat--1 { grid-column: 1 / -1; grid-row: 2; min-height: 56vw; }
  .stat--2, .stat--3 { grid-row: 3; min-height: 44vw; }
  .stat--2 { grid-column: 1; margin-top: 0; }
  .stat--3 { grid-column: 2; margin-top: 32px; }
  .stat { padding: 18px; justify-content: flex-start; gap: 14px; }

  .calc-in, .calc-out { padding: 20px; }
  .calc-panels { grid-template-columns: repeat(10, minmax(0, 1fr)); }

  .close { grid-template-columns: 1fr 1fr; gap: 8px; }
  .close-main { grid-column: 1 / -1; grid-row: 1; min-height: 300px; padding: 24px; }
  .close-side { min-height: 120px; }
  .close-main .button { align-self: stretch; }

  .mark { height: auto; min-height: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 4px; align-items: end; }
  .mark span { height: calc(var(--h) * 0.24 * 100svh / 100); font-size: 26vw; }
  .foot-grid .cols { grid-column: 1 / -1; grid-template-columns: 1fr 1fr; }
  .foot-grid .contact { grid-column: 1 / -1; }

  .two, .three { grid-template-columns: minmax(0, 1fr); }
  .num-list { grid-template-columns: minmax(0, 1fr); }
  .gallery-row--split { grid-template-columns: minmax(0, 1fr); }

  .lightbox { grid-template-columns: minmax(0, 1fr); padding: 16px 12px 84px; }
  .lb-btn:not(.lb-close) { position: absolute; bottom: 20px; }
  .lb-prev { left: calc(50% - 56px); }
  .lb-next { right: calc(50% - 56px); }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .shot, .button, .strip-imgs { transition: none; }
}

.svc .more { position: relative; margin-top: 12px; font-size: var(--step-small); font-weight: 500; }
@media (hover: hover) and (pointer: fine) { .svc:hover .more { text-decoration: underline; text-underline-offset: 0.25em; } }
