/* ForeGoals — shared stylesheet for the static site.
   Mirrors the brand system from the old Flutter build: same palette,
   same spacing scale, same component shapes. No JS-driven layout —
   everything here is flexbox/grid + media queries. */

:root {
  --green: #12b76a;
  --dark-green: #0d5c3d;
  --seed: #0fb972;
  --bg: #f6f9f7;
  --text: #0f0f0f;
  --text-70: rgba(0, 0, 0, 0.7);
  --text-55: rgba(0, 0, 0, 0.55);
  --text-50: rgba(0, 0, 0, 0.5);
  --amber: #b54708;
  --radius-lg: 28px;
  --radius-md: 20px;
  --radius-sm: 12px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
    "Helvetica Neue", Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

p,
h1,
h2,
h3,
li,
span {
  overflow-wrap: break-word;
}

a {
  color: inherit;
}

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

.wrap {
  max-width: 1100px;
  width: 92%;
  margin: 0 auto;
  padding: 32px 0;
}

@media (min-width: 1200px) {
  .wrap {
    width: 1100px;
  }
}

/* ── Typography ─────────────────────────────────────────────────────── */

h1,
h2,
h3 {
  margin: 0;
  font-weight: 800;
  color: var(--dark-green);
  line-height: 1.2;
}

h1 {
  font-size: 2.1rem;
}

h2 {
  font-size: 1.7rem;
}

h3 {
  font-size: 1.25rem;
}

p {
  margin: 0;
}

.lede {
  font-size: 1.05rem;
  color: var(--text-70);
  line-height: 1.55;
}

.muted {
  color: var(--text-55);
}

.eyebrow {
  display: block;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 1.1px;
  color: var(--green);
  text-transform: uppercase;
  margin-bottom: 8px;
}

.section {
  margin-top: 56px;
}

.section-header {
  margin-bottom: 20px;
}

/* ── Brand mark ──────────────────────────────────────────────────────── */

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
}

.brand img {
  width: 40px;
  height: 40px;
  border-radius: 12px;
}

.brand span {
  font-weight: 800;
  font-size: 1.15rem;
  color: var(--dark-green);
}

/* ── Buttons ─────────────────────────────────────────────────────────── */

.btn-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 22px;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 20px;
  border-radius: 10px;
  font-weight: 700;
  font-size: 0.95rem;
  text-decoration: none;
  border: 2px solid transparent;
  cursor: pointer;
  white-space: nowrap;
}

.btn-filled {
  background: var(--green);
  color: #fff;
}

.btn-filled:hover {
  background: #0fa05e;
}

.btn-outline {
  background: transparent;
  color: var(--dark-green);
  border-color: var(--green);
}

.btn-outline:hover {
  background: rgba(18, 183, 106, 0.08);
}

.btn svg {
  width: 20px;
  height: 20px;
  flex: none;
}

/* ── Hero ────────────────────────────────────────────────────────────── */

.hero {
  padding: 24px;
  border-radius: var(--radius-lg);
  background: linear-gradient(180deg, #e9fbf1, #dff7ec);
  display: flex;
  gap: 24px;
  align-items: center;
  justify-content: space-between;
}

.hero-copy {
  flex: 3 1 420px;
  min-width: 0;
}

.hero-image {
  flex: 2 1 220px;
  min-width: 0;
  display: flex;
  justify-content: center;
}

.hero h1 {
  font-size: 2.3rem;
  margin: 20px 0 14px;
}

.hero .lede {
  margin-bottom: 8px;
}

.hero .no-sensors {
  font-style: italic;
  color: var(--text-55);
  font-size: 0.95rem;
}

.hero .brand-philosophy {
  margin-top: 16px;
  color: var(--dark-green);
  font-weight: 600;
}

@media (max-width: 819px) {
  .hero {
    flex-direction: column;
    align-items: stretch;
  }
  .hero h1 {
    font-size: 1.8rem;
  }
}

/* ── Three benefits ──────────────────────────────────────────────────── */

.benefit-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
}

.benefit-card {
  flex: 1 1 280px;
  min-width: 0;
  background: #fff;
  border-radius: 16px;
  padding: 18px;
}

.benefit-card svg {
  width: 26px;
  height: 26px;
  color: var(--green);
  margin-bottom: 10px;
}

.benefit-card h3 {
  margin-bottom: 8px;
}

.benefit-card p {
  color: var(--text-70);
  line-height: 1.4;
}

/* ── Split section (copy + phone, alternating sides) ────────────────── */

.split {
  display: flex;
  align-items: center;
  gap: 40px;
}

.split.image-left {
  flex-direction: row;
}

.split.image-right {
  flex-direction: row-reverse;
}

.split-copy {
  flex: 5 1 420px;
  min-width: 0;
}

.split-copy h2 {
  margin-bottom: 14px;
}

.split-copy p {
  color: var(--text-70);
  margin-bottom: 10px;
}

.split-image {
  flex: none;
  display: flex;
  justify-content: center;
}

@media (max-width: 819px) {
  .split,
  .split.image-left,
  .split.image-right {
    flex-direction: column;
  }
  .split-image {
    order: -1;
  }
}

/* ── Phone frame ─────────────────────────────────────────────────────── */

.phone-frame {
  position: relative;
  background: #0f0f0f;
  border-radius: 36px;
  padding: 8px;
  width: 240px;
  max-width: 100%;
  box-shadow: 0 16px 30px rgba(0, 0, 0, 0.18);
  flex: none;
}

.phone-frame.phone-frame--big {
  width: 300px;
  max-width: 100%;
}

.phone-frame.phone-frame--small {
  width: 200px;
  max-width: 100%;
}

.phone-frame img,
.phone-frame video {
  border-radius: 28px;
  width: 100%;
  display: block;
}

.phone-frame::before {
  content: "";
  position: absolute;
  top: 18px;
  left: 50%;
  transform: translateX(-50%);
  width: 32%;
  height: 22px;
  background: #0f0f0f;
  border-radius: 14px;
  z-index: 1;
}

.phone-badge {
  position: absolute;
  top: 4px;
  right: -8px;
  background: #fff;
  border-radius: 20px;
  padding: 6px 10px;
  font-size: 0.75rem;
  font-weight: 800;
  color: var(--dark-green);
  display: flex;
  align-items: center;
  gap: 4px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
  z-index: 2;
}

.phone-badge svg {
  width: 14px;
  height: 14px;
}

/* ── Generic content card ───────────────────────────────────────────── */

.panel {
  background: #fff;
  border-radius: 24px;
  padding: 28px;
}

.panel-dark {
  background: var(--dark-green);
  color: #fff;
}

.callout {
  border: 1px solid rgba(18, 183, 106, 0.3);
  border-radius: 14px;
  padding: 16px;
  background: #fff;
}

.callout .label {
  display: block;
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--text-55);
  margin-bottom: 4px;
}

.callout .big {
  font-size: 1.4rem;
  font-weight: 800;
  color: var(--dark-green);
}

.callout .note {
  margin-top: 10px;
  font-style: italic;
  color: var(--text-70);
  line-height: 1.4;
}

/* ── Tracking model list ─────────────────────────────────────────────── */

.track-list {
  list-style: none;
  margin: 0 0 16px;
  padding: 0;
}

.track-list li {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 14px;
}

.track-list .dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--green);
  margin-top: 7px;
  flex: none;
}

.track-list strong {
  color: var(--text);
}

.track-list span {
  color: var(--text-70);
}

.timer-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--dark-green);
  color: #fff;
  font-weight: 700;
  border-radius: 12px;
  padding: 10px 14px;
}

.timer-chip svg {
  width: 20px;
  height: 20px;
}

/* ── Question framework ─────────────────────────────────────────────── */

.quote-block {
  background: var(--bg);
  border-radius: 12px;
  padding: 14px;
  font-style: italic;
  color: var(--text-55);
  margin: 18px 0;
}

.big-question {
  font-size: 1.7rem;
  font-weight: 900;
  color: var(--dark-green);
  margin: 0 0 6px;
}

.chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 22px;
}

.chip {
  background: rgba(18, 183, 106, 0.1);
  border: 1px solid rgba(18, 183, 106, 0.3);
  color: var(--dark-green);
  font-weight: 700;
  border-radius: 999px;
  padding: 8px 16px;
  font-size: 0.9rem;
}

/* ── Flow (goal -> forethought) ─────────────────────────────────────── */

.flow {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}

.flow-step {
  min-width: 240px;
  text-align: center;
  padding: 12px 22px;
  border-radius: 14px;
  border: 1px solid;
}

.flow-step .flow-label {
  display: block;
  font-size: 0.8rem;
  font-weight: 800;
  letter-spacing: 1px;
}

.flow-step .flow-value {
  font-size: 1.3rem;
  font-weight: 800;
  color: var(--text);
}

.flow-arrow {
  color: rgba(0, 0, 0, 0.25);
  margin: 2px 0;
}

/* ── AI coach card ───────────────────────────────────────────────────── */

.coach-card {
  border: 1px solid rgba(18, 183, 106, 0.3);
}

.coach-card .coach-title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 800;
  color: var(--dark-green);
  margin-bottom: 14px;
}

.coach-card .coach-title svg {
  width: 22px;
  height: 22px;
}

.coach-card .label-hard-truth {
  color: var(--amber);
}

.coach-card .coach-label {
  display: block;
  font-weight: 800;
  letter-spacing: 1px;
  font-size: 0.85rem;
  margin-bottom: 6px;
}

.coach-card p {
  color: rgba(0, 0, 0, 0.8);
  line-height: 1.6;
  margin-bottom: 14px;
}

/* ── Improvement loop ────────────────────────────────────────────────── */

.loop-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}

.loop-card {
  width: 190px;
  background: #fff;
  border-radius: 16px;
  padding: 16px;
}

.loop-card .loop-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}

.loop-card .loop-index {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: rgba(18, 183, 106, 0.12);
  color: var(--dark-green);
  font-weight: 800;
  font-size: 0.8rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

.loop-card svg {
  width: 20px;
  height: 20px;
  color: var(--green);
}

.loop-card h3 {
  font-size: 1rem;
  margin-bottom: 6px;
}

.loop-card p {
  font-size: 0.85rem;
  color: rgba(0, 0, 0, 0.65);
  line-height: 1.35;
}

.loop-arrow {
  color: rgba(0, 0, 0, 0.2);
  flex: none;
}

.loop-note {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 12px;
  color: var(--text-55);
  font-style: italic;
}

.loop-note svg {
  width: 22px;
  height: 22px;
  color: var(--green);
  flex: none;
}

@media (max-width: 899px) {
  .loop-row {
    flex-direction: column;
    align-items: stretch;
  }
  .loop-card {
    width: auto;
  }
  .loop-arrow {
    align-self: center;
    transform: rotate(90deg);
  }
}

/* ── Pricing ─────────────────────────────────────────────────────────── */

.tier-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin-top: 18px;
}

.tier-card {
  width: 320px;
  border-radius: 20px;
  padding: 22px;
  background: #fff;
  border: 1px solid rgba(0, 0, 0, 0.08);
}

.tier-card.tier-highlight {
  background: var(--dark-green);
  color: #fff;
  border: none;
}

.tier-card h3 {
  font-size: 1.1rem;
  margin-bottom: 10px;
}

.tier-card.tier-highlight h3 {
  color: #fff;
}

.tier-price {
  font-size: 1.9rem;
  font-weight: 900;
  color: var(--dark-green);
}

.tier-highlight .tier-price {
  color: #fff;
}

.tier-period {
  font-size: 1rem;
  font-weight: 600;
  color: rgba(0, 0, 0, 0.6);
}

.tier-highlight .tier-period {
  color: rgba(255, 255, 255, 0.8);
}

.tier-tagline {
  display: block;
  margin: 8px 0 16px;
  color: rgba(0, 0, 0, 0.7);
  line-height: 1.4;
}

.tier-highlight .tier-tagline {
  color: rgba(255, 255, 255, 0.9);
}

.tier-card ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

.tier-card li {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  margin-bottom: 8px;
  color: rgba(0, 0, 0, 0.75);
}

.tier-highlight li {
  color: rgba(255, 255, 255, 0.9);
}

.tier-card li svg {
  width: 18px;
  height: 18px;
  color: var(--green);
  flex: none;
  margin-top: 1px;
}

.tier-highlight li svg {
  color: #fff;
}

/* ── Final CTA ───────────────────────────────────────────────────────── */

.final-cta {
  padding: 28px;
  border-radius: var(--radius-lg);
  background: linear-gradient(180deg, #e9fbf1, #dff7ec);
  text-align: center;
}

.final-cta .lede {
  margin: 8px auto 0;
  max-width: 520px;
}

.final-cta .btn-row {
  justify-content: center;
}

.store-row {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  justify-content: center;
  margin-top: 20px;
}

.store-btn {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  background: #000;
  color: #fff;
  border: 1px solid #fff;
  border-radius: 8px;
  padding: 12px 24px;
  text-decoration: none;
}

.store-btn svg {
  width: 32px;
  height: 32px;
}

.store-btn span {
  font-size: 0.85rem;
  font-weight: 600;
  line-height: 1.2;
  white-space: pre-line;
}

.qr-card {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  margin-top: 28px;
  padding: 16px 20px;
  background: #fff;
  border-radius: var(--radius-md);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.08);
}

.qr-card img {
  display: block;
  width: 120px;
  height: 120px;
}

.qr-card span {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--dark-green);
}

/* QR codes are for someone already on a phone browser to scan with a
   second device — not useful to someone already browsing on mobile. */
@media (max-width: 820px) {
  .qr-card {
    display: none;
  }
}

/* ── Footer ──────────────────────────────────────────────────────────── */

footer {
  margin: 24px 0 40px;
  text-align: center;
}

footer a {
  color: var(--text-55);
  text-decoration: underline;
}

footer .dot {
  color: var(--text-55);
  margin: 0 6px;
}

/* ── Simple content pages (FAQ, Support, Privacy, Terms) ───────────────── */

.page-header {
  background: #fff;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
  padding: 20px 0;
  margin-bottom: 8px;
}

.page-header .wrap {
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.page-header .back-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--dark-green);
  text-decoration: none;
  font-weight: 700;
}

.page-title {
  margin-top: 16px;
}

.page-subtitle {
  margin-top: 8px;
  color: var(--text-70);
}

.updated {
  margin-top: 8px;
  font-style: italic;
  color: var(--text-55);
  font-size: 0.9rem;
}

.faq-section-title {
  margin: 28px 0 16px;
}

.faq-item {
  margin-bottom: 24px;
}

.faq-item h3 {
  font-size: 1.05rem;
  margin-bottom: 8px;
}

.faq-item p {
  color: rgba(0, 0, 0, 0.8);
  line-height: 1.6;
  white-space: pre-line;
}

.legal-section {
  margin-bottom: 20px;
}

.legal-section h2 {
  font-size: 1.3rem;
  margin-bottom: 8px;
}

.legal-section > p {
  color: rgba(0, 0, 0, 0.75);
  line-height: 1.6;
  white-space: pre-line;
  margin-bottom: 16px;
}

.legal-sub {
  margin-bottom: 16px;
}

.legal-sub h3 {
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 6px;
}

.legal-sub p {
  color: rgba(0, 0, 0, 0.75);
  line-height: 1.6;
  white-space: pre-line;
}

.info-box {
  display: flex;
  align-items: center;
  gap: 12px;
  background: rgba(15, 185, 114, 0.08);
  border-radius: 12px;
  padding: 16px;
  margin-top: 24px;
  color: var(--dark-green);
}

.info-box svg {
  width: 24px;
  height: 24px;
  flex: none;
}

.help-card {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  background: #fff;
  border: 1px solid #e0e5e1;
  border-radius: 12px;
  padding: 16px;
  margin-bottom: 16px;
  box-shadow: 0 6px 14px rgba(0, 0, 0, 0.04);
}

.help-card .icon-circle {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: rgba(15, 185, 114, 0.12);
  display: flex;
  align-items: center;
  justify-content: center;
  flex: none;
}

.help-card .icon-circle svg {
  width: 20px;
  height: 20px;
  color: var(--dark-green);
}

.help-card h3 {
  font-size: 1.05rem;
  margin-bottom: 6px;
}

.help-card p {
  color: rgba(0, 0, 0, 0.78);
  line-height: 1.55;
}

.contact-card {
  background: rgba(15, 185, 114, 0.08);
  border: 1px solid rgba(15, 185, 114, 0.3);
  border-radius: 12px;
  padding: 16px;
}

.contact-card .contact-title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
  color: var(--dark-green);
  margin-bottom: 8px;
}

.contact-card .email-box {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #fff;
  border: 1px solid #e0e5e1;
  border-radius: 10px;
  padding: 10px 12px;
  margin-top: 12px;
  font-weight: 600;
  color: var(--dark-green);
  text-decoration: none;
}

.tip-box {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  background: #e9fbf1;
  border-radius: 12px;
  padding: 16px;
  margin-top: 32px;
}

.tip-box svg {
  width: 22px;
  height: 22px;
  color: var(--dark-green);
  flex: none;
}

.quick-links {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 28px;
}

/* ── Compare page ────────────────────────────────────────────────────── */

.job-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 12px;
  margin-top: 16px;
}

.job-card {
  background: #fff;
  border: 1px solid #e0e5e1;
  border-radius: var(--radius-sm);
  padding: 16px;
}

.job-card.job-foregoals {
  border-color: rgba(18, 183, 106, 0.6);
  background: #e9fbf1;
}

.job-card .job-need {
  display: block;
  font-size: 0.85rem;
  color: var(--text-55);
  font-weight: 600;
}

.job-card .job-app {
  display: block;
  margin-top: 4px;
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--dark-green);
}

.compare-table {
  width: 100%;
  margin-top: 16px;
  border-collapse: collapse;
  background: #fff;
  border-radius: var(--radius-sm);
  overflow: hidden;
  font-size: 0.92rem;
}

.compare-table th,
.compare-table td {
  padding: 12px;
  text-align: left;
  vertical-align: top;
  border-bottom: 1px solid #e0e5e1;
}

.compare-table thead th {
  background: var(--dark-green);
  color: #fff;
}

.compare-table tbody th {
  width: 15%;
  font-weight: 700;
}

.compare-table .col-foregoals {
  background: #e9fbf1;
  font-weight: 600;
}

.compare-table thead .col-foregoals {
  background: var(--green);
}

.compare-table tbody tr:last-child th,
.compare-table tbody tr:last-child td {
  border-bottom: none;
}

.compare-note {
  margin-top: 12px;
  font-size: 0.85rem;
  color: var(--text-55);
}

.vs-section {
  margin: 20px 0 28px;
}

.vs-section h3 {
  font-size: 1.2rem;
  margin-bottom: 8px;
}

.vs-section p {
  color: rgba(0, 0, 0, 0.8);
  line-height: 1.6;
  margin: 0 0 10px;
}

.vs-section .verdict {
  font-weight: 700;
  color: var(--dark-green);
}

.plain-list {
  margin: 12px 0 0;
  padding-left: 20px;
  line-height: 1.6;
  color: rgba(0, 0, 0, 0.8);
}

.plain-list li {
  margin-bottom: 6px;
}

@media (max-width: 819px) {
  .compare-table,
  .compare-table tbody,
  .compare-table tr,
  .compare-table th,
  .compare-table td {
    display: block;
    width: 100%;
  }

  .compare-table {
    background: none;
    border-radius: 0;
    overflow: visible;
  }

  .compare-table thead {
    display: none;
  }

  .compare-table tbody tr {
    background: #fff;
    border: 1px solid #e0e5e1;
    border-radius: var(--radius-sm);
    margin-bottom: 14px;
    overflow: hidden;
  }

  .compare-table tbody th {
    width: 100%;
    background: var(--dark-green);
    color: #fff;
  }

  .compare-table td::before {
    content: attr(data-app);
    display: block;
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--text-55);
    text-transform: uppercase;
    letter-spacing: 0.04em;
  }

  .compare-table tbody tr td:last-child {
    border-bottom: none;
  }

  .compare-table td.cell-none {
    display: none;
  }
}
