/* PolyQuip demo site. Plain CSS, mobile first, no external fonts. */
:root {
  --bg: #0e1012;
  --bg-2: #15181b;
  --panel: #1b1f23;
  --line: #2a3036;
  --text: #e8eaec;
  --muted: #a3abb3;
  --green: #4fbf5a;
  --green-dk: #2f8a3a;
  --amber: #f2b632;
  --radius: 10px;
  --wrap: 1180px;
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.55;
  overflow-x: hidden;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--green); }
h1, h2, h3 { line-height: 1.15; margin: 0 0 .5em; letter-spacing: -.01em; }
h2 { font-size: clamp(1.7rem, 6vw, 2.6rem); }
h3 { font-size: 1.25rem; }
p { margin: 0 0 1em; }
section[id], header[id] { scroll-margin-top: 64px; }

.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 20px; }
.eyebrow {
  display: inline-block;
  font-size: .78rem;
  font-weight: 700;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--amber);
  margin-bottom: .8em;
}
.lead { font-size: 1.12rem; color: #cfd4d9; max-width: 46em; }
.muted { color: var(--muted); }

/* ---------- top bar ---------- */
.topbar {
  position: sticky; top: 0; z-index: 20;
  background: rgba(14, 16, 18, .94);
  border-bottom: 1px solid var(--line);
  -webkit-backdrop-filter: saturate(1.4) blur(8px);
  backdrop-filter: saturate(1.4) blur(8px);
}
.topbar .wrap { display: flex; align-items: center; gap: 14px; min-height: 56px; }
.mark {
  font-weight: 800; font-size: 1.35rem; color: var(--text); text-decoration: none;
  letter-spacing: -.02em; white-space: nowrap; flex: 0 0 auto;
}
.mark i { font-style: italic; color: var(--green); }
.nav {
  display: flex; gap: 4px; overflow-x: auto; flex: 1 1 auto; min-width: 0;
  scrollbar-width: none; -webkit-overflow-scrolling: touch;
}
.nav::-webkit-scrollbar { display: none; }
.nav a {
  color: var(--muted); text-decoration: none; font-size: .9rem; font-weight: 600;
  padding: 8px 10px; border-radius: 6px; white-space: nowrap;
}
.nav a:hover, .nav a:focus { color: var(--text); background: var(--panel); }
.nav a.cta { color: #0e1012; background: var(--green); }

/* ---------- hero ---------- */
.hero { position: relative; min-height: 88vh; display: flex; align-items: flex-end; overflow: hidden; }
.hero > img {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 40% 50%;
}
.hero::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(14,16,18,.05) 0%, rgba(14,16,18,.42) 40%, rgba(14,16,18,.97) 100%);
}
.hero .wrap { position: relative; z-index: 1; padding-top: 120px; padding-bottom: 44px; }
.hero h1 { font-size: clamp(2.1rem, 9vw, 4.2rem); max-width: 14em; }
.hero .lead { color: #e1e5e8; }
.btns { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 1.4em; }
.btn {
  display: inline-block; padding: 13px 20px; border-radius: 8px; font-weight: 700;
  text-decoration: none; font-size: 1rem; border: 2px solid var(--green);
}
.btn.primary { background: var(--green); color: #0e1012; }
.btn.ghost { color: var(--text); border-color: rgba(255,255,255,.35); }
.btn:hover { filter: brightness(1.08); }

.facts { background: var(--bg-2); border-bottom: 1px solid var(--line); }
.facts ul {
  list-style: none; margin: 0; padding: 18px 0;
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px 18px;
}
.facts li { font-size: .92rem; color: var(--muted); border-left: 3px solid var(--green); padding-left: 10px; }
.facts li b { display: block; color: var(--text); font-size: 1rem; }

/* ---------- sections ---------- */
.section { padding: 72px 0; border-bottom: 1px solid var(--line); }
.section.alt { background: var(--bg-2); }
.section-head { margin-bottom: 36px; }
.systems > *, .system > *, .data-grid > *, .about-grid > *, .contact-grid > * { min-width: 0; }

.systems { display: grid; gap: 28px; }
.system {
  background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; display: grid;
}
.system .media { background: #000; display: flex; flex-direction: column; min-width: 0; }
.system .main { width: 100%; aspect-ratio: 16 / 10; object-fit: cover; }
.system .body { padding: 22px 20px 24px; }
.system .tag {
  font-size: .75rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--green);
}
.specs { list-style: none; padding: 0; margin: 14px 0 20px; border-top: 1px solid var(--line); }
.specs li {
  display: flex; gap: 12px; justify-content: space-between; padding: 9px 0;
  border-bottom: 1px solid var(--line); font-size: .95rem;
}
.specs li span:first-child { color: var(--muted); flex: 0 0 42%; }
.specs li span:last-child { text-align: right; }
/* per-system photo carousel (script at the end of index.html) */
.carousel { position: relative; overflow: hidden; aspect-ratio: 16 / 10; touch-action: pan-y; }
.carousel .track { position: absolute; inset: 0; display: flex; transition: transform .55s ease; }
.carousel .slide { flex: 0 0 100%; width: 100%; height: 100%; object-fit: cover; }
.carousel .prev, .carousel .next {
  display: none; position: absolute; top: 0; bottom: 0; width: 22%; max-width: 96px;
  border: 0; padding: 0; background: transparent; cursor: pointer; color: #fff;
}
.carousel .prev { left: 0; }
.carousel .next { right: 0; }
.carousel.ready .prev, .carousel.ready .next { display: block; }
.carousel .prev span, .carousel .next span {
  position: absolute; top: 50%; margin-top: -20px; width: 40px; height: 40px; border-radius: 50%;
  background: rgba(14, 16, 18, .55); font-size: 30px; line-height: 36px; text-align: center;
}
.carousel .prev span { left: 8px; }
.carousel .next span { right: 8px; }
.carousel .dots { position: absolute; left: 0; right: 0; bottom: 6px; display: flex; justify-content: center; }
.carousel .dots button { width: 24px; height: 24px; padding: 0; border: 0; background: transparent; cursor: pointer; }
.carousel .dots button::after {
  content: ""; display: block; width: 9px; height: 9px; margin: auto; border-radius: 50%;
  background: rgba(255, 255, 255, .55); box-shadow: 0 0 2px rgba(0, 0, 0, .7);
}
.carousel .dots button[aria-current="true"]::after { background: var(--green); }
.carousel button:focus-visible { outline: 2px solid var(--green); outline-offset: -2px; }
@media (prefers-reduced-motion: reduce) { .carousel .track { transition: none; } }

/* ---------- data ---------- */
.data-grid { display: grid; gap: 28px; }
.records {
  list-style: none; margin: 0; padding: 0; display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 230px), 1fr)); gap: 10px;
}
.records li {
  background: var(--panel); border: 1px solid var(--line); border-radius: 8px;
  padding: 12px 14px; font-size: .95rem;
}
.records li b { display: block; font-size: 1rem; }
.records li span { color: var(--muted); font-size: .88rem; }
.flow { counter-reset: step; list-style: none; padding: 0; margin: 0; display: grid; gap: 14px; }
.flow li {
  counter-increment: step; position: relative; padding: 16px 16px 16px 60px;
  background: var(--panel); border: 1px solid var(--line); border-radius: 8px;
}
.flow li::before {
  content: counter(step); position: absolute; left: 16px; top: 16px;
  width: 30px; height: 30px; border-radius: 50%; background: var(--green); color: #0e1012;
  font-weight: 800; display: grid; place-items: center;
}
.flow li b { display: block; margin-bottom: 2px; }
.gallery { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.gallery figure { margin: 0; }
.gallery img { width: 100%; aspect-ratio: 1 / 1; object-fit: cover; border-radius: 8px; }
.gallery figcaption { font-size: .8rem; color: var(--muted); margin-top: 4px; }
.gallery .wide { grid-column: 1 / -1; }
.gallery .wide img { aspect-ratio: 4 / 3; }

.ticket { margin-top: 8px; }
.table-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; border: 1px solid var(--line); border-radius: 8px; }
table { border-collapse: collapse; width: 100%; font-family: var(--mono); font-size: .82rem; min-width: 520px; }
th, td { padding: 9px 10px; text-align: right; border-bottom: 1px solid var(--line); white-space: nowrap; }
th { color: var(--muted); font-weight: 600; background: var(--panel); font-family: var(--font); }
th:first-child, td:first-child { text-align: left; }
td.ok { color: var(--green); }
.callout {
  border-left: 4px solid var(--amber); background: var(--panel); padding: 16px 18px; border-radius: 0 8px 8px 0;
  font-size: 1.05rem;
}

/* ---------- parts ---------- */
.parts {
  list-style: none; margin: 0; padding: 0; display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 260px), 1fr)); gap: 16px;
}
.part {
  background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; display: flex; flex-direction: column;
}
.part .ph {
  aspect-ratio: 4 / 3; background:
    repeating-linear-gradient(135deg, #1f2428 0 14px, #1b1f23 14px 28px);
  display: grid; place-items: center; color: #59626b; font-size: .8rem; letter-spacing: .1em; text-transform: uppercase;
}
.part .ph img { width: 100%; height: 100%; object-fit: cover; }
.part .pb { padding: 14px 16px 18px; display: flex; flex-direction: column; gap: 6px; flex: 1; }
.part .cat { font-size: .72rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--amber); }
.part h3 { font-size: 1.08rem; margin: 0; }
.part p { font-size: .93rem; color: #c5cbd0; margin: 0; }
.part .ask { margin-top: auto; padding-top: 8px; font-weight: 700; font-size: .92rem; text-decoration: none; }

/* ---------- about ---------- */
.about-grid { display: grid; gap: 28px; }
.about-grid img { border-radius: var(--radius); width: 100%; aspect-ratio: 4 / 5; object-fit: cover; }
.points { list-style: none; padding: 0; margin: 18px 0 0; display: grid; gap: 12px; }
.points li { padding-left: 18px; position: relative; }
.points li::before { content: ""; position: absolute; left: 0; top: .6em; width: 8px; height: 8px; background: var(--green); border-radius: 2px; }
.points b { color: var(--text); }

/* ---------- contact ---------- */
form { display: grid; gap: 14px; max-width: 640px; }
label { display: grid; gap: 6px; font-weight: 600; font-size: .95rem; }
input, select, textarea {
  width: 100%; font: inherit; color: var(--text); background: var(--panel);
  border: 1px solid var(--line); border-radius: 8px; padding: 12px 12px;
}
input:focus, select:focus, textarea:focus { outline: 2px solid var(--green); outline-offset: 1px; }
textarea { min-height: 130px; resize: vertical; }
.form-note { font-size: .85rem; color: var(--muted); }
.contact-grid { display: grid; gap: 36px; }
.linkedin {
  display: inline-flex; align-items: center; gap: 10px; color: var(--text); text-decoration: none;
  border: 1px solid var(--line); background: var(--panel); padding: 12px 16px; border-radius: 8px; font-weight: 700;
}
.linkedin svg { width: 22px; height: 22px; fill: #4c8ed9; flex: 0 0 auto; }

footer { padding: 34px 0 44px; color: var(--muted); font-size: .9rem; }
footer .wrap { display: flex; flex-wrap: wrap; gap: 8px 24px; justify-content: space-between; }

/* ---------- wider screens ---------- */
@media (min-width: 720px) {
  body { font-size: 18px; }
  .facts ul { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .system { grid-template-columns: 1.15fr 1fr; }
  .system:nth-child(even) .media { order: 2; }
  .system .carousel { aspect-ratio: auto; flex: 1 1 auto; min-height: 340px; }
  .system .body { padding: 30px 30px 32px; }
  .data-grid { grid-template-columns: 1.1fr 1fr; align-items: start; }
  .gallery { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .about-grid { grid-template-columns: 1fr 1.3fr; align-items: center; }
  .contact-grid { grid-template-columns: 1.4fr 1fr; }
  .section { padding: 96px 0; }
}

/* ---------- phone tightening ---------- */
@media (max-width: 719px) {
  .topbar .wrap { gap: 6px; padding: 0 10px; }
  .mark { font-size: .98rem; }
  .nav { gap: 0; }
  .nav a:first-child { margin-left: auto; }
  .nav a { font-size: .7rem; padding: 7px 2px; }
  .nav a.cta { padding: 7px 5px; margin-left: 2px; }
  .part { flex-direction: row; }
  .part .ph { flex: 0 0 34%; aspect-ratio: auto; min-height: 120px; font-size: .62rem; text-align: center; padding: 4px; }
  .part .ph img { position: static; }
  .part .pb { padding: 12px 14px 14px; }
  /* hero photo shown whole at phone width so the cabinet logo and the crew both stay in frame */
  .hero { min-height: 0; }
  .hero > img { bottom: auto; height: auto; aspect-ratio: 4 / 3; }
  .hero::after { bottom: auto; height: 75vw; background: linear-gradient(180deg, rgba(14,16,18,0) 55%, rgba(14,16,18,.97) 100%); }
  .hero .wrap { padding-top: calc(75vw - 36px); }
}

/* ---------- pneumatic overlay trailers (full-width feature section, 2026-11-12) ---------- */
.feature-grid { display: grid; gap: 24px; }
.feature-grid > * { min-width: 0; }
.feature .carousel { aspect-ratio: 4 / 3; border-radius: var(--radius); background: #000; }
@media (min-width: 720px) {
  .feature-grid { grid-template-columns: 1.6fr 1fr; align-items: center; gap: 36px; }
}
/* portrait slide (pneumatic 2468): show the whole photo so the A/B lettering and the control panel both stay in frame */
.carousel .slide.portrait { object-fit: contain; background: #000; }

/* ---------- EPC volumetric and batch plant systems (full-width feature section, 2026-11-12 c); #systems shares it since 2026-11-12 h ---------- */
#epc .carousel, #systems .carousel { aspect-ratio: 4 / 3; border-radius: var(--radius); background: #000; }
#epc .carousel .dots, #systems .carousel .dots { flex-wrap: wrap; padding: 0 40px; }
#epc .carousel .dots button, #systems .carousel .dots button { width: 16px; }
.epc-blocks { display: grid; gap: 20px; margin-top: 28px; }
.epc-blocks > * { min-width: 0; }
.epc-block {
  background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 22px 20px 24px; display: flex; flex-direction: column;
}
.epc-block .tag { font-size: .75rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--green); }
.epc-block .btn { align-self: flex-start; margin-top: auto; }
@media (min-width: 720px) {
  #epc .carousel, #systems .carousel { aspect-ratio: 16 / 9; }
  .epc-blocks { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 28px; }
  .epc-block { padding: 30px 30px 32px; }
}

/* ---------- data, GPS and customer portal (full-width feature section, 2026-11-13 a) ----------
   Sample map: js/data-map.js (Leaflet from vendor/leaflet/, loaded when the map nears the screen). Colours follow the
   portal machine page: job colours, grey pumps-off, yellow #fff3cd selected row. */
.pqmap { border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; background: var(--panel); }
.pqmap-bar {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 14px;
  background: #1f2937; color: #fff; padding: 10px 14px; border-bottom: 1px solid var(--line);
}
.pqmap-title b { display: block; font-size: 1rem; }
.pqmap-title span { font-size: .82rem; color: #c5ccd3; }
.pqmap-pick { display: flex; align-items: center; gap: 8px; font-size: .82rem; color: #c5ccd3; max-width: 100%; }
.pqmap-pick[hidden] { display: none; }
.pqmap-pick select {
  font: inherit; font-size: .88rem; color: var(--text); background: var(--bg); border: 1px solid var(--line);
  border-radius: 6px; padding: 6px 8px; max-width: 100%; min-width: 0;
}
.pqmap-body { display: grid; }
.pqmap-body > * { min-width: 0; }
.pqmap-map { height: 360px; background: #2c3628; }
.pqmap-table { max-height: 300px; overflow: auto; -webkit-overflow-scrolling: touch; border-top: 1px solid var(--line); }
.pqmap-table table { min-width: 0; font-size: .76rem; }
.pqmap-table th { position: sticky; top: 0; z-index: 1; }
.pqmap-table th, .pqmap-table td { padding: 6px 8px; }
.pqmap-table tbody tr { cursor: pointer; }
.pqmap-table tbody tr:hover td { background: #232a31; }
.pqmap-table tr.off td { color: var(--muted); }
.pqmap-table tbody tr.highlight td, .pqmap-table tbody tr.highlight:hover td { background: #fff3cd; color: #111; }
.pqmap-table tr:focus { outline: 2px solid var(--amber); outline-offset: -2px; }
.pqmap-table .sw { display: inline-block; width: 9px; height: 9px; border-radius: 50%; margin-right: 6px; vertical-align: 0; }
.pqmap-foot { margin: 0; padding: 10px 14px; font-size: .8rem; color: var(--muted); border-top: 1px solid var(--line); }
.pqmap-failed .pqmap-map { display: none; }
/* Leaflet bits drawn by the map script */
.pqmap .leaflet-container { font-family: var(--font); background: #2c3628; }
.pqmap .jlegend {
  background: rgba(255,255,255,.92); color: #111; padding: 6px 8px; border-radius: 5px; font-size: 12px; line-height: 18px;
}
.pqmap .jlegend i { display: inline-block; width: 11px; height: 11px; border-radius: 50%; margin-right: 4px; vertical-align: -1px; }
.pqmap .pq-pop { font-size: 12px; color: #111; }
.pqmap .pq-pop strong { display: block; margin-bottom: 3px; }
.pqmap .pq-pop table { font-family: var(--font); font-size: 12px; min-width: 0; width: auto; }
.pqmap .pq-pop td { padding: 1px 10px 1px 0; border: 0; text-align: left; color: #111; }
.pqmap .pq-pop td + td { text-align: right; font-family: var(--mono); padding-right: 0; }
.pqmap .leaflet-popup-content { margin: 9px 12px; }
.epc-blocks.three .specs li span:first-child { flex-basis: 36%; }
@media (min-width: 720px) {
  .pqmap-map { height: 420px; }
  .pqmap-table { max-height: 420px; }
}
@media (min-width: 960px) {
  .pqmap-body { grid-template-columns: 1.35fr 1fr; }
  .pqmap-map { height: 480px; }
  .pqmap-table { max-height: 480px; border-top: 0; border-left: 1px solid var(--line); }
}
@media (min-width: 1100px) {
  .epc-blocks.three { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; }
  .epc-blocks.three .epc-block { padding: 26px 24px 28px; }
}

/* 2026-11-15 c: plain fact list (#pneumatic) */
ul.facts { margin: 14px 0 20px; padding-left: 1.15em; }
ul.facts li { margin: 0 0 8px; line-height: 1.45; }

/* Remote support section (2026-11-20) */
.support-fig { margin: 26px 0 8px; padding: 14px 8px 6px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); }
.support-fig svg { width: 100%; height: auto; display: block; }
.support-fig .s-line { fill: none; stroke: #9aa4ad; stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; }
.support-fig .s-fill { fill: #242a30; }
.support-fig .s-steel { fill: #39424a; }
.support-fig .s-glass { fill: #1a2026; }
.support-fig .s-tire { fill: #15181b; }
.support-fig .s-ground { stroke: var(--line); stroke-width: 3; }
.support-fig .s-green-fill { fill: var(--green); }
.support-fig .s-dim-fill { fill: #8b959e; }
.support-fig .s-wave { fill: none; stroke: var(--green); stroke-width: 3; stroke-linecap: round; opacity: .85; }
.support-fig .s-link { fill: none; stroke: var(--green); stroke-width: 3.5; stroke-linecap: round; stroke-dasharray: 3 13; animation: supflow 1.1s linear infinite; }
.support-fig .s-trend { fill: none; stroke: var(--green); stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; }
.support-fig .s-headset { fill: var(--amber); stroke: var(--amber); stroke-width: 3.5; stroke-linecap: round; }
.support-fig .s-headset path { fill: none; }
.support-fig .s-label text { fill: var(--muted); font: 600 19px var(--font); text-anchor: middle; letter-spacing: .02em; }
.support-points { margin-bottom: 22px; }
@keyframes supflow { to { stroke-dashoffset: -16; } }
@media (prefers-reduced-motion: reduce) { .support-fig .s-link { animation: none; } }
@media (min-width: 860px) { .support-points { grid-template-columns: repeat(3, 1fr); gap: 22px; } }

/* Header mark + footer companies (2026-11-20 b) */
.mark b { font-weight: 600; color: var(--muted); letter-spacing: 0; margin-left: .12em; }
footer .wrap.foot { display: block; text-align: center; }
.foot-main { font-size: 1.3rem; font-weight: 800; color: var(--text); letter-spacing: -.01em; }
.foot-cos { display: flex; justify-content: space-between; gap: 16px 40px; max-width: 760px; margin: 14px auto 18px; line-height: 1.4; }
.foot-cos span:first-child { text-align: left; }
.foot-cos span:last-child { text-align: right; }
.foot-copy { font-size: .85rem; }
@media (max-width: 719px) {
  .mark { font-size: .9rem; }
  .mark b { font-size: .86em; margin-left: .06em; }
  .nav a { font-size: .64rem; padding: 7px 1.5px; }
  .foot-cos { font-size: .78rem; gap: 10px; }
  .foot-cos span { white-space: nowrap; }
}
/* Header "Tech": smaller, tucked against the p, raised to mid-letter (Gerry 2026-11-20 06:29) */
.mark b { font-size: .58em; margin-left: .14em; position: relative; top: -.22em; letter-spacing: .01em; }
@media (max-width: 719px) { .mark b { font-size: .6em; margin-left: .14em; } }
