/* Layout: the same look as glidemote.com, so the company and its apps read as one.
   Dark first, with a light palette for people whose system is set to light, or who
   pick it with the button in the header (data-theme, set by theme.js). Sections are
   set like a manual: hairlines and run-in heads rather than cards. */
:root {
  color-scheme: dark;
  --bg: #0a0b0d;
  --bg-raised: #0f1114;
  --surface: #131518;
  --surface-2: #1b1e23;
  --line: rgba(255, 255, 255, 0.08);
  --line-strong: rgba(255, 255, 255, 0.15);
  --fg: #eef0f3;
  --muted: #8f96a0;
  --accent: #5b8cff;
  --accent-text: #86a8ff;
  --cta: #3366f0;
  --cta-hover: #4675f5;
  --cta-ink: #ffffff;

  --font-display: "Young Serif", ui-serif, Georgia, "Times New Roman", serif;
  --font-body: "Onest", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;

  --radius: 10px;
}

@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) {
    color-scheme: light;
    --bg: #f3f5f8;
    --bg-raised: #ebeef3;
    --surface: #ffffff;
    --surface-2: #f2f4f8;
    --line: rgba(14, 20, 32, 0.09);
    --line-strong: rgba(14, 20, 32, 0.17);
    --fg: #0e1218;
    --muted: #59606d;
    --accent: #3366f0;
    --accent-text: #2556d8;
    --cta: #2556d8;
    --cta-hover: #1f4bc2;
  }
}
:root[data-theme="light"] {
  color-scheme: light;
  --bg: #f3f5f8;
  --bg-raised: #ebeef3;
  --surface: #ffffff;
  --surface-2: #f2f4f8;
  --line: rgba(14, 20, 32, 0.09);
  --line-strong: rgba(14, 20, 32, 0.17);
  --fg: #0e1218;
  --muted: #59606d;
  --accent: #3366f0;
  --accent-text: #2556d8;
  --cta: #2556d8;
  --cta-hover: #1f4bc2;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }

html { scroll-behavior: smooth; scroll-padding-top: 72px; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -webkit-text-size-adjust: 100%;
}

/* Paints the band behind a phone's status bar above the sticky nav. */
body::before {
  content: "";
  position: fixed;
  inset: 0 0 auto;
  height: env(safe-area-inset-top, 0px);
  z-index: 10;
  background: var(--bg);
}

h1, h2, h3 { margin: 0; text-wrap: balance; font-synthesis: none; }
p { margin: 0; }
a { color: inherit; }
img, svg { max-width: 100%; }

:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 6px; }

.wrap {
  width: 100%;
  max-width: 1180px;
  margin-inline: auto;
  padding-left: max(16px, env(safe-area-inset-left, 0px));
  padding-right: max(16px, env(safe-area-inset-right, 0px));
}
@media (min-width: 720px) {
  .wrap {
    padding-left: max(32px, env(safe-area-inset-left, 0px));
    padding-right: max(32px, env(safe-area-inset-right, 0px));
  }
}

/* -- buttons --------------------------------------------------------------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 50px;
  padding: 0 24px;
  border: 1px solid transparent;
  border-radius: 10px;
  background: var(--cta);
  color: var(--cta-ink);
  font: 600 1rem/1 var(--font-body);
  text-decoration: none;
  white-space: nowrap;
  transition: background 0.15s, border-color 0.15s, transform 0.15s;
}
.btn:hover { background: var(--cta-hover); }
.btn:active { transform: translateY(1px); }

.text-link {
  font-weight: 600;
  text-decoration: underline;
  text-decoration-color: var(--line-strong);
  text-decoration-thickness: 1px;
  text-underline-offset: 4px;
}
.text-link:hover { text-decoration-color: currentColor; }

/* -- nav ------------------------------------------------------------------- */

.nav {
  position: sticky;
  top: env(safe-area-inset-top, 0px);
  z-index: 5;
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  -webkit-backdrop-filter: blur(14px) saturate(1.4);
  backdrop-filter: blur(14px) saturate(1.4);
  border-bottom: 1px solid var(--line);
}
.nav-inner { display: flex; align-items: center; gap: 24px; height: 64px; }

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font: 400 1.25rem/1 var(--font-display);
  letter-spacing: -0.01em;
  text-decoration: none;
}
.brand .mark { width: 28px; height: 28px; flex: none; }

.nav-links { display: flex; gap: 26px; margin-left: auto; }
.nav-links a { color: var(--muted); font-size: 0.9375rem; font-weight: 500; text-decoration: none; }
.nav-links a:hover, .nav-links a[aria-current] { color: var(--fg); }

/* Light or dark. It shows the one in use, and hides without scripts, since then it
   can't do anything. */
.theme-toggle {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  margin-right: -8px;
  padding: 0;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  transition: color 0.15s, background 0.15s;
}
.theme-toggle:hover { color: var(--fg); background: var(--surface-2); }
.theme-toggle svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.theme-toggle .sun, :root[data-theme="light"] .theme-toggle .moon { display: none; }
:root[data-theme="light"] .theme-toggle .sun { display: block; }
:root:not([data-theme]) .theme-toggle { display: none; }

@media (max-width: 640px) {
  .nav-links { gap: 18px; }
}

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

.hero { border-bottom: 1px solid var(--line); }
.hero-inner { padding-block: clamp(56px, 9vw, 120px) clamp(64px, 9vw, 112px); }

h1 {
  max-width: 14em;
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(2.75rem, 1.8rem + 3.6vw, 4.9rem);
  line-height: 1;
  letter-spacing: -0.02em;
}

.lede { margin-top: 22px; max-width: 34em; color: var(--muted); font-size: 1.1875rem; line-height: 1.55; }

.cta-row { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 28px; margin-top: 32px; }

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

.band { padding-block: clamp(64px, 8vw, 104px); }
.band + .band { border-top: 1px solid var(--line); }

.section-head { display: grid; gap: 12px; max-width: 40rem; margin-bottom: clamp(32px, 4vw, 48px); }
h2 {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(2rem, 1.4rem + 2.2vw, 3rem);
  line-height: 1.05;
  letter-spacing: -0.015em;
}
.section-head p { color: var(--muted); font-size: 1.125rem; }

h3 { font-size: 1.1875rem; font-weight: 600; line-height: 1.25; }

/* products: one feature per product, its words beside a picture of it, then what's next */

.feature {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr);
  align-items: center;
  gap: 40px 64px;
  padding-block: 32px;
  border-top: 1px solid var(--line);
}
@media (max-width: 900px) { .feature { grid-template-columns: minmax(0, 1fr); } }
.feature-copy { display: grid; gap: 18px; max-width: 34rem; }
.feature-copy > p { color: var(--muted); }
.feature-copy .cta-row { margin-top: 10px; }
.feature-name { display: flex; align-items: center; gap: 16px; }
.feature-name img { width: 56px; height: 56px; flex: none; border-radius: 13px; }
.feature-name h3 { font: 400 2rem/1.05 var(--font-display); letter-spacing: -0.015em; }
.tagline { margin-top: 4px; color: var(--muted); }
.feature-copy .facts { font-size: 0.9375rem; }
.feature-shot {
  display: block;
  overflow: hidden;
  border-radius: var(--radius);
  background: #0a0b0d;
  border: 1px solid var(--line-strong);
}
.feature-shot img { display: block; width: 100%; height: auto; }

.coming {
  display: grid;
  grid-template-columns: minmax(0, 260px) minmax(0, 1fr);
  gap: 8px 64px;
  padding-top: 24px;
  border-top: 1px solid var(--line);
}
.coming p { max-width: 40rem; color: var(--muted); }
@media (max-width: 720px) { .coming { grid-template-columns: minmax(0, 1fr); } }

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

.footer { border-top: 1px solid var(--line); background: var(--bg-raised); }
.footer-inner { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 32px; padding-block: 36px; color: var(--muted); font-size: 0.9375rem; }
.footer .brand { color: var(--fg); margin-right: auto; }
.footer a:not(.brand) { color: var(--fg); text-underline-offset: 3px; }
.footer-links { display: flex; flex-wrap: wrap; gap: 8px 24px; }
.fine { width: 100%; font-size: 0.8125rem; }

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