/* ─── TOKENS ──────────────────────────────────────────── */
:root {
  --navy:    #0A1628;
  --navy2:   #0d1f38;
  --emerald: #50C878;
  --emerald2:#3da85e;
  --crema:   #F5F0E8;
  --blanco:  #ffffff;
  --gris:    #5a6478;
  --ease:    cubic-bezier(.25,.46,.45,.94);
}

/* ─── RESET ───────────────────────────────────────────── */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { font-family: 'DM Sans', sans-serif; background: var(--crema); color: var(--navy); overflow-x: hidden; text-rendering: optimizeLegibility; -webkit-font-smoothing: antialiased; }
img { display: block; max-width: 100%; }
a { text-decoration: none; color: inherit; }

/* ─── SCROLL PROGRESS ─────────────────────────────────── */
#progress-bar {
  position: fixed; top: 0; left: 0; height: 2px; width: 0%;
  background: linear-gradient(90deg, var(--emerald2), var(--emerald));
  z-index: 1000; transition: width .1s linear;
}

/* ─── NAV ─────────────────────────────────────────────── */
nav {
  position: fixed; top: 2px; left: 0; right: 0; z-index: 900;
  display: flex; align-items: center; justify-content: space-between;
  padding: 1rem 3rem;
  transition: background .4s var(--ease), box-shadow .4s, padding .3s;
}
nav.scrolled {
  background: rgba(10,22,40,.97);
  backdrop-filter: blur(14px);
  box-shadow: 0 2px 28px rgba(0,0,0,.22);
  padding: .7rem 3rem;
}
.nav-logo { display: flex; flex-direction: column; }
.nav-logo-name { font-family: 'Playfair Display', serif; color: var(--crema); font-size: 1.2rem; letter-spacing: .25em; line-height: 1; }
.nav-logo-sub  { color: var(--emerald); font-size: .55rem; letter-spacing: .4em; text-transform: uppercase; margin-top: 3px; }
.nav-links {
  display: flex; align-items: center; gap: .3rem;
}
.nav-link {
  color: rgba(245,240,232,.65); font-size: .82rem; font-weight: 500;
  padding: .45rem .8rem; border-radius: 50px;
  transition: color .2s, background .2s;
  white-space: nowrap;
}
.nav-link:hover { color: var(--crema); background: rgba(255,255,255,.07); }
.nav-link.active { color: var(--emerald); }
.nav-right { display: flex; align-items: center; gap: .8rem; }
.nav-cta {
  display: inline-flex; align-items: center; gap: .45rem;
  background: var(--emerald2); color: #fff;
  padding: .55rem 1.3rem; border-radius: 50px;
  font-size: .82rem; font-weight: 600; letter-spacing: .02em;
  box-shadow: 0 3px 16px rgba(61,168,94,.3);
  transition: transform .2s, box-shadow .2s, background .2s;
}
.nav-cta:hover { transform: translateY(-1px); background: #2e8f4a; box-shadow: 0 5px 22px rgba(61,168,94,.45); }
.nav-cta svg { width: 15px; height: 15px; }

/* ─── FLOATING WA ──────────────────────────────────────── */
#wa-float {
  position: fixed; bottom: 2rem; right: 2rem; z-index: 800;
  width: 56px; height: 56px; border-radius: 50%;
  background: #25D366; color: #fff;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 4px 20px rgba(37,211,102,.45);
  transition: transform .2s;
}
#wa-float:hover { transform: scale(1.1); }
#wa-float svg { width: 26px; height: 26px; }
#wa-float::before {
  content: ''; position: absolute;
  width: 56px; height: 56px; border-radius: 50%;
  background: rgba(37,211,102,.3);
  animation: waPulse 2.4s ease-out infinite;
}
@keyframes waPulse { 0%{transform:scale(1);opacity:.8} 100%{transform:scale(2.3);opacity:0} }

/* ─── FOOTER ───────────────────────────────────────────── */
footer {
  background: #060e1a; color: rgba(245,240,232,.3);
  text-align: center; padding: 2.5rem 2rem 2rem; font-size: .73rem; line-height: 2;
}
footer a { color: var(--emerald); opacity: .6; }
.footer-nav { display: flex; gap: 1.5rem; justify-content: center; flex-wrap: wrap; margin-bottom: .8rem; }
.footer-nav a { color: rgba(245,240,232,.4); font-size: .75rem; transition: color .2s; }
.footer-nav a:hover { color: var(--emerald); }
.footer-social { display: flex; gap: .9rem; justify-content: center; margin-bottom: 1.2rem; }
.footer-social a {
  width: 34px; height: 34px; border-radius: 50%;
  background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.1);
  display: flex; align-items: center; justify-content: center;
  color: rgba(245,240,232,.45); transition: background .2s, color .2s, border-color .2s;
}
.footer-social a:hover { background: var(--emerald); border-color: var(--emerald); color: #fff; opacity: 1; }
.footer-social svg { width: 15px; height: 15px; }

/* ─── SECTION UTILS ─────────────────────────────────────── */
.eyebrow {
  display: inline-flex; align-items: center; gap: .5rem;
  font-size: .65rem; letter-spacing: .38em; text-transform: uppercase;
  margin-bottom: .9rem; font-weight: 500;
}
.eyebrow span { display: block; width: 28px; height: 1px; }
.eyebrow.dark { color: var(--emerald2); }
.eyebrow.dark span { background: var(--emerald2); }
.eyebrow.light { color: var(--emerald); }
.eyebrow.light span { background: var(--emerald); }

/* ─── REVEAL ──────────────────────────────────────────── */
.r { opacity: 0; transition: opacity .75s var(--ease), transform .75s var(--ease); }
.r.up    { transform: translateY(22px); }
.r.left  { transform: translateX(-24px); }
.r.right { transform: translateX(24px); }
.r.on    { opacity: 1; transform: none; }
.d1 { transition-delay: .1s; }
.d2 { transition-delay: .2s; }
.d3 { transition-delay: .3s; }
.d4 { transition-delay: .4s; }

/* ─── BUTTONS ─────────────────────────────────────────── */
.btn-wa {
  display: inline-flex; align-items: center; gap: .55rem;
  background: #25D366; color: #fff;
  padding: 1rem 2rem; border-radius: 50px;
  font-weight: 600; font-size: .95rem;
  box-shadow: 0 4px 24px rgba(37,211,102,.38);
  transition: transform .2s, box-shadow .2s;
}
.btn-wa:hover { transform: translateY(-2px); box-shadow: 0 8px 32px rgba(37,211,102,.55); }
.btn-wa svg { width: 20px; height: 20px; flex-shrink: 0; }
.btn-wa-sm {
  display: inline-flex; align-items: center; gap: .45rem;
  background: #25D366; color: #fff;
  padding: .7rem 1.4rem; border-radius: 50px;
  font-weight: 600; font-size: .82rem;
  box-shadow: 0 3px 16px rgba(37,211,102,.3);
  transition: transform .2s;
}
.btn-wa-sm:hover { transform: translateY(-1px); }
.btn-wa-sm svg { width: 16px; height: 16px; flex-shrink: 0; }
.btn-navy {
  display: inline-flex; align-items: center; gap: .55rem;
  background: var(--navy); color: var(--crema);
  padding: 1rem 2rem; border-radius: 50px;
  font-weight: 600; font-size: .95rem;
  box-shadow: 0 4px 22px rgba(10,22,40,.25);
  transition: transform .2s, box-shadow .2s;
}
.btn-navy:hover { transform: translateY(-2px); box-shadow: 0 8px 32px rgba(10,22,40,.35); }
.btn-outline-light {
  display: inline-flex; align-items: center; gap: .5rem;
  border: 1px solid rgba(245,240,232,.25); color: rgba(245,240,232,.7);
  padding: 1rem 1.8rem; border-radius: 50px;
  font-size: .9rem; font-weight: 500;
  transition: border-color .2s, color .2s;
}
.btn-outline-light:hover { border-color: var(--emerald); color: var(--emerald); }
.btn-outline-dark {
  display: inline-flex; align-items: center; gap: .5rem;
  border: 1px solid rgba(10,22,40,.25); color: var(--navy);
  padding: 1rem 1.8rem; border-radius: 50px;
  font-size: .9rem; font-weight: 500;
  transition: border-color .2s, background .2s;
}
.btn-outline-dark:hover { border-color: var(--emerald2); background: rgba(80,200,120,.05); }

/* ─── PAGE HERO (interior pages) ──────────────────────── */
.page-hero {
  background: linear-gradient(145deg, var(--navy) 0%, #0d2040 100%);
  padding: 9rem 5rem 5rem; position: relative; overflow: hidden;
}
.page-hero::before {
  content: ''; position: absolute; inset: 0;
  background: radial-gradient(ellipse at 20% 60%, rgba(80,200,120,.1) 0%, transparent 60%);
  pointer-events: none;
}
.page-hero-inner { max-width: 1100px; margin: 0 auto; position: relative; z-index: 1; }
.page-hero h1 {
  font-family: 'Playfair Display', serif;
  color: var(--crema); font-size: clamp(2.2rem,4vw,3.8rem);
  line-height: 1.15; margin-bottom: 1.2rem;
}
.page-hero h1 em { color: var(--emerald); font-style: italic; }
.page-hero p { color: rgba(245,240,232,.65); font-size: 1.05rem; line-height: 1.8; max-width: 560px; }

/* ─── STATS BAR ────────────────────────────────────────── */
.stats {
  background: var(--emerald2);
  display: grid; grid-template-columns: repeat(4, 1fr);
  padding: 2.2rem 5rem; gap: .5rem;
}
.stat { text-align: center; color: #fff; position: relative; }
.stat + .stat::before {
  content: ''; position: absolute; left: 0; top: 10%; bottom: 10%;
  width: 1px; background: rgba(255,255,255,.2);
}
.stat-n { font-family: 'Playfair Display', serif; font-size: 2.4rem; font-weight: 700; line-height: 1; }
.stat-l { font-size: .75rem; opacity: .82; margin-top: .3rem; letter-spacing: .04em; }

/* ─── CARDS SHARED ──────────────────────────────────────── */
.section-std { padding: 6rem 5rem; }
.inner { max-width: 1100px; margin: 0 auto; }
.section-title {
  font-family: 'Playfair Display', serif;
  font-size: clamp(1.8rem,2.8vw,2.8rem); line-height: 1.18; margin-bottom: .8rem;
  letter-spacing: -.01em;
}
.section-lead { color: var(--gris); max-width: 540px; line-height: 1.85; margin-bottom: 3.5rem; font-size: 1.02rem; }
.section-title.light { color: var(--crema); }
.section-lead.light { color: rgba(245,240,232,.58); }

/* ─── MOBILE ─────────────────────────────────────────────  */
@media (max-width: 1000px) {
  nav { padding: .9rem 1.5rem; }
  nav.scrolled { padding: .65rem 1.5rem; }
  .nav-links { display: none; }
  .stats { grid-template-columns: repeat(2,1fr); padding: 2rem 1.5rem; }
  .section-std { padding: 4rem 1.5rem; }
  .page-hero { padding: 7rem 1.5rem 4rem; }
}

/* ── FOOTER DISCLAIMER ─────────────────────────────── */
.footer-disclaimer {
  max-width: 760px;
  margin: 0 auto 1.5rem;
  padding: 1.2rem 1.5rem;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 10px;
  color: rgba(245,240,232,.3);
  font-size: .72rem;
  line-height: 1.7;
  text-align: center;
}
.footer-disclaimer strong {
  display: block;
  color: rgba(245,240,232,.5);
  letter-spacing: .08em;
  text-transform: uppercase;
  font-size: .65rem;
  margin-bottom: .4rem;
}

/* ── SVG ICON SIZING ───────────────────────────────── */
.area-visual-icon svg { width: 52px; height: 52px; color: var(--emerald); display: block; margin: 0 auto; }
.pilar-icon svg       { width: 36px; height: 36px; color: var(--crema); display: block; margin: 0 auto; opacity: .85; }
.area-icon svg        { width: 32px; height: 32px; color: var(--navy); display: block; }
.perfil-icon svg      { width: 38px; height: 38px; color: var(--emerald2); display: block; }

/* ── BRAND PRIMARY BUTTON ───────────────────────────── */
.btn-primary {
  display: inline-flex; align-items: center; gap: .55rem;
  background: var(--emerald2); color: #fff;
  padding: 1rem 2rem; border-radius: 50px;
  font-weight: 600; font-size: .95rem; letter-spacing: .02em;
  box-shadow: 0 4px 24px rgba(61,168,94,.3);
  transition: transform .2s, box-shadow .2s, background .2s;
}
.btn-primary:hover { transform: translateY(-2px); background: #2e8f4a; box-shadow: 0 8px 32px rgba(61,168,94,.45); }
.btn-primary svg { width: 20px; height: 20px; flex-shrink: 0; }

/* ── HAMBURGER MOBILE MENU ──────────────────────────── */
.nav-hamburger {
  display: none;
  flex-direction: column; gap: 5px;
  background: none; border: none;
  cursor: pointer; padding: .4rem;
  z-index: 910;
}
.nav-hamburger span {
  display: block; width: 22px; height: 1.5px;
  background: var(--crema); border-radius: 2px;
  transition: transform .3s var(--ease), opacity .3s, width .3s;
  transform-origin: center;
}
.nav-hamburger.open span:nth-child(1) { transform: translateY(6.5px) rotate(45deg); }
.nav-hamburger.open span:nth-child(2) { opacity: 0; width: 0; }
.nav-hamburger.open span:nth-child(3) { transform: translateY(-6.5px) rotate(-45deg); }

.mobile-menu {
  position: fixed; inset: 0; z-index: 850;
  background: rgba(6,14,26,.97);
  backdrop-filter: blur(20px);
  display: flex; flex-direction: column;
  align-items: center; justify-content: center; gap: .5rem;
  opacity: 0; pointer-events: none;
  transition: opacity .35s var(--ease);
}
.mobile-menu.open { opacity: 1; pointer-events: all; }
.mobile-menu a {
  font-family: 'Playfair Display', serif;
  font-size: clamp(1.6rem, 5vw, 2.2rem);
  color: rgba(245,240,232,.5); font-weight: 600;
  padding: .6rem 2rem; border-radius: 8px;
  transition: color .2s;
  letter-spacing: .01em;
}
.mobile-menu a:hover, .mobile-menu a.active { color: var(--crema); }
.mobile-menu .mobile-cta {
  margin-top: 1.5rem;
  background: var(--emerald2); color: #fff;
  padding: .9rem 2.5rem; border-radius: 50px;
  font-family: 'DM Sans', sans-serif;
  font-size: 1rem; font-weight: 700;
}
.mobile-menu .mobile-divider {
  width: 40px; height: 1px;
  background: rgba(245,240,232,.12); margin: .8rem 0;
}

@media (max-width: 1000px) {
  /* Nav siempre visible con fondo en mobile */
  nav {
    background: rgba(10,22,40,.98) !important;
    backdrop-filter: blur(14px);
    box-shadow: 0 2px 20px rgba(0,0,0,.3);
    padding: .85rem 1.5rem !important;
  }
  .nav-hamburger {
    display: flex !important;
    padding: .65rem .7rem;
    background: rgba(80,200,120,.18);
    border: 1px solid rgba(80,200,120,.35);
    border-radius: 8px;
    gap: 5px;
  }
  .nav-hamburger span {
    width: 26px;
    height: 2px;
    background: #fff !important;
  }
  .nav-right { display: none; }
  .nav-cta { display: none; }
}

/* ─── MOBILE GLOBAL (≤768px) ──────────────────────────── */
@media (max-width: 768px) {

  /* Tipografía base */
  body { font-size: 15px; }

  /* Botones: apilar en columna en pantallas chicas */
  .hero-buttons,
  .cta-final-btns,
  .diag-hero-btns,
  .diag-cta-btns,
  .sob-hero-btns,
  .frank-cta-btns {
    flex-direction: column;
    align-items: stretch;
  }
  .hero-buttons a,
  .cta-final-btns a,
  .diag-hero-btns a,
  .diag-cta-btns a,
  .sob-hero-btns a,
  .frank-cta-btns a {
    text-align: center;
    justify-content: center;
  }

  /* Secciones genéricas */
  .section-std,
  .page-hero { padding: 3.5rem 1.25rem; }

  /* Stats de 2 columnas */
  .stats { grid-template-columns: repeat(2,1fr); gap: .8rem; padding: 2rem 1.25rem; }

  /* Footer */
  .footer-nav { flex-wrap: wrap; gap: .5rem 1.2rem; justify-content: center; font-size: .78rem; }
  .footer-social { gap: .5rem; }

  /* WhatsApp float: más pequeño y sin texto */
  .wa-float { width: 52px; height: 52px; font-size: 0; padding: 0; justify-content: center; }
  .wa-float svg { width: 26px; height: 26px; margin: 0; }
}

/* ─── MOBILE PEQUEÑO (≤480px) ─────────────────────────── */
@media (max-width: 480px) {

  /* Logo nav más pequeño */
  .nav-logo-name { font-size: .95rem; letter-spacing: .22em; }
  .nav-logo-sub  { font-size: .48rem; }

  /* Stats: 1 columna */
  .stats { grid-template-columns: 1fr 1fr; }

  /* Badges: 2 columnas */
  .confianza-badges { display: grid; grid-template-columns: 1fr 1fr; gap: 1.5rem 1rem; }

  /* Botones: ancho completo */
  .btn-primary, .btn-outline-light, .btn-outline-dark,
  .btn-white, .btn-outline-white {
    width: 100%; justify-content: center;
  }

  /* Proceso DOMUS: 1 columna */
  .proceso-steps { grid-template-columns: 1fr !important; }

  /* TikTok iframes: altura proporcional */
  .tiktok-wrap iframe { height: 520px !important; }

  /* Herramientas: tabs scroll horizontal */
  .calc-tabs { overflow-x: auto; -webkit-overflow-scrolling: touch; flex-wrap: nowrap; }
  .calc-tab   { white-space: nowrap; flex-shrink: 0; }

  /* Herramientas: resultado compacto */
  .calc-results { padding: 2rem 1.2rem; }

  /* Frank trayectoria: 1 columna */
  .tray-grid { grid-template-columns: 1fr !important; }

  /* Pilares: 1 columna */
  .pilares { grid-template-columns: 1fr !important; }
}
