/*
 * Altitude website stylesheet.
 * Brand palette: ink #1f1f30, periwinkle #7795fa, ice #cfdaff.
 * Derived tones are expressed in OKLCH and tinted toward the brand hue.
 */

@font-face {
  font-family: "Linear Grotesk";
  src: url("../fonts/LinearGrotesk-Light.otf") format("opentype");
  font-weight: 300;
  font-display: swap;
}
@font-face {
  font-family: "Linear Grotesk";
  src: url("../fonts/LinearGrotesk-Regular.otf") format("opentype");
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: "Linear Grotesk";
  src: url("../fonts/LinearGrotesk-Medium.otf") format("opentype");
  font-weight: 500;
  font-display: swap;
}
@font-face {
  font-family: "Linear Grotesk";
  src: url("../fonts/LinearGrotesk-SemiBold.otf") format("opentype");
  font-weight: 600;
  font-display: swap;
}
@font-face {
  font-family: "Linear Grotesk";
  src: url("../fonts/LinearGrotesk-Bold.otf") format("opentype");
  font-weight: 700;
  font-display: swap;
}

:root {
  --ink: #1f1f30;
  --periwinkle: #7795fa;
  --ice: #cfdaff;

  --ink-raised: oklch(0.29 0.035 283);
  --periwinkle-deep: oklch(0.5 0.17 272);
  --ice-soft: oklch(0.965 0.016 272);
  --paper: oklch(0.992 0.004 272);

  --text: var(--ink);
  --text-muted: oklch(0.46 0.03 280);
  --text-on-dark: oklch(0.97 0.008 272);
  --text-on-dark-muted: oklch(0.78 0.035 275);

  --line: oklch(0.89 0.02 272);
  --line-strong: oklch(0.8 0.035 272);
  --line-dark: oklch(0.37 0.03 282);

  --font: "Linear Grotesk", "Helvetica Neue", Arial, sans-serif;

  --step--1: 0.8125rem;
  --step-0: 1.0625rem;
  --step-1: 1.3125rem;
  --step-2: clamp(1.5rem, 1.25rem + 0.8vw, 1.875rem);
  --step-3: clamp(2.125rem, 1.5rem + 2.4vw, 3.5rem);
  --step-4: clamp(2.75rem, 1.6rem + 4.6vw, 6rem);

  --gutter: clamp(20px, 4vw, 48px);
  --container: 1280px;
  --section-y: clamp(88px, 11vw, 168px);
  --header-h: 72px;

  --radius: 10px;
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
}

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

html {
  -webkit-text-size-adjust: 100%;
  scroll-padding-top: calc(var(--header-h) + 16px);
}

@media (prefers-reduced-motion: no-preference) {
  html {
    scroll-behavior: smooth;
  }
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--text);
  font-family: var(--font);
  font-size: var(--step-0);
  line-height: 1.6;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

img,
svg {
  display: block;
  max-width: 100%;
}

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

a {
  color: inherit;
}

button {
  font: inherit;
  color: inherit;
}

:focus-visible {
  outline: 2px solid var(--periwinkle);
  outline-offset: 3px;
  border-radius: 4px;
}

.skip-link {
  position: absolute;
  left: 16px;
  top: -100px;
  z-index: 100;
  padding: 10px 16px;
  background: var(--ink);
  color: var(--text-on-dark);
  border-radius: var(--radius);
  text-decoration: none;
}

.skip-link:focus {
  top: 16px;
}

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

/* ---------- Type primitives ---------- */

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: var(--step--1);
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.eyebrow::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 2px;
  background: var(--periwinkle);
}

.on-dark .eyebrow {
  color: var(--text-on-dark-muted);
}

.display {
  font-size: var(--step-4);
  font-weight: 600;
  line-height: 0.98;
  letter-spacing: -0.04em;
}

.heading {
  font-size: var(--step-3);
  font-weight: 600;
  line-height: 1.04;
  letter-spacing: -0.032em;
  text-wrap: balance;
}

.lede {
  font-size: var(--step-1);
  line-height: 1.5;
  color: var(--text-muted);
  max-width: 34em;
  text-wrap: pretty;
}

.on-dark {
  background: var(--ink);
  color: var(--text-on-dark);
}

.on-dark .lede,
.on-dark .muted {
  color: var(--text-on-dark-muted);
  line-height: 1.65;
}

.muted {
  color: var(--text-muted);
}

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 48px;
  padding: 0 22px;
  border-radius: var(--radius);
  border: 1px solid transparent;
  font-size: 0.9375rem;
  font-weight: 500;
  letter-spacing: -0.005em;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  transition:
    background-color 200ms var(--ease-out),
    border-color 200ms var(--ease-out),
    color 200ms var(--ease-out);
}

.btn .arrow {
  transition: transform 250ms var(--ease-out);
}

.btn:hover .arrow {
  transform: translateX(3px);
}

.btn-primary {
  background: var(--ink);
  color: var(--text-on-dark);
}

.btn-primary:hover {
  background: var(--ink-raised);
}

.btn-secondary {
  border-color: var(--line-strong);
  color: var(--ink);
}

.btn-secondary:hover {
  border-color: var(--ink);
}

.btn-accent {
  background: var(--periwinkle);
  color: var(--ink);
}

.btn-accent:hover {
  background: var(--ice);
}

.btn-ghost {
  border-color: var(--line-dark);
  color: var(--text-on-dark);
}

.btn-ghost:hover {
  border-color: var(--text-on-dark-muted);
}

.btn-small {
  min-height: 40px;
  padding: 0 16px;
  font-size: 0.875rem;
}

.text-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 500;
  color: var(--periwinkle-deep);
  text-decoration: none;
}

.text-link:hover {
  text-decoration: underline;
  text-underline-offset: 4px;
}

.text-link--on-dark {
  color: var(--periwinkle);
}

/* ---------- Header ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--paper);
  border-bottom: 1px solid transparent;
  transition: border-color 200ms var(--ease-out);
}

.site-header.is-scrolled {
  border-bottom-color: var(--line);
}

.site-header--tinted {
  background: var(--ice-soft);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--header-h);
}

.brand {
  display: inline-flex;
  flex-shrink: 0;
}

.brand img {
  height: 26px;
  width: auto;
}

.nav {
  display: flex;
  align-items: center;
  gap: 36px;
}

.nav-links {
  display: flex;
  gap: 32px;
  list-style: none;
  padding: 0;
}

.nav-links a {
  font-size: 0.9375rem;
  font-weight: 500;
  color: var(--text-muted);
  text-decoration: none;
  transition: color 150ms var(--ease-out);
}

.nav-links a:hover {
  color: var(--ink);
}

.nav-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  margin-right: -10px;
  padding: 0;
  background: none;
  border: 0;
  cursor: pointer;
}

.nav-toggle-bars {
  position: relative;
  width: 20px;
  height: 12px;
}

.nav-toggle-bars::before,
.nav-toggle-bars::after {
  content: "";
  position: absolute;
  left: 0;
  width: 100%;
  height: 1.5px;
  background: var(--ink);
  transition: transform 250ms var(--ease-out);
}

.nav-toggle-bars::before {
  top: 0;
}

.nav-toggle-bars::after {
  bottom: 0;
}

.nav-toggle[aria-expanded="true"] .nav-toggle-bars::before {
  transform: translateY(5.25px) rotate(45deg);
}

.nav-toggle[aria-expanded="true"] .nav-toggle-bars::after {
  transform: translateY(-5.25px) rotate(-45deg);
}

@media (max-width: 860px) {
  .nav-toggle {
    display: inline-flex;
  }

  .nav {
    position: absolute;
    top: var(--header-h);
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 20px;
    padding: 8px var(--gutter) 28px;
    background: inherit;
    border-bottom: 1px solid var(--line);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    transition:
      opacity 200ms var(--ease-out),
      transform 250ms var(--ease-out),
      visibility 0s linear 250ms;
  }

  .nav.is-open {
    opacity: 1;
    visibility: visible;
    transform: none;
    transition:
      opacity 200ms var(--ease-out),
      transform 250ms var(--ease-out);
  }

  .nav-links {
    flex-direction: column;
    gap: 0;
  }

  .nav-links a {
    display: block;
    padding: 14px 0;
    border-bottom: 1px solid var(--line);
    font-size: var(--step-1);
    color: var(--ink);
  }

  .nav .btn {
    align-self: flex-start;
  }
}

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

.hero {
  position: relative;
  overflow: hidden;
  background: var(--ice-soft);
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
  align-items: center;
  gap: 40px;
  padding-top: clamp(56px, 8vw, 120px);
  padding-bottom: clamp(56px, 7vw, 104px);
}

.hero-copy {
  display: grid;
  gap: 28px;
  justify-items: start;
}

.hero-copy .display {
  max-width: 11ch;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 8px;
}

.networks {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px 18px;
  margin-top: 28px;
}

.networks img {
  height: 22px;
  width: auto;
}

.networks-sep {
  width: 1px;
  height: 20px;
  background: var(--line-strong);
}

.networks-label {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--text-muted);
}

.hero-visual {
  position: relative;
  justify-self: end;
  width: min(100%, 500px);
}

.hero-visual img {
  width: 100%;
  height: auto;
  filter: drop-shadow(0 40px 60px oklch(0.55 0.14 272 / 0.22));
}

@media (prefers-reduced-motion: no-preference) {
  .hero-visual img {
    animation: float 9s ease-in-out infinite;
  }
}

@keyframes float {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-12px);
  }
}

.service-index {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  list-style: none;
  padding: 0;
  border-top: 1px solid var(--line-strong);
}

.service-index a {
  display: grid;
  grid-template-columns: auto 1fr auto;
  column-gap: 16px;
  row-gap: 6px;
  height: 100%;
  padding: 28px 28px 36px 0;
  text-decoration: none;
  transition: background-color 200ms var(--ease-out);
}

.service-index li + li a {
  padding-left: 28px;
  border-left: 1px solid var(--line-strong);
}

.service-index .index-num {
  font-size: var(--step--1);
  font-weight: 500;
  color: var(--periwinkle-deep);
  font-variant-numeric: tabular-nums;
  padding-top: 4px;
}

.service-index .index-title {
  font-size: var(--step-1);
  font-weight: 600;
  letter-spacing: -0.015em;
}

.service-index .index-desc {
  grid-column: 2 / 3;
  font-size: 0.9375rem;
  color: var(--text-muted);
  line-height: 1.5;
}

.service-index .arrow {
  grid-row: 1;
  grid-column: 3;
  color: var(--text-muted);
  transition:
    transform 250ms var(--ease-out),
    color 200ms var(--ease-out);
}

.service-index a:hover .arrow {
  color: var(--ink);
  transform: translate(2px, 2px);
}

@media (max-width: 900px) {
  .hero-grid {
    grid-template-columns: 1fr;
  }

  .hero-visual {
    grid-row: 1;
    justify-self: start;
    width: min(56%, 280px);
  }

  .service-index {
    grid-template-columns: 1fr;
  }

  .service-index a,
  .service-index li + li a {
    padding: 22px 0;
    border-left: 0;
  }

  .service-index li + li {
    border-top: 1px solid var(--line-strong);
  }
}

/* ---------- Section scaffolding ---------- */

.section {
  padding-block: var(--section-y);
}

.section-head {
  display: grid;
  grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
  gap: 24px 64px;
  align-items: end;
  margin-bottom: clamp(56px, 7vw, 96px);
}

.section-head .heading-group {
  display: grid;
  gap: 24px;
  justify-items: start;
}

.section-head .heading {
  max-width: 16ch;
}

@media (max-width: 900px) {
  .section-head {
    grid-template-columns: 1fr;
  }
}

/* ---------- Managed RPC section ---------- */

.statement {
  font-size: var(--step-3);
  font-weight: 500;
  line-height: 1.12;
  letter-spacing: -0.03em;
  max-width: 22ch;
  text-wrap: balance;
}

.statement em {
  font-style: normal;
  color: var(--periwinkle);
}

.trace {
  display: grid;
  grid-template-columns: auto minmax(40px, 1fr) auto minmax(40px, 1fr) auto;
  align-items: center;
  margin-block: clamp(56px, 7vw, 96px);
}

.trace-node {
  display: grid;
  gap: 6px;
  padding: 18px 22px;
  border: 1px solid var(--line-dark);
  border-radius: var(--radius);
}

.trace-node--core {
  background: var(--periwinkle);
  border-color: var(--periwinkle);
  color: var(--ink);
}

.trace-label {
  font-size: var(--step--1);
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-on-dark-muted);
}

.trace-node--core .trace-label {
  color: oklch(0.3 0.06 275);
}

.trace-name {
  font-size: var(--step-1);
  font-weight: 600;
  letter-spacing: -0.015em;
  white-space: nowrap;
}

.trace-link {
  position: relative;
  height: 1px;
  background: var(--line-dark);
  overflow: hidden;
}

.trace-link::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, transparent 0%, var(--periwinkle) 40%, transparent 55%);
  transform: translateX(-100%);
}

@media (prefers-reduced-motion: no-preference) {
  .trace-link::after {
    animation: pulse 2.6s var(--ease-out) infinite;
  }

  .trace-link + .trace-node + .trace-link::after {
    animation-delay: 0.7s;
  }
}

@keyframes pulse {
  to {
    transform: translateX(100%);
  }
}

@media (max-width: 760px) {
  .trace {
    grid-template-columns: 1fr;
    justify-items: start;
  }

  .trace-link {
    width: 1px;
    height: 32px;
    margin-left: 24px;
  }

  .trace-link::after {
    background: linear-gradient(180deg, transparent 0%, var(--periwinkle) 40%, transparent 55%);
    transform: translateY(-100%);
  }

  @media (prefers-reduced-motion: no-preference) {
    .trace-link::after {
      animation-name: pulse-down;
    }
  }
}

@keyframes pulse-down {
  to {
    transform: translateY(100%);
  }
}

.features {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 48px;
  list-style: none;
  padding: 0;
}

.feature {
  display: grid;
  align-content: start;
  gap: 14px;
  padding-top: 24px;
  border-top: 1px solid var(--line-dark);
}

.feature-num {
  font-size: var(--step--1);
  font-weight: 500;
  color: var(--periwinkle);
  font-variant-numeric: tabular-nums;
}

.feature h3 {
  font-size: var(--step-2);
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.2;
}

.feature p {
  max-width: 34ch;
}

@media (max-width: 900px) {
  .features {
    grid-template-columns: 1fr;
    gap: 36px;
  }
}

/* ---------- Peering section ---------- */

.split {
  display: grid;
  grid-template-columns: minmax(0, 6fr) minmax(0, 5fr);
  gap: 48px 96px;
  align-items: start;
}

.split .heading-group {
  display: grid;
  gap: 24px;
  justify-items: start;
}

.split .heading {
  max-width: 14ch;
}

.split .lede {
  font-size: var(--step-0);
  line-height: 1.65;
}

.spec {
  border: 1px solid var(--line);
  border-radius: calc(var(--radius) + 4px);
  background: var(--ice-soft);
}

.spec-price {
  display: grid;
  gap: 10px;
  padding: 32px 32px 28px;
  border-bottom: 1px solid var(--line);
}

.spec-amount {
  font-size: var(--step-1);
  color: var(--text-muted);
}

.spec-amount span {
  font-size: var(--step-3);
  font-weight: 600;
  letter-spacing: -0.035em;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}

.spec-price .muted {
  font-size: 0.9375rem;
  max-width: 44ch;
}

.spec-list {
  display: grid;
  gap: 14px;
  margin: 0;
  padding: 28px 32px;
  list-style: none;
}

.spec-list li {
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 500;
}

.spec-list svg {
  flex-shrink: 0;
  color: var(--periwinkle-deep);
}

.spec-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px 28px;
  padding: 24px 32px 32px;
  border-top: 1px solid var(--line);
}

@media (max-width: 900px) {
  .split {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 520px) {
  .spec-price,
  .spec-list,
  .spec-actions {
    padding-inline: 20px;
  }
}

/* ---------- Technical scope section ---------- */

.scope {
  background: var(--ice);
}

.scope .eyebrow,
.scope .lede {
  color: oklch(0.38 0.05 278);
}

.scope .eyebrow::before {
  background: var(--ink);
}

.scope .text-link {
  color: var(--ink);
}

.scope-grid {
  --cell-pad: clamp(20px, 2.5vw, 36px);
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1px;
  margin-inline: calc(var(--cell-pad) * -1);
  padding: 0;
  list-style: none;
  background: oklch(0.78 0.06 272);
  border-block: 1px solid oklch(0.78 0.06 272);
}

.scope-grid li {
  display: grid;
  align-content: start;
  gap: 10px;
  padding: 36px var(--cell-pad) 44px;
  background: var(--ice);
}

.scope-grid h3 {
  font-size: var(--step-1);
  font-weight: 600;
  letter-spacing: -0.015em;
  line-height: 1.25;
}

.scope-grid p {
  max-width: 32ch;
  font-size: 0.9375rem;
  line-height: 1.55;
  color: oklch(0.38 0.05 278);
}

@media (max-width: 1000px) {
  .scope-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  .scope-grid {
    grid-template-columns: 1fr;
  }
}

.section-link {
  margin-top: clamp(40px, 5vw, 64px);
}


/* ---------- CTA ---------- */

.cta {
  position: relative;
  overflow: hidden;
}

.cta-grid {
  display: grid;
  grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
  align-items: center;
  gap: 48px;
  min-height: 520px;
}

.cta-copy {
  display: grid;
  gap: 28px;
  justify-items: start;
  padding-block: var(--section-y);
}

.cta-copy .display {
  max-width: 9ch;
}

.cta-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.cta-visual {
  align-self: end;
  justify-self: end;
  width: min(100%, 460px);
  margin-bottom: -18%;
}

.cta-visual img {
  width: 100%;
  height: auto;
}

@media (max-width: 900px) {
  .cta-grid {
    grid-template-columns: 1fr;
    min-height: 0;
  }

  .cta-copy {
    padding-bottom: 0;
  }

  .cta-visual {
    justify-self: center;
    width: min(70%, 320px);
  }
}

/* ---------- FAQ ---------- */

.faq-grid {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: 48px 96px;
  align-items: start;
}

.faq-intro {
  display: grid;
  gap: 24px;
  justify-items: start;
  position: sticky;
  top: calc(var(--header-h) + 40px);
}

.faq-list {
  border-top: 1px solid var(--line);
}

.faq-item {
  border-bottom: 1px solid var(--line);
}

.faq-question {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  width: 100%;
  padding: 26px 0;
  background: none;
  border: 0;
  text-align: left;
  font-size: var(--step-1);
  font-weight: 500;
  letter-spacing: -0.012em;
  line-height: 1.35;
  cursor: pointer;
}

.faq-icon {
  position: relative;
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  border: 1px solid var(--line-strong);
  border-radius: 50%;
  transition:
    transform 300ms var(--ease-out),
    background-color 200ms var(--ease-out),
    border-color 200ms var(--ease-out);
}

.faq-icon::before,
.faq-icon::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 10px;
  height: 1.5px;
  background: currentColor;
  transform: translate(-50%, -50%);
}

.faq-icon::after {
  transform: translate(-50%, -50%) rotate(90deg);
}

.faq-question:hover .faq-icon {
  border-color: var(--ink);
}

.faq-question[aria-expanded="true"] .faq-icon {
  transform: rotate(45deg);
  background: var(--ink);
  border-color: var(--ink);
  color: var(--text-on-dark);
}

.faq-answer {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows 350ms var(--ease-out);
}

.faq-answer > div {
  overflow: hidden;
}

.faq-answer p {
  max-width: 60ch;
  padding-bottom: 28px;
  padding-right: 52px;
  color: var(--text-muted);
}

.faq-answer a {
  color: var(--periwinkle-deep);
  text-underline-offset: 3px;
}

.faq-item.is-open .faq-answer {
  grid-template-rows: 1fr;
}

@media (max-width: 900px) {
  .faq-grid {
    grid-template-columns: 1fr;
  }

  .faq-intro {
    position: static;
  }
}

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

.site-footer {
  padding-top: clamp(72px, 9vw, 120px);
  padding-bottom: 40px;
}

.footer-top {
  display: grid;
  grid-template-columns: minmax(0, 6fr) minmax(0, 6fr);
  gap: 56px 96px;
  padding-bottom: clamp(56px, 7vw, 96px);
}

.footer-brand {
  display: grid;
  gap: 28px;
  justify-items: start;
  align-content: start;
}

.footer-brand img {
  height: 26px;
  width: auto;
}

.footer-tagline {
  font-size: var(--step-2);
  font-weight: 500;
  letter-spacing: -0.02em;
  line-height: 1.25;
  max-width: 18ch;
}

.footer-cols {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 32px;
}

.footer-col h2 {
  margin-bottom: 18px;
  font-size: var(--step--1);
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-on-dark-muted);
}

.footer-col ul {
  display: grid;
  gap: 12px;
  list-style: none;
  padding: 0;
}

.footer-col a {
  font-size: 0.9375rem;
  text-decoration: none;
  color: var(--text-on-dark);
  transition: color 150ms var(--ease-out);
}

.footer-col a:hover {
  color: var(--periwinkle);
}

.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 16px 32px;
  padding-top: 28px;
  border-top: 1px solid var(--line-dark);
  font-size: 0.875rem;
  color: var(--text-on-dark-muted);
}

.footer-bottom nav {
  display: flex;
  gap: 28px;
}

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

.footer-bottom a:hover {
  color: var(--text-on-dark);
}

@media (max-width: 900px) {
  .footer-top {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 520px) {
  .footer-cols {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* ---------- Legal pages ---------- */

.legal-hero {
  background: var(--ice-soft);
  padding-top: clamp(48px, 7vw, 96px);
  padding-bottom: clamp(40px, 5vw, 72px);
  border-bottom: 1px solid var(--line);
}

.legal-hero .container {
  display: grid;
  gap: 20px;
  justify-items: start;
}

.legal-hero .heading {
  max-width: none;
}

.legal-layout {
  display: grid;
  grid-template-columns: minmax(0, 3fr) minmax(0, 8fr);
  gap: 48px 96px;
  padding-block: clamp(56px, 7vw, 96px) var(--section-y);
}

.legal-toc {
  position: sticky;
  top: calc(var(--header-h) + 32px);
  align-self: start;
}

.legal-toc h2 {
  margin-bottom: 16px;
  font-size: var(--step--1);
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.legal-toc ol {
  display: grid;
  gap: 10px;
  list-style: none;
  padding: 0;
}

.legal-toc a {
  font-size: 0.9375rem;
  color: var(--text-muted);
  text-decoration: none;
}

.legal-toc a:hover {
  color: var(--ink);
}

.prose {
  max-width: 68ch;
}

.prose h2 {
  margin-top: 56px;
  margin-bottom: 16px;
  font-size: var(--step-2);
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.2;
}

.prose h2:first-child {
  margin-top: 0;
}

.prose h3 {
  margin-top: 32px;
  margin-bottom: 12px;
  font-size: var(--step-1);
  font-weight: 600;
  letter-spacing: -0.012em;
}

.prose p,
.prose ul,
.prose ol {
  margin-bottom: 16px;
  color: oklch(0.36 0.03 280);
}

.prose ul,
.prose ol {
  padding-left: 22px;
}

.prose li {
  margin-bottom: 8px;
}

.prose li::marker {
  color: var(--periwinkle-deep);
}

.prose a {
  color: var(--periwinkle-deep);
  text-underline-offset: 3px;
}

@media (max-width: 900px) {
  .legal-layout {
    grid-template-columns: 1fr;
  }

  .legal-toc {
    position: static;
    padding-bottom: 32px;
    border-bottom: 1px solid var(--line);
  }
}

/* ---------- Motion ---------- */

@media (prefers-reduced-motion: no-preference) {
  .js [data-reveal] {
    opacity: 0;
    transform: translateY(18px);
    transition:
      opacity 700ms var(--ease-out),
      transform 900ms var(--ease-out);
    transition-delay: calc(var(--reveal-order, 0) * 90ms);
  }

  .js [data-reveal].is-visible {
    opacity: 1;
    transform: none;
  }
}
