/* =========================================================
   LAYER 9 — partner layer for safe, frontier AI
   ========================================================= */

:root {
  --bg:        #f4f2ec;
  --bg-cream:  #eceae2;
  --bg-sage:  #d9dec8;
  --bg-dark:   #14140f;

  --ink:       #14140f;
  --ink-body:  #2a2a24;
  --ink-mute:  #6e6e63;
  --ink-faded: #9c9c90;

  --on-dark:        #f4f2ec;
  --on-dark-mute:   #c9c7bd;
  --on-dark-faded:  #8a8a7e;

  --sage:      #b7c2a0;
  --sage-deep: #9fb084;

  --line:        rgba(20, 20, 15, 0.13);
  --line-strong: rgba(20, 20, 15, 0.22);
  --line-dark:   rgba(255, 255, 255, 0.09);

  --container: 1143px;
  --pad-x: 32px;

  --radius-card: 18px;
  --radius-card-lg: 20px;
  --radius-flow: 24px;
  --radius-pill: 999px;

  --font-sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink-body);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; }
img, svg { display: block; max-width: 100%; }
ul, ol { margin: 0; padding: 0; list-style: none; }
p, h1, h2, h3, h4 { margin: 0; }

::selection { background: var(--sage); color: var(--ink); }

.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 var(--pad-x);
}

/* ---------------- Typography ---------------- */
.display {
  font-weight: 600;
  font-size: clamp(40px, 8vw, 80px);
  line-height: 0.98;
  letter-spacing: -0.035em;
  color: var(--ink);
  margin-top: 22px;
}

.h2 {
  font-weight: 600;
  font-size: clamp(32px, 5.4vw, 57.15px);
  line-height: 1.04;
  letter-spacing: -0.028em;
  color: var(--ink);
  max-width: 17ch;
}
.h2--narrow { max-width: 14ch; }
.h2--invert { color: var(--on-dark); max-width: 14ch; }
.h2 .muted, .lead .muted { color: var(--ink-mute); }

.h3 {
  font-weight: 500;
  font-size: 22px;
  line-height: 1.2;
  letter-spacing: -0.012em;
  color: var(--ink);
}

.lead {
  font-size: 18.288px;
  line-height: 1.5;
  letter-spacing: -0.004em;
  color: var(--ink-body);
  max-width: 60ch;
}
.lead--narrow { max-width: 56ch; }
.lead--invert { color: var(--on-dark-mute); }

.eyebrow {
  font-family: var(--font-mono);
  font-size: 13px;
  line-height: 1.5;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-mute);
  margin: 0;
}
.eyebrow--xs { font-size: 12px; letter-spacing: 0.06em; }
.eyebrow--dark { color: var(--on-dark-faded); }
.eyebrow--dot { display: inline-flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.eyebrow__sep { color: var(--ink-faded); }
.eyebrow__faded { color: var(--ink-mute); }

.dot {
  display: inline-block;
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--sage);
}

.muted { color: var(--ink-mute); }

/* ---------------- Pills (buttons) ---------------- */
.pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 23px;
  border-radius: var(--radius-pill);
  font-weight: 500;
  font-size: 15px;
  letter-spacing: -0.005em;
  line-height: 1;
  border: 1px solid transparent;
  transition: background-color .15s ease, color .15s ease, border-color .15s ease, transform .12s ease;
  white-space: nowrap;
}
.pill--lg { padding: 13px 23px; font-size: 15px; min-height: 49px; }
.pill--block { width: 100%; }

.pill--dark { background: var(--ink); color: var(--on-dark); }
.pill--dark:hover { background: #2a2a22; }

.pill--ghost { color: var(--ink); border-color: var(--line); }
.pill--ghost:hover { border-color: var(--line-strong); background: rgba(20,20,15,0.03); }

.pill--sage { background: var(--sage); color: var(--ink); }
.pill--sage:hover { background: #a8b58e; }

.pill:active { transform: translateY(1px); }

/* ---------------- Chips (mono labels) ---------------- */
.chip {
  display: inline-flex;
  align-items: center;
  height: 32px;
  padding: 0 13px;
  border-radius: var(--radius-pill);
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink);
  border: 1px solid transparent;
  white-space: nowrap;
}
.chip--mono { font-family: var(--font-mono); }
.chip--sage { background: var(--sage); border-color: var(--sage); color: var(--ink); }
.chip--dark { background: var(--ink); border-color: var(--ink); color: var(--on-dark); }
.chip--ghost { color: var(--ink); border-color: var(--line); background: transparent; }
.chip--ghost-dark { color: var(--on-dark); border-color: var(--line-dark); background: transparent; }

/* ---------------- Nav ---------------- */
.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(244, 242, 236, 0.85);
  backdrop-filter: saturate(180%) blur(12px);
  -webkit-backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--line);
}
.nav__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 73px;
  gap: 24px;
}
.nav__links {
  display: flex;
  align-items: center;
  gap: 32px;
  font-size: 14px;
  color: var(--ink);
}
.nav__links a:not(.pill) {
  color: var(--ink);
  transition: color .15s ease;
}
.nav__links a:not(.pill):hover { color: var(--ink-mute); }
.nav__links .pill { padding: 10px 19px; min-height: 37px; font-size: 14px; }

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  letter-spacing: -0.005em;
  color: var(--ink);
}
.brand__name { font-size: 18px; }
.brand__mark {
  width: 14px; height: 14px;
  border-radius: 50%;
  background: var(--ink);
  position: relative;
  overflow: hidden;
}
.brand__mark::after {
  content: "";
  position: absolute;
  inset: 0 0 0 50%;
  background: var(--sage);
}

/* ---------------- Sections ---------------- */
.section {
  padding: 96px 0;
}
.section--bordered {
  border-bottom: 1px solid var(--line);
}
.section--cream { background: var(--bg-cream); }
.section--dark {
  background: var(--bg-dark);
  color: var(--on-dark);
}

.section .eyebrow + .h2,
.section .eyebrow + .row-baseline,
.section .eyebrow + .display { margin-top: 24px; }

.section .h2 + .lead,
.section .h2 + .two-col,
.section .row-baseline + .lead,
.section .h2--invert + .lead--invert { margin-top: 28px; }

.section .lead + .list-rows,
.section .lead + .cards-5,
.section .lead + .flow,
.section .lead + .timeline,
.section .h2 + .list-rows,
.section .h2 + .cards-5,
.section .h2--narrow + .timeline { margin-top: 56px; }

.section .cards-5 + .lead,
.section .flow + .cards-3,
.section .lead + .ownership { margin-top: 56px; }

/* ---------------- Hero ---------------- */
.hero {
  padding: 96px 0 80px;
}
.hero .lead { max-width: 760px; margin-top: 28px; font-size: 18.288px; }
.hero__cta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 40px;
}

/* ---------------- Two column ---------------- */
.two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 56px;
  margin-top: 64px;
}
@media (max-width: 760px) {
  .two-col { grid-template-columns: 1fr; gap: 24px; }
}

/* ---------------- List rows (numbered with rules) ---------------- */
.list-rows {
  border-top: 1px solid var(--line);
}
.list-rows li {
  display: grid;
  grid-template-columns: 80px 320px 1fr;
  align-items: center;
  gap: 32px;
  padding: 36px 0;
  border-bottom: 1px solid var(--line);
  min-height: 99px;
}
.list-rows__num {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-mute);
}
.list-rows__title {
  font-weight: 500;
  font-size: 22px;
  line-height: 1.2;
  letter-spacing: -0.012em;
  color: var(--ink);
  margin: 0;
}
.list-rows__desc {
  font-size: 16px;
  line-height: 1.55;
  color: var(--ink-body);
  max-width: 56ch;
}
@media (max-width: 880px) {
  .list-rows li {
    grid-template-columns: 64px 1fr;
    gap: 12px 16px;
    padding: 24px 0;
  }
  .list-rows__title { grid-column: 2; }
  .list-rows__desc { grid-column: 1 / -1; padding-left: 80px; }
}
@media (max-width: 540px) {
  .list-rows__desc { padding-left: 0; }
}

/* ---------------- Row with chip baseline ---------------- */
.row-baseline {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
}
.row-baseline .chip { margin-top: 16px; }

/* ---------------- Flow chart ---------------- */
.flow {
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: var(--radius-flow);
  padding: 56px 32px 64px;
  margin: 56px 0 0;
  color: var(--ink);
}
.flow__svg {
  display: block;
  width: 100%;
  height: auto;
  max-width: 1000px;
  margin: 0 auto;
  overflow: visible;
}
.flow__svg-num,
.flow__svg-step-num {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.06em;
  fill: var(--ink-mute);
}
.flow__svg-label {
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: 24px;
  letter-spacing: -0.02em;
  fill: var(--ink);
}
.flow__svg-step-text {
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: 13px;
  letter-spacing: -0.005em;
  fill: var(--ink);
}

.flow__list { display: none; }

@media (max-width: 760px) {
  .flow { padding: 32px 20px 36px; }
  .flow__svg { display: none; }
  .flow__list {
    display: flex;
    flex-direction: column;
    gap: 28px;
  }
  .flow__list-stage {
    display: grid;
    grid-template-columns: 36px 1fr;
    column-gap: 16px;
    row-gap: 12px;
  }
  .flow__list-num {
    font-family: var(--font-mono);
    font-size: 12px;
    letter-spacing: 0.06em;
    color: var(--ink-mute);
    padding-top: 6px;
  }
  .flow__list-title {
    font-weight: 600;
    font-size: 22px;
    letter-spacing: -0.02em;
    color: var(--ink);
    margin: 0;
  }
  .flow__list-substeps {
    grid-column: 2;
    display: flex;
    flex-direction: column;
    gap: 8px;
    font-size: 14px;
    color: var(--ink-body);
  }
  .flow__list-substeps li {
    display: flex;
    gap: 12px;
    align-items: baseline;
  }
  .flow__list-substep-num {
    font-family: var(--font-mono);
    font-size: 12px;
    letter-spacing: 0.06em;
    color: var(--ink-mute);
    min-width: 36px;
  }
}

/* ---------------- Cards ---------------- */
.cards-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
  margin-top: 56px;
}
.cards-5 {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 16px;
}
@media (max-width: 1080px) {
  .cards-5 { grid-template-columns: repeat(3, 1fr); }
  .cards-3 { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .cards-5 { grid-template-columns: 1fr 1fr; }
}

.card {
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: var(--radius-card);
  padding: 29px 25px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  min-height: 248px;
}
.card--cream { background: var(--bg-cream); border-radius: var(--radius-card-lg); }
.card--sage  { background: var(--bg-sage);  border-radius: var(--radius-card-lg); }
.card--tall  { min-height: 240px; padding: 28px 24px; }
.card__head {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.card .h3 + .card__body { margin-top: 8px; }
.card__body {
  font-size: 16px;
  line-height: 1.55;
  color: var(--ink-body);
}
.card--tall .h3 { margin-top: auto; }
.card--tall .card__body { margin-top: 8px; }

/* ---------------- Timeline ---------------- */
.timeline {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 56px;
  border-top: 1px solid var(--line);
  padding-top: 32px;
}
.timeline__col { position: relative; }
.timeline__list {
  margin-top: 32px;
  position: relative;
  padding-left: 0;
}
.timeline__list::before {
  content: "";
  position: absolute;
  left: 5px;
  top: 12px;
  bottom: 12px;
  width: 1px;
  background: var(--line);
}
.timeline__item {
  position: relative;
  padding-left: 32px;
  padding-bottom: 28px;
}
.timeline__item:last-child { padding-bottom: 0; }
.timeline__item::before {
  content: "";
  position: absolute;
  left: 0;
  top: 6px;
  width: 11px; height: 11px;
  border-radius: 3px;
  background: var(--bg);
  border: 1.5px solid var(--ink);
  z-index: 1;
}
.timeline__item.is-client::before { background: var(--sage); }
.timeline__item p {
  font-size: 16px;
  line-height: 1.55;
  color: var(--ink);
  margin: 0;
  max-width: 28ch;
}
.timeline__tag {
  display: inline-block;
  margin-top: 8px;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--sage-deep);
}
@media (max-width: 880px) {
  .timeline { grid-template-columns: 1fr; gap: 40px; }
}

/* ---------------- Ownership row ---------------- */
.ownership {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 32px;
  border-top: 1px solid var(--line);
  padding-top: 32px;
}
.ownership__chips {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
@media (max-width: 760px) {
  .ownership { grid-template-columns: 1fr; }
}

/* ---------------- CTA / Form ---------------- */
.cta {
  display: grid;
  grid-template-columns: 1fr 480px;
  gap: 56px;
  align-items: start;
}
.cta__copy { color: var(--on-dark); }
.cta .h2 + .lead { margin-top: 28px; }
.cta__chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 32px;
}

.form {
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.input {
  background: transparent;
  border: 1px solid var(--line-dark);
  border-radius: 12px;
  padding: 14px 16px;
  color: var(--on-dark);
  font: inherit;
  font-size: 15px;
  letter-spacing: -0.005em;
  font-family: var(--font-sans);
  transition: border-color .15s ease, background-color .15s ease;
}
.input::placeholder { color: var(--on-dark-faded); }
.input:focus {
  outline: none;
  border-color: rgba(255,255,255,0.3);
  background: rgba(255,255,255,0.02);
}
.input--area { resize: vertical; min-height: 120px; line-height: 1.5; }

.form__honeypot {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

@media (max-width: 980px) {
  .cta { grid-template-columns: 1fr; }
}

/* ---------------- Footer ---------------- */
.footer {
  background: var(--bg);
  border-top: 1px solid var(--line);
  padding: 56px 0 40px;
  font-size: 14px;
}
.footer__inner {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 48px;
  row-gap: 48px;
}
.footer__brand .brand { margin-bottom: 16px; }
.footer__tagline {
  color: var(--ink-mute);
  max-width: 36ch;
  margin: 0;
}
.footer__heading {
  font-family: var(--font-mono);
  font-size: 13px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-mute);
  margin: 0 0 16px;
}
.footer__col ul li { margin-bottom: 8px; }
.footer__col a { color: var(--ink); transition: color .15s ease; }
.footer__col a:hover { color: var(--ink-mute); }
.footer__rule {
  grid-column: 1 / -1;
  border: 0;
  border-top: 1px solid var(--line);
  margin: 8px 0 0;
  width: 100%;
}
.footer__bottom {
  grid-column: 1 / -1;
  display: flex;
  justify-content: space-between;
  font-family: var(--font-mono);
  font-size: 13px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-mute);
}
@media (max-width: 880px) {
  .footer__inner { grid-template-columns: 1fr 1fr; }
  .footer__brand { grid-column: 1 / -1; }
}
@media (max-width: 540px) {
  .footer__inner { grid-template-columns: 1fr; }
  .footer__bottom { flex-direction: column; gap: 8px; }
}

/* ---------------- Responsive nav ---------------- */
@media (max-width: 880px) {
  .nav__links { gap: 16px; }
  .nav__links a:not(.pill) { display: none; }
}

/* ---------------- Motion: reveals & hovers ---------------- */
[data-reveal] {
  opacity: 0;
  transform: translateY(12px);
  transition: opacity .8s cubic-bezier(.2, .7, .2, 1), transform .8s cubic-bezier(.2, .7, .2, 1);
  will-change: opacity, transform;
}
[data-reveal].is-revealed {
  opacity: 1;
  transform: none;
}

.list-rows li {
  transition: background-color .25s ease, padding .25s ease;
}
.list-rows li:hover {
  background: rgba(20, 20, 15, 0.018);
}

.card {
  transition: transform .35s cubic-bezier(.2, .7, .2, 1),
              border-color .25s ease,
              box-shadow .35s ease;
}
.card:hover {
  transform: translateY(-3px);
  border-color: var(--line-strong);
  box-shadow: 0 18px 40px -28px rgba(20, 20, 15, 0.18);
}

.pill {
  transition: background-color .15s ease, color .15s ease, border-color .15s ease, transform .25s cubic-bezier(.2, .7, .2, 1);
}
.pill:hover { transform: translateY(-1px); }
.pill:active { transform: translateY(1px); }

.brand__mark {
  transition: transform .6s cubic-bezier(.2, .7, .2, 1);
}
.brand:hover .brand__mark {
  transform: rotate(180deg);
}

@media (prefers-reduced-motion: reduce) {
  [data-reveal] {
    opacity: 1;
    transform: none;
    transition: none;
  }
  *, *::before, *::after {
    animation-duration: .01ms !important;
    transition-duration: .01ms !important;
  }
}
