:root {
  color-scheme: light dark;
  --canvas: #ffffff;
  --card: #f7f7f7;
  --stroke: #ededed;
  --ink: #000000;
  --on-ink: #ffffff;
  --muted: #6b6b6b;
  --faint: #6b6b6b;
  --thumb: #f2f2f2;
  --thumb-stroke: #e4e4e4;
  --protein: #ff5a5a;
  --carbs: #f5a524;
  --fat: #4a90d9;
  --protein-track: #ffe4e4;
  --carbs-track: #fdeccf;
  --fat-track: #dce9f7;
  --success: #10b981;
  --warn: #f5a524;
  --font-display: "Outfit", ui-rounded, system-ui, sans-serif;
  --font-body: "Nunito", ui-sans-serif, system-ui, sans-serif;
  --ease: cubic-bezier(0.32, 0.72, 0, 1);
  --radius-chip: 14px;
  --radius-card: 24px;
  --radius-cta: 28px;
  --cta-h: 56px;
  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-5: 20px;
  --space-6: 24px;
  --space-8: 32px;
  --space-10: 40px;
  --space-16: 64px;
  --space-24: 96px;
  --prose: 66ch;
  --page: 1120px;
  --shadow: 0 2px 16px rgba(0, 0, 0, 0.04);
}

@media (prefers-color-scheme: dark) {
  :root {
    --canvas: #000000;
    --card: #1c1c1e;
    --stroke: #2f2f31;
    --ink: #ffffff;
    --on-ink: #000000;
    --muted: #8e8e93;
    --faint: #8a8a8e;
    --thumb: #2c2c2e;
    --thumb-stroke: #3a3a3c;
    --protein-track: #3a2020;
    --carbs-track: #3a2e18;
    --fat-track: #1c2c3e;
    --shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
  }
}

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

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

body {
  min-height: 100dvh;
  background: var(--canvas);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 1.0625rem;
  font-weight: 400;
  line-height: 1.65;
  letter-spacing: -0.01em;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: inherit;
  text-underline-offset: 3px;
}

a:hover {
  color: var(--ink);
}

:focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: 3px;
}

.skip {
  position: absolute;
  left: -999px;
  top: 8px;
  background: var(--ink);
  color: var(--on-ink);
  padding: 8px 14px;
  border-radius: 999px;
  z-index: 20;
}

.skip:focus {
  left: 12px;
}

.macro-bar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  display: flex;
  z-index: 12;
  pointer-events: none;
}

.macro-bar i:nth-child(1) { flex: 2.36; background: var(--protein); }
.macro-bar i:nth-child(2) { flex: 4.65; background: var(--carbs); }
.macro-bar i:nth-child(3) { flex: 2.99; background: var(--fat); }

.island-wrap {
  position: sticky;
  top: 14px;
  z-index: 10;
  display: flex;
  justify-content: center;
  padding: 0 16px;
  pointer-events: none;
}

.island {
  pointer-events: auto;
  display: flex;
  align-items: center;
  gap: 6px;
  width: min(100%, 920px);
  padding: 6px 6px 6px 10px;
  background: color-mix(in oklab, var(--card) 88%, var(--canvas));
  backdrop-filter: saturate(1.4) blur(18px);
  -webkit-backdrop-filter: saturate(1.4) blur(18px);
  border: 1px solid var(--stroke);
  border-radius: 999px;
  box-shadow: var(--shadow);
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  padding: 4px 10px 4px 4px;
  border-radius: 999px;
  flex: none;
}

.brand img {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  box-shadow: 0 0 0 1px var(--stroke);
}

.brand strong {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.95rem;
  letter-spacing: -0.03em;
}

.island nav {
  display: flex;
  align-items: center;
  gap: 2px;
  margin-left: auto;
  overflow-x: auto;
  scrollbar-width: none;
}

.island nav::-webkit-scrollbar { display: none; }

.island a:not(.brand) {
  text-decoration: none;
  font-family: var(--font-display);
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--muted);
  padding: 8px 12px;
  border-radius: 999px;
  white-space: nowrap;
  transition: color 420ms var(--ease), background 420ms var(--ease);
}

.island a:not(.brand):hover {
  color: var(--ink);
  background: var(--card);
}

.island a.is-active {
  color: var(--ink);
  background: var(--thumb);
}

.lang {
  display: flex;
  background: var(--card);
  border: 1px solid var(--stroke);
  border-radius: 999px;
  padding: 3px;
  margin-left: 4px;
  flex: none;
}

.lang button {
  appearance: none;
  border: 0;
  background: transparent;
  color: var(--muted);
  font-family: var(--font-display);
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  padding: 6px 9px;
  border-radius: 999px;
  cursor: pointer;
}

.lang button.is-active {
  background: var(--ink);
  color: var(--on-ink);
}

.page {
  width: min(100% - 40px, var(--page));
  margin: 0 auto;
  padding: 48px 0 96px;
}

.legal-grid {
  display: grid;
  grid-template-columns: minmax(220px, 280px) minmax(0, 1fr);
  gap: 64px;
  align-items: start;
}

.lede {
  position: sticky;
  top: 92px;
}

.kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-display);
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--muted);
  background: var(--card);
  border: 1px solid var(--stroke);
  border-radius: 999px;
  padding: 6px 12px;
  margin-bottom: 20px;
}

.kicker .dots {
  display: flex;
  gap: 4px;
}

.kicker .dots span {
  width: 6px;
  height: 6px;
  border-radius: 50%;
}

.kicker .dots span:nth-child(1) { background: var(--protein); }
.kicker .dots span:nth-child(2) { background: var(--carbs); }
.kicker .dots span:nth-child(3) { background: var(--fat); }

h1 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(2.4rem, 6vw, 4.4rem);
  line-height: 0.96;
  letter-spacing: -0.045em;
  margin-bottom: 16px;
}

.subhead {
  color: var(--muted);
  font-size: 1.05rem;
  max-width: 36ch;
  margin-bottom: 20px;
}

.meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 28px;
}

.pill {
  font-family: var(--font-display);
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--muted);
  background: var(--card);
  border: 1px solid var(--stroke);
  border-radius: 999px;
  padding: 6px 12px;
  text-decoration: none;
}

a.pill:hover {
  color: var(--ink);
}

.toc {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.toc a {
  text-decoration: none;
  color: var(--muted);
  font-family: var(--font-display);
  font-size: 0.875rem;
  font-weight: 500;
  padding: 8px 10px;
  border-radius: 12px;
  transition: color 420ms var(--ease), background 420ms var(--ease);
}

.toc a:hover,
.toc a.is-active {
  color: var(--ink);
  background: var(--card);
}

.prose {
  max-width: var(--prose);
}

.prose > * + * {
  margin-top: 1.1em;
}

.prose h2 {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 650;
  letter-spacing: -0.03em;
  line-height: 1.2;
  margin-top: 3.2em;
  scroll-margin-top: 96px;
}

.prose h2 .num {
  display: block;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 8px;
}

.prose h3 {
  font-family: var(--font-display);
  font-size: 1.05rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  margin-top: 1.6em;
}

.prose p,
.prose li {
  color: color-mix(in oklab, var(--ink) 78%, var(--muted));
  overflow-wrap: break-word;
}

.prose ul,
.prose ol {
  padding-left: 1.2em;
}

.prose a {
  text-decoration: underline;
}

.prose a.btn,
.prose a.tile,
.prose a.pill {
  text-decoration: none;
}

.bezel {
  background: var(--card);
  border: 1px solid var(--stroke);
  border-radius: 28px;
  padding: 6px;
}

.bezel > .inner {
  background: var(--canvas);
  border: 1px solid var(--stroke);
  border-radius: 22px;
  padding: 18px 20px;
}

.stack {
  display: grid;
  gap: 10px;
}

.tile {
  background: var(--card);
  border: 1px solid var(--stroke);
  border-radius: var(--radius-card);
  padding: 16px 18px;
}

.tile h3,
.tile .t {
  font-family: var(--font-display);
  font-size: 0.95rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  margin-bottom: 4px;
}

.tile p,
.tile .d {
  font-size: 0.9rem;
  color: var(--muted);
  margin: 0;
}

.processors {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(148px, 1fr));
  gap: 10px;
}

.processors a {
  text-decoration: none;
  background: var(--card);
  border: 1px solid var(--stroke);
  border-radius: 20px;
  padding: 16px;
  min-height: 92px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: transform 500ms var(--ease);
}

.processors a:hover {
  transform: translateY(-2px);
  color: inherit;
}

.processors strong {
  font-family: var(--font-display);
  font-size: 0.95rem;
  font-weight: 600;
}

.processors span {
  font-size: 0.78rem;
  color: var(--muted);
}

.steps {
  counter-reset: step;
  list-style: none;
  padding: 0;
  display: grid;
  gap: 12px;
}

.steps li {
  counter-increment: step;
  display: grid;
  grid-template-columns: 32px 1fr;
  gap: 14px;
  align-items: start;
  color: var(--muted);
  font-size: 0.95rem;
}

.steps li::before {
  content: counter(step, decimal-leading-zero);
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.75rem;
  letter-spacing: 0.04em;
  color: var(--on-ink);
  background: var(--ink);
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: grid;
  place-items: center;
}

.cta-block {
  margin-top: 64px;
  background: var(--ink);
  color: var(--on-ink);
  border-radius: 32px;
  padding: 36px 32px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.cta-block h2 {
  font-family: var(--font-display);
  font-size: 1.8rem;
  letter-spacing: -0.035em;
  line-height: 1.05;
  margin: 0 0 8px;
}

.cta-block p {
  color: color-mix(in oklab, var(--on-ink) 70%, transparent);
  margin: 0;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  height: var(--cta-h);
  padding: 0 8px 0 22px;
  background: var(--on-ink);
  color: var(--ink);
  border-radius: var(--radius-cta);
  text-decoration: none;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1rem;
  transition: transform 420ms var(--ease);
}

.btn:hover {
  color: var(--ink);
  transform: scale(0.985);
}

.btn i {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--card);
  display: grid;
  place-items: center;
}

.plans {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.plan {
  background: var(--card);
  border: 1px solid var(--stroke);
  border-radius: 24px;
  padding: 22px;
}

.plan.pro {
  background: var(--ink);
  color: var(--on-ink);
  border-color: var(--ink);
}

.plan h3 {
  font-family: var(--font-display);
  font-size: 1.15rem;
  margin-bottom: 14px;
}

.plan ul {
  list-style: none;
  padding: 0;
  display: grid;
  gap: 8px;
}

.plan li {
  font-size: 0.92rem;
  color: inherit;
}

.plan.pro li {
  color: color-mix(in oklab, var(--on-ink) 78%, transparent);
}

.site-foot {
  width: min(100% - 40px, var(--page));
  margin: 0 auto;
  padding: 32px 0 48px;
  border-top: 1px solid var(--stroke);
  display: flex;
  flex-wrap: wrap;
  gap: 16px 28px;
  align-items: center;
  color: var(--muted);
  font-size: 0.875rem;
}

.site-foot nav {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin-left: auto;
}

.site-foot a {
  text-decoration: none;
  color: var(--muted);
}

.site-foot a:hover { color: var(--ink); }

.hero-home {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 56px;
  align-items: center;
  padding: 72px 0 48px;
}

.phone {
  background: var(--canvas);
  border: 1px solid var(--stroke);
  border-radius: 28px;
  padding: 20px 0 22px;
  box-shadow: var(--shadow);
}

.week {
  display: flex;
  justify-content: space-between;
  padding: 0 20px;
}

.week div {
  width: 40px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 7px;
  font-family: var(--font-display);
  font-size: 0.72rem;
  color: var(--muted);
}

.week b {
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}

.week .on {
  width: 40px;
  height: 40px;
  border-radius: 20px;
  background: var(--ink);
  color: var(--on-ink);
  display: grid;
  place-items: center;
  font-weight: 600;
  font-size: 1rem;
  font-variant-numeric: tabular-nums;
}

.week div:has(.on) {
  color: var(--ink);
  font-weight: 600;
}

.hero-card {
  margin: 18px 20px 0;
  background: var(--card);
  border: 1px solid var(--stroke);
  border-radius: 24px;
  padding: 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.kcal {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 3.4rem;
  line-height: 0.92;
  letter-spacing: -0.035em;
  font-variant-numeric: tabular-nums;
}

.kcal-cap {
  color: var(--muted);
  font-size: 0.84rem;
  margin-top: 9px;
}

.macros3 {
  display: flex;
  gap: 11px;
  margin: 12px 20px 0;
}

.m-tile {
  flex: 1;
  background: var(--card);
  border: 1px solid var(--stroke);
  border-radius: 20px;
  padding: 12px;
}

.m-tile strong {
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.m-tile small {
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--muted);
}

.m-tile > span {
  display: block;
  color: var(--muted);
  font-size: 0.72rem;
  margin-top: 8px;
}

.scan-cta {
  margin: 20px 20px 0;
  height: 56px;
  border-radius: 28px;
  background: var(--ink);
  color: var(--on-ink);
  display: grid;
  place-items: center;
  font-family: var(--font-display);
  font-weight: 600;
}

.badges {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 28px;
}

.badges a img {
  height: 48px;
}

.how {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
  margin: 48px 0;
}

.how article {
  background: var(--card);
  border: 1px solid var(--stroke);
  border-radius: 24px;
  padding: 22px;
}

.how .n {
  font-family: var(--font-display);
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted);
}

.how h3 {
  font-family: var(--font-display);
  font-size: 1.35rem;
  letter-spacing: -0.03em;
  margin: 10px 0 8px;
}

.faq-search {
  width: 100%;
  height: 56px;
  border-radius: 28px;
  border: 1px solid var(--stroke);
  background: var(--card);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 1rem;
  padding: 0 22px;
  margin: 8px 0 28px;
}

.faq-item {
  border: 1px solid var(--stroke);
  background: var(--card);
  border-radius: 20px;
  overflow: hidden;
}

.faq-item + .faq-item { margin-top: 8px; }

.faq-q {
  width: 100%;
  text-align: left;
  background: none;
  border: 0;
  color: var(--ink);
  font-family: var(--font-display);
  font-size: 1.02rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  padding: 18px 20px;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  gap: 16px;
}

.faq-a {
  display: none;
  padding: 0 20px 18px;
  color: var(--muted);
  font-size: 0.95rem;
}

.faq-item.is-open .faq-a { display: block; }

.faq-item.is-open .faq-q span:last-child { transform: rotate(45deg); }

.cat-title {
  font-family: var(--font-display);
  font-size: 0.75rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--muted);
  margin: 32px 0 12px;
}

.help-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
}

.help-grid a {
  text-decoration: none;
  background: var(--card);
  border: 1px solid var(--stroke);
  border-radius: 22px;
  padding: 18px;
}

.help-grid h3 {
  font-family: var(--font-display);
  font-size: 1.05rem;
  margin-bottom: 6px;
}

.help-grid p {
  color: var(--muted);
  font-size: 0.88rem;
}

.reveal {
  opacity: 0;
  transform: translateY(18px);
  animation: rise 800ms var(--ease) forwards;
}

@keyframes rise {
  to { opacity: 1; transform: none; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; animation: none; }
  * { transition: none !important; }
}

@media (max-width: 860px) {
  .legal-grid,
  .hero-home,
  .how,
  .plans,
  .help-grid {
    grid-template-columns: 1fr;
  }
  .lede { position: static; }
  .toc {
    flex-direction: row;
    overflow-x: auto;
    padding-bottom: 8px;
  }
  .toc a { white-space: nowrap; }
  .island {
    width: 100%;
    border-radius: 22px;
    flex-wrap: wrap;
    padding: 8px;
  }
  .island nav {
    width: 100%;
    margin-left: 0;
    order: 3;
  }
  .page { width: min(100% - 32px, var(--page)); padding-top: 20px; }
  .hero-home { padding-top: 20px; gap: 28px; }
  .kcal { font-size: 2.6rem; }
  .cta-block { padding: 28px 22px; }
  .btn { width: 100%; padding-right: 8px; }
}

@media print {
  .macro-bar, .island-wrap, .cta-block, .site-foot, .lang { display: none !important; }
  body { background: #fff; color: #000; }
  .lede { position: static; }
}
