/* Layout: plant-drawing feel. Wide hero with a live schematic, then content on a 12-col grid with spec "data plates". */
:root {
  --ink: #16211f;          /* text, header */
  --body: #33403d;
  --muted: #5d6b67;
  --paper: #f6f7f4;        /* page ground, slightly green-grey */
  --panel: #e9ede8;        /* filter-felt panel */
  --line: #cfd6d1;
  --green: #0e5a4e;        /* process green, the brand colour */
  --green-ink: #0a3f37;
  --amber: #e2a11b;        /* signal amber, used sparingly */
  --on-green: #f2f7f4;
  --card: #ffffff;
  --dust: #a58a5c;
  --display: "Big Shoulders Display", "Arial Narrow", "Roboto Condensed", sans-serif;
  --sans: "IBM Plex Sans", "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, "SFMono-Regular", Consolas, monospace;
  --wrap: 1180px;
  --gutter: clamp(16px, 4vw, 40px);
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --ink: #e7eeea; --body: #c3cdc9; --muted: #95a39e; --paper: #101614; --panel: #18211e;
    --line: #2a3632; --green: #3fae98; --green-ink: #0b2c26; --amber: #f0b43a; --on-green: #08130f;
    --card: #151d1a; --dust: #c8a979; color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --ink: #e7eeea; --body: #c3cdc9; --muted: #95a39e; --paper: #101614; --panel: #18211e;
  --line: #2a3632; --green: #3fae98; --green-ink: #0b2c26; --amber: #f0b43a; --on-green: #08130f;
  --card: #151d1a; --dust: #c8a979; color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body { margin: 0; background: var(--paper); color: var(--body); font: 400 1.0625rem/1.65 var(--sans); }
img, svg { max-width: 100%; height: auto; }
a { color: var(--green); text-underline-offset: 3px; }
a:hover { color: var(--ink); }
:focus-visible { outline: 3px solid var(--amber); outline-offset: 2px; }
h1, h2, h3 { color: var(--ink); font-family: var(--display); font-weight: 800; line-height: 1.02; text-wrap: balance; margin: 0; letter-spacing: 0.005em; }
h1 { font-size: clamp(2.6rem, 6.2vw, 4.6rem); text-transform: uppercase; }
h2 { font-size: clamp(2rem, 3.8vw, 2.9rem); text-transform: uppercase; }
h3 { font-size: 1.55rem; }
p { margin: 0; max-width: 68ch; }
.wrap { max-width: var(--wrap); margin-inline: auto; padding-inline: var(--gutter); }
.eyebrow { font: 600 0.78rem/1 var(--mono); letter-spacing: 0.12em; text-transform: uppercase; color: var(--green); }
.lead { font-size: 1.2rem; color: var(--body); }
.stack { display: grid; gap: 1.1rem; align-content: start; min-width: 0; }
.stack-lg { display: grid; gap: 2rem; }
.skip { position: absolute; left: -9999px; }
.skip:focus { left: 16px; top: 16px; background: var(--card); padding: 8px 12px; z-index: 50; }

/* Header */
.site-header { position: sticky; top: env(safe-area-inset-top, 0px); z-index: 20; background: var(--paper); border-bottom: 1px solid var(--line); }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: 68px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ink); }
.brand svg { width: 34px; height: 34px; flex: none; }
.brand-name { font: 800 1.4rem/1 var(--display); letter-spacing: 0.03em; text-transform: uppercase; white-space: nowrap; }
.brand-sub { display: block; white-space: nowrap; font: 500 0.6rem/1.2 var(--mono); letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); }
.nav { display: flex; align-items: center; gap: 0.25rem; }
.nav a { white-space: nowrap; text-decoration: none; color: var(--ink); font-weight: 500; font-size: 0.95rem; padding: 0.5rem 0.7rem; border-radius: 4px; }
.nav a:hover, .nav a[aria-current="page"] { background: var(--panel); }
.nav .has-menu { position: relative; }
.nav .menu { position: absolute; left: 0; top: 100%; min-width: 270px; background: var(--card); border: 1px solid var(--line); box-shadow: 0 12px 30px rgba(0,0,0,.12); padding: 0.4rem; display: none; }
.nav .has-menu:hover .menu, .nav .has-menu:focus-within .menu { display: grid; }
.nav .menu a { padding: 0.55rem 0.7rem; }
.btn { display: inline-flex; align-items: center; gap: 0.5rem; background: var(--green); color: var(--on-green); border: 0; border-radius: 4px; padding: 0.8rem 1.2rem; font: 600 1rem/1 var(--sans); text-decoration: none; cursor: pointer; }
.btn:hover { background: var(--ink); color: var(--paper); }
.btn-ghost { background: transparent; color: var(--ink); box-shadow: inset 0 0 0 2px var(--ink); }
.btn-ghost:hover { background: var(--ink); color: var(--paper); }
.nav .btn { margin-left: 0.5rem; color: var(--on-green); }
.nav .btn:hover { color: var(--paper); background: var(--ink); }
.menu-toggle { display: none; background: none; border: 2px solid var(--ink); color: var(--ink); border-radius: 4px; padding: 0.45rem 0.7rem; font: 600 0.9rem var(--sans); }
@media (max-width: 1300px) {
  .menu-toggle { display: inline-block; }
  .nav { display: none; position: absolute; left: 0; right: 0; top: 100%; background: var(--paper); border-bottom: 1px solid var(--line); flex-direction: column; align-items: stretch; padding: 0.5rem var(--gutter) 1rem; max-height: calc(100vh - 70px); overflow-y: auto; }
  .nav.open { display: flex; }
  .nav .menu { position: static; display: grid; border: 0; box-shadow: none; padding: 0 0 0 1rem; background: transparent; min-width: 0; }
  .nav .btn { margin: 0.5rem 0 0; justify-content: center; }
}

/* Hero */
.hero { border-bottom: 1px solid var(--line); background: linear-gradient(180deg, var(--paper), var(--panel)); }
.hero .wrap { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr); gap: clamp(1.5rem, 4vw, 3.5rem); align-items: center; padding-block: clamp(2.5rem, 6vw, 5rem); }
.hero h1 span { color: var(--green); }
.hero-actions { display: flex; flex-wrap: wrap; gap: 0.75rem; }
.schematic { width: 100%; }
@media (max-width: 860px) { .hero .wrap { grid-template-columns: 1fr; } }

/* Page header for inner pages */
.page-head { border-bottom: 1px solid var(--line); background: var(--panel); }
.page-head .wrap { padding-block: clamp(2rem, 5vw, 3.5rem); display: grid; gap: 1rem; }
.crumbs { font: 500 0.8rem var(--mono); color: var(--muted); display: flex; flex-wrap: wrap; gap: 0.4rem; }
.crumbs a { color: var(--muted); }

/* Spec plate */
.plate { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); border: 2px solid var(--ink); background: var(--card); }
.plate div { padding: 1rem 1.1rem; border-right: 1px solid var(--line); display: grid; gap: 0.3rem; }
.plate div:last-child { border-right: 0; }
.plate b { font: 800 2.1rem/1 var(--display); color: var(--ink); font-variant-numeric: tabular-nums; }
.plate span { font: 500 0.74rem/1.35 var(--mono); text-transform: uppercase; letter-spacing: 0.06em; color: var(--muted); }
@media (max-width: 760px) { .plate { grid-template-columns: repeat(2, minmax(0, 1fr)); } .plate div:nth-child(2) { border-right: 0; } .plate div:nth-child(-n+2) { border-bottom: 1px solid var(--line); } }

/* Sections */
.section { padding-block: clamp(3rem, 7vw, 5.5rem); }
.section-alt { background: var(--panel); }
.section-head { display: grid; gap: 0.8rem; margin-bottom: 2rem; }
.grid-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(1.5rem, 4vw, 3rem); }
.grid-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1.25rem; }
@media (max-width: 860px) { .grid-2, .grid-3 { grid-template-columns: 1fr; } }
.type-card { display: grid; grid-template-rows: auto 1fr auto; gap: 1rem; padding: 1.4rem; background: var(--card); border: 1px solid var(--line); border-top: 4px solid var(--green); text-decoration: none; color: var(--body); }
.type-card:hover { border-color: var(--ink); color: var(--body); }
.type-card h3 { color: var(--ink); }
.type-card .more { font: 600 0.9rem var(--sans); color: var(--green); }
.type-card svg { width: 64px; height: 64px; }
.prose { display: grid; gap: 1.1rem; min-width: 0; }
.prose h2 { margin-top: 1.2rem; }
.prose h3 { margin-top: 0.6rem; }
.prose ul { margin: 0; padding-left: 1.2rem; display: grid; gap: 0.45rem; max-width: 66ch; }
.ticks { list-style: none; padding: 0; margin: 0; display: grid; gap: 0.6rem; }
.ticks li { padding-left: 1.6rem; position: relative; }
.ticks li::before { content: ""; position: absolute; left: 0; top: 0.55em; width: 0.8rem; height: 0.35rem; border-left: 2px solid var(--green); border-bottom: 2px solid var(--green); transform: rotate(-45deg); }
.aside { background: var(--card); border: 1px solid var(--line); padding: 1.4rem; display: grid; gap: 0.8rem; align-content: start; }
.aside h3 { font-size: 1.3rem; }
.table-wrap { overflow-x: auto; border: 1px solid var(--line); background: var(--card); }
table { border-collapse: collapse; width: 100%; font-size: 0.95rem; }
th, td { text-align: left; padding: 0.7rem 0.9rem; border-bottom: 1px solid var(--line); vertical-align: top; }
th { font: 600 0.75rem/1.3 var(--mono); text-transform: uppercase; letter-spacing: 0.06em; color: var(--muted); background: var(--panel); }
td.num { font-family: var(--mono); font-variant-numeric: tabular-nums; white-space: nowrap; }
.note { font-size: 0.9rem; color: var(--muted); }

/* Steps (a real sequence) */
.steps { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1.25rem; counter-reset: s; }
.steps li { counter-increment: s; display: grid; gap: 0.5rem; padding-top: 1rem; border-top: 2px solid var(--ink); }
.steps li::before { content: counter(s, decimal-leading-zero); font: 600 0.85rem var(--mono); color: var(--green); }
.steps b { font: 800 1.35rem/1.1 var(--display); color: var(--ink); text-transform: uppercase; }
.steps-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: 2rem; }
@media (max-width: 860px) { .steps { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 480px) { .steps { grid-template-columns: 1fr; } }

/* Applications list */
.apps { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1px; background: var(--line); border: 1px solid var(--line); }
.apps-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
@media (max-width: 760px) { .apps, .apps-3 { grid-template-columns: 1fr; } }
.apps > * { background: var(--card); padding: 1.25rem; display: grid; gap: 0.4rem; align-content: start; }
.apps h3 { font-size: 1.3rem; }

/* FAQ */
.faq { display: grid; gap: 0; border-top: 1px solid var(--line); }
.faq details { border-bottom: 1px solid var(--line); padding: 1rem 0; }
.faq summary { cursor: pointer; font-weight: 600; color: var(--ink); list-style: none; display: flex; justify-content: space-between; gap: 1rem; }
.faq summary::after { content: "+"; font: 600 1.3rem/1 var(--mono); color: var(--green); }
.faq details[open] summary::after { content: "–"; }
.faq details p { margin-top: 0.7rem; }

/* Projects */
.projects { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 1.25rem; }
.project { background: var(--card); border: 1px solid var(--line); padding: 1.25rem; display: grid; gap: 0.5rem; align-content: start; }
.project time { font: 500 0.8rem var(--mono); color: var(--muted); }
.project h3 { font-size: 1.35rem; }

/* CTA band + enquiry */
.cta-band { background: var(--green-ink); color: #dfe9e5; }
.cta-band h2, .cta-band h3 { color: #ffffff; }
.cta-band .eyebrow { color: var(--amber); }
.cta-band a { color: #ffffff; }
.cta-band .wrap { display: grid; grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr); gap: clamp(1.5rem, 5vw, 4rem); padding-block: clamp(3rem, 7vw, 5rem); }
@media (max-width: 860px) { .cta-band .wrap { grid-template-columns: 1fr; } }
.contact-lines { display: grid; gap: 0.6rem; font-size: 1.05rem; }
.contact-lines span { display: block; font: 500 0.72rem var(--mono); letter-spacing: 0.1em; text-transform: uppercase; color: #9fbab2; }
form.enquiry { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.9rem; background: #ffffff; color: #16211f; padding: clamp(1.1rem, 3vw, 1.75rem); border-radius: 4px; }
form.enquiry .full { grid-column: 1 / -1; }
form.enquiry label { display: grid; gap: 0.3rem; font: 600 0.82rem var(--sans); color: #33403d; }
form.enquiry input, form.enquiry select, form.enquiry textarea { font: 400 1rem var(--sans); padding: 0.65rem 0.75rem; border: 1px solid #b9c3be; border-radius: 3px; background: #fbfcfb; color: #16211f; width: 100%; }
form.enquiry textarea { min-height: 120px; resize: vertical; }
form.enquiry .btn { justify-self: start; background: #0e5a4e; color: #ffffff; }
form.enquiry .btn:hover { background: #16211f; }
form.enquiry .form-status { grid-column: 1 / -1; font-weight: 600; color: #0e5a4e; }
.hp { position: absolute; left: -9999px; }
@media (max-width: 560px) { form.enquiry { grid-template-columns: 1fr; } }

/* Footer */

:root .site-footer { background: #0c1412; color: #b8c6c1; }
.site-footer .wrap { padding-block: 3rem; display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 2rem; }
.site-footer h4 { margin: 0 0 0.8rem; font: 600 0.75rem var(--mono); letter-spacing: 0.1em; text-transform: uppercase; color: #ffffff; }
.site-footer a { color: #b8c6c1; text-decoration: none; }
.site-footer a:hover { color: #ffffff; text-decoration: underline; }
.site-footer ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 0.45rem; font-size: 0.95rem; }
.site-footer .brand { color: #ffffff; }
.site-footer .brand-sub { color: #8aa29a; }
.legal { border-top: 1px solid #22302c; }
.legal .wrap { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 0.5rem; padding-block: 1.1rem; font-size: 0.85rem; grid-template-columns: none; }
@media (max-width: 860px) { .site-footer .wrap { grid-template-columns: 1fr 1fr; } }
@media (max-width: 480px) { .site-footer .wrap { grid-template-columns: 1fr; } }

/* Schematic animation */
.sch-line { stroke: var(--ink); fill: none; stroke-width: 2; }
.sch-fill { fill: var(--card); stroke: var(--ink); stroke-width: 2; }
.sch-bag { fill: var(--panel); stroke: var(--green); stroke-width: 2; }
.sch-label { font: 600 11px var(--mono); fill: var(--muted); letter-spacing: 0.06em; }
.sch-amber { fill: var(--amber); }
.sch-green { fill: var(--green); }
.dust { fill: var(--dust); }
.clean { fill: none; stroke: var(--green); stroke-width: 2.5; stroke-dasharray: 6 8; animation: flow 1.6s linear infinite; }
.dust-in { animation: drift 3.2s linear infinite; }
.dust-in:nth-child(2) { animation-delay: -0.8s; } .dust-in:nth-child(3) { animation-delay: -1.6s; } .dust-in:nth-child(4) { animation-delay: -2.4s; }
.dust-fall { animation: fall 2.4s ease-in infinite; }
.dust-fall:nth-child(2) { animation-delay: -0.6s; } .dust-fall:nth-child(3) { animation-delay: -1.2s; } .dust-fall:nth-child(4) { animation-delay: -1.8s; }
.pulse { animation: pulse 2.4s ease-out infinite; transform-box: fill-box; transform-origin: center top; }
@keyframes flow { to { stroke-dashoffset: -28; } }
@keyframes drift { from { transform: translateX(-60px); opacity: 0; } 20% { opacity: 1; } to { transform: translateX(70px); opacity: 0.2; } }
@keyframes fall { from { transform: translateY(0); opacity: 0; } 20% { opacity: 1; } to { transform: translateY(70px); opacity: 0; } }
@keyframes pulse { 0%, 70% { opacity: 0; transform: scaleY(0.2); } 78% { opacity: 1; transform: scaleY(1); } 100% { opacity: 0; transform: scaleY(1); } }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .clean, .dust-in, .dust-fall, .pulse { animation: none; }
  .pulse { opacity: 0; }
}

/* Photos */
.photo { margin: 0; display: grid; gap: 0.5rem; }
.photo img { width: 100%; aspect-ratio: 2 / 1; object-fit: cover; display: block; background: var(--panel); border: 1px solid var(--line); }
.photo figcaption { font: 500 0.78rem/1.4 var(--mono); color: var(--muted); }
.ph-box { aspect-ratio: 2 / 1; max-width: 100%; display: grid; place-items: center; background: repeating-linear-gradient(135deg, var(--panel) 0 12px, var(--card) 12px 24px); border: 1px dashed var(--line); }
.ph-box span { font: 600 0.75rem var(--mono); letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); background: var(--card); padding: 0.3rem 0.6rem; }
.project .photo img, .project .ph-box { aspect-ratio: 16 / 9; }
.photo-row { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1.25rem; }
@media (max-width: 860px) { .photo-row { grid-template-columns: 1fr; } }
.project figcaption { display: none; }
