/* =========================================================
   Crediamigos · Landing Styles
   Paleta extraída del logo:
     - Azul oscuro (primary)   #1a4970
     - Azul claro  (accent)    #7cc4e5
     - Texto oscuro            #14253a
     - Fondo crema             #f6f9fc
   ========================================================= */

:root {
  --c-primary:        #1a4970;
  --c-primary-dark:   #133655;
  --c-primary-light:  #235f8e;
  --c-accent:         #7cc4e5;
  --c-accent-light:   #b4dff0;
  --c-accent-dark:    #4ea7d1;
  --c-text:           #14253a;
  --c-text-muted:     #5a6b80;
  --c-bg:             #ffffff;
  --c-bg-alt:         #f6f9fc;
  --c-border:         #e6edf5;
  --c-wa:             #25d366;
  --c-wa-dark:        #1da851;

  --radius-sm: 10px;
  --radius:    16px;
  --radius-lg: 24px;

  --shadow-sm: 0 2px 8px rgba(20,37,58,.06);
  --shadow:    0 8px 30px rgba(20,37,58,.08);
  --shadow-lg: 0 20px 60px rgba(20,37,58,.14);

  --font: 'Plus Jakarta Sans', system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}

* { box-sizing: border-box; }

html, body {
  margin: 0; padding: 0;
  background: var(--c-bg);
  color: var(--c-text);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  scroll-behavior: smooth;
}

img { max-width: 100%; height: auto; display: block; }

a { color: var(--c-primary); text-decoration: none; }
a:hover { color: var(--c-primary-dark); }

.container {
  width: 100%;
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 24px;
}
.container-narrow { max-width: 820px; }
.center { text-align: center; }

/* ===================== TOPBAR ===================== */
.topbar {
  position: sticky; top: 0; z-index: 100;
  background: rgba(255,255,255,.92);
  backdrop-filter: saturate(160%) blur(10px);
  -webkit-backdrop-filter: saturate(160%) blur(10px);
  border-bottom: 1px solid transparent;
  transition: border-color .2s ease, box-shadow .2s ease;
}
.topbar.scrolled {
  border-color: var(--c-border);
  box-shadow: var(--shadow-sm);
}
.topbar-inner {
  display: flex; align-items: center; justify-content: space-between;
  height: 72px;
}
.brand { display: flex; align-items: center; gap: 8px; }
.brand-logo { height: 44px; width: auto; }
.nav-desktop { display: flex; gap: 28px; }
.nav-desktop a {
  color: var(--c-text);
  font-weight: 500;
  font-size: .95rem;
  transition: color .15s ease;
}
.nav-desktop a:hover { color: var(--c-primary); }

@media (max-width: 800px) {
  .nav-desktop { display: none; }
  .brand-logo { height: 38px; }
}

/* ===================== BUTTONS ===================== */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  gap: 8px;
  padding: 12px 20px;
  font-family: inherit;
  font-weight: 700;
  font-size: .95rem;
  border-radius: 999px;
  border: 2px solid transparent;
  cursor: pointer;
  transition: transform .15s ease, box-shadow .2s ease, background .2s ease, color .2s ease;
  white-space: nowrap;
}
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(0); }
.btn-sm  { padding: 9px 16px; font-size: .85rem; }
.btn-lg  { padding: 16px 28px; font-size: 1rem; }

.btn-primary {
  background: var(--c-primary);
  color: #fff;
  box-shadow: 0 6px 20px rgba(26,73,112,.3);
}
.btn-primary:hover { background: var(--c-primary-dark); color: #fff; box-shadow: 0 10px 28px rgba(26,73,112,.4); }

.btn-whatsapp {
  background: var(--c-wa);
  color: #fff;
  box-shadow: 0 6px 20px rgba(37,211,102,.35);
}
.btn-whatsapp:hover { background: var(--c-wa-dark); color: #fff; box-shadow: 0 10px 28px rgba(37,211,102,.45); }

.btn-whatsapp-outline {
  background: transparent;
  color: #fff;
  border-color: rgba(255,255,255,.6);
}
.btn-whatsapp-outline:hover { background: #fff; color: var(--c-primary); border-color: #fff; }

.btn-white {
  background: #fff;
  color: var(--c-primary);
  box-shadow: 0 10px 30px rgba(0,0,0,.18);
}
.btn-white:hover { background: var(--c-accent-light); color: var(--c-primary-dark); }

/* ===================== HERO ===================== */
.hero {
  position: relative;
  padding: 70px 0 90px;
  background:
    radial-gradient(circle at 85% 10%, rgba(124,196,229,.22) 0%, transparent 45%),
    radial-gradient(circle at 0% 90%,  rgba(26,73,112,.08) 0%, transparent 45%),
    var(--c-bg);
  overflow: hidden;
}
.hero::before {
  content: ""; position: absolute; inset: 0;
  background-image:
    radial-gradient(circle, rgba(26,73,112,.05) 1px, transparent 1px);
  background-size: 24px 24px;
  pointer-events: none;
  mask-image: linear-gradient(180deg, rgba(0,0,0,.5), transparent 70%);
}
.hero-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 60px;
  align-items: center;
  position: relative; z-index: 1;
}
.eyebrow {
  display: inline-block;
  padding: 6px 14px;
  background: rgba(124,196,229,.2);
  color: var(--c-primary);
  border-radius: 999px;
  font-weight: 600;
  font-size: .82rem;
  letter-spacing: .02em;
  margin-bottom: 18px;
}
.hero-copy h1 {
  font-size: clamp(2rem, 4.2vw, 3.4rem);
  line-height: 1.1;
  margin: 0 0 18px;
  font-weight: 800;
  letter-spacing: -.02em;
}
.accent {
  background: linear-gradient(110deg, var(--c-primary) 30%, var(--c-accent-dark) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.lead {
  font-size: 1.1rem;
  color: var(--c-text-muted);
  margin: 0 0 28px;
  max-width: 580px;
}
.hero-ctas {
  display: flex; gap: 12px; flex-wrap: wrap;
  margin-bottom: 36px;
}
.trust-row {
  display: flex; gap: 32px;
  flex-wrap: wrap;
  padding-top: 24px;
  border-top: 1px solid var(--c-border);
}
.trust-item { display: flex; flex-direction: column; }
.trust-item strong { color: var(--c-primary); font-size: 1.1rem; font-weight: 700; }
.trust-item span { color: var(--c-text-muted); font-size: .85rem; }

@media (max-width: 900px) {
  .hero { padding: 50px 0 70px; }
  .hero-grid { grid-template-columns: 1fr; gap: 40px; }
  .trust-row { gap: 20px; }
}

/* HERO VISUAL: mockup tarjeta */
.hero-visual {
  position: relative;
  min-height: 380px;
  display: flex; align-items: center; justify-content: center;
}
.hero-card {
  width: 100%;
  max-width: 380px;
  background: #fff;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
  transform: rotate(-2deg);
  animation: floatY 5s ease-in-out infinite;
}
.hero-card-head {
  display: flex; align-items: center; gap: 8px;
  padding: 16px 20px;
  background: linear-gradient(135deg, var(--c-primary), var(--c-primary-light));
  color: #fff;
}
.hero-card-head .dot { width: 9px; height: 9px; border-radius: 50%; }
.dot-r { background: #ff5f56; }
.dot-y { background: #ffbd2e; }
.dot-g { background: #27c93f; }
.hero-card-title { margin-left: 8px; font-size: .85rem; opacity: .9; font-weight: 500; }
.hero-card-body { padding: 26px 24px; }
.line { height: 12px; border-radius: 6px; background: var(--c-bg-alt); margin-bottom: 14px; }
.line-1 { width: 75%; }
.line-2 { width: 55%; }
.line-3 { width: 65%; }
.line-4 { width: 45%; }
.hero-pill {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 16px;
  margin: 6px 0 18px;
  background: linear-gradient(120deg, rgba(124,196,229,.22), rgba(124,196,229,.08));
  border-radius: var(--radius-sm);
  font-size: .9rem;
}
.hero-pill span { color: var(--c-text-muted); }
.hero-pill .ok { color: #16a34a; font-weight: 700; }

.floating {
  position: absolute;
  background: #fff;
  color: var(--c-primary);
  padding: 10px 16px;
  border-radius: 999px;
  box-shadow: var(--shadow);
  font-weight: 700;
  font-size: .9rem;
  animation: floatY 4s ease-in-out infinite;
}
.floating-1 { top: 10%; left: -5%; animation-delay: -1s; }
.floating-2 { top: 50%; right: -8%; animation-delay: -2.5s; }
.floating-3 { bottom: 8%; left: 5%; animation-delay: -3.5s; }

@keyframes floatY {
  0%,100% { transform: translateY(0) rotate(-2deg); }
  50%     { transform: translateY(-10px) rotate(-2deg); }
}
.floating, .floating-1, .floating-2, .floating-3 {
  animation-name: floatYpill;
}
@keyframes floatYpill {
  0%,100% { transform: translateY(0); }
  50%     { transform: translateY(-8px); }
}

@media (max-width: 600px) {
  .floating { display: none; }
  .hero-card { transform: none; max-width: 100%; }
}

/* ===================== SECTIONS COMUNES ===================== */
.section { padding: 88px 0; }
.section-alt { background: var(--c-bg-alt); }
.section-head {
  text-align: center;
  max-width: 720px;
  margin: 0 auto 56px;
}
.section-head h2 {
  font-size: clamp(1.7rem, 3vw, 2.4rem);
  margin: 8px 0 0;
  letter-spacing: -.01em;
  line-height: 1.15;
  font-weight: 800;
}
.section-head p { color: var(--c-text-muted); margin-top: 14px; font-size: 1.05rem; }

@media (max-width: 600px) {
  .section { padding: 60px 0; }
  .section-head { margin-bottom: 36px; }
}

/* ===================== BENEFICIOS CARDS ===================== */
.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 22px;
}
.card {
  background: var(--c-bg);
  border: 1px solid var(--c-border);
  border-radius: var(--radius);
  padding: 28px 24px;
  transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
}
.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow);
  border-color: var(--c-accent);
}
.card-icon {
  width: 56px; height: 56px;
  border-radius: 14px;
  display: flex; align-items: center; justify-content: center;
  background: linear-gradient(135deg, var(--c-primary), var(--c-accent-dark));
  color: #fff;
  margin-bottom: 18px;
}
.card-icon svg { width: 28px; height: 28px; }
.card h3 { margin: 0 0 8px; font-size: 1.15rem; font-weight: 700; }
.card p  { margin: 0; color: var(--c-text-muted); font-size: .95rem; }

/* ===================== COMO FUNCIONA ===================== */
.steps {
  list-style: none; padding: 0; margin: 0 0 48px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 24px;
  counter-reset: step;
}
.step {
  position: relative;
  background: #fff;
  border-radius: var(--radius);
  padding: 32px 26px 28px;
  box-shadow: var(--shadow-sm);
  transition: transform .2s ease, box-shadow .2s ease;
}
.step:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.step-num {
  position: absolute; top: -18px; left: 26px;
  width: 44px; height: 44px; border-radius: 50%;
  background: linear-gradient(135deg, var(--c-primary), var(--c-accent-dark));
  color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-weight: 800;
  font-size: 1.1rem;
  box-shadow: 0 8px 20px rgba(26,73,112,.3);
}
.step h3 { margin: 12px 0 6px; font-size: 1.15rem; font-weight: 700; }
.step p  { margin: 0; color: var(--c-text-muted); font-size: .95rem; }

/* ===================== CONFIANZA ===================== */
.trust-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 48px;
  align-items: start;
}
.trust-text h2 { margin: 8px 0 18px; font-size: clamp(1.6rem, 2.8vw, 2.2rem); font-weight: 800; }
.trust-text p { color: var(--c-text-muted); margin-bottom: 22px; }
.bullets {
  list-style: none; padding: 0; margin: 0 0 28px;
}
.bullets li {
  position: relative;
  padding: 8px 0 8px 32px;
  color: var(--c-text);
  font-size: 1rem;
}
.bullets li::before {
  content: "";
  position: absolute; left: 0; top: 12px;
  width: 18px; height: 18px;
  background: var(--c-accent);
  border-radius: 50%;
  box-shadow: inset 0 0 0 4px #fff, 0 0 0 2px var(--c-accent);
}
.ceo-card {
  display: flex; align-items: center; gap: 16px;
  padding: 18px;
  background: #fff;
  border: 1px solid var(--c-border);
  border-radius: var(--radius);
  width: fit-content;
  max-width: 100%;
}
.ceo-avatar {
  width: 52px; height: 52px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--c-primary), var(--c-accent-dark));
  color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-weight: 800;
  font-size: 1.05rem;
}
.ceo-card strong { display: block; font-size: 1rem; }
.ceo-card span   { display: block; color: var(--c-text-muted); font-size: .88rem; }

.trust-aside {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
.metric {
  background: #fff;
  border: 1px solid var(--c-border);
  border-radius: var(--radius);
  padding: 22px 18px;
  text-align: center;
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.metric:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow);
  border-color: var(--c-accent);
}
.metric strong {
  display: block; font-size: 1.05rem;
  color: var(--c-primary);
  font-weight: 800;
  margin-bottom: 4px;
  word-break: break-word;
}
.metric span { color: var(--c-text-muted); font-size: .85rem; }

@media (max-width: 900px) {
  .trust-grid { grid-template-columns: 1fr; gap: 32px; }
}

/* ===================== FAQ ===================== */
.faqs { display: flex; flex-direction: column; gap: 12px; }
.faqs details {
  background: #fff;
  border: 1px solid var(--c-border);
  border-radius: var(--radius);
  padding: 18px 22px;
  transition: border-color .2s ease, box-shadow .2s ease;
}
.faqs details[open] {
  border-color: var(--c-accent);
  box-shadow: var(--shadow-sm);
}
.faqs summary {
  list-style: none;
  cursor: pointer;
  font-weight: 700;
  color: var(--c-text);
  position: relative;
  padding-right: 32px;
}
.faqs summary::-webkit-details-marker { display: none; }
.faqs summary::after {
  content: "+";
  position: absolute; right: 0; top: -2px;
  font-size: 1.6rem;
  font-weight: 400;
  color: var(--c-primary);
  transition: transform .2s ease;
}
.faqs details[open] summary::after { content: "−"; }
.faqs details p { margin: 12px 0 0; color: var(--c-text-muted); font-size: .95rem; }

/* ===================== CTA FINAL ===================== */
.cta-final {
  background: linear-gradient(120deg, var(--c-primary) 0%, var(--c-primary-light) 50%, var(--c-accent-dark) 100%);
  color: #fff;
  padding: 70px 0;
  position: relative;
  overflow: hidden;
}
.cta-final::before {
  content: "";
  position: absolute; inset: 0;
  background-image: radial-gradient(circle, rgba(255,255,255,.08) 1px, transparent 1px);
  background-size: 22px 22px;
  pointer-events: none;
}
.cta-final-inner {
  position: relative; z-index: 1;
  display: flex; align-items: center; justify-content: space-between;
  gap: 32px;
  flex-wrap: wrap;
}
.cta-final h2 { font-size: clamp(1.5rem, 2.6vw, 2rem); margin: 0 0 8px; font-weight: 800; }
.cta-final p { margin: 0; opacity: .9; max-width: 540px; }
.cta-final-buttons { display: flex; gap: 12px; flex-wrap: wrap; }

@media (max-width: 720px) {
  .cta-final-inner { flex-direction: column; align-items: flex-start; }
}

/* ===================== FOOTER ===================== */
.footer {
  background: #0f1e2e;
  color: #c2d2e3;
  padding: 60px 0 24px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 32px;
  padding-bottom: 32px;
  border-bottom: 1px solid rgba(255,255,255,.08);
}
.footer-logo {
  height: 44px;
  filter: brightness(0) invert(1);
  margin-bottom: 14px;
}
.footer-text { color: #c2d2e3; opacity: .8; font-size: .9rem; line-height: 1.6; }
.footer h4 { color: #fff; margin: 0 0 14px; font-size: .95rem; font-weight: 700; }
.footer a {
  display: block;
  color: #c2d2e3;
  opacity: .8;
  font-size: .9rem;
  padding: 5px 0;
  transition: opacity .15s ease, color .15s ease;
}
.footer a:hover { opacity: 1; color: var(--c-accent); }
.footer-bottom {
  padding-top: 22px;
  display: flex; justify-content: space-between; align-items: center;
  flex-wrap: wrap; gap: 12px;
}
.footer-bottom small { color: #8a9bb0; font-size: .82rem; }

@media (max-width: 720px) {
  .footer-grid { grid-template-columns: 1fr 1fr; }
}

/* ===================== WHATSAPP FLOTANTE ===================== */
.wa-float {
  position: fixed;
  bottom: 24px; right: 24px;
  width: 60px; height: 60px;
  background: var(--c-wa);
  color: #fff;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 10px 30px rgba(37,211,102,.45);
  z-index: 200;
  transition: transform .2s ease, box-shadow .2s ease;
  animation: pulseWa 2.5s ease-in-out infinite;
}
.wa-float:hover {
  transform: scale(1.08);
  box-shadow: 0 14px 40px rgba(37,211,102,.55);
  color: #fff;
}
@keyframes pulseWa {
  0%, 100% { box-shadow: 0 10px 30px rgba(37,211,102,.45), 0 0 0 0 rgba(37,211,102,.4); }
  50%      { box-shadow: 0 10px 30px rgba(37,211,102,.45), 0 0 0 14px rgba(37,211,102,0); }
}
