/* Grounded Systems. Self-hosted fonts, no external requests. */
@font-face {
  font-family: "Newsreader";
  src: url("/assets/fonts/newsreader.woff2") format("woff2");
  font-weight: 200 800;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Hanken Grotesk";
  src: url("/assets/fonts/hanken-grotesk.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

:root {
  --ink: #0E2A47;
  --blue: #1F5FBF;
  --umber: #8A6240;
  --chalk: #F4F7FB;
  --mist: #DCE6F2;
  --mist-deep: #A9BDD8;
  --text: #2A425C;
  --on-dark: rgba(255, 255, 255, 0.88);
  --gutter: clamp(1.25rem, 4vw, 3rem);
  --space-section: clamp(4.5rem, 9vw, 8.5rem);
  --serif: "Newsreader", Georgia, "Times New Roman", serif;
  --sans: "Hanken Grotesk", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: #fff;
  color: var(--text);
  font-family: var(--sans);
  font-size: 1.0625rem;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img, svg { display: block; max-width: 100%; }
h1, h2, h3, p, dl, dd, ul, figure { margin: 0; }
ul { padding: 0; list-style: none; }
a { color: inherit; }

:focus-visible { outline: 3px solid var(--blue); outline-offset: 3px; border-radius: 2px; }
.platform :focus-visible { outline-color: #fff; }

.skip {
  position: absolute; left: 1rem; top: -4rem; z-index: 20;
  background: var(--ink); color: #fff; padding: 0.7rem 1rem; border-radius: 6px;
}
.skip:focus { top: 1rem; }

.wrap { width: 100%; max-width: calc(1200px + var(--gutter) * 2); margin-inline: auto; padding-inline: var(--gutter); }

/* Header */
.site-header { position: relative; z-index: 10; padding-block: 1.5rem; }
.site-header__inner { display: flex; align-items: center; justify-content: space-between; gap: 1.5rem; }
.brand { display: inline-flex; align-items: center; gap: 0.65rem; text-decoration: none; color: var(--ink); }
.brand__ground { fill: var(--umber); }
.brand__name { font-family: var(--serif); font-size: 1.35rem; font-weight: 500; letter-spacing: -0.01em; }
.nav { display: flex; align-items: center; gap: clamp(1rem, 2.4vw, 2.25rem); font-size: 0.975rem; font-weight: 500; }
.nav a { text-decoration: none; color: var(--ink); padding-block: 0.25rem; }
.nav a:not(.nav__cta):hover { text-decoration: underline; text-decoration-color: var(--umber); text-decoration-thickness: 2px; text-underline-offset: 6px; }
.nav__cta { border: 1.5px solid var(--ink); border-radius: 6px; padding: 0.5rem 1rem !important; transition: background 0.15s, color 0.15s; }
.nav__cta:hover { background: var(--ink); color: #fff !important; }

/* Hero */
.hero { overflow-x: clip; padding-top: clamp(1.25rem, 3.5vw, 3.25rem); }
h1 {
  font-family: var(--serif);
  font-weight: 300;
  font-size: clamp(2.9rem, 6.4vw, 5.5rem);
  line-height: 1;
  letter-spacing: -0.028em;
  color: var(--ink);
  max-width: 12.5ch;
}
.lede { margin-top: clamp(1.25rem, 2.2vw, 1.75rem); max-width: 34rem; font-size: clamp(1.125rem, 1.6vw, 1.3rem); line-height: 1.55; color: var(--text); }
.actions { margin-top: clamp(1.5rem, 2.6vw, 2rem); display: flex; flex-wrap: wrap; gap: 0.85rem; }

.btn {
  display: inline-flex; align-items: center; justify-content: center;
  font: 600 1rem/1.2 var(--sans);
  padding: 0.9rem 1.5rem; border-radius: 6px; text-decoration: none;
  border: 1.5px solid transparent; transition: background 0.15s, color 0.15s, border-color 0.15s;
}
.btn--primary { background: var(--ink); color: #fff; }
.btn--primary:hover { background: var(--blue); }
.btn--ghost { border-color: var(--ink); color: var(--ink); }
.btn--ghost:hover { background: var(--ink); color: #fff; }
.btn--light { background: #fff; color: var(--ink); }
.btn--light:hover { background: var(--mist); }

/* Fence-line chart: the one memorable element */
.fence { margin-top: clamp(2rem, 3.4vw, 3rem); }
.fence__stage { position: relative; max-width: calc(1200px + var(--gutter) * 2); margin-inline: auto; padding-inline: var(--gutter); }
.fence__stage::after {
  content: ""; position: absolute; left: 50%; bottom: -3px; width: 100vw; height: 3px;
  transform: translateX(-50%); background: var(--umber);
}
.fence__svg { width: 100%; height: clamp(190px, 22vw, 300px); overflow: visible; }
.fence__median { stroke: var(--umber); stroke-width: 1.5; stroke-dasharray: 6 6; }
.fence__label {
  position: absolute; left: var(--gutter); transform: translateY(-135%);
  font-size: 0.9rem; font-weight: 500; color: var(--umber);
}
.post {
  fill: var(--mist-deep); stroke: transparent; stroke-width: 18px; pointer-events: all;
  transform-box: fill-box; transform-origin: 50% 100%;
  animation: rise 0.9s cubic-bezier(0.2, 0.7, 0.2, 1) both;
  transition: fill 0.15s;
}
.post--up { fill: var(--blue); }
.post:hover, .post.is-active { fill: var(--ink); }
@keyframes rise { from { transform: scaleY(0); } to { transform: scaleY(1); } }
.fence__tip {
  position: absolute; z-index: 2; pointer-events: none; white-space: nowrap;
  transform: translate(-50%, -100%);
  background: var(--ink); color: #fff; font-size: 0.85rem; font-weight: 500;
  padding: 0.4rem 0.7rem; border-radius: 5px;
}
.fence__tip[hidden] { display: none; }
.fence figcaption { margin-top: 1.25rem; font-size: 0.875rem; color: #51657E; }
.fence figcaption.wrap { padding-bottom: 0; }

/* Sections */
.section { padding-block: var(--space-section); }
.section--tint { background: var(--chalk); }
.split { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); gap: clamp(2rem, 6vw, 6rem); }
.split__head { align-self: start; position: sticky; top: 2rem; }
h2 {
  font-family: var(--serif); font-weight: 350; color: var(--ink);
  font-size: clamp(2rem, 3.6vw, 3.1rem); line-height: 1.08; letter-spacing: -0.02em;
}
h3 { font-family: var(--serif); font-weight: 450; color: var(--ink); font-size: 1.5rem; line-height: 1.2; letter-spacing: -0.01em; }
h3 + p { margin-top: 0.5rem; max-width: 34rem; }
.section-lede { margin-top: 1.25rem; max-width: 22rem; }
.stack { display: grid; gap: clamp(2rem, 4vw, 3rem); }
.principles { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(2rem, 4vw, 3.25rem) clamp(1.5rem, 4vw, 3.5rem); }
.big { font-family: var(--serif); font-weight: 350; font-size: clamp(1.5rem, 2.6vw, 2.1rem); line-height: 1.3; color: var(--ink); max-width: 36rem; letter-spacing: -0.01em; }
.big + p { margin-top: 1.5rem; max-width: 34rem; }
.big + p + p { margin-top: 1.5rem; }
.textlink { font-weight: 600; color: var(--ink); text-decoration: underline; text-decoration-color: var(--umber); text-decoration-thickness: 2px; text-underline-offset: 6px; }
.textlink:hover { color: var(--blue); }

/* Platform (the one dark section) */
.platform { background: var(--ink); color: var(--on-dark); padding-block: var(--space-section); }
.platform__grid { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr); gap: clamp(2.5rem, 7vw, 6rem); align-items: center; }
.platform h2 { color: #fff; font-size: clamp(2.25rem, 4.4vw, 3.75rem); }
.platform__lede { margin-top: 1.5rem; max-width: 34rem; font-size: 1.15rem; }
.roles { margin-top: 2.25rem; display: grid; gap: 1.4rem; max-width: 34rem; }
.roles dt { font-family: var(--serif); font-size: 1.3rem; font-weight: 450; color: #fff; }
.roles dd { margin-top: 0.15rem; }
.platform__links { margin-top: 2.5rem; }
.platform__note { margin-top: 1rem; font-size: 0.9rem; color: rgba(255, 255, 255, 0.72); }

.compare { background: var(--chalk); color: var(--ink); border-radius: 14px; padding: clamp(1.25rem, 3vw, 2rem); }
.compare__head { display: flex; justify-content: space-between; align-items: baseline; gap: 1rem; flex-wrap: wrap; }
.compare__title { font-family: var(--serif); font-size: 1.3rem; font-weight: 450; }
.compare__tag { font-size: 0.85rem; color: #51657E; }
.compare__rows { margin-top: 1.75rem; display: grid; gap: 1.5rem; }
.compare__rows li { display: grid; grid-template-columns: 8.5rem minmax(0, 1fr) 3.25rem; align-items: center; gap: 1rem; font-size: 0.95rem; }
.compare__val { font-weight: 600; text-align: right; font-variant-numeric: tabular-nums; }
.track { position: relative; height: 10px; background: var(--mist); border-radius: 5px; }
.bar { position: absolute; inset: 0 auto 0 0; background: var(--blue); border-radius: 5px; }
.bar--a { width: 64%; }
.bar--b { width: 72%; }
.bar--c { width: 60.67%; }
.bar--d { width: 78%; }
.tick { position: absolute; left: 66.667%; top: -6px; bottom: -6px; width: 2px; background: var(--umber); }
.compare__foot { margin-top: 1.5rem; font-size: 0.85rem; color: #51657E; }

/* Contact and footer */
.contact { padding-block: var(--space-section); }
.contact__lede { margin-top: 1rem; }
.contact__mail {
  display: inline-block; margin-top: 1.5rem; max-width: 100%; overflow-wrap: anywhere;
  font-family: var(--serif); font-weight: 300; color: var(--ink);
  font-size: clamp(1.6rem, 5.6vw, 4.25rem); line-height: 1.1; letter-spacing: -0.02em;
  text-decoration: underline; text-decoration-color: var(--umber); text-decoration-thickness: 3px; text-underline-offset: 0.18em;
}
.contact__mail:hover { color: var(--blue); }
.site-footer { border-top: 3px solid var(--umber); padding-block: 2rem 2.5rem; font-size: 0.9rem; color: #51657E; }
.site-footer__inner { display: flex; flex-wrap: wrap; gap: 0.5rem 2.5rem; align-items: baseline; }
.site-footer__brand { font-family: var(--serif); font-size: 1.15rem; color: var(--ink); font-weight: 500; }

/* Responsive */
@media (max-width: 860px) {
  .split, .platform__grid { grid-template-columns: minmax(0, 1fr); }
  .split__head { position: static; }
  .principles { grid-template-columns: minmax(0, 1fr); }
  .nav a:not(.nav__cta) { display: none; }
}
@media (max-width: 480px) {
  .compare__rows li { grid-template-columns: 6.5rem minmax(0, 1fr) 2.9rem; gap: 0.7rem; font-size: 0.9rem; }
  .fence__label { font-size: 0.8rem; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .post { animation: none; }
  * { transition-duration: 0.01ms !important; }
}

.post:nth-of-type(1) { animation-delay: 200ms; }
.post:nth-of-type(2) { animation-delay: 232ms; }
.post:nth-of-type(3) { animation-delay: 264ms; }
.post:nth-of-type(4) { animation-delay: 296ms; }
.post:nth-of-type(5) { animation-delay: 328ms; }
.post:nth-of-type(6) { animation-delay: 360ms; }
.post:nth-of-type(7) { animation-delay: 392ms; }
.post:nth-of-type(8) { animation-delay: 424ms; }
.post:nth-of-type(9) { animation-delay: 456ms; }
.post:nth-of-type(10) { animation-delay: 488ms; }
.post:nth-of-type(11) { animation-delay: 520ms; }
.post:nth-of-type(12) { animation-delay: 552ms; }
.post:nth-of-type(13) { animation-delay: 584ms; }
.post:nth-of-type(14) { animation-delay: 616ms; }
.post:nth-of-type(15) { animation-delay: 648ms; }
.post:nth-of-type(16) { animation-delay: 680ms; }
.post:nth-of-type(17) { animation-delay: 712ms; }
.post:nth-of-type(18) { animation-delay: 744ms; }
.post:nth-of-type(19) { animation-delay: 776ms; }
.post:nth-of-type(20) { animation-delay: 808ms; }
.post:nth-of-type(21) { animation-delay: 840ms; }
.post:nth-of-type(22) { animation-delay: 872ms; }
.post:nth-of-type(23) { animation-delay: 904ms; }
.post:nth-of-type(24) { animation-delay: 936ms; }
.fence__label { top: 58.91%; }

