/* ============================================================
   Reyes Project — Landing v0.1
   Paleta de marca:
     Primario   #567EC0
     Marino     #0B1A33  (azul muy oscuro, casi negro)
     Blanco     #FFFFFF
     Fondo suave #F3F7FC
     WhatsApp   #0A7C42  (verde accesible AA con texto blanco)
   Mobile-first. Cuerpo mínimo 18px.
   ============================================================ */

:root {
  --primario: #567EC0;
  --primario-oscuro: #3E63A0;
  --marino: #0B1A33;
  --texto: #10233F;
  --texto-suave: #3B4A63;
  --blanco: #FFFFFF;
  --fondo-suave: #F3F7FC;
  --borde: #DDE6F2;
  --whatsapp: #0A7C42;
  --whatsapp-oscuro: #086636;

  --radio: 16px;
  --ancho-max: 720px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  font-size: 19px;
  line-height: 1.65;
  color: var(--texto);
  background: var(--blanco);
  -webkit-font-smoothing: antialiased;
}

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

/* Enlace de salto para lectores de pantalla / teclado */
.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--marino);
  color: #fff;
  padding: 14px 20px;
  z-index: 100;
  border-radius: 0 0 var(--radio) 0;
  font-weight: 700;
}
.skip-link:focus {
  left: 0;
}

.container {
  width: 100%;
  max-width: var(--ancho-max);
  margin: 0 auto;
  padding: 0 20px;
}

/* ---------- Header ---------- */
.site-header {
  background: var(--blanco);
  border-bottom: 1px solid var(--borde);
  padding: 18px 0;
}
.header-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}
.logo {
  width: auto;
  height: 44px;
}

/* ---------- Selector de idioma ES | EN ---------- */
.lang-switch {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  flex: 0 0 auto;
}
.lang-btn {
  font-family: inherit;
  font-size: 1rem;
  font-weight: 700;
  line-height: 1;
  color: var(--texto);
  background: transparent;
  border: 2px solid transparent;
  border-radius: 10px;
  padding: 10px 12px;
  min-width: 46px;
  min-height: 44px;
  cursor: pointer;
  transition: background-color 0.15s ease, color 0.15s ease;
}
.lang-btn:hover {
  background: var(--fondo-suave);
}
.lang-btn.is-active {
  background: var(--primario-oscuro);
  color: #fff;
}
.lang-btn:focus-visible {
  outline: 3px solid var(--primario);
  outline-offset: 2px;
}
.lang-sep {
  color: var(--borde);
  font-weight: 400;
  user-select: none;
}

/* ---------- Hero ---------- */
.hero {
  background: linear-gradient(180deg, #EAF1FB 0%, var(--blanco) 100%);
  text-align: center;
  padding: 56px 0 48px;
}
.hero-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
}
h1 {
  font-size: clamp(2.1rem, 8vw, 3.1rem);
  line-height: 1.15;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--marino);
  margin: 0 0 18px;
}
.subtitulo {
  font-size: clamp(1.15rem, 4.6vw, 1.5rem);
  line-height: 1.5;
  color: var(--texto-suave);
  margin: 0 0 34px;
  max-width: 30ch;
}
.hero-nota {
  margin: 20px 0 0;
  font-size: 1rem;
  color: var(--texto-suave);
}

/* ---------- Botón WhatsApp (CTA) ---------- */
.btn-whatsapp {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  width: 100%;
  max-width: 420px;
  min-height: 68px;
  padding: 18px 28px;
  background: var(--whatsapp);
  color: #fff;
  font-size: 1.3rem;
  font-weight: 700;
  text-decoration: none;
  border-radius: var(--radio);
  box-shadow: 0 6px 18px rgba(10, 124, 66, 0.28);
  transition: background-color 0.15s ease, transform 0.15s ease, box-shadow 0.15s ease;
}
.btn-whatsapp:hover {
  background: var(--whatsapp-oscuro);
}
.btn-whatsapp:active {
  transform: translateY(1px);
}
.btn-whatsapp .wa-icon {
  flex: 0 0 auto;
  width: 32px;
  height: 32px;
}
/* Variante sobre fondo oscuro: refuerzo de foco */
.btn-whatsapp--claro {
  box-shadow: 0 6px 22px rgba(0, 0, 0, 0.35);
}

/* Foco visible y accesible en todos los enlaces/botones */
a:focus-visible {
  outline: 4px solid var(--primario);
  outline-offset: 3px;
  border-radius: 6px;
}
.btn-whatsapp:focus-visible {
  outline: 4px solid #fff;
  outline-offset: 3px;
  box-shadow: 0 0 0 8px rgba(86, 126, 192, 0.9);
}

/* ---------- Cómo funciona ---------- */
.pasos {
  padding: 56px 0;
  background: var(--blanco);
}
h2 {
  font-size: clamp(1.6rem, 6vw, 2.2rem);
  line-height: 1.2;
  font-weight: 800;
  color: var(--marino);
  text-align: center;
  margin: 0 0 36px;
}
.pasos-lista {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 20px;
}
.paso {
  background: var(--fondo-suave);
  border: 1px solid var(--borde);
  border-radius: var(--radio);
  padding: 28px 24px;
  text-align: center;
}
.paso-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 64px;
  height: 64px;
  margin: 0 auto 16px;
  background: var(--primario);
  color: #fff;
  font-size: 1.9rem;
  font-weight: 800;
  border-radius: 50%;
}
.paso-titulo {
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--marino);
  margin: 0 0 10px;
}
.paso-texto {
  margin: 0;
  color: var(--texto-suave);
  font-size: 1.1rem;
}

/* ---------- Confianza ---------- */
.confianza {
  background: var(--marino);
  color: #fff;
  padding: 56px 0;
}
.confianza-inner {
  text-align: center;
}
.confianza h2 {
  color: #fff;
  margin-bottom: 18px;
}
.confianza-texto {
  margin: 0 auto;
  max-width: 44ch;
  font-size: 1.2rem;
  line-height: 1.6;
  color: #DCE6F5;
}

/* ---------- CTA final ---------- */
.cta-final {
  background: linear-gradient(180deg, var(--blanco) 0%, #EAF1FB 100%);
  padding: 56px 0 64px;
}
.cta-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}
.cta-texto {
  font-size: 1.2rem;
  color: var(--texto-suave);
  margin: 0 0 30px;
}

/* ---------- Grupo de botones del CTA final ---------- */
.cta-botones {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  width: 100%;
}

/* ---------- Botón de correo (secundario, accesible) ---------- */
.btn-email {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  width: 100%;
  max-width: 420px;
  min-height: 68px;
  padding: 18px 28px;
  background: #fff;
  color: var(--marino);
  font-size: 1.25rem;
  font-weight: 700;
  text-decoration: none;
  border: 2px solid var(--marino);
  border-radius: var(--radio);
  transition: background-color 0.15s ease, color 0.15s ease, transform 0.15s ease;
}
.btn-email:hover {
  background: var(--marino);
  color: #fff;
}
.btn-email:active {
  transform: translateY(1px);
}
.btn-email .mail-icon {
  flex: 0 0 auto;
  width: 28px;
  height: 28px;
}
.btn-email:focus-visible {
  outline: 4px solid var(--primario);
  outline-offset: 3px;
}

/* ---------- Footer ---------- */
.site-footer {
  background: var(--marino);
  color: #E6EDF9;
  text-align: center;
  padding: 32px 0;
  font-size: 1rem;
}
.footer-inner p {
  margin: 0 0 10px;
}
.footer-inner p:last-child {
  margin-bottom: 0;
}
.footer-email {
  color: #fff;
  font-weight: 700;
  font-size: 1.15rem;
  text-decoration: underline;
  text-underline-offset: 3px;
}
.footer-email:hover {
  color: #DCE6F5;
}
.footer-email:focus-visible {
  outline: 3px solid var(--primario);
  outline-offset: 3px;
  border-radius: 6px;
}
.footer-legal {
  color: #C5D2E8;
}

/* ---------- Página 404 ---------- */
.error-page {
  min-height: 60vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 56px 0 64px;
  background: linear-gradient(180deg, #EAF1FB 0%, var(--blanco) 100%);
}
.error-code {
  font-size: clamp(3.5rem, 16vw, 6rem);
  font-weight: 800;
  line-height: 1;
  color: var(--primario);
  margin: 0 0 8px;
}
.error-title {
  font-size: clamp(1.5rem, 6vw, 2.1rem);
  font-weight: 800;
  color: var(--marino);
  margin: 0 0 14px;
}
.error-sub {
  font-size: 1.15rem;
  color: var(--texto-suave);
  margin: 0 0 32px;
}
.error-actions {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  width: 100%;
}
.link-home {
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--primario-oscuro);
  text-decoration: underline;
  text-underline-offset: 4px;
}
.link-home:focus-visible {
  outline: 3px solid var(--primario);
  outline-offset: 3px;
  border-radius: 6px;
}

/* ---------- Escritorio ---------- */
@media (min-width: 760px) {
  body { font-size: 20px; }
  .logo { height: 60px; }
  .hero { padding: 76px 0 64px; }
  .pasos-lista {
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
  }
  .paso { padding: 34px 24px; }
}

/* ---------- Respeto a quien prefiere menos movimiento ---------- */
@media (prefers-reduced-motion: reduce) {
  * {
    transition: none !important;
    scroll-behavior: auto !important;
  }
}
