/* Basic layout */
*,
*::before,
*::after {
  box-sizing: border-box;
}

:root {
  --color-bg: #ffffff;
  --color-text: #0f172a;
  --color-muted: #4b5563;
  --color-soft: #6b7280;
  --color-extra-muted: #9ca3af;
  --color-border: #e5e7eb;
  --color-border-light: #d1d5db;
  --color-section-alt: #f9fafb;
  --color-card: #ffffff;
  --color-card-alt: #f9fafb;
  --color-nav-bg: rgba(255, 255, 255, 0.9);
  --color-nav-border: rgba(226, 232, 240, 0.9);
  --color-nav-sheet: rgba(255, 255, 255, 0.98);
  --color-footer-border: #e5e7eb;
  --color-hero-pill-bg: #e5efff;
  --color-hero-pill-muted-bg: rgba(229, 239, 255, 0.65);
  --color-pill-text: #0b63f6;
  --color-link: #0b63f6;
  --color-link-hover: #174fd6;
  --color-pill-tag-bg: #e5efff;
  --color-pill-tag-text: #1d4ed8;
  --color-modal-panel: #ffffff;
  --color-modal-close-bg: rgba(226, 232, 240, 0.6);
  --color-modal-backdrop: rgba(15, 23, 42, 0.45);
}

body {
  margin: 0;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "SF Pro Text",
    "Segoe UI", sans-serif;
  color: var(--color-text);
  background: var(--color-bg);
}

img {
  max-width: 100%;
  display: block;
}

.page {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* Nav */

.nav {
  position: sticky;
  top: 0;
  z-index: 40;
  backdrop-filter: blur(16px);
  background: var(--color-nav-bg);
  border-bottom: 1px solid var(--color-nav-border);
}

.inner {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 1.25rem;
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.9rem 1.25rem 0.9rem 0;
}

.logo-wrap {
  display: flex;
  align-items: center;
  gap: 0.7rem;
}

.logo-mark {
  width: 34px;
  height: 34px;
  border-radius: 11px;
  background: #0b63f6;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  box-shadow: 0 10px 25px rgba(37, 99, 235, 0.6);
}

.logo-mark img {
  width: 140%;
  height: auto;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 1.2rem;
  font-size: 0.9rem;
}

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

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

.nav-cta {
  padding: 0.4rem 1rem;
  border-radius: 999px;
  border: 1px solid var(--color-link);
  color: var(--color-link);
  font-weight: 600;
}

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 4px;
  border: none;
  background: transparent;
  padding: 0;
}

.nav-toggle span {
  width: 18px;
  height: 2px;
  background: var(--color-text);
  border-radius: 999px;
}

/* Hero */

.hero {
  padding: 4.5rem 0 4rem;
}

.hero-inner {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr);
  gap: 3.5rem;
  align-items: center;
}

.hero-copy h1 {
  font-size: clamp(2.4rem, 4vw, 3.1rem);
  letter-spacing: -0.04em;
  margin-bottom: 1rem;
}

.hero-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.2rem 0.9rem;
  border-radius: 999px;
  font-size: 0.8rem;
  color: var(--color-pill-text);
  background: var(--color-hero-pill-bg);
  margin-bottom: 1rem;
}

.hero-pill-muted {
  background: var(--color-hero-pill-muted-bg);
  color: var(--color-text);
}

.hero-sub {
  font-size: 1rem;
  color: var(--color-muted);
  max-width: 30rem;
  margin-bottom: 1.5rem;
}

.waitlist-form {
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem;
}

.waitlist-form input[type="email"] {
  flex: 1;
  min-width: 13rem;
  padding: 0.75rem 0.9rem;
  border-radius: 999px;
  border: 1px solid var(--color-border-light);
  font-size: 0.9rem;
  outline: none;
  background: var(--color-card);
  color: var(--color-text);
}

.waitlist-form input[type="email"]:focus {
  border-color: #0b63f6;
  box-shadow: 0 0 0 1px rgba(11, 99, 246, 0.4);
}

.waitlist-form button {
  padding: 0.78rem 1.4rem;
  border-radius: 999px;
  border: none;
  background: #0b63f6;
  color: #ffffff;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  box-shadow: 0 12px 30px rgba(37, 99, 235, 0.4);
}

.waitlist-form button:hover {
  filter: brightness(1.05);
}

.hero-footnote {
  margin-top: 0.6rem;
  font-size: 0.78rem;
  color: var(--color-extra-muted);
}

.testflight-link {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  margin-top: 1rem;
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--color-link);
  text-decoration: none;
  transition: color 0.2s ease;
}

.testflight-link::after {
  content: "↗";
  font-size: 0.9rem;
  display: inline-block;
  transform: translateY(-1px);
}

.testflight-link:hover {
  color: var(--color-link-hover);
}

.testflight-link-light {
  color: #f8fafc;
}

.testflight-link-light:hover {
  color: #cbd5f5;
}

.hero-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 2.5rem;
  margin-top: 2.2rem;
  font-size: 0.8rem;
}

.stat-number {
  display: block;
  font-size: 1.4rem;
  font-weight: 700;
}

.stat-label {
  color: var(--color-soft);
}

/* Phone frames using real screenshots */

.hero-visual {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 420px;
  padding: 1.5rem 0;
  isolation: isolate;
}

.hero-visual::before,
.hero-visual::after {
  content: "";
  position: absolute;
  inset: 0;
  margin: auto;
  border-radius: 999px;
  z-index: 0;
}

.hero-visual::before {
  width: 360px;
  height: 360px;
  background: radial-gradient(circle at 30% 20%, rgba(14, 165, 233, 0.35), transparent 65%),
    radial-gradient(circle at 70% 80%, rgba(59, 130, 246, 0.55), rgba(59, 130, 246, 0.05));
  filter: blur(0);
}

.hero-visual::after {
  width: 420px;
  height: 420px;
  background: rgba(15, 23, 42, 0.08);
  filter: blur(45px);
}

.phone-frame {
  width: 260px;
  border-radius: 36px;
  padding: 8px;
  background: linear-gradient(145deg, #020617, #111827);
  box-shadow: 0 25px 70px rgba(15, 23, 42, 0.7);
  overflow: hidden;
  position: relative;
  z-index: 1;
}

.phone-frame img {
  border-radius: 28px;
}

.phone-main {
  position: relative;
  z-index: 2;
  transform: translateX(24px) rotate(-2deg);
}

.phone-secondary {
  position: absolute;
  left: -10px;
  top: 70px;
  width: 220px;
  opacity: 0.95;
  transform: rotate(-12deg);
  box-shadow: 0 35px 60px rgba(2, 6, 23, 0.35);
}

/* Terms page */

.terms-hero {
  padding: 4rem 0 2.5rem;
  background: radial-gradient(circle at top, rgba(14, 165, 233, 0.1), transparent 55%);
}

.terms-hero-inner {
  max-width: 680px;
  text-align: center;
  margin: 0 auto;
}

.terms-hero-inner h1 {
  font-size: clamp(2.2rem, 4vw, 3rem);
  margin-bottom: 0.6rem;
}

.terms-hero-sub {
  color: var(--color-muted);
  margin-bottom: 0.8rem;
}

.terms-body {
  background: var(--color-card);
}

.terms-intro {
  max-width: 720px;
  margin-bottom: 2rem;
}

.terms-intro h2 {
  font-size: 1.7rem;
  margin-bottom: 0.6rem;
}

.terms-intro p {
  color: var(--color-muted);
  font-size: 1rem;
}

.terms-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.6rem;
  grid-auto-rows: 1fr;
}

.terms-card {
  padding: 1.35rem 1.3rem;
  border-radius: 20px;
  border: 1px solid var(--color-border);
  background: var(--color-card-alt);
  box-shadow: 0 18px 40px rgba(15, 23, 42, 0.04);
  height: 100%;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.terms-card h3 {
  margin-top: 0;
  margin-bottom: 0.6rem;
  font-size: 1.05rem;
}

.terms-card p {
  margin: 0;
  color: var(--color-muted);
  font-size: 0.95rem;
  line-height: 1.6;
}

.terms-footer {
  margin-top: 2.5rem;
  text-align: center;
  font-size: 0.95rem;
  color: var(--color-muted);
}

.terms-footer-link {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  margin-top: 0.4rem;
  color: var(--color-link);
  font-weight: 600;
  text-decoration: none;
}

.terms-footer-link:hover {
  text-decoration: underline;
}

/* Sections */

.section {
  padding: 3.5rem 0;
}

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

.section-header {
  max-width: 32rem;
  margin-bottom: 2.4rem;
}

.section-header h2 {
  font-size: 1.7rem;
  margin-bottom: 0.4rem;
}

.section-header p {
  color: var(--color-muted);
  font-size: 0.98rem;
}

/* Steps */

.steps {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.6rem;
}

.step-card {
  padding: 1.4rem 1.3rem;
  border-radius: 18px;
  border: 1px solid var(--color-border);
  background: var(--color-card);
  box-shadow: 0 18px 40px rgba(15, 23, 42, 0.06);
}

.step-number {
  width: 28px;
  height: 28px;
  border-radius: 999px;
  background: #eef2ff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.8rem;
  font-weight: 600;
  color: #4f46e5;
  margin-bottom: 0.7rem;
}

.step-card h3 {
  font-size: 1rem;
  margin-bottom: 0.45rem;
}

.step-card p {
  font-size: 0.9rem;
  color: var(--color-soft);
}

/* Split layout */

.layout-split {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr);
  gap: 2.8rem;
  align-items: center;
}

.section-copy h2 {
  font-size: 1.6rem;
  margin-bottom: 0.6rem;
}

.section-copy p {
  font-size: 0.96rem;
  color: var(--color-muted);
  margin-bottom: 1.1rem;
}

.feature-list {
  list-style: none;
  padding-left: 0;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  font-size: 0.9rem;
  color: var(--color-text);
}

.feature-list li::before {
  content: "•";
  color: var(--color-link);
  font-weight: 700;
  margin-right: 0.4rem;
}

/* Section visuals */

.section-visual {
  position: relative;
}

/* Trust */

.trust-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
}

.trust-card {
  padding: 1rem 0.9rem;
  border-radius: 16px;
  background: var(--color-card);
  border: 1px solid var(--color-border);
  font-size: 0.86rem;
  color: var(--color-muted);
}

.trust-label {
  display: inline-block;
  font-size: 0.72rem;
  padding: 0.16rem 0.55rem;
  border-radius: 999px;
  background: var(--color-pill-tag-bg);
  color: var(--color-pill-tag-text);
  font-weight: 600;
  margin-bottom: 0.4rem;
}

/* FAQ */

.faq-grid {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.faq-item {
  border-radius: 20px;
  border: 1px solid var(--color-border);
  background: var(--color-card);
  padding: 1rem 1.2rem;
  font-size: 0.95rem;
  transition: border-color 0.25s ease, box-shadow 0.25s ease, transform 0.25s ease;
}

.faq-item[open] {
  border-color: rgba(59, 130, 246, 0.4);
  box-shadow: 0 18px 40px rgba(15, 23, 42, 0.08);
  transform: translateY(-2px);
}

.faq-item summary {
  cursor: pointer;
  font-weight: 600;
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  font-size: 1rem;
}

.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-item summary::after {
  content: "+";
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 1px solid var(--color-border);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  color: var(--color-link);
  transition: transform 0.3s ease, border-color 0.3s ease, background 0.3s ease;
}

.faq-item[open] summary::after {
  transform: rotate(45deg);
  border-color: transparent;
  background: rgba(11, 99, 246, 0.1);
}

.faq-content {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows 0.35s ease, opacity 0.35s ease;
  opacity: 0;
}

.faq-content > * {
  overflow: hidden;
  margin: 0;
  color: var(--color-soft);
  line-height: 1.6;
}

.faq-item[open] .faq-content {
  grid-template-rows: 1fr;
  opacity: 1;
  margin-top: 0.6rem;
}

/* Final CTA */

.final-cta {
  background: radial-gradient(circle at top left, #0b63f6, #1d4ed8);
  color: #ffffff;
}

.final-cta-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.8rem;
}

.final-cta h2 {
  font-size: 1.7rem;
  margin-bottom: 0.4rem;
}

.final-cta p {
  font-size: 0.96rem;
  opacity: 0.94;
}

.final-cta .waitlist-form-inline input[type="email"] {
  background: rgba(15, 23, 42, 0.06);
  border-color: transparent;
  color: #ffffff;
}

.final-cta .waitlist-form-inline input::placeholder {
  color: rgba(248, 250, 252, 0.7);
}

.final-cta .waitlist-form-inline button {
  background: #ffffff;
  color: #0b63f6;
  box-shadow: none;
}

.final-cta .testflight-link {
  align-self: flex-start;
  margin-top: 0.8rem;
}

/* Footer */

.footer {
  border-top: 1px solid var(--color-footer-border);
  padding: 1rem 0;
  font-size: 0.8rem;
  color: var(--color-soft);
}

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

.footer-links {
  display: flex;
  gap: 0.8rem;
}

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

.footer a:hover {
  color: #0b63f6;
}

/* Waitlist modal */

body.modal-open {
  overflow: hidden;
}

.waitlist-modal {
  position: fixed;
  inset: 0;
  z-index: 60;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
}

.waitlist-modal.is-visible {
  opacity: 1;
  pointer-events: auto;
}

.waitlist-modal__backdrop {
  position: absolute;
  inset: 0;
  background: var(--color-modal-backdrop);
  backdrop-filter: blur(6px);
}

.waitlist-modal__panel {
  position: relative;
  z-index: 1;
  width: min(420px, 100%);
  border-radius: 26px;
  padding: 2.2rem 2.4rem 2.4rem;
  background: var(--color-modal-panel);
  box-shadow: 0 35px 80px rgba(15, 23, 42, 0.25);
  text-align: center;
}

.waitlist-modal__close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: none;
  background: var(--color-modal-close-bg);
  color: var(--color-text);
  font-size: 1.3rem;
  line-height: 1;
  cursor: pointer;
}

.waitlist-modal__icon {
  width: 70px;
  margin: 0 auto 1.2rem;
}

.waitlist-modal__icon svg {
  display: block;
  width: 100%;
  height: auto;
}

.waitlist-modal__eyebrow {
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--color-link);
  font-weight: 600;
  margin-bottom: 0.6rem;
}

.waitlist-modal__panel h3 {
  font-size: 1.6rem;
  margin: 0 0 0.9rem;
}

.waitlist-modal__message {
  font-size: 0.95rem;
  color: var(--color-muted);
  margin-bottom: 1.7rem;
}

.waitlist-modal__message span {
  font-weight: 600;
  color: var(--color-text);
}

.waitlist-modal__action {
  padding: 0.85rem 1.8rem;
  border-radius: 999px;
  border: none;
  background: linear-gradient(120deg, #0b63f6, #2563eb);
  color: #ffffff;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  box-shadow: 0 18px 35px rgba(37, 99, 235, 0.35);
}

.waitlist-modal__action:hover {
  filter: brightness(1.05);
}

.waitlist-modal__action:focus,
.waitlist-modal__close:focus {
  outline: 2px solid rgba(11, 99, 246, 0.4);
  outline-offset: 2px;
}

@media (max-width: 520px) {
  .waitlist-modal__panel {
    padding: 2rem 1.6rem 1.9rem;
  }
}

@media (prefers-color-scheme: dark) {
  :root {
    --color-bg: #020617;
    --color-text: #f8fafc;
    --color-muted: #cbd5f5;
    --color-soft: #94a3b8;
    --color-extra-muted: #7c8fc2;
    --color-border: rgba(148, 163, 184, 0.35);
    --color-border-light: rgba(148, 163, 184, 0.4);
    --color-section-alt: #0f172a;
    --color-card: #0f172a;
    --color-card-alt: #101c32;
    --color-nav-bg: rgba(2, 6, 23, 0.9);
    --color-nav-border: rgba(15, 23, 42, 0.8);
    --color-nav-sheet: rgba(2, 6, 23, 0.95);
    --color-footer-border: rgba(148, 163, 184, 0.35);
    --color-hero-pill-bg: rgba(37, 99, 235, 0.25);
    --color-hero-pill-muted-bg: rgba(59, 130, 246, 0.18);
    --color-pill-text: #e0edff;
    --color-link: #8cb7ff;
    --color-link-hover: #a8c9ff;
    --color-pill-tag-bg: rgba(79, 70, 229, 0.25);
    --color-pill-tag-text: #c7d2fe;
    --color-modal-panel: #0b1220;
    --color-modal-close-bg: rgba(59, 72, 99, 0.5);
    --color-modal-backdrop: rgba(2, 6, 23, 0.7);
  }

  body {
    color: var(--color-text);
    background: var(--color-bg);
  }

  .logo-mark {
    box-shadow: 0 10px 25px rgba(15, 23, 42, 0.65);
  }

  .hero {
    background: radial-gradient(circle at top, rgba(14, 165, 233, 0.08), transparent 55%);
  }

  .steps .step-card,
  .trust-card,
  .faq-item,
  .terms-card {
    box-shadow: 0 18px 30px rgba(0, 0, 0, 0.35);
  }

  .footer {
    background: #050b16;
  }

  .waitlist-form input[type="email"] {
    background: rgba(15, 23, 42, 0.6);
  }

  .waitlist-modal__panel {
    box-shadow: 0 40px 80px rgba(0, 0, 0, 0.55);
  }
}

/* Responsive */

@media (max-width: 1024px) {
  .terms-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  .terms-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (max-width: 880px) {
  .hero-inner,
  .layout-split {
    grid-template-columns: minmax(0, 1fr);
  }

  .hero-inner {
    gap: 2.5rem;
  }

  .hero-visual {
    margin-top: 0.5rem;
    min-height: auto;
    padding: 0;
  }

  .phone-secondary {
    display: none;
  }

  .phone-main {
    transform: none;
  }

  .steps {
    grid-template-columns: minmax(0, 1fr);
  }

  .final-cta-inner {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (max-width: 720px) {
  .nav-inner {
    padding-right: 0;
  }

  .nav-links {
    position: absolute;
    top: 100%;
    right: 0;
    left: 0;
    padding: 0.75rem 1.25rem 1rem;
    background: var(--color-nav-sheet);
    border-bottom: 1px solid var(--color-border);
    flex-direction: column;
    align-items: flex-start;
    gap: 0.8rem;
    display: none;
  }

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

  .nav-toggle {
    display: flex;
  }

  .hero {
    padding-top: 3rem;
  }
}
