:root {
  --bg: #f4f2ec;
  --bg-sunken: #ebe8df;
  --fg: #141414;
  --fg-muted: #5c5a54;
  --fg-subtle: #8a8780;
  --rule: #d8d3c5;
  --accent: #141414;
  --accent-hover: #000;
  --maxw: 1180px;
  --pad-x: clamp(1.25rem, 4vw, 3rem);
  --section-y: clamp(4rem, 8vw, 7.5rem);
}

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

html {
  background: var(--bg);
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  color: var(--fg);
  font-family: "Inter", system-ui, -apple-system, "Helvetica Neue", Arial, sans-serif;
  font-size: 16px;
  line-height: 1.55;
  font-feature-settings: "ss01", "cv11";
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

a {
  color: inherit;
}

button {
  font: inherit;
  color: inherit;
}

.skip-link {
  position: fixed;
  top: 0.75rem;
  left: 0.75rem;
  z-index: 100;
  padding: 0.65rem 0.9rem;
  background: var(--fg);
  color: var(--bg);
  text-decoration: none;
  transform: translateY(-180%);
}

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

/* Header */

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  padding: 1.1rem var(--pad-x);
  border-bottom: 1px solid var(--rule);
  background: color-mix(in srgb, var(--bg) 94%, transparent);
  backdrop-filter: blur(14px);
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: clamp(1.5rem, 3.5vw, 3.5rem);
}

.wordmark {
  display: inline-flex;
  align-items: baseline;
  gap: 0.6rem;
  color: var(--fg);
  text-decoration: none;
  white-space: nowrap;
}

.wordmark-name {
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
}

.wordmark-suffix {
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--fg-muted);
}

.site-nav {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: clamp(1rem, 2.4vw, 2.25rem);
}

.site-nav a {
  position: relative;
  color: var(--fg-muted);
  font-size: 0.75rem;
  font-weight: 500;
  text-decoration: none;
  white-space: nowrap;
  transition: color 0.15s ease;
}

.site-nav a::after {
  content: "";
  position: absolute;
  right: 0;
  bottom: -0.45rem;
  left: 0;
  height: 1px;
  background: var(--fg);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.15s ease;
}

.site-nav a:hover,
.site-nav a:focus-visible,
.site-nav a[aria-current="page"] {
  color: var(--fg);
}

.site-nav a:hover::after,
.site-nav a:focus-visible::after,
.site-nav a[aria-current="page"]::after {
  transform: scaleX(1);
}

/* Shared layout */

main {
  flex: 1;
  width: 100%;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: var(--section-y) var(--pad-x);
  display: flex;
  flex-direction: column;
  gap: var(--section-y);
}

.eyebrow {
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--fg-muted);
}

.section-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1.5rem;
  padding-bottom: 1.25rem;
  border-bottom: 1px solid var(--rule);
}

.section-note {
  font-size: 0.8125rem;
  color: var(--fg-subtle);
}

.lede {
  color: var(--fg-muted);
  font-size: clamp(1rem, 1.4vw, 1.125rem);
  line-height: 1.68;
}

.cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  padding: 0.85rem 1.4rem;
  border-radius: 2px;
  background: var(--accent);
  color: var(--bg);
  font-size: 0.875rem;
  font-weight: 500;
  letter-spacing: 0.01em;
  text-decoration: none;
  transition: background 0.2s ease;
  white-space: nowrap;
}

.cta:hover,
.cta:focus-visible {
  background: var(--accent-hover);
  outline: none;
}

.cta-sm {
  padding: 0.52rem 0.95rem;
  font-size: 0.78rem;
}

.cta-arrow,
.text-link > span[aria-hidden="true"],
.focus-link span {
  display: inline-block;
  transition: transform 0.2s ease;
}

.cta:hover .cta-arrow,
.cta:focus-visible .cta-arrow,
.text-link:hover > span[aria-hidden="true"],
.text-link:focus-visible > span[aria-hidden="true"],
.focus-card:hover .focus-link span,
.focus-card:focus-visible .focus-link span {
  transform: translateX(4px);
}

.text-link {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  font-size: 0.95rem;
  font-weight: 500;
  text-decoration: none;
}

.text-link-label {
  text-decoration: underline;
  text-underline-offset: 0.25em;
}

.text-link--small {
  margin-top: 1.15rem;
  font-size: 0.8rem;
}

/* Homepage hero */

.hero {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.hero-header {
  display: inline-flex;
  gap: 0.65rem;
  flex-wrap: wrap;
  color: var(--fg-subtle);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.hero h1 {
  max-width: none;
  color: var(--fg);
  font-size: clamp(2.5rem, 6vw, 4.8rem);
  font-weight: 500;
  letter-spacing: -0.045em;
  line-height: 0.99;
}

.hero-line {
  display: block;
  white-space: nowrap;
}

/* Focus overview */

.focus-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
}

.focus-card {
  min-height: 12.5rem;
  padding: 1.5rem clamp(1.5rem, 3vw, 2.4rem);
  border-right: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
  color: var(--fg);
  text-decoration: none;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  gap: 1rem;
  transition: background 0.18s ease;
}

.focus-card:nth-child(2n) {
  border-right: none;
}

.focus-card:hover,
.focus-card:focus-visible {
  background: var(--bg-sunken);
  outline: none;
}

.focus-card-copy {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.focus-title {
  max-width: 12ch;
  font-size: clamp(1.45rem, 2.6vw, 2.2rem);
  font-weight: 500;
  letter-spacing: -0.025em;
  line-height: 1.08;
}

.focus-description {
  max-width: 42ch;
  color: var(--fg-muted);
  font-size: 0.92rem;
  line-height: 1.65;
}

.focus-link {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 0.75rem;
  font-weight: 500;
}

/* Contact and footer */

.contact-panel {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 2rem;
}

.contact-panel h2 {
  margin-top: 0.85rem;
  font-size: clamp(1.6rem, 3vw, 2.5rem);
  font-weight: 500;
  letter-spacing: -0.03em;
}

.site-footer {
  padding: 1.4rem var(--pad-x);
  border-top: 1px solid var(--rule);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  color: var(--fg-muted);
  font-size: 0.75rem;
  flex-wrap: wrap;
}

.site-footer a {
  text-decoration: none;
  transition: color 0.15s ease;
}

.site-footer a:hover {
  color: var(--fg);
}

.footer-links {
  display: inline-flex;
  gap: 1.5rem;
  flex-wrap: wrap;
}

/* Focus-area pages */

.focus-hero {
  display: block;
}

.focus-hero-copy h1 {
  width: fit-content;
  margin-inline: auto;
  max-width: 13ch;
  font-size: clamp(2.7rem, 6vw, 5.1rem);
  font-weight: 500;
  letter-spacing: -0.05em;
  line-height: 0.98;
}

.focus-hero-copy {
  width: min(100%, 55rem);
  margin: 0 auto;
}

.focus-hero-copy .lede {
  max-width: 55ch;
  margin: 2rem auto 0;
}

.capability-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border-bottom: 1px solid var(--rule);
}

.capability {
  min-height: 14rem;
  padding: 1.7rem 1.7rem 2.2rem;
  border-right: 1px solid var(--rule);
}

.capability:last-child {
  border-right: none;
}

.capability h3 {
  margin-bottom: 0.8rem;
  font-size: 1.05rem;
  font-weight: 500;
}

.capability p {
  color: var(--fg-muted);
  font-size: 0.88rem;
  line-height: 1.65;
}

.case-list {
  list-style: none;
}

.case-study {
  padding: clamp(2.2rem, 5vw, 4rem) 0;
  border-bottom: 1px solid var(--rule);
  display: grid;
  grid-template-columns: minmax(11rem, 0.6fr) minmax(0, 1.4fr);
  gap: clamp(2rem, 7vw, 7rem);
  scroll-margin-top: 7rem;
}

.case-meta h3 {
  font-size: 1.1rem;
  font-weight: 500;
  line-height: 1.3;
}

.case-evidence {
  margin-top: 1.75rem;
  display: grid;
  gap: 1.15rem;
}

.case-evidence > div {
  display: grid;
  gap: 0.1rem;
}

.case-evidence dt {
  color: var(--fg);
  font-size: clamp(1.15rem, 1.7vw, 1.4rem);
  font-weight: 500;
  letter-spacing: -0.025em;
  line-height: 1.2;
  overflow-wrap: anywhere;
  text-wrap: balance;
}

.case-evidence dd {
  max-width: 20ch;
  color: var(--fg-subtle);
  font-size: 0.72rem;
  line-height: 1.45;
}

.case-copy {
  max-width: 60ch;
}

.case-copy p {
  color: var(--fg-muted);
  font-size: 0.98rem;
  line-height: 1.72;
}

.case-copy p + p {
  margin-top: 1rem;
}

.case-label {
  display: block;
  margin-bottom: 0.35rem;
  color: var(--fg);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.empty-state {
  min-height: 15rem;
  padding: clamp(2rem, 5vw, 4rem);
  border-bottom: 1px solid var(--rule);
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  gap: 1rem;
}

.empty-state h3 {
  font-size: 1.2rem;
  font-weight: 500;
}

.empty-state p {
  max-width: 52ch;
  color: var(--fg-subtle);
  font-size: 0.9rem;
  line-height: 1.65;
}

.back-link {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  color: var(--fg-muted);
  font-size: 0.78rem;
  text-decoration: none;
}

.back-link:hover {
  color: var(--fg);
}

/* Who we are */

.network-grid {
  border-bottom: 1px solid var(--rule);
  display: grid;
  grid-template-columns: repeat(6, 1fr);
}

.network-role {
  grid-column: span 2;
  min-height: 11rem;
  padding: 1.7rem clamp(1.5rem, 3vw, 2.4rem) 2.2rem;
  border-right: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
}

.network-role:nth-child(3),
.network-role:nth-child(5) {
  border-right: none;
}

.network-role:nth-child(4),
.network-role:nth-child(5) {
  grid-column: span 3;
  border-bottom: none;
}

.network-role h2 {
  font-size: 1.05rem;
  font-weight: 500;
}

.network-role p {
  max-width: 48ch;
  margin-top: 0.8rem;
  color: var(--fg-muted);
  font-size: 0.88rem;
  line-height: 1.65;
}

/* Legal */

.legal {
  max-width: 70ch;
}

.legal h2 {
  margin-top: 2.25rem;
  color: var(--fg);
  font-size: 0.9375rem;
  font-weight: 600;
  letter-spacing: 0.005em;
}

.legal > h2:first-of-type {
  margin-top: 0;
}

.legal p {
  margin-top: 0.6rem;
  color: var(--fg-muted);
  font-size: 1rem;
  line-height: 1.65;
}

.legal p + p {
  margin-top: 1rem;
}

.legal a {
  color: var(--fg);
}

/* Focus states */

:focus-visible {
  outline: 2px solid var(--fg);
  outline-offset: 3px;
}

.cta:focus-visible {
  outline-offset: -3px;
}

/* Responsive */

@media (max-width: 920px) {
  .site-header {
    grid-template-columns: 1fr auto;
    gap: 1rem;
  }

  .site-nav {
    grid-column: 1 / -1;
    grid-row: 2;
    justify-content: flex-start;
    overflow-x: auto;
    padding: 0.15rem 0 0.2rem;
    scrollbar-width: none;
  }

  .site-nav::-webkit-scrollbar {
    display: none;
  }
}

@media (max-width: 700px) {
  .section-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.45rem;
  }

  .focus-grid,
  .case-study {
    grid-template-columns: 1fr;
  }

  .focus-card {
    min-height: auto;
    border-right: none;
  }

  .contact-panel {
    align-items: flex-start;
    flex-direction: column;
  }

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

  .capability {
    min-height: 11rem;
    border-right: none;
    border-bottom: 1px solid var(--rule);
  }

  .capability:last-child {
    border-bottom: none;
  }

  .case-study {
    gap: 1.4rem;
  }

  .case-evidence {
    grid-template-columns: repeat(auto-fit, minmax(8rem, 1fr));
  }

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

  .network-role,
  .network-role:nth-child(2n),
  .network-role:last-child {
    grid-column: auto;
    border-right: none;
    border-bottom: 1px solid var(--rule);
  }

  .network-role:last-child {
    border-bottom: none;
  }
}

@media (max-width: 480px) {
  .site-header {
    padding: 0.9rem 1.1rem;
  }

  .wordmark-suffix {
    display: none;
  }

  .site-nav {
    gap: 0.6rem 1rem;
    flex-wrap: wrap;
    overflow-x: visible;
  }

  .hero--home h1 {
    font-size: 2.25rem;
  }

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

@media (max-width: 360px) {
  .case-evidence {
    grid-template-columns: 1fr;
    gap: 0.9rem;
  }
}

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

  * {
    transition: none !important;
  }
}
