/* CaloDine — calodine.com
   Design system mirrors the iOS app: warm off-white, fresh green,
   soft orange, deep charcoal, large rounded cards. */

:root {
  --bg: #F9F7F3;
  --surface: #FFFFFF;
  --ink: #212429;
  --ink-2: #62666C;
  --ink-3: #696E74;
  --green: #27AE60;
  --green-deep: #13854A;
  /* Text-on-light link green and text-bearing gradient: AA-contrast safe. */
  --link: #0E6B3C;
  --green-grad: linear-gradient(135deg, #17864A, #0E6B3C);
  --green-tint: rgba(39, 174, 96, 0.12);
  --orange: #F98C3C;
  --orange-tint: rgba(249, 140, 60, 0.14);
  --protein: #377AF6;
  --carbs: #F69232;
  --fat: #9C5AE5;
  --stroke: rgba(0, 0, 0, 0.06);
  --shadow: 0 12px 32px rgba(23, 43, 30, 0.08);
  --shadow-soft: 0 6px 18px rgba(23, 43, 30, 0.06);
  --radius-lg: 24px;
  --radius-md: 16px;
  --radius-sm: 12px;
  --font: ui-rounded, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --maxw: 1120px;
}

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

html { scroll-behavior: smooth; }

/* Keep anchored headings clear of the sticky nav */
[id] { scroll-margin-top: 84px; }

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--ink);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

/* height:auto is load-bearing: images carry width/height attributes for
   aspect-ratio hints, and without it max-width distorts them. */
img { max-width: 100%; height: auto; display: block; }

a { color: var(--link); text-decoration: none; }
a:hover { text-decoration: underline; }

.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }

/* ---------- Nav ---------- */

.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: saturate(180%) blur(14px);
  -webkit-backdrop-filter: saturate(180%) blur(14px);
  background: rgba(249, 247, 243, 0.82);
  border-bottom: 1px solid var(--stroke);
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
  gap: 16px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  font-size: 19px;
  color: var(--ink);
  letter-spacing: -0.2px;
}
.brand:hover { text-decoration: none; }
.brand svg { width: 34px; height: 34px; }

.nav-links {
  display: flex;
  align-items: center;
  gap: 26px;
  font-size: 15px;
  font-weight: 600;
}
.nav-links a { color: var(--ink-2); }
.nav-links a:hover { color: var(--ink); text-decoration: none; }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-weight: 700;
  font-size: 15px;
  border-radius: 14px;
  padding: 12px 22px;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
  cursor: pointer;
  border: none;
}
.btn:hover { text-decoration: none; transform: translateY(-1px); }
.btn:active { transform: scale(0.98); }

.btn-primary {
  background: var(--green-grad);
  color: #fff;
  box-shadow: 0 8px 20px rgba(19, 133, 74, 0.28);
}
.btn-primary:hover { color: #fff; box-shadow: 0 10px 26px rgba(19, 133, 74, 0.34); }

.btn-quiet {
  background: var(--surface);
  color: var(--ink);
  border: 1.5px solid var(--stroke);
  box-shadow: var(--shadow-soft);
}

.nav-cta { padding: 10px 18px; font-size: 14px; }

@media (max-width: 760px) {
  .nav-links { display: none; }
}

/* ---------- Hero ---------- */

.hero { padding: 72px 0 40px; overflow: hidden; }

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

/* Editorial kicker — a short accent rule + quiet label, not a tinted pill. */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--ink-2);
  margin-bottom: 18px;
}
.eyebrow::before {
  content: "";
  width: 26px;
  height: 2px;
  border-radius: 2px;
  background: var(--green);
}

h1 {
  font-size: clamp(40px, 6vw, 64px);
  line-height: 1.04;
  letter-spacing: -1.5px;
  font-weight: 800;
}

.hero-sub {
  margin: 22px 0 30px;
  font-size: 19px;
  color: var(--ink-2);
  max-width: 34em;
}

.hero-ctas { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }

.store-badge { display: inline-block; transition: transform 0.15s ease; }
.store-badge:hover { transform: translateY(-1px); }
.store-badge svg { height: 52px; width: auto; display: block; }

.coming-soon {
  font-size: 13px;
  font-weight: 600;
  color: var(--ink-3);
  margin-top: 10px;
}

.hero-stats {
  display: flex;
  gap: 28px;
  margin-top: 36px;
  flex-wrap: wrap;
}
.stat b { display: block; font-size: 24px; letter-spacing: -0.5px; }
.stat span { font-size: 13px; color: var(--ink-2); font-weight: 600; }

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

.phone-wrap { position: relative; display: flex; justify-content: center; }

.phone {
  width: min(320px, 78vw);
  border-radius: 48px;
  padding: 12px;
  background: #1c1e21;
  box-shadow: 0 30px 60px rgba(23, 43, 30, 0.25), 0 4px 14px rgba(0, 0, 0, 0.12);
}
.phone img { border-radius: 38px; }

.float-chip {
  position: absolute;
  background: var(--surface);
  border-radius: 16px;
  box-shadow: var(--shadow);
  border: 1px solid var(--stroke);
  padding: 10px 16px;
  font-size: 14px;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 8px;
  animation: floaty 5s ease-in-out infinite;
}
.float-chip .dot { width: 10px; height: 10px; border-radius: 50%; }
.chip-a { top: 36%; left: max(0px, calc(50% - 250px)); animation-delay: 0s; }
.chip-b { bottom: 13%; right: max(0px, calc(50% - 255px)); animation-delay: 2.2s; }

@keyframes floaty {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-8px); }
}

@media (max-width: 880px) {
  .hero { padding-top: 48px; }
  .hero-grid { grid-template-columns: 1fr; gap: 40px; }
  .float-chip { display: none; }
}

/* ---------- Chain strip ---------- */

.chains { padding: 34px 0 10px; }
.chains-track {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  justify-content: center;
}
.chain-pill {
  background: var(--surface);
  border: 1px solid var(--stroke);
  border-radius: 999px;
  padding: 8px 16px;
  font-size: 14px;
  font-weight: 700;
  color: var(--ink-2);
  box-shadow: var(--shadow-soft);
  white-space: nowrap;
}
.chains-note {
  text-align: center;
  font-size: 12px;
  color: var(--ink-3);
  margin-top: 18px;
}

/* ---------- Sections ---------- */

section { padding: 72px 0; }

.section-head { max-width: 640px; margin: 0 auto 48px; text-align: center; }
.section-head .eyebrow { margin-bottom: 14px; }
h2 {
  font-size: clamp(30px, 4.4vw, 42px);
  letter-spacing: -1px;
  line-height: 1.1;
  font-weight: 800;
}
.section-head p { margin-top: 14px; color: var(--ink-2); font-size: 17px; }

/* Steps */
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.step {
  background: var(--surface);
  border-radius: var(--radius-lg);
  border: 1px solid var(--stroke);
  box-shadow: var(--shadow-soft);
  padding: 28px;
}
.step-num {
  width: 42px; height: 42px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  background: var(--green-tint);
  color: var(--green-deep);
  font-weight: 800;
  font-size: 17px;
  margin-bottom: 16px;
}
.step h3 { font-size: 19px; margin-bottom: 8px; letter-spacing: -0.3px; }
.step p { color: var(--ink-2); font-size: 15px; }

@media (max-width: 820px) { .steps { grid-template-columns: 1fr; } }

/* Feature rows */
.feature-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 56px;
  align-items: center;
  padding: 44px 0;
}
.feature-row.flip .feature-copy { order: 2; }
.feature-row.flip .phone-wrap { order: 1; }

.feature-copy h3 {
  font-size: clamp(24px, 3.2vw, 32px);
  letter-spacing: -0.7px;
  line-height: 1.15;
  margin-bottom: 14px;
}
.feature-copy > p { color: var(--ink-2); font-size: 17px; margin-bottom: 20px; }

.check-list { list-style: none; display: grid; gap: 12px; }
.check-list li { display: flex; gap: 12px; align-items: flex-start; font-size: 15.5px; font-weight: 600; }
.check-list .tick {
  flex: none;
  width: 22px; height: 22px;
  border-radius: 50%;
  background: var(--green);
  color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: 12px;
  margin-top: 2px;
}

.feature-row .phone { width: min(290px, 74vw); }

@media (max-width: 880px) {
  .feature-row, .feature-row.flip { grid-template-columns: 1fr; gap: 32px; }
  .feature-row.flip .feature-copy { order: 1; }
  .feature-row.flip .phone-wrap { order: 2; }
}

/* Trust grid */
.trust-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.trust-card {
  background: var(--surface);
  border-radius: var(--radius-lg);
  border: 1px solid var(--stroke);
  box-shadow: var(--shadow-soft);
  padding: 26px;
}
.trust-card .icon {
  width: 46px; height: 46px;
  border-radius: 14px;
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 14px;
  background: var(--green-tint);
  color: #0E7B44;
}
.trust-card .icon svg { width: 22px; height: 22px; }
.trust-card:nth-child(2) .icon { background: var(--orange-tint); color: #C56A1C; }
.trust-card:nth-child(3) .icon { background: rgba(55, 122, 246, 0.12); color: #2E63C9; }
.trust-card:nth-child(4) .icon { background: rgba(156, 90, 229, 0.12); color: #7E45C4; }
.trust-card:nth-child(5) .icon { background: var(--green-tint); color: #0E7B44; }
.trust-card:nth-child(6) .icon { background: var(--orange-tint); color: #C56A1C; }
.trust-card h3 { font-size: 17px; margin-bottom: 6px; letter-spacing: -0.2px; }
.trust-card p { font-size: 14.5px; color: var(--ink-2); }

@media (max-width: 880px) { .trust-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .trust-grid { grid-template-columns: 1fr; } }

/* ---------- Pricing ---------- */

.pricing-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 380px));
  gap: 22px;
  justify-content: center;
  align-items: stretch;
}

.price-card {
  position: relative;
  background: var(--surface);
  border-radius: var(--radius-lg);
  border: 1.5px solid var(--stroke);
  box-shadow: var(--shadow-soft);
  padding: 30px 28px;
  display: flex;
  flex-direction: column;
}
.price-card.best {
  border: 2.5px solid var(--green);
  box-shadow: var(--shadow);
}
.ribbon {
  position: absolute;
  top: -13px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--green-grad);
  color: #fff;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 1.2px;
  padding: 5px 14px;
  border-radius: 999px;
  box-shadow: 0 4px 10px rgba(19, 133, 74, 0.3);
}
.price-card h3 { font-size: 18px; }
.price {
  font-size: 40px;
  font-weight: 800;
  letter-spacing: -1px;
  margin: 8px 0 2px;
}
.price small { font-size: 16px; font-weight: 700; color: var(--ink-2); letter-spacing: 0; }
.price-sub { font-size: 14px; font-weight: 600; color: var(--green-deep); margin-bottom: 18px; }
.price-card ul { list-style: none; display: grid; gap: 10px; font-size: 14.5px; margin-bottom: 22px; }
.price-card ul li { display: flex; gap: 10px; align-items: flex-start; color: var(--ink-2); font-weight: 600; }
.price-card .btn { margin-top: auto; }

.pricing-note {
  text-align: center;
  font-size: 12.5px;
  color: var(--ink-3);
  max-width: 560px;
  margin: 26px auto 0;
}

@media (max-width: 760px) { .pricing-grid { grid-template-columns: minmax(0, 420px); } }

/* ---------- FAQ ---------- */

.faq { max-width: 720px; margin: 0 auto; display: grid; gap: 12px; }
.faq details {
  background: var(--surface);
  border-radius: var(--radius-md);
  border: 1px solid var(--stroke);
  box-shadow: var(--shadow-soft);
  padding: 18px 22px;
}
.faq summary {
  cursor: pointer;
  font-weight: 700;
  font-size: 16px;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+";
  font-size: 22px;
  font-weight: 600;
  color: var(--green);
  transition: transform 0.2s ease;
}
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { margin-top: 12px; color: var(--ink-2); font-size: 15px; }

/* ---------- CTA band ---------- */

.cta-band {
  background: linear-gradient(135deg, #17864A, #0E7B50);
  border-radius: var(--radius-lg);
  color: #fff;
  text-align: center;
  padding: 64px 32px;
  box-shadow: 0 24px 48px rgba(19, 133, 74, 0.25);
}
.cta-band h2 { color: #fff; }
.cta-band p { margin: 14px auto 28px; max-width: 32em; color: rgba(255, 255, 255, 0.92); font-size: 17px; }

/* ---------- Footer ---------- */

footer {
  border-top: 1px solid var(--stroke);
  padding: 48px 0 40px;
  margin-top: 40px;
  font-size: 14px;
  color: var(--ink-2);
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 32px;
  margin-bottom: 32px;
}
.footer-grid h4 {
  font-size: 12px;
  letter-spacing: 1.4px;
  text-transform: uppercase;
  color: var(--ink-3);
  margin-bottom: 12px;
}
.footer-grid ul { list-style: none; display: grid; gap: 8px; }
.footer-grid a { color: var(--ink-2); }
.footer-grid a:hover { color: var(--ink); }
.footer-brand p { margin-top: 10px; max-width: 30em; font-size: 13.5px; }

.legalese {
  border-top: 1px solid var(--stroke);
  padding-top: 24px;
  font-size: 12px;
  color: var(--ink-3);
  display: grid;
  gap: 8px;
}

@media (max-width: 760px) { .footer-grid { grid-template-columns: 1fr; } }

/* ---------- Legal / document pages ---------- */

.doc { max-width: 760px; margin: 0 auto; padding: 56px 24px 72px; }
.doc h1 { font-size: clamp(30px, 4.6vw, 40px); margin-bottom: 8px; }
.doc .updated { color: var(--ink-3); font-size: 14px; font-weight: 600; margin-bottom: 36px; }
.doc h2 { font-size: 21px; letter-spacing: -0.3px; margin: 34px 0 10px; }
.doc p, .doc li { color: #3a3e44; font-size: 16px; }
.doc ul { padding-left: 22px; margin: 10px 0; }
.doc li { margin-bottom: 8px; }
.doc .callout {
  background: var(--green-tint);
  border-radius: var(--radius-md);
  padding: 18px 20px;
  font-weight: 600;
  color: var(--link);
  margin: 20px 0;
  font-size: 15px;
}
.doc .callout.warn { background: var(--orange-tint); color: #9a5314; }

/* Badge legend on the data page */
.badge-row { display: flex; gap: 10px; align-items: flex-start; margin-bottom: 14px; }
.badge-chip {
  flex: none;
  font-size: 12px;
  font-weight: 800;
  padding: 5px 12px;
  border-radius: 999px;
  background: var(--green-tint);
  color: var(--green-deep);
  white-space: nowrap;
  margin-top: 2px;
}
.badge-row p { font-size: 14.5px; }

/* 404 */
.notfound { min-height: 55vh; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 40px 24px; }
.notfound h1 { font-size: 64px; }
.notfound p { color: var(--ink-2); margin: 12px 0 26px; }

@media (prefers-reduced-motion: reduce) {
  .float-chip { animation: none; }
  html { scroll-behavior: auto; }
}
