:root {
  --bg: #fbfbfd;
  --bg-alt: #f5f5f7;
  --card: #ffffff;
  --text: #1d1d1f;
  --text-secondary: #6e6e73;
  --link: #0066cc;
  --hairline: rgba(0, 0, 0, 0.1);
  --nav-bg: rgba(251, 251, 253, 0.72);
  --button-bg: #1d1d1f;
  --button-text: #ffffff;
  --shadow: 0 30px 60px -20px rgba(0, 0, 0, 0.25), 0 12px 24px -12px rgba(0, 0, 0, 0.15);
  --phone-frame: #1d1d1f;
  --gutter: max(22px, env(safe-area-inset-left));
  --content: 980px;
  --radius-card: 22px;
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Helvetica Neue", Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  color-scheme: light dark;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #000000;
    --bg-alt: #101012;
    --card: #1c1c1e;
    --text: #f5f5f7;
    --text-secondary: #a1a1a6;
    --link: #2997ff;
    --hairline: rgba(255, 255, 255, 0.14);
    --nav-bg: rgba(22, 22, 23, 0.72);
    --button-bg: #f5f5f7;
    --button-text: #1d1d1f;
    --shadow: 0 30px 60px -20px rgba(0, 0, 0, 0.9), 0 0 0 1px rgba(255, 255, 255, 0.08);
    --phone-frame: #3a3a3c;
  }
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: 64px; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-size: 17px;
  line-height: 1.47;
  letter-spacing: -0.022em;
}

img { display: block; max-width: 100%; height: auto; }
a { color: var(--link); text-decoration: none; }
a:hover { text-decoration: underline; }
:focus-visible { outline: 3px solid var(--link); outline-offset: 3px; border-radius: 6px; }

h1, h2, h3 {
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Display", "Helvetica Neue", Helvetica, Arial, sans-serif;
  margin: 0;
}

/* Frosted navigation bar */
.nav {
  position: sticky;
  top: 0;
  z-index: 10;
  background: var(--nav-bg);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 0.5px solid var(--hairline);
}
.nav-inner {
  max-width: var(--content);
  margin: 0 auto;
  padding: 0 var(--gutter);
  height: 52px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.nav-title {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--text);
  font-weight: 600;
  font-size: 19px;
  letter-spacing: -0.02em;
}
.nav-title:hover { text-decoration: none; }
.nav-links { display: flex; align-items: center; gap: 22px; font-size: 13px; }
.nav-links a { color: var(--text); opacity: 0.8; }
.nav-links a:hover { opacity: 1; text-decoration: none; }
.nav-links .nav-get {
  opacity: 1;
  background: var(--link);
  color: #fff;
  padding: 4px 12px;
  border-radius: 980px;
  font-weight: 500;
}

/* Hero */
.hero {
  text-align: center;
  padding: 72px var(--gutter) 0;
  max-width: 1200px;
  margin: 0 auto;
}
.hero-icon {
  width: 128px;
  margin: 0 auto 16px;
}
.hero h1 {
  font-size: clamp(44px, 8vw, 80px);
  line-height: 1.05;
  font-weight: 700;
  letter-spacing: -0.015em;
}
.hero-lede {
  font-size: clamp(21px, 3vw, 28px);
  line-height: 1.2;
  color: var(--text-secondary);
  margin: 10px 0 32px;
  letter-spacing: 0.004em;
}

.downloads {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 14px;
}
.store-button {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-width: 200px;
  padding: 11px 22px 11px 18px;
  border-radius: 980px;
  background: var(--button-bg);
  color: var(--button-text);
  border: 1px solid var(--button-bg);
  text-align: left;
  transition: transform 0.15s ease, opacity 0.15s ease;
}
.store-button:hover { text-decoration: none; opacity: 0.88; }
.store-button:active { transform: scale(0.97); }
.store-button svg {
  width: 26px;
  height: 26px;
  flex: none;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
  stroke-linecap: round;
}
.store-button span { font-size: 19px; font-weight: 600; line-height: 1.1; }
.store-button small { display: block; font-size: 11px; font-weight: 400; opacity: 0.8; letter-spacing: 0; }
.store-button.secondary { background: transparent; color: var(--text); border-color: var(--text); }

.requirements { margin: 16px 0 0; font-size: 14px; color: var(--text-secondary); }

/* Mac with an iPhone in front of its lower right corner */
.devices {
  position: relative;
  max-width: 1000px;
  margin: 64px auto 0;
  padding: 0 7% 6% 0;
}
.device-mac img {
  border-radius: clamp(8px, 1.4vw, 14px);
  box-shadow: var(--shadow);
}
.device-phone {
  position: absolute;
  right: 0;
  bottom: 0;
  width: 22%;
}
.device-phone img {
  border: clamp(4px, 0.9vw, 9px) solid var(--phone-frame);
  border-radius: clamp(20px, 4.4vw, 46px);
  box-shadow: var(--shadow);
}

/* Features */
.features {
  max-width: var(--content);
  margin: 0 auto;
  padding: 120px var(--gutter) 0;
}
.features h2, .support h2 {
  font-size: clamp(32px, 5vw, 48px);
  line-height: 1.08;
  font-weight: 700;
  text-align: center;
  margin-bottom: 48px;
}
.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(280px, 100%), 1fr));
  gap: 16px;
}
.feature {
  background: var(--bg-alt);
  border-radius: var(--radius-card);
  padding: 28px 28px 30px;
}
.feature h3 { font-size: 21px; font-weight: 600; margin-bottom: 8px; letter-spacing: 0.01em; }
.feature p { margin: 0; color: var(--text-secondary); }

.gallery {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(12px, 3vw, 40px);
  max-width: 820px;
  margin: 80px auto 0;
}
.gallery figure { margin: 0; text-align: center; }
.gallery img {
  border: clamp(3px, 0.7vw, 7px) solid var(--phone-frame);
  border-radius: clamp(16px, 3.4vw, 36px);
  box-shadow: var(--shadow);
}
.gallery figcaption { margin-top: 16px; font-size: 14px; color: var(--text-secondary); }

/* Support */
.support {
  max-width: var(--content);
  margin: 0 auto;
  padding: 120px var(--gutter) 96px;
}
.support-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 1fr));
  gap: 16px;
}
.support-card {
  display: block;
  background: var(--bg-alt);
  border-radius: var(--radius-card);
  padding: 28px;
  color: var(--text);
  transition: transform 0.2s ease;
}
.support-card:hover { text-decoration: none; transform: translateY(-2px); }
.support-card h3 { font-size: 24px; font-weight: 600; margin-bottom: 8px; }
.support-card p { margin: 0 0 14px; color: var(--text-secondary); }
.support-card .more { color: var(--link); }
.support-card .more::after { content: " \203A"; }

.faq { max-width: 720px; margin: 56px auto 0; }
.faq details { border-bottom: 0.5px solid var(--hairline); }
.faq details:first-child { border-top: 0.5px solid var(--hairline); }
.faq summary {
  list-style: none;
  cursor: pointer;
  padding: 18px 32px 18px 0;
  font-weight: 600;
  position: relative;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+";
  position: absolute;
  right: 4px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 24px;
  font-weight: 300;
  color: var(--text-secondary);
  transition: transform 0.2s ease;
}
.faq details[open] summary::after { transform: translateY(-50%) rotate(45deg); }
.faq details p { margin: 0 0 20px; color: var(--text-secondary); }

/* Footer */
.footer {
  background: var(--bg-alt);
  border-top: 0.5px solid var(--hairline);
  font-size: 12px;
  color: var(--text-secondary);
  padding: 20px var(--gutter) max(24px, env(safe-area-inset-bottom));
}
.footer-inner {
  max-width: var(--content);
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px 24px;
}
.footer p { margin: 0; }
.footer nav { display: flex; gap: 20px; }
.footer a { color: var(--text-secondary); }
.footer a:hover { color: var(--text); }
.legal { max-width: var(--content); margin: 10px auto 0 !important; }

@media (max-width: 600px) {
  body { font-size: 16px; }
  .nav-links a:not(.nav-get) { display: none; }
  .hero { padding-top: 48px; }
  .hero-icon { width: 96px; }
  .downloads { flex-direction: column; align-items: stretch; max-width: 320px; margin: 0 auto; }
  .store-button { justify-content: center; }
  .devices { margin-top: 44px; padding-right: 10%; }
  .device-phone { width: 30%; }
  .features, .support { padding-top: 88px; }
  .gallery { grid-template-columns: repeat(3, 62%); overflow-x: auto; scroll-snap-type: x mandatory; padding: 8px var(--gutter) 24px; margin: 56px calc(-1 * var(--gutter)) 0; scrollbar-width: none; }
  .gallery::-webkit-scrollbar { display: none; }
  .gallery figure { scroll-snap-align: center; }
}

/* Privacy policy */
.policy {
  max-width: 692px;
  margin: 0 auto;
  padding: 64px var(--gutter) 96px;
}
.policy h1 { font-size: clamp(36px, 6vw, 48px); line-height: 1.08; font-weight: 700; }
.policy-date { margin: 8px 0 32px; color: var(--text-secondary); font-size: 14px; }
.policy-lede { font-size: 21px; line-height: 1.38; margin: 0 0 8px; }
.policy h2 { font-size: 24px; font-weight: 600; margin: 40px 0 10px; }
.policy p, .policy li { color: var(--text-secondary); }
.policy strong { color: var(--text); font-weight: 600; }
.policy ul { padding-left: 1.2em; margin: 0 0 16px; }
.policy li { margin-bottom: 8px; }

/* Stands in for the download buttons until the App Store page exists. */
.availability {
  display: inline-block;
  margin: 0;
  padding: 10px 20px;
  border-radius: 980px;
  background: var(--bg-alt);
  border: 0.5px solid var(--hairline);
  font-size: 17px;
  font-weight: 500;
}
@media (max-width: 600px) {
  .availability { border-radius: 18px; text-wrap: balance; max-width: 320px; }
}
