:root {
  --paper: #f2f2ee;
  --ink: #151512;
  --muted: #63635c;
  --line: #c9c9c1;
  --signal: #c7462f;
  --gutter: clamp(1.25rem, 4vw, 4rem);
  --content: 92rem;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: "Avenir Next", Avenir, "Century Gothic", sans-serif;
  font-size: 1rem;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

a {
  color: inherit;
}

.skip-link {
  position: fixed;
  top: 0.75rem;
  left: 0.75rem;
  z-index: 10;
  padding: 0.65rem 0.85rem;
  background: var(--ink);
  color: var(--paper);
  transform: translateY(-160%);
}

.skip-link:focus {
  transform: translateY(0);
}

.site-header,
main,
footer {
  width: min(100%, var(--content));
  margin-inline: auto;
}

.site-header {
  min-height: 5.25rem;
  padding: 0 var(--gutter);
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--line);
}

.wordmark {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  font-weight: 650;
  text-decoration: none;
  letter-spacing: -0.02em;
}

.mark {
  width: 2rem;
  height: 2rem;
  display: grid;
  place-items: center;
  background: var(--ink);
  color: var(--paper);
  font-family: ui-monospace, "SFMono-Regular", monospace;
  font-size: 0.86rem;
  font-weight: 700;
}

nav {
  display: flex;
  gap: clamp(1.25rem, 3vw, 2.5rem);
}

nav a,
.text-link {
  text-underline-offset: 0.35rem;
  text-decoration-thickness: 1px;
  transition: color 150ms ease;
}

nav a {
  text-decoration: none;
}

nav a:hover,
nav a:focus-visible,
.text-link:hover,
.text-link:focus-visible,
.contact a:hover,
.contact a:focus-visible {
  color: var(--signal);
}

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

.intro {
  min-height: min(43rem, calc(100svh - 5.25rem));
  padding: clamp(3.5rem, 7vh, 5.5rem) var(--gutter);
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(17rem, 0.75fr);
  align-items: center;
  gap: clamp(3rem, 7vw, 7rem);
  border-bottom: 1px solid var(--line);
}

.intro-copy {
  max-width: 56rem;
}

h1,
h2,
p {
  margin-top: 0;
}

h1 {
  max-width: 48rem;
  margin-bottom: clamp(1.5rem, 3vw, 2.25rem);
  font-size: clamp(3.2rem, 6.3vw, 6.25rem);
  font-weight: 520;
  line-height: 0.94;
  letter-spacing: -0.06em;
  text-wrap: balance;
}

.intro-copy p {
  max-width: 35rem;
  margin-bottom: 0;
  font-size: clamp(1.08rem, 1.7vw, 1.45rem);
  color: var(--muted);
  text-wrap: pretty;
}

.window-study {
  width: min(100%, 22rem);
  aspect-ratio: 1;
  justify-self: end;
  display: grid;
  grid-template-columns: 1fr 1fr;
  border: 1px solid var(--ink);
}

.window-study span {
  display: grid;
  place-items: center;
  border-right: 1px solid var(--ink);
  border-bottom: 1px solid var(--ink);
}

.window-study span:nth-child(2n) {
  border-right: 0;
}

.window-study span:nth-child(n + 3) {
  border-bottom: 0;
}

.window-study .active-pane {
  background: var(--ink);
  color: var(--paper);
  font-family: ui-monospace, "SFMono-Regular", monospace;
  font-size: clamp(1.5rem, 4vw, 3rem);
  letter-spacing: -0.08em;
}

.product {
  padding: clamp(4rem, 7vw, 6.5rem) var(--gutter);
  display: grid;
  grid-template-columns: 4rem minmax(15rem, 0.9fr) minmax(18rem, 1fr);
  gap: clamp(1.5rem, 5vw, 6rem);
  border-bottom: 1px solid var(--line);
}

.section-index,
.product-heading > p,
footer {
  font-family: ui-monospace, "SFMono-Regular", monospace;
  font-size: 0.78rem;
  letter-spacing: 0.04em;
}

.section-index {
  padding-top: 0.4rem;
  color: var(--muted);
}

.product-heading > p {
  margin-bottom: 1.25rem;
  color: var(--muted);
}

.product h2 {
  margin-bottom: 0;
  font-size: clamp(3.5rem, 5.5vw, 5.5rem);
  font-weight: 520;
  line-height: 0.95;
  letter-spacing: -0.065em;
}

.product-copy {
  max-width: 33rem;
  padding-top: 0.2rem;
}

.product-copy p {
  margin-bottom: 2rem;
  font-size: clamp(1.15rem, 2vw, 1.6rem);
  line-height: 1.42;
  text-wrap: pretty;
}

.text-link {
  display: inline-block;
  font-weight: 600;
}

.contact {
  min-height: 19rem;
  padding: clamp(4rem, 7vw, 6rem) var(--gutter);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 4rem;
  background: var(--ink);
  color: var(--paper);
}

.contact h2 {
  max-width: 48rem;
  margin-bottom: 0;
  font-size: clamp(2.8rem, 5vw, 5rem);
  font-weight: 520;
  line-height: 1;
  letter-spacing: -0.06em;
}

.contact a {
  width: fit-content;
  font-size: clamp(1.15rem, 2vw, 1.6rem);
  text-underline-offset: 0.4rem;
  transition: color 150ms ease;
}

footer {
  padding: 1.4rem var(--gutter);
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  color: var(--muted);
}

@media (max-width: 760px) {
  .site-header {
    min-height: 4.5rem;
  }

  .intro {
    min-height: auto;
    grid-template-columns: 1fr;
    align-items: start;
  }

  .window-study {
    width: min(70vw, 19rem);
    justify-self: start;
  }

  .product {
    grid-template-columns: 2rem 1fr;
  }

  .product-copy {
    grid-column: 2;
  }
}

@media (max-width: 480px) {
  nav a:first-child {
    display: none;
  }

  h1 {
    font-size: clamp(3rem, 16vw, 4.5rem);
  }

  .product {
    grid-template-columns: 1fr;
  }

  .section-index {
    display: none;
  }

  .product-copy {
    grid-column: 1;
  }

  footer {
    flex-direction: column;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    transition-duration: 0.01ms !important;
  }
}
