/* Landing de Habits — identidad "Tierra cruda" (misma paleta que la app):
   adobe = marca y acción, oliva = vegetación, cremas de cal de fondo. */
:root {
  --bg: #FAF6F0;
  --bg2: #F2EBE1;
  --ink: #201810;
  --ink2: #443729;
  --muted: #6B5C4C;
  --line: #E5DACB;
  --adobe: #A64B29;
  --adobe-d: #7C3618;
  --adobe-dd: #5E2810;
  --adobe-50: #FBF1EA;
  --adobe-100: #F5DFD0;
  --olive: #5C6B3C;
  --olive-50: #F1F4E6;
  --sun: #F0B429;
  --radius: 20px;
  --shadow: 0 30px 60px -32px rgba(94, 50, 25, .45), 0 2px 6px rgba(94, 50, 25, .06);
  --font: "Bricolage Grotesque", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --hand: "Caveat", "Segoe Script", cursive;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 76px; -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font-family: var(--font); font-size: 17px; line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}
img, svg { display: block; max-width: 100%; }
h1, h2, h3, p, ul, ol, figure { margin: 0; }
ul, ol { padding: 0; list-style: none; }
a { color: inherit; }
button { font: inherit; }
:focus-visible { outline: 3px solid var(--adobe); outline-offset: 3px; border-radius: 6px; }

.wrap { width: 100%; max-width: 1120px; margin: 0 auto; padding: 0 20px; }
.skip {
  position: absolute; left: 12px; top: -60px; z-index: 100; background: var(--adobe-d); color: #fff;
  padding: 10px 14px; border-radius: 10px; text-decoration: none; font-weight: 700;
}
.skip:focus { top: 12px; }

/* ── Botones ───────────────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  background: var(--adobe-d); color: #fff; text-decoration: none; font-weight: 700;
  padding: 12px 22px; border-radius: 16px; border: 2px solid transparent;
  box-shadow: 0 14px 28px -12px rgba(166, 75, 41, .65);
  transition: background .2s, transform .15s, box-shadow .2s;
}
.btn:hover { background: var(--adobe-dd); }
.btn:active { transform: scale(.985); }
.btn--sm { padding: 8px 16px; border-radius: 12px; font-size: 15px; box-shadow: none; }
.btn--lg { padding: 16px 28px; font-size: 18px; border-radius: 18px; }
.btn--ghost { background: transparent; color: var(--adobe-d); border-color: var(--adobe-100); box-shadow: none; }
.btn--ghost:hover { background: var(--adobe-50); border-color: var(--adobe-100); }
.btn--light { background: #fff; color: var(--adobe-dd); box-shadow: 0 16px 30px -14px rgba(0, 0, 0, .5); }
.btn--light:hover { background: var(--adobe-50); }

/* ── Cabecera ──────────────────────────────────────────── */
.top {
  position: sticky; top: 0; z-index: 50;
  background: rgba(250, 246, 240, .82); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px);
  border-bottom: 1px solid transparent; transition: border-color .2s;
}
.top.is-stuck { border-bottom-color: var(--line); }
.top__in { display: flex; align-items: center; justify-content: space-between; height: 68px; }
.top__nav { display: flex; align-items: center; gap: 14px; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; }
.brand__dot { width: 18px; height: 18px; border-radius: 6px; background: var(--adobe); }
.brand__name { font-weight: 800; font-size: 22px; letter-spacing: .01em; color: var(--adobe-dd); }
.link-quiet { text-decoration: none; font-weight: 600; color: var(--ink2); padding: 8px 6px; }
.link-quiet:hover { color: var(--adobe-d); }
.lang { display: inline-flex; padding: 3px; background: var(--bg2); border-radius: 12px; }
.lang button {
  border: 0; background: transparent; color: var(--muted); font-weight: 700; font-size: 13px;
  padding: 6px 11px; border-radius: 9px; cursor: pointer; letter-spacing: .04em;
}
.lang button[aria-pressed="true"] { background: #fff; color: var(--adobe-dd); box-shadow: 0 1px 3px rgba(94, 50, 25, .15); }

/* ── Tipografía común ──────────────────────────────────── */
.eyebrow {
  font-size: 13px; font-weight: 700; letter-spacing: .24em; text-transform: uppercase; color: var(--olive);
}
h1, h2, h3 { font-weight: 800; letter-spacing: -.02em; line-height: 1.08; text-wrap: balance; }
h2 { font-size: clamp(30px, 4.2vw, 46px); }
h3 { font-size: 21px; line-height: 1.2; }
.sub { color: var(--muted); font-size: 18px; margin-top: 12px; }

/* ── Portada ───────────────────────────────────────────── */
.hero {
  position: relative; overflow: hidden;
  background:
    radial-gradient(900px 520px at 88% 8%, rgba(237, 199, 175, .55), transparent 70%),
    radial-gradient(700px 480px at 0% 100%, rgba(203, 214, 166, .35), transparent 70%),
    var(--bg);
}
/* curvas de nivel: el territorio de fondo */
.hero::before {
  content: ""; position: absolute; inset: 0; opacity: .5; pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='600' height='400' viewBox='0 0 600 400' fill='none' stroke='%23E5DACB' stroke-width='1.2'%3E%3Cpath d='M0 330C100 300 200 360 300 330S500 360 600 330'/%3E%3Cpath d='M0 290C100 260 200 320 300 290S500 320 600 290'/%3E%3Cpath d='M0 250C100 220 200 280 300 250S500 280 600 250'/%3E%3Cpath d='M0 210C100 180 200 240 300 210S500 240 600 210'/%3E%3Cpath d='M0 170C100 140 200 200 300 170S500 200 600 170'/%3E%3C/svg%3E");
  background-size: 600px 400px;
  -webkit-mask-image: linear-gradient(180deg, #000 30%, transparent 100%); mask-image: linear-gradient(180deg, #000 30%, transparent 100%);
}
.hero__in {
  position: relative; display: grid; grid-template-columns: 1.2fr 1fr; gap: 48px; align-items: center;
  padding-top: 56px; padding-bottom: 72px;
}
.hero h1 { font-size: clamp(38px, 5.4vw, 64px); margin: 16px 0 22px; color: var(--ink); }
.hero h1 span { display: block; color: var(--adobe); }
.lead { font-size: clamp(18px, 2vw, 20px); color: var(--ink2); max-width: 34em; }
.cta-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 30px; }
.hint { color: var(--muted); font-size: 15px; margin-top: 12px; }
.hero__art svg {
  width: 100%; height: auto; border-radius: 24px; border: 1px solid rgba(206, 191, 172, .8); box-shadow: var(--shadow); background: #f6f1e2;
}
.hero__art figcaption { text-align: center; color: var(--muted); font-size: 14px; margin-top: 10px; }
.lbl text { font: 700 10.5px ui-sans-serif, system-ui, sans-serif; fill: #4b463f; stroke: #f7f3e8; stroke-width: 3; paint-order: stroke; stroke-linejoin: round; }
.lbl .in-pond { font-size: 9.5px; fill: #0f4f73; stroke: #d6edf8; stroke-width: 2.5; }

/* ── Fuentes ───────────────────────────────────────────── */
.sources { border-block: 1px solid var(--line); background: var(--bg); }
.sources .wrap { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 10px 28px; padding-block: 22px; }
.sources p { color: var(--muted); font-size: 15px; }
.sources ul { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px 26px; }
.sources li { font-weight: 700; color: var(--ink2); font-size: 15px; letter-spacing: .02em; }

/* ── Secciones ─────────────────────────────────────────── */
.sec { padding: 96px 0; }
.sec--band { background: var(--bg2); }
.sec__head { max-width: 720px; margin-bottom: 48px; }
.sec__head .eyebrow { margin-bottom: 12px; }

/* Pasos */
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; counter-reset: s; }
.step {
  position: relative; background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 28px 26px 30px; box-shadow: 0 1px 0 rgba(255, 255, 255, .8) inset;
}
.step__n {
  position: absolute; top: 22px; right: 24px; font-family: var(--hand); font-size: 44px; line-height: 1; color: var(--adobe); opacity: .55; font-weight: 700;
}
.step__ic { width: 48px; height: 48px; fill: none; stroke: var(--adobe); stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; margin-bottom: 18px; }
.step p { color: var(--muted); margin-top: 8px; }

/* Marco de navegador + capturas */
.frame {
  border-radius: 18px; overflow: hidden; background: #fff; border: 1px solid var(--line); box-shadow: var(--shadow);
}
.frame__bar { display: flex; align-items: center; gap: 7px; height: 38px; padding: 0 14px; background: #EDE3D4; border-bottom: 1px solid var(--line); }
.frame__bar i { width: 11px; height: 11px; border-radius: 50%; background: #D8C9B3; }
.frame__bar span { margin-left: 14px; font-size: 13px; color: var(--muted); background: rgba(255, 255, 255, .6); padding: 3px 16px; border-radius: 8px; }
.frame img { width: 100%; height: auto; }

.feat { display: grid; grid-template-columns: 1fr 1.15fr; gap: 56px; align-items: center; margin-top: 88px; }
.feat--rev { grid-template-columns: 1.15fr 1fr; }
.feat--rev .feat__txt { order: 2; }
.feat__txt h3 { font-size: clamp(26px, 3vw, 34px); margin: 14px 0 12px; }
.feat__txt p { color: var(--ink2); font-size: 18px; max-width: 28em; }
.chip {
  display: inline-block; font-size: 13px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase;
  color: var(--adobe-d); background: var(--adobe-100); padding: 5px 12px; border-radius: 99px;
}
.shot { border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); box-shadow: var(--shadow); background: #fff; }
.shot img { width: 100%; height: auto; }
.shot--soft { max-width: 460px; justify-self: center; }

/* Tarjetas */
.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 26px 24px; transition: transform .2s, box-shadow .2s; }
.card:hover { transform: translateY(-3px); box-shadow: 0 22px 40px -26px rgba(94, 50, 25, .5); }
.card svg { width: 40px; height: 40px; fill: none; stroke: var(--olive); stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; margin-bottom: 14px; }
.card h3 { font-size: 19px; }
.card p { color: var(--muted); margin-top: 6px; font-size: 16px; }

/* Caminos */
.paths { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.path {
  position: relative; display: flex; flex-direction: column; gap: 10px; text-decoration: none;
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 30px 26px 26px;
  transition: transform .2s, box-shadow .2s, border-color .2s;
}
.path:hover { transform: translateY(-3px); border-color: var(--adobe-100); box-shadow: 0 22px 40px -26px rgba(94, 50, 25, .5); }
.path p { color: var(--muted); flex: 1; }
.path__go { color: var(--adobe-d); font-weight: 700; margin-top: 6px; }
.path--main { border-color: var(--adobe); box-shadow: 0 0 0 1px var(--adobe) inset; }
.badge {
  position: absolute; top: -13px; left: 22px; background: var(--adobe-d); color: #fff;
  font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; padding: 5px 12px; border-radius: 99px;
}

/* Cierre */
.closing { background: var(--adobe-dd); color: #fff; text-align: center; position: relative; overflow: hidden; }
.closing::before {
  content: ""; position: absolute; inset: 0; opacity: .12; pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='600' height='400' viewBox='0 0 600 400' fill='none' stroke='%23fff' stroke-width='1.4'%3E%3Cpath d='M0 330C100 300 200 360 300 330S500 360 600 330'/%3E%3Cpath d='M0 290C100 260 200 320 300 290S500 320 600 290'/%3E%3Cpath d='M0 250C100 220 200 280 300 250S500 280 600 250'/%3E%3Cpath d='M0 210C100 180 200 240 300 210S500 240 600 210'/%3E%3C/svg%3E");
}
.closing__in { position: relative; padding-block: 92px; display: flex; flex-direction: column; align-items: center; gap: 14px; }
.closing .note { font-family: var(--hand); font-size: 30px; color: #F0B429; line-height: 1; }
.closing h2 { font-size: clamp(34px, 5vw, 56px); }
.closing p { color: #F5DFD0; font-size: 19px; }
.closing .btn { margin-top: 14px; }
.closing .hint { color: #DE9F7C; margin-top: 6px; }

/* Pie */
.foot { background: var(--bg); padding: 40px 0 34px; }
.foot__in { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 22px; }
.foot__tag { color: var(--muted); font-size: 14px; letter-spacing: .16em; text-transform: uppercase; margin-top: 8px; }
.foot__links { display: flex; flex-wrap: wrap; gap: 8px 26px; align-items: flex-start; }
.foot__links a { color: var(--ink2); font-weight: 600; text-decoration: none; font-size: 15px; }
.foot__links a:hover { color: var(--adobe-d); text-decoration: underline; }
.foot__legal { color: var(--muted); font-size: 14px; max-width: 46em; margin-top: 26px; padding-top: 20px; border-top: 1px solid var(--line); }

/* Aparición suave (sólo si hay JS; sin JS todo queda visible) */
.js .reveal { opacity: 0; transform: translateY(18px); transition: opacity .7s ease, transform .7s cubic-bezier(.2, .7, .2, 1); }
.js .reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js .reveal { opacity: 1; transform: none; transition: none; }
  .btn, .card, .path { transition: none; }
}

/* ── Tablet y móvil ────────────────────────────────────── */
@media (max-width: 920px) {
  .hero__in { grid-template-columns: 1fr; gap: 36px; padding-top: 36px; padding-bottom: 56px; }
  .hero__art { max-width: 560px; }
  .steps, .cards, .paths { grid-template-columns: 1fr; }
  .feat, .feat--rev { grid-template-columns: 1fr; gap: 26px; margin-top: 64px; }
  .feat--rev .feat__txt { order: 0; }
  .sec { padding: 72px 0; }
  .sec__head { margin-bottom: 34px; }
  .cards { gap: 14px; }
}
@media (min-width: 640px) and (max-width: 920px) {
  .cards { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 560px) {
  body { font-size: 16.5px; }
  .wrap { padding-left: 16px; padding-right: 16px; }
  .top__in { height: 60px; }
  .link-quiet { display: none; }
  .brand__name { font-size: 20px; }
  .cta-row .btn { width: 100%; }
  .frame__bar { height: 30px; }
  .frame__bar span { padding: 1px 12px; font-size: 12px; }
  .sources .wrap { padding-block: 18px; }
}
