/* =================================================================
   Stratton — styles.css
   BLOQUE 1: utilidades base usadas en header, footer, shells y FAB.
   (Se irá ampliando por bloques; todo lo personalizado se define
   AQUÍ antes de usarse en el HTML — sección 4.)
   ================================================================= */

/* --- Tokens auxiliares ------------------------------------------------ */
:root {
  --header-h: 72px;         /* altura del header en móvil  */
  --wa-green: #25D366;      /* verde WhatsApp del botón flotante */
}
@media (min-width: 1024px) {
  :root { --header-h: 80px; } /* altura del header en desktop (lg) */
}

/* --- Base ------------------------------------------------------------- */
body { font-family: 'Inter', sans-serif; }

/* Compensa el header sticky al saltar a una ancla (evita que el
   título de la sección quede oculto bajo el header). */
section[id] { scroll-margin-top: var(--header-h); }

/* Scroll suave nativo como respaldo del scroll por JS. */
html { scroll-behavior: smooth; }

/* --- Accesibilidad ---------------------------------------------------- */
/* Enlace "saltar al contenido": oculto hasta recibir foco por teclado. */
.skip-link {
  position: absolute;
  left: 0.75rem;
  top: -3rem;
  z-index: 100;
  background: #14305C;
  color: #fff;
  padding: 0.5rem 1rem;
  border-radius: 0 0 0.5rem 0.5rem;
  font-size: 0.875rem;
  transition: top 0.2s ease;
}
.skip-link:focus { top: 0; }

/* Foco visible dorado y consistente en toda la navegación por teclado. */
a:focus-visible,
button:focus-visible {
  outline: 2px solid #BD9760;
  outline-offset: 2px;
  border-radius: 0.375rem;
}

/* --- Marca ------------------------------------------------------------ */
.brand { text-decoration: none; }
.brand-img { display: block; height: auto; transition: transform 0.2s ease; }
.brand:hover .brand-img { transform: translateY(-1px); }

/* --- Enlaces de navegación (desktop): subrayado dorado animado -------- */
.nav-link {
  position: relative;
  font-size: 0.95rem;
  font-weight: 500;
  color: #1A2333;
  padding: 0.25rem 0;
  transition: color 0.2s ease;
}
.nav-link::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -2px;
  width: 0;
  height: 2px;
  background: #BD9760;
  transition: width 0.25s ease;
}
.nav-link:hover { color: #14305C; }
.nav-link:hover::after { width: 100%; }
/* Estado ACTIVO: marca la sección donde está el usuario (subrayado fijo) */
.nav-link.active { color: #14305C; }
.nav-link.active::after { width: 100%; }

/* --- Enlaces de navegación (móvil) ------------------------------------ */
.mobile-link {
  display: block;
  padding: 0.75rem 0.25rem;
  font-size: 1rem;
  font-weight: 500;
  color: #1A2333;
  border-bottom: 1px solid #EEF1F5;
  transition: color 0.15s ease, padding-left 0.15s ease;
}
.mobile-link:hover { color: #14305C; padding-left: 0.5rem; }
/* Estado ACTIVO en móvil: color navy + acento dorado a la izquierda */
.mobile-link.active { color: #14305C; padding-left: 0.6rem; box-shadow: inset 3px 0 0 #BD9760; }

/* --- Botón CTA "Cotizar" (cápsula dorada; texto navy por WCAG) -------- */
/* Regla sección 7: texto sobre dorado SIEMPRE primario-dark, nunca blanco. */
.btn-cotiza {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;              /* área táctil mínima móvil */
  padding: 0.55rem 1.5rem;
  border-radius: 9999px;         /* cápsula */
  background: #BD9760;
  color: #0C1F3D;
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-weight: 700;
  font-size: 0.95rem;
  border: none;
  box-shadow: 0 2px 8px rgba(20, 48, 92, 0.15);
  transition: background 0.2s ease, transform 0.15s ease, box-shadow 0.2s ease;
}
.btn-cotiza:hover {
  background: #8A6A38;
  transform: translateY(-1px);
  box-shadow: 0 6px 16px rgba(20, 48, 92, 0.22);
}
.btn-cotiza:active { transform: translateY(0); }

/* --- Botones de redes sociales (íconos) ------------------------------- */
.social-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 9999px;
  color: #14305C;
  transition: color 0.2s ease, background 0.2s ease, transform 0.15s ease;
}
.social-btn:hover { color: #BD9760; background: #EEF1F5; transform: translateY(-1px); }
/* Variante para el footer (fondo navy oscuro). */
.social-btn--dark { color: #EEF1F5; }
.social-btn--dark:hover { color: #BD9760; background: rgba(255, 255, 255, 0.08); }

/* --- Footer ----------------------------------------------------------- */
.footer-title {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-weight: 700;
  font-size: 0.8rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #BD9760;
  margin-bottom: 1rem;
}
.footer-link { color: inherit; transition: color 0.15s ease; }
.footer-link:hover { color: #BD9760; }

/* --- Shells de sección (temporales para el bloque 1) ------------------ */
/* Dan altura a las secciones vacías para poder probar en Live Server el
   header sticky, el scroll suave y la hamburguesa. Se retiran conforme
   se llene cada sección en los bloques 2-4. */
.section-shell { min-height: 60vh; }

/* --- Botón flotante de WhatsApp --------------------------------------- */
.whatsapp-fab {
  position: fixed;
  right: 1rem;
  bottom: 1rem;
  z-index: 60;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  border-radius: 9999px;
  background: var(--wa-green);
  color: #fff;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.22);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.whatsapp-fab:hover {
  transform: scale(1.06);
  box-shadow: 0 10px 26px rgba(0, 0, 0, 0.28);
}
@media (min-width: 640px) {
  .whatsapp-fab { right: 1.5rem; bottom: 1.5rem; width: 60px; height: 60px; }
}

/* --- Divisor de ola (utilidad lista para bloques 2+) ------------------ */
/* Contenedor para insertar los <svg> de olas entre secciones navy/claras.
   Se documenta aquí para que esté definido ANTES de usarse. */
.wave-divider { display: block; width: 100%; line-height: 0; }
.wave-divider svg { display: block; width: 100%; height: auto; }

/* --- Preferencia de movimiento reducido ------------------------------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    transition-duration: 0.001ms !important;
  }
}

/* =================================================================
   BLOQUE 2 — Contenido: utilidades de secciones, cards, badges,
   placeholders de imagen, formulario y divisores de ola.
   ================================================================= */

/* --- Envoltura de sección estándar ------------------------------------ */
.section { padding-top: 3.5rem; padding-bottom: 3.5rem; }
@media (min-width: 1024px) { .section { padding-top: 6rem; padding-bottom: 6rem; } }
.wrap { max-width: 80rem; margin-inline: auto; padding-inline: 1rem; }
@media (min-width: 640px) { .wrap { padding-inline: 1.5rem; } }

/* --- Eyebrow (etiqueta superior con barra dorada) --------------------- */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-weight: 700;
  font-size: 0.78rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #8A6A38;                 /* acento-dark: gold legible sobre claro */
  margin-bottom: 0.9rem;
}
.eyebrow::before {
  content: "";
  width: 26px; height: 2px;
  background: #BD9760;            /* barra dorada decorativa */
}
.eyebrow--on-dark { color: #EEF1F5; }   /* sobre navy: texto claro, barra dorada */

/* --- Títulos y subtítulos de sección ---------------------------------- */
.h-section {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.01em;
  color: #14305C;
  font-size: clamp(1.75rem, 4vw, 3rem);
}
.h-section--on-dark { color: #ffffff; }
.h-section .gold { color: #8A6A38; }              /* palabra destacada sobre claro */
.h-section--on-dark .gold { color: #BD9760; }     /* destacado sobre navy (texto grande = OK) */
.sub-section {
  margin-top: 1rem;
  font-size: 1.05rem;
  line-height: 1.7;
  color: #4B5563;
  max-width: 48rem;
}
.sub-section--on-dark { color: rgba(238, 241, 245, 0.85); }

/* --- Cards ------------------------------------------------------------- */
.card-s {
  background: #ffffff;
  border: 1px solid #EEF1F5;
  border-radius: 1rem;                 /* rounded-xl generoso */
  padding: 1.5rem;
  box-shadow: 0 2px 14px rgba(20, 48, 92, 0.05);
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}
.card-s--hover:hover {
  transform: translateY(-4px);
  box-shadow: 0 14px 32px rgba(20, 48, 92, 0.12);
  border-color: rgba(189, 151, 96, 0.4);
}
.card-title {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-weight: 700;
  font-size: 1.15rem;
  color: #14305C;
  margin-bottom: 0.4rem;
}
.card-text { font-size: 0.95rem; line-height: 1.6; color: #4B5563; }

/* --- Badge de ícono (escudo/palomita) --------------------------------- */
.icon-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 52px; height: 52px;
  border-radius: 0.9rem;
  background: #EEF1F5;
  color: #14305C;
  margin-bottom: 1rem;
  transition: background 0.2s ease, color 0.2s ease;
}
.card-s--hover:hover .icon-badge { background: #14305C; color: #BD9760; }

/* --- Placeholder de imagen (degradado navy + ícono de línea) ---------- */
/* Reemplazar por <img> final; conservar width/height del contenedor. */
.media-ph {
  position: relative;
  width: 100%;
  border-radius: 1rem;
  overflow: hidden;
  background:
    radial-gradient(120% 120% at 20% 10%, #1B3B6F 0%, #14305C 45%, #0C1F3D 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(238, 241, 245, 0.5);
}
.media-ph::after {                 /* etiqueta con el nombre del archivo esperado */
  content: attr(data-file);
  position: absolute;
  bottom: 0.6rem; right: 0.75rem;
  font-size: 0.68rem;
  letter-spacing: 0.03em;
  color: rgba(238, 241, 245, 0.55);
  font-family: 'Inter', sans-serif;
}
.media-ph svg { width: 44px; height: 44px; opacity: 0.7; }
/* Foto real montada sobre el placeholder: si carga, lo cubre; si falta, se ve el degradado */
.media-img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; }

/* --- Chips de confianza (hero) ---------------------------------------- */
.trust-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.85rem;
  font-weight: 500;
  color: #EEF1F5;
}
.trust-chip svg { color: #BD9760; flex-shrink: 0; }

/* --- Botones adicionales ---------------------------------------------- */
.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  min-height: 48px;
  padding: 0.7rem 1.6rem;
  border-radius: 9999px;
  background: #14305C;
  color: #ffffff;
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-weight: 700;
  font-size: 0.98rem;
  border: none;
  box-shadow: 0 2px 10px rgba(20, 48, 92, 0.2);
  transition: background 0.2s ease, transform 0.15s ease, box-shadow 0.2s ease;
}
.btn-primary:hover { background: #0C1F3D; transform: translateY(-1px); box-shadow: 0 8px 20px rgba(20, 48, 92, 0.28); }
.btn-primary:active { transform: translateY(0); }

.btn-outline-light {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  min-height: 48px;
  padding: 0.7rem 1.6rem;
  border-radius: 9999px;
  background: transparent;
  color: #ffffff;
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-weight: 700;
  font-size: 0.98rem;
  border: 1.5px solid rgba(238, 241, 245, 0.5);
  transition: background 0.2s ease, border-color 0.2s ease, transform 0.15s ease;
}
.btn-outline-light:hover { background: rgba(255, 255, 255, 0.08); border-color: #BD9760; transform: translateY(-1px); }
.btn-block { width: 100%; }

/* --- Franja de aseguradoras ------------------------------------------- */
.aseg-logo {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 88px;
  background: #ffffff;
  border: 1px solid #EEF1F5;
  border-radius: 0.9rem;
  box-shadow: 0 2px 10px rgba(20, 48, 92, 0.04);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.aseg-logo:hover { transform: translateY(-3px); box-shadow: 0 10px 24px rgba(20, 48, 92, 0.1); }
.aseg-logo span {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-weight: 800;
  font-size: 1.35rem;
  letter-spacing: 0.02em;
  color: #4B5563;                 /* placeholder tipográfico gris hasta el logo real */
}
/* Logos normalizados ÓPTICAMENTE (no por altura fija): los anchos
   (Banorte, Atlas) se dejan más altos y los compactos (GNP) más chicos,
   para que todos tengan un peso visual parejo. Ajusta los px a ojo. */
.aseg-img { position: absolute; inset: 0; margin: auto; width: auto; height: auto; object-fit: contain; }
.aseg-img.l-gnp     { max-height: 40px; max-width: 66%; }    /* GNP — OK */
.aseg-img.l-banorte { max-height: 60px; max-width: 100%; }   /* Banorte — +ancho */
.aseg-img.l-bxmas   { max-height: 46px; max-width: 70%; }    /* BX+ — OK */
.aseg-img.l-atlas   { max-height: 58px; max-width: 100%; }   /* Atlas — +ancho */

/* --- Formulario -------------------------------------------------------- */
.form-label {
  display: block;
  font-size: 0.9rem;
  font-weight: 600;
  color: #1A2333;
  margin-bottom: 0.4rem;
}
.form-input, .form-select {
  width: 100%;
  min-height: 48px;
  padding: 0.7rem 0.9rem;
  font-size: 0.98rem;
  font-family: 'Inter', sans-serif;
  color: #1A2333;
  background: #ffffff;
  border: 1.5px solid #E2E7EE;
  border-radius: 0.7rem;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.form-input::placeholder { color: #9AA4B2; }
.form-input:focus, .form-select:focus {
  outline: none;
  border-color: #14305C;
  box-shadow: 0 0 0 3px rgba(20, 48, 92, 0.12);
}
.radio-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.55rem 1rem;
  border: 1.5px solid #E2E7EE;
  border-radius: 9999px;
  font-size: 0.92rem;
  color: #1A2333;
  cursor: pointer;
  transition: border-color 0.15s ease, background 0.15s ease;
}
.radio-pill:hover { border-color: #BD9760; }
.radio-pill input { accent-color: #14305C; }
.form-note { font-size: 0.82rem; color: #4B5563; line-height: 1.5; }
.form-note a { color: #8A6A38; text-decoration: underline; }
/* Honeypot anti-spam: fuera de pantalla, invisible para el usuario */
.hp-field { position: absolute; left: -9999px; top: auto; width: 1px; height: 1px; overflow: hidden; }

/* --- Divisor de ola: fill según color de la sección ------------------- */
.wave-divider--up { margin-top: -1px; }        /* evita línea de 1px */
.wave-fill-light   { color: #F7F8FA; }          /* gris-50 */
.wave-fill-navy    { color: #14305C; }          /* primario */

/* --- Tarjeta de concepto (glosario "en simple") ----------------------- */
.concept {
  padding: 1.1rem 1.25rem;
  background: #F7F8FA;
  border-left: 3px solid #BD9760;
  border-radius: 0 0.7rem 0.7rem 0;
}
.concept dt { font-family: 'Plus Jakarta Sans', sans-serif; font-weight: 700; color: #14305C; margin-bottom: 0.2rem; }
.concept dd { font-size: 0.92rem; color: #4B5563; line-height: 1.55; }

/* Retiramos los shells temporales del bloque 1 (ya hay contenido). */
.section-shell { min-height: 0; }

/* =================================================================
   AJUSTES: ondas sutiles, franja de respaldo, imagen en Nosotros
   ================================================================= */

/* Onda casi imperceptible: altura mínima y proporcional */
.wave-divider svg { height: auto; max-height: 26px; }
.wave-fill-white { color: #ffffff; }

/* Franja de respaldo (logos en gris, look de "trust bar", no showcase) */
.strip-logo { position: relative; display: inline-flex; align-items: center; height: 48px; }
.strip-logo img {
  width: auto; object-fit: contain;
  filter: grayscale(1); opacity: 0.65;
  transition: filter 0.2s ease, opacity 0.2s ease;
}
.strip-logo:hover img { filter: grayscale(0); opacity: 1; }
/* Alturas ópticas por logo (todas ~+20%; Banorte y Atlas un poco más) */
.strip-logo.l-gnp img     { height: 31px; }
.strip-logo.l-banorte img { height: 44px; }
.strip-logo.l-bxmas img   { height: 34px; }
.strip-logo.l-atlas img   { height: 41px; }
.strip-logo span {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-weight: 800; font-size: 1.05rem; color: #9AA4B2;
}
