@font-face { font-family: "Inter"; src: url("/fonts/inter-regular.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Inter"; src: url("/fonts/inter-medium.woff2") format("woff2"); font-weight: 500; font-display: swap; }
@font-face { font-family: "Inter"; src: url("/fonts/inter-semibold.woff2") format("woff2"); font-weight: 600; font-display: swap; }

:root {
  color-scheme: dark;
  --black: #000000;
  --paper: #f4f4f1;
  --muted: #8e8e89;
  --faint: #5e5e59;
  --line: rgba(255, 255, 255, 0.12);
  --lift: #161616;
  --down: #3cb87a;
  --up: #e25b54;
  --gutter: clamp(20px, 5vw, 56px);
  --measure: 34em;
  box-sizing: border-box;
  padding-top: env(safe-area-inset-top, 0px);
  padding-bottom: env(safe-area-inset-bottom, 0px);
}
*, *::before, *::after { box-sizing: inherit; }
html { scroll-padding-top: env(safe-area-inset-top, 0px); -webkit-text-size-adjust: 100%; }

html, body { margin: 0; background: var(--black); color: var(--paper); }
body {
  font-family: "Inter", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  font-size: 17px;
  line-height: 1.55;
  font-feature-settings: "cv11", "ss01";
  -webkit-font-smoothing: antialiased;
}
img, svg { max-width: 100%; display: block; }
a { color: var(--paper); text-decoration-color: var(--faint); text-underline-offset: 0.2em; }
a:hover { text-decoration-color: var(--paper); }
:focus-visible { outline: 2px solid var(--paper); outline-offset: 3px; border-radius: 4px; }
p { margin: 0 0 1em; }
.num { font-variant-numeric: tabular-nums; }

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

/* Header */
.top { display: flex; align-items: center; justify-content: space-between; padding-block: 22px; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; font-weight: 600; letter-spacing: -0.01em; }
.brand svg { width: 28px; height: 28px; }
.top nav a { color: var(--muted); text-decoration: none; font-size: 15px; }
.top nav a:hover, .top nav a[aria-current] { color: var(--paper); }

/* Hero */
.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  gap: clamp(32px, 6vw, 96px);
  align-items: center;
  padding-block: clamp(40px, 9vw, 120px) clamp(56px, 9vw, 128px);
}
h1 {
  margin: 0 0 28px;
  font-size: clamp(52px, 9vw, 112px);
  font-weight: 500;
  letter-spacing: -0.055em;
  line-height: 0.92;
}
.lead { color: var(--muted); font-size: clamp(18px, 2vw, 21px); line-height: 1.5; max-width: 26em; }
.lead strong { color: var(--paper); font-weight: 500; }
.platform { margin-top: 32px; color: var(--faint); font-size: 15px; }

/* The wheel demo */
.demo {
  background: var(--lift);
  border-radius: 36px;
  padding: 28px 24px 24px;
  max-width: 400px;
  width: 100%;
  justify-self: end;
}
.demo-head { display: flex; justify-content: space-between; align-items: baseline; }
.day { color: var(--muted); font-weight: 500; font-size: 16px; margin: 0; }
.units { display: inline-flex; border: 1px solid var(--line); border-radius: 999px; padding: 2px; }
.units button {
  appearance: none; border: 0; background: none; color: var(--faint);
  font: inherit; font-size: 13px; padding: 3px 10px; border-radius: 999px; cursor: pointer;
}
.units button[aria-pressed="true"] { background: #2a2a2a; color: var(--paper); }

.wheel {
  --row: 64px;
  position: relative;
  display: flex; justify-content: center; align-items: center; gap: 2px;
  height: calc(var(--row) * 3);
  margin: 14px 0 6px;
  -webkit-mask-image: linear-gradient(transparent, #000 30%, #000 70%, transparent);
          mask-image: linear-gradient(transparent, #000 30%, #000 70%, transparent);
}
.col {
  height: 100%;
  overflow-y: scroll;
  scroll-snap-type: y mandatory;
  scrollbar-width: none;
  overscroll-behavior: contain;
  cursor: grab;
  touch-action: pan-y;
  border-radius: 10px;
}
.col::-webkit-scrollbar { display: none; }
.col:active { cursor: grabbing; }
.col ol { list-style: none; margin: 0; padding: var(--row) 0; }
.col li {
  height: var(--row);
  display: flex; align-items: center; justify-content: center;
  scroll-snap-align: center;
  font-size: 54px; font-weight: 500; letter-spacing: -0.04em;
  font-variant-numeric: tabular-nums;
  padding-inline: 2px;
  user-select: none;
}
.col[data-wide] li { min-width: 2.5ch; justify-content: flex-end; }
.dot, .unit { font-size: 54px; font-weight: 500; color: var(--paper); }
.unit { font-size: 17px; color: var(--muted); align-self: center; margin-left: 8px; font-weight: 400; letter-spacing: 0; }

.confirm-row { display: flex; flex-direction: column; align-items: center; gap: 6px; min-height: 58px; }
.confirm {
  appearance: none; border: 0; cursor: pointer;
  background: var(--paper); color: var(--black);
  font: inherit; font-size: 14px; font-weight: 500;
  padding: 8px 26px; border-radius: 999px;
  box-shadow: 0 6px 18px rgba(244, 244, 241, 0.12);
  transition: background-color 0.2s, color 0.2s;
}
.confirm[aria-disabled="true"] { background: #2a2a2a; color: var(--faint); box-shadow: none; cursor: default; }
.saved { color: var(--muted); font-size: 12px; height: 16px; }

.week { margin-top: 14px; border-top: 1px solid var(--line); padding-top: 16px; }
.week-head { display: flex; justify-content: space-between; color: var(--faint); font-size: 13px; }
.week-head output { font-weight: 500; }
.week svg { width: 100%; height: 88px; margin-top: 8px; overflow: visible; }
.down { color: var(--down); }
.up { color: var(--up); }

/* Sections */
.section { border-top: 1px solid var(--line); padding-block: clamp(56px, 8vw, 104px); }
h2 {
  margin: 0 0 20px;
  font-size: clamp(30px, 4.2vw, 46px);
  font-weight: 500;
  letter-spacing: -0.035em;
  line-height: 1.05;
  max-width: 16em;
}
.section > .wrap > p { color: var(--muted); max-width: var(--measure); }

.split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(32px, 6vw, 96px); align-items: start; }
.split p { color: var(--muted); max-width: var(--measure); }

/* Metrics */
.metrics { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 40px 32px; margin-top: 56px; }
.metric dt { color: var(--faint); font-size: 14px; font-weight: 500; }
.metric .val { display: block; margin-top: 6px; font-size: clamp(36px, 4.4vw, 52px); font-weight: 500; letter-spacing: -0.04em; line-height: 1; color: var(--paper); font-variant-numeric: tabular-nums; }
.metric .per { display: block; color: var(--muted); font-size: 14px; margin-top: 6px; }
.metric dd { margin: 18px 0 0; color: var(--muted); font-size: 15px; line-height: 1.55; }
.trends { display: flex; gap: 14px; margin-top: 6px; font-size: 19px; font-weight: 500; font-variant-numeric: tabular-nums; }
.trends span { white-space: nowrap; }
.trends span small { display: block; color: var(--faint); font-size: 12px; font-weight: 400; }

/* Strava list */
.activities { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line); }
.activities li { display: grid; grid-template-columns: 1fr auto auto; gap: 20px; align-items: baseline; padding: 16px 0; border-bottom: 1px solid var(--line); }
.activities .name { font-weight: 500; }
.activities .when { color: var(--faint); font-size: 14px; }
.activities .kcal { font-variant-numeric: tabular-nums; font-weight: 500; text-align: right; min-width: 5.5em; }
.activities .kcal small { color: var(--muted); font-weight: 400; }
.fineprint { color: var(--faint); font-size: 14px; margin-top: 14px; }

/* Privacy promises */
.promises { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 32px; margin: 48px 0 36px; padding: 0; list-style: none; }
.promises li { border-left: 2px solid var(--line); padding-left: 18px; color: var(--muted); font-size: 15px; }
.promises strong { display: block; color: var(--paper); font-weight: 500; font-size: 18px; margin-bottom: 6px; letter-spacing: -0.01em; }

/* Footer */
.foot { border-top: 1px solid var(--line); padding-block: 32px 48px; color: var(--faint); font-size: 14px; }
.foot .wrap { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px 24px; }
.foot a { color: var(--muted); text-decoration: none; }
.foot a:hover { color: var(--paper); }
.foot nav { display: flex; gap: 24px; }

/* Privacy page */
.doc { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: clamp(32px, 6vw, 96px); padding-block: clamp(32px, 6vw, 80px) 96px; }
.doc h1 { font-size: clamp(48px, 7vw, 84px); margin-bottom: 24px; }
.toc { position: sticky; top: calc(24px + env(safe-area-inset-top, 0px)); align-self: start; padding-top: 12px; }
.toc ol { list-style: none; margin: 0; padding: 0; border-left: 1px solid var(--line); }
.toc a { display: block; padding: 6px 0 6px 16px; margin-left: -1px; border-left: 1px solid transparent; color: var(--muted); text-decoration: none; font-size: 15px; }
.toc a:hover { color: var(--paper); border-left-color: var(--paper); }
.doc article { max-width: 36em; }
.doc article .lead { margin-bottom: 40px; max-width: none; }
.doc h2 { max-width: none; font-size: 24px; letter-spacing: -0.02em; margin: 56px 0 14px; padding-top: 28px; border-top: 1px solid var(--line); }
.doc article p { color: #c9c9c4; }
.at-a-glance { list-style: none; padding: 0; margin: 0 0 8px; display: grid; gap: 10px; }
.at-a-glance li { padding-left: 22px; position: relative; color: var(--paper); }
.at-a-glance li::before { content: ""; position: absolute; left: 0; top: 0.62em; width: 8px; height: 8px; border-radius: 50%; background: var(--down); }

/* Responsive */
@media (max-width: 900px) {
  .hero { grid-template-columns: 1fr; }
  .demo { justify-self: start; }
  .metrics { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .split { grid-template-columns: 1fr; }
  .promises { grid-template-columns: 1fr; gap: 20px; }
  .doc { grid-template-columns: 1fr; }
  .toc { position: static; }
}
@media (max-width: 520px) {
  body { font-size: 16px; }
  .metrics { grid-template-columns: 1fr; }
  .demo { border-radius: 28px; padding-inline: 16px; }
  .wheel { --row: 56px; }
  .col li, .dot { font-size: 46px; }
  .activities li { grid-template-columns: 1fr auto; }
  .activities .when { grid-column: 1; grid-row: 2; }
  .activities .kcal { grid-row: 1 / span 2; grid-column: 2; align-self: center; }
}
@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; animation: none !important; scroll-behavior: auto !important; }
}
.metric dd.figure { margin: 0; }

/* Change */
.change { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); margin: 56px 0 0; border-top: 1px solid var(--line); }
.change > div { padding: 24px 24px 8px 0; }
.change > div + div { border-left: 1px solid var(--line); padding-left: 24px; }
.change dt { color: var(--faint); font-size: 14px; font-weight: 500; }
.change dd { margin: 10px 0 0; font-size: clamp(36px, 5vw, 64px); font-weight: 500; letter-spacing: -0.04em; line-height: 1; font-variant-numeric: tabular-nums; white-space: nowrap; }
.change dd small { font-size: 0.32em; letter-spacing: 0; color: var(--muted); font-weight: 400; }
@media (max-width: 900px) {
  .change { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .change > div:nth-child(3) { border-left: 0; padding-left: 0; }
  .change > div:nth-child(n+3) { border-top: 1px solid var(--line); }
}

/* Secondary button, same shape as Confirm */
.pill { display: inline-block; padding: 9px 22px; border: 1px solid var(--line); border-radius: 999px; color: var(--paper); text-decoration: none; font-size: 15px; font-weight: 500; transition: border-color 0.2s, background-color 0.2s; }
.pill:hover { border-color: var(--muted); background: var(--lift); }
