@font-face {
  font-family: "Archivo";
  src: url("/fonts/archivo.woff2") format("woff2");
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-display: swap;
}

:root {
  /* Night side, from the Signet tile gradient. */
  --night: #0f1830;
  --night-2: #1d2848;
  --starlight: #f3f5f9;
  --dusk: #a9b6cc;
  --teal: #76c5d7;

  /* Day side: shared with invent.industries. */
  --paper: oklch(0.9842 0.0036 251.66);
  --ink: oklch(0.2101 0.0318 264.77);
  --steel: oklch(0.5 0.0409 257.62);
  --rule: oklch(0.869 0.02 253.49);
  --accent: #294c8b;

  --gutter: clamp(1rem, 5vw, 4.5rem);
  --wide: 125%;
  --mono: ui-monospace, "SF Mono", "JetBrains Mono", Menlo, monospace;

  font-family: "Archivo", ui-sans-serif, system-ui, sans-serif;
  font-size: 112.5%;
  line-height: 1.55;
  color: var(--ink);
  background: var(--paper);
  -webkit-text-size-adjust: 100%;
}

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

html { scroll-behavior: smooth; }

body { margin: 0; background: var(--paper); }

h1, h2, h3, p, dl, dd, ul, ol { margin: 0; padding: 0; }

a { color: inherit; }

code {
  font-family: var(--mono);
  font-size: 0.875em;
}

:focus-visible {
  outline: 2px solid var(--teal);
  outline-offset: 4px;
}

.skip {
  position: absolute;
  left: var(--gutter);
  top: -4rem;
  z-index: 3;
  padding: 0.5rem 0.875rem;
  background: var(--paper);
  color: var(--ink);
}
.skip:focus { top: 1rem; }

/* --- Hero ----------------------------------------------------------------- */

.hero {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 88svh;
  padding: 0 var(--gutter);
  background:
    radial-gradient(60rem 40rem at 85% 110%, rgb(73 163 180 / 0.28), transparent 70%),
    linear-gradient(160deg, var(--night) 0%, var(--night-2) 100%);
  color: var(--starlight);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  padding: 1.75rem 0;
}

.nav-logo img {
  display: block;
  width: auto;
  height: 2.5rem;
}

.nav-links {
  display: flex;
  gap: clamp(1rem, 3vw, 2.5rem);
  list-style: none;
  font-size: 0.875rem;
  font-stretch: var(--wide);
  font-weight: 500;
}
.nav-links a {
  padding: 0.5rem 0;
  text-decoration: none;
  background: linear-gradient(currentColor, currentColor) no-repeat 0 100% / 0 1px;
  transition: background-size 0.2s ease-out;
}
.nav-links a:hover { background-size: 100% 1px; }

.hero-copy {
  max-width: 42rem;
  padding: 4rem 0 clamp(3rem, 9vh, 6rem);
}

.tag {
  display: inline-block;
  margin-bottom: 1.25rem;
  padding: 0.25rem 0.625rem;
  border: 1px solid var(--teal);
  color: var(--teal);
  font-size: 0.75rem;
  font-stretch: var(--wide);
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

h1 {
  font-size: clamp(2.125rem, 1.2rem + 3.6vw, 4rem);
  font-stretch: var(--wide);
  font-weight: 600;
  line-height: 1.04;
  letter-spacing: -0.015em;
  text-wrap: balance;
}

.hero-copy p:not(.tag) {
  max-width: 34rem;
  margin-top: 1.5rem;
  color: var(--dusk);
}

.button {
  display: inline-block;
  margin-top: 2.25rem;
  padding: 0.8125rem 1.5rem;
  border: 1px solid currentColor;
  font-size: 0.875rem;
  font-stretch: var(--wide);
  font-weight: 500;
  text-decoration: none;
  transition: background-color 0.2s ease-out, color 0.2s ease-out;
}
.button:hover {
  background: var(--starlight);
  color: var(--night);
}

/* --- Sections ------------------------------------------------------------- */

.section {
  display: grid;
  grid-template-columns: minmax(0, 4fr) minmax(0, 8fr);
  column-gap: var(--gutter);
  padding: clamp(4rem, 10vw, 7.5rem) var(--gutter);
}
.section + .section { border-top: 1px solid var(--rule); }

h2 {
  font-size: 1.5rem;
  font-stretch: var(--wide);
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: -0.01em;
}

.section-body { max-width: 46rem; }

.steps {
  display: grid;
  gap: 2.25rem;
  list-style: none;
  counter-reset: step;
}
.steps li {
  position: relative;
  padding-left: 3rem;
  counter-increment: step;
}
.steps li::before {
  content: counter(step);
  position: absolute;
  left: 0;
  top: 0.05rem;
  width: 1.875rem;
  height: 1.875rem;
  border-radius: 50%;
  background: var(--accent);
  color: var(--starlight);
  font-size: 0.875rem;
  font-weight: 600;
  line-height: 1.875rem;
  text-align: center;
}
.steps h3, .principles h3 {
  font-size: 1.1875rem;
  font-stretch: var(--wide);
  font-weight: 600;
  line-height: 1.4;
}
.steps p, .principles p {
  max-width: 34rem;
  margin-top: 0.375rem;
}

.group {
  margin-top: 4.5rem;
  font-size: 0.9375rem;
  font-weight: 500;
  color: var(--steel);
}

.projects { margin-top: 0.875rem; }
.projects > div {
  display: grid;
  grid-template-columns: minmax(0, 9rem) minmax(0, 1fr);
  column-gap: 2rem;
  padding: 1.375rem 0;
  border-top: 1px solid var(--rule);
}
.projects dt {
  font-size: 1.1875rem;
  font-stretch: var(--wide);
  font-weight: 600;
  line-height: 1.4;
}
.projects dd { max-width: 32rem; }

.principles {
  display: grid;
  gap: 2.75rem;
}

.lead {
  max-width: 32rem;
  font-size: 1.375rem;
  line-height: 1.4;
}

.downloads {
  display: grid;
  gap: 1rem;
  margin-top: 2rem;
  list-style: none;
}
.downloads li {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.375rem 1.25rem;
  padding: 1.25rem 1.375rem;
  border: 1px solid var(--rule);
  background: #fff;
}
.download {
  font-size: 1.1875rem;
  font-stretch: var(--wide);
  font-weight: 600;
  text-decoration: underline;
  text-decoration-color: var(--teal);
  text-decoration-thickness: 2px;
  text-underline-offset: 0.3em;
}
.download:hover { color: var(--accent); }
.downloads span {
  color: var(--steel);
  font-size: 0.9375rem;
}

.note {
  max-width: 36rem;
  margin-top: 1.5rem;
  color: var(--steel);
  font-size: 0.9375rem;
}
.fingerprint {
  margin-top: 0.5rem;
  overflow-wrap: anywhere;
  font-size: 0.875rem;
}

.setup {
  display: grid;
  gap: 0.75rem;
  margin-top: 1rem;
  padding-left: 1.375rem;
}

/* --- Footer --------------------------------------------------------------- */

.footer {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 2rem;
  padding: 3.5rem var(--gutter) 3rem;
  border-top: 1px solid var(--rule);
  font-size: 0.8125rem;
  color: var(--steel);
}
.footer img {
  display: block;
  width: min(13rem, 56vw);
  height: auto;
}

/* --- Small screens -------------------------------------------------------- */

@media (max-width: 47.9375rem) {
  .section { grid-template-columns: minmax(0, 1fr); }
  .section-body { margin-top: 2.25rem; }
  .projects > div { grid-template-columns: minmax(0, 1fr); }
  .projects dd { margin-top: 0.25rem; }
  .nav-logo img { height: 2rem; }
}

@media (max-width: 30rem) {
  .nav-links li:first-child { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .nav-links a, .button { transition: none; }
}
