/* Wando — the app's design system, ported.
 *
 * Every token below is lifted from Wando/Design/Theme.swift and Typography.swift rather
 * than eyeballed, so the site and the app cannot drift into looking like cousins. One
 * branded red and nothing else loud; every other surface stays neutral.
 */

:root {
  --accent: #e63946;
  --accent-pressed: #c92e3b;

  --background: #ffffff;
  --surface: #f7f7f8;
  --surface-sunken: #f0f0f2;

  --ink: #14161a;
  --ink-secondary: #5b6069;
  --ink-tertiary: #8e939c;

  --hairline: #e4e5e9;
  --on-accent: #ffffff;

  --card-radius: 16px;
  --control-radius: 14px;
  --gutter: 24px;

  /* The app is one column on a phone. On a wide screen the column stops growing rather
     than stretching into a 1300px line of text — same rule as Design/Adaptive.swift. */
  --measure: 760px;
  --measure-wide: 1080px;
}

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

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--background);
  color: var(--ink);
  font-family: "Montserrat", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  /* The app runs a full weight heavier than a typical iOS app; Montserrat is generous, so
     medium is the floor for body copy. */
  font-weight: 500;
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

.wrap {
  width: 100%;
  max-width: var(--measure);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.wrap--wide {
  max-width: var(--measure-wide);
}

/* ---------- type ---------- */

h1,
h2,
h3 {
  margin: 0;
  letter-spacing: -0.02em;
  line-height: 1.12;
}

h1 {
  font-weight: 800;
  font-size: clamp(40px, 7vw, 68px);
}

h2 {
  font-weight: 800;
  font-size: clamp(28px, 4vw, 38px);
}

h3 {
  font-weight: 700;
  font-size: 20px;
  line-height: 1.3;
}

p {
  margin: 0 0 1.1em;
}

a {
  color: var(--accent);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

.kicker {
  font-weight: 700;
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-tertiary);
  margin: 0 0 18px;
}

.lede {
  font-size: clamp(18px, 2.2vw, 22px);
  color: var(--ink-secondary);
  max-width: 34em;
}

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

/* ---------- header ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: rgba(255, 255, 255, 0.86);
  backdrop-filter: saturate(180%) blur(14px);
}

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

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  font-size: 19px;
  color: var(--ink);
  letter-spacing: -0.02em;
}

.logo:hover {
  text-decoration: none;
}

.logo-mark {
  width: 26px;
  height: 26px;
}

.site-header nav {
  display: flex;
  gap: 22px;
  font-size: 14px;
  font-weight: 600;
}

.site-header nav a {
  color: var(--ink-secondary);
}

.site-header nav a:hover {
  color: var(--ink);
  text-decoration: none;
}

/* ---------- mobile nav drawer ---------- */

/* The header runs out of room somewhere under 400px: the logo plus four links needs more
   than the gutter leaves, and `space-between` has nothing to give, so the wordmark ended up
   touching the first link. Below the breakpoint the nav becomes a drawer behind a
   hamburger, built by nav.js.
   
   The fallback matters: with no JavaScript there is no toggle, so the nav stays a wrapped
   row and every link is still reachable. That is why the drawer styles hang off
   `body.nav-open` rather than hiding the nav outright. */

.nav-toggle {
  display: none;
  position: relative;
  z-index: 40;
  width: 44px;
  height: 44px;
  margin-right: -10px;
  padding: 0;
  border: 0;
  background: none;
  cursor: pointer;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
}

.nav-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  border-radius: 2px;
  background: var(--ink);
  transition: transform 0.24s ease, opacity 0.18s ease;
}

body.nav-open .nav-toggle span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

body.nav-open .nav-toggle span:nth-child(2) {
  opacity: 0;
}

body.nav-open .nav-toggle span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

.nav-backdrop {
  position: fixed;
  inset: 0;
  z-index: 20;
  background: rgba(20, 22, 26, 0.34);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.28s ease;
}

body.nav-open .nav-backdrop {
  opacity: 1;
  pointer-events: auto;
}

@media (max-width: 640px) {
  .site-header .wrap {
    height: 58px;
  }

  .logo {
    font-size: 17px;
  }

  .logo-mark {
    width: 22px;
    height: 22px;
  }

  /* Only becomes a drawer once nav.js has added the toggle to open it. */
  .site-header:has(.nav-toggle) nav {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    z-index: 30;
    width: min(78vw, 300px);
    flex-direction: column;
    align-items: stretch;
    gap: 2px;
    padding: 78px 24px 32px;
    background: var(--background);
    box-shadow: -18px 0 46px rgba(20, 22, 26, 0.13);
    transform: translateX(100%);
    transition: transform 0.28s cubic-bezier(0.32, 0.72, 0, 1);
    overflow-y: auto;
  }

  body.nav-open .site-header nav {
    transform: translateX(0);
  }

  .site-header:has(.nav-toggle) nav a {
    font-size: 17px;
    font-weight: 600;
    color: var(--ink);
    padding: 13px 0;
    border-bottom: 1px solid var(--hairline);
  }

  .site-header:has(.nav-toggle) nav a:last-child {
    border-bottom: 0;
  }

  .nav-toggle {
    display: flex;
  }

  /* No JavaScript, no toggle: fall back to a wrapped row so nothing is unreachable. */
  .site-header:not(:has(.nav-toggle)) .wrap {
    height: auto;
    min-height: 56px;
    flex-wrap: wrap;
    justify-content: center;
    gap: 4px 18px;
    padding-top: 10px;
    padding-bottom: 10px;
  }

  .site-header:not(:has(.nav-toggle)) nav {
    gap: 16px;
    font-size: 13px;
  }
}

/* ---------- hero ---------- */

.hero {
  text-align: center;
  padding: clamp(56px, 9vw, 104px) 0 clamp(48px, 7vw, 88px);
}

.hero canvas {
  width: clamp(150px, 26vw, 210px);
  height: clamp(150px, 26vw, 210px);
  display: block;
  margin: 0 auto 30px;
}

.hero .lede {
  margin: 20px auto 0;
}

.pills {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  margin: 30px 0 0;
  padding: 0;
  list-style: none;
}

.pills li {
  background: var(--surface);
  border-radius: 999px;
  padding: 9px 17px;
  font-size: 13px;
  font-weight: 600;
  color: var(--ink-secondary);
}

/* ---------- call to action ---------- */

/* Official store badges. Apple and Google both require their supplied artwork used as
   issued — no recolouring, no redrawing, no altered proportions — so the only thing this
   sets is the height. Matching heights is what keeps neither store looking favoured. */
.badge-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-content: center;
  align-items: center;
  margin-top: 34px;
}

/* No fixed box. Equalising the link widths padded 24px of air onto the Apple side, which
   stacked with each badge's own clear space — 1.5px inside Apple's, 15px inside Google's —
   and pushed the pair about 54px apart. Natural widths and a 6px gap bring the pills to
   roughly 22px, which is what the eye reads as a pair. */
.badge-row a {
  display: inline-flex;
  align-items: center;
  transition: transform 0.12s ease, opacity 0.12s ease;
}

.badge-row a:hover {
  opacity: 0.85;
  text-decoration: none;
}

.badge-row a:active {
  transform: scale(0.97);
}

/* Sized by the black pills, which is what the eye compares — not by the files.
 *
 * The assets carry very different clear space: Apple's pill fills 95.2% of its image
 * height, Google's only 64%, because Google's ships with its full mandated padding baked
 * in. So the image heights differ on purpose and the pills underneath come out level —
 * both 53px tall.
 *
 * Their widths still differ, 163 against 184, because the pills are 3.08:1 and 3.48:1 and
 * neither company allows their artwork stretched. Each link is given the same fixed width
 * so the pair occupies identical space and the row stays square; the narrower Apple badge
 * simply sits centred in its box, which is the clear space Apple asks for anyway. */
.badge {
  display: block;
  width: auto;
}

.badge--apple {
  height: 56px;
}

.badge--google {
  height: 83px;
}




.cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 52px;
  padding: 0 32px;
  margin-top: 34px;
  border: 0;
  border-radius: var(--control-radius);
  background: var(--accent);
  color: var(--on-accent);
  font-family: inherit;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  transition: transform 0.12s ease, background 0.12s ease;
}

.cta:hover {
  background: var(--accent-pressed);
  text-decoration: none;
}

.cta:active {
  transform: scale(0.97);
}

.cta[aria-disabled="true"] {
  background: var(--surface);
  color: var(--ink-secondary);
  cursor: default;
}

.cta[aria-disabled="true"]:hover {
  background: var(--surface);
}

.cta-note {
  margin: 14px 0 0;
  font-size: 13px;
  font-weight: 600;
  color: var(--ink-tertiary);
}

/* ---------- sections ---------- */

section {
  padding: clamp(52px, 8vw, 88px) 0;
}

section + section {
  border-top: 1px solid var(--hairline);
}

.section-head {
  margin-bottom: 40px;
}

.section-head p {
  margin-top: 14px;
}

/* ---------- cards ---------- */

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

.card {
  background: var(--surface);
  border-radius: var(--card-radius);
  padding: 26px;
}

.card h3 {
  margin-bottom: 8px;
}

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

.step-number {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  margin-bottom: 16px;
  border-radius: 999px;
  background: var(--accent);
  color: var(--on-accent);
  font-size: 14px;
  font-weight: 800;
}

/* The countdown, which is the one thing besides the accent allowed to raise its voice. */
.countdown {
  font-weight: 800;
  font-size: clamp(56px, 10vw, 92px);
  line-height: 1;
  color: var(--accent);
  letter-spacing: -0.04em;
}

.countdown-row {
  display: flex;
  align-items: baseline;
  gap: 14px;
  flex-wrap: wrap;
}

.countdown-row span {
  font-weight: 700;
  font-size: clamp(20px, 3vw, 28px);
  color: var(--ink-secondary);
}

/* ---------- long-form legal pages ---------- */

.doc {
  padding: clamp(40px, 6vw, 72px) 0 96px;
}

.doc h1 {
  font-size: clamp(32px, 5vw, 46px);
  margin-bottom: 8px;
}

.doc h2 {
  font-size: 22px;
  margin: 44px 0 14px;
  padding-top: 28px;
  border-top: 1px solid var(--hairline);
}

.doc h2:first-of-type {
  border-top: 0;
  padding-top: 0;
}

.doc h3 {
  font-size: 17px;
  margin: 26px 0 8px;
}

.doc p,
.doc li {
  color: var(--ink-secondary);
  font-size: 16px;
}

.doc strong {
  color: var(--ink);
  font-weight: 700;
}

.doc ul {
  padding-left: 20px;
}

.doc li {
  margin-bottom: 8px;
}

.doc hr {
  display: none; /* section rules are drawn by the h2 border instead */
}

.doc table {
  width: 100%;
  border-collapse: collapse;
  margin: 20px 0 26px;
  font-size: 15px;
}

.doc th,
.doc td {
  text-align: left;
  vertical-align: top;
  padding: 12px 14px;
  border-bottom: 1px solid var(--hairline);
  color: var(--ink-secondary);
}

.doc th {
  font-weight: 700;
  font-size: 12px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-tertiary);
}

.doc-meta {
  font-size: 14px;
  font-weight: 600;
  color: var(--ink-tertiary);
  margin-bottom: 36px;
}

/* ---------- footer ---------- */

.site-footer {
  padding: 48px 0;
  font-size: 14px;
  color: var(--ink-tertiary);
}

.site-footer .wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  align-items: center;
  justify-content: space-between;
}

.site-footer nav {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
}

.site-footer a {
  color: var(--ink-secondary);
  font-weight: 600;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  * {
    animation-duration: 0.001ms !important;
    transition-duration: 0.001ms !important;
  }
}
