/* ============================================================
   VENTUM BRAND GUIDE — Core stylesheet
   ============================================================ */

:root {
  /* PRIMARY */
  --navy:       #0B1F33;
  --navy-deep:  #061320;
  --white:      #FFFFFF;
  --air:        #DDF3FF;

  /* SECONDARY */
  --teal:       #22B8A7;
  --mist:       #E7ECEF;
  --signal:     #2563EB;

  /* ACCENT */
  --efficacy:   #47B881;

  /* INK SCALE */
  --ink-100:    #0B1F33;
  --ink-80:     #2A3A4D;
  --ink-60:     #56657A;
  --ink-40:     #8A98AB;
  --ink-20:     #C6CFD9;
  --ink-10:     #E7ECEF;
  --ink-05:     #F3F6F8;
  --paper:      #FBFCFD;

  /* TYPE */
  --sans: "Geist", "Söhne", "Helvetica Neue", Helvetica, Arial, sans-serif;
  --mono: "Geist Mono", "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;

  /* SCALE */
  --t-display: 88px;
  --t-h1:      56px;
  --t-h2:      40px;
  --t-h3:      28px;
  --t-h4:      20px;
  --t-body:    17px;
  --t-small:   14px;
  --t-micro:   11px;

  /* RHYTHM */
  --gutter:    32px;
  --section-y: 140px;
  --content-w: 1180px;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }

body {
  font-family: var(--sans);
  background: var(--paper);
  color: var(--ink-100);
  font-size: var(--t-body);
  line-height: 1.55;
  /* No ss01/ss02: in Geist those swap 'a' for an alternate glyph (a.ss01/
     a.ss02) that has no reverse-Unicode mapping, so Chromium on Linux
     (production) drops every lowercase 'a' from the PDF/PPTX text layer even
     though it renders visually. Default 'a' extracts correctly everywhere.
     (cv11 is not a real Geist feature — it was a no-op.) */
  font-feature-settings: normal;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

/* ---------- TYPE ---------- */
h1, h2, h3, h4 {
  margin: 0;
  font-weight: 500;
  letter-spacing: -0.02em;
  line-height: 1.04;
  color: var(--ink-100);
  text-wrap: balance;
}
h1 { font-size: var(--t-h1); letter-spacing: -0.03em; }
h2 { font-size: var(--t-h2); }
h3 { font-size: var(--t-h3); letter-spacing: -0.015em; }
h4 { font-size: var(--t-h4); letter-spacing: -0.01em; }

p { margin: 0; text-wrap: pretty; }

.display {
  font-size: var(--t-display);
  font-weight: 400;
  letter-spacing: -0.04em;
  line-height: 0.96;
}

.mono {
  font-family: var(--mono);
  /* Keep "zero" (slashed zero) but drop ss01 — in Geist Mono ss01 also swaps
     'a' for an alternate that drops from the PDF/PPTX text layer on Linux. */
  font-feature-settings: "zero";
  letter-spacing: 0;
}
.eyebrow {
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--ink-60);
}
.eyebrow.on-dark { color: rgba(255,255,255,0.55); }
.eyebrow .dot {
  display: inline-block;
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--teal);
  margin-right: 10px; vertical-align: middle;
}

.lede {
  font-size: 22px;
  line-height: 1.45;
  color: var(--ink-80);
  letter-spacing: -0.005em;
  text-wrap: pretty;
}

/* ---------- LAYOUT ---------- */
.wrap {
  max-width: var(--content-w);
  margin: 0 auto;
  padding: 0 48px;
}
section.chapter {
  padding: var(--section-y) 0;
  border-top: 1px solid var(--ink-10);
}
section.chapter:first-of-type { border-top: none; }
section.chapter.on-navy {
  background: var(--navy);
  color: var(--white);
  border-top: none;
}
section.chapter.on-air {
  background: linear-gradient(180deg, var(--air) 0%, #F3FAFF 100%);
  border-top: none;
}
section.chapter.on-mist {
  background: var(--ink-05);
  border-top: none;
}

.on-navy h1, .on-navy h2, .on-navy h3, .on-navy h4 { color: var(--white); }
.on-navy .lede { color: rgba(255,255,255,0.78); }
.on-navy .eyebrow { color: rgba(255,255,255,0.55); }
/* Defensive overrides so light-card classes never inherit white from on-navy parents,
   and so .muted text inside on-navy sections stays legible. */
.on-navy .muted { color: rgba(255,255,255,0.65); }
.on-navy .card:not(.on-navy) { color: var(--ink-100); }
.on-navy .card:not(.on-navy) .muted { color: var(--ink-60); }
.on-navy .card:not(.on-navy) .lede { color: var(--ink-80); }
.on-navy .card:not(.on-navy) .eyebrow { color: var(--ink-60); }
.on-navy .card.on-navy .muted { color: rgba(255,255,255,0.65); }

/* ---------- CHAPTER HEADER ---------- */
.chapter-head {
  display: grid;
  grid-template-columns: 240px 1fr;
  gap: 48px;
  margin-bottom: 72px;
  align-items: start;
}
.chapter-num {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--ink-40);
  letter-spacing: 0.18em;
  text-transform: uppercase;
  padding-top: 8px;
  border-top: 1px solid var(--ink-20);
}
.on-navy .chapter-num { color: rgba(255,255,255,0.45); border-color: rgba(255,255,255,0.18); }
.chapter-title h1 { margin-bottom: 16px; }
.chapter-title .lede { max-width: 720px; }

/* ---------- GRID HELPERS ---------- */
.grid { display: grid; gap: var(--gutter); }
.g-2 { grid-template-columns: repeat(2, 1fr); }
.g-3 { grid-template-columns: repeat(3, 1fr); }
.g-4 { grid-template-columns: repeat(4, 1fr); }
.g-6 { grid-template-columns: repeat(6, 1fr); }

.row { display: flex; gap: var(--gutter); flex-wrap: wrap; }
.stack { display: flex; flex-direction: column; gap: 16px; }
.stack-sm { display: flex; flex-direction: column; gap: 8px; }
.stack-lg { display: flex; flex-direction: column; gap: 32px; }

/* ---------- CARDS ---------- */
.card {
  background: var(--white);
  border: 1px solid var(--ink-10);
  border-radius: 4px;
  padding: 32px;
}
.card.flush { padding: 0; overflow: hidden; }
.card.on-navy {
  background: var(--navy);
  color: var(--white);
  border-color: rgba(255,255,255,0.12);
}
.card .label {
  font-family: var(--mono);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--ink-40);
  margin-bottom: 14px;
}

/* ---------- BUTTONS / CTA ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 14px 22px;
  border-radius: 2px;
  font-family: var(--sans);
  font-size: 15px;
  font-weight: 500;
  letter-spacing: -0.005em;
  text-decoration: none;
  border: 1px solid var(--navy);
  background: var(--navy);
  color: var(--white);
  transition: all .18s ease;
}
.btn:hover { background: var(--navy-deep); border-color: var(--navy-deep); }
.btn.ghost { background: transparent; color: var(--navy); }
.btn.on-dark { background: var(--white); color: var(--navy); border-color: var(--white); }
.btn.on-dark.ghost { background: transparent; color: var(--white); border-color: rgba(255,255,255,0.4); }
.btn .arrow { width: 16px; height: 1px; background: currentColor; position: relative; }
.btn .arrow::after {
  content: ""; position: absolute; right: 0; top: -3px;
  width: 7px; height: 7px;
  border-right: 1px solid currentColor;
  border-top: 1px solid currentColor;
  transform: rotate(45deg);
}

/* ---------- IMAGE PLACEHOLDERS ---------- */
.imgph {
  position: relative;
  background:
    repeating-linear-gradient(135deg,
      rgba(11,31,51,0.05) 0px,
      rgba(11,31,51,0.05) 1px,
      transparent 1px,
      transparent 14px),
    var(--ink-05);
  border: 1px solid var(--ink-10);
  border-radius: 2px;
  display: flex; align-items: center; justify-content: center;
  color: var(--ink-60);
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  text-align: center;
  padding: 16px;
  overflow: hidden;
}
.imgph.dark {
  background:
    repeating-linear-gradient(135deg,
      rgba(255,255,255,0.05) 0px,
      rgba(255,255,255,0.05) 1px,
      transparent 1px,
      transparent 14px),
    #122a40;
  border-color: rgba(255,255,255,0.08);
  color: rgba(255,255,255,0.55);
}
.imgph.air {
  background:
    repeating-linear-gradient(135deg,
      rgba(37,99,235,0.06) 0px,
      rgba(37,99,235,0.06) 1px,
      transparent 1px,
      transparent 14px),
    linear-gradient(180deg, #EAF6FF, #DDF3FF);
  border-color: #BFE1F5;
  color: #2a5a7e;
}
.imgph .ph-tag {
  position: absolute; top: 12px; left: 12px;
  font-size: 10px;
  background: rgba(11,31,51,0.06);
  padding: 4px 8px;
  border-radius: 2px;
}
.imgph.dark .ph-tag { background: rgba(255,255,255,0.08); color: rgba(255,255,255,0.7); }
.imgph .ph-label { max-width: 70%; line-height: 1.4; }

/* ---------- KPI / STAT ---------- */
.stat .num {
  font-family: var(--sans);
  font-size: 92px;
  font-weight: 400;
  letter-spacing: -0.05em;
  line-height: 0.9;
  color: var(--navy);
}
.stat .num.air { color: var(--air); }
.stat .num.teal { color: var(--teal); }
.stat .num.green { color: var(--efficacy); }
.stat .unit {
  font-family: var(--mono);
  font-size: 13px;
  color: var(--ink-60);
  margin-top: 12px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
}
.stat .desc { margin-top: 8px; color: var(--ink-80); max-width: 320px; }

/* ---------- DIVIDERS ---------- */
.hr-thin { height: 1px; background: var(--ink-10); margin: 24px 0; }
.hr-thin.on-dark { background: rgba(255,255,255,0.12); }

/* ---------- TAG ---------- */
.tag {
  display: inline-flex; align-items: center;
  padding: 6px 10px;
  border: 1px solid var(--ink-20);
  border-radius: 2px;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  color: var(--ink-60);
  text-transform: uppercase;
  background: var(--white);
}
.tag.on-dark { border-color: rgba(255,255,255,0.18); color: rgba(255,255,255,0.7); background: transparent; }
.tag.solid { background: var(--navy); color: var(--white); border-color: var(--navy); }
.tag.teal { background: var(--teal); color: var(--white); border-color: var(--teal); }
.tag.green { background: var(--efficacy); color: var(--white); border-color: var(--efficacy); }

/* ---------- LIST ---------- */
ul.clean { list-style: none; padding: 0; margin: 0; }
ul.clean li {
  padding: 16px 0;
  border-top: 1px solid var(--ink-10);
  display: grid;
  grid-template-columns: 28px 1fr;
  gap: 16px;
  align-items: baseline;
}
ul.clean li:first-child { border-top: none; padding-top: 0; }
ul.clean li .idx {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--ink-40);
  letter-spacing: 0.1em;
}
.on-navy ul.clean li { border-color: rgba(255,255,255,0.10); }
.on-navy ul.clean li .idx { color: rgba(255,255,255,0.45); }

/* ---------- SIDE NAV ---------- */
.sidenav {
  position: fixed;
  top: 32px; left: 32px;
  z-index: 100;
  background: rgba(251,252,253,0.94);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid var(--ink-10);
  border-radius: 4px;
  padding: 14px 16px 14px 18px;
  font-family: var(--mono);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  max-height: calc(100vh - 64px);
  overflow-y: auto;
  width: 200px;
  max-width: 200px;
}
.sidenav .brand {
  display: flex; align-items: center; gap: 8px;
  margin-bottom: 14px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--ink-10);
}
.sidenav .brand img { height: 18px; width: auto; }
.sidenav .brand .meta {
  font-size: 9px;
  color: var(--ink-40);
  letter-spacing: 0.14em;
}
.sidenav ol { list-style: none; padding: 0; margin: 0; counter-reset: ch; }
.sidenav ol li { counter-increment: ch; margin: 0; padding: 4px 0; }
.sidenav ol.sidenav-grouped { counter-reset: ch; }
.sidenav ol.sidenav-grouped li.sidenav-part {
  counter-increment: none;
  list-style: none;
  margin: 16px 0 6px;
  padding: 6px 0 4px;
  font-family: var(--mono);
  font-size: 9px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink-100);
  border-top: 1px solid var(--ink-10);
  font-weight: 500;
}
.sidenav ol.sidenav-grouped li.sidenav-part:first-child {
  margin-top: 4px;
  border-top: none;
  padding-top: 0;
}
.sidenav ol.sidenav-grouped li.sidenav-part::before { content: none !important; }
.sidenav ol li a {
  color: var(--ink-60);
  text-decoration: none;
  display: grid;
  grid-template-columns: 24px 1fr;
  gap: 8px;
  align-items: baseline;
  transition: color .12s ease;
}
.sidenav ol li a::before {
  content: counter(ch, decimal-leading-zero);
  color: var(--ink-40);
  font-size: 9px;
}
.sidenav ol li a:hover { color: var(--navy); }
.sidenav ol li a.active { color: var(--navy); font-weight: 500; }

/* ---------- TOP MARK (hero) ---------- */
.topmark {
  position: absolute; top: 32px; right: 48px;
  z-index: 5;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.55);
  display: flex; gap: 16px; align-items: center;
}
.topmark .pill {
  border: 1px solid rgba(255,255,255,0.22);
  padding: 5px 10px;
  border-radius: 999px;
}

/* ---------- FOG GRADIENT BG (used in hero & ambient) ---------- */
.fog-bg {
  background-color: var(--navy);
  background-image:
    radial-gradient(ellipse 80% 60% at 20% 110%, rgba(34,184,167,0.22), transparent 60%),
    radial-gradient(ellipse 70% 50% at 90% 0%, rgba(37,99,235,0.28), transparent 55%),
    radial-gradient(ellipse 60% 40% at 50% 50%, rgba(221,243,255,0.10), transparent 60%);
}
/* Compound: a frame-shadow card that should also carry the fog atmosphere.
   Without this, .frame-shadow's `background: white` shorthand (declared later)
   nullifies .fog-bg's background-image, producing a white card with invisible
   white text. */
.frame-shadow.fog-bg {
  background-color: var(--navy);
  background-image:
    radial-gradient(ellipse 80% 60% at 20% 110%, rgba(34,184,167,0.22), transparent 60%),
    radial-gradient(ellipse 70% 50% at 90% 0%, rgba(37,99,235,0.28), transparent 55%),
    radial-gradient(ellipse 60% 40% at 50% 50%, rgba(221,243,255,0.10), transparent 60%);
  color: var(--white);
}
.chapter.on-navy.fog-bg {
  background-color: var(--navy);
  background-image:
    radial-gradient(ellipse 80% 60% at 20% 110%, rgba(34,184,167,0.22), transparent 60%),
    radial-gradient(ellipse 70% 50% at 90% 0%, rgba(37,99,235,0.28), transparent 55%),
    radial-gradient(ellipse 60% 40% at 50% 50%, rgba(221,243,255,0.10), transparent 60%);
}

/* ---------- COLOR SWATCH ---------- */
.swatch {
  border-radius: 4px;
  border: 1px solid var(--ink-10);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  background: var(--white);
}
.swatch .chip { height: 180px; }
.swatch .meta { padding: 16px 18px 20px; }
.swatch .meta .name { font-size: 16px; font-weight: 500; letter-spacing: -0.01em; margin-bottom: 10px; }
.swatch .meta .row-kv { display: flex; justify-content: space-between; font-family: var(--mono); font-size: 11px; color: var(--ink-60); padding: 3px 0; letter-spacing: 0.04em; }
.swatch .meta .row-kv span:first-child { color: var(--ink-40); }

/* ---------- TYPE SPECIMEN ---------- */
.specimen {
  display: grid;
  grid-template-columns: 200px 1fr;
  gap: 32px;
  padding: 32px 0;
  border-top: 1px solid var(--ink-10);
  align-items: baseline;
}
.specimen:first-of-type { border-top: none; padding-top: 0; }
.specimen .spec-meta .spec-name { font-family: var(--mono); font-size: 11px; text-transform: uppercase; letter-spacing: 0.12em; color: var(--ink-60); margin-bottom: 6px; }
.specimen .spec-meta .spec-size { font-family: var(--mono); font-size: 11px; color: var(--ink-40); letter-spacing: 0.06em; }
.specimen .spec-meta .spec-use { font-size: 13px; color: var(--ink-60); margin-top: 10px; line-height: 1.4; max-width: 160px; }

/* ---------- PILLAR ---------- */
.pillar {
  background: var(--white);
  border: 1px solid var(--ink-10);
  padding: 32px;
  border-radius: 4px;
  display: flex;
  flex-direction: column;
  gap: 20px;
  min-height: 340px;
}
.pillar .pillar-num {
  font-family: var(--mono);
  font-size: 11px;
  color: var(--teal);
  letter-spacing: 0.14em;
  text-transform: uppercase;
}
.pillar h3 { font-size: 24px; }
.pillar .sample {
  font-family: var(--sans);
  font-size: 15px;
  color: var(--ink-80);
  line-height: 1.5;
  border-left: 2px solid var(--teal);
  padding-left: 14px;
  margin-top: auto;
}

/* ---------- DO / DONT ---------- */
.dd { padding: 24px; border-radius: 3px; }
.dd.do  { background: rgba(71,184,129,0.06); border: 1px solid rgba(71,184,129,0.25); }
.dd.dont { background: rgba(11,31,51,0.04); border: 1px solid var(--ink-20); }
.dd .label {
  font-family: var(--mono);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  margin-bottom: 14px;
  display: flex; align-items: center; gap: 8px;
}
.dd.do .label { color: var(--efficacy); }
.dd.dont .label { color: var(--ink-60); }
.dd ul { padding: 0; margin: 0; list-style: none; }
.dd li {
  padding: 8px 0;
  border-top: 1px solid rgba(11,31,51,0.06);
  font-size: 14.5px;
  color: var(--ink-80);
  line-height: 1.5;
}
.dd li:first-child { border-top: none; }

/* ---------- TEMPLATE FRAME (one-pagers, brochures) ---------- */
.frame-meta {
  display: flex; justify-content: space-between; align-items: baseline;
  margin-bottom: 14px;
  font-family: var(--mono); font-size: 11px;
  text-transform: uppercase; letter-spacing: 0.12em;
  color: var(--ink-60);
}
.frame-meta .frame-tag { color: var(--ink-40); }
.frame-shadow {
  box-shadow:
    0 1px 0 rgba(11,31,51,0.04),
    0 30px 60px -20px rgba(11,31,51,0.18),
    0 12px 24px -10px rgba(11,31,51,0.08);
  background: var(--white);
  border: 1px solid var(--ink-10);
  border-radius: 2px;
}

/* ---------- ICONS ---------- */
.icon {
  width: 28px; height: 28px;
  display: inline-flex; align-items: center; justify-content: center;
}
.icon svg { width: 100%; height: 100%; }
.icon.lg { width: 40px; height: 40px; }

/* utility */
.mt-8 { margin-top: 8px; } .mt-16 { margin-top: 16px; } .mt-24 { margin-top: 24px; } .mt-32 { margin-top: 32px; } .mt-48 { margin-top: 48px; } .mt-64 { margin-top: 64px; }
.mb-8 { margin-bottom: 8px; } .mb-16 { margin-bottom: 16px; } .mb-24 { margin-bottom: 24px; } .mb-32 { margin-bottom: 32px; }
.tac { text-align: center; }
.muted { color: var(--ink-60); }
.muted-d { color: rgba(255,255,255,0.62); }
.divider { height: 1px; background: var(--ink-10); width: 100%; }
.divider.on-dark { background: rgba(255,255,255,0.12); }

/* Print niceties */
@media print {
  .sidenav { display: none; }
  section.chapter { page-break-inside: avoid; padding: 60px 0; }
}

/* ---------- COLLAPSIBLE SIDENAV ---------- */
.sidenav { transition: transform 0.22s ease; }
body.sidenav-collapsed .sidenav { transform: translateX(calc(-100% - 40px)); }
.sidenav-toggle {
  position: fixed; top: 32px; left: 32px; z-index: 200;
  width: 38px; height: 38px;
  background: rgba(251,252,253,0.96);
  border: 1px solid var(--ink-10);
  border-radius: 4px;
  cursor: pointer;
  font-size: 16px;
  display: flex; align-items: center; justify-content: center;
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  transition: transform 0.22s ease, box-shadow 0.18s;
  color: var(--ink-100);
}
body:not(.sidenav-collapsed) .sidenav-toggle { transform: translateX(170px); }
.sidenav-toggle:hover { box-shadow: 0 8px 18px -4px rgba(11,31,51,0.20); }
.sidenav-studio-link {
  display: block;
  padding: 10px 12px;
  margin: 4px 0 14px;
  background: var(--navy);
  color: white !important;
  text-decoration: none;
  border-radius: 3px;
  font-size: 10px;
  letter-spacing: 0.16em;
  text-align: center;
  font-weight: 500;
  font-family: var(--mono);
  text-transform: uppercase;
}
.sidenav-studio-link:hover { background: var(--navy-deep); }

.sidenav-studio-link,
.sidenav > a.sidenav-studio-link {
  display: block !important;
  visibility: visible !important;
  opacity: 1 !important;
  height: auto !important;
  width: auto !important;
  padding: 10px 12px !important;
  margin: 4px 0 14px !important;
  background: #0B1F33 !important;
  color: #ffffff !important;
  text-decoration: none !important;
  text-align: center !important;
  text-transform: uppercase !important;
  letter-spacing: 0.16em !important;
  font-family: "Geist Mono", monospace !important;
  font-size: 10px !important;
  font-weight: 500 !important;
  border-radius: 3px !important;
  border: none !important;
  position: static !important;
  transform: none !important;
}
.studio-fixed-btn {
  position: fixed;
  top: 32px;
  right: 32px;
  z-index: 300;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  background: #0B1F33;
  color: white;
  text-decoration: none;
  font-family: "Geist Mono", monospace;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  border-radius: 3px;
  box-shadow: 0 6px 16px -4px rgba(11,31,51,0.25);
  transition: all 0.15s;
}
.studio-fixed-btn:hover {
  background: #061320;
  transform: translateY(-1px);
}
@media print { .studio-fixed-btn { display: none; } }
