:root {
  --bg: #eef3fa;
  --bg-deep: #d9e6f7;
  --surface: #ffffff;
  --ink: #0b1220;
  --muted: #5b667a;
  --line: #d5e0ef;
  --brand: #1e7bff;
  --brand-dark: #0b5bd6;
  --accent: #00bfa5;
  --max: 720px;
  --wide: 1080px;
  --font-display: "Outfit", "Segoe UI", sans-serif;
  --font-body: "Sora", "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.65;
}

body.page-landing {
  background:
    radial-gradient(900px 480px at 85% 8%, rgba(0, 191, 165, 0.16), transparent 55%),
    radial-gradient(1100px 620px at -5% -5%, rgba(30, 123, 255, 0.22), transparent 58%),
    linear-gradient(180deg, #e8f0fb 0%, var(--bg) 42%, #f7f9fc 100%);
}

a { color: var(--brand-dark); }
a:hover { color: var(--brand); }

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  border-bottom: 1px solid transparent;
}

.site-header--glass {
  backdrop-filter: blur(14px);
  background: rgba(238, 243, 250, 0.78);
  border-bottom-color: rgba(213, 224, 239, 0.7);
}

.site-header__inner,
.site-footer__inner,
.wrap,
.section__inner {
  width: min(100% - 2rem, var(--max));
  margin-inline: auto;
}

.site-header__inner--wide,
.site-footer__inner--wide,
.section__inner--wide {
  width: min(100% - 2rem, var(--wide));
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.9rem 0;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  text-decoration: none;
  color: var(--ink);
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: -0.02em;
}

.brand__mark {
  width: 1.85rem;
  height: 1.85rem;
  border-radius: 0.45rem;
  object-fit: cover;
  display: block;
  box-shadow: 0 4px 12px rgba(11, 18, 32, 0.16);
}

.nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 0.85rem 1.1rem;
  font-size: 0.92rem;
}

.nav a {
  text-decoration: none;
  color: var(--muted);
  font-weight: 600;
}

.nav a:hover,
.nav a[aria-current="page"] {
  color: var(--brand-dark);
}

/* —— Landing hero —— */
.hero-landing {
  position: relative;
  min-height: min(100svh, 920px);
  display: grid;
  align-items: center;
  padding: 1.5rem 0 2.5rem;
  overflow: clip;
}

.hero-landing__glow {
  position: absolute;
  inset: 8% 5% auto;
  height: 55%;
  background:
    radial-gradient(circle at 30% 40%, rgba(30, 123, 255, 0.18), transparent 55%),
    radial-gradient(circle at 70% 30%, rgba(0, 191, 165, 0.14), transparent 50%);
  filter: blur(8px);
  pointer-events: none;
}

.hero-landing__grid {
  position: relative;
  width: min(100% - 2rem, var(--wide));
  margin-inline: auto;
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 2.5rem 3rem;
  align-items: center;
}

.brand-lockup {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  margin: 0 0 1.1rem;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(2.35rem, 5.2vw, 4.1rem);
  letter-spacing: -0.045em;
  line-height: 1.02;
  color: var(--ink);
}

.brand-lockup img {
  width: clamp(3rem, 5vw, 3.6rem);
  height: clamp(3rem, 5vw, 3.6rem);
  border-radius: 0.95rem;
  box-shadow: 0 14px 34px rgba(11, 91, 214, 0.28);
  animation: float-y 4.8s ease-in-out infinite;
}

.hero-landing__lede {
  margin: 0;
  max-width: 28rem;
  color: var(--muted);
  font-size: clamp(1.02rem, 1.6vw, 1.18rem);
  font-weight: 400;
  line-height: 1.55;
}

.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1.6rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  padding: 0.85rem 1.25rem;
  border-radius: 12px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.98rem;
  text-decoration: none;
  transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}

.btn--primary {
  background: linear-gradient(160deg, var(--brand) 0%, var(--brand-dark) 100%);
  color: #fff;
  box-shadow: 0 12px 28px rgba(30, 123, 255, 0.32);
}

.btn--primary:hover {
  color: #fff;
  transform: translateY(-1px);
  box-shadow: 0 16px 34px rgba(30, 123, 255, 0.38);
}

.btn--ghost {
  background: rgba(255, 255, 255, 0.7);
  color: var(--ink);
  border: 1px solid var(--line);
}

.btn--ghost:hover {
  color: var(--ink);
  background: #fff;
}

.btn--store {
  margin-top: 0.35rem;
  pointer-events: none;
  opacity: 0.92;
}

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

.phone-stack {
  position: relative;
  width: min(100%, 340px);
  height: 520px;
  margin-inline: auto;
}

.phone-frame {
  border-radius: 2rem;
  padding: 0.45rem;
  background: linear-gradient(160deg, #1a2338, #0b1220);
  box-shadow:
    0 30px 60px rgba(11, 18, 32, 0.28),
    0 0 0 1px rgba(255, 255, 255, 0.08) inset;
}

.phone-frame img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 1.6rem;
}

.phone-frame--front {
  position: absolute;
  right: 0;
  bottom: 0;
  width: 78%;
  z-index: 2;
  animation: float-y 5.6s ease-in-out infinite;
}

.phone-frame--back {
  position: absolute;
  left: 0;
  top: 1.5rem;
  width: 68%;
  z-index: 1;
  opacity: 0.92;
  transform: rotate(-8deg);
  filter: saturate(0.95);
  animation: float-y 6.2s ease-in-out infinite;
  animation-delay: 0.35s;
}

.phone-frame--solo {
  width: min(100%, 260px);
  margin-inline: auto;
  animation: float-y 5.8s ease-in-out infinite;
}

.phone-frame--rail {
  width: 100%;
  padding: 0.35rem;
  border-radius: 1.5rem;
  box-shadow: 0 16px 36px rgba(11, 18, 32, 0.18);
}

.phone-frame--rail img {
  border-radius: 1.2rem;
}

.feature-row {
  width: min(100% - 2rem, var(--wide));
  margin: 0 auto 4rem;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2.5rem 3rem;
  align-items: center;
}

.feature-row--flip .feature-row__copy { order: 2; }
.feature-row--flip .phone-frame--solo { order: 1; }

.feature-row__copy .section__title {
  text-align: left;
}

.section--gallery {
  background: rgba(255, 255, 255, 0.45);
}

.screen-rail {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(150px, 170px);
  gap: 1.1rem;
  overflow-x: auto;
  padding: 0.5rem 0.25rem 1.25rem;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
}

.screen-rail__item {
  margin: 0;
  scroll-snap-align: start;
  text-align: center;
}

.screen-rail__item figcaption {
  margin-top: 0.65rem;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.92rem;
  color: var(--muted);
}

@keyframes float-y {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}

@keyframes float-y-tilt {
  0%, 100% { transform: rotate(-8deg) translateY(0); }
  50% { transform: rotate(-8deg) translateY(-10px); }
}

.phone-frame--back {
  animation-name: float-y-tilt;
}

/* —— Sections —— */
.section {
  padding: 4.5rem 0;
}

.section--features {
  background: linear-gradient(180deg, transparent, rgba(255, 255, 255, 0.55) 20%, rgba(255, 255, 255, 0.7));
}

.section--practice {
  background:
    linear-gradient(135deg, rgba(30, 123, 255, 0.08), rgba(0, 191, 165, 0.1)),
    #f3f7fc;
}

.section--download {
  padding-bottom: 5rem;
}

.section__title {
  margin: 0 0 0.65rem;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(1.55rem, 3vw, 2.15rem);
  letter-spacing: -0.03em;
  line-height: 1.15;
}

.section__lede {
  margin: 0 auto 2rem;
  max-width: 34rem;
  color: var(--muted);
  text-align: center;
}

.section__lede--left {
  margin-left: 0;
  text-align: left;
}

.section__inner--center {
  text-align: center;
}

.section__inner--split {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 2rem;
  align-items: center;
  width: min(100% - 2rem, var(--wide));
}

.feature-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 1.35rem 2rem;
  grid-template-columns: 1fr 1fr;
}

.feature-list__item {
  padding: 0;
  border: 0;
  background: none;
}

.feature-list__item strong {
  display: block;
  margin-bottom: 0.25rem;
  font-family: var(--font-display);
  font-size: 1.08rem;
  letter-spacing: -0.02em;
}

.feature-list__item span {
  color: var(--muted);
  font-size: 0.96rem;
}

.pillars {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.65rem;
}

.pillars li {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.15rem;
  letter-spacing: -0.02em;
  padding-left: 1rem;
  border-left: 3px solid var(--accent);
}

.download-logo {
  border-radius: 1.1rem;
  margin-bottom: 1rem;
  box-shadow: 0 14px 32px rgba(11, 91, 214, 0.25);
  animation: float-y 4.8s ease-in-out infinite;
}

.fineprint {
  margin: 1rem 0 0;
  color: var(--muted);
  font-size: 0.85rem;
}

/* —— Motion —— */
.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal--delay { transition-delay: 0.12s; }

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* —— Legal pages —— */
main.legal-main { padding: 2.5rem 0 3.5rem; }

.legal {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 1.5rem 1.35rem 1.8rem;
}

.legal .meta {
  color: var(--muted);
  font-size: 0.92rem;
  margin: 0 0 1.4rem;
}

.legal h1 {
  margin: 0 0 0.35rem;
  font-family: var(--font-display);
  font-size: clamp(1.6rem, 3.5vw, 2rem);
  letter-spacing: -0.03em;
}

.legal h2 {
  margin: 1.7rem 0 0.55rem;
  font-family: var(--font-display);
  font-size: 1.15rem;
  letter-spacing: -0.01em;
}

.legal p,
.legal li { color: #243044; }

.legal ul {
  padding-left: 1.2rem;
  margin: 0.4rem 0 0.8rem;
}

.legal li + li { margin-top: 0.35rem; }

.site-footer {
  border-top: 1px solid var(--line);
  padding: 1.25rem 0 2rem;
  color: var(--muted);
  font-size: 0.9rem;
  background: rgba(255, 255, 255, 0.35);
}

.site-footer__inner {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.25rem;
  justify-content: space-between;
}

.site-footer a {
  text-decoration: none;
  color: var(--muted);
  font-weight: 600;
}

.site-footer a:hover { color: var(--brand-dark); }

@media (max-width: 860px) {
  .hero-landing__grid,
  .section__inner--split,
  .feature-row {
    grid-template-columns: 1fr;
  }

  .feature-row--flip .feature-row__copy,
  .feature-row--flip .phone-frame--solo {
    order: initial;
  }

  .feature-row {
    margin-bottom: 3rem;
    text-align: center;
  }

  .feature-row__copy .section__title,
  .feature-row .section__lede--left {
    text-align: center;
  }

  .feature-row .section__lede--left {
    margin-inline: auto;
  }

  .hero-landing {
    min-height: auto;
    padding-top: 1.25rem;
  }

  .hero-landing__visual { order: -1; }

  .phone-stack {
    height: 420px;
    width: min(100%, 280px);
    margin-bottom: 0.75rem;
  }

  .phone-frame--solo {
    width: min(100%, 220px);
  }

  .brand-lockup {
    flex-wrap: wrap;
  }

  .nav a:nth-child(1),
  .nav a:nth-child(2) {
    display: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
  .brand-lockup img,
  .phone-frame,
  .phone-frame--front,
  .phone-frame--back,
  .phone-frame--solo,
  .download-logo {
    animation: none;
  }
}
