/* ============================================================
   Next Ambulances — A4 print documents (shared)
   Light / sanitary. Portrait 210 × 297 mm.
   ============================================================ */

:root {
  --bg:        #FFFFFF;
  --bg-soft:   #EEF3F8;
  --bg-card:   #F6F9FC;
  --bg-elev:   #E3EBF2;
  --line:      #CFDAE4;
  --line-soft: rgba(28,42,54,0.10);
  --ink:       #1E2D38;
  --ink-mute:  #51616E;
  --ink-dim:   #8696A3;
  --accent:    #E3262B;
  --accent-2:  #1E78B4;
  --med:       #E2453B;
  --safety:    #1E78B4;
  --humani:    #2E9B78;
  --font-sans: "Archivo", system-ui, -apple-system, sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, monospace;
}

@page { size: A4 portrait; margin: 0; }

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  background: #DCE3EA;
  font-family: var(--font-sans);
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img { display: block; max-width: 100%; }

.doc {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 26px;
  padding: 34px 16px 60px;
}

.page {
  width: 210mm;
  height: 297mm;
  flex: none;
  background: var(--bg);
  color: var(--ink);
  position: relative;
  overflow: hidden;
  padding: 17mm 16mm 14mm;
  display: flex;
  flex-direction: column;
  box-shadow: 0 24px 70px rgba(30,45,58,0.16);
  -webkit-print-color-adjust: exact;
  print-color-adjust: exact;
}

/* faint technical grid texture (not an infographic — just paper) */
.page::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(30,45,58,0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(30,45,58,0.03) 1px, transparent 1px);
  background-size: 14mm 14mm;
  pointer-events: none;
}
.page > * { position: relative; z-index: 1; }

/* ── shared type ─────────────────────────────────────────────── */
.kicker {
  font-family: var(--font-mono);
  font-size: 9.5px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--ink-dim);
  display: inline-flex;
  align-items: center;
  gap: 9px;
}
.kicker .dot {
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--accent);
  flex: none;
}
.mono { font-family: var(--font-mono); }

h1, h2, h3, h4 { margin: 0; font-weight: 700; letter-spacing: -0.02em; line-height: 1.05; }
p { margin: 0; }

.lead {
  font-size: 12.5px;
  line-height: 1.5;
  color: var(--ink-mute);
  max-width: 62ch;
}
.accent { color: var(--accent); }

/* ── content page header / footer ───────────────────────────── */
.ph {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  padding-bottom: 9px;
  border-bottom: 1px solid var(--line);
}
.ph-num {
  font-family: var(--font-mono);
  font-size: 9.5px;
  letter-spacing: 0.18em;
  color: var(--ink-dim);
}
.ph-title {
  font-size: 27px;
  margin-top: 16px;
  max-width: 24ch;
}
.ph-lead {
  margin-top: 12px;
  margin-bottom: 22px;
}

.body { flex: 1 1 auto; min-height: 0; display: flex; flex-direction: column; justify-content: center; }

.pf {
  margin-top: auto;
  padding-top: 10px;
  border-top: 1px solid var(--line);
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-family: var(--font-mono);
  font-size: 8.5px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-dim);
}
.pf .accent { color: var(--accent); }

/* ── logo ────────────────────────────────────────────────────── */
.logo {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  color: var(--ink);
}
.logo svg { width: 34px; height: 34px; flex: none; }
.logo .lw { display: flex; flex-direction: column; line-height: 1; }
.logo .lw b { font-size: 19px; font-weight: 800; letter-spacing: -0.03em; white-space: nowrap; }
.logo .lw b i { color: var(--accent); font-style: normal; }
.logo .lw span {
  font-family: var(--font-mono);
  font-size: 8.5px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--ink-dim);
  margin-top: 3px;
}

/* ── cover ───────────────────────────────────────────────────── */
.cover { justify-content: space-between; padding: 19mm 16mm 15mm; }
.cover-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
}
.cover-ref {
  text-align: right;
  font-family: var(--font-mono);
  font-size: 9px;
  letter-spacing: 0.16em;
  color: var(--ink-dim);
  line-height: 1.7;
  text-transform: uppercase;
}
.cover-mid { margin-top: auto; }
.cover-doc {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 20px;
}
.cover-title {
  font-size: 60px;
  line-height: 0.98;
  letter-spacing: -0.035em;
  font-weight: 800;
  max-width: 16ch;
}
.cover-sub {
  margin-top: 24px;
  font-size: 14px;
  line-height: 1.55;
  color: var(--ink-mute);
  max-width: 54ch;
}
.cover-rule {
  height: 1px;
  background: var(--line);
  margin: 30px 0 22px;
}
.cover-meta {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
}
.cover-meta .k {
  font-family: var(--font-mono);
  font-size: 8.5px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ink-dim);
  margin-bottom: 6px;
}
.cover-meta .v { font-size: 13px; font-weight: 600; }
.cover-foot {
  margin-top: 26px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-family: var(--font-mono);
  font-size: 8.5px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-dim);
}

/* big quiet index number on covers */
.cover-index {
  position: absolute;
  right: 14mm;
  bottom: 38mm;
  font-family: var(--font-mono);
  font-size: 150px;
  font-weight: 300;
  color: rgba(30,45,58,0.05);
  line-height: 1;
  z-index: 0;
}

/* ── grids ───────────────────────────────────────────────────── */
.cols-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 0 26px; }
.cols-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0; }

/* ── pillars (about) ─────────────────────────────────────────── */
.pillar {
  padding: 18px 18px 18px 0;
  border-top: 1px solid var(--line);
}
.pillar .c {
  font-family: var(--font-mono);
  font-size: 9px;
  color: var(--accent);
  letter-spacing: 0.16em;
  margin-bottom: 9px;
}
.pillar h4 { font-size: 15px; margin-bottom: 7px; }
.pillar p { font-size: 11.5px; line-height: 1.5; color: var(--ink-mute); }

/* ── meta strip (numbers) ────────────────────────────────────── */
.strip {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
}
.strip .cell {
  padding: 18px 16px;
  border-right: 1px solid var(--line);
}
.strip .cell:last-child { border-right: 0; }
.strip .num { font-family: var(--font-mono); font-size: 9px; color: var(--ink-dim); letter-spacing: 0.14em; }
.strip .big { font-size: 38px; font-weight: 800; letter-spacing: -0.03em; margin: 6px 0 4px; }
.strip .big.sm { font-size: 22px; }
.strip .lbl { font-size: 10.5px; color: var(--ink-mute); line-height: 1.35; }

/* ── lines list ──────────────────────────────────────────────── */
.lines { border-top: 1px solid var(--line); }
.line {
  display: grid;
  grid-template-columns: 30px 1fr;
  gap: 16px;
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
}
.line .ix { font-family: var(--font-mono); font-size: 11px; color: var(--ink-dim); padding-top: 3px; }
.line .tag {
  font-family: var(--font-mono);
  font-size: 9px;
  letter-spacing: 0.16em;
  color: var(--accent);
  text-transform: uppercase;
}
.line h4 { font-size: 16px; margin: 6px 0 6px; }
.line p { font-size: 11.5px; line-height: 1.5; color: var(--ink-mute); max-width: 76ch; }

/* ── material comparison table ───────────────────────────────── */
.matrix {
  display: grid;
  grid-template-columns: 1.1fr 1fr 1fr 1fr;
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  font-size: 11px;
}
.matrix > div {
  padding: 11px 13px;
  border-bottom: 1px solid var(--line);
  border-right: 1px solid var(--line);
}
.matrix .rh { color: var(--ink-dim); font-family: var(--font-mono); font-size: 9.5px; letter-spacing: 0.08em; text-transform: uppercase; }
.matrix .col-h { background: var(--bg-card); }
.matrix .col-h.ours { background: rgba(227,38,43,0.12); }
.matrix .col-h .name { font-weight: 700; font-size: 12.5px; }
.matrix .col-h .t { font-family: var(--font-mono); font-size: 8.5px; color: var(--ink-dim); letter-spacing: 0.08em; margin-top: 4px; text-transform: uppercase; }
.matrix .col-h.ours .t { color: var(--accent); }
.matrix .v { font-weight: 600; }
.matrix .ours-cell { background: rgba(227,38,43,0.06); }
.matrix .ours-cell .v { color: var(--accent-2); }
.matrix > div:nth-child(4n) { border-right: 0; }

/* ── benefits ────────────────────────────────────────────────── */
.benefits { display: grid; grid-template-columns: repeat(2, 1fr); border-top: 1px solid var(--line); }
.benefit {
  display: grid;
  grid-template-columns: 30px 1fr;
  gap: 13px;
  padding: 15px 22px 15px 0;
  border-bottom: 1px solid var(--line);
}
.benefit:nth-child(odd) { border-right: 1px solid var(--line); padding-right: 22px; }
.benefit:nth-child(even) { padding-left: 22px; }
.benefit .code {
  width: 26px; height: 26px;
  border: 1px solid var(--accent);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-mono); font-size: 11px; color: var(--accent);
}
.benefit h4 { font-size: 13px; margin-bottom: 5px; }
.benefit p { font-size: 11px; line-height: 1.45; color: var(--ink-mute); }

/* ── type cards (med) ────────────────────────────────────────── */
.types { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.type {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 14px 15px;
  background: var(--bg-card);
  display: flex;
  flex-direction: column;
}
.type .top { display: flex; align-items: center; gap: 11px; margin-bottom: 9px; }
.type .id {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  color: var(--accent);
  border: 1px solid var(--line);
  border-radius: 5px;
  padding: 4px 8px;
  background: var(--bg);
}
.type .nm { font-size: 14px; font-weight: 700; }
.type .tg { font-family: var(--font-mono); font-size: 8.5px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--ink-dim); }
.type p { font-size: 10.8px; line-height: 1.45; color: var(--ink-mute); margin-bottom: 11px; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: auto; }
.chip {
  font-family: var(--font-mono);
  font-size: 8.5px;
  letter-spacing: 0.06em;
  color: var(--ink-mute);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 4px 9px;
}

/* ── module cards ────────────────────────────────────────────── */
.mods { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
.mod {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 14px 15px;
  background: var(--bg-card);
}
.mod h4 { font-size: 14px; margin-bottom: 6px; }
.mod p { font-size: 11px; line-height: 1.45; color: var(--ink-mute); margin-bottom: 10px; }

/* ── process steps ───────────────────────────────────────────── */
.steps { display: flex; flex-direction: column; }
.step {
  display: grid;
  grid-template-columns: 54px 1fr 150px;
  gap: 18px;
  align-items: start;
  padding: 16px 0;
  border-top: 1px solid var(--line);
}
.step:last-child { border-bottom: 1px solid var(--line); }
.step .n { font-family: var(--font-mono); font-size: 30px; font-weight: 300; color: var(--accent); line-height: 1; }
.step h4 { font-size: 16px; margin-bottom: 6px; }
.step p { font-size: 11.5px; line-height: 1.5; color: var(--ink-mute); }
.step .out {
  font-family: var(--font-mono);
  font-size: 9px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-dim);
  border-left: 1px solid var(--line);
  padding-left: 14px;
}
.step .out b { display: block; color: var(--ink); font-weight: 600; margin-top: 4px; font-size: 11px; letter-spacing: 0; text-transform: none; font-family: var(--font-sans); }

/* ── packages ────────────────────────────────────────────────── */
.pkgs { display: grid; grid-template-columns: 1fr 1fr; gap: 13px; }
.pkg {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 16px 17px;
  background: var(--bg-card);
  display: flex;
  flex-direction: column;
}
.pkg.featured { border-color: var(--accent); background: rgba(227,38,43,0.06); }
.pkg .tg { font-family: var(--font-mono); font-size: 8.5px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink-dim); }
.pkg.featured .tg { color: var(--accent); }
.pkg h4 { font-size: 17px; margin: 9px 0 8px; }
.pkg .sub { font-size: 10.8px; line-height: 1.45; color: var(--ink-mute); margin-bottom: 12px; }
.pkg ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 7px; margin-top: auto; }
.pkg li { font-size: 10.8px; color: var(--ink); padding-left: 16px; position: relative; line-height: 1.35; }
.pkg li::before { content: "—"; position: absolute; left: 0; color: var(--accent); }

/* ── clients ─────────────────────────────────────────────────── */
.clients { border-top: 1px solid var(--line); }
.client {
  display: grid;
  grid-template-columns: 200px 1fr;
  gap: 20px;
  padding: 14px 0;
  border-bottom: 1px solid var(--line);
  align-items: baseline;
}
.client h4 { font-size: 14px; }
.client p { font-size: 11.5px; line-height: 1.45; color: var(--ink-mute); }

/* ── big message ─────────────────────────────────────────────── */
.msg { display: flex; flex-direction: column; gap: 2px; margin: 4px 0; }
.msg .l { font-size: 40px; font-weight: 800; letter-spacing: -0.03em; line-height: 1.04; }
.msg .l.dim { color: var(--ink-dim); }
.msg .l.acc { color: var(--accent); }

/* ── contact ─────────────────────────────────────────────────── */
.contact-box {
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
}
.crow {
  display: grid;
  grid-template-columns: 200px 1fr;
  border-bottom: 1px solid var(--line);
}
.crow:last-child { border-bottom: 0; }
.crow .k {
  padding: 14px 16px;
  font-family: var(--font-mono);
  font-size: 9.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-dim);
  border-right: 1px solid var(--line);
  background: var(--bg-card);
}
.crow .v { padding: 14px 16px; font-size: 14px; font-weight: 600; }
.crow .v.accent { color: var(--accent); }

/* ── figures (kits doc) ──────────────────────────────────────── */
.fig { border: 1px solid var(--line); border-radius: 8px; overflow: hidden; background: var(--bg-card); }
.fig img { width: 100%; object-fit: cover; }
.fig .cap {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 9px 12px;
  font-family: var(--font-mono);
  font-size: 8.5px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-dim);
  border-top: 1px solid var(--line);
}
.fig .cap b { color: var(--accent); font-weight: 600; }
.gal { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.gal .fig img { height: 30mm; }

/* ── steps (kits process, vertical with code) ───────────────── */
.kstep {
  display: grid;
  grid-template-columns: 40px 1fr;
  gap: 16px;
  padding: 13px 0;
  border-top: 1px solid var(--line);
  align-items: baseline;
}
.kstep:last-child { border-bottom: 1px solid var(--line); }
.kstep .n { font-family: var(--font-mono); font-size: 13px; color: var(--accent); }
.kstep h4 { font-size: 14px; margin-bottom: 5px; }
.kstep p { font-size: 11.5px; line-height: 1.45; color: var(--ink-mute); }

/* ── shared text blocks (also used by the Sunray dossier) ────── */
.blk-k {
  font-family: var(--font-mono);
  font-size: 9px; letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--accent); margin-bottom: 10px;
}
.prose p { font-size: 11.5px; line-height: 1.55; color: var(--ink-mute); margin-bottom: 9px; }
.prose p:last-child { margin-bottom: 0; }
.prose b { color: var(--ink); font-weight: 600; }

/* ── norm chips ──────────────────────────────────────────────── */
.norms { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 12px; }
.norms span {
  font-family: var(--font-mono); font-size: 8.5px; letter-spacing: 0.06em;
  color: var(--ink-mute); border: 1px solid var(--line); border-radius: 999px; padding: 4px 9px;
}
.norms span.hot { border-color: var(--accent); color: var(--accent); }

.spacer-12 { height: 12px; }
.spacer-18 { height: 18px; }
.spacer-24 { height: 24px; }

/* ── screen fit (preview only; print resets) ─────────────────── */
@media print {
  body { background: none; }
  .doc { gap: 0; padding: 0; }
  .page { box-shadow: none; break-after: page; zoom: 1 !important; }
  .page:last-child { break-after: auto; }
}
