/* ---------- Design tokens ---------- */
:root {
  --color-primary: #2f6fed;
  --color-primary-dark: #1c4fd1;
  --color-purple: #6c5ce7;
  --color-teal: #00d2c6;
  --color-coral: #ff6b4a;
  --color-coral-dark: #ea5333;

  --gradient-brand: linear-gradient(135deg, var(--color-purple) 0%, var(--color-primary) 55%, var(--color-teal) 100%);
  --gradient-cta: linear-gradient(135deg, var(--color-coral) 0%, #ff9770 100%);

  --ink-900: #10131a;
  --ink-700: #3a3f4d;
  --ink-500: #6b7080;
  --ink-300: #b9bdc9;

  --bg-page: #fbfbfe;
  --bg-alt: #f2f2fb;
  --bg-card: #ffffff;

  --radius-sm: 10px;
  --radius-md: 18px;
  --radius-lg: 28px;

  --shadow-sm: 0 2px 10px rgba(16, 19, 26, 0.06);
  --shadow-md: 0 10px 30px rgba(47, 111, 237, 0.14);
  --shadow-lg: 0 24px 60px rgba(16, 19, 26, 0.16);

  --font-head: 'Poppins', 'Segoe UI', sans-serif;
  --font-body: 'Inter', 'Segoe UI', sans-serif;

  --header-h: 76px;
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 16px); overflow-x: hidden; }
body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink-700);
  background: var(--bg-page);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  max-width: 100vw;
}
img { max-width: 100%; display: block; }
p, h1, h2, h3, h4 { overflow-wrap: break-word; }
a { color: inherit; text-decoration: none; }
ul { margin: 0; padding: 0; list-style: none; }
h1, h2, h3, h4 { font-family: var(--font-head); color: var(--ink-900); margin: 0 0 0.5em; line-height: 1.15; }
p { margin: 0 0 1em; }

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

.text-gradient {
  background: var(--gradient-brand);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.eyebrow {
  display: inline-block;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 0.78rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--color-primary);
  margin-bottom: 10px;
}

/* ---------- Buttons & badges ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 28px;
  border-radius: 999px;
  font-family: var(--font-head);
  font-weight: 600;
  font-size: 0.98rem;
  border: none;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease, opacity 0.15s ease;
}
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(0); }

.btn-primary {
  background: var(--gradient-brand);
  color: #fff;
  box-shadow: var(--shadow-md);
}
.btn-accent {
  background: var(--gradient-cta);
  color: #fff;
  box-shadow: 0 10px 30px rgba(255, 107, 74, 0.32);
}
.btn:disabled { opacity: 0.6; cursor: not-allowed; transform: none; }

.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  border-radius: 999px;
  font-size: 0.82rem;
  font-weight: 600;
  font-family: var(--font-head);
}
.badge-soon {
  background: rgba(47, 111, 237, 0.1);
  color: var(--color-primary-dark);
}
.badge-lg { padding: 10px 18px; font-size: 0.9rem; }

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  height: var(--header-h);
  display: flex;
  align-items: center;
  background: rgba(251, 251, 254, 0.78);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(16, 19, 26, 0.06);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; }
.brand { display: flex; align-items: center; gap: 10px; }
.brand-logo { height: 36px; width: auto; }
.brand-name { font-family: var(--font-head); font-weight: 700; font-size: 1.15rem; color: var(--ink-900); }

.nav-links { display: flex; align-items: center; gap: 30px; }
.nav-links a {
  font-family: var(--font-head);
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--ink-700);
  position: relative;
  padding: 6px 0;
}
.nav-links a.active,
.nav-links a:hover { color: var(--color-primary); }
.nav-links a.active::after {
  content: '';
  position: absolute;
  left: 0; right: 0; bottom: -4px;
  height: 3px;
  border-radius: 3px;
  background: var(--gradient-brand);
}

.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 40px;
  height: 40px;
  background: none;
  border: none;
  cursor: pointer;
}
.nav-toggle span { display: block; height: 2px; width: 24px; background: var(--ink-900); border-radius: 2px; transition: transform 0.2s ease, opacity 0.2s ease; }
.nav-toggle.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.open span:nth-child(2) { opacity: 0; }
.nav-toggle.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  overflow: hidden;
  padding: 76px 0 90px;
  background: var(--bg-page);
}
.hero-inner {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  align-items: center;
  gap: 40px;
}
.hero-copy, .hero-art { min-width: 0; }
.hero-copy h1 { font-size: clamp(2.2rem, 4.2vw, 3.4rem); font-weight: 800; overflow-wrap: break-word; }
.hero-sub { font-size: 1.08rem; color: var(--ink-500); max-width: 46ch; }
.hero-actions { display: flex; align-items: center; gap: 18px; flex-wrap: wrap; margin-top: 8px; }

.hero-art { position: relative; display: flex; justify-content: center; }
.blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(10px);
  opacity: 0.5;
  z-index: 0;
}
.blob-1 { width: 260px; height: 260px; background: var(--color-teal); top: -30px; right: 10%; opacity: 0.35; }
.blob-2 { width: 220px; height: 220px; background: var(--color-purple); bottom: -20px; left: 8%; opacity: 0.3; }

.floating { animation: float 5s ease-in-out infinite; }
@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-14px); }
}

/* ---------- Phone frame ---------- */
.phone-frame {
  position: relative;
  z-index: 1;
  background: #0e0f14;
  border-radius: 34px;
  padding: 10px;
  box-shadow: var(--shadow-lg);
  width: 220px;
  border: none;
  cursor: default;
  display: block;
}
.phone-frame img { border-radius: 24px; width: 100%; display: block; }
.phone-frame::before {
  content: '';
  position: absolute;
  top: 22px;
  left: 50%;
  transform: translateX(-50%);
  width: 60px;
  height: 8px;
  border-radius: 6px;
  background: #1e2028;
  z-index: 2;
}
.phone-frame-lg { width: 300px; }

button.phone-frame { cursor: zoom-in; padding: 10px 10px 0; text-align: left; }
.phone-caption {
  display: block;
  color: #fff;
  font-family: var(--font-head);
  font-weight: 600;
  font-size: 0.88rem;
  text-align: center;
  padding: 10px 4px 12px;
}

/* ---------- Sections ---------- */
.section { padding: 88px 0; }
.section-alt { background: var(--bg-alt); }
.section-heading { max-width: 640px; margin: 0 auto 48px; text-align: center; }
.section-heading h2 { font-size: clamp(1.7rem, 3vw, 2.3rem); }
.section-heading p { color: var(--ink-500); }

/* ---------- Feature grid ---------- */
.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 24px;
}
.feature-card {
  background: var(--bg-card);
  border-radius: var(--radius-md);
  padding: 30px 26px;
  box-shadow: var(--shadow-sm);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.feature-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-md); }
.feature-icon {
  width: 52px;
  height: 52px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--gradient-brand);
  color: #fff;
  margin-bottom: 18px;
}
.feature-icon .icon { width: 26px; height: 26px; }
.feature-card h3 { font-size: 1.08rem; margin-bottom: 8px; }
.feature-card p { color: var(--ink-500); font-size: 0.95rem; margin: 0; }

/* ---------- Screenshot showcase ---------- */
.screenshot-row {
  display: flex;
  gap: 26px;
  overflow-x: auto;
  padding: 10px 4px 26px;
  scroll-snap-type: x proximity;
}
.screenshot-row .phone-frame { flex: 0 0 auto; scroll-snap-align: start; }
.screenshot-row::-webkit-scrollbar { height: 8px; }
.screenshot-row::-webkit-scrollbar-thumb { background: var(--ink-300); border-radius: 8px; }

/* ---------- CTA band ---------- */
.cta-band {
  background: var(--gradient-brand);
  padding: 70px 0;
}
.cta-inner { text-align: center; color: #fff; }
.cta-inner h2 { color: #fff; font-size: clamp(1.6rem, 3vw, 2.1rem); }
.cta-inner p { color: rgba(255,255,255,0.85); max-width: 50ch; margin: 0 auto 26px; }

/* ---------- Page hero (contact / manual) ---------- */
.page-hero {
  padding: 64px 0 36px;
  background: linear-gradient(180deg, rgba(108,92,231,0.08), rgba(251,251,254,0) 70%);
}
.page-hero h1 { font-size: clamp(2rem, 3.6vw, 2.8rem); }

/* ---------- Contact form ---------- */
.contact-layout {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 48px;
  align-items: start;
}
.contact-form {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  padding: 36px;
  box-shadow: var(--shadow-sm);
}
.form-row { margin-bottom: 20px; display: flex; flex-direction: column; gap: 8px; }
.form-row label { font-family: var(--font-head); font-weight: 600; font-size: 0.9rem; color: var(--ink-700); }
.form-row input,
.form-row select,
.form-row textarea {
  font-family: var(--font-body);
  font-size: 1rem;
  padding: 13px 16px;
  border-radius: var(--radius-sm);
  border: 1.5px solid #e3e4ee;
  background: #fdfdff;
  color: var(--ink-900);
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.form-row input:focus,
.form-row select:focus,
.form-row textarea:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 4px rgba(47,111,237,0.12);
}
.form-row textarea { resize: vertical; min-height: 130px; }
.honeypot { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form-status { min-height: 1.4em; margin: 14px 0 0; font-weight: 600; font-size: 0.92rem; }
.form-status.success { color: #1a9c6c; }
.form-status.error { color: var(--color-coral-dark); }
.contact-aside { display: flex; justify-content: center; padding-top: 10px; }

/* ---------- Manual layout ---------- */
.manual-layout { display: grid; grid-template-columns: 240px 1fr; gap: 56px; align-items: start; }
.manual-toc {
  position: sticky;
  top: calc(var(--header-h) + 24px);
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 22px;
  background: var(--bg-card);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
}
.toc-title { font-family: var(--font-head); font-weight: 700; font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--ink-500); margin: 0 0 8px; }
.manual-toc a {
  font-size: 0.92rem;
  color: var(--ink-700);
  padding: 8px 10px;
  border-radius: 8px;
  font-weight: 500;
}
.manual-toc a:hover { background: var(--bg-alt); color: var(--color-primary); }
.manual-toc a.active { background: rgba(47,111,237,0.1); color: var(--color-primary-dark); font-weight: 700; }

.manual-content { display: flex; flex-direction: column; gap: 64px; }
.manual-entry h2 { font-size: 1.5rem; scroll-margin-top: calc(var(--header-h) + 16px); }
.manual-entry p { color: var(--ink-700); max-width: 68ch; }
.manual-list { display: flex; flex-direction: column; gap: 10px; max-width: 68ch; }
.manual-list li {
  position: relative;
  padding-left: 26px;
  color: var(--ink-700);
}
.manual-list li::before {
  content: '';
  position: absolute;
  left: 0; top: 8px;
  width: 10px; height: 10px;
  border-radius: 3px;
  background: var(--gradient-brand);
}

.manual-figure {
  margin: 24px 0 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}
.manual-figure .phone-frame { width: 210px; }
.manual-figure figcaption { color: var(--ink-500); font-size: 0.9rem; text-align: center; }
.manual-figure.two-up { flex-direction: row; justify-content: center; flex-wrap: wrap; gap: 24px; }

/* ---------- Lightbox ---------- */
.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(10, 11, 16, 0.86);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 200;
  padding: 40px 20px;
}
.lightbox[hidden] { display: none; }
.lightbox figure { margin: 0; max-width: 380px; text-align: center; }
.lightbox img { border-radius: 28px; box-shadow: var(--shadow-lg); }
.lightbox figcaption { color: #fff; margin-top: 16px; font-family: var(--font-head); font-weight: 600; }
.lightbox-close {
  position: absolute;
  top: 24px; right: 28px;
  background: rgba(255,255,255,0.12);
  color: #fff;
  border: none;
  width: 44px; height: 44px;
  border-radius: 50%;
  font-size: 1.6rem;
  cursor: pointer;
  line-height: 1;
}

/* ---------- 404 ---------- */
.not-found { text-align: center; padding: 140px 0; }
.not-found .btn { margin-top: 12px; }

/* ---------- Footer ---------- */
.site-footer { background: var(--ink-900); color: rgba(255,255,255,0.7); padding: 52px 0 0; }
.footer-inner { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 24px; padding-bottom: 40px; border-bottom: 1px solid rgba(255,255,255,0.08); }
.footer-brand { display: flex; align-items: center; gap: 14px; }
.footer-logo { height: 34px; width: auto; }
.footer-brand p { margin: 0; font-size: 0.92rem; }
.footer-links { display: flex; gap: 26px; font-weight: 600; font-family: var(--font-head); font-size: 0.92rem; }
.footer-links a:hover { color: #fff; }
.footer-bottom { padding: 20px 0; font-size: 0.82rem; text-align: center; }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .hero-inner { grid-template-columns: 1fr; text-align: center; }
  .hero-copy { order: 1; }
  .hero-art { order: 0; }
  .hero-actions { justify-content: center; }
  .hero-sub { margin-left: auto; margin-right: auto; }
  .contact-layout { grid-template-columns: 1fr; }
  .contact-aside { order: -1; }
  .manual-layout { grid-template-columns: 1fr; }
  .manual-toc { position: static; flex-direction: row; flex-wrap: wrap; }
}

@media (max-width: 720px) {
  .nav-links {
    position: absolute;
    top: var(--header-h);
    left: 0; right: 0;
    background: var(--bg-page);
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
    padding: 16px 24px 22px;
    border-bottom: 1px solid rgba(16,19,26,0.08);
    display: none;
  }
  .nav-links.open { display: flex; }
  .nav-links a { width: 100%; padding: 10px 0; }
  .nav-toggle { display: flex; }
  .section { padding: 60px 0; }
}
