/* ==========================================================================
   Biso — landing institucional (demo)
   Paleta y tipografía tomadas 1:1 de src/theme/tokens.ts para que esta
   página no divirja del lenguaje visual real de la app.
   ========================================================================== */

:root {
  --yellow-500: #F6C500;
  --yellow-600: #D9AD00;
  --yellow-100: #FBE9A8;

  --text-900: #18181B;
  --text-700: #3F3F46;
  --text-500: #71717A;
  --text-400: #A1A1AA;
  --border-200: #E4E4E7;
  --surface-100: #FAFAFA;
  --white: #FFFFFF;

  --success: #15803D;

  --font-body: 'Plus Jakarta Sans', system-ui, sans-serif;
  --font-brand: 'Quicksand', system-ui, sans-serif;

  --radius-sm: 6px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-photo: 20px;
  --radius-full: 999px;

  --shadow-card: 0 1px 4px rgba(0, 0, 0, 0.06);
  --shadow-lift: 0 20px 45px rgba(24, 24, 27, 0.12);

  --header-h: 76px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--text-900);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
ul { margin: 0; padding: 0; list-style: none; }
h1, h2, h3 { font-family: var(--font-brand); font-weight: 700; margin: 0; color: var(--text-900); }
p { margin: 0; line-height: 1.6; }

.container {
  max-width: 1160px;
  margin: 0 auto;
  padding: 0 24px;
}

/* Textura sutil para que los bloques de color no queden planos */
.noise-overlay {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 9999;
  opacity: 0.025;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  mix-blend-mode: overlay;
}

/* ---------- Botones ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 15px;
  padding: 12px 22px;
  border-radius: var(--radius-full);
  border: none;
  cursor: pointer;
  transition: transform .18s ease, background .18s ease, box-shadow .18s ease, border-color .18s ease;
  white-space: nowrap;
}
.btn:active { transform: scale(0.97); }
.btn-primary { background: var(--yellow-500); color: var(--text-900); }
.btn-primary:hover { background: var(--yellow-600); box-shadow: 0 8px 24px rgba(246, 197, 0, 0.35); }
.btn-outline { background: transparent; color: var(--text-900); border: 1.5px solid var(--yellow-500); }
.btn-outline:hover { background: var(--yellow-100); }
.btn-ghost { background: transparent; color: var(--text-700); border: 1px solid var(--border-200); }
.btn-ghost:hover { background: var(--surface-100); }
.btn-lg { padding: 15px 28px; font-size: 16px; }
.btn-block { width: 100%; }

/* ---------- Header ---------- */
.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  height: var(--header-h);
  display: flex;
  align-items: center;
  background: rgba(255, 255, 255, 0.72);
  backdrop-filter: blur(14px) saturate(1.4);
  -webkit-backdrop-filter: blur(14px) saturate(1.4);
  border-bottom: 1px solid rgba(228, 228, 231, 0.7);
  transition: box-shadow .2s ease;
}
.site-header.scrolled { box-shadow: 0 4px 24px rgba(24,24,27,0.06); }
/*
 * Patrón logo-izquierda / nav-centro / acciones-derecha: NO usar
 * justify-content:space-between acá — con 3 hermanos de ancho distinto
 * (logo angosto vs. bloque de acciones más ancho), space-between reparte
 * el espacio libre en gaps IGUALES a los costados del nav, pero como los
 * vecinos no pesan lo mismo, el nav termina centrado respecto a sus
 * vecinos, no respecto a la página — se ve corrido hacia el lado del
 * vecino más angosto. En cambio, dejando que `.main-nav` sea el único
 * flex:1 (crece para ocupar TODO el espacio sobrante) y centrando sus
 * links puertas adentro, el nav queda centrado en la página de verdad, sin
 * importar cuánto pesen logo/acciones a los costados — y ambos quedan
 * anclados a sus bordes reales porque no compiten por crecer.
 */
.header-inner { display: flex; align-items: center; gap: 20px; }
.brand { flex-shrink: 0; }
.brand-logo { height: 42px; width: auto; }
.main-nav { flex: 1; display: flex; justify-content: center; gap: 32px; }
.main-nav a { font-size: 14.5px; font-weight: 600; color: var(--text-700); position: relative; padding: 4px 0; }
.main-nav a::after {
  content: ''; position: absolute; left: 0; bottom: -2px; width: 0; height: 2px;
  background: var(--yellow-500); transition: width .2s ease;
}
.main-nav a:hover::after { width: 100%; }
.header-actions { flex-shrink: 0; display: flex; gap: 10px; align-items: center; }
.nav-toggle { display: none; flex-shrink: 0; }

/* ---------- Reveal on scroll ---------- */
.reveal { opacity: 0; transform: translateY(28px); transition: opacity .7s cubic-bezier(.16,1,.3,1), transform .7s cubic-bezier(.16,1,.3,1); }
.reveal.is-visible { opacity: 1; transform: translateY(0); }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  padding: calc(var(--header-h) + 76px) 0 90px;
  overflow: hidden;
}
.hero-blobs { position: absolute; inset: 0; z-index: 0; }
.blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(60px);
  opacity: 0.35;
  animation: float 16s ease-in-out infinite;
}
.blob-1 { width: 420px; height: 420px; background: var(--yellow-500); top: -140px; right: -120px; }
.blob-2 { width: 280px; height: 280px; background: var(--yellow-100); bottom: -80px; left: -60px; animation-delay: -5s; }
.blob-3 { width: 200px; height: 200px; background: #FDE68A; top: 40%; left: 55%; animation-delay: -10s; opacity: .25; }
@keyframes float {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(-30px, 30px) scale(1.08); }
}

.hero-inner {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 56px;
  align-items: center;
}
.eyebrow {
  display: inline-block;
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 12.5px;
  letter-spacing: 1.6px;
  text-transform: uppercase;
  color: var(--text-700);
  background: var(--yellow-100);
  padding: 6px 14px;
  border-radius: var(--radius-full);
  margin-bottom: 20px;
}
.eyebrow-light { background: rgba(246,197,0,0.16); color: var(--yellow-500); }

.hero h1 {
  font-size: clamp(34px, 4.6vw, 54px);
  line-height: 1.08;
  letter-spacing: -0.5px;
  margin-bottom: 22px;
}
.hero-sub { font-size: 17.5px; color: var(--text-500); max-width: 480px; margin-bottom: 32px; }
.hero-ctas { display: flex; gap: 14px; flex-wrap: wrap; margin-bottom: 28px; }
.hero-ctas .btn svg { transition: transform .18s ease; }
.hero-ctas .btn:hover svg { transform: translateX(3px); }
.hero-badges { display: flex; gap: 10px; flex-wrap: wrap; }
.badge {
  font-size: 12.5px;
  font-weight: 600;
  color: var(--text-700);
  background: var(--surface-100);
  border: 1px solid var(--border-200);
  padding: 6px 12px;
  border-radius: var(--radius-full);
}

/* ---------- Phone mockup ---------- */
.hero-visual { position: relative; display: flex; justify-content: center; }
.phone-mock {
  width: 280px;
  height: 570px;
  background: var(--text-900);
  border-radius: 42px;
  padding: 14px;
  box-shadow: var(--shadow-lift), 0 0 0 1px rgba(24,24,27,0.06);
  position: relative;
  animation: hover-phone 6s ease-in-out infinite;
}
@keyframes hover-phone {
  0%, 100% { transform: translateY(0) rotate(-1.2deg); }
  50% { transform: translateY(-14px) rotate(1deg); }
}
.phone-notch {
  position: absolute;
  top: 14px; left: 50%; transform: translateX(-50%);
  width: 110px; height: 22px;
  background: var(--text-900);
  border-radius: 0 0 16px 16px;
  z-index: 2;
}
.phone-screen {
  background: var(--white);
  width: 100%; height: 100%;
  border-radius: 30px;
  padding: 34px 16px 16px;
  overflow: hidden;
  position: relative;
}
.mock-header { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 14px; }
.mock-greeting { font-family: var(--font-brand); font-weight: 700; font-size: 15px; color: var(--text-900); margin: 0 0 3px; }
.mock-address {
  display: flex; align-items: center; gap: 4px;
  font-size: 10.5px; font-weight: 600; color: var(--text-500); margin: 0;
}
.mock-address svg { flex-shrink: 0; color: var(--yellow-600); }
.mock-bell {
  width: 30px; height: 30px;
  border-radius: 50%;
  background: var(--surface-100);
  display: flex; align-items: center; justify-content: center;
  color: var(--text-700);
  flex-shrink: 0;
}
.mock-search {
  display: flex; align-items: center; gap: 8px;
  height: 38px; padding: 0 14px;
  border-radius: var(--radius-full);
  background: var(--surface-100);
  border: 1px solid var(--border-200);
  color: var(--text-400);
  font-size: 12px; font-weight: 600;
  margin-bottom: 14px;
}

.mock-tracking-card {
  border-radius: var(--radius-md);
  background: var(--text-900);
  overflow: hidden;
  margin-bottom: 14px;
  box-shadow: var(--shadow-card);
}
.mock-tracking-map { height: 56px; background: linear-gradient(135deg, #2A2A30, #18181B); }
.mock-tracking-info { display: flex; align-items: center; gap: 8px; padding: 10px 12px; }
.mock-tracking-dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--yellow-500);
  box-shadow: 0 0 0 4px rgba(246,197,0,0.22);
  flex-shrink: 0;
  animation: pulse-dot 1.8s ease-in-out infinite;
}
@keyframes pulse-dot { 0%, 100% { opacity: 1; } 50% { opacity: .4; } }
.mock-tracking-title { font-size: 11.5px; font-weight: 700; color: var(--white); margin: 0; }
.mock-tracking-sub { font-size: 10px; color: var(--text-400); margin: 2px 0 0; }

.mock-chips { display: flex; gap: 6px; margin-bottom: 14px; }
.mock-chip {
  font-size: 10.5px; font-weight: 700;
  padding: 6px 12px;
  border-radius: var(--radius-full);
  background: var(--surface-100);
  color: var(--text-500);
  border: 1px solid var(--border-200);
}
.mock-chip-active { background: var(--yellow-500); color: var(--text-900); border-color: var(--yellow-500); }

.mock-section-title { font-size: 11px; font-weight: 700; color: var(--text-700); margin: 0 0 10px; }
.mock-row { display: flex; gap: 10px; margin-bottom: 16px; }
.mock-card {
  flex: 1;
  background: var(--white);
  border: 1px solid var(--border-200);
  border-radius: var(--radius-md);
  padding: 8px;
  box-shadow: var(--shadow-card);
}
.mock-card-photo { height: 52px; border-radius: 8px; background: var(--surface-100); margin-bottom: 8px; }
.mock-card-photo.alt { background: var(--yellow-100); }
.mock-card-title { font-size: 11.5px; font-weight: 700; color: var(--text-900); margin: 0 0 4px; }
.mock-card-meta { display: flex; justify-content: space-between; font-size: 9.5px; font-weight: 600; color: var(--text-500); }
.mock-fab {
  position: absolute;
  bottom: 18px; right: 16px;
  width: 46px; height: 46px;
  border-radius: 50%;
  background: var(--yellow-500);
  box-shadow: 0 6px 16px rgba(246,197,0,.5);
  display: flex; align-items: center; justify-content: center;
}

/* ---------- Secciones genéricas ---------- */
.section { padding: 100px 0; }
.section-tint { background: var(--surface-100); }
.section-head { max-width: 640px; margin: 0 auto 56px; text-align: center; }
.section-head h2 { font-size: clamp(26px, 3.2vw, 38px); }
.section-sub { color: var(--text-500); font-size: 16.5px; max-width: 480px; margin: 16px 0 24px; }

/* ---------- Cómo funciona ---------- */
.steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }
.step {
  background: var(--white);
  border: 1px solid var(--border-200);
  border-radius: var(--radius-lg);
  padding: 28px 22px;
  position: relative;
  transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
}
.step:hover { transform: translateY(-6px); box-shadow: var(--shadow-lift); border-color: transparent; }
.step-icon {
  width: 52px; height: 52px;
  border-radius: 14px;
  background: var(--yellow-100);
  color: var(--text-900);
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 18px;
}
.step-num { position: absolute; top: 24px; right: 22px; font-family: var(--font-brand); font-weight: 700; font-size: 22px; color: var(--border-200); }
.step h3 { font-size: 18px; margin-bottom: 8px; }
.step p { color: var(--text-500); font-size: 14.5px; }

/* ---------- Cobertura (dark) ---------- */
.section-dark { background: var(--text-900); color: var(--white); }
.section-dark h2 { color: var(--white); }
.section-dark .section-sub { color: var(--text-400); }
.cobertura-inner { display: grid; grid-template-columns: 1fr 0.9fr; gap: 56px; align-items: center; }
.check-list li {
  position: relative;
  padding-left: 28px;
  margin-bottom: 14px;
  font-size: 15px;
  color: var(--text-500);
}
.section-dark .check-list li { color: var(--text-400); }
.check-list li::before {
  content: '✓';
  position: absolute; left: 0; top: -1px;
  width: 20px; height: 20px;
  border-radius: 50%;
  background: var(--yellow-500);
  color: var(--text-900);
  font-size: 12px; font-weight: 800;
  display: flex; align-items: center; justify-content: center;
}
.map-illustration { aspect-ratio: 1; max-width: 340px; margin: 0 auto; }
.map-pins circle:not(:first-child) { animation: pin-pulse 2.4s ease-in-out infinite; }
.map-pins circle:nth-child(3) { animation-delay: .3s; }
.map-pins circle:nth-child(4) { animation-delay: .6s; }
.map-pins circle:nth-child(5) { animation-delay: .9s; }
.map-pins circle:nth-child(6) { animation-delay: 1.2s; }
@keyframes pin-pulse { 0%, 100% { opacity: .5; } 50% { opacity: 1; } }

/* ---------- Split (comercios / repartidores) ---------- */
.split { display: grid; grid-template-columns: 0.85fr 1.15fr; gap: 64px; align-items: center; }
.split-reverse { grid-template-columns: 1.15fr 0.85fr; }
.split-reverse .split-visual { order: 2; }
.stat-card {
  background: var(--white);
  border: 1px solid var(--border-200);
  border-radius: var(--radius-lg);
  padding: 28px;
  box-shadow: var(--shadow-card);
}
.stat-card-dark { background: var(--text-900); border-color: var(--text-900); }
.stat-row { display: flex; justify-content: space-between; align-items: center; padding: 14px 0; border-bottom: 1px solid var(--border-200); }
.stat-card-dark .stat-row { border-bottom-color: rgba(255,255,255,0.12); }
.stat-row:last-child { border-bottom: none; }
.stat-row span { font-size: 13.5px; color: var(--text-500); }
.stat-card-dark .stat-row span { color: var(--text-400); }
.stat-row strong { font-size: 15px; }
.stat-card-dark .stat-row strong { color: var(--white); }

/* ---------- CTA descarga ---------- */
.section-cta { background: linear-gradient(160deg, var(--yellow-100), var(--white) 60%); text-align: center; }
.cta-inner { display: flex; flex-direction: column; align-items: center; }
.cta-isologo { width: 64px; margin-bottom: 20px; }
.section-cta h2 { font-size: clamp(28px, 3.6vw, 42px); margin-bottom: 12px; }
.section-cta p { color: var(--text-700); font-size: 17px; margin-bottom: 32px; }
.store-badges { display: flex; gap: 16px; flex-wrap: wrap; justify-content: center; }
.store-badge {
  display: flex; align-items: center; gap: 10px;
  background: var(--text-900); color: var(--white);
  padding: 12px 22px;
  border-radius: var(--radius-md);
  transition: transform .18s ease, background .18s ease;
}
.store-badge:hover { transform: translateY(-3px); background: #000; }
.store-badge small { display: block; font-size: 11px; opacity: .7; }
.store-badge strong { display: block; font-size: 15px; }
.store-badges-compact { margin-bottom: 18px; }

/* ---------- Footer ---------- */
.site-footer { background: var(--text-900); color: var(--text-400); padding: 56px 0 32px; }
.footer-inner { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 18px; }
.footer-logo { height: 36px; }
.footer-tagline { font-family: var(--font-brand); font-weight: 600; color: var(--white); font-size: 15px; }
.footer-nav { display: flex; gap: 26px; flex-wrap: wrap; justify-content: center; }
.footer-nav a { font-size: 13.5px; font-weight: 600; }
.footer-nav a:hover { color: var(--yellow-500); }
.footer-copy { font-size: 12.5px; margin-top: 14px; }

/* ---------- Login overlay (demo) ---------- */
.overlay {
  position: fixed; inset: 0; z-index: 200;
  display: flex; align-items: center; justify-content: center;
  visibility: hidden; opacity: 0;
  transition: opacity .25s ease, visibility .25s ease;
}
.overlay.is-open { visibility: visible; opacity: 1; }
.overlay-backdrop { position: absolute; inset: 0; background: rgba(24,24,27,0.55); backdrop-filter: blur(4px); }
.login-panel {
  position: relative;
  background: var(--white);
  width: min(420px, calc(100% - 32px));
  border-radius: 22px;
  padding: 36px 32px 32px;
  box-shadow: var(--shadow-lift);
  transform: translateY(18px) scale(.97);
  transition: transform .3s cubic-bezier(.16,1,.3,1);
}
.overlay.is-open .login-panel { transform: translateY(0) scale(1); }
.overlay-close {
  position: absolute; top: 16px; right: 16px;
  width: 32px; height: 32px; border-radius: 50%;
  border: none; background: var(--surface-100); color: var(--text-500);
  cursor: pointer; font-size: 14px;
}
.overlay-close:hover { background: var(--border-200); }
.login-mark { width: 44px; margin-bottom: 14px; }
.login-panel h3 { font-size: 21px; margin-bottom: 8px; }
.login-sub { color: var(--text-500); font-size: 14px; margin-bottom: 22px; }
.login-tabs {
  display: flex;
  background: var(--surface-100);
  border-radius: var(--radius-full);
  padding: 4px;
  margin-bottom: 20px;
}
.login-tab {
  flex: 1;
  border: none;
  background: transparent;
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 13.5px;
  color: var(--text-500);
  padding: 9px 10px;
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: background .18s ease, color .18s ease;
}
.login-tab.is-active { background: var(--white); color: var(--text-900); box-shadow: var(--shadow-card); }
.field { display: block; margin-bottom: 16px; }
.field span { display: block; font-size: 12.5px; font-weight: 700; color: var(--text-700); margin-bottom: 6px; }
.field input, .field select {
  width: 100%;
  font-family: var(--font-body);
  font-size: 15px;
  padding: 12px 14px;
  border-radius: var(--radius-md);
  border: 1.5px solid var(--border-200);
  background: var(--white);
  color: var(--text-900);
  outline: none;
  transition: border-color .18s ease;
}
.field input:focus, .field select:focus { border-color: var(--yellow-500); }
.login-step[hidden] { display: none; }
.construccion-badge { font-size: 40px; margin-bottom: 8px; }

/* ---------- Responsive ---------- */
@media (max-width: 920px) {
  .hero-inner, .cobertura-inner, .split, .split-reverse { grid-template-columns: 1fr; }
  .split-reverse .split-visual { order: 0; }
  .steps { grid-template-columns: repeat(2, 1fr); }
  /* Sin .main-nav (oculto), .header-inner queda con sólo 2-3 hermanos de
     ancho fijo (logo, botón Descargar, hamburguesa) — acá sí conviene
     space-between (ancla el primero y el último a los bordes reales), y
     el `gap` de la regla base sigue de piso para que nunca se toquen
     aunque el contenido sea angosto. */
  .header-inner { justify-content: space-between; }
  .main-nav { display: none; }
  .header-actions .btn-ghost { display: none; }
  .nav-toggle {
    display: flex; flex-direction: column; justify-content: center; gap: 5px;
    width: 40px; height: 40px; border: none; background: none; cursor: pointer;
  }
  .nav-toggle span { display: block; height: 2px; background: var(--text-900); border-radius: 2px; }
  .hero-visual { margin-top: 24px; }
}
@media (max-width: 600px) {
  .steps { grid-template-columns: 1fr; }
  .section { padding: 70px 0; }
  .hero { padding-top: calc(var(--header-h) + 48px); }
  .phone-mock { width: 240px; height: 490px; }
}
