:root {
  --bg: #f6f6f3;
  --surface: #ffffff;
  --ink: #0d0d12;
  --muted: #5c5c66;
  --line: #e4e4de;
  --accent: #4f46e5;
  --accent-2: #a855f7;
  --gradient: linear-gradient(135deg, #4f46e5 0%, #a855f7 100%);
  --radius: 16px;
  --shadow-sm: 0 1px 2px rgba(13, 13, 18, 0.06);
  --shadow-lg: 0 24px 48px -16px rgba(13, 13, 18, 0.18);
  --font: "Inter", "Segoe UI", system-ui, -apple-system, "Helvetica Neue", Arial, sans-serif;
}

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--ink);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

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

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

ul {
  list-style: none;
}

button {
  font: inherit;
  color: inherit;
  background: none;
  border: none;
  cursor: pointer;
}

.container {
  width: 100%;
  max-width: 1160px;
  margin: 0 auto;
  padding: 0 24px;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  top: -48px;
  left: 16px;
  z-index: 100;
  padding: 10px 16px;
  background: var(--ink);
  color: var(--bg);
  border-radius: 8px;
  font-weight: 600;
  transition: top 0.2s ease;
}

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

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

::selection {
  background: var(--accent);
  color: #ffffff;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(246, 246, 243, 0.88);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}

.header-inner {
  display: flex;
  align-items: center;
  gap: 32px;
  height: 72px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  font-size: 1.25rem;
  letter-spacing: -0.02em;
}

.brand-mark {
  width: 32px;
  height: 32px;
  flex-shrink: 0;
}

.site-nav {
  margin-left: auto;
}

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

.nav-list a {
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--muted);
  transition: color 0.2s ease;
}

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

.header-cta {
  flex-shrink: 0;
}

.menu-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--surface);
}

.menu-toggle-bar {
  display: block;
  width: 100%;
  height: 2px;
  border-radius: 2px;
  background: var(--ink);
  transition: transform 0.25s ease, opacity 0.25s ease;
}

.menu-toggle.is-active .menu-toggle-bar:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.menu-toggle.is-active .menu-toggle-bar:nth-child(2) {
  opacity: 0;
}

.menu-toggle.is-active .menu-toggle-bar:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 24px;
  border-radius: 12px;
  font-weight: 600;
  font-size: 0.95rem;
  line-height: 1.2;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease, color 0.2s ease;
}

.btn-primary {
  background: var(--gradient);
  color: #ffffff;
  box-shadow: 0 8px 20px -8px rgba(79, 70, 229, 0.55);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 14px 28px -10px rgba(79, 70, 229, 0.6);
}

.btn-ghost {
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--ink);
}

.btn-ghost:hover {
  border-color: var(--ink);
  transform: translateY(-2px);
}

.btn-light {
  background: #ffffff;
  color: var(--ink);
  box-shadow: 0 12px 28px -12px rgba(0, 0, 0, 0.4);
}

.btn-light:hover {
  transform: translateY(-2px);
}

.hero {
  padding: clamp(72px, 10vw, 120px) 0 clamp(64px, 8vw, 96px);
  overflow: hidden;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: clamp(40px, 6vw, 80px);
  align-items: center;
}

.eyebrow {
  display: inline-block;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 20px;
}

h1,
h2,
h3 {
  line-height: 1.1;
  letter-spacing: -0.03em;
  font-weight: 800;
}

h1 {
  font-size: clamp(2.6rem, 6vw, 4.4rem);
  letter-spacing: -0.045em;
  margin-bottom: 24px;
}

.hero-lead {
  font-size: clamp(1.05rem, 1.6vw, 1.25rem);
  color: var(--muted);
  max-width: 34em;
  margin-bottom: 36px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}

.hero-preview {
  position: relative;
}

.hero-preview::before {
  content: "";
  position: absolute;
  inset: -12%;
  background: radial-gradient(closest-side, rgba(168, 85, 247, 0.18), transparent 70%);
  z-index: -1;
}

.mockup {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
}

.hero-preview .mockup {
  transform: rotate(-1.5deg);
  transition: transform 0.4s ease;
}

.hero-preview .mockup:hover {
  transform: rotate(0deg);
}

.mockup-bar {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 12px 16px;
  background: #fafaf8;
  border-bottom: 1px solid var(--line);
}

.mockup-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--line);
}

.mockup-title {
  margin-left: 8px;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--muted);
}

.mockup-body {
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.mockup-tabs {
  display: flex;
  gap: 20px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line);
}

.mockup-tab {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--muted);
  padding-bottom: 2px;
}

.mockup-tab.is-active {
  color: var(--ink);
  border-bottom: 2px solid var(--accent);
}

.mockup-route {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 12px 16px;
  align-items: center;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fcfcfa;
}

.mockup-node {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.mockup-avatar {
  width: 30px;
  height: 30px;
  border-radius: 9px;
  background: var(--gradient);
  flex-shrink: 0;
}

.mockup-avatar-alt {
  background: linear-gradient(135deg, #0ea5e9 0%, #6366f1 100%);
}

.mockup-node-text {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.mockup-node-label {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}

.mockup-node-name {
  font-size: 0.9rem;
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.mockup-arrow {
  width: 20px;
  height: 20px;
  color: var(--muted);
  justify-self: end;
}

.mockup-targets {
  grid-column: 1 / -1;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.mockup-target {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 10px 6px 6px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
}

.mockup-target .mockup-avatar {
  width: 20px;
  height: 20px;
  border-radius: 6px;
}

.mockup-target-name {
  font-size: 0.78rem;
  font-weight: 600;
}

.mockup-chip {
  grid-column: 1 / -1;
  justify-self: start;
  padding: 4px 12px;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.chip-active {
  background: #eef0ff;
  color: #4338ca;
  border: 1px solid #d4d8ff;
}

.chip-queued {
  background: #fdf3e3;
  color: #9a5b00;
  border: 1px solid #f3ddb4;
}

.chip-retrying {
  background: #fdece8;
  color: #b23a1e;
  border: 1px solid #f5c9bd;
}

.chip-delivered {
  background: #e7f6ef;
  color: #0f7a4d;
  border: 1px solid #bfe8d4;
}

.mockup-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fcfcfa;
}

.mockup-item-text {
  display: flex;
  flex-direction: column;
  min-width: 0;
  margin-right: auto;
}

.mockup-item-title {
  font-size: 0.88rem;
  font-weight: 700;
}

.mockup-item-meta {
  font-size: 0.75rem;
  color: var(--muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.features {
  padding: clamp(72px, 10vw, 120px) 0;
  border-top: 1px solid var(--line);
}

.section-head {
  max-width: 640px;
  margin-bottom: clamp(40px, 6vw, 64px);
}

.section-head h2 {
  font-size: clamp(1.9rem, 3.6vw, 2.8rem);
  margin-bottom: 16px;
}

.section-sub {
  color: var(--muted);
  font-size: 1.05rem;
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 24px;
}

.feature-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 28px;
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.feature-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: #d8d8d0;
}

.feature-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: #eef0ff;
  color: var(--accent);
  margin-bottom: 20px;
}

.feature-icon svg {
  width: 24px;
  height: 24px;
}

.feature-card h3 {
  font-size: 1.15rem;
  margin-bottom: 10px;
}

.feature-card p {
  color: var(--muted);
  font-size: 0.95rem;
}

.how-it-works {
  background: var(--ink);
  color: #f6f6f3;
  padding: clamp(72px, 10vw, 120px) 0;
}

.how-it-works .eyebrow {
  color: #b9b3ff;
}

.how-it-works .section-head h2 {
  color: #ffffff;
}

.steps-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.step-card {
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.04);
  padding: 32px;
  transition: background-color 0.25s ease, transform 0.25s ease;
}

.step-card:hover {
  background: rgba(255, 255, 255, 0.07);
  transform: translateY(-4px);
}

.step-number {
  display: block;
  font-size: 2.4rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  background: var(--gradient);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
  margin-bottom: 20px;
}

.step-card h3 {
  font-size: 1.2rem;
  color: #ffffff;
  margin-bottom: 10px;
}

.step-card p {
  color: #a0a0ab;
  font-size: 0.95rem;
}

.preview {
  padding: clamp(72px, 10vw, 120px) 0;
  border-top: 1px solid var(--line);
}

.preview-grid {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: clamp(40px, 6vw, 80px);
  align-items: center;
}

.preview-copy h2 {
  font-size: clamp(1.9rem, 3.6vw, 2.8rem);
  margin-bottom: 16px;
}

.preview-copy > p {
  color: var(--muted);
  font-size: 1.05rem;
  margin-bottom: 24px;
}

.preview-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.preview-list li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-weight: 500;
}

.preview-list li::before {
  content: "";
  flex-shrink: 0;
  width: 20px;
  height: 20px;
  margin-top: 3px;
  border-radius: 50%;
  background: var(--gradient);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E") center / 12px no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E") center / 12px no-repeat;
}

.preview-visual .mockup {
  box-shadow: var(--shadow-lg);
}

.faq {
  padding: clamp(72px, 10vw, 120px) 0;
  border-top: 1px solid var(--line);
}

.faq-inner {
  max-width: 760px;
}

.faq-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.faq-item {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 14px;
  overflow: hidden;
  transition: border-color 0.2s ease;
}

.faq-item:hover {
  border-color: #d0d0c8;
}

.faq-item summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 24px;
  font-weight: 700;
  font-size: 1.02rem;
  cursor: pointer;
  list-style: none;
}

.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-item summary::after {
  content: "+";
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: #eef0ff;
  color: var(--accent);
  font-size: 1.2rem;
  font-weight: 600;
  transition: transform 0.25s ease;
}

.faq-item[open] summary::after {
  transform: rotate(45deg);
}

.faq-item p {
  padding: 0 24px 20px;
  color: var(--muted);
  font-size: 0.95rem;
}

.cta {
  background: var(--gradient);
  padding: clamp(72px, 10vw, 110px) 0;
  text-align: center;
}

.cta-inner {
  max-width: 640px;
}

.cta h2 {
  color: #ffffff;
  font-size: clamp(2rem, 4vw, 3rem);
  margin-bottom: 16px;
}

.cta p {
  color: rgba(255, 255, 255, 0.85);
  font-size: 1.1rem;
  margin-bottom: 32px;
}

.site-footer {
  background: var(--ink);
  color: #a0a0ab;
  padding: 56px 0 40px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 40px;
  align-items: start;
}

.footer-brand .brand {
  color: #ffffff;
  margin-bottom: 14px;
}

.footer-tagline {
  font-size: 0.9rem;
  max-width: 30em;
}

.footer-nav ul {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.footer-nav a {
  font-size: 0.9rem;
  color: #a0a0ab;
  transition: color 0.2s ease;
}

.footer-nav a:hover {
  color: #ffffff;
}

.footer-meta {
  text-align: right;
  font-size: 0.85rem;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

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

  .hero-preview {
    max-width: 560px;
  }

  .steps-grid {
    grid-template-columns: 1fr;
    max-width: 560px;
  }

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

  .footer-meta {
    text-align: left;
  }
}

@media (max-width: 720px) {
  .header-inner {
    gap: 16px;
  }

  .header-cta {
    display: none;
  }

  .menu-toggle {
    display: flex;
    margin-left: auto;
  }

  .site-nav {
    position: absolute;
    top: 72px;
    left: 0;
    right: 0;
    margin: 0;
    background: var(--surface);
    border-bottom: 1px solid var(--line);
    box-shadow: var(--shadow-lg);
    padding: 12px 24px 20px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    transition: opacity 0.25s ease, transform 0.25s ease, visibility 0.25s ease;
  }

  .site-nav.is-open {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
  }

  .nav-list {
    flex-direction: column;
    align-items: stretch;
    gap: 4px;
  }

  .nav-list a {
    display: block;
    padding: 12px 8px;
    border-radius: 10px;
    font-size: 1rem;
  }

  .nav-list a:hover {
    background: var(--bg);
  }

  .mockup-route {
    grid-template-columns: 1fr;
  }

  .mockup-arrow {
    justify-self: start;
    transform: rotate(90deg);
  }

  .mockup-item {
    flex-wrap: wrap;
  }

  .mockup-item-text {
    flex: 1 1 auto;
  }
}

@media (max-width: 480px) {
  .container {
    padding: 0 18px;
  }

  .hero-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .hero-actions .btn {
    width: 100%;
  }

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

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 28px;
  }

  .faq-item summary {
    padding: 16px 18px;
  }

  .faq-item p {
    padding: 0 18px 16px;
  }
}

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

  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }
}
