/* =========================================================
   APRAI S.A.S. — Hoja de estilos principal
   Paleta derivada del logo: azul #1B3187 · verde salvia #AAC582
   ========================================================= */

:root {
  --navy-950: #0A1438;
  --navy-900: #0F1C52;
  --navy-800: #152670;
  --navy-700: #1B3187;   /* logo */
  --navy-600: #2B45A6;
  --navy-100: #E6EAF6;
  --navy-50:  #F3F5FB;

  --green-500: #AAC582;  /* logo */
  --green-300: #CBDBB4;
  --green-100: #E0EAD2;
  --green-50:  #F4F8EE;
  --green-700: #4E6A2B;  /* texto verde accesible sobre claro */

  --ink:     #1A1F2E;
  --ink-2:   #3A4152;
  --muted:   #5A6275;
  --line:    #DDE2EC;
  --line-2:  #ECEFF5;
  --bg:      #FFFFFF;
  --bg-alt:  #F6F8F4;
  --danger:  #B42318;
  --danger-bg: #FEF3F2;
  --success: #2F6B2A;

  --font-serif: "Source Serif 4", Georgia, "Times New Roman", serif;
  --font-sans: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;

  --radius-sm: 6px;
  --radius: 10px;
  --radius-lg: 18px;
  --shadow-sm: 0 1px 2px rgba(15, 28, 82, .06), 0 1px 3px rgba(15, 28, 82, .08);
  --shadow: 0 10px 30px -12px rgba(15, 28, 82, .22);
  --shadow-lg: 0 30px 60px -20px rgba(15, 28, 82, .35);

  --ease: cubic-bezier(.22, .61, .36, 1);
  --ease-out: cubic-bezier(.16, 1, .3, 1);
  --container: 1200px;
  --gutter: clamp(16px, 4vw, 40px);
  --header-h: 76px;
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 16px); }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font-family: var(--font-sans); font-size: 1.0625rem; line-height: 1.65;
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
img, svg { display: block; max-width: 100%; height: auto; }
a { color: var(--navy-700); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--navy-600); }
button, input, select, textarea { font: inherit; color: inherit; }
h1, h2, h3, h4 { margin: 0 0 .5em; line-height: 1.15; color: var(--navy-900); font-weight: 600; }
h1, h2 { font-family: var(--font-serif); letter-spacing: -.015em; }
h3 { font-size: 1.25rem; letter-spacing: -.005em; }
p { margin: 0 0 1em; }
ul { padding-left: 1.2em; }
:focus-visible { outline: 3px solid var(--green-500); outline-offset: 3px; border-radius: 4px; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link { position: absolute; left: 16px; top: -60px; z-index: 1000; background: var(--navy-900); color: #fff; padding: 10px 16px; border-radius: var(--radius-sm); transition: top .2s; }
.skip-link:focus { top: 12px; color: #fff; }

/* ---------- Layout ---------- */
.container { width: 100%; max-width: var(--container); margin: 0 auto; padding: 0 var(--gutter); }
.container--narrow { max-width: 860px; }
.section { padding: clamp(64px, 9vw, 120px) 0; position: relative; }
.section--alt { background: var(--bg-alt); }
.section--tint { background: var(--navy-50); }
.section--dark { background: var(--navy-900); color: #D7DCEE; }
.section--dark h2, .section--dark h3 { color: #fff; }
.section-head { max-width: 760px; margin-bottom: clamp(36px, 5vw, 56px); }
.section-head--center { margin-left: auto; margin-right: auto; text-align: center; }
.grid { display: grid; gap: clamp(16px, 2.4vw, 28px); }
.grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.split { display: grid; grid-template-columns: 1.05fr .95fr; gap: clamp(32px, 6vw, 88px); align-items: center; }
.split--top { align-items: start; }
@media (max-width: 960px) {
  .grid-3, .grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .split { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
}

/* ---------- Tipografía ---------- */
.eyebrow {
  display: inline-flex; align-items: center; gap: 10px; margin-bottom: 16px;
  font-size: .78rem; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--green-700);
}
.eyebrow::before { content: ""; width: 10px; height: 10px; background: var(--green-500); transform: rotate(45deg) scaleY(.7); flex: none; }
.section--dark .eyebrow, .hero .eyebrow, .page-hero .eyebrow { color: var(--green-500); }
.h-display { font-size: clamp(2.4rem, 5.6vw, 4.4rem); font-weight: 600; line-height: 1.04; }
.h-1 { font-size: clamp(2rem, 4.2vw, 3.2rem); }
.h-2 { font-size: clamp(1.75rem, 3.4vw, 2.6rem); }
.h-display em, .h-1 em, .h-2 em { font-style: italic; font-weight: 500; color: var(--green-500); }
.section:not(.section--dark) .h-2 em, .section:not(.section--dark) .h-1 em { color: var(--navy-600); }
.lead { font-size: clamp(1.08rem, 1.5vw, 1.25rem); line-height: 1.6; color: var(--muted); }
.section--dark .lead { color: #B9C1DD; }
.small { font-size: .9rem; color: var(--muted); }

/* ---------- Botones ---------- */
.btn {
  --bg: var(--navy-700); --fg: #fff; --bd: var(--navy-700);
  position: relative; display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 50px; padding: 12px 24px; border-radius: 999px; border: 1.5px solid var(--bd);
  background: var(--bg); color: var(--fg); font-weight: 600; font-size: .98rem; line-height: 1.2;
  text-decoration: none; cursor: pointer; overflow: hidden; isolation: isolate;
  transition: transform .25s var(--ease), box-shadow .25s var(--ease), background-color .25s, color .25s, border-color .25s;
}
.btn::after {
  content: ""; position: absolute; inset: 0; z-index: -1; background: var(--navy-900);
  transform: translateX(-101%); transition: transform .45s var(--ease-out);
}
.btn:hover { color: var(--fg); transform: translateY(-2px); box-shadow: var(--shadow); }
.btn:hover::after { transform: translateX(0); }
.btn:active { transform: translateY(0); }
.btn .arrow { width: 18px; height: 18px; transition: transform .3s var(--ease); }
.btn:hover .arrow { transform: translateX(4px); }
.btn--light { --bg: #fff; --fg: var(--navy-900); --bd: #fff; }
.btn--light::after { background: var(--green-100); }
.btn--green { --bg: var(--green-500); --fg: var(--navy-950); --bd: var(--green-500); }
.btn--green::after { background: #fff; }
.btn--ghost { --bg: transparent; --fg: var(--navy-700); --bd: var(--navy-700); }
.btn--ghost::after { background: var(--navy-700); }
.btn--ghost:hover { --fg: #fff; }
.btn--ghost-light { --bg: transparent; --fg: #fff; --bd: rgba(255,255,255,.45); }
.btn--ghost-light::after { background: rgba(255,255,255,.12); }
.btn--sm { min-height: 42px; padding: 8px 18px; font-size: .92rem; }
.btn--block { width: 100%; }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; }
.link-arrow { display: inline-flex; align-items: center; gap: 8px; font-weight: 600; text-decoration: none; color: var(--navy-700); }
.link-arrow svg { width: 16px; height: 16px; transition: transform .3s var(--ease); }
.link-arrow:hover svg { transform: translateX(4px); }

/* ---------- Encabezado ---------- */
.progress { position: fixed; top: 0; left: 0; height: 3px; width: 100%; z-index: 120; background: linear-gradient(90deg, var(--green-500), var(--navy-600)); transform-origin: 0 50%; transform: scaleX(0); }
.site-header {
  position: sticky; top: 0; z-index: 100; height: var(--header-h);
  background: rgba(255,255,255,.92); backdrop-filter: saturate(160%) blur(12px); -webkit-backdrop-filter: saturate(160%) blur(12px);
  border-bottom: 1px solid transparent; transition: height .3s var(--ease), box-shadow .3s, border-color .3s;
}
.site-header.is-scrolled { --header-h: 64px; box-shadow: 0 6px 24px -16px rgba(15,28,82,.35); border-color: var(--line-2); }
.header-inner { height: 100%; display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; flex: none; }
.brand img { width: 112px; height: auto; transition: width .3s var(--ease); }
.site-header.is-scrolled .brand img { width: 98px; }
.brand-tag { display: none; font-size: .7rem; line-height: 1.25; color: var(--muted); letter-spacing: .04em; border-left: 1px solid var(--line); padding-left: 12px; }
@media (min-width: 1360px) { .brand-tag { display: block; } }

.nav { display: flex; align-items: center; gap: 4px; }
.nav-list { display: flex; align-items: center; gap: 2px; list-style: none; margin: 0; padding: 0; }
.nav-link, .nav-trigger {
  position: relative; display: inline-flex; align-items: center; gap: 6px; padding: 10px 12px;
  font-size: .95rem; font-weight: 500; color: var(--ink-2); text-decoration: none; background: none; border: 0; cursor: pointer; white-space: nowrap;
}
.header-cta { white-space: nowrap; }
.nav-link::after, .nav-trigger::after {
  content: ""; position: absolute; left: 12px; right: 12px; bottom: 4px; height: 2px; background: var(--green-500);
  transform: scaleX(0); transform-origin: left; transition: transform .3s var(--ease);
}
.nav-link:hover, .nav-trigger:hover, .nav-link[aria-current="page"] { color: var(--navy-700); }
.nav-link:hover::after, .nav-trigger:hover::after, .nav-link[aria-current="page"]::after, .nav-trigger[aria-expanded="true"]::after { transform: scaleX(1); }
.nav-trigger svg { width: 14px; height: 14px; transition: transform .25s; }
.nav-trigger[aria-expanded="true"] svg { transform: rotate(180deg); }
.has-menu { position: relative; }
.mega {
  position: absolute; top: calc(100% + 10px); left: 50%; width: min(640px, 90vw);
  transform: translate(-50%, 8px); opacity: 0; visibility: hidden; pointer-events: none;
  background: #fff; border: 1px solid var(--line-2); border-radius: var(--radius-lg); box-shadow: var(--shadow-lg);
  padding: 14px; display: grid; grid-template-columns: 1fr 1fr; gap: 4px;
  transition: opacity .22s var(--ease), transform .22s var(--ease), visibility 0s .22s;
}
.mega.is-open { opacity: 1; visibility: visible; pointer-events: auto; transform: translate(-50%, 0); transition-delay: 0s; }
.mega a { display: block; padding: 12px 14px; border-radius: var(--radius); text-decoration: none; color: var(--ink); transition: background-color .2s; }
.mega a:hover { background: var(--navy-50); }
.mega strong { display: block; font-size: .95rem; color: var(--navy-900); }
.mega span { display: block; font-size: .82rem; color: var(--muted); line-height: 1.45; margin-top: 2px; }
.mega .mega-featured { grid-column: 1 / -1; background: var(--green-50); border: 1px solid var(--green-100); }
.mega .mega-featured:hover { background: var(--green-100); }
.header-cta { margin-left: 10px; }

.menu-toggle { display: none; width: 46px; height: 46px; border-radius: 50%; border: 1px solid var(--line); background: #fff; cursor: pointer; position: relative; }
.menu-toggle span { position: absolute; left: 13px; right: 13px; height: 2px; background: var(--navy-900); border-radius: 2px; transition: transform .3s var(--ease), opacity .2s; }
.menu-toggle span:nth-child(1) { top: 16px; } .menu-toggle span:nth-child(2) { top: 22px; } .menu-toggle span:nth-child(3) { top: 28px; }
.menu-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.menu-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.menu-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

@media (max-width: 1023px) {
  /* backdrop-filter crearía un bloque contenedor para el panel fijo del menú */
  .site-header { backdrop-filter: none; -webkit-backdrop-filter: none; background: #fff; }
  .menu-toggle { display: inline-block; }
  .nav {
    position: fixed; inset: var(--header-h) 0 0 0; z-index: 99; background: #fff;
    flex-direction: column; align-items: stretch; gap: 0; padding: 12px var(--gutter) 32px; overflow-y: auto;
    opacity: 0; visibility: hidden; transform: translateY(-8px); transition: opacity .25s var(--ease), transform .25s var(--ease), visibility 0s .25s;
  }
  .nav.is-open { opacity: 1; visibility: visible; transform: none; transition-delay: 0s; }
  .nav-list { flex-direction: column; align-items: stretch; }
  .nav-link, .nav-trigger { width: 100%; justify-content: space-between; padding: 16px 4px; font-size: 1.08rem; border-bottom: 1px solid var(--line-2); }
  .nav-link::after, .nav-trigger::after { display: none; }
  .mega { position: static; width: auto; transform: none; box-shadow: none; border: 0; padding: 0 0 8px; grid-template-columns: 1fr; display: none; opacity: 1; visibility: visible; pointer-events: auto; }
  .mega.is-open { display: grid; transform: none; }
  .header-cta { margin: 24px 0 0; width: 100%; }
  body.nav-open { overflow: hidden; }
}

/* ---------- Hero (inicio) ---------- */
.hero {
  position: relative; overflow: hidden; color: #D7DCEE;
  background: radial-gradient(1200px 600px at 85% 10%, rgba(43,69,166,.55), transparent 60%), linear-gradient(160deg, var(--navy-900) 0%, var(--navy-950) 100%);
  padding: clamp(72px, 11vw, 140px) 0 clamp(64px, 9vw, 110px);
}
.hero h1 { color: #fff; margin-bottom: 24px; }
.hero .lead { color: #BAC2DE; max-width: 600px; margin-bottom: 36px; }
.hero-grid { display: grid; grid-template-columns: 1.15fr .85fr; gap: 48px; align-items: center; position: relative; z-index: 1; }
.hero-trust { display: flex; flex-wrap: wrap; gap: 10px 28px; margin-top: 44px; padding-top: 28px; border-top: 1px solid rgba(255,255,255,.12); font-size: .9rem; color: #AEB7D6; }
.hero-trust span { display: inline-flex; align-items: center; gap: 10px; }
.hero-trust svg { width: 18px; height: 18px; color: var(--green-500); flex: none; }
.hero-art { position: relative; aspect-ratio: 1 / 1; }
.hero-art svg { width: 100%; height: 100%; overflow: visible; }
.hero-art .rh { fill: none; stroke: var(--green-500); stroke-width: 1.2; opacity: .55; stroke-dasharray: 1200; stroke-dashoffset: 1200; animation: draw 2.4s var(--ease-out) forwards; }
.hero-art .rh:nth-child(2) { animation-delay: .15s; opacity: .4; } .hero-art .rh:nth-child(3) { animation-delay: .3s; opacity: .3; }
.hero-art .rh:nth-child(4) { animation-delay: .45s; opacity: .2; } .hero-art .rh:nth-child(5) { animation-delay: .6s; opacity: .12; }
.hero-art .rh-fill { fill: url(#gGreen); opacity: 0; animation: fadeIn 1.4s .9s var(--ease) forwards; }
.hero-card {
  position: absolute; background: rgba(255,255,255,.96); color: var(--ink); border-radius: var(--radius); padding: 14px 18px; box-shadow: var(--shadow-lg);
  display: flex; align-items: center; gap: 12px; font-size: .88rem; line-height: 1.35; opacity: 0; animation: floatIn .9s var(--ease-out) forwards;
}
.hero-card strong { display: block; color: var(--navy-900); font-size: 1rem; }
.hero-card .ic { width: 38px; height: 38px; border-radius: 50%; background: var(--green-100); color: var(--green-700); display: grid; place-items: center; flex: none; }
.hero-card .ic svg { width: 20px; height: 20px; }
.hero-card--a { top: 14%; left: -6%; animation-delay: 1.2s; }
.hero-card--b { bottom: 16%; right: -4%; animation-delay: 1.45s; }
.hero-card--a, .hero-card--b { --float: 0; }
@keyframes draw { to { stroke-dashoffset: 0; } }
@keyframes fadeIn { to { opacity: 1; } }
@keyframes floatIn { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: none; } }
@keyframes drift { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }
.hero-card.is-live { animation: drift 6s ease-in-out infinite; opacity: 1; }
.hero-pattern { position: absolute; inset: 0; opacity: .07; pointer-events: none;
  background-image: linear-gradient(30deg, transparent 49.3%, #fff 49.6%, #fff 50.4%, transparent 50.7%), linear-gradient(-30deg, transparent 49.3%, #fff 49.6%, #fff 50.4%, transparent 50.7%);
  background-size: 120px 70px; mask-image: linear-gradient(90deg, transparent 30%, #000 100%); -webkit-mask-image: linear-gradient(90deg, transparent 30%, #000 100%); }
.split-word { display: inline-block; opacity: 0; transform: translateY(.4em); animation: wordIn .8s var(--ease-out) forwards; }
@keyframes wordIn { to { opacity: 1; transform: none; } }
@media (max-width: 960px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero-art { max-width: 420px; margin: 8px auto 0; width: 100%; }
  .hero-card--a { left: 0; } .hero-card--b { right: 0; }
}

/* ---------- Hero interior ---------- */
.page-hero {
  position: relative; overflow: hidden; color: #C9D0E8;
  background: radial-gradient(900px 400px at 90% 0%, rgba(43,69,166,.5), transparent 60%), linear-gradient(160deg, var(--navy-900), var(--navy-950));
  padding: clamp(56px, 8vw, 104px) 0 clamp(52px, 7vw, 88px);
}
.page-hero h1 { color: #fff; max-width: 880px; }
.page-hero .lead { color: #BAC2DE; max-width: 720px; }
.page-hero .btn-row { margin-top: 32px; }
.breadcrumb { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; padding: 0; margin: 0 0 28px; font-size: .85rem; color: #8F99BE; }
.breadcrumb a { color: #C9D0E8; text-decoration: none; }
.breadcrumb a:hover { color: #fff; text-decoration: underline; }
.breadcrumb li + li::before { content: "/"; margin-right: 8px; opacity: .5; }
.page-hero .hero-pattern { opacity: .06; }

/* ---------- Cifras ---------- */
.stats { background: #fff; border-bottom: 1px solid var(--line-2); }
.stats-grid { display: grid; grid-template-columns: repeat(4, 1fr); }
.stat { padding: clamp(28px, 4vw, 44px) clamp(12px, 2vw, 28px); border-left: 1px solid var(--line-2); }
.stat:first-child { border-left: 0; }
.stat-num { font-family: var(--font-serif); font-size: clamp(2.2rem, 4vw, 3.2rem); font-weight: 600; line-height: 1; color: var(--navy-700); display: flex; align-items: baseline; gap: 2px; }
.stat-num small { font-size: .55em; color: var(--green-700); }
.stat p { margin: 10px 0 0; font-size: .92rem; color: var(--muted); line-height: 1.45; }
@media (max-width: 860px) { .stats-grid { grid-template-columns: repeat(2, 1fr); } .stat:nth-child(3) { border-left: 0; } .stat:nth-child(n+3) { border-top: 1px solid var(--line-2); } }

/* ---------- Tarjetas ---------- */
.card {
  position: relative; display: flex; flex-direction: column; height: 100%;
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius-lg); padding: clamp(24px, 3vw, 34px);
  transition: transform .35s var(--ease), box-shadow .35s var(--ease), border-color .35s;
}
.card::before { content: ""; position: absolute; left: 0; right: 0; top: -1px; height: 3px; border-radius: var(--radius-lg) var(--radius-lg) 0 0; background: linear-gradient(90deg, var(--navy-700), var(--green-500)); transform: scaleX(0); transform-origin: left; transition: transform .5s var(--ease-out); }
.card:hover { transform: translateY(-6px); box-shadow: var(--shadow); border-color: transparent; }
.card:hover::before { transform: scaleX(1); }
.card h3 { margin-top: 4px; }
.card p { color: var(--muted); font-size: .98rem; }
.card .link-arrow { margin-top: auto; padding-top: 8px; }
.card-link { position: absolute; inset: 0; z-index: 1; border-radius: inherit; }
.card .ic {
  width: 52px; height: 52px; border-radius: 14px; margin-bottom: 18px; display: grid; place-items: center;
  background: var(--navy-50); color: var(--navy-700); transition: background-color .35s, color .35s, transform .35s var(--ease);
}
.card:hover .ic { background: var(--navy-700); color: #fff; transform: rotate(-6deg) scale(1.04); }
.card .ic svg { width: 26px; height: 26px; }
.card--feature { background: linear-gradient(180deg, #fff, var(--green-50)); border-color: var(--green-100); }
.tag { display: inline-block; align-self: flex-start; font-size: .72rem; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; padding: 5px 10px; border-radius: 999px; background: var(--green-100); color: var(--green-700); margin-bottom: 14px; }
.tag--navy { background: var(--navy-100); color: var(--navy-700); }

/* Renta: dos perfiles */
.renta-split { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(16px, 2.4vw, 28px); }
.profile {
  position: relative; overflow: hidden; border-radius: var(--radius-lg); padding: clamp(28px, 4vw, 44px); min-height: 100%;
  display: flex; flex-direction: column; isolation: isolate; transition: transform .4s var(--ease), box-shadow .4s var(--ease);
}
.profile:hover { transform: translateY(-6px); box-shadow: var(--shadow-lg); }
.profile--co { background: #fff; border: 1px solid var(--line); }
.profile--ext { background: linear-gradient(150deg, var(--navy-800), var(--navy-950)); color: #C9D0E8; }
.profile--ext h3 { color: #fff; }
.profile h3 { font-family: var(--font-serif); font-size: clamp(1.5rem, 2.4vw, 1.9rem); font-weight: 600; }
.profile .deco { position: absolute; right: -60px; top: -60px; width: 220px; height: 220px; z-index: -1; opacity: .5; transition: transform .8s var(--ease-out); }
.profile:hover .deco { transform: rotate(12deg) scale(1.08); }
.profile ul { margin: 8px 0 28px; }
.profile .btn-row { margin-top: auto; }
@media (max-width: 860px) { .renta-split { grid-template-columns: 1fr; } }

/* Listas con rombo */
.check-list { list-style: none; padding: 0; margin: 0 0 1em; display: grid; gap: 12px; }
.check-list li { position: relative; padding-left: 28px; }
.check-list li::before { content: ""; position: absolute; left: 4px; top: .55em; width: 10px; height: 10px; background: var(--green-500); transform: rotate(45deg) scaleY(.75); }
.profile--ext .check-list li::before, .section--dark .check-list li::before { background: var(--green-500); }
.check-list--cols { grid-template-columns: 1fr 1fr; gap: 12px 32px; }
@media (max-width: 640px) { .check-list--cols { grid-template-columns: 1fr; } }

/* ---------- Metodología ---------- */
.steps { position: relative; display: grid; grid-template-columns: repeat(4, 1fr); gap: clamp(16px, 2.4vw, 28px); counter-reset: step; }
.steps-line { position: absolute; left: 0; right: 0; top: 27px; height: 2px; background: rgba(255,255,255,.12); }
.section:not(.section--dark) .steps-line { background: var(--line); }
.steps-line i { position: absolute; inset: 0; background: linear-gradient(90deg, var(--green-500), var(--navy-600)); transform: scaleX(0); transform-origin: left; transition: transform 1.6s var(--ease-out); }
.steps.is-visible .steps-line i { transform: scaleX(1); }
.step { position: relative; counter-increment: step; }
.step-num {
  position: relative; z-index: 1; width: 56px; height: 56px; margin-bottom: 22px; display: grid; place-items: center;
  font-family: var(--font-serif); font-size: 1.25rem; font-weight: 600; color: var(--navy-950); background: var(--green-500);
  clip-path: polygon(50% 0, 100% 50%, 50% 100%, 0 50%); transition: transform .4s var(--ease);
}
.step:hover .step-num { transform: scale(1.1) rotate(90deg); }
.step:hover .step-num span { transform: rotate(-90deg); }
.step-num span { display: block; transition: transform .4s var(--ease); }
.step h3 { font-size: 1.15rem; }
.step p { font-size: .96rem; color: inherit; opacity: .85; margin: 0; }
.section:not(.section--dark) .step p { color: var(--muted); opacity: 1; }
@media (max-width: 960px) {
  .steps { grid-template-columns: 1fr; gap: 0; }
  .steps-line { left: 27px; right: auto; top: 0; bottom: 0; width: 2px; height: auto; }
  .steps-line i { transform: scaleY(0); transform-origin: top; }
  .steps.is-visible .steps-line i { transform: scaleY(1); }
  .step { display: grid; grid-template-columns: 56px 1fr; gap: 0 20px; padding-bottom: 32px; }
  .step-num { margin: 0; grid-row: span 2; }
}

/* ---------- Pilares / Diferenciales ---------- */
.pillar { padding: 28px 0 0; border-top: 1px solid var(--line); }
.section--dark .pillar { border-color: rgba(255,255,255,.14); }
.pillar h3 { display: flex; align-items: center; gap: 12px; }
.pillar h3::before { content: ""; width: 12px; height: 12px; background: var(--green-500); transform: rotate(45deg) scaleY(.7); flex: none; }
.pillar p { color: var(--muted); margin: 0; }
.section--dark .pillar p { color: #B9C1DD; }

/* Credenciales */
.creds { display: grid; gap: 0; border: 1px solid var(--line); border-radius: var(--radius-lg); background: #fff; overflow: hidden; box-shadow: var(--shadow-sm); }
.cred { display: grid; grid-template-columns: 1fr auto; gap: 16px; align-items: center; padding: 20px 24px; border-top: 1px solid var(--line-2); }
.cred:first-child { border-top: 0; }
.cred dt { color: var(--muted); font-size: .92rem; }
.cred dd { margin: 0; font-weight: 600; color: var(--navy-900); text-align: right; font-variant-numeric: tabular-nums; }
.quote-block { position: relative; padding: clamp(28px, 4vw, 44px); border-radius: var(--radius-lg); background: var(--navy-900); color: #D7DCEE; }
.quote-block p { font-family: var(--font-serif); font-size: clamp(1.2rem, 2vw, 1.5rem); line-height: 1.45; color: #fff; }
.quote-block small { color: var(--green-500); font-weight: 600; letter-spacing: .08em; text-transform: uppercase; font-size: .75rem; }

/* Sectores */
.sector { display: flex; gap: 18px; padding: 24px; border-radius: var(--radius-lg); background: #fff; border: 1px solid var(--line); transition: border-color .3s, box-shadow .3s, transform .3s var(--ease); height: 100%; }
.sector:hover { border-color: var(--green-500); box-shadow: var(--shadow-sm); transform: translateY(-3px); }
.sector .ic { width: 46px; height: 46px; flex: none; display: grid; place-items: center; border-radius: 12px; background: var(--green-100); color: var(--green-700); }
.sector .ic svg { width: 24px; height: 24px; }
.sector h3 { font-size: 1.08rem; margin-bottom: 6px; }
.sector p { margin: 0; font-size: .95rem; color: var(--muted); }

/* ---------- FAQ ---------- */
.faq { border-top: 1px solid var(--line); }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary {
  list-style: none; cursor: pointer; padding: 22px 48px 22px 0; position: relative;
  font-weight: 600; font-size: 1.05rem; color: var(--navy-900); transition: color .2s;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary:hover { color: var(--navy-600); }
.faq summary::after {
  content: ""; position: absolute; right: 8px; top: 50%; width: 14px; height: 14px; margin-top: -9px;
  border-right: 2px solid var(--navy-700); border-bottom: 2px solid var(--navy-700); transform: rotate(45deg); transition: transform .3s var(--ease);
}
.faq details[open] summary::after { transform: rotate(-135deg); margin-top: -2px; }
.faq .faq-body { overflow: hidden; }
.faq .faq-body > div { padding: 0 0 24px; color: var(--muted); }
.faq .faq-body p:last-child { margin-bottom: 0; }

/* ---------- Banda CTA ---------- */
.cta-band { position: relative; overflow: hidden; border-radius: var(--radius-lg); padding: clamp(36px, 6vw, 72px); background: linear-gradient(135deg, var(--navy-700), var(--navy-950)); color: #C9D0E8; display: grid; grid-template-columns: 1.4fr auto; gap: 32px; align-items: center; }
.cta-band h2 { color: #fff; margin-bottom: 10px; }
.cta-band p { margin: 0; }
.cta-band .deco { position: absolute; right: -80px; bottom: -120px; width: 380px; opacity: .25; pointer-events: none; }
@media (max-width: 860px) { .cta-band { grid-template-columns: 1fr; } }

/* ---------- Formulario ---------- */
.form-wrap { display: grid; grid-template-columns: .8fr 1.2fr; gap: clamp(32px, 5vw, 72px); align-items: start; }
@media (max-width: 960px) { .form-wrap { grid-template-columns: 1fr; } .page-contacto .form-card { order: -1; } }
.form-aside .check-list { margin-top: 24px; }
.contact-lines { list-style: none; padding: 0; margin: 28px 0 0; display: grid; gap: 14px; font-size: .96rem; }
.contact-lines li { display: flex; gap: 12px; align-items: flex-start; }
.contact-lines svg { width: 20px; height: 20px; color: var(--navy-700); flex: none; margin-top: 3px; }
.form-card { position: relative; background: #fff; border: 1px solid var(--line); border-radius: var(--radius-lg); padding: clamp(22px, 4vw, 44px); box-shadow: var(--shadow); }
.form-card h3 { font-family: var(--font-serif); font-size: 1.5rem; }
.form-intro { color: var(--muted); font-size: .95rem; margin-bottom: 24px; }
.fieldset { border: 0; padding: 0; margin: 0 0 22px; min-width: 0; }
.fieldset[hidden] { display: none; }
.fieldset.is-entering { animation: fieldIn .45s var(--ease-out); }
@keyframes fieldIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.legend { display: block; font-weight: 600; color: var(--navy-900); margin-bottom: 12px; font-size: .98rem; padding: 0; }
.legend .opt, .label .opt { font-weight: 400; color: var(--muted); font-size: .85rem; }
.service-options { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
@media (max-width: 520px) { .service-options { grid-template-columns: 1fr; } }
.choice { position: relative; }
.choice input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.choice label {
  display: flex; gap: 12px; align-items: flex-start; height: 100%; padding: 14px 16px; border: 1.5px solid var(--line); border-radius: var(--radius); cursor: pointer;
  transition: border-color .2s, background-color .2s, box-shadow .2s; font-size: .93rem; line-height: 1.35;
}
.choice label strong { display: block; color: var(--navy-900); font-size: .97rem; margin-bottom: 2px; }
.choice label span { color: var(--muted); font-size: .84rem; }
.choice label::before { content: ""; flex: none; width: 18px; height: 18px; margin-top: 2px; border-radius: 50%; border: 2px solid #9AA3B8; transition: border-color .2s, box-shadow .2s, background-color .2s; }
.choice input[type="checkbox"] + label::before { border-radius: 5px; }
.choice label:hover { border-color: var(--navy-600); }
.choice input:checked + label { border-color: var(--navy-700); background: var(--navy-50); box-shadow: 0 0 0 3px rgba(27,49,135,.08); }
.choice input:checked + label::before { border-color: var(--navy-700); background: var(--navy-700); box-shadow: inset 0 0 0 3px #fff; }
.choice input[type="checkbox"]:checked + label::before { box-shadow: none; background: var(--navy-700) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M3.5 8.5l3 3 6-7' fill='none' stroke='%23fff' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center/12px no-repeat; }
.choice input:focus-visible + label { outline: 3px solid var(--green-500); outline-offset: 2px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chips .choice label { padding: 9px 14px; border-radius: 999px; align-items: center; }
.chips .choice label::before { margin-top: 0; width: 16px; height: 16px; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px 16px; }
.form-grid .full { grid-column: 1 / -1; }
@media (max-width: 560px) { .form-grid { grid-template-columns: 1fr; } }
.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.label { font-weight: 600; font-size: .9rem; color: var(--navy-900); }
.input, .select, .textarea {
  width: 100%; min-height: 50px; padding: 12px 14px; border: 1.5px solid var(--line); border-radius: var(--radius); background: #fff;
  font-size: 1rem; transition: border-color .2s, box-shadow .2s; appearance: none; -webkit-appearance: none;
}
.select { padding-right: 40px; background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M4 6l4 4 4-4' fill='none' stroke='%231B3187' stroke-width='1.8' stroke-linecap='round'/%3E%3C/svg%3E") right 14px center/16px no-repeat; }
.textarea { min-height: 120px; resize: vertical; }
.input:hover, .select:hover, .textarea:hover { border-color: #B9C1D3; }
.input:focus, .select:focus, .textarea:focus { outline: none; border-color: var(--navy-700); box-shadow: 0 0 0 4px rgba(27,49,135,.12); }
.field.has-error .input, .field.has-error .select, .field.has-error .textarea { border-color: var(--danger); background: var(--danger-bg); }
.field.is-valid .input { border-color: #8DB26A; }
.error-msg { display: none; font-size: .84rem; color: var(--danger); font-weight: 500; }
.has-error > .error-msg, .fieldset.has-error .error-msg { display: block; animation: fieldIn .25s var(--ease); }
.hint { font-size: .82rem; color: var(--muted); }
.consent { display: flex; gap: 12px; align-items: flex-start; font-size: .88rem; color: var(--ink-2); line-height: 1.5; }
.consent input { width: 20px; height: 20px; margin: 2px 0 0; flex: none; accent-color: var(--navy-700); }
.hp { position: absolute !important; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 16px; margin-top: 24px; }
.form-actions .small { margin: 0; flex: 1 1 220px; }
.btn .spinner { display: none; width: 18px; height: 18px; border: 2px solid rgba(255,255,255,.4); border-top-color: #fff; border-radius: 50%; animation: spin .8s linear infinite; }
.btn.is-loading .spinner { display: inline-block; }
.btn.is-loading .arrow { display: none; }
.btn[disabled] { cursor: progress; opacity: .85; transform: none; }
@keyframes spin { to { transform: rotate(360deg); } }
.form-alert { display: none; margin-top: 18px; padding: 14px 16px; border-radius: var(--radius); background: var(--danger-bg); color: var(--danger); border: 1px solid #F5C2BD; font-size: .93rem; }
.form-alert.is-visible { display: block; animation: fieldIn .3s var(--ease); }
.form-success { display: none; text-align: center; padding: clamp(16px, 3vw, 32px) 0; }
.form-success.is-visible { display: block; animation: fieldIn .5s var(--ease-out); }
.form-success h3 { margin-top: 18px; }
.form-success p { color: var(--muted); max-width: 440px; margin-left: auto; margin-right: auto; }
.success-mark { width: 84px; height: 84px; margin: 0 auto; }
.success-mark path, .success-mark polygon { stroke-dasharray: 300; stroke-dashoffset: 300; animation: draw 1s .1s var(--ease-out) forwards; }
.success-mark path { animation-delay: .5s; }
.ref-code { display: inline-block; margin: 8px 0 20px; padding: 6px 14px; border-radius: 999px; background: var(--navy-50); color: var(--navy-700); font-weight: 600; font-variant-numeric: tabular-nums; letter-spacing: .04em; }

/* ---------- Contenido largo ---------- */
.prose { max-width: 760px; }
.prose h2 { font-size: clamp(1.5rem, 2.6vw, 2rem); margin-top: 1.6em; }
.prose h3 { margin-top: 1.4em; }
.prose p, .prose li { color: var(--ink-2); }
.prose li { margin-bottom: .4em; }
.note { padding: 18px 20px; border-left: 3px solid var(--green-500); background: var(--green-50); border-radius: 0 var(--radius) var(--radius) 0; font-size: .95rem; color: var(--ink-2); }
.note strong { color: var(--navy-900); }
.toc { position: sticky; top: calc(var(--header-h) + 24px); padding: 24px; border: 1px solid var(--line); border-radius: var(--radius-lg); background: #fff; }
.toc ol { margin: 0; padding-left: 1.2em; display: grid; gap: 8px; font-size: .95rem; }
.toc a { text-decoration: none; }
.pending { background: #FFF4CC; outline: 1px dashed #C99A00; padding: 0 4px; border-radius: 3px; }

/* ---------- Pie ---------- */
.site-footer { background: var(--navy-950); color: #9DA6C8; padding: clamp(56px, 7vw, 88px) 0 28px; font-size: .94rem; }
.footer-grid { display: grid; grid-template-columns: 1.3fr 1fr 1fr 1.2fr; gap: 40px; }
.footer-brand .logo-chip { display: inline-block; background: #fff; border-radius: var(--radius); padding: 10px 14px; margin-bottom: 18px; }
.footer-brand .logo-chip img { width: 120px; }
.site-footer h2 { font-family: var(--font-sans); font-size: .78rem; letter-spacing: .14em; text-transform: uppercase; color: #fff; margin-bottom: 16px; }
.site-footer ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.site-footer a { color: #C9D0E8; text-decoration: none; }
.site-footer a:hover { color: #fff; text-decoration: underline; }
.footer-legal { margin-top: 48px; padding-top: 24px; border-top: 1px solid rgba(255,255,255,.1); display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; font-size: .84rem; color: #7F89AF; }
@media (max-width: 960px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .footer-grid { grid-template-columns: 1fr; } }

/* ---------- Revelado al hacer scroll ---------- */
.js [data-reveal] { opacity: 0; transform: translateY(28px); transition: opacity .9s var(--ease-out), transform .9s var(--ease-out); transition-delay: var(--d, 0s); }
.js [data-reveal="left"] { transform: translateX(-28px); }
.js [data-reveal="right"] { transform: translateX(28px); }
.js [data-reveal="scale"] { transform: scale(.96); }
.js [data-reveal].is-visible { opacity: 1; transform: none; }
main, .site-footer { overflow-x: clip; }
@media (max-width: 960px) { .js [data-reveal="left"], .js [data-reveal="right"] { transform: translateY(28px); } }

/* ---------- Movimiento reducido ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; animation-delay: 0s !important; transition-duration: .001ms !important; transition-delay: 0s !important; }
  .js [data-reveal] { opacity: 1; transform: none; }
  .hero-art .rh { stroke-dashoffset: 0; }
  .split-word { opacity: 1; transform: none; }
}

@media print {
  .site-header, .site-footer, .progress, .hero-art, .cta-band { display: none !important; }
  body { color: #000; }
}
