/* Invictus CAD, v2 landing page (25 Oct 2026). Chart-table world: a white drawing sheet on the Solaris Marine
   ground, chart-style graduated borders, a compass rose under the part, buoyage paint colours for parts. */
@font-face { font-family: "Fira Sans"; font-weight: 400; font-display: swap; src: url(firasans-400-latin.woff2) format("woff2"); }
@font-face { font-family: "Fira Sans"; font-weight: 500; font-display: swap; src: url(firasans-500-latin.woff2) format("woff2"); }
@font-face { font-family: "Fira Sans"; font-weight: 600; font-display: swap; src: url(firasans-600-latin.woff2) format("woff2"); }
@font-face { font-family: "Fira Code"; font-weight: 400; font-display: swap; src: url(firacode-400-latin.woff2) format("woff2"); }
@font-face { font-family: "Fira Code"; font-weight: 500; font-display: swap; src: url(firacode-500-latin.woff2) format("woff2"); }

:root {
  /* Solaris Marine site tokens, extended for a chart table */
  --paper: #F5F7FA;          /* ground: the Solaris page colour */
  --sheet: #FFFFFF;          /* drawing sheet, cards */
  --tint: #E9F0F7;           /* shoal tint: chart shallow water */
  --tint-2: #D6E4F1;
  --ink: #0D1824;            /* Solaris ink */
  --ink-2: #3B4A5C;
  --ink-3: #54657A;
  --rule: rgba(13, 24, 36, .12);
  --rule-2: rgba(13, 24, 36, .26);
  --sea: #1a6db5;            /* Solaris accent */
  --sea-ink: #155d9b;
  --sea-hover: #14558e;
  --sea-wash: rgba(26, 109, 181, .09);
  --on-sea: #ffffff;
  --navy: #0B1F33;
  --clash: #B8165F;          /* chart magenta: dangers */
  --clash-wash: rgba(184, 22, 95, .08);
  --ok: #1B6E41;
  --ok-wash: rgba(27, 110, 65, .09);
  --wait: #855000;
  --wait-wash: rgba(196, 128, 10, .12);
  /* paint: IALA buoyage colours plus galvanised steel */
  --p-yellow: #E5A21A;
  --p-red: #C8312F;
  --p-green: #1F8A53;
  --p-blue: #1a6db5;
  --p-steel: #8C99A7;
  /* the 3D stage */
  --gl-paper: #FFFFFF;
  --gl-ink: #0D1824;
  --gl-lead: #1a6db5;
  --gl-floor: #1a6db5;
  --gl-shadow: #0D1824;
  --gl-hi: #FFFFFF;

  --sans: "Fira Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "Fira Code", ui-monospace, "Cascadia Mono", monospace;
  --gut: clamp(16px, 3.3vw, 48px);
  --gap: clamp(12px, 1.6vw, 24px);
  --sect: clamp(80px, 9vw, 136px);
  --ease: cubic-bezier(.16, 1, .3, 1);
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --paper: #0B1421; --sheet: #0E1826; --tint: #132034; --tint-2: #1A2B43;
    --ink: #E8ECF1; --ink-2: #A8B4C4; --ink-3: #8C9BAE;
    --rule: rgba(232, 236, 241, .12); --rule-2: rgba(232, 236, 241, .26);
    --sea: #6aaee8; --sea-ink: #6aaee8; --sea-hover: #8fc3ef; --sea-wash: rgba(106, 174, 232, .12); --on-sea: #0B1421;
    --navy: #07101B;
    --clash: #F27AB8; --clash-wash: rgba(242, 122, 184, .12);
    --ok: #67C892; --ok-wash: rgba(103, 200, 146, .12);
    --wait: #E9B957; --wait-wash: rgba(233, 185, 87, .13);
    --gl-paper: #15253A; --gl-ink: #DCE6F1; --gl-lead: #6aaee8; --gl-floor: #6aaee8; --gl-shadow: #000000; --gl-hi: #FFFFFF;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --paper: #0B1421; --sheet: #0E1826; --tint: #132034; --tint-2: #1A2B43;
  --ink: #E8ECF1; --ink-2: #A8B4C4; --ink-3: #8C9BAE;
  --rule: rgba(232, 236, 241, .12); --rule-2: rgba(232, 236, 241, .26);
  --sea: #6aaee8; --sea-ink: #6aaee8; --sea-hover: #8fc3ef; --sea-wash: rgba(106, 174, 232, .12); --on-sea: #0B1421;
  --navy: #07101B;
  --clash: #F27AB8; --clash-wash: rgba(242, 122, 184, .12);
  --ok: #67C892; --ok-wash: rgba(103, 200, 146, .12);
  --wait: #E9B957; --wait-wash: rgba(233, 185, 87, .13);
  --gl-paper: #15253A; --gl-ink: #DCE6F1; --gl-lead: #6aaee8; --gl-floor: #6aaee8; --gl-shadow: #000000; --gl-hi: #FFFFFF;
  color-scheme: dark;
}

/* ── base ─────────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 72px; scrollbar-color: var(--rule-2) var(--paper); }
body {
  margin: 0; background: var(--paper); color: var(--ink);
  font: 400 17px/1.55 var(--sans);
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; overflow-x: clip;
}
::selection { background: var(--sea); color: var(--on-sea); }
::-webkit-scrollbar { width: 11px; height: 11px; }
::-webkit-scrollbar-track { background: var(--paper); }
::-webkit-scrollbar-thumb { background: var(--rule-2); border: 3px solid var(--paper); border-radius: 6px; }
a { color: var(--sea-ink); text-underline-offset: .2em; text-decoration-thickness: 1px; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 2px solid var(--sea); outline-offset: 3px; border-radius: 2px; }
[hidden] { display: none !important; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: 12px; top: -60px; z-index: 50; padding: 10px 14px; background: var(--sheet); color: var(--ink); border: 1px solid var(--rule-2); border-radius: 4px; }
.skip:focus { top: 12px; }
.mono, code, kbd, samp { font-family: var(--mono); font-variant-ligatures: none; }
svg.i { width: 1.1em; height: 1.1em; flex: none; }
h1, h2, h3 { margin: 0; color: var(--ink); text-wrap: balance; }
h1 { font-size: clamp(2.35rem, 1.1rem + 3vw, 4rem); line-height: 1.03; letter-spacing: -.022em; font-weight: 600; }
h2 { font-size: clamp(1.85rem, 1.05rem + 2vw, 2.95rem); line-height: 1.07; letter-spacing: -.018em; font-weight: 600; }
h3 { font-size: 18px; line-height: 1.3; letter-spacing: -.01em; font-weight: 600; }
p { margin: 0; }
.lead { font-size: clamp(17px, 15.4px + .35vw, 19.5px); line-height: 1.5; color: var(--ink-2); max-width: 52ch; }
.wrap { max-width: 1440px; margin: 0 auto; padding: 0 var(--gut); }

/* ── buttons ───────────────────────────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 50px; padding: 0 22px;
  font: 600 16px/1.1 var(--sans); letter-spacing: -.005em; text-decoration: none; border-radius: 4px; border: 1px solid transparent;
  transition: background-color .2s var(--ease), border-color .2s var(--ease), color .2s var(--ease), transform .2s var(--ease), box-shadow .2s var(--ease);
  cursor: pointer;
}
.btn-sea { background: var(--sea); color: var(--on-sea); box-shadow: 0 10px 20px -14px rgba(13, 24, 36, .55); }
.btn-sea:hover { background: var(--sea-hover); transform: translateY(-1px); }
.btn-sea:active { transform: translateY(1px); box-shadow: none; }
.btn-sea svg { transition: transform .2s var(--ease); }
.btn-sea:hover svg { transform: translateX(3px); }
.btn-line { background: transparent; color: var(--ink); border-color: var(--rule-2); }
.btn-line:hover { border-color: var(--ink); background: var(--sea-wash); }
.btn-sm { min-height: 40px; padding: 0 16px; font-size: 14.5px; }

/* ── header ────────────────────────────────────────────────────────── */
.top {
  position: sticky; top: 0; z-index: 30; background: color-mix(in srgb, var(--paper) 92%, transparent);
  backdrop-filter: saturate(1.4) blur(10px); -webkit-backdrop-filter: saturate(1.4) blur(10px);
  border-bottom: 1px solid var(--rule);
}
.top .wrap { display: flex; align-items: center; gap: 24px; min-height: 64px; }
.brand { display: flex; align-items: center; gap: 11px; color: var(--ink); text-decoration: none; flex: none; }
.brand img { width: 30px; height: 30px; display: block; }
.brand b { font-weight: 600; font-size: 17px; letter-spacing: -.015em; }
.brand span { font-size: 13.5px; color: var(--ink-3); padding-left: 11px; border-left: 1px solid var(--rule-2); line-height: 1.2; }
.nav { display: flex; gap: 4px; margin: 0 0 0 auto; padding: 0; list-style: none; }
.nav a { display: block; padding: 8px 11px; border-radius: 4px; color: var(--ink-2); font-size: 14.5px; font-weight: 500; text-decoration: none; }
.nav a:hover { color: var(--ink); background: var(--sea-wash); }
.top .btn { margin-left: 8px; }

/* ── hero ─────────────────────────────────────────────────────────── */
.hero { padding: clamp(28px, 4vw, 56px) 0 clamp(56px, 6vw, 88px); }
.hero .wrap { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gap); align-items: center; }
.pitch { grid-column: 1 / 6; padding-right: clamp(0px, 1.5vw, 24px); }
.pitch .lead { margin-top: 24px; }
.actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 32px; }
.fine { margin-top: 18px; font-size: 14px; color: var(--ink-3); max-width: 46ch; }

/* the drawing sheet, with a chart's graduated neatline */
.sheet {
  position: relative; background: var(--sheet); color: var(--ink); border: 1px solid var(--ink);
  padding: 22px; border-radius: 2px; box-shadow: 0 30px 60px -40px rgba(13, 24, 36, .45);
}
.sheet::before {
  content: ""; position: absolute; inset: 5px; pointer-events: none; border: 1px solid var(--ink);
  background:
    repeating-linear-gradient(90deg, var(--ink-2) 0 20px, transparent 20px 40px) 0 0 / 100% 4px no-repeat,
    repeating-linear-gradient(90deg, var(--ink-2) 0 20px, transparent 20px 40px) 0 100% / 100% 4px no-repeat,
    repeating-linear-gradient(180deg, var(--ink-2) 0 20px, transparent 20px 40px) 0 0 / 4px 100% no-repeat,
    repeating-linear-gradient(180deg, var(--ink-2) 0 20px, transparent 20px 40px) 100% 0 / 4px 100% no-repeat;
}
.sheet::after { content: ""; position: absolute; inset: 11px; pointer-events: none; border: 1px solid var(--rule-2); }
.stage { grid-column: 6 / -1; }
.stage .sheet { display: grid; grid-template-columns: minmax(0, .3fr) minmax(0, .7fr); grid-template-rows: auto minmax(0, 1fr) auto; min-height: min(700px, calc(100svh - 150px)); }

.brief {
  grid-column: 1 / -1; position: relative; z-index: 1; display: flex; align-items: center; gap: 14px; flex-wrap: wrap;
  padding: 8px 8px 14px; border-bottom: 1px solid var(--rule-2);
}
.brief .lbl { font: 500 12px/1 var(--mono); letter-spacing: .07em; text-transform: uppercase; color: var(--ink-3); flex: none; }
.brief .typed { flex: 1 1 360px; min-width: 0; font-size: 16px; line-height: 1.35; color: var(--ink); min-height: 1.35em; }
.caret { display: inline-block; width: 2px; height: 1.15em; margin-left: 1px; vertical-align: -.18em; background: var(--sea); animation: blink 1s steps(1) infinite; }
.caret.off { visibility: hidden; animation: none; }
@keyframes blink { 50% { opacity: 0; } }
.steps { display: flex; gap: 6px; margin: 0; padding: 0; list-style: none; flex: none; }
.steps li { display: flex; align-items: center; gap: 7px; padding: 8px 12px 8px 10px; border-radius: 3px; font-size: 12.5px; font-weight: 500; color: var(--ink-3); border: 1px solid var(--rule); transition: color .3s, border-color .3s, background-color .3s; }
.steps li::before { content: ""; width: 7px; height: 7px; border-radius: 50%; border: 1.5px solid currentColor; transition: background-color .3s; }
.steps li.on { color: var(--sea-ink); border-color: color-mix(in srgb, var(--sea) 45%, transparent); }
.steps li.done { color: var(--ink); border-color: var(--rule-2); }
.steps li.done::before { background: var(--sea); border-color: var(--sea); }

.views { grid-column: 1; grid-row: 2; position: relative; z-index: 1; display: grid; align-content: space-evenly; gap: 14px; padding: 16px 18px 12px 6px; border-right: 1px solid var(--rule); }
.views figure { margin: 0; }
.views figcaption { font: 500 11.5px/1 var(--mono); letter-spacing: .07em; text-transform: uppercase; color: var(--ink-3); margin-bottom: 6px; }
svg.v { display: block; width: 100%; height: auto; overflow: visible; }
.v-section { width: 62% !important; }
/* strokes in drawing units (the three views share one scale, about 2 px per unit at 1440) */
svg.v path, svg.v circle { fill: none; stroke: var(--ink); stroke-linecap: round; stroke-linejoin: round; }
svg.v .vis { stroke-width: .62; }
svg.v .hid { stroke-width: .4; stroke-dasharray: 1.9 1.2; opacity: .7; }
svg.v .hat { stroke-width: .26; stroke: var(--ink-3); }
svg.v .dim { stroke-width: .36; stroke: var(--sea-ink); }
svg.v .arw { fill: var(--sea-ink); stroke: none; }
svg.v .dv { fill: var(--sea-ink); font: 600 7.6px var(--mono); text-anchor: middle; paint-order: stroke; stroke: var(--sheet); stroke-width: 2.2px; stroke-linejoin: round; transition: opacity .4s; }
svg.v .pen { fill: var(--sea); stroke: var(--sheet); stroke-width: .5; transition: opacity .3s; }
.drawing svg.v .dv { opacity: 0; }
.drawing svg.v .dv.on { opacity: 1; }

.model { grid-column: 2; grid-row: 2; position: relative; min-height: 360px; }
.model canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; touch-action: pan-y; cursor: grab; }
.model canvas:active { cursor: grabbing; }
.model canvas:focus-visible { outline-offset: -4px; }
.model .hint { position: absolute; right: 12px; top: 12px; margin: 0; display: flex; align-items: center; gap: 7px; font-size: 12.5px; color: var(--ink-3); pointer-events: none; }
.model .turn { position: absolute; left: 14px; bottom: 10px; margin: 0; font: 500 12px/1 var(--mono); color: var(--ink-3); pointer-events: none; }
.model .msg { position: absolute; inset: 0; display: grid; place-items: center; padding: 24px; text-align: center; font-size: 15px; color: var(--ink-2); }

.tb { grid-column: 1 / -1; grid-row: 3; position: relative; z-index: 1; display: grid; grid-template-columns: 1fr 1.45fr 1.35fr .95fr; border-top: 1px solid var(--ink); }
.tb > div { padding: 10px 12px 11px; border-right: 1px solid var(--rule-2); min-width: 0; }
.tb > div:last-child { border-right: 0; }
.tb .r2 { border-top: 1px solid var(--rule-2); }
.tb .span2 { grid-column: span 2; }
.tb dt, .tb .k { display: block; font: 500 11.5px/1.2 var(--mono); letter-spacing: .06em; text-transform: uppercase; color: var(--ink-3); }
.tb dd, .tb .val { margin: 5px 0 0; font: 500 14.5px/1.3 var(--mono); letter-spacing: -.01em; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-variant-numeric: tabular-nums; }
.tb .sub { display: block; margin-top: 3px; font: 400 12.5px/1.35 var(--mono); color: var(--ink-3); white-space: normal; }
dl.tb { margin: 0; }
.chips { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 7px; }
.chip {
  min-width: 42px; min-height: 34px; padding: 0 12px; border-radius: 3px; border: 1px solid var(--rule-2); background: var(--sheet);
  font: 500 13px/1 var(--mono); color: var(--ink); cursor: pointer; transition: border-color .15s, background-color .15s, color .15s;
}
.chip:hover { border-color: var(--ink); }
.chip[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: var(--sheet); }
.swatch { width: 32px; min-width: 32px; min-height: 32px; padding: 0; position: relative; }
.swatch::before { content: ""; position: absolute; inset: 5px; border-radius: 2px; background: var(--c); box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .15); }
.swatch[aria-pressed="true"] { background: var(--sheet); border-color: var(--ink); box-shadow: inset 0 0 0 1px var(--ink); }
.sw-yellow { --c: var(--p-yellow); } .sw-red { --c: var(--p-red); } .sw-blue { --c: var(--p-blue); } .sw-green { --c: var(--p-green); } .sw-steel { --c: var(--p-steel); }
.tb .fin { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.tb .fin .val { margin: 0; font-family: var(--sans); font-size: 13px; color: var(--ink-2); }
.replay { display: inline-flex; align-items: center; gap: 8px; margin-top: 7px; padding: 0 14px; min-height: 34px; border-radius: 3px; border: 1px solid var(--rule-2); background: transparent; color: var(--ink); font: 500 13px/1 var(--sans); cursor: pointer; }
.replay:hover { border-color: var(--ink); background: var(--sea-wash); }

/* ── sections ─────────────────────────────────────────────────────── */
.sect { padding: var(--sect) 0; border-top: 1px solid var(--rule); }
.shead { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gap); align-items: end; margin-bottom: clamp(32px, 4vw, 56px); }
.shead h2 { grid-column: 1 / 8; }
.shead .lead { grid-column: 8 / -1; }
.k { font: 500 11.5px/1.2 var(--mono); letter-spacing: .06em; text-transform: uppercase; color: var(--ink-3); }
.st { display: inline-flex; align-items: center; gap: 7px; font-size: 14px; font-weight: 500; white-space: nowrap; }
.st::before { content: ""; width: 8px; height: 8px; border-radius: 50%; flex: none; }
.st-ok { color: var(--ok); } .st-ok::before { background: var(--ok); }
.st-wait { color: var(--wait); } .st-wait::before { background: transparent; border: 2px solid var(--wait); width: 9px; height: 9px; box-sizing: border-box; }
.st-run { color: var(--sea-ink); } .st-run::before { background: var(--sea); border-radius: 1px; }
.tscroll { position: relative; overflow-x: auto; scrollbar-width: thin; }
.rec td { position: relative; }
.tscroll:focus-visible { outline-offset: 2px; }

/* assemblies: the widest stage on the page, on chart shoal tint */
.asm { background: var(--tint); }
.asm-grid { display: grid; grid-template-columns: minmax(0, 1fr) 400px; gap: var(--gap); align-items: stretch; }
.asm-stage { position: relative; min-height: 600px; background: var(--sheet); border: 1px solid var(--rule-2); border-radius: 2px; overflow: hidden; }
.asm-stage canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; touch-action: pan-y; cursor: grab; }
.asm-stage canvas:active { cursor: grabbing; }
.asm-stage canvas:focus-visible { outline-offset: -4px; }
.asm-bar { position: absolute; left: 14px; right: 14px; top: 14px; z-index: 2; display: flex; justify-content: space-between; gap: 10px; flex-wrap: wrap; pointer-events: none; }
.seg { display: inline-flex; padding: 3px; gap: 3px; border-radius: 5px; background: var(--paper); border: 1px solid var(--rule-2); pointer-events: auto; }
.seg button { min-height: 38px; padding: 0 14px; border: 0; border-radius: 3px; background: transparent; color: var(--ink-2); font: 500 14.5px/1 var(--sans); cursor: pointer; transition: background-color .2s, color .2s; }
.seg button:hover { color: var(--ink); background: var(--sea-wash); }
.seg button[aria-pressed="true"] { background: var(--ink); color: var(--sheet); }
.balloons { position: absolute; inset: 0; pointer-events: none; z-index: 1; }
.bl { position: absolute; left: 0; top: 0; display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; background: var(--sheet); border: 1.5px solid var(--ink); font: 600 13.5px/1 var(--sans); color: var(--ink); opacity: 0; transition: opacity .3s, border-color .2s, background-color .2s, color .2s; will-change: transform; }
.bl.on { opacity: 1; }
.bl.hot { background: var(--ink); color: var(--sheet); }
.clash-pin { position: absolute; left: 0; top: 0; margin: 0; z-index: 1; pointer-events: none; }
.clash-pin .tag { position: absolute; left: 0; top: 0; padding: 8px 12px; border-radius: 3px; background: var(--clash); color: #fff; font: 600 13.5px/1.2 var(--sans); white-space: nowrap; opacity: 0; transition: opacity .3s; will-change: transform; }
:root[data-theme="dark"] .clash-pin .tag { color: #0B1421; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .clash-pin .tag { color: #0B1421; } }
.clash-pin .tag::after { content: ""; position: absolute; left: 50%; top: 100%; width: 2px; height: 12px; margin-left: -1px; background: var(--clash); }
.clash-pin .dot { position: absolute; left: -9px; top: -9px; width: 18px; height: 18px; border-radius: 50%; border: 2.5px solid var(--clash); opacity: 0; transition: opacity .3s; will-change: transform; }
.clash-pin.on .tag, .clash-pin.on .dot { opacity: 1; }
.asm-stage .msg { position: absolute; inset: 0; display: grid; place-items: start center; margin: 0; padding: 76px 24px 24px; text-align: center; color: var(--ink-2); pointer-events: none; }
.asm-stage canvas.wait { opacity: .15; transition: opacity .2s; }
.asm-side { background: var(--sheet); border: 1px solid var(--rule-2); border-radius: 2px; padding: 22px 22px 20px; display: flex; flex-direction: column; gap: 14px; }
.parts { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--rule); }
.part { width: 100%; display: grid; grid-template-columns: 28px 14px minmax(0, 1fr) 76px; align-items: center; gap: 10px; padding: 11px 10px; border: 0; border-bottom: 1px solid var(--rule); background: transparent; color: var(--ink); text-align: left; font: inherit; cursor: pointer; transition: background-color .15s; }
.part:hover, .part.hot { background: var(--sea-wash); }
.part .bn { display: grid; place-items: center; width: 26px; height: 26px; border-radius: 50%; border: 1.5px solid var(--ink); font: 600 13px/1 var(--sans); }
.part.hot .bn { background: var(--ink); color: var(--sheet); }
.part .pc { width: 14px; height: 14px; border-radius: 2px; background: var(--c, var(--p-steel)); box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .18); }
.part .pn { font-weight: 500; font-size: 15.5px; line-height: 1.25; min-width: 0; }
.part .pn small { display: block; font: 400 12.5px/1.35 var(--mono); color: var(--ink-3); margin-top: 2px; }

.part .pm { font: 500 14px/1 var(--mono); color: var(--ink); white-space: nowrap; text-align: right; }
.ptotal { display: grid; grid-template-columns: 1fr auto; gap: 2px 10px; align-items: baseline; font-size: 15px; color: var(--ink-2); }
.ptotal b { font: 600 16px/1 var(--mono); color: var(--ink); }
.ptotal small { grid-column: 1 / -1; font-size: 12.5px; color: var(--ink-3); }
.clash { margin-top: auto; padding: 16px 16px 14px; border-radius: 3px; background: var(--ok-wash); border: 1px solid color-mix(in srgb, var(--ok) 35%, transparent); transition: background-color .3s, border-color .3s; }
.clash[data-state="bad"] { background: var(--clash-wash); border-color: color-mix(in srgb, var(--clash) 45%, transparent); }
.clash h3 { font-size: 13px; font-weight: 600; letter-spacing: .02em; color: var(--ink-2); }
.cres { display: flex; align-items: center; gap: 8px; margin-top: 6px; font-size: 21px; font-weight: 600; letter-spacing: -.01em; color: var(--ok); }
.cres svg { width: 22px; height: 22px; }
.clash[data-state="bad"] .cres { color: var(--clash); }
.cpairs { list-style: none; margin: 8px 0 0; padding: 0; font-size: 14px; color: var(--ink-2); }
.cpairs li { display: flex; justify-content: space-between; gap: 10px; padding: 3px 0; }
.cpairs b { font: 500 13.5px/1.4 var(--mono); color: var(--ink); white-space: nowrap; }
.whatif { margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--rule-2); }
.tog { display: flex; align-items: center; gap: 10px; width: 100%; min-height: 40px; padding: 0; border: 0; background: transparent; color: var(--ink); font: 500 14.5px/1.3 var(--sans); text-align: left; cursor: pointer; }
.tog .sw { position: relative; flex: none; width: 36px; height: 20px; border-radius: 10px; background: var(--rule-2); transition: background-color .2s; }
.tog .sw::after { content: ""; position: absolute; left: 3px; top: 3px; width: 14px; height: 14px; border-radius: 50%; background: var(--sheet); box-shadow: 0 1px 2px rgba(0, 0, 0, .3); transition: transform .2s var(--ease); }
.tog[aria-pressed="true"] .sw { background: var(--clash); }
.tog[aria-pressed="true"] .sw::after { transform: translateX(16px); }
.tog:hover .sw { box-shadow: 0 0 0 3px var(--sea-wash); }

/* reading: the enquiry and the brief made from it */
.read-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); gap: var(--gap); align-items: start; }
.mail { background: var(--sheet); border: 1px solid var(--rule-2); border-radius: 2px; }
.mail-h { padding: 18px 22px 14px; border-bottom: 1px solid var(--rule); }
.mail-h .from { font-size: 15px; color: var(--ink-2); } .mail-h .from b { color: var(--ink); font-weight: 600; }
.mail-h .subj { margin-top: 4px; font-size: 18px; font-weight: 600; letter-spacing: -.01em; }
.mail-h .meta { margin-top: 4px; font-size: 13.5px; color: var(--ink-3); }
.lines { list-style: none; margin: 0; padding: 12px 0 16px; }
.lines li { position: relative; padding: 5px 22px 5px 58px; font-size: 16px; line-height: 1.5; transition: background-color .25s; }
.lines li::before { content: "L" attr(data-l); position: absolute; left: 20px; top: 7px; font: 500 12.5px/1.4 var(--mono); color: var(--ink-3); }
.lines li.hl { background: var(--sea-wash); box-shadow: inset 3px 0 0 var(--sea); }
.lines li.hl::before { color: var(--sea-ink); }
.brief-out { background: var(--sheet); border: 1px solid var(--rule-2); border-radius: 2px; padding: 18px 22px 18px; }
.bo-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; padding-bottom: 12px; border-bottom: 1px solid var(--ink); }
.bo-head h3 { font-size: 18px; }
.bo-state { font: 500 13px/1.3 var(--mono); color: var(--ink-3); }
.fields { margin: 0; }
.f { display: grid; grid-template-columns: 150px minmax(0, 1fr); gap: 4px 14px; align-items: baseline; padding: 10px 8px; border-bottom: 1px solid var(--rule); transition: background-color .25s, opacity .4s, transform .4s var(--ease); }
.f dt { font-size: 14px; color: var(--ink-3); }
.f dd { margin: 0; font-size: 15.5px; font-weight: 500; color: var(--ink); display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.f.ask dd { display: block; }
.f.hl { background: var(--sea-wash); }
.src { min-height: 32px; padding: 0 12px; border-radius: 3px; border: 1px solid var(--rule-2); background: transparent; color: var(--sea-ink); font: 500 12.5px/1 var(--mono); cursor: pointer; white-space: nowrap; }
.src:hover, .src:focus-visible { border-color: var(--sea); background: var(--sea-wash); }
.f.ask dd { font-weight: 400; color: var(--ink-2); }
.blank { display: block; width: fit-content; margin: 0 0 6px; padding: 8px 10px; line-height: 1; border-radius: 3px; border: 1px dashed var(--wait); color: var(--wait); font: 500 12.5px/1.4 var(--mono); }
.bo-note { margin-top: 14px; font-size: 14px; color: var(--ink-3); }
.fields.pre .f { opacity: 0; transform: translateY(6px); }
.fields.pre .f.in { opacity: 1; transform: none; }

/* project board */
.board { background: var(--sheet); border: 1px solid var(--rule-2); border-radius: 2px; }
.board-h { display: flex; justify-content: space-between; align-items: center; gap: 16px 24px; flex-wrap: wrap; padding: 18px 22px; border-bottom: 1px solid var(--ink); }
.pname b { display: block; font-size: 19px; font-weight: 600; letter-spacing: -.01em; }
.pname span { font-size: 14px; color: var(--ink-3); }
.wait { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; margin: 0; padding: 0; }
.wait li { padding: 8px 12px; border-radius: 3px; background: var(--paper); border: 1px solid var(--rule); font-size: 14px; color: var(--ink-2); }
.wait b { font: 600 14px/1 var(--mono); color: var(--ink); margin-right: 3px; }
.board-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
.board-grid > div { padding: 20px 22px 22px; min-width: 0; }
.board-grid h3 { margin-bottom: 12px; display: flex; align-items: center; gap: 8px; }
.jobs { border-right: 1px solid var(--rule); }
.reg { grid-column: 1 / -1; border-top: 1px solid var(--rule); }
.joblist { list-style: none; margin: 0; padding: 0; }
.joblist li { display: grid; grid-template-columns: 52px minmax(0, 1fr) auto; gap: 4px 10px; align-items: center; padding: 10px 0; border-bottom: 1px solid var(--rule); }
.jn { font-size: 13.5px; color: var(--ink-3); }
.jt { font-weight: 500; font-size: 15.5px; } .jt small { display: block; font-weight: 400; font-size: 13px; color: var(--ink-3); }
.count { display: inline-grid; place-items: center; min-width: 28px; padding: 8px 10px; border-radius: 12px; background: var(--sea); color: var(--on-sea); font: 600 13px/1 var(--mono); }
.appr { display: grid; gap: 12px; align-content: start; }
.appr h3 { margin-bottom: 0; }
.card { padding: 14px 16px 14px; border: 1px solid var(--rule-2); border-radius: 3px; background: var(--paper); transition: background-color .3s, border-color .3s; }
.card.ok { background: var(--ok-wash); border-color: color-mix(in srgb, var(--ok) 35%, transparent); }
.ctitle { font-weight: 600; font-size: 15.5px; } .ctitle .mono { font-weight: 500; font-size: 13.5px; color: var(--ink-3); margin-right: 6px; }
.delta { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin: 10px 0 0; }
.delta div { padding: 10px 12px; border-radius: 3px; background: var(--sheet); border: 1px solid var(--rule); }
.delta dt { font: 500 11.5px/1.2 var(--mono); letter-spacing: .06em; text-transform: uppercase; color: var(--ink-3); }
.delta dd { margin: 3px 0 0; font: 500 14.5px/1.3 var(--mono); }
.delta div:first-child dd { color: var(--ink-3); text-decoration: line-through; text-decoration-color: var(--rule-2); }
.why { margin-top: 9px; font-size: 14px; color: var(--ink-2); }
.cact { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.card.ok .cact { display: none; }
.done-note { margin-top: 10px; font-size: 14px; font-weight: 500; color: var(--ok); }
table { width: 100%; border-collapse: collapse; font-size: 15px; }
th, td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--rule); vertical-align: middle; }
thead th { font: 500 11.5px/1.2 var(--mono); letter-spacing: .06em; text-transform: uppercase; color: var(--ink-3); border-bottom-color: var(--rule-2); }
td.mono { font-size: 14px; }
tr.flash td { animation: flash 1.6s var(--ease); }
@keyframes flash { from { background: var(--sea-wash); } to { background: transparent; } }

/* inspections */
.insp-grid { display: grid; grid-template-columns: 340px minmax(0, 1fr); gap: clamp(24px, 4vw, 64px); align-items: start; }
.phone-col { display: grid; gap: 20px; justify-items: start; }
.phone { margin: 0; width: 300px; padding: 12px; border-radius: 36px; background: #0D1824; box-shadow: 0 30px 50px -30px rgba(13, 24, 36, .55), inset 0 0 0 1px rgba(255, 255, 255, .08); }
.screen { position: relative; border-radius: 26px; overflow: hidden; background: #0B1421; color: #E8ECF1; aspect-ratio: 9 / 17.5; display: flex; flex-direction: column; }
.ph-top { display: flex; justify-content: space-between; padding: 16px 18px 10px; font: 500 13px/1 var(--mono); color: #A8B4C4; }
.ph-top span:last-child { color: #fff; }
.shot { position: relative; flex: 1; margin: 0 10px; border-radius: 10px; overflow: hidden; background: #26313d; }
.shot img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; transition: opacity .35s, transform .6s var(--ease); }
.shot img.swap { opacity: 0; transform: scale(1.04); }
.filed { margin: 10px 10px 14px; padding: 11px 13px; border-radius: 10px; background: #13233A; border: 1px solid rgba(106, 174, 232, .35); transition: opacity .35s, transform .35s var(--ease); }
.filed.pre { opacity: 0; transform: translateY(8px); }
.fl1 { font: 600 12px/1 var(--mono); letter-spacing: .08em; text-transform: uppercase; color: #6aaee8; }
.fl2 { margin-top: 5px; font-size: 15px; font-weight: 500; color: #fff; }
.story { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; max-width: 340px; }
.story li { font-size: 15px; color: var(--ink-2); padding-left: 14px; border-left: 1px solid var(--rule-2); }
.story b { color: var(--ink); font-weight: 600; }
.record { background: var(--sheet); border: 1px solid var(--rule-2); border-radius: 2px; padding: 18px 22px 18px; min-width: 0; }
.rec-h { display: flex; justify-content: space-between; align-items: baseline; gap: 10px 16px; flex-wrap: wrap; padding-bottom: 12px; border-bottom: 1px solid var(--ink); }
.rec-h p { font-size: 13.5px; color: var(--ink-3); }
.rec { min-width: 620px; table-layout: fixed; }
.rec th[scope="row"] { font: 600 14px/1 var(--mono); width: 64px; }
.rec td { padding: 8px; }
.rec td .ph { position: relative; display: block; width: 100%; aspect-ratio: 4 / 3; border-radius: 3px; overflow: hidden; background: var(--tint); }
.rec td .ph img { width: 100%; height: 100%; object-fit: cover; display: block; }
.rec td time { display: block; margin-top: 5px; font: 500 12px/1.2 var(--mono); color: var(--ink-3); }
.rec td.new time { color: var(--sea-ink); }
.fly { position: fixed; z-index: 40; margin: 0; border-radius: 4px; overflow: hidden; pointer-events: none; transform-origin: 0 0; box-shadow: 0 18px 30px -16px rgba(13, 24, 36, .6); transition: transform .9s var(--ease), opacity .3s .8s; }
.fly img { width: 100%; height: 100%; object-fit: cover; display: block; }
.rec td.new .ph { box-shadow: 0 0 0 2px var(--sea); }
.rec td.todo span[aria-hidden] { display: block; width: 100%; aspect-ratio: 4 / 3; border-radius: 3px; border: 1px dashed var(--rule-2); }
.rec-note { margin-top: 12px; font-size: 14px; color: var(--ink-3); }

/* logs */
.log-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--gap); }
.log { background: var(--sheet); border: 1px solid var(--rule-2); border-radius: 2px; padding: 16px 18px 8px; min-width: 0; }
.log h3 { padding-bottom: 10px; border-bottom: 1px solid var(--ink); }
.log ol { list-style: none; margin: 0; padding: 0; min-height: 372px; }
.log li { display: grid; grid-template-columns: 58px minmax(0, 1fr); gap: 2px 10px; padding: 10px 0; border-bottom: 1px solid var(--rule); font-size: 14.5px; line-height: 1.4; }
.log li:last-child { border-bottom: 0; }
.log time { font: 500 12.5px/1.6 var(--mono); color: var(--ink-3); }
.log .ref { grid-column: 2; font: 400 12.5px/1.3 var(--mono); color: var(--ink-3); }
.log li.in { animation: logIn .7s var(--ease); }
.log li.mine time { color: var(--sea-ink); }
@keyframes logIn { from { opacity: 0; transform: translateY(-8px); } to { opacity: 1; transform: none; } }

/* close: deep navy in both themes */
.close { background: var(--navy); color: #E8ECF1; padding: clamp(80px, 8vw, 120px) 0 0; overflow: hidden; }
.close .wrap { position: relative; }
.close .deco { position: absolute; right: var(--gut); top: -10px; width: min(560px, 44%); opacity: .55; pointer-events: none; }
.close .deco svg.v path, .close .deco svg.v circle { stroke: #8fb6da; }
.close .deco svg.v .arw, .close .deco svg.v .dv { fill: #8fb6da; }
.close .deco svg.v .dv { stroke: var(--navy); }
.close .deco svg.v .hat { stroke: #8fb6da; }
.close h2 { color: #fff; max-width: 18ch; font-size: clamp(2.1rem, 1.2rem + 2.6vw, 3.6rem); }
.close .lead { color: #B9C5D3; margin-top: 18px; }
.close .btn-sea { background: #6aaee8; color: #0B1421; }
.close .btn-sea:hover { background: #8fc3ef; }
.close .btn-line { color: #E8ECF1; border-color: rgba(232, 236, 241, .4); }
.close .btn-line:hover { border-color: #fff; background: rgba(232, 236, 241, .08); }
.close .more { margin-top: 26px; font-size: 16px; color: #B9C5D3; }
.close a:not(.btn) { color: #8fc3ef; }
.close :focus-visible { outline-color: #8fc3ef; }
.foot { display: flex; justify-content: space-between; align-items: center; gap: 12px 32px; flex-wrap: wrap; margin-top: clamp(64px, 7vw, 100px); padding: 22px 0 26px; border-top: 1px solid rgba(232, 236, 241, .16); }
.sig { display: flex; align-items: center; gap: 10px; font-size: 15px; font-weight: 500; color: #fff; }
.legal { font-size: 13px; color: #9FAEC0; max-width: 72ch; }

/* ── narrower screens ─────────────────────────────────────────────── */
@media (max-width: 1180px) {
  .nav { display: none; }
  .top .btn { margin-left: auto; }
  .pitch { grid-column: 1 / -1; max-width: 760px; }
  .stage { grid-column: 1 / -1; margin-top: 40px; }
  .shead h2, .shead .lead { grid-column: 1 / -1; }
  .shead .lead { margin-top: 16px; }
  .asm-grid { grid-template-columns: minmax(0, 1fr); }
  .asm-stage { min-height: 520px; }
  .read-grid { grid-template-columns: minmax(0, 1fr); }
  .insp-grid { grid-template-columns: minmax(0, 1fr); }
  .phone-col { grid-template-columns: auto minmax(0, 1fr); align-items: start; gap: 20px 32px; }
  .phone-col .phone { grid-row: span 3; }
}
@media (max-width: 760px) {
  body { font-size: 16px; }
  .brand span { display: none; }
  .top .wrap { min-height: 58px; }
  .actions .btn { flex: 1 1 100%; }
  .hero .wrap { display: flex; flex-direction: column; align-items: stretch; }
  .pitch { display: contents; }
  .pitch h1 { order: 1; }
  .stage { order: 2; margin: 22px calc(-1 * var(--gut)) 0; }
  .pitch .lead { order: 3; margin-top: 26px; }
  .pitch .actions { order: 4; }
  .pitch .fine { order: 5; }
  svg.v .dv { font-size: 8.4px; }
  .sheet { padding: 16px 14px; border-left: 0; border-right: 0; border-radius: 0; }
  .stage .sheet { grid-template-columns: minmax(0, 1fr); grid-template-rows: auto; min-height: 0; }
  .brief { padding: 4px 4px 12px; }
  .steps { width: 100%; flex-wrap: wrap; }
  .model { grid-column: 1; grid-row: 2; min-height: 0; aspect-ratio: 1 / 1; }
  .views { grid-column: 1; grid-row: 3; grid-template-columns: 1fr 1fr; align-items: end; padding: 14px 4px; border-right: 0; border-top: 1px solid var(--rule); }
  .views figure:last-child { grid-column: 1 / -1; }
  .v-section { width: 50% !important; }
  .tb { grid-row: 4; grid-template-columns: 1fr 1fr; }
  .tb > div { border-top: 1px solid var(--rule-2); }
  .tb > div:nth-child(2n) { border-right: 0; }
  .tb .span2 { grid-column: 1 / -1; border-right: 0; }
  .tb .val { white-space: normal; }
  .reg .tscroll { overflow: visible; }
  .reg thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  .reg tbody, .reg tr, .reg td { display: block; }
  .reg tr { display: grid; grid-template-columns: auto 1fr auto; gap: 4px 12px; padding: 12px 0; border-bottom: 1px solid var(--rule); }
  .reg td { padding: 0; border: 0; }
  .reg td:nth-child(1) { grid-column: 1; }
  .reg td:nth-child(2) { grid-column: 1 / -1; grid-row: 2; font-weight: 500; }
  .reg td:nth-child(1) { grid-row: 1; }
  .reg td:nth-child(3) { grid-column: 3; grid-row: 1; text-align: right; }
  .reg td:nth-child(3)::before { content: "Rev "; color: var(--ink-3); }
  .reg td:nth-child(4) { grid-column: 1 / 3; grid-row: 3; }
  .reg td:nth-child(5) { grid-column: 3; grid-row: 3; text-align: right; color: var(--ink-2); font-size: 14px; }
  .rec { min-width: 0; }
  .rec th, .rec td { padding: 6px 3px; }
  .rec th[scope="row"] { width: 46px; font-size: 12.5px; }
  .rec thead th { font-size: 11px; letter-spacing: 0; white-space: normal; line-height: 1.25; }
  .rec td time { font-size: 11px; }
  .asm-stage { min-height: 0; aspect-ratio: 4 / 5; margin: 0 calc(-1 * var(--gut)); border-left: 0; border-right: 0; border-radius: 0; }
  .asm-bar { left: 10px; right: 10px; top: 10px; }
  .seg button { padding: 0 10px; font-size: 14px; }
  .asm-side { margin: 0 calc(-1 * var(--gut)); border-left: 0; border-right: 0; border-radius: 0; padding: 18px var(--gut); }
  .f { grid-template-columns: minmax(0, 1fr); }
  .mail, .brief-out { margin: 0 calc(-1 * var(--gut)); border-left: 0; border-right: 0; border-radius: 0; }
  .brief-out { padding: 16px var(--gut); }
  .lines li { padding-right: var(--gut); }
  .board { margin: 0 calc(-1 * var(--gut)); border-left: 0; border-right: 0; border-radius: 0; }
  .board-grid { grid-template-columns: minmax(0, 1fr); }
  .jobs { border-right: 0; }
  .appr { border-top: 1px solid var(--rule); }
  .board-grid > div, .board-h { padding-left: var(--gut); padding-right: var(--gut); }
  .joblist li { grid-template-columns: 46px minmax(0, 1fr); }
  .joblist .st { grid-column: 2; }
  .delta { grid-template-columns: 1fr; }
  .phone-col { grid-template-columns: minmax(0, 1fr); justify-items: center; }
  .phone-col .phone { grid-row: auto; width: min(300px, 82vw); }
  .record { margin: 0 calc(-1 * var(--gut)); border-left: 0; border-right: 0; border-radius: 0; padding: 16px var(--gut); }
  .log-grid { grid-template-columns: minmax(0, 1fr); }
  .log ol { min-height: 0; }
  .close .deco { position: static; width: 100%; max-width: 360px; margin: 0 0 24px; opacity: .5; }
}
@media (min-width: 1800px) { body { zoom: 1.25; } }
@media (min-width: 2300px) { body { zoom: 1.6; } }
@media (min-width: 3000px) { body { zoom: 2.1; } }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: .01ms !important; animation: none !important; }
}
