:root {
  color-scheme: light;
  --paper: #f4f0ea;
  --paper-soft: #fbf8f2;
  --ink: #160902;
  --muted: #756b62;
  --line: #ded7cd;
  --line-strong: #202020;
  --signal: #5f95aa;
  --panel: #eee9e1;
  --resource-bg: #8d8176;
  --resource-panel: #f3f2ee;
  --resource-muted: #55524e;
  --shadow-soft: 0 22px 70px rgba(22, 9, 2, 0.06);
  --header-height: 70px;
  --content-max: 1260px;
  --resources-max: 1500px;
  --type-hero: 5rem;
  --type-page: 4.75rem;
  --type-section: 3rem;
  --type-doc-title: 2.45rem;
  --type-body: 1rem;
}

* {
  box-sizing: border-box;
}

html {
  background: var(--paper);
  color: var(--ink);
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 16px;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

body {
  margin: 0;
  min-height: 100vh;
  overflow-x: clip;
  background: var(--paper);
}

body:has(.resources-shell) {
  background: var(--resource-bg);
}

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

button,
input,
textarea {
  font: inherit;
}

a {
  color: inherit;
  text-decoration: none;
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible {
  outline: 2px solid var(--signal);
  outline-offset: 3px;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  display: grid;
  grid-template-columns: minmax(max-content, 1fr) auto minmax(0, 1fr);
  align-items: center;
  min-height: var(--header-height);
  padding: 0 2.375rem;
  background: rgba(244, 240, 234, 0.92);
  border-bottom: 1px solid rgba(222, 215, 205, 0.78);
  backdrop-filter: blur(18px);
}

.site-header::after {
  content: "";
}

.brand {
  min-width: max-content;
  display: inline-flex;
  align-items: center;
}

.brand-logo {
  display: block;
  height: 38px;
  width: auto;
}

.main-nav {
  display: flex;
  gap: 2.75rem;
  align-items: center;
  min-width: 0;
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0;
  text-transform: uppercase;
}

.main-nav a {
  opacity: 0.76;
  transition: opacity 160ms ease;
  white-space: nowrap;
}

.main-nav a[aria-current="page"],
.main-nav a:hover {
  opacity: 1;
}

.main-nav a.nav-app {
  opacity: 1;
  font-weight: 600;
}

.main-nav a.nav-app:last-child {
  padding: 0.35rem 0.85rem;
  border: 1px solid currentColor;
  border-radius: 999px;
}

.home-shell {
  min-width: 0;
}

.hero-system {
  display: grid;
  grid-template-columns: minmax(0, 1.55fr) minmax(0, 0.95fr);
  min-height: calc(100vh - var(--header-height));
  border-bottom: 1px solid var(--line);
}

.hero-visual {
  position: relative;
  min-height: 38rem;
  overflow: hidden;
  border-right: 1px solid var(--line);
}

#waveform-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.hero-copy {
  position: relative;
  display: flex;
  flex-direction: column;
  min-width: 0;
  min-height: 38rem;
  padding: 4rem 3.75rem 3.5rem;
}

.hero-dots,
.hero-copy > div[aria-hidden="true"] {
  display: none !important;
}

.eyebrow,
.post-meta,
.product-grid span {
  margin: 0;
  color: var(--signal);
  font-size: 0.6875rem;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

.hero-copy h1,
.page-intro h1 {
  margin: 0;
  max-width: 100%;
  font-weight: 900;
  letter-spacing: 0;
  overflow-wrap: anywhere;
  text-wrap: balance;
}

.hero-copy h1 {
  font-size: var(--type-hero);
  line-height: 0.92;
}

.page-intro h1 {
  max-width: 58rem;
  font-size: var(--type-page);
  line-height: 1;
}

.lede,
.chat-post p,
.product-grid p,
.demo-copy p:not(.eyebrow) {
  color: var(--muted);
  font-family: "Libre Baskerville", Georgia, serif;
  font-size: var(--type-body);
  line-height: 1.68;
}

.lede {
  max-width: 28rem;
  margin: 2.375rem 0 0;
}

.product-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1.5rem;
  margin-top: 2rem;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1.75rem;
  width: fit-content;
  margin-top: auto;
}

.round-link {
  display: inline-flex;
  align-items: center;
  gap: 1rem;
  width: fit-content;
  font-size: 0.75rem;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

.round-link b {
  display: grid;
  place-items: center;
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 999px;
  background: #e6dfd5;
  font-size: 1rem;
}

.section-kicker {
  display: grid;
  grid-template-columns: minmax(12rem, 0.3fr) minmax(0, 0.7fr);
  gap: 3rem;
  align-items: start;
  width: min(var(--content-max), calc(100% - 3.5rem));
  margin: 0 auto;
}

.section-kicker h2 {
  margin: 0;
  max-width: 48rem;
  font-size: var(--type-section);
  line-height: 1.06;
  letter-spacing: 0;
  text-wrap: balance;
}

.system-brief {
  padding: 5.75rem 0 6.25rem;
  border-bottom: 1px solid var(--line);
}

.authority-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  width: min(var(--content-max), calc(100% - 3.5rem));
  margin: 3.25rem auto 0;
  border-top: 1px solid var(--line);
  border-left: 1px solid var(--line);
}

.authority-grid article,
.matrix-grid article {
  min-width: 0;
  padding: 2rem;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: rgba(251, 248, 242, 0.46);
}

.authority-grid span,
.matrix-grid span,
.pipeline-steps span {
  color: var(--signal);
  font-size: 0.75rem;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

.authority-grid h3,
.matrix-grid h3 {
  margin: 1rem 0 0.875rem;
  font-size: 1.5rem;
  line-height: 1.15;
}

.authority-grid p,
.pipeline-copy p,
.pipeline-steps p,
.principle-strip p,
.matrix-grid p {
  margin: 0;
  color: var(--muted);
  font-family: "Libre Baskerville", Georgia, serif;
  font-size: var(--type-body);
  line-height: 1.65;
}

.pipeline-band {
  display: grid;
  grid-template-columns: minmax(18rem, 0.36fr) minmax(0, 0.64fr);
  gap: 4rem;
  width: min(var(--content-max), calc(100% - 3.5rem));
  margin: 0 auto;
  padding: 6.25rem 0;
  border-bottom: 1px solid var(--line);
}

.pipeline-copy h2 {
  margin: 1.25rem 0 1.5rem;
  font-size: var(--type-section);
  line-height: 1.06;
}

.pipeline-steps {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1px;
  margin: 0;
  padding: 0;
  background: var(--line);
  list-style: none;
}

.pipeline-steps li {
  min-width: 0;
  padding: 1.75rem;
  background: var(--paper);
}

.pipeline-steps strong {
  display: block;
  margin: 0.875rem 0 0.625rem;
  font-size: 1.25rem;
  line-height: 1.2;
}

.principle-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  width: min(var(--content-max), calc(100% - 3.5rem));
  margin: 0 auto;
  padding: 6.25rem 0 7rem;
  gap: 3rem;
}

.principle-strip article {
  min-width: 0;
}

.principle-strip h2 {
  margin: 0 0 1rem;
  font-size: 1.75rem;
  line-height: 1.12;
  text-wrap: balance;
}

.page-shell {
  width: min(var(--content-max), calc(100% - 3.5rem));
  margin: 0 auto;
  padding: 5.375rem 0 6.875rem;
}

.page-intro {
  padding-bottom: 4.375rem;
  border-bottom: 1px solid var(--line);
}

.page-intro .eyebrow,
.demo-copy .eyebrow {
  margin-bottom: 1.25rem;
}

.blog-page {
  max-width: 72.5rem;
}

.chat-journal {
  display: grid;
  gap: 1.75rem;
  padding-top: 3.25rem;
}

.chat-post {
  width: min(47.5rem, 100%);
  padding: 2.125rem;
  background: var(--paper-soft);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 22px 60px rgba(22, 9, 2, 0.04);
}

.featured-post {
  width: min(57.5rem, 100%);
}

.align-right {
  justify-self: end;
}

.chat-post h2,
.product-grid h2 {
  margin: 1rem 0 0.75rem;
  font-size: var(--type-section);
  line-height: 1.05;
  letter-spacing: 0;
  overflow-wrap: anywhere;
}

.chat-post p,
.product-grid p {
  margin: 0;
}

.chat-post a {
  display: inline-block;
  margin-top: 1.5rem;
  font-size: 0.75rem;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

.resources-shell {
  width: min(var(--resources-max), calc(100% - 3rem));
  margin: 0 auto;
  padding: 4.875rem 0 4.5rem;
}

.resource-tabs {
  display: flex;
  align-items: end;
  padding-left: 1.625rem;
}

.resource-tabs button {
  position: relative;
  display: grid;
  place-items: center;
  width: 9.875rem;
  height: 3rem;
  margin-right: 0.5rem;
  border: 0;
  background: #dcd6c5;
  color: #0d0d0d;
  font-size: 0.875rem;
  font-weight: 600;
  letter-spacing: 0;
  clip-path: polygon(10% 0, 90% 0, 100% 100%, 0 100%);
  cursor: pointer;
}

.resource-tabs button.active,
.resource-tabs button[aria-selected="true"] {
  background: #d4d3d3;
  color: #fbf8f2;
  font-weight: 800;
}

.resource-tabs button:nth-child(3) {
  background: #afa494;
}

.resource-tabs button:nth-child(3).active,
.resource-tabs button:nth-child(3)[aria-selected="true"] {
  background: #d4d3d3;
}

.resource-board {
  display: grid;
  grid-template-columns: minmax(17.5rem, 22.5rem) minmax(0, 1fr);
  min-height: min(73rem, calc(100vh - 11.875rem));
  overflow: hidden;
  background: var(--resource-panel);
  border-radius: 10px;
  box-shadow: var(--shadow-soft);
}

.resource-sidebar {
  min-width: 0;
  border-right: 1px solid var(--line-strong);
  background: #ededeb;
}

.sidebar-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 5.75rem;
  padding: 0 1.75rem;
  border-bottom: 1px solid var(--line-strong);
  font-size: 1rem;
  font-weight: 700;
}

.sidebar-title button,
.document-toolbar button {
  border: 0;
  background: transparent;
  color: #0c0c0c;
  cursor: pointer;
}

.resource-list {
  display: grid;
}

.resource-item {
  display: grid;
  gap: 0.375rem;
  width: 100%;
  min-height: 6.25rem;
  padding: 1.125rem 1.75rem;
  border: 0;
  border-left: 4px solid transparent;
  background: transparent;
  color: #111;
  font: inherit;
  text-align: left;
  cursor: pointer;
}

.resource-item.active,
.resource-item[aria-selected="true"] {
  border-left-color: #0c0c0c;
  background: #dfdfdc;
}

.resource-item time,
.document-toolbar {
  color: #5f5d59;
  font-size: 0.8125rem;
}

.resource-item strong {
  font-size: 1rem;
  font-weight: 650;
  line-height: 1.28;
  overflow-wrap: anywhere;
}

.resource-item span {
  display: -webkit-box;
  overflow: hidden;
  color: var(--resource-muted);
  font-size: 0.875rem;
  line-height: 1.35;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.resource-document {
  min-width: 0;
  padding: 2.25rem 2.375rem 5.625rem;
  background: var(--resource-panel);
  color: #090909;
}

.document-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 0.875rem;
}

.document-toolbar button {
  min-width: 2rem;
  min-height: 2rem;
  font-size: 1.375rem;
  line-height: 1;
}

.resource-document h1 {
  margin: 0 0 1.25rem;
  max-width: 48rem;
  font-size: var(--type-doc-title);
  line-height: 1.08;
  font-weight: 520;
  letter-spacing: 0;
  overflow-wrap: anywhere;
}

.resource-document h2 {
  margin: 0 0 0.5rem;
  font-size: 1rem;
  line-height: 1.4;
}

.resource-document p,
.resource-document li {
  max-width: 48rem;
  margin: 0;
  font-size: 1rem;
  line-height: 1.6;
}

.resource-document ul {
  display: grid;
  gap: 0.375rem;
  max-width: 48rem;
  margin: 0.25rem 0 0;
  padding-left: 1.25rem;
}

.document-lede {
  margin-bottom: 1.875rem !important;
  color: var(--resource-muted);
}

#resource-content {
  display: grid;
  gap: 1.375rem;
}

.resource-empty {
  padding: 1.75rem 2rem;
  color: var(--resource-muted);
  font-size: 0.9375rem;
}


.product-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  border-left: 1px solid var(--line);
}

.product-grid article {
  min-height: 18.75rem;
  padding: 2.625rem;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.architecture-matrix {
  padding: 5.75rem 0 0;
}

.matrix-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin-top: 3rem;
  border-top: 1px solid var(--line);
  border-left: 1px solid var(--line);
}

.contact-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(21.25rem, 30rem);
  gap: 4.375rem;
}

.contact-layout .page-intro {
  border-bottom: 0;
}

.contact-form {
  display: grid;
  align-content: start;
  gap: 1.125rem;
  padding: 2.125rem;
  background: var(--paper-soft);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.contact-form label {
  display: grid;
  gap: 0.5rem;
  font-size: 0.6875rem;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

.contact-form input,
.contact-form textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 0;
  background: var(--paper);
  color: var(--ink);
  padding: 0.8125rem 0.875rem;
}

.contact-form button {
  min-height: 3rem;
  border: 0;
  background: var(--ink);
  color: var(--paper-soft);
  font-size: 0.75rem;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
  cursor: pointer;
}

@media (min-width: 1440px) {
  :root {
    --type-hero: 5rem;
    --type-page: 5.25rem;
    --type-section: 3.35rem;
    --type-doc-title: 2.65rem;
  }
}

@media (max-width: 1180px) {
  :root {
    --type-hero: 5rem;
    --type-page: 3.875rem;
    --type-section: 2.55rem;
    --type-doc-title: 2.2rem;
  }

  .site-header {
    grid-template-columns: 1fr;
    gap: 1.125rem;
    padding: 1.125rem 1.375rem;
  }

  .site-header::after {
    content: none;
  }

  .main-nav {
    justify-self: start;
    flex-wrap: wrap;
    gap: 1rem 1.25rem;
  }

  .hero-system,
  .contact-layout,
  .product-grid,
  .section-kicker,
  .pipeline-band,
  .principle-strip,
  .matrix-grid {
    grid-template-columns: 1fr;
  }

  .hero-visual {
    min-height: 31rem;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .hero-copy {
    min-height: auto;
    padding: 3rem 2rem;
  }

  .hero-actions {
    margin-top: 3.5rem;
  }

  .system-brief,
  .pipeline-band {
    padding-block: 4.5rem;
  }

  .section-kicker,
  .authority-grid,
  .pipeline-band,
  .principle-strip {
    width: min(100% - 2rem, 47.5rem);
  }

  .authority-grid {
    grid-template-columns: 1fr;
    margin-top: 2.5rem;
  }

  .pipeline-band {
    gap: 2.5rem;
  }

  .pipeline-steps {
    grid-template-columns: 1fr;
  }

  .principle-strip {
    padding-block: 4.5rem;
  }

  .matrix-grid {
    margin-top: 2.25rem;
  }

  .page-shell {
    width: min(100% - 2rem, 47.5rem);
    padding-top: 3.5rem;
  }

  .resources-shell {
    width: min(100% - 1.75rem, 47.5rem);
    padding-top: 2.25rem;
  }

  .resource-tabs {
    padding-left: 0.625rem;
  }

  .resource-tabs button {
    width: 6.75rem;
    height: 2.625rem;
    font-size: 0.8125rem;
  }

  .resource-board {
    grid-template-columns: 1fr;
    min-height: auto;
  }

  .resource-sidebar {
    border-right: 0;
    border-bottom: 1px solid var(--line-strong);
  }

  .resource-document {
    padding: 1.875rem 1.5rem 3.5rem;
  }
}

@media (max-width: 640px) {
  :root {
    --type-hero: 3.25rem;
    --type-page: 2.65rem;
    --type-section: 2rem;
    --type-doc-title: 1.85rem;
  }

  .site-header {
    padding: 1rem;
  }

  .brand-logo {
    height: 30px;
  }

  .main-nav {
    gap: 0.75rem 1rem;
    font-size: 0.625rem;
  }

  .hero-visual {
    min-height: 25rem;
  }

  .hero-copy {
    padding: 2.5rem 1.5rem;
  }

  .lede {
    margin-top: 1.75rem;
  }

  .round-link b {
    width: 2.375rem;
    height: 2.375rem;
  }

  .page-shell {
    width: min(100% - 1.25rem, 47.5rem);
    padding-bottom: 4.5rem;
  }

  .page-intro {
    padding-bottom: 3rem;
  }

  .resources-shell {
    width: calc(100% - 1rem);
  }

  .resource-tabs {
    overflow-x: auto;
    padding-left: 0.25rem;
  }

  .resource-tabs button {
    flex: 0 0 6.25rem;
  }

  .resource-item {
    padding: 1rem 1.25rem;
  }

  .product-grid article,
  .authority-grid article,
  .matrix-grid article,
  .pipeline-steps li,
  .contact-form,
  .chat-post {
    padding: 1.5rem;
  }

  .system-brief,
  .pipeline-band,
  .principle-strip {
    padding-block: 3.5rem;
  }
}

@media (max-width: 380px) {
  :root {
    --type-hero: 3rem;
    --type-page: 2.35rem;
    --type-section: 1.8rem;
  }

  .hero-copy {
    padding-inline: 1.125rem;
  }
}
