:root {
  color-scheme: light;
  --background: #f5f1e8;
  --surface: #ede7da;
  --text: #252724;
  --muted: #666960;
  --line: #d4cdbf;
  --accent: #8a4d35;
  --accent-dark: #663725;
  --max-width: 70rem;
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--background);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 1rem;
  line-height: 1.65;
  text-rendering: optimizeLegibility;
}

a {
  color: inherit;
  text-decoration-color: color-mix(in srgb, currentColor 45%, transparent);
  text-decoration-thickness: 0.08em;
  text-underline-offset: 0.2em;
}

a:hover {
  color: var(--accent-dark);
  text-decoration-color: currentColor;
}

a:focus-visible {
  border-radius: 0.125rem;
  outline: 0.1875rem solid var(--accent);
  outline-offset: 0.25rem;
}

.shell {
  width: min(calc(100% - 3rem), var(--max-width));
  margin-inline: auto;
}

.site-header {
  border-bottom: 1px solid var(--line);
}

.header-inner {
  display: flex;
  min-height: 5rem;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
}

.wordmark {
  font-size: 1.05rem;
  font-weight: 750;
  letter-spacing: -0.02em;
  text-decoration: none;
}

nav {
  display: flex;
  align-items: center;
  gap: clamp(1.25rem, 4vw, 2.5rem);
  font-size: 0.875rem;
}

nav a {
  text-decoration: none;
}

.hero {
  display: grid;
  align-content: center;
  min-height: min(42rem, calc(100vh - 5rem));
  padding-block: 7rem;
}

.eyebrow,
.platform,
.section-number {
  margin: 0 0 1rem;
  color: var(--accent);
  font-size: 0.75rem;
  font-weight: 750;
  letter-spacing: 0.13em;
  text-transform: uppercase;
}

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

h1 {
  max-width: 15ch;
  margin-bottom: 1.5rem;
  font-size: clamp(3.25rem, 9vw, 7.5rem);
  font-weight: 680;
  letter-spacing: -0.065em;
  line-height: 0.94;
}

.intro {
  max-width: 34rem;
  margin-bottom: 0;
  color: var(--muted);
  font-size: clamp(1.1rem, 2vw, 1.35rem);
}

.apps {
  padding-block: 3rem 8rem;
}

.section-heading {
  display: flex;
  align-items: baseline;
  gap: 1rem;
  margin-bottom: 2rem;
  border-bottom: 1px solid var(--line);
}

.section-heading h2 {
  margin-bottom: 1rem;
  font-size: 1rem;
  letter-spacing: 0.02em;
}

.section-number {
  margin: 0;
}

.app-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: end;
  gap: 3rem;
  padding: clamp(2rem, 6vw, 4.5rem);
  border: 1px solid var(--line);
  background: var(--surface);
}

.app-card h3 {
  margin-bottom: 0.5rem;
  font-size: clamp(2rem, 5vw, 3.5rem);
  font-weight: 650;
  letter-spacing: -0.045em;
  line-height: 1;
}

.app-card-copy > p:last-child {
  max-width: 32rem;
  margin-bottom: 0;
  color: var(--muted);
}

.text-link {
  font-weight: 650;
  white-space: nowrap;
}

.site-footer {
  border-top: 1px solid var(--line);
}

.footer-inner {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 2rem 4rem;
  padding-block: 3.5rem;
  font-size: 0.875rem;
}

.footer-inner p {
  margin: 0;
}

.footer-inner span,
.copyright {
  color: var(--muted);
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 1rem 2rem;
}

.copyright {
  grid-column: 1 / -1;
}

.page-main {
  padding-block: clamp(4rem, 9vw, 8rem);
}

.page-header {
  max-width: 48rem;
  margin-bottom: clamp(4rem, 9vw, 7rem);
}

.page-header h1 {
  max-width: none;
  font-size: clamp(2.75rem, 7vw, 5.5rem);
}

.page-header .intro {
  max-width: 43rem;
}

.page-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.7fr) minmax(14rem, 0.75fr);
  gap: clamp(3rem, 8vw, 8rem);
  align-items: start;
}

.prose {
  max-width: 45rem;
}

.prose h2 {
  margin: 3rem 0 1rem;
  font-size: 1.5rem;
  letter-spacing: -0.025em;
  line-height: 1.25;
}

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

.prose p,
.prose ul {
  margin-bottom: 1.35rem;
}

.prose ul {
  padding-left: 1.25rem;
}

.prose li + li {
  margin-top: 0.4rem;
}

.side-panel {
  padding-top: 1.25rem;
  border-top: 0.1875rem solid var(--accent);
}

.side-panel h2 {
  margin-bottom: 1rem;
  font-size: 0.8rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.side-panel ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

.side-panel li {
  border-bottom: 1px solid var(--line);
}

.side-panel a {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding-block: 0.9rem;
  text-decoration: none;
}

.back-link {
  display: inline-block;
  margin-bottom: 2rem;
  font-size: 0.875rem;
}

.policy-meta {
  color: var(--muted);
  font-size: 0.875rem;
}

.error-page {
  display: grid;
  min-height: calc(100vh - 5rem);
  place-items: center;
  padding-block: 5rem;
}

.error-content {
  max-width: 40rem;
  text-align: center;
}

.error-code {
  margin-bottom: 0.75rem;
  color: var(--accent);
  font-size: 0.75rem;
  font-weight: 750;
  letter-spacing: 0.15em;
}

.error-content h1 {
  margin-inline: auto;
  font-size: clamp(3rem, 9vw, 6rem);
}

.error-content p {
  color: var(--muted);
}

@media (max-width: 44rem) {
  .shell {
    width: min(calc(100% - 2rem), var(--max-width));
  }

  .header-inner {
    min-height: 4.5rem;
  }

  nav {
    gap: 1rem;
  }

  nav a:first-child {
    display: none;
  }

  .hero {
    min-height: auto;
    padding-block: 6rem;
  }

  .apps {
    padding-block: 2rem 5rem;
  }

  .app-card {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .text-link {
    white-space: normal;
  }

  .footer-inner,
  .page-grid {
    grid-template-columns: 1fr;
  }

  .footer-links {
    justify-content: flex-start;
  }

  .copyright {
    grid-column: auto;
  }

  .page-header {
    margin-bottom: 4rem;
  }
}

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

@media print {
  .site-header,
  .site-footer,
  .side-panel,
  .back-link {
    display: none;
  }

  body {
    background: #fff;
    color: #000;
  }

  .page-main {
    padding: 0;
  }
}
