/* ==========================================================================
   CrediListo — components.css (v2, rediseño completo)
   Cada sección tiene una composición propia — nada de "card grid" repetido
   siete veces. Inspirado en el análisis real de Fase 2 (Wise/Monzo/Revolut):
   tipografía enorme con carácter, bloques de color a sangre completa,
   franjas de confianza con cifras verificables, formas orgánicas.
   ========================================================================== */

/* ---- Botones ---- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.05rem;
  padding: 1rem 1.9rem;
  border-radius: var(--radius-pill);
  transition: transform 0.2s var(--ease), box-shadow 0.2s var(--ease);
  white-space: nowrap;
}
.btn:hover { transform: translateY(-3px) scale(1.01); }
.btn:active { transform: translateY(-1px) scale(0.99); }

.btn--primary { background: var(--green-300); color: var(--navy-900); box-shadow: var(--shadow-md); }
.btn--primary:hover { box-shadow: var(--shadow-lg); }

.btn--onlight { background: var(--navy-900); color: var(--white); box-shadow: var(--shadow-sm); }
.btn--onlight:hover { box-shadow: var(--shadow-md); }

.btn--outline {
  background: transparent;
  color: var(--white);
  border: 2px solid rgba(255,255,255,0.35);
}
.btn--outline:hover { border-color: var(--white); }
.btn--outline.on-light { color: var(--navy-900); border-color: var(--gray-200); }
.btn--outline.on-light:hover { border-color: var(--navy-900); }

.btn--whatsapp { background: var(--whatsapp-green); color: var(--white); }
.btn--whatsapp:hover { box-shadow: var(--shadow-md); }

.btn--block { width: 100%; }
.btn--sm { padding: 0.7rem 1.3rem; font-size: 0.92rem; }
.btn svg { width: 20px; height: 20px; flex-shrink: 0; }

/* ---- Header: transparente sobre el hero, sólido al hacer scroll ---- */
.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 900;
  height: var(--header-height);
  display: flex;
  align-items: center;
  background: transparent;
  transition: background 0.3s ease, box-shadow 0.3s ease, backdrop-filter 0.3s ease;
}
.site-header.is-scrolled {
  background: rgba(255, 255, 255, 0.72);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border-bottom: 1px solid rgba(255,255,255,0.5);
  box-shadow: 0 8px 24px rgba(7,29,40,0.08);
}
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .site-header.is-scrolled { background: rgba(255,255,255,0.96); }
}
.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
}

.brand { display: flex; align-items: center; gap: 0.5rem; }
.brand img {
  height: 34px; width: auto;
  transition: filter 0.3s ease;
  filter: brightness(0) invert(1); /* blanco sobre el hero transparente */
}
.site-header.is-scrolled .brand img { filter: none; } /* logo a color cuando el header ya tiene fondo sólido */

.nav-desktop { display: none; }
.nav-desktop ul { display: flex; align-items: center; gap: clamp(1.25rem, 1vw + 0.9rem, 2.25rem); }
.nav-desktop a {
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--white);
  position: relative;
  padding-block: 0.4rem;
  transition: color 0.3s ease;
}
.site-header.is-scrolled .nav-desktop a { color: var(--navy-900); }
.nav-desktop a::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: -2px;
  height: 2px;
  background: var(--green-500);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.2s ease;
}
.nav-desktop a:hover::after,
.nav-desktop a[aria-current="page"]::after { transform: scaleX(1); }

.header-actions { display: flex; align-items: center; gap: var(--space-3); }
.header-actions .btn--primary { color: var(--navy-900); }
/* En mobile (<980px) el CTA del header top-bar se oculta: logo + hamburguesa
   no dejan espacio para un botón con texto sin desbordar en pantallas de
   320-375px. El CTA sigue disponible de inmediato al abrir el menú (mismo
   botón, a ancho completo, dentro de .nav-mobile). */
.site-header > .container > .header-actions { display: none; }

.nav-toggle {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  border-radius: var(--radius-sm);
}
.nav-toggle span { display: block; width: 22px; height: 2px; background: var(--white); transition: transform 0.25s ease, opacity 0.25s ease, background 0.3s ease; }
.site-header.is-scrolled .nav-toggle span { background: var(--navy-900); }
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
.nav-toggle[aria-expanded="true"] span { background: var(--navy-900) !important; }

.nav-mobile {
  position: fixed;
  inset: 0;
  background: var(--navy-900);
  padding: calc(var(--header-height) + var(--space-4)) var(--space-4) var(--space-5);
  transform: translateY(-100%);
  transition: transform 0.4s var(--ease);
  z-index: 850;
  overflow-y: auto;
}
.nav-mobile.is-open { transform: translateY(0); }
/* Logo dentro del overlay: sin esto no había forma de volver al Home una vez
   abierto el menú, el logo del header queda tapado por el propio overlay. */
.nav-mobile__brand { display: inline-flex; align-items: center; margin-bottom: var(--space-6); }
.nav-mobile__brand img { height: 30px; width: auto; filter: brightness(0) invert(1); }
.nav-mobile ul { display: flex; flex-direction: column; gap: var(--space-3); margin-bottom: var(--space-5); }
.nav-mobile a { font-family: var(--font-display); font-size: 2rem; font-weight: 800; color: var(--white); }
.nav-mobile .header-actions { flex-direction: column; align-items: stretch; }
.nav-mobile .header-actions .btn { width: 100%; }

body.nav-open { overflow: hidden; }

@media (min-width: 980px) {
  .nav-desktop { display: block; }
  .nav-toggle { display: none; }
  .nav-mobile { display: none; }
  .site-header > .container > .header-actions { display: flex; }
}

/* ---- Hero: sangre completa, oscuro, tipografía enorme ---- */
.hero {
  position: relative;
  min-height: 100svh;
  display: flex;
  align-items: center;
  padding-block: calc(var(--header-height) + var(--space-6)) var(--space-7);
  background: var(--gradient-hero);
  color: var(--white);
  overflow: hidden;
}
.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--gradient-mesh);
  pointer-events: none;
}
.hero-blob {
  position: absolute;
  top: -10%;
  right: -12%;
  width: min(60vw, 720px);
  aspect-ratio: 1;
  opacity: 0.9;
  filter: blur(0.5px);
  animation: float 14s ease-in-out infinite;
  pointer-events: none;
}
@keyframes float {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  50% { transform: translateY(24px) rotate(6deg); }
}

.hero .container { position: relative; z-index: 1; }

.hero-copy { max-width: 920px; }
.hero-copy .eyebrow { color: var(--green-300); }
.hero-copy h1 {
  font-size: var(--fs-display);
  color: var(--white);
  margin-bottom: var(--space-4);
  text-wrap: balance;
}
.hero-copy h1 em {
  font-style: normal;
  color: var(--green-400);
}
.hero-copy .lead { color: rgba(255,255,255,0.78); max-width: 54ch; margin-bottom: var(--space-5); }

.hero-actions { display: flex; flex-wrap: wrap; gap: var(--space-3); margin-bottom: var(--space-6); }

.hero-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-3);
  max-width: 780px;
}
.hero-stat {
  padding: var(--space-3) var(--space-3);
  border-radius: var(--radius-md);
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  box-shadow: var(--glass-shadow);
}
@supports (backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px)) {
  .hero-stat {
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
  }
}
.hero-stat strong {
  display: block;
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 1.2rem + 1vw, 2.1rem);
  color: var(--white);
}
.hero-stat span { font-size: 0.82rem; color: rgba(255,255,255,0.68); }

/* ---- Ticker de confianza (marquee) ---- */
.trust-ticker {
  background: var(--navy-800);
  color: var(--white);
  overflow: hidden;
  white-space: nowrap;
  padding-block: var(--space-2);
}
.trust-ticker__track {
  display: inline-flex;
  animation: marquee 28s linear infinite;
}
.trust-ticker:hover .trust-ticker__track { animation-play-state: paused; }
.trust-ticker__item {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1rem;
  padding-inline: var(--space-5);
}
.trust-ticker__item::after { content: "✦"; margin-left: var(--space-5); opacity: 0.5; }
@keyframes marquee {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

/* ---- Cómo funciona: zigzag ---- */
.process-list { display: flex; flex-direction: column; gap: var(--space-6); }
.process-item {
  display: grid;
  gap: var(--space-4);
  align-items: center;
}
.process-item__number {
  font-family: var(--font-display);
  font-size: clamp(4rem, 3rem + 4vw, 7rem);
  font-weight: 800;
  line-height: 1;
  color: transparent;
  -webkit-text-stroke: 2px var(--navy-700);
  opacity: 0.9;
}
.process-item__body h3 { margin-bottom: var(--space-2); }
.process-item__body p { color: var(--gray-700); font-size: 1.02rem; max-width: 46ch; }

@media (min-width: 720px) {
  .process-list { gap: var(--space-7); }
  .process-item { grid-template-columns: 160px 1fr; }
  .process-item:nth-child(even) { direction: rtl; }
  .process-item:nth-child(even) > * { direction: ltr; }
}

/* ---- Beneficios: bento grid ---- */
.bento { display: grid; gap: var(--space-4); grid-template-columns: 1fr; }
.bento-card {
  position: relative;
  border-radius: var(--radius-lg);
  padding: var(--space-5);
  overflow: hidden;
  min-height: 220px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
}
.bento-card h3 { margin-bottom: 0.4rem; }
.bento-card p { font-size: 0.95rem; }
.bento-card--dark { background: var(--navy-900); color: var(--white); }
.bento-card--dark h3 { color: var(--white); }
.bento-card--dark p { color: rgba(255,255,255,0.72); }
.bento-card--green { background: var(--navy-700); color: var(--white); }
.bento-card--green h3 { color: var(--white); }
.bento-card--green p { color: rgba(255,255,255,0.76); }
.bento-card--cream { background: var(--cream); color: var(--navy-900); }
.bento-card--cream p { color: var(--gray-700); }
.bento-card--outline { background: var(--white); border: 1.5px solid var(--gray-200); color: var(--navy-900); }
.bento-card--outline p { color: var(--gray-700); }
.bento-card .icon-mark {
  position: absolute;
  top: var(--space-4);
  right: var(--space-4);
  width: 46px; height: 46px;
  opacity: 0.9;
}

@media (min-width: 720px) {
  .bento { grid-template-columns: repeat(2, 1fr); }
  .bento-card--lg { grid-column: span 2; min-height: 260px; }
}
@media (min-width: 1080px) {
  .bento { grid-template-columns: repeat(4, 1fr); }
  .bento-card--lg { grid-column: span 2; }
}

/* ---- Requisitos: panel oscuro con checklist grande ---- */
.req-section { background: var(--navy-900); color: var(--white); }
.req-panel { display: grid; gap: var(--space-6); align-items: center; }
.req-media {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  aspect-ratio: 1/1;
}
.req-media img { width: 100%; height: 100%; object-fit: cover; }
.req-media::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(180deg, transparent 40%, rgba(7,29,40,0.55) 100%);
}

/* ---- Insignia flotante en liquid glass sobre imágenes ---- */
.media-badge {
  position: absolute;
  left: var(--space-3);
  bottom: var(--space-3);
  right: var(--space-3);
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-3) var(--space-4);
  border-radius: var(--radius-md);
  background: var(--glass-bg-strong);
  border: 1px solid rgba(255,255,255,0.6);
  box-shadow: var(--glass-shadow);
  z-index: 2;
}
@supports (backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px)) {
  .media-badge {
    background: rgba(255,255,255,0.6);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
  }
}
.media-badge strong { display: block; font-family: var(--font-display); font-size: 1.3rem; color: var(--navy-900); line-height: 1; }
.media-badge span { display: block; font-size: 0.78rem; color: var(--gray-700); margin-top: 2px; }
.req-list { display: grid; gap: var(--space-3); margin-top: var(--space-5); }
.req-list li { display: flex; gap: var(--space-3); align-items: flex-start; padding-block: var(--space-2); border-bottom: 1px solid rgba(255,255,255,0.12); }
.req-list .check {
  flex-shrink: 0;
  width: 30px; height: 30px;
  border-radius: 50%;
  background: rgba(255,255,255,0.14);
  color: var(--green-300);
  display: flex; align-items: center; justify-content: center;
  font-weight: 800;
}
.req-list p { font-size: 1rem; color: rgba(255,255,255,0.85); margin: 0; }

/* Variante para usar req-list sobre fondo claro (no dentro de req-section oscuro) */
.req-list--onlight li { border-bottom-color: var(--gray-200); }
.req-list--onlight p { color: var(--gray-700); }

@media (min-width: 980px) {
  .req-panel { grid-template-columns: 0.85fr 1.15fr; }
}

/* ---- Nosotros: pull-quote grande ---- */
.about-section { position: relative; }
.about-panel { display: grid; gap: var(--space-6); align-items: start; }
.about-quote {
  font-family: var(--font-display);
  font-size: clamp(1.6rem, 1.3rem + 1.5vw, 2.6rem);
  font-weight: 700;
  color: var(--navy-900);
  line-height: 1.15;
  margin-bottom: var(--space-4);
}
/* Sin sticky: la imagen es MÁS ALTA que su columna de texto, así que al hacer
   scroll el sticky la desprendía y la deslizaba fuera de la sección, montándola
   sobre la banda siguiente. */
.about-media { position: relative; }
.about-media img { border-radius: var(--radius-lg); aspect-ratio: 3/4; object-fit: cover; box-shadow: var(--shadow-md); }
.about-media .media-badge { position: absolute; }
.about-traits { display: grid; gap: var(--space-2); margin-top: var(--space-5); }
.trait {
  display: flex;
  gap: var(--space-2);
  align-items: center;
  font-weight: 700;
  color: var(--navy-900);
}
.trait::before { content: "→"; color: var(--navy-700); }

@media (min-width: 980px) {
  .about-panel { grid-template-columns: 1fr 0.8fr; }
}

/* ---- Acordeón FAQ ---- */
.accordion { display: grid; gap: var(--space-2); }
.accordion-item { border-bottom: 1.5px solid var(--gray-200); }
.accordion-trigger {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
  padding-block: var(--space-4);
  text-align: left;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.15rem;
  color: var(--navy-900);
}
.accordion-trigger .plus {
  flex-shrink: 0;
  width: 32px; height: 32px;
  border-radius: 50%;
  background: var(--cream);
  display: flex; align-items: center; justify-content: center;
  position: relative;
  transition: transform 0.25s ease, background 0.25s ease;
}
.accordion-trigger .plus::before, .accordion-trigger .plus::after {
  content: ""; position: absolute; background: var(--navy-900); border-radius: 2px;
}
.accordion-trigger .plus::before { width: 14px; height: 2px; }
.accordion-trigger .plus::after { width: 2px; height: 14px; }
.accordion-trigger[aria-expanded="true"] .plus { transform: rotate(45deg); background: var(--green-300); }

.accordion-panel { display: grid; grid-template-rows: 0fr; transition: grid-template-rows 0.35s var(--ease); }
.accordion-panel > div { overflow: hidden; }
.accordion-item.is-open .accordion-panel { grid-template-rows: 1fr; }
.accordion-panel p { padding-bottom: var(--space-4); padding-right: var(--space-6); color: var(--gray-700); font-size: 1rem; }

/* ---- Blog cards ---- */
.blog-scroll { display: flex; gap: var(--space-4); overflow-x: auto; padding-bottom: var(--space-3); scroll-snap-type: x mandatory; }
.blog-scroll::-webkit-scrollbar { height: 6px; }
.blog-scroll::-webkit-scrollbar-thumb { background: var(--gray-200); border-radius: 999px; }

.blog-card {
  display: flex;
  flex-direction: column;
  border-radius: var(--radius-md);
  overflow: hidden;
  background: var(--white);
  border: 1.5px solid var(--gray-200);
  height: 100%;
  transition: box-shadow 0.25s ease, transform 0.25s ease, opacity 0.2s ease;
  flex: 0 0 300px;
  scroll-snap-align: start;
}
/* Filtro de categorías (interactions.js): fade en vez de display:none instantáneo */
.blog-card.is-filtered-out { opacity: 0; transform: scale(0.96); pointer-events: none; }
.grid-cards .blog-card { flex: none; }
.blog-card:hover { box-shadow: var(--shadow-md); transform: translateY(-4px); }
.blog-card__media { aspect-ratio: 4/3; overflow: hidden; }
.blog-card__media img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.4s ease; }
.blog-card:hover .blog-card__media img { transform: scale(1.05); }
.blog-card__body { padding: var(--space-4); display: flex; flex-direction: column; gap: 0.5rem; flex: 1; }
.blog-card__category { font-size: 0.72rem; font-weight: 800; text-transform: uppercase; letter-spacing: 0.05em; color: var(--navy-700); }
.blog-card__body h3 { font-size: 1.08rem; font-weight: 700; }
.blog-card__body p { font-size: 0.9rem; color: var(--gray-700); flex: 1; }
.blog-card__meta { font-size: 0.78rem; color: var(--gray-500); }

.grid-cards { display: grid; gap: var(--space-4); grid-template-columns: 1fr; }
@media (min-width: 720px) { .grid-cards { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1080px) { .grid-cards { grid-template-columns: repeat(3, 1fr); } }

/* ---- CTA final / formulario: sangre completa verde ---- */
.cta-final { background: var(--gradient-brand); color: var(--white); position: relative; overflow: hidden; }
.cta-panel { display: grid; gap: var(--space-6); position: relative; z-index: 1; }
.cta-copy .eyebrow { color: var(--white); }
.cta-copy h2 { color: var(--white); }
.cta-copy p { color: rgba(255,255,255,0.97); font-size: 1.05rem; }
.cta-copy .btn--whatsapp { margin-top: var(--space-4); }

.form-card {
  background: rgba(255,255,255,0.9);
  border: 1px solid rgba(255,255,255,0.6);
  border-radius: var(--radius-lg);
  padding: var(--space-5);
  color: var(--ink);
  box-shadow: var(--shadow-lg);
}
@supports (backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px)) {
  .form-card {
    background: rgba(255,255,255,0.72);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
  }
}
.form-row { display: grid; gap: var(--space-3); margin-bottom: var(--space-3); }
.field label { display: block; font-size: 0.85rem; font-weight: 700; margin-bottom: 0.4rem; color: var(--navy-900); }
.field input {
  width: 100%;
  padding: 0.85rem 1rem;
  border: 1.5px solid rgba(7,29,40,0.12);
  border-radius: var(--radius-sm);
  font-size: 0.95rem;
  transition: border-color 0.15s ease, background 0.15s ease;
  background: rgba(255,255,255,0.75);
}
.field input:focus { border-color: var(--green-600); background: var(--white); }
.field input[aria-invalid="true"] { border-color: var(--error); }
.field .field-error { display: none; color: var(--error); font-size: 0.78rem; margin-top: 0.3rem; }
.field.has-error .field-error { display: block; }
.field.has-error input { border-color: var(--error); }

.form-note { font-size: 0.78rem; color: var(--gray-500); margin-top: var(--space-3); }
.form-success {
  display: none; align-items: flex-start; gap: 0.75rem;
  background: rgba(34,167,104,0.1); border: 1px solid var(--green-500);
  border-radius: var(--radius-sm); padding: var(--space-3); margin-top: var(--space-3); font-size: 0.88rem;
}
.form-success.is-visible {
  display: flex;
  opacity: 1;
  transform: translateY(0);
  transition: opacity 0.35s var(--ease), transform 0.35s var(--ease);
}
/* Entrada desde display:none — evita el salto brusco al confirmar el envío */
@starting-style {
  .form-success.is-visible { opacity: 0; transform: translateY(8px); }
}

@media (min-width: 980px) {
  .cta-panel { grid-template-columns: 1fr 1fr; align-items: center; }
}

/* ---- Footer: oscuro, wordmark gigante ---- */
.site-footer { background: var(--navy-900); color: rgba(255,255,255,0.72); padding-top: var(--space-7); }
.footer-grid { display: grid; gap: var(--space-5); padding-bottom: var(--space-6); border-bottom: 1px solid rgba(255,255,255,0.12); }
.footer-brand img { width: 150px; height: auto; margin-bottom: var(--space-3); display: block; }
.footer-brand p { font-size: 0.92rem; max-width: 340px; color: rgba(255,255,255,0.65); }
.footer-social { display: flex; gap: 0.6rem; margin-top: var(--space-4); }
.footer-social a { width: 40px; height: 40px; border-radius: 50%; background: rgba(255,255,255,0.08); display: flex; align-items: center; justify-content: center; transition: background 0.15s ease; }
.footer-social a:hover { background: var(--navy-700); }
.footer-social img { width: 18px; height: 18px; filter: brightness(0) invert(1); }

.footer-col h4 { color: var(--white); font-family: var(--font-display); font-size: 0.95rem; margin-bottom: var(--space-3); }
.footer-col ul { display: grid; gap: 0.65rem; }
.footer-col a { font-size: 0.92rem; }
.footer-col a:hover { color: var(--green-300); }

.footer-wordmark {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(3rem, 2rem + 8vw, 9rem);
  line-height: 0.85;
  color: rgba(255,255,255,0.06);
  padding-block: var(--space-4);
  text-align: center;
  user-select: none;
}

.footer-bottom { display: flex; flex-direction: column; gap: var(--space-2); padding-block: var(--space-4); font-size: 0.8rem; }

@media (min-width: 720px) {
  .footer-grid { grid-template-columns: 1.3fr repeat(3, 1fr); }
  .footer-bottom { flex-direction: row; justify-content: space-between; }
}

/* ---- WhatsApp flotante ---- */
.whatsapp-float {
  position: fixed; right: 20px; bottom: 20px;
  height: 62px; border-radius: var(--radius-pill);
  background: var(--whatsapp-green);
  display: flex; align-items: center; gap: 0.7rem;
  padding-inline: 0.9rem;
  box-shadow: var(--shadow-lg); z-index: 800;
  transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease);
}
.whatsapp-float:hover { transform: scale(1.04); box-shadow: var(--shadow-lg), 0 0 0 6px rgba(255,255,255,0.15); }
.whatsapp-float__icon {
  flex-shrink: 0; width: 44px; height: 44px; border-radius: 50%;
  background: rgba(255,255,255,0.16);
  display: flex; align-items: center; justify-content: center;
}
.whatsapp-float img { width: 26px; height: 26px; }
.whatsapp-float__label {
  font-family: var(--font-display); font-weight: 700; font-size: 0.88rem;
  color: var(--white); white-space: nowrap; line-height: 1.15; max-width: 180px;
  white-space: normal; text-align: left;
}

@media (max-width: 640px) {
  .whatsapp-float { width: 58px; height: 58px; padding: 0; justify-content: center; }
  .whatsapp-float__icon { width: 100%; height: 100%; background: transparent; }
  .whatsapp-float__label { display: none; }
}

/* ---- Page hero (subpáginas) ---- */
.page-hero { background: var(--navy-900); color: var(--white); padding-block: calc(var(--header-height) + var(--space-6)) var(--space-6); position: relative; overflow: hidden; }
.page-hero .eyebrow { color: var(--green-300); }
.page-hero h1 { color: var(--white); margin-bottom: var(--space-3); font-size: var(--fs-h1); }
.page-hero p { color: rgba(255,255,255,0.78); max-width: 640px; font-size: 1.05rem; }
.breadcrumb { font-size: 0.85rem; color: rgba(255,255,255,0.55); margin-bottom: var(--space-3); }
.breadcrumb a { color: rgba(255,255,255,0.85); font-weight: 700; }

/* ---- Filtro de blog ---- */
.filter-bar { display: flex; flex-wrap: wrap; gap: 0.6rem; margin-bottom: var(--space-6); }
.filter-chip {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 44px;
  padding: 0.55rem 1.2rem; border-radius: var(--radius-pill); border: 1.5px solid var(--gray-200);
  font-size: 0.85rem; font-weight: 700; color: var(--navy-900);
  transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}
.filter-chip.is-active, .filter-chip:hover { background: var(--navy-900); border-color: var(--navy-900); color: var(--white); }

/* ---- Comparativa (Beneficios / Requisitos) ---- */
.compare-grid { display: grid; gap: var(--space-4); }
.compare-col { border-radius: var(--radius-lg); padding: var(--space-5); }
.compare-col--against { background: var(--gray-100); }
.compare-col--for { background: var(--navy-900); color: var(--white); }
.compare-col h3 { margin-bottom: var(--space-4); }
.compare-col--for h3 { color: var(--white); }
.compare-col ul { display: grid; gap: var(--space-3); }
.compare-col li { display: flex; gap: var(--space-3); align-items: flex-start; font-size: 0.98rem; }
.compare-col--against li { color: var(--gray-700); }
.compare-col--for li { color: rgba(255,255,255,0.85); }
.compare-col .mark { flex-shrink: 0; width: 26px; height: 26px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: 0.85rem; }
.compare-col--against .mark { background: var(--gray-300); color: var(--gray-700); }
.compare-col--for .mark { background: rgba(255,255,255,0.16); color: var(--green-300); }

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

/* ---- Casos de uso (tarjetas simples) ---- */
.usecase-card {
  background: var(--white);
  border: 1.5px solid var(--gray-200);
  border-radius: var(--radius-md);
  padding: var(--space-4);
  height: 100%;
}
.usecase-card .icon-mark { width: 42px; height: 42px; border-radius: var(--radius-sm); background: var(--cream); display: flex; align-items: center; justify-content: center; margin-bottom: var(--space-3); font-size: 1.3rem; }
.usecase-card h3 { font-size: 1.05rem; margin-bottom: 0.4rem; }
.usecase-card p { font-size: 0.92rem; color: var(--gray-700); }

/* ---- Pilares (grid de valores, reutiliza look de bento) ---- */
.pillars-grid { display: grid; gap: var(--space-4); grid-template-columns: 1fr; }
@media (min-width: 720px) { .pillars-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1080px) { .pillars-grid { grid-template-columns: repeat(4, 1fr); } }

/* ---- Insignia de duración estimada (Requisitos paso a paso) ---- */
.step-time {
  display: inline-flex; align-items: center; gap: 0.4rem;
  font-size: 0.78rem; font-weight: 800; text-transform: uppercase; letter-spacing: 0.04em;
  color: var(--navy-700); margin-bottom: 0.5rem;
}
.step-time::before { content: "⏱"; }

/* ---- Nota de dato propuesto (transparencia con el cliente, no visible al usuario final) ---- */
.data-note { font-size: 0.78rem; color: var(--gray-600); margin-top: var(--space-2); }

/* ---- Artículo de blog ---- */
.article-body { max-width: 720px; margin-inline: auto; }
.article-body h2 { margin-top: var(--space-6); margin-bottom: var(--space-3); font-size: var(--fs-h3); }
.article-body p { margin-bottom: var(--space-3); color: var(--gray-700); font-size: 1.05rem; }
.article-meta { display: flex; gap: var(--space-3); align-items: center; margin-bottom: var(--space-4); font-size: 0.85rem; color: rgba(255,255,255,0.7); }
.article-cta { margin-top: var(--space-7); background: var(--cream); border-radius: var(--radius-lg); padding: var(--space-5); text-align: center; }
.article-cta h3 { margin-bottom: var(--space-2); }
.article-cta p { color: var(--gray-700); margin-bottom: var(--space-4); }

/* ---- CTA final: acciones y checklist (v0.5.1) ---- */
.cta-actions { display: flex; flex-wrap: wrap; gap: var(--space-3); margin-top: var(--space-5); }
.cta-checklist { display: grid; gap: var(--space-3); }
.cta-checklist li {
  display: grid;
  gap: 0.15rem;
  padding: var(--space-3) var(--space-4);
  border-radius: var(--radius-md);
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.16);
}
.cta-checklist strong { font-family: var(--font-display); font-size: 1rem; color: var(--white); }
.cta-checklist span { font-size: 0.88rem; color: rgba(255,255,255,0.72); }

/* ---- Variante compacta del page-hero (página de solicitud) ---- */
.page-hero--tight p { max-width: 62ch; }

/* ==========================================================================
   QA v0.5.1 — correcciones de contraste, jerarquía y paleta 95/5
   ========================================================================== */

/* 1. El botón principal deja de ser verde: azul sobre claro, blanco sobre oscuro.
      El verde queda solo en acentos pequeños y el verde de WhatsApp es de canal. */
.btn--primary { background: var(--navy-800); color: var(--white); box-shadow: var(--shadow-md); }
.btn--primary:hover { box-shadow: var(--shadow-lg); }
.hero .btn--primary,
.section--dark .btn--primary,
.section--green .btn--primary,
.cta-final .btn--primary,
.req-section .btn--primary,
.page-hero .btn--primary,
.site-header .btn--primary,
.sol-aside-card .btn--primary { background: var(--white); color: var(--navy-900); }

/* 2. Secciones oscuras sin clase .section--dark: títulos y eyebrow ilegibles.
      .req-section pintaba h2 en navy sobre navy. */
.req-section h2, .req-section h3, .req-section h4,
.custodia h2, .custodia h3,
.page-hero h1, .page-hero h2 { color: var(--white); }
.req-section .eyebrow,
.cta-final .eyebrow,
.page-hero .eyebrow { color: var(--green-300); }
.req-section p { color: rgba(255,255,255,0.82); }

/* 3. Párrafos consecutivos y párrafo tras titular venían pegados (reset margin:0). */
main h2 + p,
main h3 + p,
main p + p,
main .lead + p { margin-top: var(--space-3); }
main .section-head p + p { margin-top: var(--space-2); }

/* 4. El subrayado del nav y el acordeón vuelven a acento discreto */
.nav-desktop a::after { background: var(--green-400); }

/* 5. La cifra del rango se partía en dos líneas y desalineaba las tres tarjetas */
.hero-stats { align-items: stretch; }
.hero-stat { display: flex; flex-direction: column; justify-content: center; }
.hero-stat strong { font-size: clamp(1.25rem, 0.95rem + 1vw, 1.9rem); white-space: nowrap; }
@media (max-width: 480px) { .hero-stat strong { white-space: normal; } }

/* ==========================================================================
   QA v0.5.2 — diagramación: proceso, pilares y proporciones de imagen
   ========================================================================== */

/* 6. "Su préstamo en 4 pasos" quedaba con enormes vacíos: el zigzag en rtl
      empujaba el número al extremo opuesto y dejaba media fila en blanco.
      Pasa a una grilla de 4 columnas con el número sobre el título. */
.process-list {
  display: grid;
  gap: var(--space-5);
  grid-template-columns: 1fr;
}
.process-item {
  display: block;
  padding-top: var(--space-4);
  border-top: 1.5px solid var(--gray-200);
}
.process-item__number {
  display: block;
  font-size: clamp(2.6rem, 2rem + 1.6vw, 3.6rem);
  margin-bottom: var(--space-2);
  -webkit-text-stroke: 1.5px var(--navy-700);
}
.process-item__body h3 { margin-bottom: var(--space-2); }
.process-item__body p { max-width: 40ch; font-size: 0.98rem; }
@media (min-width: 720px) {
  .process-list { grid-template-columns: repeat(2, 1fr); gap: var(--space-5) var(--space-5); }
  .process-item { grid-template-columns: none; }
  .process-item:nth-child(even) { direction: ltr; }
}
@media (min-width: 1080px) {
  .process-list { grid-template-columns: repeat(4, 1fr); }
}

/* 7. Pilares: el tercero era crema sobre fondo crema (no se leía como tarjeta)
      y la cascada de entrada los dejaba desalineados a media animación. */
.pillars-grid { align-items: stretch; }
.pillars-grid .bento-card { min-height: 0; justify-content: flex-start; }
.pillars-grid .bento-card--cream,
.pillars-grid .bento-card--outline { border: 1.5px solid var(--gray-200); }
.pillars-grid.stagger-children > *:nth-child(1) { transition-delay: 0ms; }
.pillars-grid.stagger-children > *:nth-child(2) { transition-delay: 40ms; }
.pillars-grid.stagger-children > *:nth-child(3) { transition-delay: 80ms; }
.pillars-grid.stagger-children > *:nth-child(4) { transition-delay: 120ms; }

/* 8. Proporciones: el retrato 3:4 competía con el texto y la insignia se salía
      del recorte; el panel de requisitos daba muy poco ancho a la foto. */
.about-media img { aspect-ratio: 4/5; }
.about-media { position: relative; }
.about-media .media-badge { bottom: var(--space-4); }
@media (min-width: 980px) {
  .req-panel { grid-template-columns: 1fr 1.05fr; }
  .about-panel { grid-template-columns: 1fr 0.85fr; }
}

/* 9. El foco verde chillón sobre azul: mismo nivel de visibilidad, en marca. */
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible,
.sol-choice input:focus-visible + span,
.sol-term:has(input:focus-visible) { outline: 3px solid var(--navy-700); outline-offset: 2px; }
.section--dark a:focus-visible,
.cta-final a:focus-visible,
.hero a:focus-visible,
.req-section a:focus-visible { outline-color: var(--white); }

/* 10. El retrato seguía más alto que su columna de texto y la insignia caía
       fuera de la sección: se fija la altura para que converse con el bloque. */
@media (min-width: 980px) {
  /* La foto acompaña al bloque de texto completo: la columna se estira a la
     altura de la fila y la imagen la llena. Como la imagen llena el contenedor,
     la insignia (absoluta) vuelve a quedar sobre la foto y no flotando debajo. */
  .about-panel { grid-template-columns: 1fr 0.78fr; align-items: stretch; }
  .about-media { height: 100%; min-height: 420px; }
  .about-media img { aspect-ratio: auto; height: 100%; width: 100%; object-fit: cover; }
}

/* 11. Los titulares de los pasos rompen a dos líneas y descuadran los párrafos */
@media (min-width: 1080px) {
  .process-item__body h3 { min-height: 2.3em; font-size: 1.25rem; }
}

/* 12. Con 4 tarjetas, la grilla de 3 columnas dejaba una sola en la última fila */
@media (min-width: 1080px) {
  .grid-cards { grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); }
}

/* 13. El párrafo del page-hero venía pegado al h1 */
main h1 + p { margin-top: var(--space-3); }

/* ==========================================================================
   QA v0.5.3 — auditoría de espaciado, contraste y objetivos táctiles
   ========================================================================== */

/* 14. Ritmo vertical: 5.5rem de padding por sección es correcto en escritorio
       pero asfixia la lectura en móvil, donde el alto de pantalla es el recurso
       escaso. Escala el ritmo con el viewport. */
@media (max-width: 719px) {
  .section { padding-block: var(--space-6); }
  .section--tight { padding-block: var(--space-5); }
  .section-head { margin-bottom: var(--space-5); }
  .page-hero { padding-block: calc(var(--header-height) + var(--space-4)) var(--space-5); }
}

/* 15. Objetivos táctiles: los enlaces del footer y del menú móvil medían 17 px
       de alto. Mínimo recomendado 44 px (WCAG 2.5.8 / iOS HIG). */
@media (max-width: 979px) {
  .footer-col a,
  .nav-mobile ul a {
    display: block;
    padding-block: 0.7rem;
    min-height: 44px;
  }
  .footer-col ul { gap: 0; }
  .footer-social a { width: 44px; height: 44px; }
  .breadcrumb a { display: inline-block; padding-block: 0.35rem; }
}

/* 16. Medida de lectura: las respuestas del acordeón y los textos de página
       llegaban a 103 caracteres por línea (el rango cómodo es 60–75). */
.accordion-panel p,
.article-body p,
.page-hero p { max-width: 68ch; }
.accordion { max-width: 860px; }

/* 17. Contraste por debajo de 4.5:1 en textos pequeños */
.blog-card__meta { color: var(--gray-700); }
.data-note {
  font-size: 0.82rem;
  color: var(--gray-700);
  max-width: 78ch;
  line-height: 1.55;
}

/* 18. El "+" del acordeón se volvía verde al abrir: sobre blanco es el peor
       contraste de la paleta, y rompe el 95/5. */
.accordion-trigger[aria-expanded="true"] .plus { background: var(--navy-800); }
.accordion-trigger[aria-expanded="true"] .plus::before,
.accordion-trigger[aria-expanded="true"] .plus::after { background: var(--white); }
.accordion-trigger { gap: var(--space-4); }

/* 19. Los enlaces del footer eran texto suelto de 17 px de alto: se amplía el
       área de clic también en escritorio y se gana ritmo en la columna. */
.footer-col a { display: inline-block; padding-block: 0.3rem; }

/* ==========================================================================
   Artículos del blog — tipografía de lectura larga
   ========================================================================== */
.article-hero {
  width: 100%;
  /* height:auto es obligatorio: los atributos width/height del <img> entran como
     hints de presentación y fijan la altura, anulando el aspect-ratio. */
  height: auto;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  border-radius: var(--radius-lg);
  margin-bottom: var(--space-5);
}
.article-body > p { font-size: 1.05rem; line-height: 1.75; color: var(--gray-700); }
.article-body h2 {
  font-size: clamp(1.35rem, 1.15rem + 0.7vw, 1.7rem);
  margin-top: var(--space-6);
  margin-bottom: var(--space-3);
  color: var(--navy-900);
  text-wrap: balance;
}
.article-body h2 + p { margin-top: 0; }
.article-body strong { color: var(--navy-900); font-weight: 700; }

.article-list {
  display: grid;
  gap: var(--space-3);
  margin: var(--space-4) 0;
  max-width: 68ch;
}
.article-list li {
  position: relative;
  padding-left: var(--space-5);
  font-size: 1.02rem;
  line-height: 1.65;
  color: var(--gray-700);
}
.article-list li::before {
  content: "";
  position: absolute;
  left: 0; top: 0.65em;
  width: 10px; height: 2px;
  border-radius: 2px;
  background: var(--navy-700);
}

.article-quote {
  margin: var(--space-5) 0;
  padding: var(--space-4) var(--space-5);
  border-left: 3px solid var(--navy-700);
  background: var(--cream);
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
  max-width: 68ch;
}
.article-quote p {
  font-family: var(--font-display);
  font-size: 1.12rem;
  font-weight: 600;
  line-height: 1.45;
  color: var(--navy-900);
  margin: 0;
}

.article-cta__actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
  justify-content: center;
  margin-top: var(--space-4);
}
