@import url('https://fonts.googleapis.com/css2?family=Geist:wght@400;500;600&family=Geist+Mono:wght@400;500&display=swap');

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

:root {
  --color-bg: #ffffff;
  --color-text: #171717;
  --color-text-2: #4d4d4d;
  --color-text-3: #666666;
  --color-text-4: #808080;
  --color-border: #ebebeb;
  --color-surface: #fafafa;
  --color-link: #0072f5;
  --color-focus: hsla(212, 100%, 48%, 1);
  --shadow-border: rgba(0, 0, 0, 0.08) 0px 0px 0px 1px;
  --shadow-border-light: rgb(235, 235, 235) 0px 0px 0px 1px;
  --shadow-card: rgba(0, 0, 0, 0.08) 0px 0px 0px 1px,
    rgba(0, 0, 0, 0.04) 0px 2px 2px,
    rgba(0, 0, 0, 0.04) 0px 8px 8px -8px,
    #fafafa 0px 0px 0px 1px;
  --shadow-card-hover: rgba(0, 0, 0, 0.12) 0px 0px 0px 1px,
    rgba(0, 0, 0, 0.06) 0px 4px 8px,
    rgba(0, 0, 0, 0.04) 0px 8px 8px -8px,
    #fafafa 0px 0px 0px 1px;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: 'Geist', Arial, 'Apple Color Emoji', 'Segoe UI Emoji', sans-serif;
  font-feature-settings: "liga" 1;
  color: var(--color-text);
  background: var(--color-bg);
  line-height: 1.56;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.mono {
  font-family: 'Geist Mono', ui-monospace, 'SFMono-Regular', 'Roboto Mono', Menlo, Monaco, monospace;
  font-feature-settings: "liga" 1;
}

a {
  color: var(--color-link);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

img {
  max-width: 100%;
}

/* Container */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 40px;
}

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

/* ───── NAV ───── */
.nav {
  position: sticky;
  top: 0;
  z-index: 100;
  height: 48px;
  background: var(--color-bg);
  box-shadow: var(--shadow-border);
  display: flex;
  align-items: center;
}

.nav .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
}

.nav-logo {
  display: flex;
  align-items: baseline;
  gap: 8px;
  text-decoration: none;
  color: var(--color-text);
}

.nav-logo-name {
  font-size: 16px;
  font-weight: 600;
  letter-spacing: -0.32px;
}

.nav-logo-sub {
  font-size: 12px;
  color: var(--color-text-4);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 32px;
  list-style: none;
}

.nav-links a {
  font-size: 14px;
  font-weight: 500;
  color: var(--color-text-2);
  text-decoration: none;
  transition: color 0.15s;
}

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

.btn-primary {
  display: inline-flex;
  align-items: center;
  background: var(--color-text);
  color: #ffffff;
  padding: 8px 16px;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 500;
  font-family: inherit;
  border: none;
  cursor: pointer;
  text-decoration: none;
  transition: opacity 0.15s;
}

.btn-primary:hover {
  opacity: 0.85;
  text-decoration: none;
  color: #ffffff;
}

.btn-secondary {
  display: inline-flex;
  align-items: center;
  background: var(--color-bg);
  color: var(--color-text);
  padding: 8px 16px;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 500;
  font-family: inherit;
  border: none;
  cursor: pointer;
  text-decoration: none;
  box-shadow: var(--shadow-border-light);
  transition: background 0.15s;
}

.btn-secondary:hover {
  background: var(--color-surface);
  text-decoration: none;
}

.hamburger {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
  color: var(--color-text);
}

.hamburger svg {
  width: 24px;
  height: 24px;
}

/* ───── HERO ───── */
.hero {
  padding: 80px 0 64px;
  text-align: center;
}

.hero h1 {
  font-size: 56px;
  font-weight: 600;
  letter-spacing: -2.88px;
  line-height: 1.08;
  color: var(--color-text);
  max-width: 700px;
  margin: 0 auto 20px;
}

.hero-sub {
  font-size: 18px;
  font-weight: 400;
  color: var(--color-text-2);
  max-width: 600px;
  margin: 0 auto 32px;
  line-height: 1.56;
}

.hero-ctas {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-bottom: 24px;
}

.hero-proof {
  font-size: 12px;
  font-weight: 500;
  color: var(--color-text-4);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

/* Hero diagram */
.hero-diagram {
  max-width: 700px;
  margin: 48px auto 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  padding: 32px 24px;
  background: var(--color-surface);
  border-radius: 8px;
  box-shadow: var(--shadow-border);
}

.diagram-col {
  display: flex;
  flex-direction: column;
  gap: 8px;
  flex: 1;
}

.diagram-col-title {
  font-size: 11px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--color-text-4);
  margin-bottom: 4px;
}

.diagram-box {
  padding: 6px 10px;
  background: var(--color-bg);
  border-radius: 4px;
  box-shadow: var(--shadow-border);
  font-size: 12px;
  font-weight: 500;
  color: var(--color-text-2);
  text-align: center;
}

.diagram-arrow {
  flex-shrink: 0;
  color: var(--color-text-4);
  font-size: 20px;
  display: flex;
  align-items: center;
}

/* ───── PROBLEM / SOLUTION ───── */
.problems {
  padding: 64px 0;
  border-top: 1px solid var(--color-border);
}

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

.problem-card {
  text-align: center;
}

.problem-before {
  font-size: 14px;
  color: var(--color-text-4);
  margin-bottom: 8px;
  text-decoration: line-through;
}

.problem-after {
  font-size: 18px;
  font-weight: 600;
  letter-spacing: -0.72px;
  color: var(--color-text);
}

/* ───── FEATURES ───── */
.features {
  padding: 80px 0;
  border-top: 1px solid var(--color-border);
}

.section-label {
  font-size: 11px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--color-text-4);
  margin-bottom: 8px;
}

.section-title {
  font-size: 40px;
  font-weight: 600;
  letter-spacing: -2.4px;
  line-height: 1.2;
  color: var(--color-text);
  margin-bottom: 48px;
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}

.feature-card {
  padding: 24px;
  border-radius: 8px;
  box-shadow: var(--shadow-card);
  transition: box-shadow 0.15s;
}

.feature-card:hover {
  box-shadow: var(--shadow-card-hover);
}

.feature-icon {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  background: var(--color-surface);
  box-shadow: var(--shadow-border);
  margin-bottom: 16px;
  color: var(--color-text-3);
}

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

.feature-card h3 {
  font-size: 18px;
  font-weight: 600;
  letter-spacing: -0.72px;
  margin-bottom: 8px;
}

.feature-card p {
  font-size: 14px;
  color: var(--color-text-2);
  line-height: 1.56;
}

/* ───── HOW IT WORKS ───── */
.how-it-works {
  padding: 80px 0;
  border-top: 1px solid var(--color-border);
}

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

.step {
  counter-increment: step;
  position: relative;
}

.step-number {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
  background: var(--color-text);
  color: #ffffff;
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 16px;
}

.step h3 {
  font-size: 16px;
  font-weight: 600;
  letter-spacing: -0.32px;
  margin-bottom: 8px;
}

.step p {
  font-size: 14px;
  color: var(--color-text-2);
  line-height: 1.56;
}

.step-connector {
  position: absolute;
  top: 16px;
  left: calc(32px + 12px);
  right: -12px;
  height: 1px;
  background: var(--color-border);
}

.step:last-child .step-connector {
  display: none;
}

/* ───── ARCHITECTURE ───── */
.architecture {
  padding: 80px 0;
  border-top: 1px solid var(--color-border);
}

.arch-diagram {
  display: grid;
  grid-template-columns: 1fr auto 1fr auto 1fr;
  gap: 0;
  align-items: start;
  padding: 32px;
  background: var(--color-surface);
  border-radius: 8px;
  box-shadow: var(--shadow-border);
}

.arch-col {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.arch-col-title {
  font-size: 11px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--color-text-4);
  margin-bottom: 8px;
}

.arch-box {
  padding: 10px 14px;
  background: var(--color-bg);
  border-radius: 6px;
  box-shadow: var(--shadow-card);
  font-size: 13px;
  font-weight: 500;
  color: var(--color-text-2);
}

.arch-center .arch-box {
  background: var(--color-bg);
  color: var(--color-text);
  font-weight: 600;
}

.arch-connector {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 0 16px;
  min-height: 200px;
}

.arch-connector-line {
  width: 40px;
  height: 1px;
  background: var(--color-border);
  position: relative;
}

.arch-connector-line::after {
  content: '';
  position: absolute;
  right: -1px;
  top: -3px;
  width: 0;
  height: 0;
  border-top: 3px solid transparent;
  border-bottom: 3px solid transparent;
  border-left: 6px solid var(--color-border);
}

/* ───── OPEN SOURCE ───── */
.opensource {
  padding: 80px 0;
  border-top: 1px solid var(--color-border);
  text-align: center;
}

.opensource h2 {
  font-size: 40px;
  font-weight: 600;
  letter-spacing: -2.4px;
  margin-bottom: 32px;
}

.opensource-points {
  display: flex;
  flex-direction: column;
  gap: 12px;
  max-width: 480px;
  margin: 0 auto 32px;
  text-align: left;
}

.opensource-points li {
  font-size: 16px;
  color: var(--color-text-2);
  list-style: none;
  padding-left: 24px;
  position: relative;
}

.opensource-points li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 8px;
  width: 8px;
  height: 8px;
  border-radius: 2px;
  background: var(--color-text);
}

/* ───── CTA ───── */
.cta-section {
  padding: 80px 0;
  border-top: 1px solid var(--color-text);
  text-align: center;
}

.cta-section h2 {
  font-size: 40px;
  font-weight: 600;
  letter-spacing: -2.4px;
  margin-bottom: 16px;
}

.cta-section .cta-desc {
  font-size: 18px;
  color: var(--color-text-2);
  max-width: 600px;
  margin: 0 auto 32px;
  line-height: 1.56;
}

.cta-section .cta-email {
  font-size: 14px;
  color: var(--color-text-3);
  margin-top: 12px;
}

.cta-section .cta-footer-small {
  margin-top: 40px;
  font-size: 12px;
  color: var(--color-text-4);
}

/* ───── FOOTER ───── */
.footer {
  padding: 32px 0;
  border-top: 1px solid var(--color-border);
}

.footer .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.footer-logo {
  display: flex;
  align-items: baseline;
  gap: 8px;
}

.footer-logo-name {
  font-size: 14px;
  font-weight: 600;
  color: var(--color-text);
}

.footer-tagline {
  font-size: 12px;
  color: var(--color-text-4);
}

.footer-links {
  display: flex;
  gap: 24px;
  list-style: none;
}

.footer-links a {
  font-size: 14px;
  font-weight: 500;
  color: var(--color-text-2);
  text-decoration: none;
}

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

.footer-copy {
  font-size: 12px;
  color: var(--color-text-4);
}

/* ───── MOBILE ───── */
@media (max-width: 768px) {
  .nav-links {
    display: none;
    position: absolute;
    top: 48px;
    left: 0;
    right: 0;
    background: var(--color-bg);
    box-shadow: var(--shadow-card);
    flex-direction: column;
    padding: 16px 20px;
    gap: 16px;
  }

  .nav-links.open {
    display: flex;
  }

  .hamburger {
    display: block;
  }

  .hero {
    padding: 48px 0 40px;
  }

  .hero h1 {
    font-size: 36px;
    letter-spacing: -1.8px;
  }

  .hero-sub {
    font-size: 16px;
  }

  .hero-ctas {
    flex-direction: column;
  }

  .hero-diagram {
    flex-direction: column;
    gap: 12px;
  }

  .diagram-arrow {
    transform: rotate(90deg);
  }

  .problems-grid {
    grid-template-columns: 1fr;
    gap: 24px;
  }

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

  .steps {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .step-connector {
    display: none;
  }

  .arch-diagram {
    grid-template-columns: 1fr;
    gap: 24px;
    padding: 20px;
  }

  .arch-connector {
    min-height: auto;
    padding: 8px 0;
    transform: rotate(90deg);
  }

  .footer .container {
    flex-direction: column;
    gap: 16px;
    text-align: center;
  }

  .section-title {
    font-size: 32px;
    letter-spacing: -1.28px;
  }
}

@media (max-width: 480px) {
  .hero h1 {
    font-size: 28px;
    letter-spacing: -1.4px;
  }
}
