/* ==========================================================================
   e-Shajara — public site (landing, open tree & person pages, share pages)
   Warm paper, deep forest green, one gold accent. Fraunces for display,
   Manrope for everything else. Light only: these are marketing pages.
   ========================================================================== */

:root {
  --ink: #0d3d26;
  --ink-2: #13502f;
  --ink-3: #1c6a3f;
  --paper: #f8fbf4;
  --paper-2: #edf5e8;
  --white: #ffffff;
  --text: #1c2a25;
  --muted: #5d6b65;
  --line: #dfe8d4;
  --line-soft: #e8f0de;
  --gold: #c99a2e;
  --gold-bright: #e9c869;
  --gold-soft: #f6ecd0;
  --sage: #e0f0e3;
  --female: #b46a58;
  --radius: 20px;
  --radius-sm: 12px;
  --shadow-sm: 0 1px 2px rgba(13, 61, 38, 0.06), 0 2px 8px rgba(13, 61, 38, 0.05);
  --shadow: 0 2px 4px rgba(13, 61, 38, 0.05), 0 18px 40px -18px rgba(13, 61, 38, 0.28);
  --shadow-lg: 0 30px 80px -30px rgba(13, 61, 38, 0.45);
  --display: "Fraunces", Georgia, "Times New Roman", serif;
  --sans: "Manrope", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body.site { margin: 0; background: var(--paper); color: var(--text); font-family: var(--sans); font-size: 16px;
  line-height: 1.6; -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; }
:where(.site) img { max-width: 100%; height: auto; }
:where(.site) a { color: inherit; }
:where(.site) :is(h1, h2, h3, p) { margin: 0; }
:where(.site) svg { display: block; }
.wrap { width: 100%; max-width: 1200px; margin: 0 auto; padding-inline: 24px; }
.skip { position: absolute; left: -999px; top: 8px; z-index: 100; padding: 10px 16px; border-radius: 10px; background: var(--ink); color: #fff; }
.skip:focus { left: 16px; }
:focus-visible { outline: 3px solid var(--gold-bright); outline-offset: 3px; border-radius: 6px; }

/* ------------------------------------------------------------------ type */
.display { font-family: var(--display); font-weight: 600; font-size: clamp(2.4rem, 5.2vw, 4.1rem); line-height: 1.04;
  letter-spacing: -0.025em; color: var(--ink); font-variation-settings: "opsz" 144; }
.display em { font-style: italic; font-weight: 500; color: var(--gold); }
.display-sm { font-size: clamp(2rem, 4vw, 3.1rem); }
.h2 { font-family: var(--display); font-weight: 600; font-size: clamp(1.9rem, 3.4vw, 2.75rem); line-height: 1.1;
  letter-spacing: -0.02em; color: var(--ink); }
.h2-light { color: #f7f1e3; }
.h3 { font-family: var(--display); font-weight: 600; font-size: 1.45rem; line-height: 1.2; color: var(--ink); letter-spacing: -0.01em; }
.lead { font-size: 1.13rem; line-height: 1.7; color: var(--muted); max-width: 62ch; }
.lead-light { color: #c3d3ca; }
.lead-tight { margin-top: 6px; }
.eyebrow { display: inline-flex; align-items: center; gap: 9px; font-size: 0.8rem; font-weight: 700; letter-spacing: 0.12em;
  text-transform: uppercase; color: var(--gold); margin-bottom: 16px; }
.eyebrow a { color: inherit; text-decoration: none; border-bottom: 1px solid currentColor; }
.eyebrow-light { color: var(--gold-bright); }
.eyebrow-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--gold); box-shadow: 0 0 0 4px var(--gold-soft); }

/* --------------------------------------------------------------- buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; font: 700 0.98rem/1 var(--sans);
  padding: 15px 22px; border-radius: 999px; border: 1.5px solid transparent; text-decoration: none; cursor: pointer;
  white-space: nowrap; transition: transform .18s ease, background-color .18s ease, box-shadow .18s ease, border-color .18s ease, color .18s; }
.btn svg { width: 18px; height: 18px; flex-shrink: 0; transition: transform .18s ease; }
.btn:hover svg { transform: translateX(3px); }
.btn:active { transform: translateY(1px); }
.btn-sm { padding: 10px 16px; font-size: 0.9rem; }
.btn-lg { padding: 17px 28px; font-size: 1.02rem; }
.btn-block { width: 100%; }
.btn-primary { background: var(--ink); color: #fff; box-shadow: 0 10px 24px -12px rgba(13, 61, 38, 0.7); }
.btn-primary:hover { background: var(--ink-2); box-shadow: 0 16px 30px -14px rgba(13, 61, 38, 0.8); transform: translateY(-1px); }
.btn-outline { border-color: rgba(13, 61, 38, 0.22); color: var(--ink); background: transparent; }
.btn-outline:hover { border-color: var(--ink); background: rgba(13, 61, 38, 0.04); }
.btn-ghost { color: var(--ink); background: transparent; }
.btn-ghost:hover { background: rgba(13, 61, 38, 0.06); }
.btn-gold { background: var(--gold-bright); color: var(--ink); box-shadow: 0 12px 28px -14px rgba(233, 200, 105, 0.9); }
.btn-gold:hover { background: #f1d582; transform: translateY(-1px); }
.btn-outline-light { border-color: rgba(247, 241, 227, 0.35); color: #f7f1e3; }
.btn-outline-light:hover { border-color: #f7f1e3; background: rgba(255, 255, 255, 0.06); }

/* ------------------------------------------------------------------- nav */
.nav { position: sticky; top: 0; z-index: 50; background: rgba(251, 248, 241, 0.82); backdrop-filter: saturate(1.4) blur(14px);
  -webkit-backdrop-filter: saturate(1.4) blur(14px); border-bottom: 1px solid transparent; transition: border-color .2s, box-shadow .2s; }
.nav.is-scrolled { border-bottom-color: var(--line); box-shadow: 0 6px 24px -18px rgba(13, 61, 38, 0.35); }
.nav-row { display: flex; align-items: center; gap: 28px; height: 72px; }
.brand { display: inline-flex; align-items: center; gap: 11px; text-decoration: none; color: var(--ink); }
.brand-mark { width: 38px; height: 38px; display: inline-flex; align-items: center; justify-content: center;
  filter: drop-shadow(0 4px 10px rgba(13, 61, 38, 0.28)); }
.brand-mark svg { width: 38px; height: 38px; }
.brand-name { font-family: var(--display); font-weight: 700; font-size: 1.35rem; letter-spacing: -0.02em; }
.brand-light { color: #f7f1e3; }
.brand-light .brand-mark { filter: none; }
.nav-links { display: flex; align-items: center; gap: 4px; margin-left: 12px; }
.nav-links > a { padding: 9px 13px; border-radius: 999px; font-size: 0.94rem; font-weight: 600; color: #3b4a44; text-decoration: none; }
.nav-links > a:hover, .nav-links > a[aria-current] { color: var(--ink); background: rgba(13, 61, 38, 0.06); }
.nav-cta { display: flex; gap: 6px; margin-left: auto; }
.nav-cta-mobile { display: none; }
.nav-burger { display: none; margin-left: auto; width: 44px; height: 44px; border: 0; border-radius: 12px; background: transparent; cursor: pointer; position: relative; }
.nav-burger span { position: absolute; left: 12px; right: 12px; height: 2px; border-radius: 2px; background: var(--ink); transition: transform .2s, top .2s; }
.nav-burger span:first-child { top: 17px; }
.nav-burger span:last-child { top: 25px; }
.nav.is-open .nav-burger span:first-child { top: 21px; transform: rotate(45deg); }
.nav.is-open .nav-burger span:last-child { top: 21px; transform: rotate(-45deg); }

/* ------------------------------------------------------------------ hero */
.hero { position: relative; overflow: hidden; padding: 56px 0 64px; }
.hero::before { content: ""; position: absolute; inset: -30% -10% auto auto; width: 820px; height: 820px; border-radius: 50%;
  background: radial-gradient(closest-side, rgba(233, 200, 105, 0.22), rgba(233, 200, 105, 0)); pointer-events: none; }
.hero::after { content: ""; position: absolute; inset: auto auto -40% -15%; width: 700px; height: 700px; border-radius: 50%;
  background: radial-gradient(closest-side, rgba(35, 71, 59, 0.10), rgba(35, 71, 59, 0)); pointer-events: none; }
.hero-grid { position: relative; z-index: 1; display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr); gap: 56px; align-items: center; }
.hero-copy .lead { margin-top: 22px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 32px; }
.hero-actions-center { justify-content: center; }
.hero-points { list-style: none; padding: 0; margin: 28px 0 0; display: flex; flex-wrap: wrap; gap: 10px 22px; font-size: 0.92rem; font-weight: 600; color: #44524c; }
.hero-points li { display: inline-flex; align-items: center; gap: 8px; }
.hero-points svg { width: 18px; height: 18px; padding: 3px; border-radius: 50%; background: var(--sage); color: var(--ink); }

.hero-visual { position: relative; padding: 44px 24px 44px 40px; }
/* the app as it really looks: a browser window with the family map inside */
.app-mock { position: relative; border-radius: 18px; overflow: hidden; background: #fff; border: 1px solid var(--line);
  box-shadow: var(--shadow-lg); transform: rotate(-1deg); }
.am-chrome { display: flex; align-items: center; gap: 6px; padding: 9px 12px; background: #eef3ea; border-bottom: 1px solid var(--line-soft); }
.am-chrome i { width: 9px; height: 9px; border-radius: 50%; background: #d3dccd; }
.am-chrome span { margin-left: 10px; flex: 1; padding: 3px 10px; border-radius: 999px; background: #fff; font-size: 0.68rem; color: var(--muted); }
.am-bar { display: flex; align-items: center; gap: 8px; padding: 9px 14px; border-bottom: 1px solid var(--line-soft); font-size: 0.8rem; color: var(--ink); }
.am-logo { width: 20px; height: 20px; border-radius: 6px; background: #1a7a46; box-shadow: inset 0 -6px 0 rgba(245,214,127,.9); }
.am-tabs { margin-left: auto; display: flex; gap: 4px; }
.am-tabs em { font-style: normal; font-size: 0.68rem; font-weight: 700; padding: 4px 8px; border-radius: 8px; color: var(--muted); }
.am-tabs em.is-on { background: #e4f5ea; color: #1a7a46; }
.am-map { position: relative; aspect-ratio: 13 / 9; background-color: #e6f4eb;
  background-image: radial-gradient(#bcdcc8 1px, transparent 1.5px); background-size: 16px 16px; }
.am-lines { position: absolute; inset: 0; width: 100%; height: 100%; fill: none; stroke: #c9a227; stroke-width: 2.2; stroke-linecap: round; }
.am-lines circle { fill: #e6f4eb; stroke-width: 1.8; }
.am-lines .am-dash { stroke-dasharray: 3 5; opacity: .8; }
.am-card { position: absolute; width: 21.2%; min-height: 12.8%; box-sizing: border-box; display: flex; flex-direction: column; align-items: center; justify-content: center;
  padding: 4px 6px; border-radius: 12px 12px 12px 4px; background: linear-gradient(180deg, #2c4c3a, #203a2c); border: 1.5px solid #c9a227;
  color: #f1ead9; font: 700 clamp(0.62rem, 1.5vw, 0.82rem)/1.2 Georgia, serif; text-align: center; box-shadow: 0 6px 14px rgba(15,42,34,.28); }
.am-card small { font: 600 clamp(0.52rem, 1.1vw, 0.64rem)/1.2 var(--sans); color: #b8d2c1; margin-top: 2px; }
.am-card.is-f { border-radius: 12px 12px 4px 12px; }
.am-card.is-root { width: 25%; min-height: 15%; border: 2px solid #ffe9a8; background: linear-gradient(180deg, #3c6a4c, #244433);
  box-shadow: 0 8px 22px rgba(233,200,105,.45); }
.am-card.is-root svg { width: 14px; height: 14px; color: #ffe9a8; }
.am-card.is-root small { color: #ffe9a8; }
.am-card.is-add { background: rgba(255,255,255,.7); border: 1.5px dashed #1a7a46; color: #1a7a46; font-family: var(--sans); box-shadow: none; }
.am-zoom { position: absolute; right: 3%; bottom: 5%; display: flex; flex-direction: column; gap: 4px; }
.am-zoom i { width: 22px; height: 22px; border-radius: 7px; background: #fff; box-shadow: var(--shadow-sm); display: flex; align-items: center; justify-content: center;
  font-style: normal; font-weight: 700; color: var(--ink); font-size: 0.85rem; }
.float-story { right: -28px; bottom: -34px; flex-direction: column; align-items: flex-start; gap: 3px; width: 230px; animation-delay: -4.5s; }
@media (max-width: 1279px) { .float-story { display: none; } }
.am-card.is-add { white-space: nowrap; font-size: clamp(0.56rem, 1.2vw, 0.72rem); }
.float-story b { font-family: var(--display); font-weight: 600; font-size: 0.92rem; line-height: 1.35; }
.mock { position: relative; background: var(--white); border: 1px solid var(--line); border-radius: 24px; padding: 22px 22px 18px;
  box-shadow: var(--shadow-lg); transform: rotate(-1.2deg); }
.mock-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; padding-bottom: 14px; border-bottom: 1px solid var(--line-soft); margin-bottom: 12px; }
.mock-kicker { display: block; font-size: 0.72rem; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); }
.mock-title { display: block; font-family: var(--display); font-weight: 600; font-size: 1.3rem; color: var(--ink); }
.mock-badge { display: inline-flex; align-items: center; gap: 8px; padding: 7px 11px; border-radius: 999px; background: var(--ink); color: var(--gold-bright);
  font-size: 0.78rem; font-weight: 800; white-space: nowrap; }
.mock-dots, .gen-dots { display: inline-flex; gap: 3px; }
.mock-dots i, .gen-dots i { width: 6px; height: 6px; border-radius: 50%; background: rgba(233, 200, 105, 0.28); }
.mock-dots i.on { background: var(--gold-bright); }
.mock-gens { list-style: none; margin: 0; padding: 0; position: relative; }
.mock-gens::before { content: ""; position: absolute; left: 14px; top: 16px; bottom: 16px; width: 2px; background: linear-gradient(var(--gold-bright), var(--gold)); opacity: .55; }
.mock-gens li { position: relative; display: flex; align-items: center; gap: 8px; padding: 5px 0; }
.mock-num { position: relative; z-index: 1; width: 30px; height: 30px; flex-shrink: 0; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center;
  background: var(--gold-soft); color: #8a6516; font-family: var(--display); font-weight: 700; font-size: 0.78rem; border: 2px solid #fff; }
.mock-person { display: inline-flex; flex-direction: column; padding: 5px 11px 5px 10px; border-radius: 10px; font-size: 0.8rem; font-weight: 700; line-height: 1.2;
  background: var(--sage); color: var(--ink); border-left: 3px solid var(--ink-3); }
.mock-person small { font-size: 0.68rem; font-weight: 600; color: var(--muted); }
.mock-person.is-f { background: #f6ebe6; border-left-color: var(--female); }
.mock-person.is-you { background: var(--ink); color: #fff; border-left-color: var(--gold-bright); box-shadow: 0 8px 18px -8px rgba(15,42,34,.6); }
.mock-person.is-you small { color: var(--gold-bright); }
.mock-more { font-size: 0.74rem; font-weight: 700; color: var(--muted); padding: 4px 8px; border-radius: 8px; background: var(--paper-2); }

.float { position: absolute; z-index: 2; display: flex; align-items: center; gap: 11px; padding: 12px 14px; background: #fff; border: 1px solid var(--line);
  border-radius: 16px; box-shadow: var(--shadow); font-size: 0.85rem; line-height: 1.3; animation: floaty 7s ease-in-out infinite; }
.float b { display: block; color: var(--ink); }
.float small { display: block; color: var(--muted); font-size: 0.74rem; }
.float-join { top: -30px; right: 28px; }
.float-av { width: 34px; height: 34px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; background: var(--female); color: #fff; font-weight: 800; }
.float-book { bottom: -6px; left: -4px; animation-delay: -2.5s; }
.float-ic { width: 36px; height: 36px; border-radius: 10px; display: inline-flex; align-items: center; justify-content: center; background: var(--gold-soft); color: #8a6516; }
.float-ic svg { width: 20px; height: 20px; }
.float-quiz { right: -18px; bottom: 120px; flex-direction: column; align-items: stretch; gap: 6px; width: 210px; animation-delay: -4.5s; }
.float-kicker { font-size: 0.68rem; font-weight: 800; letter-spacing: 0.08em; text-transform: uppercase; color: var(--gold); }
.quiz-opt { display: flex; align-items: center; gap: 6px; padding: 6px 9px; border-radius: 9px; background: var(--paper); font-weight: 600; font-size: 0.8rem; }
.quiz-opt svg { width: 14px; height: 14px; }
.quiz-opt.is-right { background: #e3f1e6; color: #1f6a3a; }
@keyframes floaty { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }
@media (prefers-reduced-motion: reduce) { .float { animation: none; } }

.hero-stats { position: relative; z-index: 1; display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); margin: 56px 0 0;
  border: 1px solid var(--line); border-radius: var(--radius); background: rgba(255, 255, 255, 0.6); overflow: hidden; }
.hero-stats div { padding: 20px 24px; border-left: 1px solid var(--line); }
.hero-stats div:first-child { border-left: 0; }
.hero-stats dd { margin: 0; font-family: var(--display); font-weight: 600; font-size: 2rem; color: var(--ink); line-height: 1.1; order: -1; }
.hero-stats div { display: flex; flex-direction: column; }
.hero-stats dt { font-size: 0.86rem; color: var(--muted); font-weight: 600; }

/* ------------------------------------------------------------- sections */
.section { padding: 104px 0; }
.section-tight { padding: 48px 0 96px; }
.section-soft { background: var(--paper-2); }
.section-head { max-width: 720px; margin-bottom: 52px; }
.section-head .lead { margin-top: 16px; }
.section-head-row { max-width: none; display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; flex-wrap: wrap; }
.link-arrow { font-weight: 700; color: var(--ink); text-decoration: none; border-bottom: 2px solid var(--gold-bright); padding-bottom: 2px; }
.link-arrow:hover { color: var(--gold); }
.empty { color: var(--muted); }

/* dark band with the seven-generation ladder */
.band { padding: 104px 0; }
.band-dark { position: relative; overflow: hidden; background: var(--ink); color: #dfe8e2; }
.band-dark::before { content: ""; position: absolute; right: -240px; top: -240px; width: 720px; height: 720px; border-radius: 50%;
  background: repeating-radial-gradient(circle, rgba(233, 200, 105, 0.07) 0 1px, transparent 1px 46px); pointer-events: none; }
.yetti-grid { position: relative; display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr); gap: 72px; align-items: center; }
.yetti-grid .lead { margin: 20px 0 32px; }
.ladder { list-style: none; margin: 0; padding: 0; position: relative; }
.ladder::before { content: ""; position: absolute; left: 21px; top: 22px; bottom: 22px; width: 2px; background: linear-gradient(var(--gold-bright), rgba(233, 200, 105, 0.12)); }
.ladder li { position: relative; display: grid; grid-template-columns: 44px 1fr; column-gap: 18px; align-items: center; padding: 9px 0; }
.ladder span { grid-row: span 2; width: 44px; height: 44px; border-radius: 50%; display: flex; align-items: center; justify-content: center;
  font-family: var(--display); font-weight: 700; background: var(--gold-bright); color: var(--ink); box-shadow: 0 0 0 6px var(--ink); }
.ladder b { font-size: 1.08rem; color: #f7f1e3; font-weight: 700; }
.ladder small { color: #9fb5aa; font-size: 0.86rem; }
.ladder li.is-faint span { background: transparent; color: var(--gold-bright); border: 2px dashed rgba(233, 200, 105, 0.55); }
.ladder li.is-faint b { color: #b9c9c0; }

/* steps */
.steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 22px; counter-reset: none; }
.step { position: relative; display: flex; flex-direction: column; padding: 30px; border-radius: var(--radius); background: var(--white); border: 1px solid var(--line); box-shadow: var(--shadow-sm); }
.step-num { font-family: var(--display); font-weight: 600; font-size: 2.6rem; line-height: 1; color: var(--gold-bright); -webkit-text-stroke: 1px var(--gold); margin-bottom: 18px; }
.step h3 { font-family: var(--display); font-weight: 600; font-size: 1.35rem; color: var(--ink); margin-bottom: 10px; }
.step p { color: var(--muted); }
.step-ui { margin-top: auto; padding-top: 22px; display: flex; flex-direction: column; gap: 8px; }
.ui-field, .ui-row { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 12px; background: var(--paper); border: 1px solid var(--line-soft); font-weight: 700; color: var(--ink); font-size: 0.92rem; }
.ui-field { flex-direction: column; align-items: flex-start; gap: 0; }
.ui-field small { font-size: 0.7rem; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--muted); }
.ui-row em { margin-left: auto; font-style: normal; font-size: 0.74rem; font-weight: 700; padding: 3px 9px; border-radius: 999px; background: var(--sage); color: var(--ink-3); }
.ui-av { width: 26px; height: 26px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; font-style: normal; font-size: 0.78rem; background: var(--ink); color: var(--gold-bright); }
.ui-av-2 { background: var(--female); color: #fff; }
.ui-doc, .ui-img { width: 26px; height: 26px; border-radius: 7px; background: var(--gold-soft); border: 1.5px solid var(--gold); }
.ui-img { background: linear-gradient(135deg, var(--ink) 55%, var(--gold-bright) 55%); border-color: var(--ink); }

/* bento */
.bento { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.card { position: relative; display: flex; flex-direction: column; padding: 28px; border-radius: var(--radius); background: var(--white); border: 1px solid var(--line); box-shadow: var(--shadow-sm); }
.card h3 { font-family: var(--display); font-weight: 600; font-size: 1.25rem; color: var(--ink); margin: 16px 0 8px; }
.card p { color: var(--muted); font-size: 0.97rem; }
.card-ic { width: 46px; height: 46px; border-radius: 14px; display: inline-flex; align-items: center; justify-content: center; background: var(--sage); color: var(--ink); }
.card-ic svg { width: 24px; height: 24px; }
.card-wide { grid-column: span 2; flex-direction: row; align-items: center; gap: 24px; }
.card-dark { background: var(--ink); border-color: var(--ink); }
.card-dark h3 { color: #f7f1e3; margin-top: 0; font-size: 1.6rem; }
.card-dark p { color: #b9ccc2; }
.card-copy { flex: 1 1 0; }
.card-art { flex: 0 0 320px; width: 320px; max-width: 100%; height: auto; }

/* audiences */
.aud { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.aud-card { position: relative; display: flex; flex-direction: column; gap: 10px; padding: 32px 28px; border-radius: var(--radius); text-decoration: none;
  border: 1px solid var(--line); background: var(--white); overflow: hidden; transition: transform .2s ease, box-shadow .2s ease, border-color .2s; }
.aud-card::before { content: ""; position: absolute; left: 0; top: 0; right: 0; height: 5px; }
.aud-fam::before { background: var(--ink-3); }
.aud-edu::before { background: #3f6fb0; }
.aud-teach::before { background: var(--gold); }
.aud-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); border-color: #d9cfb8; }
.aud-card h3 { font-family: var(--display); font-weight: 600; font-size: 1.4rem; color: var(--ink); }
.aud-card p { color: var(--muted); }
.aud-go { margin-top: auto; padding-top: 10px; font-weight: 700; color: var(--ink); }

/* open tree cards */
.tree-cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.tree-card { display: flex; flex-direction: column; gap: 10px; padding: 26px; border-radius: var(--radius); background: var(--white); border: 1px solid var(--line);
  text-decoration: none; box-shadow: var(--shadow-sm); transition: transform .2s ease, box-shadow .2s ease; }
.tree-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.tree-card-top { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.tree-card-era { font-size: 0.74rem; font-weight: 800; letter-spacing: 0.08em; text-transform: uppercase; color: var(--gold); }
.tree-card .gen-dots i { background: var(--line); }
.tree-card .gen-dots i.on { background: var(--gold); }
.tree-card-name { font-family: var(--display); font-weight: 600; font-size: 1.5rem; line-height: 1.15; color: var(--ink); }
.tree-card-desc { color: var(--muted); font-size: 0.95rem; }
.tree-card-meta { display: flex; flex-wrap: wrap; gap: 16px; margin-top: auto; padding-top: 14px; border-top: 1px solid var(--line-soft); font-size: 0.88rem; color: var(--muted); }
.tree-card-meta b { color: var(--ink); }

/* privacy */
.privacy { display: grid; grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr); gap: 64px; align-items: start; }
.privacy .lead { margin-top: 16px; }
.privacy-list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.privacy-list li { position: relative; padding: 22px 22px 22px 58px; border-radius: var(--radius-sm); background: var(--white); border: 1px solid var(--line); color: var(--muted); font-size: 0.95rem; }
.privacy-list li::before { content: ""; position: absolute; left: 20px; top: 24px; width: 24px; height: 24px; border-radius: 8px; background: var(--ink)
  url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23e9c869' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 12.5 4 4L18 8.5'/%3E%3C/svg%3E") center/16px no-repeat; }
.privacy-list b { display: block; color: var(--ink); margin-bottom: 4px; font-size: 1rem; }

/* faq */
.faq-grid { display: grid; grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr); gap: 64px; align-items: start; }
.faq-grid .lead { margin-top: 16px; }
.faq details { border-bottom: 1px solid var(--line); }
.faq details:first-child { border-top: 1px solid var(--line); }
.faq summary { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 22px 0; cursor: pointer; list-style: none;
  font-weight: 700; font-size: 1.06rem; color: var(--ink); }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: ""; flex-shrink: 0; width: 30px; height: 30px; border-radius: 50%; background: var(--white)
  url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230f2a22' stroke-width='2.4' stroke-linecap='round'%3E%3Cpath d='M12 6v12M6 12h12'/%3E%3C/svg%3E") center/14px no-repeat;
  border: 1px solid var(--line); transition: transform .2s ease; }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { padding: 0 44px 22px 0; color: var(--muted); }

/* call to action */
.cta { position: relative; overflow: hidden; padding: 110px 0; background: var(--ink); text-align: center; }
.cta::before { content: ""; position: absolute; left: 50%; top: 50%; width: 1100px; height: 1100px; transform: translate(-50%, -50%); border-radius: 50%;
  background: repeating-radial-gradient(circle, rgba(233, 200, 105, 0.07) 0 1px, transparent 1px 54px); pointer-events: none; }
.cta-compact { padding: 80px 0; }
.cta-inner { position: relative; max-width: 760px; }
.cta-inner .lead { margin: 18px auto 0; }

/* ---------------------------------------------------------------- footer */
.footer { background: #0b201a; color: #9fb5aa; padding: 72px 0 28px; font-size: 0.93rem; }
.footer-grid { display: grid; grid-template-columns: minmax(0, 1.6fr) repeat(3, minmax(0, 1fr)); gap: 40px; }
.footer-brand p { margin-top: 16px; max-width: 36ch; }
.footer-tag { color: var(--gold-bright); font-weight: 700; }
.footer-title { color: #f7f1e3; font-weight: 700; margin-bottom: 14px; }
.footer ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.footer a { text-decoration: none; }
.footer ul a:hover { color: #f7f1e3; }
.footer-bottom { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-top: 56px; padding-top: 22px; border-top: 1px solid rgba(255, 255, 255, 0.08); font-size: 0.85rem; }

/* --------------------------------------------------------- inner pages */
.page-hero { padding: 40px 0 48px; border-bottom: 1px solid var(--line); background: linear-gradient(180deg, var(--paper-2), var(--paper)); }
.page-hero .lead { margin-top: 16px; }
.crumbs { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; font-size: 0.86rem; color: var(--muted); margin-bottom: 26px; }
.crumbs a { text-decoration: none; }
.crumbs a:hover { color: var(--ink); text-decoration: underline; }
.crumbs b { color: var(--ink); font-weight: 700; }
.crumbs span { opacity: .5; }

.tree-hero { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 48px; align-items: end; }
.facts { display: flex; flex-wrap: wrap; gap: 12px; margin: 28px 0 0; }
.facts div { padding: 12px 18px; border-radius: 14px; background: var(--white); border: 1px solid var(--line); }
.facts dt { font-size: 0.74rem; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--muted); }
.facts dd { margin: 2px 0 0; font-family: var(--display); font-weight: 600; font-size: 1.6rem; color: var(--ink); line-height: 1.1; }
.facts dd.facts-text { font-size: 1.1rem; padding-top: 4px; }
.facts a { text-decoration: none; border-bottom: 2px solid var(--gold-bright); }
.gen-rail { display: flex; flex-direction: column; gap: 4px; padding: 14px; border-radius: var(--radius); background: var(--white); border: 1px solid var(--line); box-shadow: var(--shadow-sm); }
.gen-rail a { display: grid; grid-template-columns: 30px 1fr auto; align-items: center; gap: 10px; padding: 7px 8px; border-radius: 10px; text-decoration: none; font-weight: 600; font-size: 0.92rem; color: var(--ink); }
.gen-rail a:hover { background: var(--paper); }
.gen-rail span { width: 28px; height: 28px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; background: var(--gold-soft); color: #8a6516; font-family: var(--display); font-weight: 700; font-size: 0.85rem; }
.gen-rail small { color: var(--muted); font-weight: 600; }

.tree-layout { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 48px; padding-block: 56px 96px; align-items: start; }
.tree-main { min-width: 0; }
.tree-side { position: sticky; top: 96px; display: flex; flex-direction: column; gap: 16px; }

.gen { position: relative; padding-left: 60px; padding-bottom: 36px; scroll-margin-top: 90px; }
.gen::before { content: ""; position: absolute; left: 19px; top: 44px; bottom: 0; width: 2px; background: linear-gradient(var(--gold-bright), var(--line)); }
.gen:last-of-type::before { display: none; }
.gen-head { display: flex; align-items: center; gap: 16px; margin: 0 0 18px -60px; }
.gen-num { width: 40px; height: 40px; flex-shrink: 0; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; background: var(--ink); color: var(--gold-bright);
  font-family: var(--display); font-weight: 700; box-shadow: 0 0 0 6px var(--paper); }
.gen-head p { color: var(--muted); font-size: 0.88rem; }
.people { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.person { border-radius: 16px; background: var(--white); border: 1px solid var(--line); transition: border-color .18s, box-shadow .18s, transform .18s; }
.person:hover { border-color: #d6ccb4; box-shadow: var(--shadow); transform: translateY(-2px); }
.person.is-root { border-color: var(--gold); box-shadow: 0 0 0 3px var(--gold-soft); }
.person-link { display: flex; gap: 14px; padding: 16px; text-decoration: none; }
.person-mono { width: 44px; height: 44px; flex-shrink: 0; border-radius: 12px; display: inline-flex; align-items: center; justify-content: center; font-family: var(--display); font-weight: 700; font-size: 1.15rem;
  background: var(--sage); color: var(--ink); }
.person-mono.is-f { background: #f6ebe6; color: #8b4a3b; }
.person-mono-lg { width: 88px; height: 88px; border-radius: 24px; font-size: 2.3rem; }
.person-mono-sm { width: 36px; height: 36px; border-radius: 10px; font-size: 0.95rem; }
.person-body { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.person-name { font-family: var(--display); font-weight: 600; font-size: 1.12rem; line-height: 1.25; color: var(--ink); }
.person-sub { font-size: 0.84rem; font-weight: 600; color: var(--gold); }
.person-text { font-size: 0.88rem; color: var(--muted); display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }

.stories { margin-top: 20px; display: flex; flex-direction: column; gap: 14px; }
.stories .h3 { margin-bottom: 4px; }
.story { position: relative; padding: 24px 26px 22px 30px; border-radius: 16px; background: var(--white); border: 1px solid var(--line); }
.story::before { content: ""; position: absolute; left: 0; top: 18px; bottom: 18px; width: 4px; border-radius: 0 4px 4px 0; background: var(--gold-bright); }
.story p { color: #33413c; font-size: 1.02rem; line-height: 1.75; }
.story a { display: inline-block; margin-top: 10px; font-weight: 700; font-size: 0.9rem; text-decoration: none; color: var(--ink); border-bottom: 2px solid var(--gold-bright); }

.side-card { padding: 22px; border-radius: var(--radius); background: var(--white); border: 1px solid var(--line); }
.side-title { font-family: var(--display); font-weight: 600; font-size: 1.15rem; color: var(--ink); margin-bottom: 12px; }
.side-text { color: var(--muted); font-size: 0.93rem; margin-bottom: 14px; }
.side-cta { background: var(--ink); border-color: var(--ink); }
.side-cta .side-title { color: #f7f1e3; font-size: 1.3rem; }
.side-cta p:not(.eyebrow) { color: #b9ccc2; font-size: 0.93rem; margin-bottom: 18px; }
.side-cta .eyebrow { margin-bottom: 10px; }
.sources { margin: 0; padding-left: 18px; display: flex; flex-direction: column; gap: 8px; font-size: 0.88rem; color: var(--muted); }
.side-links { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
.side-links a { display: flex; justify-content: space-between; gap: 10px; padding: 9px 0; border-top: 1px solid var(--line-soft); text-decoration: none; font-weight: 600; font-size: 0.93rem; color: var(--ink); }
.side-links li:first-child a { border-top: 0; }
.side-links a:hover { color: var(--gold); }
.side-links small { color: var(--muted); font-weight: 500; white-space: nowrap; }

.person-hero { display: flex; align-items: center; gap: 24px; }
.person-facts { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 12px; margin: 0 0 36px; }
.person-facts div { padding: 14px 16px; border-radius: 14px; background: var(--white); border: 1px solid var(--line); }
.person-facts dt { font-size: 0.74rem; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--muted); }
.person-facts dd { margin: 3px 0 0; font-weight: 700; color: var(--ink); }
.prose { margin-bottom: 36px; }
.prose .h3 { margin-bottom: 12px; }
.prose p { font-size: 1.1rem; line-height: 1.8; color: #2c3a35; max-width: 70ch; }
.family { margin-top: 40px; }
.family .h3 { margin-bottom: 16px; }
.family-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.family-group { display: flex; flex-direction: column; gap: 8px; padding: 18px; border-radius: 16px; background: var(--paper-2); }
.family-label { font-size: 0.74rem; font-weight: 800; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); }
.relative { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 12px; background: var(--white); border: 1px solid var(--line-soft); text-decoration: none; transition: border-color .15s; }
.relative:hover { border-color: var(--gold); }
.relative b { display: block; color: var(--ink); font-size: 0.95rem; }
.relative small { display: block; color: var(--muted); font-size: 0.8rem; }

.share-page { padding: 64px 0 96px; text-align: center; }
.share-inner { max-width: 880px; }
.share-inner .lead { margin: 16px auto 0; }
.share-card-img { display: block; width: 100%; margin: 36px auto 0; border-radius: 22px; box-shadow: var(--shadow-lg); }

/* reveal on scroll */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity .7s ease, transform .7s cubic-bezier(.2,.7,.2,1); }
.reveal.is-in { opacity: 1; transform: none; }

/* ------------------------------------------------------------ responsive */
@media (max-width: 1080px) {
  .hero-grid, .yetti-grid, .privacy, .faq-grid { grid-template-columns: minmax(0, 1fr); gap: 48px; }
  .hero-visual { max-width: 560px; margin: 0 auto; width: 100%; }
  .steps, .aud, .tree-cards { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .bento { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .card-wide { grid-column: span 2; }
  .tree-hero, .tree-layout { grid-template-columns: minmax(0, 1fr); }
  .tree-side { position: static; }
  .gen-rail { display: none; }
  .footer-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .footer-brand { grid-column: 1 / -1; }
}
@media (max-width: 860px) {
  .nav-links { position: fixed; left: 0; right: 0; top: 72px; flex-direction: column; align-items: stretch; gap: 2px; margin: 0; padding: 12px 16px 20px;
    background: var(--paper); border-bottom: 1px solid var(--line); box-shadow: 0 20px 40px -20px rgba(13, 61, 38, 0.4); transform: translateY(-8px); opacity: 0; pointer-events: none; transition: opacity .18s, transform .18s; }
  .nav.is-open .nav-links { opacity: 1; transform: none; pointer-events: auto; }
  .nav-links > a { padding: 13px 12px; font-size: 1rem; }
  .nav-cta-mobile { display: flex; gap: 8px; margin-top: 10px; }
  .nav-cta-mobile .btn { flex: 1; }
  .nav-cta { display: none; }
  .nav-burger { display: block; }
}
@media (max-width: 720px) {
  .wrap { padding-inline: 18px; }
  .hero { padding: 32px 0 48px; }
  .section, .band { padding: 72px 0; }
  .section-head { margin-bottom: 36px; }
  .steps, .aud, .tree-cards, .bento, .privacy-list, .people, .family-grid { grid-template-columns: minmax(0, 1fr); }
  .card-wide { grid-column: auto; flex-direction: column; align-items: stretch; }
  .card-art { flex-basis: auto; width: 100%; }
  .hero-visual { padding: 12px 0 28px; }
  .float-join { right: 4px; top: -8px; }
  .float-quiz, .float-story { display: none; }
  .am-tabs em:not(.is-on):not(:last-child) { display: none; }
  .app-mock { transform: none; }
  .float-book { left: 8px; bottom: 0; }
  .mock { transform: none; padding: 16px; }
  .hero-actions .btn { flex: 1 1 100%; }
  .hero-stats div { border-left: 0; border-top: 1px solid var(--line); }
  .hero-stats div:first-child { border-top: 0; }
  .gen { padding-left: 0; }
  .gen::before { display: none; }
  .gen-head { margin-left: 0; }
  .person-hero { align-items: flex-start; }
  .person-mono-lg { width: 64px; height: 64px; font-size: 1.7rem; border-radius: 18px; }
  .footer-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .faq details p { padding-right: 0; }
}

/* ---- legal pages (privacy / terms) ---- */
.legal { max-width: 760px; margin: 0 auto; }
.legal h1.h2 { margin: 6px 0 4px; }
.legal-updated { color: var(--muted); font-size: 0.9rem; margin: 0 0 22px; }
.legal h2 { font-size: 1.15rem; margin: 26px 0 8px; color: var(--ink); }
.legal p { line-height: 1.7; margin: 0 0 12px; color: var(--ink-2, #33423b); }
.legal a { color: var(--brand, #1a7a46); font-weight: 600; }
.legal-foot { margin-top: 28px; padding-top: 16px; border-top: 1px solid var(--line, #e3ece6); }

/* ---- biggest-trees leaderboard ---- */
.top-list { max-width: 640px; margin: 0 auto; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 8px; }
.top-row { display: flex; align-items: center; gap: 14px; padding: 12px 16px; border: 1px solid var(--line, #e3ece6);
  border-radius: 14px; background: var(--card, #fff); }
.top-rank { flex-shrink: 0; width: 30px; height: 30px; border-radius: 50%; display: flex; align-items: center;
  justify-content: center; font-weight: 800; font-size: 0.95rem; background: #e4f5ea; color: #1a7a46; }
.top-row:nth-child(1) .top-rank { background: #f6e6b8; color: #8a6a1f; }
.top-row:nth-child(2) .top-rank { background: #e9edf0; color: #5a6b76; }
.top-row:nth-child(3) .top-rank { background: #f3e0cf; color: #8a5a30; }
.top-main { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; }
.top-name { font-weight: 700; color: var(--ink); text-decoration: none; }
a.top-name:hover { color: var(--brand, #1a7a46); }
.top-sub { font-size: 0.85rem; color: var(--muted); }
.top-count { flex-shrink: 0; font-size: 0.95rem; color: var(--ink-2, #33423b); }
.top-count b { font-size: 1.15rem; color: #1a7a46; }
.top-hint { font-size: 0.9rem; color: var(--muted); max-width: 560px; margin: 0 auto 14px; }

/* champion per region */
.champ-grid { max-width: 760px; margin: 4px auto 18px; padding: 0; list-style: none;
  display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
.champ-card { margin: 0; }
.champ-card a { display: flex; flex-direction: column; gap: 2px; height: 100%; padding: 12px 14px;
  border: 1px solid var(--line, #e3ece6); border-radius: 14px; background: var(--card, #fff);
  text-decoration: none; transition: border-color .15s, box-shadow .15s, transform .15s; }
.champ-card a:hover { border-color: var(--brand, #1a7a46); box-shadow: 0 4px 14px rgba(26,122,70,.12); transform: translateY(-1px); }
.champ-card.is-on a { border-color: var(--brand, #1a7a46); box-shadow: 0 0 0 1px var(--brand, #1a7a46); }
.champ-region { font-size: 0.78rem; font-weight: 800; letter-spacing: .02em; text-transform: uppercase; color: #1a7a46; }
.champ-name { font-weight: 700; color: var(--ink); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.champ-count { font-size: 0.85rem; color: var(--muted); }
.champ-count b { font-size: 1.05rem; color: var(--ink-2, #33423b); }

/* Oilaviy / Tarixiy segmented toggle */
.seg { display: inline-flex; gap: 4px; margin: 0 auto 22px; padding: 4px; border-radius: 999px;
  border: 1px solid var(--line, #e3ece6); background: var(--card, #fff); }
.seg-wrap { text-align: center; }
.seg-btn { padding: 7px 20px; border-radius: 999px; font-size: 0.92rem; font-weight: 600; text-decoration: none;
  color: var(--ink-2, #33423b); transition: background .15s, color .15s; }
.seg-btn:hover { color: #1a7a46; }
.seg-btn.is-on { background: #1a7a46; color: #fff; }

/* region filter chips */
.region-chips { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; max-width: 720px; margin: 0 auto 20px; }
.region-chip { font-size: 0.85rem; padding: 5px 12px; border-radius: 999px; text-decoration: none;
  border: 1px solid var(--line, #e3ece6); color: var(--ink-2, #33423b); background: var(--card, #fff); }
.region-chip:hover { border-color: var(--brand, #1a7a46); color: #1a7a46; }
.region-chip.is-on { background: #1a7a46; border-color: #1a7a46; color: #fff; }

/* 🙏 rahmat button on the leaderboard */
.rahmat-form { margin: 0; flex-shrink: 0; }
.rahmat-btn { display: inline-flex; align-items: center; gap: 5px; padding: 6px 11px; border-radius: 999px;
  border: 1px solid var(--line, #e3ece6); background: var(--card, #fff); color: var(--ink-2, #33423b);
  font: inherit; font-size: 0.9rem; cursor: pointer; text-decoration: none; transition: border-color .15s, background .15s; }
.rahmat-btn:hover { border-color: #d9808a; background: #fdf1f3; color: #b23a46; }
.rahmat-btn.is-on { border-color: #d64550; background: #fdeef0; color: #b23a46; }
.rahmat-ic { width: 16px; height: 16px; flex-shrink: 0; fill: none; stroke: #b7808a; stroke-width: 1.8; }
.rahmat-btn:hover .rahmat-ic { stroke: #d64550; }
.rahmat-btn.is-on .rahmat-ic { fill: #d64550; stroke: #d64550; }
.rahmat-label { font-weight: 600; }
.rahmat-n { font-weight: 700; min-width: 0.6em; text-align: center; opacity: .85; }

.footer-legal { display: inline-flex; flex-wrap: wrap; gap: 14px; }
.footer-legal a { color: inherit; opacity: 0.85; text-decoration: none; }
.footer-legal a:hover { opacity: 1; text-decoration: underline; }
