/* Diet Advice website: one stylesheet for every language.
   Spacing and position use logical properties (inline-start, inline-end), so the same rules lay
   out right-to-left Farsi and left-to-right English. Avoid left/right here.
   Font and line heights are set per language in site.toml (--font, --lh, --lh-heading). */

:root {
  --ink: #1f2d3a;
  --muted: #5b6b78;
  --teal: #1f6f6a;
  --teal-dark: #154f4b;
  --sage: #e7f1ee;
  --cream: #fbf7f0;
  --sand: #f3e9da;
  --rose: #b5545c;
  --line: #dfe7e4;
  --white: #ffffff;
  --radius: 18px;
  --shadow: 0 10px 30px rgba(31, 45, 58, .08);
  --font: system-ui, sans-serif;
  --lh: 1.7;
  --lh-heading: 1.3;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 90px; }
body {
  margin: 0;
  font-family: var(--font);
  color: var(--ink);
  background: var(--cream);
  line-height: var(--lh);
  font-size: 17px;
}
a { color: var(--teal); }
h1, h2, h3 { line-height: var(--lh-heading); }
.wrap { max-width: 1100px; margin: 0 auto; padding: 0 20px; }

.skip {
  position: absolute; inset-inline-start: 12px; top: -80px; z-index: 100;
  background: var(--teal); color: var(--white); padding: 8px 14px; border-radius: 8px;
}
.skip:focus { top: 10px; }

.draft {
  background: #fff4d6; color: #6b5300; text-align: center;
  font-size: 14px; padding: 6px 12px; border-bottom: 1px solid #f0dfa8;
}

/* Header: white, because the logo artwork is on white. */
.site-header {
  position: sticky; top: 0; z-index: 10;
  background: var(--white);
  border-bottom: 1px solid var(--line);
  box-shadow: 0 2px 14px rgba(31, 45, 58, .05);
}
.nav { display: flex; align-items: center; gap: 18px; padding-block: 8px; }
.brand {
  display: flex; align-items: center; gap: 12px; margin-inline-end: auto;
  text-decoration: none; color: var(--muted);
}
.brand img { display: block; height: 56px; width: auto; }
.tagline { font-size: 13.5px; line-height: 1.4; max-width: 15em; text-wrap: balance; }
.links { display: flex; gap: 20px; font-size: 15px; }
.links a { color: var(--ink); text-decoration: none; }
.links a:hover { color: var(--teal); }

/* Language switch: every language by its own name; the current one is filled. */
.lang-switch {
  display: inline-flex; flex: none; padding: 3px;
  border: 1.5px solid var(--line); border-radius: 999px; background: var(--cream);
}
.lang-switch a {
  padding: 4px 12px; border-radius: 999px;
  font-size: 14px; font-weight: 700; line-height: 1.5;
  color: var(--ink); text-decoration: none;
}
.lang-switch a:hover { color: var(--teal); }
.lang-switch a[aria-current] { background: var(--teal); color: var(--white); }
.lang-switch a:lang(fa) { font-family: "Vazirmatn", Tahoma, "Segoe UI", sans-serif; }

.btn {
  display: inline-block; text-decoration: none; font-weight: 700; line-height: 1.5;
  border-radius: 999px; padding: 12px 22px; font-size: 16px;
  transition: transform .15s ease, background .15s ease;
}
.btn:hover { transform: translateY(-1px); }
.btn-primary { background: var(--teal); color: var(--white); }
.btn-primary:hover { background: var(--teal-dark); }
.btn-ghost { border: 1.5px solid var(--teal); color: var(--teal); background: transparent; }
.btn-small { padding: 8px 16px; font-size: 14px; flex: none; }

/* Hero: the soft glow sits behind the start of the headline, so it mirrors with the text. */
.hero {
  position: relative; overflow: hidden; padding: 64px 0 56px;
  background: radial-gradient(1200px 500px at 15% -10%, #dcece7 0%, rgba(220, 236, 231, 0) 60%), var(--cream);
}
[dir="rtl"] .hero {
  background: radial-gradient(1200px 500px at 85% -10%, #dcece7 0%, rgba(220, 236, 231, 0) 60%), var(--cream);
}
.hero::before {
  content: ""; position: absolute; inset: 0; opacity: .07; pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='80' height='80' viewBox='0 0 80 80'%3E%3Cg fill='none' stroke='%231f6f6a' stroke-width='1.4'%3E%3Cpath d='M40 4 L52 28 L76 40 L52 52 L40 76 L28 52 L4 40 L28 28 Z'/%3E%3Ccircle cx='40' cy='40' r='10'/%3E%3C/g%3E%3C/svg%3E");
}
.hero-grid { position: relative; display: grid; grid-template-columns: 1.25fr .75fr; gap: 40px; align-items: center; }
.eyebrow { color: var(--teal); font-weight: 700; font-size: 15px; margin: 0 0 10px; }
h1 { font-size: 44px; margin: 0 0 16px; font-weight: 800; }
.lead { font-size: 19px; color: var(--muted); margin: 0 0 26px; max-width: 34em; }
.cta-row { display: flex; gap: 12px; flex-wrap: wrap; }
.hero-card {
  background: var(--white); border-radius: var(--radius); box-shadow: var(--shadow);
  padding: 26px; border: 1px solid var(--line);
}
.card-title { margin: 0 0 10px; font-size: 18px; }
.ticks { list-style: none; padding: 0; margin: 0; }
.ticks li { position: relative; padding-inline-start: 30px; margin: 10px 0; font-size: 15.5px; }
.ticks li::before {
  content: "✓"; position: absolute; inset-inline-start: 0;
  top: calc((1em * var(--lh) - 22px) / 2);
  width: 22px; height: 22px; border-radius: 50%;
  background: var(--sage); color: var(--teal); font-weight: 800; font-size: 13px;
  display: grid; place-items: center; line-height: 22px; text-align: center;
}

section { padding: 64px 0; }
.alt { background: var(--white); }
h2 { font-size: 32px; margin: 0 0 14px; font-weight: 800; }
.section-lead { color: var(--muted); font-size: 18px; margin: 0 0 30px; max-width: 42em; }

.pains { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }
.pain {
  background: var(--cream); border: 1px solid var(--line); border-radius: 14px;
  padding: 18px 20px; font-size: 16.5px;
}
.reassure {
  margin-top: 26px; background: var(--sage); border-radius: 14px; padding: 18px 22px;
  font-weight: 700; color: var(--teal-dark); font-size: 18px;
}

.about { display: grid; grid-template-columns: .8fr 1.2fr; gap: 40px; align-items: start; }
.portrait {
  aspect-ratio: 4 / 5; border-radius: var(--radius);
  background: linear-gradient(160deg, #d9ebe6, #f3e9da);
  display: grid; place-items: center; color: var(--muted); font-size: 15px; text-align: center;
  border: 1px dashed #b9cfc8;
}
.creds { list-style: none; padding: 0; margin: 18px 0 0; display: grid; gap: 10px; }
.creds li {
  background: var(--cream); border: 1px solid var(--line); border-radius: 12px;
  padding: 10px 14px; font-size: 15.5px;
}
.creds small { color: var(--muted); display: block; font-size: 13.5px; }

.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.card {
  background: var(--white); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 24px; box-shadow: var(--shadow);
}
.card .tag {
  display: inline-block; font-size: 13px; font-weight: 700; color: var(--teal);
  background: var(--sage); border-radius: 999px; padding: 2px 12px; margin-bottom: 10px;
}
.card h3 { margin: 0 0 8px; font-size: 20px; }
.card p { margin: 0; color: var(--muted); font-size: 16px; }
.note { margin-top: 22px; font-size: 15px; color: var(--muted); }

.steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.step { position: relative; background: var(--white); border-radius: var(--radius); padding: 26px 24px 22px; border: 1px solid var(--line); }
.step-num {
  position: absolute; top: -16px; inset-inline-start: 22px;
  width: 36px; height: 36px; border-radius: 50%;
  background: var(--teal); color: var(--white); font-weight: 800; line-height: 1;
  display: grid; place-items: center;
}
.step h3 { margin: 6px 0; font-size: 18px; }
.step p { margin: 0; color: var(--muted); font-size: 15.5px; }
.book-row { margin: 26px 0 0; }

.app { display: grid; grid-template-columns: 1.1fr .9fr; gap: 40px; align-items: center; }
.soon {
  display: inline-block; background: var(--sand); color: #7a5a2b; font-weight: 700;
  font-size: 13px; padding: 3px 12px; border-radius: 999px; margin-bottom: 10px;
}
.notify-row { margin: 20px 0 0; }
.phone { width: 260px; margin: 0 auto; border-radius: 38px; padding: 14px; background: #1f2d3a; box-shadow: var(--shadow); }
.screen { background: var(--cream); border-radius: 28px; padding: 18px 14px; min-height: 440px; }
.screen .title { text-align: center; font-weight: 800; font-size: 14px; color: var(--teal); margin-bottom: 6px; }
/* The parent's own message sits at the end side, replies at the start side, as in chat apps. */
.bubble { border-radius: 16px; padding: 10px 12px; font-size: 13.5px; margin: 10px 0; line-height: 1.7; }
.bubble.user { background: var(--white); border: 1px solid var(--line); margin-inline-start: 30px; }
.bubble.bot { background: var(--sage); color: var(--teal-dark); margin-inline-end: 30px; }
.bubble.safe { background: #fff1ef; color: #7a2f35; border: 1px solid #f2cfcb; margin-inline-end: 30px; }

details { background: var(--white); border: 1px solid var(--line); border-radius: 14px; padding: 14px 18px; margin: 12px 0; }
.alt details { background: var(--cream); }
summary { cursor: pointer; font-weight: 700; font-size: 17px; }
details p { margin: 10px 0 2px; color: var(--muted); font-size: 16px; }

.help { background: #fff6f4; border: 1.5px solid #f0c9c4; border-radius: var(--radius); padding: 24px 26px; }
.help h2 { font-size: 24px; color: var(--rose); }
.help ul { margin: 6px 0 0; padding-inline-start: 20px; }
.help li { margin: 6px 0; }
.num { font-weight: 800; color: var(--ink); white-space: nowrap; text-underline-offset: 3px; }

.final {
  background: linear-gradient(135deg, var(--teal), var(--teal-dark)); color: var(--white);
  border-radius: 24px; padding: 40px; text-align: center;
}
.final h2 { color: var(--white); }
.final p { color: #dbeeea; font-size: 18px; margin: 0 0 22px; }
.final .btn-primary { background: var(--white); color: var(--teal-dark); }

.site-footer { padding: 34px 0 50px; color: var(--muted); font-size: 14px; }
.site-footer .row { display: flex; justify-content: space-between; gap: 20px; flex-wrap: wrap; border-top: 1px solid var(--line); padding-top: 22px; }
.disclaimer { margin: 0; max-width: 34em; }

@media (max-width: 1180px) {
  .tagline { display: none; }
}
@media (max-width: 900px) {
  .links { display: none; }
  .hero-grid, .about, .app { grid-template-columns: 1fr; }
  .cards, .steps, .pains { grid-template-columns: 1fr; }
  h1 { font-size: 32px; }
  h2 { font-size: 26px; }
  .steps { gap: 30px; }
  .portrait { max-width: 320px; }
}
@media (max-width: 520px) {
  .header-cta { display: none; }
  .brand img { height: 46px; }
  .final { padding: 30px 22px; }
}
