/*
 * bodyfitstudio.app — one stylesheet for every page.
 *
 * Deliberately self-contained: no web fonts, no CDN, no analytics. The privacy policy
 * says there is no tracking on our surfaces, and loading a font from someone else's
 * server would quietly make that untrue.
 *
 * Palette is the app's own (indigo → violet), and the site follows the visitor's
 * light/dark preference the way the app follows the phone's.
 */

:root {
  color-scheme: light dark;
  --bg: #f6f7fb;
  --surface: #ffffff;
  --surface-2: #f1f3f9;
  --text: #12141a;
  --text-2: #4d5566;
  --muted: #7b8494;
  --line: #e4e7ef;
  --brand: #4648d4;
  --brand-2: #6b38d4;
  --brand-tint: #eeeeff;
  --ok: #0f7a4d;
  --danger: #b3261e;
  --radius: 16px;
  --shadow: 0 1px 2px rgba(16, 20, 40, .04), 0 12px 32px rgba(16, 20, 40, .06);
  --max: 1080px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0d0f13;
    --surface: #15181e;
    --surface-2: #1b1f26;
    --text: #eef1f5;
    --text-2: #aab1bd;
    --muted: #7e8593;
    --line: #252a33;
    --brand: #8f91ff;
    --brand-2: #c0a8ff;
    --brand-tint: #1c1e33;
    --ok: #6ddba4;
    --danger: #ffb4ab;
    --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 12px 32px rgba(0, 0, 0, .3);
  }
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 16px/1.65 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 { margin: 0; font-weight: 680; letter-spacing: -0.025em; line-height: 1.18; }
h1 { font-size: clamp(30px, 5vw, 46px); }
h2 { font-size: clamp(22px, 3vw, 28px); }
h3 { font-size: 17px; letter-spacing: -0.01em; }
p { margin: 0 0 16px; color: var(--text-2); }
a { color: var(--brand); text-decoration-thickness: 1px; text-underline-offset: 2px; }
img { max-width: 100%; }
code { font: 13.5px/1.5 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; background: var(--surface-2); padding: 2px 6px; border-radius: 6px; }

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

/* ── Header ─────────────────────────────────────────────────────────────── */
header.site {
  position: sticky; top: 0; z-index: 10;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: saturate(160%) blur(12px);
  border-bottom: 1px solid var(--line);
}
header.site .bar { display: flex; align-items: center; gap: 14px; padding: 14px 24px; max-width: var(--max); margin: 0 auto; }
header.site .brand { display: flex; align-items: center; gap: 10px; font-weight: 680; letter-spacing: -0.02em; text-decoration: none; color: var(--text); }
header.site .brand img { width: 32px; height: 32px; border-radius: 9px; }
header.site nav { margin-left: auto; display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
header.site nav a { color: var(--text-2); text-decoration: none; font-size: 14.5px; font-weight: 550; padding: 8px 12px; border-radius: 999px; }
header.site nav a:hover { background: var(--surface-2); color: var(--text); }
header.site nav a[aria-current="page"] { color: var(--brand); background: var(--brand-tint); }

/* ── Buttons ────────────────────────────────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 9px;
  background: linear-gradient(135deg, var(--brand), var(--brand-2)); color: #fff;
  border: 1px solid transparent; border-radius: 999px; padding: 13px 24px;
  font-size: 15px; font-weight: 620; text-decoration: none; cursor: pointer;
}
.btn:hover { filter: brightness(1.08); }
.btn.secondary { background: var(--surface); color: var(--text); border-color: var(--line); }
.btn.secondary:hover { background: var(--surface-2); filter: none; }
.btn.danger { background: var(--danger); }
.btn[disabled] { opacity: .55; cursor: not-allowed; filter: none; }

/* ── Hero ───────────────────────────────────────────────────────────────── */
.hero { padding: 72px 0 64px; }
.hero .grid { display: grid; grid-template-columns: 1.05fr .95fr; gap: 48px; align-items: center; }
.kicker {
  display: inline-block; font-size: 12px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase;
  color: var(--brand); background: var(--brand-tint); padding: 6px 12px; border-radius: 999px; margin-bottom: 18px;
}
.hero p.lede { font-size: 18px; max-width: 52ch; margin-bottom: 26px; }
.hero .cta { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; }
.hero .shot {
  border-radius: 24px; overflow: hidden; box-shadow: var(--shadow);
  border: 1px solid var(--line); aspect-ratio: 4 / 5; object-fit: cover; width: 100%;
}

/* ── Sections ───────────────────────────────────────────────────────────── */
section { padding: 56px 0; }
section.tint { background: var(--surface); border-block: 1px solid var(--line); }
.section-head { max-width: 62ch; margin-bottom: 34px; }
.section-head p { margin-bottom: 0; }

.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 18px; }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; box-shadow: var(--shadow); }
section.tint .card { background: var(--bg); }
.card .ico {
  width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center; margin-bottom: 14px;
  background: var(--brand-tint); color: var(--brand);
}
.card .ico svg { width: 21px; height: 21px; }
.card p { margin: 8px 0 0; font-size: 14.5px; }

.steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 18px; counter-reset: step; }
.step { position: relative; padding-left: 46px; }
.step::before {
  counter-increment: step; content: counter(step);
  position: absolute; left: 0; top: 0; width: 32px; height: 32px; border-radius: 50%;
  display: grid; place-items: center; font-size: 14px; font-weight: 680; color: #fff;
  background: linear-gradient(135deg, var(--brand), var(--brand-2));
}
.step p { margin: 6px 0 0; font-size: 14.5px; }

/* ── Legal + long-form pages ────────────────────────────────────────────── */
.doc { padding: 52px 0 72px; }
.doc .meta { color: var(--muted); font-size: 14px; margin-bottom: 26px; }
.doc .intro { font-size: 17px; color: var(--text-2); border-left: 3px solid var(--brand); padding-left: 18px; margin-bottom: 34px; }
.doc article { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 8px 28px 24px; box-shadow: var(--shadow); }
.doc h2 { font-size: 18px; margin: 28px 0 8px; scroll-margin-top: 90px; }
.doc h2 .n { color: var(--brand); font-variant-numeric: tabular-nums; margin-right: 8px; }
.doc p { margin-bottom: 0; }
.toc { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 28px; }
.toc a { font-size: 13px; color: var(--text-2); text-decoration: none; background: var(--surface); border: 1px solid var(--line); padding: 6px 12px; border-radius: 999px; }
.toc a:hover { border-color: var(--brand); color: var(--brand); }

/* ── Forms / panels ─────────────────────────────────────────────────────── */
.panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; box-shadow: var(--shadow); }
.panel + .panel { margin-top: 18px; }
.panel h2 { font-size: 19px; margin-bottom: 10px; }
label.field { display: block; font-size: 14px; font-weight: 600; margin: 18px 0 6px; }
input[type="email"], input[type="text"], textarea {
  width: 100%; font: inherit; color: inherit; background: var(--bg);
  border: 1px solid var(--line); border-radius: 10px; padding: 12px 14px;
}
input:focus-visible, textarea:focus-visible, a:focus-visible, button:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; }
.note { font-size: 13.5px; color: var(--muted); }
.callout { background: var(--brand-tint); border-radius: 12px; padding: 16px 18px; font-size: 14.5px; color: var(--text-2); }
.callout strong { color: var(--text); }

/* ── Packs (buy page) ───────────────────────────────────────────────────── */
.packs { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 16px; margin-top: 22px; }
.pack { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; text-align: center; position: relative; }
.pack.best { border-color: var(--brand); box-shadow: 0 0 0 3px var(--brand-tint); }
.pack .tag { position: absolute; top: -11px; left: 50%; transform: translateX(-50%); background: linear-gradient(135deg, var(--brand), var(--brand-2)); color: #fff; font-size: 11px; font-weight: 700; letter-spacing: .04em; padding: 4px 12px; border-radius: 999px; }
.pack .n { font-size: 32px; font-weight: 680; letter-spacing: -0.03em; }
.pack .u { font-size: 13.5px; color: var(--muted); }
.pack .p { font-size: 19px; font-weight: 640; margin: 12px 0 2px; }
.pack .each { font-size: 12.5px; color: var(--muted); margin-bottom: 16px; }
.pack .btn { width: 100%; padding: 11px 16px; font-size: 14.5px; }

/* ── Result pages (payment done / cancelled) ────────────────────────────── */
.result { min-height: 78vh; display: grid; place-items: center; padding: 40px 24px; }
.result .box { max-width: 460px; text-align: center; }
.result .mark { width: 76px; height: 76px; border-radius: 50%; display: grid; place-items: center; margin: 0 auto 22px; background: var(--brand-tint); color: var(--brand); }
.result .mark svg { width: 36px; height: 36px; }
.result .mark.ok { background: color-mix(in srgb, var(--ok) 15%, transparent); color: var(--ok); }

/* ── Footer ─────────────────────────────────────────────────────────────── */
footer.site { border-top: 1px solid var(--line); padding: 40px 0 56px; margin-top: 24px; }
footer.site .cols { display: flex; gap: 32px; flex-wrap: wrap; align-items: flex-start; }
footer.site .cols > div { min-width: 160px; }
footer.site h4 { font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); margin: 0 0 10px; }
footer.site a { display: block; color: var(--text-2); text-decoration: none; font-size: 14.5px; padding: 3px 0; }
footer.site a:hover { color: var(--brand); }
footer.site .fine { margin-top: 32px; font-size: 13px; color: var(--muted); }

@media (max-width: 860px) {
  .hero { padding: 44px 0 40px; }
  .hero .grid { grid-template-columns: 1fr; gap: 32px; }
  .hero .shot { max-width: 380px; }
  section { padding: 44px 0; }
  header.site nav a { padding: 7px 9px; font-size: 14px; }
  .doc article { padding: 8px 20px 20px; }
}
