/* ================================================================
   PropIA — Landing Page CSS
   Desarrollado con: Mobile-First, CSS Custom Properties, BEM-lite
   ================================================================ */

/* ----------------------------------------------------------------
   1. CUSTOM PROPERTIES (Variables — edita aquí para cambiar colores)
   ---------------------------------------------------------------- */
:root {
  /* === COLORES PRINCIPALES === */
  --accent:        #10b981;       /* Verde esmeralda — color de acción principal */
  --accent-dark:   #059669;       /* Verde más oscuro — hover de botones */
  --accent-light:  #d1fae5;       /* Verde muy suave — fondos de chips */

  --text-primary:  #0d1f35;       /* Azul-negro profundo — títulos */
  --text-body:     #374151;       /* Gris oscuro — cuerpo de texto */
  --text-muted:    #6b7280;       /* Gris medio — subtextos y labels */
  --text-white:    #ffffff;

  /* === FONDOS === */
  --bg-base:       #ffffff;
  --bg-soft:       #f8fafc;       /* Gris muy claro — secciones alternas */
  --bg-dark:       #0d1f35;       /* Fondo oscuro — secciones de contraste */
  --bg-card:       #ffffff;

  /* === BORDES === */
  --border:        #e5e7eb;
  --border-focus:  var(--accent);

  /* === SOMBRAS === */
  --shadow-sm:     0 1px 3px rgba(0,0,0,.08), 0 1px 2px rgba(0,0,0,.05);
  --shadow-md:     0 4px 16px rgba(0,0,0,.09), 0 2px 6px rgba(0,0,0,.06);
  --shadow-lg:     0 12px 40px rgba(0,0,0,.12);
  --shadow-accent: 0 8px 24px rgba(16,185,129,.28);

  /* === TIPOGRAFÍA === */
  --font-display: 'Syne', sans-serif;
  --font-body:    'DM Sans', sans-serif;

  /* === ESPACIADO === */
  --space-xs:  .5rem;
  --space-sm:  1rem;
  --space-md:  1.5rem;
  --space-lg:  2.5rem;
  --space-xl:  4rem;
  --space-2xl: 6rem;

  /* === RADIOS === */
  --radius-sm:  6px;
  --radius-md:  12px;
  --radius-lg:  20px;
  --radius-xl:  32px;
  --radius-full: 9999px;

  /* === TRANSICIONES === */
  --transition: 220ms cubic-bezier(.4,0,.2,1);
  --transition-slow: 400ms cubic-bezier(.4,0,.2,1);
}

/* ----------------------------------------------------------------
   2. RESET & BASE
   ---------------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.65;
  color: var(--text-body);
  background: var(--bg-base);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; }
button { cursor: pointer; border: none; background: none; font-family: inherit; }
input, select, textarea {
  font-family: inherit;
  font-size: inherit;
}

/* ----------------------------------------------------------------
   3. TIPOGRAFÍA
   ---------------------------------------------------------------- */
h1, h2, h3, h4 {
  font-family: var(--font-display);
  color: var(--text-primary);
  line-height: 1.15;
  letter-spacing: -.02em;
}

h1 { font-size: clamp(2rem, 5vw + .5rem, 3.75rem); font-weight: 800; }
h2 { font-size: clamp(1.6rem, 3vw + .5rem, 2.75rem); font-weight: 700; }
h3 { font-size: clamp(1.1rem, 2vw, 1.35rem); font-weight: 600; }

p { max-width: 65ch; }

/* ----------------------------------------------------------------
   4. UTILIDADES
   ---------------------------------------------------------------- */
.container {
  width: 100%;
  max-width: 1200px;
  margin-inline: auto;
  padding-inline: 1.25rem;
}

@media (min-width: 768px) {
  .container { padding-inline: 2rem; }
}

/* ----------------------------------------------------------------
   5. COMPONENTES BASE — BOTONES
   ---------------------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  padding: .75rem 1.5rem;
  border-radius: var(--radius-full);
  font-family: var(--font-display);
  font-size: .95rem;
  font-weight: 600;
  letter-spacing: -.01em;
  transition: all var(--transition);
  white-space: nowrap;
}

.btn--accent {
  background: var(--accent);
  color: #fff;
  box-shadow: var(--shadow-accent);
}
.btn--accent:hover, .btn--accent:focus-visible {
  background: var(--accent-dark);
  transform: translateY(-2px);
  box-shadow: 0 12px 32px rgba(16,185,129,.35);
}

.btn--ghost {
  background: transparent;
  color: var(--text-primary);
  border: 1.5px solid var(--border);
}
.btn--ghost:hover, .btn--ghost:focus-visible {
  border-color: var(--text-primary);
  background: var(--bg-soft);
}

.btn--white {
  background: #fff;
  color: var(--text-primary);
  box-shadow: var(--shadow-md);
}
.btn--white:hover, .btn--white:focus-visible {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.btn--lg { padding: 1rem 2rem; font-size: 1.05rem; }
.btn--sm { padding: .5rem 1.1rem; font-size: .875rem; }
.btn--full { width: 100%; justify-content: center; }

.btn:active { transform: translateY(0) !important; }
.btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }

/* ----------------------------------------------------------------
   6. BADGE
   ---------------------------------------------------------------- */
.badge {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  padding: .3rem .85rem;
  background: var(--accent-light);
  color: var(--accent-dark);
  border-radius: var(--radius-full);
  font-size: .8rem;
  font-weight: 600;
  letter-spacing: .04em;
  text-transform: uppercase;
}
.badge--dark {
  background: rgba(13,31,53,.08);
  color: var(--text-primary);
}
.badge--white {
  background: rgba(255,255,255,.18);
  color: #fff;
  border: 1px solid rgba(255,255,255,.3);
}

/* ----------------------------------------------------------------
   7. SECTION HEADERS
   ---------------------------------------------------------------- */
.section-header {
  text-align: center;
  margin-bottom: var(--space-xl);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-sm);
}

.section-title { margin-bottom: .25rem; }
.section-title--white { color: var(--text-white); }

.section-sub {
  color: var(--text-muted);
  font-size: 1.05rem;
  max-width: 54ch;
  text-align: center;
}
.section-sub--white { color: rgba(255,255,255,.7); }

/* ----------------------------------------------------------------
   8. ANIMATIONS
   ---------------------------------------------------------------- */
[data-animate] {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity .6s ease, transform .6s ease;
}
[data-animate].is-visible {
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  [data-animate] {
    opacity: 1;
    transform: none;
    transition: none;
  }
}

/* ----------------------------------------------------------------
   9. NAVBAR
   ---------------------------------------------------------------- */
.navbar {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  background: rgba(255,255,255,.85);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid transparent;
  transition: border-color var(--transition), box-shadow var(--transition);
}
.navbar.scrolled {
  border-color: var(--border);
  box-shadow: var(--shadow-sm);
}

.navbar__inner {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  padding-block: .9rem;
}

.navbar__logo {
  display: flex;
  align-items: center;
  gap: .6rem;
  flex-shrink: 0;
}
.navbar__brand {
  font-family: var(--font-display);
  font-size: 1.2rem;
  color: var(--text-primary);
  letter-spacing: -.03em;
}
.navbar__brand strong { color: var(--accent); }

.navbar__links {
  display: none;
  align-items: center;
  gap: var(--space-md);
  margin-left: auto;
}
.navbar__links a {
  font-size: .9rem;
  font-weight: 500;
  color: var(--text-body);
  transition: color var(--transition);
}
.navbar__links a:hover { color: var(--accent); }

.navbar__cta { display: none; }

.navbar__hamburger {
  display: flex;
  flex-direction: column;
  gap: 5px;
  padding: .5rem;
  margin-left: auto;
}
.navbar__hamburger span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text-primary);
  border-radius: 2px;
  transition: all var(--transition);
}
.navbar__hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.navbar__hamburger.open span:nth-child(2) { opacity: 0; }
.navbar__hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Mobile menu */
.navbar__mobile-menu {
  display: flex;
  flex-direction: column;
  background: var(--bg-base);
  padding: 0 1.25rem;
  max-height: 0;
  overflow: hidden;
  transition: max-height .35s ease, padding .35s ease;
  border-top: 1px solid transparent;
}
.navbar__mobile-menu.open {
  max-height: 400px;
  padding: 1rem 1.25rem 1.5rem;
  border-color: var(--border);
}
.mobile-link {
  padding: .75rem 0;
  font-size: 1rem;
  font-weight: 500;
  color: var(--text-primary);
  border-bottom: 1px solid var(--border);
  transition: color var(--transition);
}
.mobile-link:last-child { border-bottom: none; }
.mobile-link:hover { color: var(--accent); }
.mobile-link--cta {
  margin-top: 1rem;
  text-align: center;
  border-bottom: none;
}

@media (min-width: 768px) {
  .navbar__links { display: flex; }
  .navbar__cta { display: inline-flex; }
  .navbar__hamburger { display: none; }
}

/* ----------------------------------------------------------------
   10. HERO
   ---------------------------------------------------------------- */
.hero {
  padding-top: calc(70px + var(--space-xl));
  padding-bottom: var(--space-2xl);
  background: var(--bg-soft);
  position: relative;
  overflow: hidden;
}

/* Subtle background grid */
.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(16,185,129,.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(16,185,129,.04) 1px, transparent 1px);
  background-size: 40px 40px;
  pointer-events: none;
}

.hero__inner {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-xl);
  align-items: center;
  position: relative;
}

.hero__text {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: var(--space-md);
}

.hero__headline {
  margin-bottom: 0;
}
.hero__headline .highlight {
  color: var(--accent);
  position: relative;
}
.hero__headline .highlight::after {
  content: '';
  position: absolute;
  left: 0; right: 0;
  bottom: 2px;
  height: 3px;
  background: var(--accent);
  opacity: .25;
  border-radius: 2px;
}

.hero__subhead {
  font-size: 1.1rem;
  color: var(--text-muted);
  max-width: 48ch;
}
.hero__subhead strong { color: var(--text-primary); }

.hero__ctas {
  display: flex;
  flex-wrap: wrap;
  gap: .75rem;
  margin-top: .5rem;
}

.hero__trust {
  display: flex;
  align-items: center;
  gap: .75rem;
  margin-top: .5rem;
}
.trust-avatars {
  display: flex;
}
.trust-avatars img {
  width: 36px; height: 36px;
  border-radius: 50%;
  border: 2px solid var(--bg-base);
  margin-left: -8px;
  object-fit: cover;
}
.trust-avatars img:first-child { margin-left: 0; }
.trust-text {
  font-size: .85rem;
  color: var(--text-muted);
}
.trust-text strong { color: var(--text-primary); }

/* HERO VISUAL */
.hero__visual { position: relative; }

.hero__mockup {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg), 0 0 0 1px var(--border);
  overflow: hidden;
}

.mockup__bar {
  display: flex;
  align-items: center;
  gap: .4rem;
  padding: .75rem 1rem;
  background: #f1f5f9;
  border-bottom: 1px solid var(--border);
}
.dot {
  width: 11px; height: 11px;
  border-radius: 50%;
}
.dot--red    { background: #f87171; }
.dot--yellow { background: #fbbf24; }
.dot--green  { background: #34d399; }
.mockup__title-bar {
  margin-left: .5rem;
  font-size: .78rem;
  color: var(--text-muted);
  font-weight: 500;
}

.mockup__body {
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.mockup__stat-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: .75rem;
}

.stat-card {
  background: var(--bg-soft);
  border-radius: var(--radius-md);
  padding: .9rem;
  display: flex;
  flex-direction: column;
  gap: .15rem;
}
.stat-card--accent {
  background: var(--accent-light);
}
.stat-label {
  font-size: .72rem;
  color: var(--text-muted);
  font-weight: 500;
}
.stat-value {
  font-family: var(--font-display);
  font-size: 1.6rem;
  font-weight: 800;
  color: var(--text-primary);
  line-height: 1;
}
.stat-delta {
  font-size: .7rem;
  color: var(--accent-dark);
  font-weight: 600;
}

.mockup__funnel {
  background: var(--bg-soft);
  border-radius: var(--radius-md);
  padding: 1rem;
  display: flex;
  flex-direction: column;
  gap: .6rem;
}
.funnel-label {
  font-size: .75rem;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: .05em;
  margin-bottom: .25rem;
}
.funnel-bar {
  display: flex;
  flex-direction: column;
  gap: .25rem;
}
.funnel-bar span {
  font-size: .72rem;
  color: var(--text-muted);
}
.funnel-bar span strong { color: var(--text-primary); }
.funnel-fill {
  height: 8px;
  border-radius: 4px;
  background: var(--accent);
  transition: width .8s ease;
}
.funnel-fill--mid  { background: #34d399; }
.funnel-fill--low  { background: #6ee7b7; }

.mockup__notification {
  display: flex;
  align-items: center;
  gap: .5rem;
  padding: .75rem 1rem;
  background: #f0fdf4;
  border: 1px solid #bbf7d0;
  border-radius: var(--radius-md);
  font-size: .78rem;
  color: #15803d;
  font-weight: 500;
}

.hero__glow {
  position: absolute;
  inset: -60px;
  background: radial-gradient(ellipse at 60% 50%, rgba(16,185,129,.15) 0%, transparent 70%);
  pointer-events: none;
  z-index: -1;
}

/* FLOATING CHIPS */
.hero__chips { display: none; }

.chip {
  position: absolute;
  display: flex;
  align-items: center;
  gap: .4rem;
  padding: .5rem 1rem;
  background: var(--bg-card);
  border-radius: var(--radius-full);
  box-shadow: var(--shadow-md);
  font-size: .8rem;
  font-weight: 600;
  color: var(--text-primary);
  white-space: nowrap;
  animation: float 4s ease-in-out infinite;
}
.chip--1 { top: 10%; right: 5%; animation-delay: 0s; }
.chip--2 { bottom: 12%; left: 3%; animation-delay: 2s; }

@keyframes float {
  0%, 100% { transform: translateY(0); }
  50%       { transform: translateY(-8px); }
}

@media (min-width: 900px) {
  .hero__inner {
    grid-template-columns: 1fr 1fr;
    gap: var(--space-2xl);
  }
  .hero__chips { display: block; }
}

/* ----------------------------------------------------------------
   11. LOGOS STRIP
   ---------------------------------------------------------------- */
.logos {
  padding-block: var(--space-lg);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  overflow: hidden;
}

.logos__label {
  text-align: center;
  font-size: .8rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: .08em;
  margin-bottom: 1rem;
}

.logos__track { overflow: hidden; }
.logos__inner {
  display: flex;
  gap: 1.5rem;
  width: max-content;
  animation: ticker 22s linear infinite;
}

@keyframes ticker {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}

.logo-pill {
  padding: .5rem 1.25rem;
  background: var(--bg-soft);
  border: 1px solid var(--border);
  border-radius: var(--radius-full);
  font-size: .875rem;
  font-weight: 600;
  color: var(--text-muted);
  white-space: nowrap;
  flex-shrink: 0;
}

/* ----------------------------------------------------------------
   12. DOLOR — ANTES VS DESPUÉS
   ---------------------------------------------------------------- */
.dolor {
  padding-block: var(--space-2xl);
  background: var(--bg-base);
}

.compare-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-md);
}

.compare-card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  padding: var(--space-lg);
  border: 1.5px solid var(--border);
}

.compare-card--before {
  border-color: #fecaca;
  background: #fff5f5;
}
.compare-card--after {
  border-color: #bbf7d0;
  background: #f0fdf4;
}

.compare-header { margin-bottom: var(--space-md); }

.compare-badge {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  padding: .35rem .9rem;
  border-radius: var(--radius-full);
  font-size: .8rem;
  font-weight: 700;
  letter-spacing: .02em;
}
.compare-badge--before {
  background: #fee2e2;
  color: #dc2626;
}
.compare-badge--after {
  background: var(--accent-light);
  color: var(--accent-dark);
}

.compare-list {
  display: flex;
  flex-direction: column;
  gap: .9rem;
}
.compare-list li {
  display: flex;
  align-items: flex-start;
  gap: .75rem;
  font-size: .95rem;
  color: var(--text-body);
  line-height: 1.45;
}
.compare-list svg { flex-shrink: 0; margin-top: 2px; }

.compare-separator {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  padding: .5rem 0;
}
.compare-separator__line {
  flex: 1;
  height: 1px;
  background: var(--border);
}
.compare-separator__icon {
  width: 44px; height: 44px;
  background: var(--bg-base);
  border: 1.5px solid var(--border);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

@media (min-width: 900px) {
  .compare-grid {
    grid-template-columns: 1fr auto 1fr;
    align-items: start;
    gap: 0;
  }
  .compare-separator {
    flex-direction: column;
    padding: 0 1.5rem;
    align-self: center;
    min-height: 200px;
  }
  .compare-separator__line {
    flex: 1;
    width: 1px;
    height: auto;
  }
}

.dolor__cta {
  text-align: center;
  margin-top: var(--space-xl);
}

/* ----------------------------------------------------------------
   13. CÓMO FUNCIONA
   ---------------------------------------------------------------- */
.como-funciona {
  padding-block: var(--space-2xl);
  background: var(--bg-soft);
}

.steps-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-md);
}

.step-card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  padding: var(--space-lg);
  border: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  gap: .75rem;
  transition: box-shadow var(--transition), transform var(--transition);
  position: relative;
  overflow: hidden;
}
.step-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0;
  right: 0; height: 3px;
  background: linear-gradient(90deg, var(--accent), transparent);
  opacity: 0;
  transition: opacity var(--transition);
}
.step-card:hover { box-shadow: var(--shadow-md); transform: translateY(-3px); }
.step-card:hover::before { opacity: 1; }

.step-card--final {
  border-color: var(--accent);
}
.step-card--final::before { opacity: 1; }

.step-number {
  font-family: var(--font-display);
  font-size: 3.5rem;
  font-weight: 800;
  color: var(--border);
  line-height: 1;
  letter-spacing: -.04em;
  position: absolute;
  top: 1rem; right: 1.25rem;
  transition: color var(--transition);
}
.step-card:hover .step-number { color: var(--accent-light); }

.step-icon { width: 48px; height: 48px; }

.step-card h3 { font-size: 1.15rem; }
.step-card p {
  font-size: .93rem;
  color: var(--text-muted);
  max-width: none;
}

.step-connector {
  display: none;
  align-items: center;
  justify-content: center;
}

@media (min-width: 900px) {
  .steps-grid {
    grid-template-columns: 1fr auto 1fr auto 1fr auto 1fr;
    align-items: start;
  }
  .step-connector {
    display: flex;
    padding-top: 4rem;
    color: var(--text-muted);
    opacity: .5;
  }
}

/* ----------------------------------------------------------------
   14. BENEFICIOS / MÉTRICAS
   ---------------------------------------------------------------- */
.beneficios {
  padding-block: var(--space-2xl);
  background: var(--bg-dark);
  position: relative;
  overflow: hidden;
}

.beneficios::before {
  content: '';
  position: absolute;
  top: -50%; left: -10%;
  width: 600px; height: 600px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(16,185,129,.12) 0%, transparent 70%);
  pointer-events: none;
}

.metrics-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-md);
  margin-bottom: var(--space-xl);
}

.metric-card {
  background: rgba(255,255,255,.05);
  border: 1px solid rgba(255,255,255,.1);
  border-radius: var(--radius-lg);
  padding: var(--space-lg);
  display: flex;
  flex-direction: column;
  gap: .5rem;
  transition: background var(--transition), border-color var(--transition);
}
.metric-card:hover {
  background: rgba(255,255,255,.08);
  border-color: var(--accent);
}

.metric-number {
  font-family: var(--font-display);
  font-size: clamp(2rem, 5vw, 3.5rem);
  font-weight: 800;
  color: var(--accent);
  line-height: 1;
}

.metric-label {
  font-size: .9rem;
  color: rgba(255,255,255,.6);
  line-height: 1.4;
  max-width: 20ch;
}

@media (min-width: 768px) {
  .metrics-grid { grid-template-columns: repeat(4, 1fr); }
}

/* TESTIMONIALS */
.testimonials-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-md);
}

.testimonial-card {
  background: rgba(255,255,255,.06);
  border: 1px solid rgba(255,255,255,.1);
  border-radius: var(--radius-lg);
  padding: var(--space-lg);
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
}

.testimonial-quote { margin-bottom: -.5rem; }

.testimonial-card p {
  color: rgba(255,255,255,.8);
  font-size: 1rem;
  line-height: 1.7;
  font-style: italic;
  max-width: none;
}

.testimonial-author {
  display: flex;
  align-items: center;
  gap: .75rem;
  margin-top: auto;
}
.testimonial-author img {
  width: 48px; height: 48px;
  border-radius: 50%;
  border: 2px solid var(--accent);
  object-fit: cover;
}
.testimonial-author strong {
  display: block;
  color: #fff;
  font-size: .95rem;
}
.testimonial-author span {
  font-size: .8rem;
  color: rgba(255,255,255,.5);
}

@media (min-width: 768px) {
  .testimonials-grid { grid-template-columns: 1fr 1fr; }
}

/* ----------------------------------------------------------------
   15. FAQ
   ---------------------------------------------------------------- */
.faq {
  padding-block: var(--space-2xl);
  background: var(--bg-base);
}

.faq-list {
  max-width: 760px;
  margin-inline: auto;
  display: flex;
  flex-direction: column;
  gap: .75rem;
}

.faq-item {
  border: 1.5px solid var(--border);
  border-radius: var(--radius-md);
  overflow: hidden;
  transition: border-color var(--transition);
}
.faq-item[open] {
  border-color: var(--accent);
}

.faq-question {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-sm);
  padding: 1rem 1.25rem;
  font-weight: 600;
  font-size: .95rem;
  color: var(--text-primary);
  cursor: pointer;
  list-style: none;
  transition: background var(--transition);
}
.faq-question:hover { background: var(--bg-soft); }
.faq-question::-webkit-details-marker { display: none; }

.faq-icon {
  flex-shrink: 0;
  color: var(--text-muted);
  transition: transform var(--transition);
}
details[open] .faq-icon { transform: rotate(180deg); }

.faq-answer {
  padding: 0 1.25rem 1rem;
  border-top: 1px solid var(--border);
}
.faq-answer p {
  padding-top: .75rem;
  font-size: .93rem;
  color: var(--text-muted);
  max-width: none;
}

/* ----------------------------------------------------------------
   16. CTA FINAL
   ---------------------------------------------------------------- */
.cta-final {
  padding-block: var(--space-2xl);
  background: linear-gradient(135deg, var(--accent-dark) 0%, var(--accent) 100%);
  text-align: center;
  position: relative;
  overflow: hidden;
}

.cta-final::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.05) 1px, transparent 1px);
  background-size: 50px 50px;
  pointer-events: none;
}

.cta-final__inner {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-md);
}

.cta-final__inner h2 {
  color: #fff;
  font-size: clamp(1.8rem, 4vw, 3rem);
  max-width: 15ch;
}

.cta-final__inner p {
  color: rgba(255,255,255,.82);
  font-size: 1.05rem;
  max-width: 52ch;
  text-align: center;
}

.cta-final__note {
  font-size: .8rem;
  color: rgba(255,255,255,.55);
}

/* ----------------------------------------------------------------
   17. FORMULARIO
   ---------------------------------------------------------------- */
.formulario {
  padding-block: var(--space-2xl);
  background: var(--bg-soft);
}

.form-wrapper {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-xl);
  max-width: 1080px;
  margin-inline: auto;
}

@media (min-width: 900px) {
  .form-wrapper { grid-template-columns: 1fr 1.4fr; align-items: start; }
}

/* Form intro */
.form-intro {
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
}
.form-intro h2 { max-width: 18ch; }
.form-intro p { color: var(--text-muted); }

.form-promises {
  display: flex;
  flex-direction: column;
  gap: .6rem;
  margin-top: .25rem;
}
.form-promises li {
  display: flex;
  align-items: center;
  gap: .6rem;
  font-size: .9rem;
  font-weight: 500;
  color: var(--text-body);
}

/* Form card */
.form-card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  padding: var(--space-lg);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-md);
}

.form-row { margin-bottom: 1.25rem; }
.form-row--split {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.25rem;
}
@media (min-width: 600px) {
  .form-row--split { grid-template-columns: 1fr 1fr; }
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: .4rem;
}

label {
  font-size: .85rem;
  font-weight: 600;
  color: var(--text-primary);
}
.label-optional {
  font-weight: 400;
  color: var(--text-muted);
}

input, select, textarea {
  width: 100%;
  padding: .8rem 1rem;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-md);
  background: var(--bg-base);
  color: var(--text-primary);
  font-size: .95rem;
  transition: border-color var(--transition), box-shadow var(--transition);
  appearance: none;
  -webkit-appearance: none;
}
input::placeholder, textarea::placeholder { color: var(--text-muted); }

input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(16,185,129,.15);
}

select {
  background-image: url("data:image/svg+xml,%3Csvg width='14' height='9' viewBox='0 0 14 9' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1 1L7 7L13 1' stroke='%236b7280' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 1rem center;
  padding-right: 2.5rem;
  cursor: pointer;
}

textarea { resize: vertical; min-height: 110px; }

.form-submit {
  margin-top: .5rem;
}

.form-privacy {
  display: flex;
  align-items: center;
  gap: .4rem;
  font-size: .78rem;
  color: var(--text-muted);
  text-align: center;
  justify-content: center;
  margin-top: .75rem;
  max-width: none;
}

/* Success state */
.form-success {
  text-align: center;
  padding: var(--space-lg);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-sm);
}
.form-success h3 {
  color: var(--accent-dark);
  font-size: 1.3rem;
}
.form-success p { color: var(--text-muted); max-width: 36ch; text-align: center; }

/* ----------------------------------------------------------------
   18. FOOTER
   ---------------------------------------------------------------- */
.footer {
  background: var(--bg-dark);
  padding-top: var(--space-xl);
}

.footer__inner {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-lg);
  padding-bottom: var(--space-lg);
  border-bottom: 1px solid rgba(255,255,255,.1);
}

@media (min-width: 768px) {
  .footer__inner { grid-template-columns: 1fr auto; align-items: start; }
}

.footer__brand {
  display: flex;
  flex-direction: column;
  gap: .75rem;
}
.footer__brand .navbar__brand { color: #fff; }
.footer__brand p {
  font-size: .875rem;
  color: rgba(255,255,255,.45);
  max-width: 36ch;
}

.footer__nav {
  display: flex;
  flex-wrap: wrap;
  gap: .75rem 1.5rem;
}
.footer__nav a {
  font-size: .875rem;
  color: rgba(255,255,255,.5);
  transition: color var(--transition);
}
.footer__nav a:hover { color: var(--accent); }

.footer__bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: .5rem;
  padding-block: var(--space-md);
}
.footer__bottom p {
  font-size: .78rem;
  color: rgba(255,255,255,.3);
  max-width: none;
}

/* ----------------------------------------------------------------
   19. WHATSAPP FAB
   ---------------------------------------------------------------- */
.whatsapp-fab {
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  z-index: 200;
  width: 56px; height: 56px;
  background: #25D366;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 20px rgba(37,211,102,.4);
  transition: all var(--transition);
}

.whatsapp-fab:hover {
  background: #20bd5c;
  transform: scale(1.1);
  box-shadow: 0 8px 28px rgba(37,211,102,.5);
}

.whatsapp-tooltip {
  position: absolute;
  right: calc(100% + .75rem);
  bottom: 50%;
  transform: translateY(50%);
  background: var(--text-primary);
  color: #fff;
  padding: .4rem .85rem;
  border-radius: var(--radius-full);
  font-size: .78rem;
  font-weight: 500;
  white-space: nowrap;
  pointer-events: none;
  opacity: 0;
  transition: opacity var(--transition);
}

.whatsapp-tooltip::after {
  content: '';
  position: absolute;
  left: 100%;
  top: 50%; transform: translateY(-50%);
  border: 5px solid transparent;
  border-left-color: var(--text-primary);
}

.whatsapp-fab:hover .whatsapp-tooltip { opacity: 1; }

/* Pulse ring animation */
.whatsapp-fab::after {
  content: '';
  position: absolute;
  inset: -4px;
  border-radius: 50%;
  border: 2px solid rgba(37,211,102,.4);
  animation: whatsapp-pulse 2s ease-out infinite;
}

@keyframes whatsapp-pulse {
  0%   { transform: scale(1); opacity: 1; }
  100% { transform: scale(1.55); opacity: 0; }
}

/* ----------------------------------------------------------------
   20. SCROLL-TO-TOP (bonus)
   ---------------------------------------------------------------- */
#scrollTop {
  position: fixed;
  bottom: 5rem;
  right: 1.5rem;
  z-index: 200;
  width: 40px; height: 40px;
  background: var(--bg-card);
  border: 1.5px solid var(--border);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-md);
  opacity: 0;
  pointer-events: none;
  transition: all var(--transition);
}
#scrollTop.visible {
  opacity: 1;
  pointer-events: auto;
}
#scrollTop:hover {
  border-color: var(--accent);
  color: var(--accent);
  transform: translateY(-2px);
}

/* ----------------------------------------------------------------
   21. RESPONSIVIDAD ADICIONAL
   ---------------------------------------------------------------- */
@media (max-width: 599px) {
  .hero__ctas { flex-direction: column; align-items: flex-start; }
  .hero__ctas .btn { width: 100%; justify-content: center; }
  .metrics-grid { grid-template-columns: 1fr; }
}

/* ----------------------------------------------------------------
   22. ACCESIBILIDAD & PREFERENCIAS
   ---------------------------------------------------------------- */
:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

@media (prefers-color-scheme: dark) {
  /* Descomenta si quieres soporte de dark mode automático
  :root {
    --bg-base:  #0f172a;
    --bg-soft:  #1e293b;
    --bg-card:  #1e293b;
    --text-primary: #f1f5f9;
    --text-body:    #94a3b8;
    --text-muted:   #64748b;
    --border:       #334155;
  }
  */
}

/* ----------------------------------------------------------------
   23. PRINT
   ---------------------------------------------------------------- */
@media print {
  .navbar, .whatsapp-fab, #scrollTop { display: none; }
  .hero { padding-top: 2rem; }
}
