/* =============================================================================
   flutter_base — landing (v2, orientada a producto)
   Muestra la app real en marcos de móvil. Color de marca del template (#246BFD)
   + colores de las categorías. Sin blobs difuminados ni glassmorphism gratuito.
   ========================================================================== */

:root {
  --bg:        #ffffff;
  --bg-2:      #f4f6fa;
  --ink:       #0e1020;
  --ink-soft:  #474d63;
  --muted:     #7b8199;
  --line:      rgba(14, 16, 32, 0.10);
  --line-2:    rgba(14, 16, 32, 0.16);
  --brand:     #246bfd;
  --brand-hov: #1b57d6;
  --brand-soft:rgba(36, 107, 253, 0.10);
  --on-brand:  #ffffff;

  --c-blue:#246bfd; --c-violet:#8b5cf6; --c-sky:#0ea5e9; --c-green:#22c55e;
  --c-amber:#f59e0b; --c-pink:#ec4899; --c-teal:#14b8a6; --c-orange:#f97316;
  --c-red:#ef4444;

  --font-sans: 'Sora', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --font-mono: 'JetBrains Mono', ui-monospace, 'SF Mono', Menlo, monospace;
  --wrap: 1160px;
  --gutter: clamp(20px, 5vw, 56px);
}
:root[data-theme='dark'] {
  --bg:        #0a0b10;
  --bg-2:      #101219;
  --ink:       #eef0f7;
  --ink-soft:  #b4bacf;
  --muted:     #7f8598;
  --line:      rgba(255, 255, 255, 0.10);
  --line-2:    rgba(255, 255, 255, 0.17);
  --brand:     #5b93ff;
  --brand-hov: #74a4ff;
  --brand-soft:rgba(91, 147, 255, 0.14);
}

*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  font-family: system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  background: var(--bg); color: var(--ink);
  font-size: 17px; line-height: 1.6; letter-spacing: -0.004em;
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
code { font-family: var(--font-mono); font-size: 0.88em; }
.wrap { width: 100%; max-width: var(--wrap); margin-inline: auto; padding-inline: var(--gutter); }
.skip { position: absolute; left: -999px; top: 8px; background: var(--ink); color: var(--bg); padding: 8px 14px; border-radius: 6px; z-index: 10000; }
.skip:focus { left: 16px; }

h1, h2, h3, h4, .h2, .h3 { font-family: var(--font-sans); letter-spacing: -0.025em; line-height: 1.1; }
.h2 { font-weight: 800; font-size: clamp(1.9rem, 3.4vw, 2.7rem); }
.h3 { font-weight: 700; font-size: clamp(1.4rem, 2.4vw, 1.95rem); letter-spacing: -0.02em; }
code.k, .h2 code, .section__sub code { color: var(--brand); font-weight: inherit; }

/* ── Botones ───────────────────────────────────────────────────────────── */
.btn {
  --py: 13px; --px: 22px;
  display: inline-flex; align-items: center; gap: 8px;
  padding: var(--py) var(--px);
  font-family: var(--font-sans); font-size: 15px; font-weight: 600;
  border: 1px solid transparent; border-radius: 10px; cursor: pointer;
  transition: transform .14s ease, background .2s ease, border-color .2s ease, color .2s ease;
}
.btn:active { transform: translateY(1px); }
.btn--sm { --py: 8px; --px: 15px; font-size: 14px; border-radius: 8px; }
.btn--lg { --py: 15px; --px: 28px; font-size: 16px; }
.btn--solid { background: var(--brand); color: var(--on-brand); }
.btn--solid:hover { background: var(--brand-hov); }
.btn--ghost { border-color: var(--line-2); color: var(--ink); }
.btn--ghost:hover { border-color: var(--ink); background: color-mix(in srgb, var(--ink) 4%, transparent); }
.btn--white { background: #fff; color: #0e1020; }
.btn--white:hover { background: #eef1f8; }

.icon-btn {
  width: 38px; height: 38px; display: grid; place-items: center;
  background: transparent; border: 1px solid var(--line); border-radius: 9px;
  cursor: pointer; color: var(--ink); font-size: 15px; transition: border-color .2s ease;
}
.icon-btn:hover { border-color: var(--line-2); }
.icon-btn__moon { display: none; }
:root[data-theme='dark'] .icon-btn__sun { display: none; }
:root[data-theme='dark'] .icon-btn__moon { display: inline; }

.link { font-family: var(--font-sans); font-weight: 600; color: var(--brand); font-size: 15px; display: inline-flex; gap: 6px; align-items: center; }
.link span { transition: transform .2s ease; }
.link:hover span { transform: translateX(3px); }

/* ── Nav ───────────────────────────────────────────────────────────────── */
.nav {
  position: sticky; top: 0; z-index: 100;
  background: color-mix(in srgb, var(--bg) 85%, transparent);
  backdrop-filter: saturate(160%) blur(10px);
  border-bottom: 1px solid var(--line);
}
.nav__inner { display: flex; align-items: center; justify-content: space-between; height: 64px; }
.wordmark { font-family: var(--font-mono); font-weight: 500; font-size: 15px; display: inline-flex; align-items: center; gap: 9px; }
.wordmark__mark { width: 14px; height: 14px; border-radius: 4px; background: var(--brand); box-shadow: inset -4px -4px 0 rgba(255,255,255,.35); }
.nav__links { display: flex; gap: 30px; }
.nav__links a { font-size: 14.5px; color: var(--ink-soft); position: relative; padding: 4px 0; transition: color .2s ease; }
.nav__links a::after { content:''; position:absolute; left:0; bottom:0; width:100%; height:2px; background: var(--brand); transform: scaleX(0); transform-origin:left; transition: transform .25s ease; }
.nav__links a:hover { color: var(--ink); }
.nav__links a:hover::after { transform: scaleX(1); }
.nav__actions { display: flex; align-items: center; gap: 10px; }
.nav__burger { display: none; width: 38px; height: 38px; border: 1px solid var(--line); border-radius: 9px; background: transparent; cursor: pointer; flex-direction: column; align-items: center; justify-content: center; gap: 5px; }
.nav__burger span { width: 16px; height: 2px; background: var(--ink); border-radius: 2px; transition: transform .25s ease; }
.nav__burger[aria-expanded='true'] span:first-child { transform: translateY(3.5px) rotate(45deg); }
.nav__burger[aria-expanded='true'] span:last-child { transform: translateY(-3.5px) rotate(-45deg); }
.nav__mobile { flex-direction: column; border-bottom: 1px solid var(--line); }
.nav__mobile a { padding: 15px var(--gutter); font-size: 16px; border-top: 1px solid var(--line); color: var(--ink-soft); }

/* ── Hero ──────────────────────────────────────────────────────────────── */
.hero { padding-top: clamp(40px, 6vw, 76px); padding-bottom: clamp(32px, 5vw, 64px); overflow: hidden; }
.hero__grid { display: grid; grid-template-columns: 1.02fr 0.98fr; gap: clamp(28px, 4vw, 56px); align-items: center; }
.hero__title { font-weight: 800; font-size: clamp(2.4rem, 5vw, 4rem); line-height: 1.04; letter-spacing: -0.035em; }
.hero__title .grad { color: var(--brand); }
.hero__lede { margin: 22px 0 0; font-size: clamp(1.05rem, 1.5vw, 1.2rem); color: var(--ink-soft); max-width: 30em; line-height: 1.6; }
.hero__cta { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 30px; }
.hero__badges { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 30px; }
.hero__badges span { font-family: var(--font-mono); font-size: 12px; color: var(--ink-soft); border: 1px solid var(--line); border-radius: 999px; padding: 6px 12px; }

/* Marcos de móvil */
.hero__art { position: relative; display: grid; place-items: center; }
.hero__art::before {
  content: ''; position: absolute; inset: 6% -4%;
  background:
    radial-gradient(circle at 1px 1px, var(--line-2) 1px, transparent 0) 0 0 / 22px 22px,
    var(--brand-soft);
  border-radius: 28px; z-index: 0; opacity: .55;
}
.phones { position: relative; z-index: 1; display: flex; justify-content: center; width: 100%; min-height: 540px; align-items: center; }

.phone { width: 258px; }
.phone__frame {
  position: relative; background: #0a0a0f; border-radius: 42px; padding: 8px;
  box-shadow: 0 2px 6px rgba(10,12,25,.10), 0 30px 60px -22px rgba(10,12,25,.45);
}
:root[data-theme='dark'] .phone__frame { box-shadow: 0 2px 6px rgba(0,0,0,.4), 0 30px 60px -22px rgba(0,0,0,.7); outline: 1px solid rgba(255,255,255,.06); }
.phone__island { position: absolute; top: 15px; left: 50%; transform: translateX(-50%); width: 76px; height: 20px; background: #000; border-radius: 12px; z-index: 6; }

.phone--front { position: relative; z-index: 2; transform: rotate(-2deg); }
.phone--back { position: absolute; right: 2%; top: -6px; z-index: 1; transform: scale(.9) rotate(5deg); }

/* Pantalla de la app */
.scr {
  --s-bg:#f4f5f8; --s-card:#ffffff; --s-line:rgba(17,19,28,.08);
  --s-line2:rgba(17,19,28,.16); --s-ink:#14151c; --s-soft:#5b6070;
  position: relative; height: 524px; border-radius: 34px; overflow: hidden;
  background: var(--s-bg); color: var(--s-ink);
  display: flex; flex-direction: column; font-size: 13px;
}
.scr--dark { --s-bg:#111319; --s-card:#1a1d26; --s-line:rgba(255,255,255,.08); --s-line2:rgba(255,255,255,.16); --s-ink:#eceef4; --s-soft:#9aa0af; }
.scr__status { display: flex; justify-content: space-between; align-items: center; padding: 13px 22px 2px; font-size: 12px; font-weight: 600; }
.scr__sig { width: 20px; height: 10px; border: 1.3px solid currentColor; border-radius: 2.5px; opacity: .5; position: relative; }
.scr__sig::before { content:''; position:absolute; top:1.6px; bottom:1.6px; left:1.6px; right:5px; background: currentColor; border-radius:1px; }
.scr__sig::after { content:''; position:absolute; right:-3px; top:50%; transform:translateY(-50%); width:1.6px; height:4px; background:currentColor; border-radius:0 1px 1px 0; }
.scr__bar { font-family: var(--font-sans); font-weight: 700; font-size: 15px; padding: 8px 18px 12px; letter-spacing: -0.01em; }
.scr__pad { flex: 1; padding: 0 14px; display: flex; flex-direction: column; gap: 9px; overflow: hidden; }

/* Tiles de la galería */
.tile { display: flex; align-items: center; gap: 11px; background: var(--s-card); border: 1px solid var(--s-line); border-radius: 14px; padding: 10px 12px; }
.tile__ic { width: 38px; height: 38px; border-radius: 10px; display: grid; place-items: center; font-size: 0; color: var(--ic); background: color-mix(in srgb, var(--ic) 15%, transparent); flex: none; }
.tile__ic svg { width: 20px; height: 20px; }
.tile__t { flex: 1; font-weight: 600; font-size: 13.5px; }
.tile__ch { color: var(--s-soft); font-size: 20px; line-height: 1; }
.c-blue{--ic:var(--c-blue)} .c-violet{--ic:var(--c-violet)} .c-sky{--ic:var(--c-sky)} .c-green{--ic:var(--c-green)} .c-amber{--ic:var(--c-amber)} .c-pink{--ic:var(--c-pink)} .c-teal{--ic:var(--c-teal)} .c-orange{--ic:var(--c-orange)}

/* Nav flotante de la app */
.scr__nav { margin: 6px 16px 16px; height: 54px; background: var(--s-card); border: 1px solid var(--s-line); border-radius: 20px; display: flex; align-items: center; justify-content: space-around; box-shadow: 0 8px 22px -8px rgba(10,12,25,.28); }
.nvi { color: var(--s-soft); font-size: 0; display: grid; place-items: center; }
.nvi svg { width: 23px; height: 23px; }
.nvi--on { color: var(--brand); }

/* Widgets UI Kit */
.kit { padding-top: 4px; gap: 11px; }
.w-btn { border-radius: 12px; padding: 12px; text-align: center; font-weight: 600; font-size: 13.5px; }
.w-btn--primary { background: var(--c-blue); color: #fff; }
.w-btn--outline { border: 1.5px solid var(--s-line2); color: var(--s-ink); }
.chips { display: flex; flex-wrap: wrap; gap: 7px; }
.chip { font-size: 11px; font-weight: 600; padding: 5px 11px; border-radius: 999px; }
.chip--green{ color:var(--c-green); background: color-mix(in srgb, var(--c-green) 17%, transparent);}
.chip--amber{ color:var(--c-amber); background: color-mix(in srgb, var(--c-amber) 17%, transparent);}
.chip--red{ color:var(--c-red); background: color-mix(in srgb, var(--c-red) 17%, transparent);}
.chip--blue{ color:var(--c-blue); background: color-mix(in srgb, var(--c-blue) 17%, transparent);}
.w-field { display: flex; flex-direction: column; gap: 5px; margin-top: 2px; }
.w-field__lbl { font-size: 11px; font-weight: 600; color: var(--s-soft); }
.w-field__box { border: 1px solid var(--s-line2); border-radius: 10px; padding: 11px 12px; font-size: 12.5px; color: var(--s-soft); background: var(--s-card); }
.w-switch { display: flex; align-items: center; justify-content: space-between; font-size: 12.5px; font-weight: 500; margin-top: 4px; }
.tgl { width: 38px; height: 22px; border-radius: 999px; background: var(--s-line2); position: relative; transition: background .2s; }
.tgl::after { content:''; position:absolute; top:2px; left:2px; width:18px; height:18px; border-radius:50%; background:#fff; box-shadow:0 1px 2px rgba(0,0,0,.3); transition: transform .2s; }
.tgl--on { background: var(--c-blue); }
.tgl--on::after { transform: translateX(16px); }

/* Búsqueda */
.search { display: flex; align-items: center; gap: 9px; background: var(--s-card); border: 1px solid var(--s-line); border-radius: 12px; padding: 11px 13px; font-size: 13px; color: var(--s-soft); }
.search__ic { font-size: 0; color: var(--s-soft); }
.search__ic svg { width: 17px; height: 17px; }
.ucard { display: flex; align-items: center; gap: 11px; padding: 9px 3px; border-bottom: 1px solid var(--s-line); }
.ava { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; font-weight: 700; font-size: 13px; color: #fff; flex: none; }
.ava--1{background:var(--c-blue)} .ava--2{background:var(--c-violet)} .ava--3{background:var(--c-pink)} .ava--4{background:var(--c-teal)}
.ucard__b b { display: block; font-size: 13.5px; font-weight: 600; }
.ucard__b small { font-size: 11.5px; color: var(--s-soft); }

/* ── Stack ─────────────────────────────────────────────────────────────── */
.stack { background: var(--bg-2); border-block: 1px solid var(--line); }
.stack__inner { display: flex; align-items: center; gap: clamp(20px, 4vw, 44px); flex-wrap: wrap; padding-block: 26px; }
.stack__lbl { font-family: var(--font-mono); font-size: 12px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); white-space: nowrap; }
.stack__list { list-style: none; padding: 0; display: flex; flex-wrap: wrap; gap: clamp(18px, 3vw, 36px); }
.stack__list li { font-family: var(--font-sans); font-weight: 700; font-size: 17px; color: var(--ink-soft); }

/* ── Pilares ───────────────────────────────────────────────────────────── */
.pillars { display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(24px, 4vw, 48px); padding-block: clamp(56px, 8vw, 92px); }
.pillar__ic { width: 50px; height: 50px; border-radius: 14px; background: var(--brand-soft); color: var(--brand); display: grid; place-items: center; margin-bottom: 18px; }
.pillar__ic svg { width: 26px; height: 26px; }
.pillar h3 { font-weight: 700; font-size: 1.35rem; margin-bottom: 9px; }
.pillar p { color: var(--ink-soft); font-size: 1.02rem; line-height: 1.55; }

/* ── Showcase ──────────────────────────────────────────────────────────── */
.show { padding-block: clamp(48px, 7vw, 80px); background: var(--bg-2); border-top: 1px solid var(--line); }
.show__head { text-align: center; max-width: 40rem; margin: 0 auto clamp(36px, 5vw, 60px); }
.feature { display: grid; grid-template-columns: 1fr 1fr; align-items: center; gap: clamp(28px, 5vw, 72px); padding-block: clamp(36px, 5vw, 64px); }
.feature--rev .feature__text { order: 2; }
.feature__text h3 { margin-bottom: 14px; }
.feature__text p { color: var(--ink-soft); font-size: 1.08rem; line-height: 1.6; margin-bottom: 20px; max-width: 32em; }
.feature__art { display: grid; place-items: center; }
.feature__art .phone { transform: rotate(-1.5deg); }
.feature--rev .feature__art .phone { transform: rotate(1.5deg); }

/* ── Grid incluido ─────────────────────────────────────────────────────── */
.section { padding-block: clamp(56px, 8vw, 96px); }
.section__head { max-width: 40rem; margin-bottom: clamp(36px, 5vw, 56px); }
.section__sub { margin-top: 14px; color: var(--ink-soft); font-size: 1.08rem; max-width: 34em; }
.grid { list-style: none; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 14px; }
.grid li { padding: 24px 22px; border: 1px solid var(--line); border-radius: 16px; background: var(--bg); transition: border-color .2s ease, transform .2s ease; }
.grid li:hover { border-color: var(--line-2); transform: translateY(-3px); }
.grid__ic { width: 42px; height: 42px; border-radius: 11px; background: var(--brand-soft); color: var(--brand); display: grid; place-items: center; margin-bottom: 14px; }
.grid__ic svg { width: 22px; height: 22px; }
.grid h4 { font-weight: 700; font-size: 1.12rem; margin-bottom: 7px; }
.grid p { color: var(--ink-soft); font-size: 0.96rem; line-height: 1.5; }
.grid code { color: var(--brand); }

/* ── Empezar ───────────────────────────────────────────────────────────── */
.start { background: var(--bg-2); border-block: 1px solid var(--line); }
.start__inner { padding-block: clamp(56px, 8vw, 92px); display: grid; grid-template-columns: 0.85fr 1.15fr; gap: clamp(32px, 5vw, 64px); align-items: start; }
.start__head { position: sticky; top: 90px; }
.steps { list-style: none; padding: 0; display: grid; gap: 14px; }
.step { display: grid; grid-template-columns: 48px 1fr; gap: 18px; align-items: center; background: var(--bg); border: 1px solid var(--line); border-radius: 16px; padding: 22px 24px; }
.step__n { width: 40px; height: 40px; border-radius: 11px; background: var(--brand); color: #fff; font-family: var(--font-sans); font-weight: 800; font-size: 1.1rem; display: grid; place-items: center; }
.step h4 { font-weight: 700; font-size: 1.12rem; margin-bottom: 12px; }
.cmd { background: color-mix(in srgb, var(--ink) 5%, transparent); border: 1px solid var(--line); border-radius: 9px; padding: 12px 15px; font-family: var(--font-mono); font-size: 13px; color: var(--ink); overflow-x: auto; }
:root[data-theme='dark'] .cmd { background: rgba(0,0,0,.35); }
.c-p { color: var(--brand); user-select: none; margin-right: 9px; }

/* ── CTA ───────────────────────────────────────────────────────────────── */
.cta { background: var(--brand); color: #fff; }
.cta__inner { padding-block: clamp(60px, 8vw, 100px); text-align: center; }
.cta__title { font-family: var(--font-sans); font-weight: 800; font-size: clamp(2rem, 4vw, 3rem); letter-spacing: -0.03em; color: #fff; }
.cta__sub { margin: 16px auto 32px; max-width: 30em; font-size: 1.1rem; color: rgba(255,255,255,.85); }

/* ── Footer ────────────────────────────────────────────────────────────── */
.foot { border-top: 1px solid var(--line); }
.foot__inner { display: grid; grid-template-columns: 1.6fr 1fr 1fr auto; gap: 32px; align-items: start; padding-block: 44px; }
.foot__note { margin-top: 12px; color: var(--muted); font-size: 0.93rem; max-width: 26em; }
.foot__links { display: flex; flex-direction: column; gap: 10px; }
.foot__links a { color: var(--ink-soft); font-size: 0.95rem; width: fit-content; }
.foot__links a:hover { color: var(--ink); }
.foot__meta { font-family: var(--font-mono); font-size: 12px; color: var(--muted); align-self: end; }

/* ── Reveal ────────────────────────────────────────────────────────────── */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity .6s ease, transform .6s ease; }
.reveal.is-visible { opacity: 1; transform: none; }

/* ── Responsive ────────────────────────────────────────────────────────── */
@media (max-width: 940px) {
  .hero__grid { grid-template-columns: 1fr; }
  .hero__art { margin-top: 24px; }
  .phones { min-height: 500px; }
  .phone--back { display: none; }
  .phone--front { transform: none; }
  .pillars { grid-template-columns: 1fr; gap: 28px; }
  .feature, .feature--rev .feature__text { grid-template-columns: 1fr; }
  .feature__text { order: 1 !important; }
  .feature__art { order: 2; }
  .start__inner { grid-template-columns: 1fr; }
  .start__head { position: static; }
  .foot__inner { grid-template-columns: 1fr 1fr; gap: 28px; }
  .foot__brand { grid-column: 1 / -1; }
  .foot__meta { align-self: start; grid-column: 1 / -1; }
}
@media (max-width: 620px) {
  .nav__links { display: none; }
  .nav__burger { display: flex; }
  .nav__actions .btn--sm { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  * { scroll-behavior: auto !important; }
  .reveal { opacity: 1; transform: none; transition: none; }
}
