:root {
  --legacy-surface: #ffffff;
  --legacy-surface-soft: #fafaf7;
  --legacy-surface-strong: #e6e5e0;
  --legacy-ink: #26251e;
  --legacy-muted: #5a5852;
  --legacy-border: #e6e5e0;
  --legacy-primary: #f54e00;
  --legacy-radius: 12px;
  --legacy-radius-control: 8px;
}

.shell {
  width: min(100% - 32px, 1280px);
  margin-inline: auto;
}

.narrow {
  width: min(100% - 32px, 820px);
}

.page-hero,
.section {
  border-bottom: 1px solid var(--legacy-border);
}

.page-hero {
  padding-block: 86px;
  text-align: center;
}

.section {
  padding-block: 86px;
}

.section-muted {
  background: var(--legacy-surface-soft);
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 16px;
  color: var(--legacy-muted);
  font-family: var(--font-cursor-mono), "JetBrains Mono", ui-monospace, monospace;
  font-size: 11px;
  font-weight: 600;
  line-height: 1.4;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.eyebrow::before {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--legacy-primary);
  content: "";
}

.page-hero h1,
.article-header h1 {
  max-width: 920px;
  margin: 0 auto 24px;
  color: var(--legacy-ink);
  font-size: clamp(46px, 8vw, 88px);
  font-weight: 400;
  line-height: 0.98;
  letter-spacing: -0.03em;
}

.section h2,
.split h2,
.contact-panel h2,
.price-card h2,
.article-content h2 {
  margin: 0 0 18px;
  color: var(--legacy-ink);
  font-size: clamp(32px, 4.5vw, 52px);
  font-weight: 400;
  line-height: 1.06;
  letter-spacing: -0.02em;
}

.feature h2,
.post-card h2 {
  font-size: 18px;
  font-weight: 600;
  line-height: 1.35;
  letter-spacing: 0;
}

.feature h3,
.stacked-links strong {
  margin: 0 0 12px;
  color: var(--legacy-ink);
  font-size: 23px;
  font-weight: 400;
  line-height: 1.18;
  letter-spacing: -0.0125em;
}

.lead,
.section-heading p:not(.eyebrow),
.split p,
.feature p,
.price-card p,
.contact-panel p,
.post-card p {
  color: var(--legacy-muted);
}

.lead {
  font-size: 19px;
  line-height: 1.65;
}

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

.actions.centered {
  justify-content: center;
}

.button {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--legacy-primary);
  border-radius: var(--legacy-radius-control);
  background: var(--legacy-primary);
  color: #ffffff;
  padding: 0 18px;
  font-size: 14px;
  font-weight: 500;
  white-space: nowrap;
}

.button-secondary {
  border-color: var(--legacy-border);
  background: var(--legacy-surface);
  color: var(--legacy-ink);
}

.feature-grid,
.pricing-grid,
.post-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.feature-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.feature,
.price-card,
.contact-panel,
.post-card,
.code-panel,
.code-grid pre {
  border: 1px solid var(--legacy-border);
  border-radius: var(--legacy-radius);
  background: var(--legacy-surface);
}

.feature,
.price-card,
.contact-panel {
  padding: 24px;
}

.icon {
  display: inline-flex;
  width: 42px;
  height: 42px;
  align-items: center;
  justify-content: center;
  margin-bottom: 28px;
  border: 1px solid var(--legacy-border);
  border-radius: var(--legacy-radius);
  background: var(--legacy-surface-soft);
  color: var(--legacy-primary);
  font-family: var(--font-cursor-mono), "JetBrains Mono", ui-monospace, monospace;
  font-size: 12px;
  font-weight: 600;
}

.split {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(360px, 1.2fr);
  gap: 48px;
  align-items: center;
}

.split.top {
  align-items: start;
}

.stacked-links,
.flow-list,
.event-list,
.data-table {
  display: grid;
  gap: 12px;
}

.stacked-links a,
.comparison div,
.event-list div,
.data-table div,
.flow-list li {
  border: 1px solid var(--legacy-border);
  border-radius: var(--legacy-radius);
  background: var(--legacy-surface);
  padding: 16px;
}

.flow-list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.flow-list li {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
}

.flow-list span {
  display: inline-flex;
  width: 36px;
  height: 36px;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: var(--legacy-surface-soft);
  color: var(--legacy-muted);
  font-family: var(--font-cursor-mono), "JetBrains Mono", ui-monospace, monospace;
  font-size: 11px;
}

.flow-list em,
.stacked-links span,
.data-table em,
.contact-notes span {
  color: var(--legacy-muted);
  font-family: var(--font-cursor-mono), "JetBrains Mono", ui-monospace, monospace;
  font-size: 11px;
  font-style: normal;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.code-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.code-grid pre,
.code-panel pre {
  overflow-x: auto;
  margin: 0;
  background: #171713;
  color: #f7f7f4;
  padding: 22px;
  font-family: var(--font-cursor-mono), "JetBrains Mono", ui-monospace, monospace;
  font-size: 13px;
  line-height: 1.65;
}

.data-table div {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.8fr) auto;
  gap: 16px;
  align-items: center;
}

.price-card.featured {
  background: var(--legacy-ink);
  color: #ffffff;
}

.price-card span {
  display: inline-flex;
  margin-bottom: 18px;
  border-radius: 999px;
  background: var(--legacy-surface-soft);
  color: var(--legacy-muted);
  padding: 5px 10px;
  font-family: var(--font-cursor-mono), "JetBrains Mono", ui-monospace, monospace;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.price-card ul {
  display: grid;
  gap: 10px;
  margin: 24px 0 0;
  padding: 0;
  list-style: none;
}

.price-card li::before {
  display: inline-block;
  width: 8px;
  height: 8px;
  margin-right: 9px;
  border-radius: 50%;
  background: var(--legacy-primary);
  content: "";
}

.contact-notes {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 24px;
}

.contact-notes span {
  border-radius: 999px;
  background: var(--legacy-surface-soft);
  padding: 7px 10px;
}

.wide-title {
  max-width: 760px;
}

.article-header {
  padding-block: 82px 40px;
  text-align: center;
}

.article-content {
  padding-bottom: 86px;
  color: var(--legacy-ink);
  font-size: 18px;
  line-height: 1.78;
}

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

  .feature-grid,
  .pricing-grid,
  .post-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 700px) {
  .shell,
  .narrow {
    width: min(100% - 24px, 1280px);
  }

  .page-hero,
  .section {
    padding-block: 58px;
  }

  .feature-grid,
  .pricing-grid,
  .post-grid,
  .code-grid,
  .flow-list li,
  .data-table div {
    grid-template-columns: 1fr;
  }
}

.covalent-mobile-menu {
  background: hsl(var(--background) / 0.82);
  -webkit-backdrop-filter: blur(18px);
  backdrop-filter: blur(18px);
  opacity: 0;
  transform: translateY(-14px);
  transition:
    opacity 420ms ease,
    transform 520ms cubic-bezier(0.16, 1, 0.3, 1);
  will-change: opacity, transform;
}

.covalent-mobile-menu[data-open="true"] {
  opacity: 1;
  transform: translateY(0);
}

.covalent-comparison-head,
.covalent-comparison-row {
  grid-template-columns: 1fr;
}

.covalent-comparison-left {
  border-right: 0;
  border-bottom: 1px solid hsl(var(--border));
}

.covalent-workflow-steps {
  display: grid;
  gap: 12px;
  min-width: 0;
}

.covalent-workflow-step {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.covalent-workflow-badge {
  width: 100%;
  height: 36px;
  justify-content: center;
  text-align: center;
  line-height: 1.2;
  white-space: normal;
}

.covalent-workflow-connector {
  display: none;
}

@media (max-width: 639px) {
  .covalent-workflow-section > div {
    padding-top: 64px;
    padding-bottom: 64px;
  }

  .covalent-workflow-title {
    font-size: clamp(2rem, 7.5vw, 2.25rem) !important;
    line-height: 1.12 !important;
  }

  .covalent-workflow-card {
    margin-top: 36px !important;
    padding: 16px !important;
  }

  .covalent-workflow-steps {
    gap: 10px;
  }

  .covalent-workflow-step {
    gap: 0;
  }

  .covalent-workflow-badge {
    height: auto;
    min-height: 34px;
    padding: 8px 12px;
    font-size: 10px;
  }

  .covalent-infra-content {
    gap: 24px;
    padding: 32px 24px !important;
  }

  .covalent-infra-title {
    font-size: clamp(2rem, 8.2vw, 2.4rem) !important;
    line-height: 1.1 !important;
    letter-spacing: -0.02em !important;
  }

  .covalent-infra-copy {
    margin-top: 16px !important;
    font-size: 1rem;
    line-height: 1.65;
  }

  .covalent-infra-actions {
    gap: 10px;
  }

  .covalent-infra-actions a {
    width: 100%;
    min-height: 48px;
  }

  .covalent-infra-tags {
    gap: 8px;
  }

  .covalent-infra-tags span {
    padding: 6px 10px;
    font-size: 10px;
  }

  .covalent-footer > div {
    padding-top: 32px;
    padding-bottom: 24px;
  }

  .covalent-footer > div > div:first-child {
    gap: 28px;
  }

  .covalent-footer-brand a {
    gap: 10px;
  }

  .covalent-footer-brand a > span:first-child {
    width: 2.7rem !important;
    height: 1.95rem !important;
  }

  .covalent-footer-brand svg {
    width: 2.7rem !important;
    height: 1.95rem !important;
  }

  .covalent-footer-copy {
    margin-top: 16px !important;
    max-width: none;
    font-size: 0.875rem;
    line-height: 1.65;
  }

  .covalent-footer-badges {
    display: none !important;
  }

  .covalent-footer-nav {
    gap: 24px 28px;
  }

  .covalent-footer-nav > div > div:first-child {
    font-size: 10px;
  }

  .covalent-footer-nav a {
    font-size: 0.875rem;
  }

  .covalent-footer > div > div:last-child {
    margin-top: 28px;
    padding-top: 18px;
  }

  .covalent-footer > div > div:last-child p:last-child {
    display: none;
  }
}

@media (min-width: 480px) and (max-width: 639px) {
  .covalent-workflow-steps {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .covalent-workflow-step:last-child {
    grid-column: 1 / -1;
  }
}

@media (min-width: 640px) {
  .covalent-comparison-head,
  .covalent-comparison-row {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .covalent-comparison-left {
    border-right: 1px solid hsl(var(--border));
    border-bottom: 0;
  }

  .covalent-workflow-steps {
    display: flex;
    min-width: max-content;
    align-items: center;
    gap: 12px;
  }

  .covalent-workflow-step {
    flex-direction: row;
    align-items: center;
    gap: 12px;
  }

  .covalent-workflow-badge {
    width: auto;
    height: 32px;
    justify-content: flex-start;
    white-space: nowrap;
  }

  .covalent-workflow-connector {
    display: block;
    width: 40px;
    height: 1px;
    background: hsl(var(--border));
  }
}

@media (prefers-reduced-motion: reduce) {
  .covalent-mobile-menu {
    transition: none;
  }
}
