:root {
  --bg: #0e1618;
  --surface: #142023;
  --surface-2: #1b2c30;
  --border: #223031;
  --text: #f5f6f6;
  --muted: #a1a8aa;
  --accent: #2c6a75;
  --accent-soft: rgba(44, 106, 117, 0.12);
  --radius: 10px;
  --font-body: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica,
    Arial, sans-serif;
  --font-display: Georgia, "Times New Roman", Times, serif;
  --font-mono: ui-monospace, "SF Mono", SFMono-Regular, Menlo, Consolas,
    "Liberation Mono", monospace;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 84px;
}

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

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

/* Layout ---------------------------------------------------------------- */

.container {
  width: min(1080px, calc(100% - 48px));
  margin-inline: auto;
}

/* Header ----------------------------------------------------------------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: rgba(14, 22, 24, 0.85);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.brand-mark {
  width: 30px;
  height: 30px;
  display: block;
  object-fit: cover;
  object-position: center;
  border-radius: 8px;
  flex-shrink: 0;
}

.brand-name {
  font-weight: 600;
  letter-spacing: 0.02em;
}

.nav {
  display: flex;
  gap: 28px;
}

.nav a {
  color: var(--muted);
  font-size: 14px;
  transition: color 0.15s ease;
}

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

/* Hero ------------------------------------------------------------------- */

.hero {
  padding: 120px 0 96px;
  border-bottom: 1px solid var(--border);
  background:
    radial-gradient(1200px 500px at 75% -10%, var(--accent-soft), transparent 60%),
    var(--bg);
}

.hero-inner {
  max-width: 960px;
  display: grid;
  grid-template-columns: minmax(0, 360px) minmax(0, 1fr);
  align-items: center;
  gap: clamp(32px, 6vw, 80px);
}

.hero-visual {
  line-height: 0;
}

.hero-visual img {
  display: block;
  width: min(340px, 100%);
  height: auto;
  border-radius: 14px;
}

.eyebrow {
  margin: 0 0 20px;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--muted);
}

h1 {
  margin: 0 0 24px;
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(40px, 7vw, 72px);
  line-height: 1.08;
  letter-spacing: -0.01em;
  text-wrap: balance;
}

h1 em {
  font-style: italic;
  color: var(--accent);
}

.lede {
  margin: 0 0 40px;
  max-width: 560px;
  color: var(--muted);
  font-size: 19px;
  line-height: 1.65;
  text-wrap: pretty;
}

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

.meta {
  margin: 0;
  font-family: var(--font-mono);
  font-size: 12.5px;
  color: var(--muted);
}

.meta.muted a {
  text-decoration: underline;
  text-underline-offset: 3px;
}

.meta.muted a:hover {
  color: var(--text);
}

/* Buttons ---------------------------------------------------------------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 22px;
  border-radius: var(--radius);
  border: 1px solid transparent;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: transform 0.12s ease, box-shadow 0.15s ease, background 0.15s ease,
    border-color 0.15s ease;
}

.btn:active {
  transform: translateY(1px);
}

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

.btn-primary:hover {
  box-shadow: 0 6px 24px rgba(44, 106, 117, 0.35);
}

.btn-ghost {
  border-color: var(--border);
  color: var(--text);
}

.btn-ghost:hover {
  border-color: var(--muted);
}

.btn-large {
  padding: 16px 30px;
  font-size: 16px;
}

.btn-meta {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 400;
  opacity: 0.85;
}

/* Features ---------------------------------------------------------------- */

.features {
  padding: 96px 0;
}

.features h2,
.how h2,
.privacy h2,
.download h2 {
  margin: 0 0 48px;
  max-width: 620px;
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(28px, 4vw, 40px);
  line-height: 1.2;
  text-wrap: balance;
}

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

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px;
  transition: border-color 0.2s ease, background 0.2s ease;
}

.card:hover {
  border-color: rgba(44, 106, 117, 0.45);
  background: var(--surface-2);
}

.card h3 {
  margin: 0 0 10px;
  font-size: 17px;
  font-weight: 600;
  letter-spacing: 0.01em;
}

.card p {
  margin: 0;
  color: var(--muted);
  font-size: 15px;
}

.card p + p {
  margin-top: 10px;
}

.card p code {
  font-family: var(--font-mono);
  font-size: 0.92em;
  color: var(--text);
  overflow-wrap: anywhere;
}

.provider-logos {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 18px;
}

.provider-logos img {
  height: 22px;
  width: auto;
  opacity: 0.75;
  transition: opacity 0.2s ease;
}

.provider-logos img:hover {
  opacity: 1;
}

.card-media {
  margin: 0 0 18px;
  width: 100%;
  aspect-ratio: 4 / 3;
  display: flex;
  align-items: center;
  justify-content: center;
}

.card-media img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

/* How it works ---------------------------------------------------------- */

.how {
  padding: 96px 0;
}

.how h2 {
  margin-bottom: 16px;
}

.how .eyebrow {
  margin-bottom: 12px;
}

.how .container > h2 {
  margin-bottom: 72px;
}

.flow {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.flow-box {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 8px;
  padding: 28px;
}

.flow-box h3 {
  margin: 4px 0 0;
  font-size: 17px;
  font-weight: 600;
  letter-spacing: 0.01em;
}

.flow-box p {
  margin: 0;
  color: var(--muted);
  font-size: 15px;
  max-width: 360px;
}

.flow-narrow {
  max-width: 460px;
}

.flow-tag {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--accent);
  color: #fff;
  font-size: 14px;
  font-weight: 600;
  line-height: 26px;
  text-align: center;
  flex-shrink: 0;
}

.flow-link {
  position: relative;
  width: 2px;
  height: 48px;
  background: var(--border);
}

.flow-link::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: -1px;
  transform: translateX(-50%);
  border-left: 6px solid transparent;
  border-right: 6px solid transparent;
  border-top: 8px solid var(--accent);
}

.flow-split,
.flow-merge {
  position: relative;
  width: 2px;
  height: 48px;
  background: transparent;
}

.flow-split .c-in,
.flow-merge .c-in,
.flow-merge .c-out {
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 2px;
  height: 24px;
  background: var(--border);
}

.flow-split .c-rail,
.flow-merge .c-rail {
  position: absolute;
  top: 24px;
  left: 0;
  width: 100%;
  height: 2px;
  background: var(--border);
}

.flow-split .c-out {
  position: absolute;
  top: 26px;
  width: 2px;
  height: 22px;
  background: var(--border);
}

.flow-split .c-out-left {
  left: 25%;
  transform: translateX(-50%);
}

.flow-split .c-out-right {
  left: 75%;
  transform: translateX(-50%);
}

.flow-merge .c-in-left {
  left: 25%;
  transform: translateX(-50%);
}

.flow-merge .c-in-right {
  left: 75%;
  transform: translateX(-50%);
}

.flow-branches {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 16px;
  width: 100%;
}

.flow-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 12px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

.flow-badge-local {
  background: var(--accent);
  color: #fff;
}

.flow-badge-cloud {
  border: 1px solid var(--accent);
  color: var(--accent);
}

/* Privacy ---------------------------------------------------------------- */

.privacy {
  padding: 96px 0;
  border-top: 1px solid var(--border);
  background: var(--surface);
}

.privacy-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 28px;
  max-width: 820px;
}

.privacy-grid p {
  margin: 0;
  color: var(--muted);
  font-size: 16px;
  text-wrap: pretty;
}

/* Download ---------------------------------------------------------------- */

.download {
  padding: 96px 0;
  text-align: center;
  border-top: 1px solid var(--border);
  background:
    radial-gradient(900px 380px at 50% 120%, var(--accent-soft), transparent 60%),
    var(--bg);
}

.download h2 {
  margin-inline: auto;
}

.download-note {
  margin: 0 auto 36px;
  max-width: 520px;
  color: var(--muted);
}

.download .meta {
  margin-top: 18px;
}

.muted {
  color: var(--muted);
}

/* Footer ------------------------------------------------------------------ */

.site-footer {
  border-top: 1px solid var(--border);
  padding: 32px 0;
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
  font-size: 14px;
}

/* Focus / a11y ------------------------------------------------------------ */

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

/* Error 404 --------------------------------------------------------------- */

.error-404 {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background:
    radial-gradient(1200px 500px at 75% -10%, var(--accent-soft), transparent 60%),
    var(--bg);
}

.error-404 .container {
  text-align: center;
  padding: 48px;
}

.error-404 .hero-visual img {
  border-radius: 12px;
  margin-bottom: 24px;
}

.error-404 h1 {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(32px, 6vw, 48px);
  margin: 0 0 24px;
  letter-spacing: -0.01em;
}

.error-404 .lede {
  color: var(--muted);
  font-size: 19px;
  line-height: 1.65;
  max-width: 560px;
  margin: 0 auto 32px;
}

.error-404 .hero-actions {
  display: flex;
  justify-content: center;
  gap: 14px;
  flex-wrap: wrap;
}

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

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

/* Responsive --------------------------------------------------------------- */

@media (max-width: 640px) {
  .hero {
    padding: 72px 0 64px;
  }

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

  .hero-visual {
    display: flex;
    justify-content: center;
  }

  .hero-visual img {
    max-width: 120px;
  }

  h1 {
    font-size: clamp(34px, 9vw, 40px);
    margin-bottom: 18px;
  }

  .lede {
    font-size: 17px;
    margin-bottom: 32px;
  }
  .features,
  .how,
  .privacy,
  .download {
    padding: 64px 0;
  }

  .how .container > h2 {
    margin-bottom: 56px;
  }

  .flow-link {
    height: 40px;
  }

  .flow-split,
  .flow-merge {
    height: 40px;
  }

  .flow-split span,
  .flow-merge span {
    display: none;
  }

  .flow-split::before,
  .flow-merge::before {
    content: "";
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 2px;
    height: 100%;
    background: var(--border);
  }

  .flow-branches {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .flow-branches .flow-box:not(:last-child)::after {
    content: "";
    width: 2px;
    height: 16px;
    margin: 4px auto 0;
    background: var(--border);
  }

  .nav {
    gap: 18px;
  }

  .nav a {
    font-size: 13px;
  }

  .brand-name {
    display: none;
  }

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