* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --color-bg: #263352;
  --color-bg-bottom: #1a2540;
  --color-text: #f5f5f5;
  --color-text-muted: #a8b4c9;
  --color-track-off: rgba(255, 255, 255, 0.18);
  --font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

html {
  scroll-behavior: smooth;
  background: linear-gradient(180deg, var(--color-bg) 0%, var(--color-bg-bottom) 100%);
}

body {
  font-family: var(--font-family);
  color: var(--color-text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* Header */
.site-header {
  width: 100%;
}

.site-header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.5rem 1.5rem 1rem;
  max-width: 720px;
  margin: 0 auto;
}

.site-brand {
  display: flex;
  align-items: center;
  gap: 0.875rem;
  color: inherit;
  text-decoration: none;
}

/* Hidden on mobile (smart app banner + footer button cover it) */
.header-cta {
  display: none;
}

.site-icon {
  width: 48px;
  height: 48px;
  border-radius: 11px;
  flex-shrink: 0;
}

.site-header h1 {
  font-size: 1.5rem;
  font-weight: 600;
  letter-spacing: -0.01em;
}

/* Fidget area */
.fidget {
  padding: 1rem 1.25rem 2rem;
  max-width: 720px;
  margin: 0 auto;
  display: flex;
  justify-content: center;
}

/* Phone-shaped frame */
.phone {
  position: relative;
  width: 100%;
  max-width: 280px;
  aspect-ratio: 9 / 19;
  background: linear-gradient(145deg, #2a2a3a, #0f0f18);
  border-radius: 44px;
  padding: 10px;
  box-shadow:
    0 30px 60px -15px rgba(0, 0, 0, 0.55),
    0 0 0 1px rgba(255, 255, 255, 0.06) inset,
    0 0 0 2px rgba(0, 0, 0, 0.4);
}

.phone-screen {
  position: relative;
  width: 100%;
  height: 100%;
  background: linear-gradient(180deg, #263352 0%, #1a2540 100%);
  border-radius: 34px;
  padding: 3.25rem 1rem 1.5rem;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Dynamic island */
.phone-screen::before {
  content: '';
  position: absolute;
  top: 0.75rem;
  left: 50%;
  transform: translateX(-50%);
  width: 78px;
  height: 22px;
  background: #000;
  border-radius: 11px;
  z-index: 1;
}

.toggle-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem 0.5rem;
  justify-items: center;
  width: 100%;
}

/* iOS-style toggle switch
   Native size is 51x31, we scale up generously for finger taps */
.toggle {
  --w: 80px;
  --h: 48px;
  --pad: 3px;
  --thumb: calc(var(--h) - var(--pad) * 2);
  position: relative;
  width: var(--w);
  height: var(--h);
  border-radius: calc(var(--h) / 2);
  background: var(--color-track-off);
  cursor: pointer;
  border: none;
  padding: 0;
  transition: background-color 0.25s ease;
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
  /* Bigger invisible hit area */
  outline-offset: 4px;
}

.toggle::before {
  content: '';
  position: absolute;
  top: var(--pad);
  left: var(--pad);
  width: var(--thumb);
  height: var(--thumb);
  border-radius: 50%;
  background: #ffffff;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.15), 0 1px 2px rgba(0, 0, 0, 0.1);
  transition: transform 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.toggle[aria-pressed="true"] {
  background: var(--tint, #4cd964);
}

.toggle[aria-pressed="true"]::before {
  transform: translateX(calc(var(--w) - var(--h)));
}

.toggle:focus-visible {
  outline: 2px solid #ffffff;
  outline-offset: 4px;
}

/* Copy */
.copy {
  padding: 2rem 1.5rem 1.5rem;
  max-width: 560px;
  margin: 0 auto;
}

/* Hero block */
.hero-block {
  margin-bottom: 3rem;
}

.eyebrow {
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #ff5fb3;
  margin-bottom: 1.25rem;
}

.hero-headline {
  font-size: clamp(2.25rem, 7vw, 4rem);
  font-weight: 700;
  line-height: 1.05;
  letter-spacing: -0.03em;
  margin-bottom: 1.75rem;
}

.hero-headline em {
  color: #ff5fb3;
  font-style: italic;
  font-weight: 700;
}

.hero-lede {
  font-size: 1.125rem;
  color: var(--color-text-muted);
  margin-bottom: 2.25rem;
  max-width: 32rem;
}

.hero-cta {
  display: inline-block;
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.hero-cta:hover {
  opacity: 0.85;
  transform: scale(1.02);
}

.hero-cta:active {
  transform: scale(0.98);
}

.hero-cta img {
  height: 56px;
  width: auto;
  display: block;
}

/* Second CTA — mobile only */
.mobile-cta {
  padding: 1rem 1.5rem 3rem;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.75rem;
  max-width: 480px;
  margin: 0 auto;
}

.mobile-cta-headline {
  font-size: 1.875rem;
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.02em;
}

.mobile-cta-headline em {
  color: #ff5fb3;
  font-style: italic;
  font-weight: 700;
}

.mobile-cta-link {
  display: inline-block;
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.mobile-cta-link:hover {
  opacity: 0.85;
  transform: scale(1.02);
}

.mobile-cta-link img {
  height: 54px;
  width: auto;
  display: block;
}

/* Footer */
footer {
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  max-width: 1200px;
  margin: 0 auto;
  margin-top: auto;
  width: 100%;
}

.footer-links {
  display: flex;
  align-items: center;
  gap: 1rem;
  font-size: 0.875rem;
}

.footer-links a {
  color: var(--color-text-muted);
  text-decoration: none;
  transition: color 0.2s ease;
}

.footer-links a:hover {
  color: var(--color-text);
}

.footer-links .separator {
  color: var(--color-text-muted);
  opacity: 0.5;
}

.footer-tagline {
  color: var(--color-text-muted);
  font-size: 0.875rem;
  opacity: 0.7;
}

.copyright {
  color: var(--color-text-muted);
  font-size: 0.8125rem;
  opacity: 0.5;
}

/* Desktop split: copy on the left, phone with toggles on the right */
@media (min-width: 900px) {
  .site-header-inner {
    max-width: 1200px;
    padding: 1rem 2rem;
  }

  .site-header h1 {
    font-size: 1.5rem;
  }

  .site-icon {
    width: 48px;
    height: 48px;
    border-radius: 11px;
  }

  .layout {
    flex: 1;
    min-height: 0;
    display: grid;
    grid-template-columns: 3fr 2fr;
    grid-template-areas: "copy fidget";
    column-gap: 3rem;
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
    align-items: center;
    width: 100%;
  }

  .header-cta {
    display: inline-flex;
    align-items: center;
    background: #ff5fb3;
    color: #ffffff;
    padding: 0.875rem 1.75rem;
    border-radius: 999px;
    text-decoration: none;
    font-weight: 600;
    font-size: 1rem;
    letter-spacing: -0.01em;
    transition: background-color 0.2s ease, transform 0.2s ease;
  }

  .header-cta:hover {
    background: #ff4aa6;
    transform: scale(1.03);
  }

  .header-cta:active {
    transform: scale(0.98);
  }

  .copy {
    grid-area: copy;
    padding: 0;
    margin: 0;
    max-width: none;
  }

  .hero-lede {
    font-size: 1.25rem;
  }

  .fidget {
    grid-area: fidget;
    padding: 0;
    margin: 0;
    max-width: none;
    justify-content: flex-end;
  }

  .phone {
    /* Smaller of fixed max or whatever fits in the viewport height */
    max-width: min(320px, calc((100vh - 220px) * 9 / 19));
  }

  footer {
    flex-direction: row;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 1rem 1.5rem;
  }

  .mobile-cta {
    display: none;
  }
}

/* Respect reduced motion */
@media (prefers-reduced-motion: reduce) {
  .toggle,
  .toggle::before,
  .hero-cta,
  .header-cta {
    transition: none;
  }
}
