:root{--bg:#f6f7f8;--surface:#ffffff;--surface-raised:#ffffff;--fill:#eef0f2;--fill-strong:#e2e5e9;--separator:#e6e8eb;--outline:#d2d6db;--text:#111316;--text-secondary:#5d646e;--text-tertiary:#69717c;--accent:#14a35c;--on-accent:#ffffff;--accent-container:rgba(20,163,92,0.12);--on-accent-container:#0b7a43;--danger:#ff3b30;--on-danger:#ffffff;--danger-container:rgba(255,59,48,0.12);--on-danger-container:#d70015;--warning:#ff9500;--warning-container:rgba(255,149,0,0.14);--success:#14a35c;--info:#007aff;--info-container:rgba(0,122,255,0.12);--premium:#b8860b;--premium-container:rgba(255,184,0,0.16);--macro-protein:#2f6bff;--macro-fat:#e08a00;--macro-carbs:#8e4fe0;--water:#0a9bd8;--status-under:#e08a00;--status-good:#14a35c;--status-over:#e5484d;--status-none:rgba(120,120,128,0.2);--water-container:rgba(10,155,216,0.12);--scrim:rgba(0,0,0,0.25);--glass:rgba(255,255,255,0.8);--glass-border:#e6e8eb;--pressed:rgba(17,19,22,0.05);--space-none:0px;--space-xxs:2px;--space-xs:4px;--space-sm:8px;--space-md:12px;--space-lg:16px;--space-xl:20px;--space-xxl:24px;--space-xxxl:32px;--space-huge:48px;--radius-card:16px;--radius-control:10px;--radius-field:10px;--radius-sheet:20px;--radius-full:999px;--size-hit:40px;--size-field:44px;--size-row:48px;--size-app-bar:64px;--size-tab-bar:64px;--size-button-lg:52px;--size-button-md:44px;--size-button-sm:34px;--size-sidebar:248px;--size-gutter:16px;--size-reading-width:720px;--size-dashboard-width:1120px;--duration-fast:150ms;--duration-base:250ms;--duration-slow:400ms;--font:system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;--font-rounded:ui-rounded, "SF Pro Rounded", system-ui, -apple-system, sans-serif;}
@media (prefers-color-scheme:dark){:root{--bg:#0d0e10;--surface:#16181b;--surface-raised:#1e2125;--fill:#24272c;--fill-strong:#2d3137;--separator:#25282d;--outline:#353a41;--text:#ecedef;--text-secondary:#9ba1a9;--text-tertiary:#838a93;--accent:#2fc97a;--on-accent:#00210f;--accent-container:rgba(47,201,122,0.18);--on-accent-container:#6be3a2;--danger:#ff453a;--on-danger:#ffffff;--danger-container:rgba(255,69,58,0.18);--on-danger-container:#ff7a70;--warning:#ff9f0a;--warning-container:rgba(255,159,10,0.18);--success:#2fc97a;--info:#0a84ff;--info-container:rgba(10,132,255,0.2);--premium:#ffc93c;--premium-container:rgba(255,201,60,0.16);--macro-protein:#5a8cff;--macro-fat:#ffb224;--macro-carbs:#b07cff;--water:#3cc4f5;--status-under:#ffb224;--status-good:#2fc97a;--status-over:#ff6369;--status-none:rgba(120,120,128,0.32);--water-container:rgba(60,196,245,0.16);--scrim:rgba(0,0,0,0.5);--glass:rgba(22,24,27,0.8);--glass-border:#25282d;--pressed:rgba(255,255,255,0.05);}}
/* OneFit beta download page. Colours, radii, spacing and font stacks are the Pulse tokens
   (packages/design/tokens.json, web themes), prepended by build.mjs as custom properties.
   Pulse rules kept here: calm flat surfaces, colour only for meaning, rounded tabular numerals
   for metrics, no gradients or decorative shadows. */

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

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

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 1rem;
  line-height: 1.5;
}

h1,
h2,
h3,
p,
ul,
ol,
dl,
dd,
blockquote {
  margin: 0;
}

ul,
ol {
  padding: 0;
  list-style: none;
}

a {
  color: var(--on-accent-container);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.18em;
}

a:hover {
  text-decoration-thickness: 2px;
}

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

code {
  font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  font-size: 0.875em;
}

.skip {
  position: absolute;
  left: var(--space-lg);
  top: -4rem;
  z-index: 1;
  padding: var(--space-sm) var(--space-lg);
  border-radius: var(--radius-control);
  background: var(--surface-raised);
  color: var(--text);
}

.skip:focus {
  top: var(--space-lg);
}

/* --- frame ------------------------------------------------------------------------------- */

.top,
main,
.foot {
  width: min(100% - 2 * var(--space-lg), 66rem);
  margin-inline: auto;
}

.top {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-sm) var(--space-lg);
  padding-block: var(--space-lg);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
  min-height: var(--size-hit);
  color: var(--text);
  text-decoration: none;
}

.mark {
  color: var(--accent);
}

.brand-name {
  font-family: var(--font-rounded);
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.badge {
  padding: 2px var(--space-sm);
  border-radius: var(--radius-full);
  background: var(--accent-container);
  color: var(--on-accent-container);
  font-size: 0.75rem;
  font-weight: 600;
  line-height: 1rem;
}

.langs ul {
  display: flex;
  gap: var(--space-xxs);
  padding: var(--space-xxs);
  border-radius: var(--radius-control);
  background: var(--fill);
}

.langs a {
  display: block;
  padding: 6px var(--space-md);
  border-radius: calc(var(--radius-control) - var(--space-xxs));
  color: var(--text-secondary);
  font-size: 0.875rem;
  font-weight: 500;
  line-height: 1.25rem;
  text-decoration: none;
}

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

.langs a[aria-current] {
  background: var(--surface-raised);
  color: var(--text);
}

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

/* Phones: words, then the downloads, then the sample day. Wide: words beside the day. */
.intro {
  display: grid;
  grid-template-areas: "text" "get" "day";
  gap: var(--space-xxxl);
  padding-top: var(--space-xxl);
}

.hero-text {
  grid-area: text;
}

.get {
  grid-area: get;
}

h1 {
  max-width: 14ch;
  font-family: var(--font-rounded);
  font-size: clamp(2.25rem, 1.2rem + 5.2vw, 4rem);
  font-weight: 700;
  line-height: 1.04;
  letter-spacing: -0.025em;
  text-wrap: balance;
}

.lead {
  max-width: 34rem;
  margin-top: var(--space-xl);
  font-size: 1.125rem;
  line-height: 1.55;
}

.lead-beta {
  max-width: 34rem;
  margin-top: var(--space-md);
  color: var(--text-secondary);
}

/* The sample day: the product's own shapes (calorie ring, macro bars), not a screenshot. */
.day {
  grid-area: day;
  justify-self: center;
  width: 100%;
  max-width: 22rem;
  padding: var(--space-xl);
  border-radius: var(--radius-sheet);
  background: var(--surface);
  border: 1px solid var(--separator);
}

.day-title {
  color: var(--text-secondary);
  font-size: 0.875rem;
  font-weight: 500;
}

.ring {
  position: relative;
  width: 11rem;
  margin: var(--space-md) auto var(--space-xl);
}

.ring svg {
  display: block;
  width: 100%;
}

.ring circle {
  fill: none;
  stroke-width: 12;
}

.ring-track {
  stroke: var(--fill-strong);
}

.ring-value {
  stroke: var(--accent);
  stroke-linecap: round;
}

.ring-text {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.metric {
  font-family: var(--font-rounded);
  font-size: 2.125rem;
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
}

.ring-unit,
.ring-goal {
  color: var(--text-secondary);
  font-size: 0.75rem;
  line-height: 1rem;
}

.bars {
  display: grid;
  gap: var(--space-md);
}

.bar {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: var(--space-xs) var(--space-md);
  font-size: 0.875rem;
  line-height: 1.25rem;
}

.bar-name {
  font-weight: 500;
}

.bar-value {
  color: var(--text-secondary);
  font-variant-numeric: tabular-nums;
}

.bar svg {
  grid-column: 1 / -1;
  display: block;
  width: 100%;
  height: 6px;
}

.bar-track {
  fill: var(--fill-strong);
}

.bar-fill {
  transform-box: fill-box;
  transform-origin: left center;
}

.bar-protein .bar-fill {
  fill: var(--macro-protein);
}

.bar-fat .bar-fill {
  fill: var(--macro-fat);
}

.bar-carbs .bar-fill {
  fill: var(--macro-carbs);
}

.bar-water .bar-fill {
  fill: var(--water);
}

/* The one moment of motion: the day fills in once, as it does in the app. */
@media (prefers-reduced-motion: no-preference) {
  .ring-value {
    animation: ring-fill 900ms cubic-bezier(0.22, 1, 0.36, 1) 150ms backwards;
  }

  .bar-fill {
    animation: bar-fill 700ms cubic-bezier(0.22, 1, 0.36, 1) 350ms backwards;
  }
}

/* The ring's circumference (2π × 52, build.mjs sampleDay): from empty to the drawn value. */
@keyframes ring-fill {
  from {
    stroke-dashoffset: 326.73;
  }
}

@keyframes bar-fill {
  from {
    transform: scaleX(0);
  }
}

/* --- get the beta: a grouped list, like the app's settings rows ---------------------------- */

h2 {
  font-size: 1.375rem;
  font-weight: 700;
  line-height: 1.75rem;
  letter-spacing: -0.012em;
}

.get h2 {
  margin-bottom: var(--space-lg);
}

.rows {
  border-radius: var(--radius-sheet);
  background: var(--surface);
  border: 1px solid var(--separator);
}

.row {
  display: grid;
  gap: var(--space-lg);
  padding: var(--space-xl);
}

.row + .row {
  border-top: 1px solid var(--separator);
}

.row h3 {
  font-size: 1.0625rem;
  font-weight: 600;
  line-height: 1.5rem;
}

.row-text p {
  max-width: 32rem;
  color: var(--text-secondary);
}

.row-text .row-req {
  margin-top: var(--space-xs);
  color: var(--text-tertiary);
  font-size: 0.875rem;
  line-height: 1.25rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: var(--size-button-lg);
  padding: var(--space-md) var(--space-xxl);
  border: 0;
  border-radius: var(--radius-control);
  background: var(--fill);
  color: var(--text);
  font: inherit;
  /* 19px bold counts as large text: the accent/on-accent pair is tuned for it (3:1). */
  font-size: 1.1875rem;
  font-weight: 700;
  line-height: 1.5rem;
  text-align: center;
  text-decoration: none;
  transition: transform var(--duration-fast);
}

.btn-primary {
  background: var(--accent);
  color: var(--on-accent);
}

.btn-tonal {
  background: var(--accent-container);
  color: var(--on-accent-container);
}

a.btn:hover {
  box-shadow: inset 0 0 0 100vmax var(--pressed);
}

a.btn:active {
  transform: scale(0.97);
}

.btn:disabled {
  color: var(--text-secondary);
  font-size: 1rem;
  font-weight: 500;
  cursor: not-allowed;
}

.facts {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-lg);
  padding: var(--space-lg);
  border-radius: var(--radius-card);
  background: var(--fill);
}

.facts dt {
  color: var(--text-secondary);
  font-size: 0.75rem;
  line-height: 1rem;
}

.facts dd {
  font-family: var(--font-rounded);
  font-size: 1.0625rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.fact-wide {
  grid-column: 1 / -1;
}

.facts .hash {
  display: block;
  font-size: 0.8125rem;
  font-weight: 400;
  line-height: 1.25rem;
  overflow-wrap: anywhere;
  user-select: all;
}

/* --- notes, install steps, support ---------------------------------------------------------- */

.columns {
  display: grid;
  gap: var(--space-huge);
  padding-block: var(--space-huge);
}

.block h2 {
  margin-bottom: var(--space-lg);
}

.notes,
.steps {
  display: grid;
  gap: var(--space-md);
  max-width: 36rem;
}

.notes li {
  position: relative;
  padding-left: var(--space-xl);
}

.notes li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.55em;
  width: 8px;
  height: 8px;
  border-radius: var(--radius-full);
  background: var(--accent);
}

/* Numbered: installing is a real sequence. */
.steps {
  counter-reset: step;
}

.steps li {
  position: relative;
  min-height: 1.75rem;
  padding-left: calc(1.75rem + var(--space-md));
  counter-increment: step;
}

.steps li::before {
  content: counter(step);
  position: absolute;
  left: 0;
  top: -0.125rem;
  width: 1.75rem;
  height: 1.75rem;
  border-radius: var(--radius-full);
  background: var(--fill-strong);
  font-family: var(--font-rounded);
  font-size: 0.875rem;
  font-weight: 700;
  line-height: 1.75rem;
  text-align: center;
}

.aside {
  max-width: 36rem;
  margin-top: var(--space-lg);
  color: var(--text-secondary);
  font-size: 0.875rem;
  line-height: 1.375rem;
}

.aside code {
  overflow-wrap: anywhere;
}

.support {
  padding: var(--space-xxl) var(--space-xl);
  border-radius: var(--radius-sheet);
  background: var(--fill);
}

.support p {
  max-width: 36rem;
  margin-top: var(--space-sm);
}

.foot {
  display: grid;
  gap: var(--space-md);
  padding-block: var(--space-xxxl) var(--space-huge);
  color: var(--text-secondary);
  font-size: 0.875rem;
  line-height: 1.25rem;
}

.legal-links ul {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-xs) var(--space-xl);
}

.legal-links a {
  display: inline-block;
  padding-block: var(--space-xs);
  color: var(--text-secondary);
}

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

/* --- legal pages ---------------------------------------------------------------------------- */

.legal {
  padding-block: var(--space-lg) var(--space-xxl);
}

.back {
  margin-bottom: var(--space-xxl);
  font-size: 0.875rem;
}

.prose {
  max-width: var(--size-reading-width);
  overflow-wrap: break-word;
}

.prose h1 {
  max-width: none;
  margin-top: var(--space-xxl);
  margin-bottom: var(--space-lg);
  font-size: clamp(1.75rem, 1.3rem + 2vw, 2.5rem);
  line-height: 1.15;
}

.prose > :first-child {
  margin-top: 0;
}

.prose h2 {
  margin-top: var(--space-huge);
  margin-bottom: var(--space-md);
}

.prose h3,
.prose h4 {
  margin-top: var(--space-xxl);
  margin-bottom: var(--space-sm);
  font-size: 1.0625rem;
  font-weight: 600;
  line-height: 1.5rem;
}

.prose p,
.prose ul,
.prose ol,
.prose blockquote,
.prose .table {
  margin-top: var(--space-md);
}

.prose ul,
.prose ol {
  padding-left: var(--space-xxl);
}

.prose ul {
  list-style: disc;
}

.prose ol {
  list-style: decimal;
}

.prose li + li,
.prose li > ul,
.prose li > ol {
  margin-top: var(--space-sm);
}

.prose blockquote {
  padding: var(--space-md) var(--space-lg);
  border-radius: var(--radius-control);
  background: var(--fill);
}

.prose blockquote p {
  margin-top: 0;
}

.prose .table {
  overflow-x: auto;
  border: 1px solid var(--separator);
  border-radius: var(--radius-control);
}

.prose table {
  width: 100%;
  min-width: 34rem;
  border-collapse: collapse;
  font-size: 0.875rem;
  line-height: 1.375rem;
}

.prose th,
.prose td {
  padding: var(--space-sm) var(--space-md);
  text-align: left;
  vertical-align: top;
}

.prose th {
  background: var(--fill);
  font-weight: 600;
}

.prose tr + tr td {
  border-top: 1px solid var(--separator);
}

/* --- wider screens -------------------------------------------------------------------------- */

@media (min-width: 40rem) {
  .row {
    grid-template-columns: 1fr auto;
    align-items: center;
    padding: var(--space-xxl);
  }

  .row .btn {
    min-width: 15rem;
  }

  .facts {
    grid-column: 1 / -1;
    grid-template-columns: auto auto 1fr;
    gap: var(--space-lg) var(--space-xxxl);
  }

  .fact-wide {
    grid-column: auto;
  }

  .support {
    padding: var(--space-xxxl);
  }
}

@media (min-width: 56rem) {
  .intro {
    grid-template-areas: "text day" "get get";
    grid-template-columns: 1fr auto;
    align-items: center;
    gap: 4.5rem var(--space-huge);
    padding-top: var(--space-huge);
  }

  .day {
    width: 22rem;
  }

  .columns {
    grid-template-columns: 1fr 1fr;
  }

  .columns-single {
    grid-template-columns: 1fr;
  }
}

@media (prefers-contrast: more) {
  .rows,
  .day,
  .prose .table {
    border-color: var(--outline);
  }

  .lead-beta,
  .row-text p,
  .bar-value {
    color: var(--text);
  }
}

@media print {
  .langs,
  .day,
  .skip {
    display: none;
  }
}
