/* ==========================================================================
   WAPPTI - GLOBAL STYLES
   ========================================================================== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --teal:    #2BB5A0;
  --teal-dk: #1e9080;
  --orange:  #E07B39;
  --orange-dk:#c96a28;
  --dark:    #1A2B2F;
  --text:    #3D4F52;
  --muted:   #6B7F82;
  --bg-gray: #F4F6F7;
  --white:   #ffffff;
  --border:  #DDE3E4;
  --radius:  14px;
}

html { scroll-behavior: smooth; }

body {
  font-family: 'Nunito', sans-serif;
  color: var(--text);
  background: var(--white);
  overflow-x: hidden;
}

/* ==========================================================================
   1. NAVIGATION (HEADER)
   ========================================================================== */
nav {
  position: sticky; top: 0; z-index: 100;
  background: var(--white);
  border-bottom: 1px solid var(--border);
  padding: 0 5%;
  display: flex; align-items: center; justify-content: space-between;
  height: 64px;
}

.logo {
  font-size: 1.7rem; font-weight: 900;
  color: var(--teal); text-decoration: none;
  letter-spacing: -1px;
  z-index: 101; /* Asegura que el logo esté por encima del menú móvil */
}

/* Enlaces del menú */
.nav-links {
  display: flex; gap: 2rem; align-items: center;
}

.nav-links a.nav-item {
  text-decoration: none; color: var(--text);
  font-weight: 600; font-size: 0.95rem;
  transition: color .2s;
}

.nav-links a.nav-item:hover { color: var(--teal); }
.nav-links a.active { color: var(--orange); border-bottom: 2px solid var(--orange); padding-bottom: 2px; }

/* Contenedor del Botón de Descarga y Hamburguesa */
.nav-actions {
  display: flex;
  align-items: center;
  gap: 1rem;
  z-index: 101;
}

/* Botón Destacado del Nav (Descargar App) */
.nav-cta {
  background: var(--teal);
  color: #fff !important;
  padding: 0.6rem 1.3rem;
  border-radius: 50px;
  font-weight: 700;
  font-size: 0.9rem;
  text-decoration: none;
  transition: all 0.3s ease;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  box-shadow: 0 4px 12px rgba(43, 181, 160, 0.2);
}

.nav-cta:hover {
  background: var(--teal-dk);
  transform: translateY(-2px);
  box-shadow: 0 6px 15px rgba(43, 181, 160, 0.3);
}

/* Menú Hamburguesa (Oculto en PC) */
.hamburger {
  display: none;
  background: none;
  border: none;
  font-size: 1.4rem;
  color: var(--dark);
  cursor: pointer;
  transition: color 0.2s;
}
.hamburger:hover { color: var(--teal); }


/* ==========================================================================
   2. BUTTONS (COMPONENTES)
   ========================================================================== */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: .75rem 1.6rem; border-radius: 50px;
  font-family: inherit; font-weight: 700; font-size: 1rem;
  cursor: pointer; text-decoration: none; border: none;
  transition: transform .15s, box-shadow .15s, background .2s;
}
.btn:hover { transform: translateY(-2px); }

.btn-orange {
  background: var(--orange); color: var(--white);
  box-shadow: 0 4px 14px rgba(224,123,57,.35);
}
.btn-orange:hover { background: var(--orange-dk); box-shadow: 0 6px 20px rgba(224,123,57,.45); }

.btn-outline-white {
  background: transparent; color: var(--white);
  border: 2px solid rgba(255,255,255,.6);
}
.btn-outline-white:hover { background: rgba(255,255,255,.12); }

.btn-outline-teal {
  background: transparent; color: var(--teal);
  border: 2px solid var(--teal);
}
.btn-outline-teal:hover { background: var(--teal); color: white; }

/* Botones de App Store / Play Store */
.store-btn {
  display: flex; align-items: center; gap: .6rem;
  background: rgba(255,255,255,.15); border: 2px solid rgba(255,255,255,.4);
  color: white; border-radius: 10px; padding: .7rem 1.4rem;
  text-decoration: none; transition: background .2s;
  font-family: inherit;
}
.store-btn:hover { background: rgba(255,255,255,.25); }
.store-btn svg { width: 20px; height: 20px; fill: white; }
.store-btn-text { display: flex; flex-direction: column; }
.store-btn-text small { font-size: .65rem; opacity: .8; }
.store-btn-text strong { font-size: .9rem; font-weight: 800; }

/* ==========================================================================
   3. ANIMACIONES GLOBALES
   ========================================================================== */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(30px); }
  to   { opacity: 1; transform: translateY(0); }
}
.fade-up { animation: fadeUp .7s ease both; }
.delay-1 { animation-delay: .15s; }
.delay-2 { animation-delay: .3s; }
.delay-3 { animation-delay: .45s; }


/* ==========================================================================
   4. INDEX SECTIONS (Hero, Ventajas, etc)
   ========================================================================== */
/* HERO */
.hero {
  min-height: 65vh;
  display: grid; grid-template-columns: 1fr 1fr;
  align-items: center; gap: 2rem;
  padding: 4rem 8%;
  background: linear-gradient(135deg, #f9fafb 60%, #e8f6f4 100%);
  position: relative; overflow: hidden;
}
.hero::before {
  content: '';
  position: absolute; right: -100px; top: -100px;
  width: 500px; height: 500px; border-radius: 50%;
  background: radial-gradient(circle, rgba(43,181,160,.08) 0%, transparent 70%);
}
.hero-tag {
  font-size: .75rem; font-weight: 800; letter-spacing: 2px;
  text-transform: uppercase; color: var(--orange);
  margin-bottom: 1rem;
}
.hero h1 {
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 900; line-height: 1.15;
  color: var(--dark); margin-bottom: 1.2rem;
}
.hero p {
  font-size: 1rem; color: var(--muted);
  line-height: 1.7; margin-bottom: 2rem; max-width: 480px;
}
.hero-img {
  position: relative; display: flex; justify-content: center; align-items: center;
  max-width: 360px; margin: 0 auto;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

/* PARA QUIEN */
.para-quien { padding: 5rem 8%; background: var(--white); }
.para-quien-grid { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 2rem; margin-top: 2.5rem; }
.para-quien-left .label { font-size: .75rem; font-weight: 800; text-transform: uppercase; letter-spacing: 2px; color: var(--orange); margin-bottom: .8rem; }
.para-quien-left h2 { font-size: 1.3rem; font-weight: 800; color: var(--teal); line-height: 1.3; margin-bottom: .8rem; }
.para-quien-left p { font-size: .9rem; color: var(--muted); line-height: 1.7; }
.profesiones-col { display: flex; flex-direction: column; gap: .6rem; }
.prof-item { display: flex; align-items: center; gap: .5rem; font-size: .9rem; font-weight: 600; color: var(--text); }
.prof-item::before { content: '✓'; color: var(--teal); font-weight: 900; font-size: 1rem; }

/* CTA BAND */
.cta-band {
  margin: 0 5%; border-radius: 20px;
  background: linear-gradient(135deg, var(--teal) 0%, var(--teal-dk) 100%);
  padding: 2.5rem 4rem;
  display: flex; align-items: center; justify-content: space-between;
  gap: 2rem; flex-wrap: wrap;
}
.cta-band h2 { font-size: 1.6rem; font-weight: 900; color: white; }
.cta-band-btns { display: flex; gap: 1rem; flex-wrap: wrap; justify-content: center; align-items: center; }

/* VENTAJAS (Accordion) */
.ventajas { padding: 6rem 8%; background: var(--bg-gray); }
.ventajas h2 { text-align: center; font-size: 1.8rem; font-weight: 900; color: var(--dark); margin-bottom: 3rem; }
.ventajas-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 3rem; align-items: center; }
.accordion { display: flex; flex-direction: column; gap: .5rem; }
.accordion-item { border-bottom: 1px solid var(--border); padding-bottom: .8rem; cursor: pointer; }
.accordion-title { display: flex; align-items: center; gap: .6rem; font-size: .95rem; font-weight: 700; color: var(--teal); padding: .5rem 0; }
.accordion-title.active { color: var(--orange); }
.accordion-title .icon { font-size: 1rem; font-weight: 900; color: inherit; }
.accordion-body { font-size: .88rem; color: var(--muted); line-height: 1.7; padding: .4rem 0 .4rem 1.4rem; display: none; }
.accordion-body.open { display: block; }

/* DUO PHONES */
.phones-duo { display: flex; justify-content: center; align-items: flex-end; position: relative; }
.phone-small { width: 160px; height: 320px; background: #111; border-radius: 26px; border: 4px solid #222; overflow: hidden; box-shadow: 0 20px 50px rgba(0,0,0,.2); }
.phone-small-screen { width: 100%; height: 100%; }
.phone-small:first-child { transform: rotate(-6deg) translateX(20px); z-index: 1; }
.phone-small:first-child .phone-small-screen { background: linear-gradient(160deg, #2BB5A0 0%, #1e9080 100%); }
.phone-small:last-child { background: #E07B39; border-color: #d06928; transform: rotate(4deg) translateX(-10px); z-index: 2; box-shadow: 0 20px 50px rgba(224,123,57,.3); }
.phone-small:last-child .phone-small-screen { background: linear-gradient(160deg, #E07B39 0%, #c96a28 100%); }

/* TESTIMONIOS */
.testimonios { padding: 4rem 8%; background: #f9f9f9; text-align: center; }
.testimonios-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 2rem; margin-top: 3rem; }
.testimonio-card { background: white; padding: 2rem; border-radius: 15px; box-shadow: 0 10px 30px rgba(0,0,0,0.05); text-align: left; transition: transform 0.3s ease; display: flex; flex-direction: column; justify-content: space-between; }
.testimonio-card:hover { transform: translateY(-5px); }
.testimonio-stars { color: #FFB400; font-size: 1.2rem; margin-bottom: 1rem; letter-spacing: 2px; }
.testimonio-card p { font-style: italic; color: #555; line-height: 1.6; margin-bottom: 1.5rem; }
.testimonio-author strong { display: block; color: #333; font-size: 1.1rem; }
.testimonio-author span { color: #00bfa5; font-size: 0.85rem; font-weight: 600; }

/* PRECIOS */
.precios { padding: 6rem 8%; background: var(--bg-gray); }
.precios-card { max-width: 700px; margin: 0 auto; background: linear-gradient(135deg, #2a6b70 0%, #1e5055 100%); border-radius: 20px; padding: 3rem; box-shadow: 0 20px 60px rgba(30,80,85,.3); }
.precios-card h2 { text-align: center; color: white; font-size: 1.6rem; font-weight: 900; margin-bottom: 2rem; }
.precios-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1px; background: rgba(255,255,255,.1); border-radius: 10px; overflow: hidden; }
.precio-item { background: rgba(255,255,255,.06); padding: 1rem 1.5rem; display: flex; align-items: center; justify-content: space-between; transition: background .2s; }
.precio-item:hover { background: rgba(255,255,255,.12); }
.precio-item .gestiones { color: rgba(255,255,255,.8); font-size: .9rem; font-weight: 600; }
.precio-item .precio { color: white; font-size: 1.1rem; font-weight: 900; }
.precio-item .gratis { color: #4ade80; font-weight: 900; font-size: 1rem; }

/* FAQ */
.faq-section { padding: 6rem 8%; background: var(--white); }
.faq-section__title { text-align: center; font-size: 1.8rem; font-weight: 900; color: var(--dark); margin-bottom: 3rem; }
.faq-section__grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0 4rem; max-width: 1000px; margin: 0 auto; }
.faq-section__col { border-left: 3px solid var(--teal); padding-left: 1.5rem; display: flex; flex-direction: column; gap: 0; }
.faq-section__item { padding: 1.1rem 0; border-bottom: 1px solid var(--border); cursor: pointer; }
.faq-section__item:last-child { border-bottom: none; }
.faq-section__question { display: flex; align-items: center; gap: .6rem; font-size: .95rem; font-weight: 800; color: var(--orange); transition: color .2s; user-select: none; }
.faq-section__question:hover { color: var(--orange-dk); }
.faq-section__icon { font-size: .6rem; color: var(--orange); flex-shrink: 0; transition: transform .25s ease; }
.faq-section__item.open .faq-section__icon { transform: rotate(180deg); }
.faq-section__answer { font-size: .9rem; color: var(--text); line-height: 1.75; padding: 0 0 0 1.3rem; max-height: 0; overflow: hidden; transition: max-height .3s ease, padding .3s ease; }
.faq-section__item.open .faq-section__answer { max-height: 300px; padding: .6rem 0 .2rem 1.3rem; }


/* ==========================================================================
   5. PHONE MOCKUP (INTERACTIVO)
   ========================================================================== */
.phone-wrap-v3 { position: relative; width: 100%; z-index: 1; perspective: 1000px; }
.phone-svg-v3 { width: 100%; height: auto; display: block; filter: drop-shadow(0 25px 35px rgba(0, 0, 0, 0.35)) drop-shadow(0 5px 15px rgba(0, 0, 0, 0.2)); }
.stat-pill { position: absolute; display: flex; align-items: center; gap: 14px; background: rgba(32, 44, 51, 0.6); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px); border: 1px solid rgba(255, 255, 255, 0.12); padding: 12px 20px; border-radius: 100px; color: white; box-shadow: 0 12px 30px rgba(0, 0, 0, 0.25), inset 0 1px 0 rgba(255, 255, 255, 0.1); z-index: 10; opacity: 0; animation: floatIn 0.8s cubic-bezier(0.16, 1, 0.3, 1) forwards; }
.stat-pill:hover { transform: translateY(-5px) scale(1.02) !important; transition: all 0.3s ease; border-color: rgba(255, 255, 255, 0.25); }
.stat-pill__icon { display: flex; justify-content: center; align-items: center; width: 38px; height: 38px; border-radius: 50%; font-size: 16px; box-shadow: 0 4px 10px rgba(0,0,0,0.1); }
.stat-pill strong { display: block; font-size: 16px; line-height: 1.1; font-weight: 800; letter-spacing: -0.3px; }
.stat-pill span { display: block; font-size: 12px; color: rgba(255, 255, 255, 0.65); line-height: 1.4; font-weight: 500; }
.stat-pill--tr { top: 12%; right: -40%; animation-delay: 1.2s; }
.stat-pill--bl { bottom: 10%; left: -40%; animation-delay: 1.4s; }

/* Animaciones Chat Interno */
@keyframes messagePop { 0% { opacity: 0; transform: translateY(20px) scale(0.95); } 100% { opacity: 1; transform: translateY(0) scale(1); } }
@keyframes floatIn { 0% { opacity: 0; transform: translateY(15px); } 100% { opacity: 1; transform: translateY(0); } }
.wa-msg { opacity: 0; transform-origin: left bottom; }
.wa-msg.out { transform-origin: right bottom; }
.wa-msg-1 { animation: messagePop 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) forwards; animation-delay: 0.5s; }
.wa-msg-2 { animation: messagePop 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) forwards; animation-delay: 1.8s; }
.wa-msg-3 { animation: messagePop 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) forwards; animation-delay: 2.6s; }
.svg-txt { font-family: system-ui, -apple-system, sans-serif; }
.fw-medium { font-weight: 500; }
.fw-bold { font-weight: 600; }
.fw-black { font-weight: 800; }

/* Mockup Variables JS */
.phone-wrap { position: relative; flex-shrink: 0; }
.phone { width: 290px; height: 600px; background: #111; border-radius: 44px; border: 6px solid #1a1a1a; box-shadow: 0 0 0 1px #333, 0 40px 100px rgba(0,0,0,.4), 0 10px 30px rgba(0,0,0,.2), inset 0 0 0 1px #222; overflow: hidden; position: relative; }
.phone::before { content: ''; position: absolute; right: -8px; top: 100px; width: 4px; height: 60px; background: #222; border-radius: 0 3px 3px 0; box-shadow: 0 80px 0 #222; }
.phone::after { content: ''; position: absolute; left: -8px; top: 120px; width: 4px; height: 40px; background: #222; border-radius: 3px 0 0 3px; box-shadow: 0 55px 0 #222, 0 100px 0 #222; }
.screen { width: 100%; height: 100%; background: #0b141a; border-radius: 38px; overflow: hidden; display: flex; flex-direction: column; position: relative; }
.status-bar { display: flex; justify-content: space-between; align-items: center; padding: .4rem 1.2rem .2rem; background: #1f2c34; font-size: .62rem; color: rgba(255,255,255,.8); font-weight: 700; position: relative; z-index: 2; }
.notch { width: 70px; height: 18px; background: #111; border-radius: 0 0 12px 12px; position: absolute; top: 0; left: 50%; transform: translateX(-50%); }
.chat-header { background: #1f2c34; padding: .55rem .9rem; display: flex; align-items: center; gap: .6rem; position: relative; z-index: 2; border-bottom: 1px solid rgba(255,255,255,.05); }
.messages { flex: 1; padding: .7rem; overflow-y: auto; overflow-x: hidden; display: flex; flex-direction: column; gap: .4rem; position: relative; z-index: 1; scrollbar-width: none; }
.msg { max-width: 87%; border-radius: 10px; font-size: .67rem; line-height: 1.55; color: rgba(255,255,255,.92); padding: .5rem .7rem .3rem; opacity: 0; animation: fadeSlideUp .35s ease forwards; }
.msg-in { background: #202c33; align-self: flex-start; border-radius: 0 10px 10px 10px; }
.msg-out { background: #005c4b; align-self: flex-end; border-radius: 10px 10px 0 10px; }
.typing { background: #202c33; border-radius: 0 10px 10px 10px; padding: .45rem .7rem; align-self: flex-start; display: none; gap: 4px; align-items: center; }
.typing.visible { display: flex; }
.dot { width: 5px; height: 5px; border-radius: 50%; background: rgba(255,255,255,.4); animation: bounce .8s infinite ease-in-out; }
.wa-btn { background: #202c33; border: none; color: #53bdeb; font-size: .68rem; font-weight: 800; padding: .42rem; text-align: center; border-radius: 6px; cursor: pointer; font-family: inherit; transition: background .15s, transform .1s; width: 100%; }
.chat-input { background: #1f2c34; padding: .45rem .6rem; display: flex; align-items: center; gap: .5rem; position: relative; z-index: 2; }
.replay-btn { position: absolute; bottom: -48px; left: 50%; transform: translateX(-50%); background: white; border: 2px solid #2BB5A0; color: #2BB5A0; font-family: inherit; font-weight: 800; font-size: .78rem; padding: .45rem 1.1rem; border-radius: 50px; cursor: pointer; opacity: 0; transition: opacity .3s, background .2s, color .2s; white-space: nowrap; z-index: 20; }
.replay-btn.visible { opacity: 1; }
@keyframes fadeSlideUp { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }
@keyframes bounce { 0%,80%,100% { transform: translateY(0); } 40% { transform: translateY(-4px); } }

/* ==========================================================================
   6. FOOTER
   ========================================================================== */
footer { padding: 3rem 8%; text-align: center; border-top: 1px solid var(--border); }
.footer-logo { font-size: 2rem; font-weight: 900; color: var(--teal); letter-spacing: -1px; margin-bottom: 1rem; display: block; text-decoration: none;}
.footer-links { display: flex; gap: 1.5rem; justify-content: center; margin-bottom: 1rem; flex-wrap: wrap;}
.footer-links a { color: var(--muted); font-size: .85rem; text-decoration: none; }
.footer-links a:hover { color: var(--teal); }
footer p { font-size: .8rem; color: var(--muted); }
footer p a { color: var(--teal); text-decoration: none; }


/* ==========================================================================
   7. RESPONSIVE MÓVIL (MEDIA QUERIES)
   ========================================================================== */
@media (max-width: 768px) {
  /* HEADER MÓVIL (Hamburguesa) */
  .hamburger { display: block; }
  .nav-cta { padding: 0.5rem 1rem; font-size: 0.8rem; }
  
  .nav-links {
    position: absolute;
    top: 64px; 
    left: -100%; 
    width: 100%;
    height: calc(100vh - 64px);
    background: var(--white);
    flex-direction: column;
    justify-content: flex-start;
    padding-top: 2rem;
    gap: 1.5rem;
    transition: left 0.3s ease-in-out;
    box-shadow: inset 0 4px 10px rgba(0,0,0,0.03);
  }

  .nav-links.active { left: 0; }
  
  .nav-links a.nav-item {
    font-size: 1.1rem;
    width: 100%;
    text-align: center;
    padding: 1rem 0;
  }

  /* REAJUSTES DE SECCIONES */
  .hero { grid-template-columns: 1fr !important; padding: 3rem 5%; text-align: center; }
  .hero-img { order: -1; display: flex !important; margin-bottom: 2rem; }
  .hero-content { order: 1; }
  .hero p { margin: 0 auto 2rem; }
  
  .stat-pill--tr { right: -5%; top: 8%; }
  .stat-pill--bl { left: -5%; bottom: 12%; }

  .para-quien-grid, 
  .ventajas-grid, 
  .testimonios-grid, 
  .faq-section__grid, 
  .precios-grid { 
      grid-template-columns: 1fr !important; 
  }
  
  .cta-band { flex-direction: column; text-align: center; padding: 2rem; }
}

@media (max-width: 380px) {
  .nav-cta .cta-text { display: none; }
  .nav-cta { padding: 0.5rem 0.8rem; }
}