/* =========================================================
   AvalPayCenter — Réplica visual (Vista 1)
   Paleta y tipografía aproximadas al portal original.
   ========================================================= */

:root {
  /* Colores (hex aproximados tomados de la página original) */
  --navy:        #10204d;  /* azul marino de títulos y textos */
  --navy-deep:   #0a1a40;
  --blue:        #3fa0e0;  /* azul claro de botones/acentos */
  --blue-soft:   #eaf4fc;  /* fondos de secciones celestes */
  --blue-softer: #f3f9fe;
  --red:         #e4002b;  /* rojo acento (dots / AV Villas) */
  --green:       #00a44a;  /* verde dot */
  --orange:      #ec6a1f;  /* badge "Nuevo" / Itaú */
  --white:       #ffffff;
  --gray-text:   #4a5568;
  --gray-line:   #e4e9f0;
  --card-shadow: 0 10px 30px rgba(16, 32, 77, 0.08);
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  font-family: 'Jost', 'Segoe UI', system-ui, sans-serif;
  color: var(--navy);
  background: var(--white);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }

a { color: inherit; text-decoration: none; }

.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

/* ---------- Botones ---------- */
.btn {
  display: inline-block;
  font-weight: 700;
  border-radius: 999px;
  padding: 12px 30px;
  cursor: pointer;
  border: none;
  font-size: 1rem;
  transition: transform .15s ease, box-shadow .15s ease;
  font-family: inherit;
}
.btn:hover { transform: translateY(-2px); }

.btn-primary { background: var(--blue); color: var(--white); }
.btn-primary:hover { box-shadow: 0 8px 20px rgba(63,160,224,.4); }

.btn-outline {
  background: transparent;
  color: var(--navy);
  border: 2px solid var(--navy);
}
.btn-outline:hover { background: var(--navy); color: var(--white); }

/* ---------- Puntos decorativos ---------- */
.dots { display: flex; gap: 10px; margin: 8px 0 18px; }
.dot { width: 14px; height: 14px; border-radius: 50%; display: inline-block; }
.dot-navy  { background: var(--navy); }
.dot-red   { background: var(--red); }
.dot-blue  { background: var(--blue); }
.dot-green { background: var(--green); }

/* =========================================================
   MODAL SEGURIDAD
   ========================================================= */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(16, 32, 77, 0.55);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  padding: 20px;
}
/* Al marcar el checkbox (X o Continuar) se oculta el modal */
.modal-close-toggle:checked ~ .modal-overlay { display: none; }

.modal-box {
  background: var(--white);
  border-radius: 20px;
  max-width: 500px;
  width: 100%;
  padding: 36px 40px 40px;
  position: relative;
  box-shadow: 0 30px 70px rgba(0, 0, 0, 0.3);
  text-align: left;
}
.modal-x {
  position: absolute;
  top: 18px;
  right: 22px;
  font-size: 1.6rem;
  line-height: 1;
  color: var(--navy);
  cursor: pointer;
  background: none;
  border: none;
}
.modal-x:hover { color: var(--blue); }

.modal-title {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--navy);
  margin-bottom: 18px;
}
.modal-warn {
  flex-shrink: 0;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--orange);
  color: var(--white);
  font-weight: 900;
  font-size: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
}
.modal-lead {
  font-size: .95rem;
  color: var(--navy);
  margin-bottom: 18px;
}
.modal-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-bottom: 28px;
}
.modal-list li {
  position: relative;
  padding-left: 28px;
  font-size: .9rem;
  color: var(--gray-text);
  line-height: 1.45;
}
.modal-list li::before {
  content: "✓";
  position: absolute;
  left: 0;
  top: 0;
  color: var(--blue);
  font-weight: 900;
}
.modal-list a { color: var(--blue); text-decoration: underline; }
.modal-continue {
  display: block;
  width: fit-content;
  margin: 0 auto;
  cursor: pointer;
  text-align: center;
}

/* =========================================================
   HEADER
   ========================================================= */
.site-header {
  background: var(--white);
  border-bottom: 1px solid var(--gray-line);
  position: sticky;
  top: 0;
  z-index: 50;
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 72px;
  gap: 20px;
}
.brand { display: flex; align-items: center; gap: 10px; }
.brand-logo { height: 34px; width: auto; }
.brand-logo-aval { height: 26px; border-left: 1px solid var(--gray-line); padding-left: 10px; }

.main-nav {
  display: flex;
  align-items: center;
  gap: 28px;
}
.main-nav ul {
  display: flex;
  list-style: none;
  gap: 26px;
  align-items: center;
}
.main-nav a {
  font-weight: 600;
  color: var(--navy);
  font-size: .98rem;
  padding: 6px 0;
}
.main-nav a:hover { color: var(--blue); }
.main-nav a.active { color: var(--blue); font-weight: 800; }
.nav-cta { padding: 10px 26px; }

/* Hamburguesa */
.nav-toggle { display: none; }
.nav-burger {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 6px;
}
.nav-burger span {
  width: 26px; height: 3px;
  background: var(--navy);
  border-radius: 3px;
}

/* =========================================================
   HERO
   ========================================================= */
.hero {
  background: var(--white);
  padding: 40px 0 30px;
}
.hero-row {
  display: flex;
  align-items: center;
  gap: 40px;
  flex-wrap: wrap;
}
.hero-title {
  font-size: clamp(1.8rem, 3vw, 2.4rem);
  font-weight: 800;
  white-space: nowrap;
  flex-shrink: 0;
}
.search-bar {
  display: flex;
  align-items: center;
  gap: 14px;
  flex: 1;
  min-width: 280px;
}
.search-bar input {
  flex: 1;
  min-width: 180px;
  border: 1px solid var(--gray-line);
  border-radius: 999px;
  padding: 16px 22px 16px 46px;
  font-size: 1rem;
  font-family: inherit;
  box-shadow: var(--card-shadow);
  outline: none;
}
.search-bar input:focus { border-color: var(--blue); }
.search-icon {
  position: absolute;
  margin-left: 18px;
  pointer-events: none;
  opacity: .5;
}

/* =========================================================
   PAGOS RÁPIDOS
   ========================================================= */
.quick-pay { padding: 30px 0 50px; }
.section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 26px;
}
.section-head h2 { font-size: 1.5rem; font-weight: 800; }
.link-all { color: var(--blue); font-weight: 700; text-decoration: underline; }

.cards-row {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 20px;
}
.qp-card {
  position: relative;
  background: var(--white);
  border-radius: 18px;
  box-shadow: var(--card-shadow);
  padding: 28px 16px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  font-weight: 700;
  color: var(--navy);
  transition: transform .15s ease, box-shadow .15s ease;
}
.qp-card:hover { transform: translateY(-4px); box-shadow: 0 16px 34px rgba(16,32,77,.14); }
.qp-icon { height: 60px; width: auto; }
.qp-icon-img { height: 56px; }
.badge-new {
  position: absolute;
  top: 10px; right: 10px;
  background: var(--orange);
  color: var(--white);
  font-size: .68rem;
  font-weight: 800;
  padding: 3px 9px;
  border-radius: 6px;
}

/* =========================================================
   BANNER PROMO CRÉDITO
   ========================================================= */
.promo-banner { background: var(--blue-soft); padding: 0 0 18px; }
.promo-inner {
  display: flex;
  align-items: center;
  gap: 30px;
  min-height: 190px;
  flex-wrap: wrap;
}
.promo-img { width: 240px; border-radius: 0 0 0 0; }
.promo-text { flex: 1; min-width: 260px; padding: 20px 0; }
.promo-small { font-size: 1.4rem; font-weight: 700; color: var(--navy); }
.promo-big { font-size: 1.6rem; font-weight: 800; color: var(--navy); margin: 4px 0 14px; }
.promo-big strong { color: var(--navy); }
.promo-tag {
  display: inline-block;
  background: var(--red);
  color: var(--white);
  font-weight: 800;
  font-size: 1.5rem;
  padding: 10px 34px;
  border-radius: 999px;
  margin-bottom: 16px;
}
.promo-legal {
  font-size: .62rem;
  color: var(--gray-text);
  margin-top: 6px;
  line-height: 1.4;
}

/* =========================================================
   BENEFICIOS
   ========================================================= */
.benefits { padding: 50px 0; }
.benefits-inner {
  display: flex;
  align-items: center;
  gap: 50px;
  flex-wrap: wrap;
}
.benefits-media {
  flex: 1;
  min-width: 300px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-template-rows: 1fr 1fr;
  gap: 16px;
}
.benefits-img-main {
  grid-row: 1 / 3;
  border-radius: 20px;
  height: 100%;
  object-fit: cover;
}
.benefits-img-small { border-radius: 20px; object-fit: cover; }
.benefits-text { flex: 1; min-width: 280px; }
.benefits-text h2 { font-size: 2rem; font-weight: 800; }
.benefits-text h3 { font-size: 1.3rem; font-weight: 800; margin-bottom: 10px; }
.benefits-text p { color: var(--gray-text); font-size: 1.05rem; max-width: 420px; }

.carousel-controls {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-top: 28px;
}
.carousel-arrow {
  width: 44px; height: 44px;
  border-radius: 50%;
  border: none;
  background: var(--navy);
  color: var(--white);
  font-size: 1.3rem;
  cursor: pointer;
  line-height: 1;
}
.carousel-arrow:hover { background: var(--navy-deep); }
.carousel-dot {
  width: 11px; height: 11px;
  border-radius: 50%;
  background: var(--gray-line);
  display: inline-block;
}
.carousel-dot.active { background: var(--navy); }

/* =========================================================
   REGÍSTRATE CTA
   ========================================================= */
.register-cta {
  background: var(--blue-soft);
  text-align: center;
  padding: 60px 0;
}
.register-cta h2 { font-size: clamp(1.6rem, 4vw, 2.4rem); font-weight: 800; }
.register-cta p { font-weight: 700; margin: 14px 0 28px; color: var(--navy); }

/* =========================================================
   MEDIOS DE PAGO
   ========================================================= */
.payment-methods { padding: 60px 0; text-align: center; }
.payment-methods h2 { font-size: 1.8rem; font-weight: 800; }
.pm-subtitle { color: var(--gray-text); margin: 10px 0 40px; }
.pm-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  max-width: 820px;
  margin: 0 auto;
}
.pm-card {
  background: var(--white);
  border-radius: 18px;
  box-shadow: var(--card-shadow);
  padding: 34px 28px;
}
.pm-logo { height: 46px; margin: 0 auto 18px; width: auto; object-fit: contain; }
.pm-logo-group {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  margin-bottom: 4px;
}
.pm-logo-group .pm-logo { height: 40px; margin: 0; }
.pm-card h3 { font-size: 1.3rem; font-weight: 800; margin-bottom: 12px; }
.pm-card p { color: var(--gray-text); font-size: .95rem; }

/* =========================================================
   FOOTER
   ========================================================= */
.site-footer { padding: 40px 0; border-top: 1px solid var(--gray-line); position: relative; }
.footer-inner { text-align: center; position: relative; }
.footer-vigilado {
  position: absolute;
  left: -4px;
  top: 0;
  height: 90px;
  width: auto;
  opacity: .9;
}
.footer-banks {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 40px;
  flex-wrap: wrap;
  margin-bottom: 24px;
}
.footer-banks-sprite { height: 34px; width: auto; }
.footer-aval { height: 40px; width: auto; }
.footer-norton { height: 44px; width: auto; }
.footer-phones {
  display: flex;
  gap: 30px;
  justify-content: center;
  flex-wrap: wrap;
  font-weight: 700;
  margin-bottom: 16px;
}
.footer-phones a { color: var(--navy); }
.footer-links {
  display: flex;
  gap: 30px;
  justify-content: center;
  flex-wrap: wrap;
  color: var(--gray-text);
}
.footer-links a:hover { color: var(--blue); }

/* =========================================================
   RESPONSIVE
   ========================================================= */
@media (max-width: 960px) {
  .cards-row { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 820px) {
  .nav-burger { display: flex; }
  .main-nav {
    position: absolute;
    top: 72px;
    left: 0;
    right: 0;
    background: var(--white);
    flex-direction: column;
    align-items: flex-start;
    gap: 0;
    padding: 0 20px;
    max-height: 0;
    overflow: hidden;
    box-shadow: var(--card-shadow);
    transition: max-height .3s ease, padding .3s ease;
  }
  .main-nav ul { flex-direction: column; width: 100%; gap: 0; align-items: stretch; }
  .main-nav ul li { border-bottom: 1px solid var(--gray-line); }
  .main-nav ul li a { display: block; padding: 14px 0; }
  .nav-cta { margin: 16px 0; }
  .nav-toggle:checked ~ .main-nav {
    max-height: 500px;
    padding: 10px 20px 20px;
  }
  .pm-grid { grid-template-columns: 1fr; }
  .benefits-inner { gap: 30px; }
}

@media (max-width: 560px) {
  .cards-row { grid-template-columns: repeat(2, 1fr); }
  .promo-tag { font-size: 1.1rem; padding: 8px 20px; }
  .promo-big { font-size: 1.3rem; }
  .footer-phones, .footer-links { flex-direction: column; gap: 10px; }
}
