/* Reset & Base */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --text: #1a202c;
  --text-secondary: #4a5568;
  --text-muted: #718096;
  --bg: #ffffff;
  --bg-alt: #f7fafc;
  --border: #e2e8f0;
  --accent: #2d3748;
  --accent-hover: #1a202c;
  --radius: 8px;
  --max-width: 960px;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Inter', Roboto, sans-serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
}

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

/* Nav */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}

.nav-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 2rem;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 600;
  font-size: 1rem;
  letter-spacing: -0.02em;
}

.nav-logo img {
  border-radius: 4px;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  font-size: 0.875rem;
  color: var(--text-secondary);
}

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

.nav-cta {
  background: var(--accent);
  color: #fff !important;
  padding: 0.4rem 1rem;
  border-radius: var(--radius);
  font-weight: 500;
  transition: background 0.15s;
}

.nav-cta:hover {
  background: var(--accent-hover);
}

/* Hero */
.hero {
  padding: 10rem 2rem 6rem;
  text-align: center;
}

.hero-inner {
  max-width: var(--max-width);
  margin: 0 auto;
}

.hero-logo {
  margin-bottom: 2rem;
  opacity: 0.9;
}

.hero h1 {
  font-size: 2.75rem;
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.03em;
  max-width: 720px;
  margin: 0 auto 1.5rem;
}

.rotating-text {
  display: block;
  position: relative;
  height: 1.3em;
  overflow: hidden;
}

.rotate-word {
  position: absolute;
  left: 0;
  right: 0;
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.4s ease, transform 0.4s ease;
  color: var(--text-secondary);
}

.rotate-word.active {
  opacity: 1;
  transform: translateY(0);
}

.hero-sub {
  font-size: 1.15rem;
  color: var(--text-secondary);
  max-width: 540px;
  margin: 0 auto 2.5rem;
  line-height: 1.7;
}

.hero-actions {
  display: flex;
  gap: 0.75rem;
  justify-content: center;
  flex-wrap: wrap;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  padding: 0.65rem 1.5rem;
  border-radius: var(--radius);
  font-size: 0.9rem;
  font-weight: 500;
  transition: all 0.15s;
  cursor: pointer;
  border: none;
}

.btn-primary {
  background: var(--accent);
  color: #fff;
}

.btn-primary:hover {
  background: var(--accent-hover);
  transform: translateY(-1px);
}

.btn-secondary {
  background: transparent;
  color: var(--text);
  border: 1px solid var(--border);
}

.btn-secondary:hover {
  border-color: var(--text-muted);
  transform: translateY(-1px);
}

/* Sections */
.section {
  padding: 5rem 2rem;
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.section.visible {
  opacity: 1;
  transform: translateY(0);
}

.section-alt {
  background: var(--bg-alt);
}

.container {
  max-width: var(--max-width);
  margin: 0 auto;
}

.section h2 {
  font-size: 1.85rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 1rem;
  text-align: center;
}

.section-body {
  font-size: 1.05rem;
  color: var(--text-secondary);
  line-height: 1.75;
  text-align: center;
  max-width: 620px;
  margin: 0 auto 1.5rem;
}

/* Steps */
.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2.5rem;
  margin-top: 2rem;
}

.step {
  text-align: left;
}

.step-num {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--accent);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 1rem;
}

.step h3 {
  font-size: 1.05rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.step p {
  font-size: 0.925rem;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* Features Grid */
.features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
  margin-top: 2.5rem;
}

.feature {
  text-align: left;
}

.feature-icon {
  width: 40px;
  height: 40px;
  border-radius: var(--radius);
  background: var(--bg);
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1rem;
  color: var(--text);
}

.feature h3 {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 0.4rem;
}

.feature p {
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* Metrics */
.metrics {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 2rem;
  text-align: center;
}

.metric {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.metric-value {
  font-size: 2.25rem;
  font-weight: 700;
  letter-spacing: -0.03em;
  font-variant-numeric: tabular-nums;
}

.metric-label {
  font-size: 0.85rem;
  color: var(--text-muted);
}

/* Integrations */
.integrations {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 2rem;
  margin-top: 2.5rem;
}

.integration {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 2rem;
}

.integration h3 {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.integration p {
  font-size: 0.925rem;
  color: var(--text-secondary);
  line-height: 1.6;
  margin-bottom: 1rem;
}

.integration code {
  font-size: 0.825rem;
  color: var(--text-muted);
  background: var(--bg-alt);
  padding: 0.3rem 0.6rem;
  border-radius: 4px;
  font-family: 'SF Mono', 'Fira Code', 'Fira Mono', Menlo, monospace;
}

/* CTA Section */
.cta-section {
  padding: 6rem 2rem;
}

.cta-code {
  text-align: center;
}

.cta-code code {
  font-size: 1rem;
  background: var(--bg-alt);
  border: 1px solid var(--border);
  padding: 0.75rem 1.5rem;
  border-radius: var(--radius);
  font-family: 'SF Mono', 'Fira Code', 'Fira Mono', Menlo, monospace;
  color: var(--text);
}

/* Footer */
.footer {
  border-top: 1px solid var(--border);
  padding: 1.5rem 2rem;
}

.footer-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.footer-left {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 500;
  font-size: 0.875rem;
}

.footer-left img {
  border-radius: 3px;
}

.footer-right {
  font-size: 0.8rem;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.footer-right a:hover {
  color: var(--text);
}

/* Responsive */
@media (max-width: 768px) {
  .hero {
    padding: 8rem 1.5rem 4rem;
  }

  .hero h1 {
    font-size: 2rem;
  }

  .hero-sub {
    font-size: 1rem;
  }

  .section {
    padding: 3.5rem 1.5rem;
  }

  .section h2 {
    font-size: 1.5rem;
  }

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

  .features-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .metrics {
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
  }

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

  .nav-links a:not(.nav-cta) {
    display: none;
  }
}

@media (max-width: 480px) {
  .hero h1 {
    font-size: 1.65rem;
  }

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

  .metric-value {
    font-size: 1.75rem;
  }
}
