@import url('https://fonts.googleapis.com/css2?family=IBM+Plex+Mono:wght@400;500;600&family=IBM+Plex+Sans:wght@400;500;600&display=swap');

:root {
  --ink: #0b0b0b;
  --paper: #ffffff;
  --line: #d8d8d8;
  --muted: #5b5b5b;
  --gutter: clamp(1.25rem, 4vw, 4.5rem);
  --sans: "IBM Plex Sans", Inter, "Helvetica Neue", Helvetica, Arial, sans-serif;
  --mono: "IBM Plex Mono", "JetBrains Mono", "SFMono-Regular", Menlo, Consolas, monospace;
}

* {
  box-sizing: border-box;
}

html {
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--paper);
}

a {
  color: inherit;
}

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

.wordmark {
  font-family: var(--mono);
  font-size: 0.84rem;
  font-weight: 700;
  letter-spacing: 0.11em;
  text-decoration: none;
  text-transform: uppercase;
}

nav {
  display: flex;
  align-items: center;
  gap: clamp(1rem, 2.2vw, 2.25rem);
}

nav a {
  font-family: var(--mono);
  position: relative;
  padding: 1.75rem 0 1.55rem;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-decoration: none;
  text-transform: uppercase;
}

nav a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 100%;
  bottom: -1px;
  height: 1px;
  background: var(--ink);
  transition: right 180ms ease;
}

nav a:hover::after,
nav a:focus-visible::after,
nav a.active::after {
  right: 0;
}

nav a.external {
  color: #0a7eea;
}

nav a.external::after {
  display: none;
}

main {
  flex: 1;
}

.intro {
  min-height: clamp(7rem, 10vw, 9.5rem);
  padding: clamp(1.75rem, 3vw, 2.5rem) var(--gutter) 1.5rem;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  border-bottom: 1px solid var(--line);
}

.eyebrow {
  margin: 0 0 1rem;
  font-size: 0.66rem;
  font-weight: 700;
  letter-spacing: 0.15em;
  text-transform: uppercase;
}

h1 {
  margin: 0;
  font-family: var(--sans);
  font-size: clamp(2.35rem, 4vw, 3.5rem);
  font-weight: 500;
  letter-spacing: -0.07em;
  line-height: 0.8;
}

.papers {
  padding: 0 var(--gutter);
}

.paper {
  display: block;
  padding: clamp(2.75rem, 5vw, 4.75rem) 0;
  border-bottom: 1px solid var(--line);
}

.paper-content {
  max-width: 66rem;
}

h2 {
  max-width: 19ch;
  margin: 0;
  font-family: var(--sans);
  font-size: clamp(2rem, 4.2vw, 4.25rem);
  font-weight: 500;
  letter-spacing: -0.055em;
  line-height: 0.96;
}

.paper p {
  max-width: 47rem;
  margin: clamp(1.4rem, 2.5vw, 2.25rem) 0 1.6rem;
  color: #272727;
  font-size: clamp(0.94rem, 1.35vw, 1.05rem);
  line-height: 1.58;
}

.paper-link {
  font-family: var(--mono);
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  padding: 0 0 0.5rem;
  border-bottom: 1px solid var(--ink);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-decoration: none;
  text-transform: uppercase;
}

.paper-link span {
  transition: transform 160ms ease;
}

.paper-link:hover span,
.paper-link:focus-visible span {
  transform: translate(0.18rem, -0.18rem);
}

.ethos-main {
  min-height: calc(100vh - 9rem);
}

.ethos-content {
  padding: 1.5rem var(--gutter) clamp(4rem, 9vw, 9rem);
  border-bottom: 1px solid var(--line);
}

.ethos-copy {
  max-width: 43rem;
  margin: 0;
  text-align: left;
}

.ethos-copy p {
  margin: 0 0 1.65rem;
  color: #272727;
  font-size: clamp(1rem, 1.55vw, 1.18rem);
  line-height: 1.65;
}

footer {
  font-family: var(--mono);
  min-height: 4.5rem;
  padding: 1.5rem var(--gutter);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.social-footer {
  justify-content: flex-end;
}

.social-footer a {
  text-decoration: none;
}

.social-footer a + a {
  margin-left: 1.6rem;
}

.social-footer a:hover,
.social-footer a:focus-visible {
  text-decoration: underline;
  text-underline-offset: 0.35rem;
}

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

  nav a {
    padding: 1.75rem 0 1.55rem;
  }

  .intro {
    min-height: 13.5rem;
    padding-top: 3.5rem;
  }

  h1 {
    font-size: clamp(3.6rem, 19vw, 5.2rem);
  }

  h2 {
    font-size: clamp(2.25rem, 11vw, 3.5rem);
  }

  footer {
    align-items: flex-start;
    flex-direction: column;
  }

}

@media (prefers-reduced-motion: reduce) {
  * {
    scroll-behavior: auto !important;
    transition: none !important;
  }
}
