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

:root {
  --ink:    #1c1c1e;
  --sub:    #48484a;
  --quiet:  #8e8e93;
  --border: #e5e5ea;
  --bg:     #ffffff;
  --bg2:    #f2f2f7;
  --blue:   #1a56db;
  --blue2:  #1240b0;
  --r:      14px;
  --font:   -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
}

html { scroll-behavior: smooth; }
body {
  font-family: var(--font);
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  line-height: 1.6;
}
a { color: var(--blue); text-decoration: none; }
a:hover { text-decoration: underline; }
img { display: block; max-width: 100%; }

.container {
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ── Bilingual toggle ── */
html[lang="bg"] .en { display: none; }
html[lang="en"] .bg { display: none; }

/* ── Nav ── */
.nav {
  position: sticky; top: 0; z-index: 100;
  background: rgba(255,255,255,0.88);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
}
.nav-inner {
  position: relative;
  display: flex; align-items: center;
  justify-content: space-between;
  height: 56px;
}
.nav-logo {
  display: flex; align-items: center; gap: 9px;
  font-weight: 700; font-size: 16px; color: var(--ink);
}
.nav-logo img { border-radius: 8px; }
.nav-right {
  display: flex; align-items: center; gap: 20px;
}
.nav-links { display: flex; gap: 20px; font-size: 14px; }
.nav-links a {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: var(--sub);
  font-weight: 500;
}
.nav-links a:hover { color: var(--blue); text-decoration: none; }
.nav-links a.active { color: var(--blue); }
.alpha-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 17px;
  padding: 2px 6px;
  border: 1px solid rgba(26, 86, 219, 0.18);
  border-radius: 999px;
  background: rgba(26, 86, 219, 0.08);
  color: var(--blue);
  font-size: 10px;
  font-weight: 800;
  line-height: 1;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}
.mobile-menu-toggle {
  display: none;
  width: 38px;
  height: 38px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--bg);
  cursor: pointer;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 4px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.08);
}
.mobile-menu-toggle span {
  display: block;
  width: 16px;
  height: 2px;
  border-radius: 999px;
  background: var(--ink);
}

/* Language toggle */
.lang-toggle {
  display: flex; align-items: center;
  background: var(--bg2); border-radius: 999px;
  padding: 3px;
  gap: 2px;
}
.lang-btn {
  border: none; background: transparent; cursor: pointer;
  font-family: var(--font); font-size: 13px; font-weight: 600;
  color: var(--quiet); padding: 4px 10px; border-radius: 999px;
  transition: background .15s, color .15s;
}
.lang-btn.active {
  background: var(--bg); color: var(--ink);
  box-shadow: 0 1px 3px rgba(0,0,0,0.12);
}

/* ── Hero ── */
.hero {
  background: linear-gradient(175deg, #f0f5ff 0%, #fff 55%);
  padding: 80px 0 80px;
  overflow-x: clip;
}
.hero-inner {
  display: grid;
  grid-template-columns: 1fr 420px;
  gap: 40px;
  align-items: flex-end;
}
.hero-text { padding-bottom: 72px; }
.hero-eyebrow {
  font-size: 12px; font-weight: 700;
  letter-spacing: .1em; text-transform: uppercase;
  color: var(--blue); margin-bottom: 16px;
}
.hero-text h1 {
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 800; line-height: 1.12;
  color: var(--ink); margin-bottom: 18px;
}
.hero-text p {
  font-size: 18px; color: var(--sub);
  line-height: 1.7; max-width: 440px;
  margin-bottom: 32px;
}
.hero-text p a { color: var(--blue); font-weight: 500; }

/* ── App Store badge ── */
.appstore-badge {
  display: inline-flex; align-items: center; gap: 10px;
  background: #000; color: #fff;
  border-radius: 12px;
  padding: 11px 20px;
  text-decoration: none;
  transition: transform .18s, opacity .18s;
  margin-bottom: 20px;
}
.appstore-badge:hover {
  opacity: .88; transform: translateY(-2px); text-decoration: none;
}
.appstore-badge svg { flex-shrink: 0; }
.badge-text { display: flex; flex-direction: column; line-height: 1.2; }
.badge-text small {
  font-size: 10px; font-weight: 400; opacity: .85; letter-spacing: .02em;
}
.badge-text strong { font-size: 20px; font-weight: 600; letter-spacing: -.02em; }

.hero-note {
  font-size: 12px; color: var(--quiet); max-width: 360px; line-height: 1.5;
}

/* Hero device: single phone, bottom-anchored */
.hero-device {
  display: flex; justify-content: center; align-items: flex-end;
}
.phone-frame {
  position: relative; width: 270px;
  background: #1a1a1a;
  border-radius: 46px;
  padding: 12px;
  box-shadow:
    0 0 0 1px #3a3a3a,
    0 30px 80px rgba(0,0,0,.28),
    0 8px 20px rgba(0,0,0,.15);
}
.phone-frame img {
  border-radius: 36px;
  width: 100%;
  height: auto;
}

/* ── Features ── */
.features { padding: 96px 0; background: var(--bg); }
.features-intro { text-align: center; margin-bottom: 72px; }
.features-intro h2 {
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  font-weight: 800; margin-bottom: 10px;
}
.features-intro p { font-size: 17px; color: var(--sub); }

.feature-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: center;
  margin-bottom: 96px;
}
.feature-row:last-child { margin-bottom: 0; }
.feature-row.flip { direction: rtl; }
.feature-row.flip > * { direction: ltr; }

.feature-copy h3 {
  font-size: clamp(1.3rem, 2.2vw, 1.75rem);
  font-weight: 800; line-height: 1.2;
  margin-bottom: 14px;
}
.feature-copy p {
  font-size: 16px; color: var(--sub); line-height: 1.75;
}
.feature-copy ul {
  margin-top: 14px; margin-left: 18px;
}
.feature-copy ul li {
  font-size: 15px; color: var(--sub); line-height: 1.7; margin-bottom: 3px;
}
.inline-map-link {
  display: inline-flex; align-items: center; gap: 4px;
  margin-top: 16px;
  font-weight: 800; font-size: 15px;
}

.feature-shot {
  display: flex; justify-content: center;
}

/* ── Divider ── */
.section-divider {
  width: 48px; height: 3px;
  background: var(--blue); border-radius: 2px;
  margin-bottom: 20px;
}

/* ── Call-out banner ── */
.cta-banner {
  background: var(--ink);
  color: #fff;
  padding: 72px 0;
  text-align: center;
}
.cta-banner h2 {
  font-size: clamp(1.5rem, 3vw, 2rem);
  font-weight: 800; margin-bottom: 12px;
}
.cta-banner p {
  font-size: 16px; opacity: .7; margin-bottom: 28px;
}
.cta-banner .appstore-badge { background: #fff; color: #000; }
.cta-banner .appstore-badge .badge-text small { opacity: .6; }

/* ── Analytics promo ── */
.analytics-promo {
  padding: 80px 0;
  background: var(--bg2);
}
.promo-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
}
.promo-text h2 {
  font-size: clamp(1.5rem, 3vw, 2rem);
  font-weight: 800;
  margin-bottom: 14px;
}
.promo-text p {
  font-size: 17px;
  color: var(--sub);
  line-height: 1.7;
  margin-bottom: 28px;
}
.analytics-cta-link {
  display: inline-block;
  font-weight: 700;
  font-size: 16px;
  color: var(--bg);
  background: var(--ink);
  padding: 14px 32px;
  border-radius: 999px;
  transition: opacity .18s, transform .18s;
}
.analytics-cta-link:hover {
  opacity: .85;
  transform: translateY(-2px);
  text-decoration: none;
  color: var(--bg);
}

/* Browser frame for analytics preview */
.browser-frame {
  background: #1a1a1a;
  border-radius: 12px;
  overflow: hidden;
  box-shadow:
    0 0 0 1px #3a3a3a,
    0 20px 60px rgba(0,0,0,.2),
    0 4px 12px rgba(0,0,0,.1);
}
.browser-bar {
  display: flex;
  gap: 7px;
  padding: 12px 16px;
  background: #2a2a2a;
}
.browser-dot {
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: #555;
}
.browser-dot:nth-child(1) { background: #ff5f57; }
.browser-dot:nth-child(2) { background: #ffbd2e; }
.browser-dot:nth-child(3) { background: #28c840; }
.browser-frame img {
  display: block;
  width: 100%;
  height: auto;
}

@media (max-width: 860px) {
  .promo-grid {
    grid-template-columns: 1fr;
    gap: 36px;
    text-align: center;
  }
  .promo-text .section-divider { margin: 0 auto 20px; }
  .promo-visual { order: -1; }
}

/* ── Footer ── */
.footer {
  background: var(--bg2);
  border-top: 1px solid var(--border);
  padding: 40px 0 32px;
}
.footer-inner {
  display: flex; flex-direction: column;
  align-items: center; gap: 16px; text-align: center;
}
.footer-logo {
  display: flex; align-items: center; gap: 8px;
  font-weight: 700; font-size: 15px; color: var(--ink);
}
.footer-logo img { border-radius: 7px; }
.footer-links { display: flex; gap: 20px; }
.footer-links a {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 13px; color: var(--sub); font-weight: 500;
}
.footer-links a:hover { color: var(--blue); text-decoration: none; }
.footer-github { display: flex; align-items: center; }
.footer-legal { font-size: 12px; color: var(--quiet); max-width: 460px; line-height: 1.6; }

/* ── Page (privacy / support) ── */
.page-header {
  background: linear-gradient(175deg, #f0f5ff 0%, #fff 70%);
  padding: 24px 0 48px;
  text-align: center;
}
.page-header h1 {
  font-size: clamp(1.8rem, 4vw, 2.6rem);
  font-weight: 800; margin-bottom: 8px;
}
.page-header p {
  color: var(--quiet);
  font-size: 15px;
  margin-top: 4px;
}
.page-header .updated {
  font-size: 14px; color: var(--quiet);
}
.alpha-note {
  max-width: 720px;
  margin: 16px auto 0;
  padding: 12px 14px;
  border: 1px solid rgba(26, 86, 219, 0.16);
  border-radius: 18px;
  background: rgba(26, 86, 219, 0.06);
  color: var(--sub);
  font-size: 14px;
  line-height: 1.5;
}
.alpha-note strong { color: var(--blue); text-transform: uppercase; letter-spacing: 0.03em; }
.alpha-title-badge {
  margin-left: 8px;
  vertical-align: middle;
  transform: translateY(-2px);
}
.page-body {
  padding: 64px 0 96px;
}
.page-body .container { max-width: 720px; }

.page-body h2 {
  font-size: 1.2rem; font-weight: 700;
  color: var(--ink); margin: 36px 0 10px;
}
.page-body h2:first-child { margin-top: 0; }
.page-body p {
  font-size: 15.5px; color: #374151;
  line-height: 1.8; margin-bottom: 12px;
}
.page-body ul {
  margin: 0 0 12px 18px;
}
.page-body ul li {
  font-size: 15.5px; color: #374151;
  line-height: 1.8; margin-bottom: 4px;
}
.page-body a { color: var(--blue); font-weight: 500; }
code {
  font-family: ui-monospace, "Cascadia Code", Menlo, monospace;
  font-size: .88em;
  background: var(--bg2);
  border-radius: 4px;
  padding: 1px 5px;
}

.callout-box {
  background: var(--bg2);
  border-radius: var(--r);
  padding: 36px 24px;
  margin-top: 44px;
  text-align: center;
}
.callout-box h2 { margin-top: 0 !important; }
.btn-primary {
  display: inline-flex; align-items: center;
  background: var(--ink);
  font-weight: 600; font-size: 15px;
  padding: 12px 28px; border-radius: 999px;
  margin-top: 12px;
  transition: opacity .18s, transform .18s;
}
a.btn-primary, .btn-primary, a.btn-primary:visited, .btn-primary:visited { color: #fff; }
.page-body a.btn-primary,
.page-body .btn-primary,
.page-body a.btn-primary:visited,
.page-body .btn-primary:visited { color: #fff; }
.btn-primary:hover {
  opacity: .85; transform: translateY(-1px); text-decoration: none; color: #fff;
}

/* ── Responsive ── */
@media (max-width: 860px) {
  .hero-inner {
    grid-template-columns: 1fr;
  }
  .hero-text { padding-bottom: 0; text-align: center; }
  .hero-text p { margin-left: auto; margin-right: auto; }
  .hero-note { margin: 0 auto; }
  .hero-device { margin-top: 40px; }

  .feature-row {
    grid-template-columns: 1fr;
    gap: 40px;
    text-align: center;
  }
  .feature-row.flip { direction: ltr; }
  .feature-shot { order: -1; }
  .feature-copy ul { text-align: left; display: inline-block; }
}

@media (max-width: 600px) {
  .nav-inner { height: 54px; }
  .nav-right { gap: 10px; }
  .mobile-menu-toggle { display: flex; }
  .nav-links {
    position: absolute;
    top: calc(100% + 8px);
    right: 24px;
    z-index: 1000;
    display: none;
    width: min(240px, calc(100vw - 48px));
    flex-direction: column;
    gap: 2px;
    padding: 8px;
    border: 1px solid rgba(229, 229, 234, 0.9);
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.97);
    box-shadow: 0 14px 40px rgba(0, 0, 0, 0.16);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
    font-size: 15px;
  }
  .nav-links.is-open { display: flex; }
  .nav-links a {
    display: flex;
    align-items: center;
    min-height: 44px;
    padding: 10px 12px;
    border-radius: 12px;
    line-height: 1.1;
  }
  .nav-links a:active,
  .nav-links a:hover {
    background: var(--bg2);
  }
  .footer-inner { align-items: flex-start; }
  .footer-links { flex-wrap: wrap; gap: 8px; }
  .footer-links a {
    display: inline-flex;
    align-items: center;
    min-height: 40px;
    padding: 8px 12px;
    border-radius: 999px;
    background: var(--bg2);
  }
  .footer-github { justify-content: center; min-width: 40px; }
  .phone-frame { width: 220px; }
}
