/* ============================================================
   SIBIN — subpage patterns (ecosystems, impact, labs,
   insights, about, contact)
   ============================================================ */

/* numbered capability rail */
.cap-rail {
  display: flex;
  flex-wrap: wrap;
  border-top: 1px solid var(--line-dark);
  margin-top: 48px;
}
.light .cap-rail { border-top-color: var(--line-light); }
.cap-rail .cap {
  flex: 1 1 200px;
  padding: 24px 28px 24px 0;
  border-bottom: 1px solid var(--line-dark);
}
.light .cap-rail .cap { border-bottom-color: var(--line-light); }
.cap-rail .cap .n {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.18em;
  color: var(--cobalt);
  margin-bottom: 10px;
}
.cap-rail .cap .t { font-size: 16px; font-weight: 500; letter-spacing: -0.01em; }

/* ecosystem block */
.eco-block {
  display: grid;
  grid-template-columns: 0.32fr 1fr;
  gap: 64px;
  padding: 110px 0;
  border-top: 1px solid var(--line-dark);
}
.light .eco-block { border-top-color: var(--line-light); }
.eco-block:first-of-type { border-top: none; padding-top: 0; }
.eco-block:last-child { padding-bottom: 0; }
.eco-block .eb-num {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 88px;
  line-height: 0.9;
  color: var(--cobalt);
  letter-spacing: -0.03em;
}
.eco-block .eb-tag {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text-lo);
  margin-top: 18px;
}
.eco-block h3 { margin-bottom: 22px; }
.eco-block .proof {
  margin-top: 40px;
  padding-top: 24px;
  border-top: 1px dashed var(--line-dark);
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-lo);
}

/* 7-step delivery model */
.delivery-track { min-height: 150vh; position: relative; }
.delivery-sticky {
  position: sticky;
  top: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  padding-top: 96px; /* clears the fixed nav while pinned; no extra gap above the heading */
}
.delivery-track { padding-top: 0; min-height: 120vh; }
.delivery-track.section { padding-top: 0; padding-bottom: 40px; }
.delivery-rail {
  position: relative;
  margin-top: 96px;
  padding-bottom: 24px;
}
.delivery-line {
  position: absolute;
  top: 7px;
  left: 0; right: 0;
  height: 1px;
  background: var(--line-light);
}
.delivery-line .fill {
  display: block;
  height: 100%;
  background: var(--cobalt);
  transform-origin: 0 50%;
  transform: scaleX(0);
}
.delivery-steps {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 12px;
  position: relative;
}
.d-step { padding-top: 0; }
.d-step .dot {
  width: 15px; height: 15px;
  border-radius: 50%;
  background: var(--white);
  border: 1.5px solid rgba(12, 17, 26, 0.35);
  margin-bottom: 28px;
  transition: background 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}
.d-step.active .dot {
  background: var(--cobalt);
  border-color: var(--cobalt);
  box-shadow: 0 0 0 6px var(--cobalt-soft);
}
.d-step .dn {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.18em;
  color: var(--text-dark-lo);
  margin-bottom: 8px;
}
.d-step .dt { font-size: 17px; font-weight: 500; letter-spacing: -0.01em; transition: color 0.3s ease; color: rgba(12, 17, 26, 0.35); }
.d-step.active .dt { color: var(--text-dark); }
.d-step .dd {
  font-family: var(--font-mono);
  font-size: 9.5px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-dark-lo);
  margin-top: 6px;
  opacity: 0;
  transition: opacity 0.3s ease;
}
.d-step.active .dd { opacity: 0.7; }

/* impact story — four moves */
.story-block { padding: 110px 0; border-top: 1px solid var(--line-dark); }
.story-block:first-of-type { border-top: none; }
.story-block .story-photo {
  width: 100%;
  aspect-ratio: 21 / 9;
  display: block;
  background: var(--ink-raised);
  margin-bottom: 56px;
}
.story-block h3 { margin-bottom: 16px; }
.four-moves {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 40px;
  margin-top: 56px;
}
.move .m-tag {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--cobalt);
  margin-bottom: 14px;
  padding-top: 16px;
  border-top: 1px solid var(--line-dark);
}
.move p { font-size: 15px; line-height: 1.65; color: var(--text-lo); }

/* quiet metric row */
.metric-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0;
  border-top: 1px solid var(--line-light);
  border-bottom: 1px solid var(--line-light);
}
.metric-row .m {
  flex: 1 1 160px;
  padding: 40px 32px 40px 0;
  border-right: 1px solid var(--line-light);
}
.metric-row .m:last-child { border-right: none; }
.metric-row .m + .m { padding-left: 32px; }
.metric-row .m .v {
  font-size: clamp(38px, 3.4vw, 56px);
  font-weight: 500;
  letter-spacing: -0.03em;
  font-variant-numeric: tabular-nums;
}
.metric-row .m .l {
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--text-dark-lo);
  margin-top: 10px;
}

/* labs editorial rows */
.lab-row {
  display: grid;
  grid-template-columns: 0.3fr 1fr;
  gap: 64px;
  padding: 96px 0;
  border-top: 1px solid var(--line-dark);
}
.lab-row:first-of-type { border-top: none; }
.lab-row .lr-num {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 110px;
  line-height: 0.85;
  color: var(--cobalt);
  letter-spacing: -0.04em;
}
.lab-row h3 { margin-bottom: 20px; }

/* insights archive */
.filter-row {
  display: flex;
  gap: 28px;
  flex-wrap: wrap;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--text-lo);
  padding: 20px 0;
  border-top: 1px solid var(--line-dark);
  border-bottom: 1px solid var(--line-dark);
  margin-bottom: 72px;
}
.filter-row button {
  background: none;
  border: none;
  font: inherit;
  color: inherit;
  letter-spacing: inherit;
  text-transform: inherit;
  cursor: pointer;
  padding: 2px 0;
}
.filter-row button.on { color: var(--cobalt); }
.archive {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 56px;
}
.entry { display: flex; flex-direction: column; gap: 18px; }
.entry .date {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.2em;
  color: var(--cobalt);
}
.entry h3 {
  font-size: clamp(24px, 2vw, 32px);
  font-weight: 500;
  letter-spacing: -0.02em;
  line-height: 1.15;
}
.entry h3 a:hover { color: var(--cobalt); transition: color 0.2s ease; }
.entry .kind {
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-lo);
}
.entry p { font-size: 15px; color: var(--text-lo); line-height: 1.65; }
.entry .author {
  font-size: 13.5px;
  color: var(--text-lo);
  border-top: 1px solid var(--line-dark);
  padding-top: 14px;
  margin-top: auto;
}

/* about — leadership rows reuse home styles */
.partners-row {
  display: flex;
  flex-wrap: wrap;
  gap: 20px 56px;
  align-items: baseline;
  font-family: var(--font-mono);
  font-size: 13px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-dark-lo);
  margin-top: 56px;
}

/* footprint map */
.footprint-wrap {
  display: grid;
  grid-template-columns: 1fr 0.9fr;
  gap: 80px;
  align-items: center;
}
.footprint-svg svg { width: 100%; max-width: 520px; height: auto; }
.fp-list { display: flex; flex-direction: column; }
.fp-item {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 24px;
  align-items: baseline;
  padding: 22px 0;
  border-bottom: 1px solid var(--line-light);
}
.fp-item .s { font-size: 24px; font-weight: 500; letter-spacing: -0.015em; }
.fp-item .y {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.18em;
  color: var(--text-dark-lo);
}

/* contact */
.contact-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 96px;
  align-items: start;
}
.c-form { display: flex; flex-direction: column; gap: 28px; }
.c-field { display: flex; flex-direction: column; gap: 10px; }
.c-field label {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--text-lo);
}
.c-field input, .c-field select, .c-field textarea {
  background: transparent;
  border: none;
  border-bottom: 1px solid rgba(242, 245, 250, 0.22);
  color: var(--text-hi);
  font-family: var(--font-sans);
  font-size: 18px;
  padding: 10px 0 14px;
  border-radius: 0;
  transition: border-color 0.25s ease;
}
.c-field select { appearance: none; cursor: pointer; }
.c-field select option { color: var(--text-dark); }
.c-field textarea { resize: vertical; min-height: 120px; }
.c-field input:focus, .c-field select:focus, .c-field textarea:focus {
  outline: none;
  border-bottom-color: var(--cobalt);
}
.c-note {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.14em;
  color: var(--text-lo);
}
.c-confirm {
  display: none;
  padding: 18px 22px;
  border: 1px solid rgba(45, 91, 255, 0.4);
  border-radius: 12px;
  font-size: 15px;
  color: var(--text-hi);
}
.c-confirm.show { display: block; }

.pathway-tiles { display: flex; flex-direction: column; gap: 2px; }
.pathway {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 24px;
  align-items: center;
  padding: 36px 32px;
  background: var(--ink-raised);
  border: 1px solid var(--line-dark);
  border-radius: 14px;
  margin-bottom: 14px;
  transition: border-color 0.25s ease, transform 0.25s ease;
}
.pathway:hover { border-color: rgba(45, 91, 255, 0.45); transform: translateY(-2px); }
.pathway h3 { font-size: 21px; font-weight: 500; letter-spacing: -0.01em; margin-bottom: 8px; }
.pathway p { font-size: 14.5px; color: var(--text-lo); }
.pathway .arrow { color: var(--cobalt); font-size: 22px; }

.direct-lines {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 48px;
  margin-top: 72px;
}
.direct-lines .dl h4 {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--text-lo);
  font-weight: 400;
  margin-bottom: 16px;
}
.direct-lines .dl a { font-size: 17px; color: var(--text-hi); }
.direct-lines .dl a:hover { color: var(--cobalt); }
.direct-lines .dl p { font-size: 15px; color: var(--text-lo); line-height: 1.7; }

/* ---------- closing CTA (black, photo right, particle bg) ---------- */
.closing-cta {
  position: relative;
  overflow: hidden;
  background: var(--void);
  color: var(--text-hi);
  padding: 140px max(24px, calc((100vw - var(--max-w)) / 2));
  border-top: 1px solid var(--line-dark);
}
.closing-cta .cta-particles {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;
  display: block;
}
.closing-cta-inner {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 72px;
  align-items: center;
}
.closing-cta .cta-copy .eyebrow { margin-bottom: 28px; }
.closing-cta .cta-copy h2 {
  margin-bottom: 24px;
  font-size: clamp(28px, 3vw, 44px);
  letter-spacing: -0.02em;
  line-height: 1.12;
}
.closing-cta .cta-copy .body-copy { margin-bottom: 36px; }
.closing-cta .cta-photo {
  position: relative;
}
.closing-cta .cta-photo image-slot,
.closing-cta .cta-photo .cta-img {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
  background: rgba(12, 17, 26, 0.6);
  border: 1px solid var(--line-dark);
  border-radius: 16px;
  overflow: hidden;
  object-fit: cover;
}
.closing-cta .cta-photo::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 16px;
  pointer-events: none;
  box-shadow: 0 0 60px rgba(45, 91, 255, 0.18);
}

/* ============================================================
   LIGHT THEME — applied to subpages via body.light-theme.
   Remaps surface/text tokens to light; the closing CTA and the
   footer re-declare the dark tokens so they stay black.
   (Homepage has no .light-theme class, so it stays dark.)
   ============================================================ */
body.light-theme {
  --void: #FAFBFD;
  --ink: #FFFFFF;
  --ink-raised: #FFFFFF;
  --text-hi: #0C111A;
  --text-lo: rgba(12, 17, 26, 0.62);
  --line-dark: rgba(12, 17, 26, 0.12);
  background: #FAFBFD;
  color: #0C111A;
}

/* nav: light glass when scrolled, light mobile sheet */
body.light-theme .site-nav.scrolled {
  background: rgba(250, 251, 253, 0.82);
  border-bottom-color: rgba(12, 17, 26, 0.10);
}
body.light-theme .mobile-menu { background: rgba(250, 251, 253, 0.97); }

/* hero: white with a soft cobalt wash */
body.light-theme .subpage-hero {
  background:
    radial-gradient(ellipse 60% 50% at 75% 10%, rgba(45, 91, 255, 0.10), transparent 65%),
    #FAFBFD;
}

/* contact form fields on light */
body.light-theme .c-field input,
body.light-theme .c-field select,
body.light-theme .c-field textarea {
  color: #0C111A;
  border-bottom-color: rgba(12, 17, 26, 0.22);
}
body.light-theme .c-field input:focus,
body.light-theme .c-field select:focus,
body.light-theme .c-field textarea:focus { border-bottom-color: var(--cobalt); }

/* contact pathway tiles: subtle light cards */
body.light-theme .pathway {
  background: #FFFFFF;
  border-color: rgba(12, 17, 26, 0.12);
  box-shadow: 0 12px 40px -28px rgba(12, 17, 26, 0.4);
}
body.light-theme .pathway:hover { border-color: rgba(45, 91, 255, 0.45); }

/* footprint map outline: dark stroke on light */
body.light-theme .footprint-svg svg polygon { stroke: rgba(12, 17, 26, 0.32); }

/* the closing CTA stays DARK — re-declare dark tokens for its subtree */
body.light-theme .closing-cta {
  --void: #07090D;
  --ink-raised: #131A26;
  --text-hi: #F2F5FA;
  --text-lo: rgba(242, 245, 250, 0.62);
  --line-dark: rgba(242, 245, 250, 0.08);
  background: #07090D;
  color: #F2F5FA;
  border-top: none;
}
body.light-theme .closing-cta .btn-ghost { color: #F2F5FA; }

/* footer stays DARK — re-declare dark tokens for its subtree */
body.light-theme .site-footer {
  --void: #07090D;
  --text-hi: #F2F5FA;
  --text-lo: rgba(242, 245, 250, 0.62);
  --line-dark: rgba(242, 245, 250, 0.08);
  background: #07090D;
  color: #F2F5FA;
}

/* responsive */
@media (max-width: 900px) {
  .eco-block, .lab-row { grid-template-columns: 1fr; gap: 28px; }
  .four-moves { grid-template-columns: 1fr 1fr; }
  .archive { grid-template-columns: 1fr; }
  .footprint-wrap { grid-template-columns: 1fr; }
  .contact-grid { grid-template-columns: 1fr; gap: 64px; }
  .delivery-steps { grid-template-columns: 1fr; gap: 28px; }
  .delivery-line { display: none; }
  .d-step .dot { margin-bottom: 12px; }
  .direct-lines { grid-template-columns: 1fr; }
  .closing-cta-inner { grid-template-columns: 1fr; gap: 48px; }
  .closing-cta { padding-top: 96px; padding-bottom: 96px; }
}
@media (max-width: 560px) {
  .four-moves { grid-template-columns: 1fr; }
}


/* ---------- consistent subpage hero (copy + particle network) ---------- */
.subpage-hero .hero-2col { display: grid; grid-template-columns: 1.05fr 0.95fr; gap: 56px; align-items: center; }
.subpage-hero .hero-copy { max-width: 60ch; }
.subpage-hero .hero-copy .btn-row { margin-top: 32px; }
.subpage-hero .hero-particles { position: relative; width: 100%; height: 360px; }
.subpage-hero .hero-particles canvas { width: 100%; height: 100%; display: block; }
.subpage-hero .who-stats { margin-top: 64px; }
@media (max-width: 900px) {
  .subpage-hero .hero-2col { grid-template-columns: 1fr; gap: 32px; }
  .subpage-hero .hero-particles { height: 220px; order: -1; }
}

/* ---------- image-banner hero (About / Ecosystems / Products / Future Labs / Insights) ---------- */
.hero-banner {
  position: relative;
  min-height: min(1024px, 100vh);
  display: flex;
  align-items: flex-end;
  padding: 0 max(24px, calc((100vw - var(--max-w)) / 2)) 20vh;
  overflow: hidden;
  background: #07090D;
}
.hero-banner .hb-bg {
  position: absolute;
  inset: 0;
  background-image: url('prologue-aerial.jpg');
  background-size: cover;
  background-position: center 28%;
  z-index: 0;
  transform: scale(1.04);
  animation: hb-zoom 18s ease-out forwards;
}
@keyframes hb-zoom {
  from { transform: scale(1.04); }
  to { transform: scale(1.16); }
}
@media (prefers-reduced-motion: reduce) {
  .hero-banner .hb-bg { animation: none; transform: scale(1.06); }
}
/* smooth merge into the white section below */
.hero-banner .hb-fade {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background:
    linear-gradient(to bottom, rgba(7,9,13,0.10) 0%, rgba(7,9,13,0.0) 30%, rgba(250,251,253,0.0) 58%, rgba(250,251,253,0.72) 84%, #FAFBFD 100%),
    linear-gradient(to top, rgba(7,9,13,0.55), transparent 45%);
}
.hero-banner .hb-inner { position: relative; z-index: 2; max-width: 62ch; }
.hero-banner .hb-inner h1 { color: #F5F8FE; text-shadow: 0 2px 30px rgba(7,9,13,0.5); }
.hero-banner .hb-inner .body-copy { color: rgba(242,245,250,0.86); margin-top: 22px; text-shadow: 0 1px 16px rgba(7,9,13,0.6); }
.hero-banner .hb-inner .btn-row { margin-top: 30px; }
body.light-theme .hero-banner { background: #07090D; }
@media (max-width: 768px) {
  .hero-banner { min-height: 88vh; padding-bottom: 16vh; }
}

/* ecosystems intro: copy left, image right */
.eco-intro { display: grid; grid-template-columns: 1fr 0.9fr; gap: 64px; align-items: start; }
.eco-intro-copy .eyebrow { margin-bottom: 22px; }
.eco-intro-copy h2 { margin-bottom: 18px; }
.eco-intro-img { border-radius: 18px; overflow: hidden; aspect-ratio: 4 / 3; background: var(--bone, #E9EDF5); }
.eco-intro-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
@media (max-width: 900px) {
  .eco-intro { grid-template-columns: 1fr; gap: 32px; }
}
