/*
 * ============================================================
 *  MATEU ASESORES DE SEGUROS — Global Design System
 *  Versión: 1.0 (2026-03)
 *  Uso: incluir en TODAS las páginas del sitio.
 *  Este archivo contiene: tipografía, variables, navbar,
 *  footer, WhatsApp float, botones compartidos, utilidades.
 * ============================================================
 */

/* ── 1. FUENTES ─────────────────────────────────────────────
   Inter es la fuente principal del design system.
   Montserrat se mantiene como fallback para páginas legacy.
   ─────────────────────────────────────────────────────────── */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap');

/* ── 2. VARIABLES DE DISEÑO ─────────────────────────────────
   Paleta reducida: brand navy + accent blue + neutros.
   Máximo 3 colores funcionales + blancos y grises.
   ─────────────────────────────────────────────────────────── */
:root {
  /* Brand */
  --color-principal:       #19346e;  /* Navy principal — navbar, footer, títulos */
  --color-principal-oscuro:#0d1b3e;  /* Navy oscuro — gradientes */
  --color-accent:          #2563eb;  /* Blue accent — CTAs primarios */

  /* Neutrals */
  --color-text-dark:       #1e293b;  /* Texto principal */
  --color-text-muted:      #64748b;  /* Texto secundario / subtítulos */
  --color-border:          #e2e8f0;  /* Bordes de tarjetas */
  --color-surface:         #f8fafc;  /* Fondos de secciones alternadas */

  /* Legacy — Bootstrap override */
  --color-texto:           #ffffff;
  --bs-primary-text-emphasis: #19346e;
}

/* ── 3. BASE / LAYOUT ───────────────────────────────────────
   Flex vertical para que el footer siempre quede abajo.
   ─────────────────────────────────────────────────────────── */
html, body {
  height: 100%;
}

body {
  display: flex;
  flex-direction: column;
  min-height: 100svh;
  margin: 0;
  font-family: 'Inter', Montserrat, sans-serif;
  -webkit-font-smoothing: antialiased;
  color: var(--color-text-dark);
  background-color: #ffffff;
}

main {
  flex: 1;
}

/* ── 4. LOGO ────────────────────────────────────────────────*/
.logo {
  display: flex;
  align-items: center;
}

.logo img {
  width: auto;
  object-fit: contain;
  display: block;
}

/* ── 5. NAVBAR ──────────────────────────────────────────────
   Fondo sólido brand navy, sin gradiente, sin sombra pesada.
   Logo reducido a 60px para navbar proporcional.
   ─────────────────────────────────────────────────────────── */
.navbar.navbar-dark {
  background: var(--color-principal) !important;
  color: var(--color-texto);
  box-shadow: none;
  border-bottom: 1px solid rgba(255,255,255,0.08);
  padding: 0.25rem 0;
}

.navbar-brand img {
  height: 60px;
  width: auto;
  display: block;
  transition: transform 0.3s ease;
}

.navbar-brand img:hover {
  transform: scale(1.05);
}

.navbar.navbar-dark .nav-link {
  font-size: 0.9rem;
  font-weight: 500;
  letter-spacing: 0.02em;
  opacity: 0.85;
  transition: opacity 0.2s;
}

.navbar.navbar-dark .nav-link:hover {
  opacity: 1;
}

@media (max-width: 768px) {
  .navbar-brand img {
    height: 50px;
  }
}

/* ── 6. FOOTER ──────────────────────────────────────────────
   Mismo color que el navbar. Tipografía refinada.
   ─────────────────────────────────────────────────────────── */
.footer {
  background: linear-gradient(135deg, var(--color-principal), var(--color-principal-oscuro));
  color: var(--color-texto);
  padding: 1.5rem 10px;
  font-size: 14px;
  text-align: center;
  border-top: 1px solid rgba(255,255,255,0.08);
}

.footer-info p {
  font-size: 0.82rem;
  opacity: 0.85;
  letter-spacing: 0.01em;
  margin: 0;
  line-height: 1.4;
}

.footer-super img {
  max-height: 36px;
  width: auto;
  display: block;
  margin: 0 auto;
  opacity: 0.9;
  transition: opacity 0.3s;
}

.footer-super img:hover {
  opacity: 1;
}

/* ── 7. BOTÓN PRIMARIO (override Bootstrap) ─────────────────*/
.btn-primary {
  background-color: var(--color-principal);
  border-color: var(--color-principal);
  border-radius: 8px;
}

.btn-primary:hover,
.btn-primary:focus {
  filter: brightness(1.1);
  background-color: var(--color-principal);
  border-color: var(--color-principal);
}

/* ── 8. BOTONES HERO ────────────────────────────────────────*/
.btn-hero-primary {
  padding: 0.875rem 2rem;
  font-size: 1rem;
  font-weight: 600;
  background: var(--color-accent);
  border: none;
  border-radius: 8px;
  color: #ffffff;
  transition: all 0.25s ease;
  box-shadow: 0 2px 8px rgba(37,99,235,0.35);
  letter-spacing: 0.01em;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
}

.btn-hero-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(37,99,235,0.5);
  background: #1d4ed8;
  color: #ffffff;
}

.btn-hero-secondary {
  padding: 0.875rem 2rem;
  font-size: 1rem;
  font-weight: 500;
  background: transparent;
  border: 1.5px solid rgba(255,255,255,0.7);
  color: white;
  border-radius: 8px;
  transition: all 0.25s ease;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
}

.btn-hero-secondary:hover {
  background: rgba(255,255,255,0.12);
  border-color: white;
  color: white;
  transform: translateY(-2px);
}

/* ── 9. BOTÓN VOLVER ────────────────────────────────────────
   Compartido entre: siniestros, services, area_clientes, etc.
   ─────────────────────────────────────────────────────────── */
.btn-volver {
  background: white;
  color: var(--color-principal);
  border: 1.5px solid var(--color-principal);
  padding: 0.625rem 1.75rem;
  border-radius: 8px;
  font-weight: 500;
  font-size: 0.9rem;
  transition: all 0.25s ease;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.btn-volver:hover {
  background: var(--color-principal);
  color: white;
  transform: translateX(-4px);
}

/* ── 10. SECTION TITLE / SUBTITLE ───────────────────────────*/
.section-title {
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  font-weight: 600;
  letter-spacing: -0.025em;
  color: var(--color-principal);
  margin-bottom: 1rem;
  text-align: center;
}

.section-subtitle {
  font-size: 1.05rem;
  color: var(--color-text-muted);
  text-align: center;
  max-width: 600px;
  margin: 0 auto 3.5rem;
  line-height: 1.65;
  font-weight: 400;
}

/* ── 11. ANIMATE CARDS ──────────────────────────────────────
   Animación de entrada compartida entre páginas de app.
   ─────────────────────────────────────────────────────────── */
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(28px); }
  to   { opacity: 1; transform: translateY(0); }
}

.animate-in {
  animation: fadeInUp 0.6s ease-out;
}

.animate-card {
  animation: fadeInUp 0.6s ease-out forwards;
  opacity: 0;
}

.animate-card:nth-child(1) { animation-delay: 0.1s; }
.animate-card:nth-child(2) { animation-delay: 0.2s; }
.animate-card:nth-child(3) { animation-delay: 0.3s; }
.animate-card:nth-child(4) { animation-delay: 0.4s; }

/* ── 12. HERO COMPARTIDO (páginas internas de app) ──────────
   Usado en: siniestros, area_clientes, services, etc.
   ─────────────────────────────────────────────────────────── */
.page-hero {
  background: linear-gradient(135deg, var(--color-principal) 0%, var(--color-principal-oscuro) 100%);
  color: white;
  padding: 3.5rem 0 2.5rem;
  margin-bottom: -40px;
  position: relative;
}

.page-hero h1 {
  font-size: clamp(1.75rem, 4vw, 2.25rem);
  font-weight: 600;
  letter-spacing: -0.02em;
  margin-bottom: 0.75rem;
}

.page-hero p {
  font-size: 1rem;
  opacity: 0.88;
  font-weight: 300;
  margin: 0;
}

/* ── 13. WHATSAPP FLOAT ─────────────────────────────────────*/
.whatsapp-float {
  position: fixed;
  width: 56px;
  height: 56px;
  bottom: 24px;
  right: 24px;
  z-index: 1000;
  background-color: #25d366;
  border-radius: 50%;
  display: flex;
  justify-content: center;
  align-items: center;
  box-shadow: 0 2px 12px rgba(37,211,102,0.4);
  transition: transform 0.3s ease;
}

.whatsapp-float:hover { transform: scale(1.1); }

.whatsapp-float img {
  width: 28px;
  height: 28px;
}

.whatsapp-float:focus {
  outline: 3px solid #128C7E;
  outline-offset: 3px;
}

/* ── 14. SCROLLBAR (WebKit) ─────────────────────────────────*/
::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: #ffffff; border-radius: 4px; }
::-webkit-scrollbar-thumb {
  background: var(--color-principal);
  border-radius: 4px;
  border: 2px solid #ffffff;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--color-principal-oscuro);
}

/* ── 15. FORM CONTROLS (shared) ─────────────────────────────*/
.form-control:focus,
.form-select:focus {
  border-color: var(--color-principal);
  box-shadow: 0 0 0 0.2rem rgba(25,52,110,0.15);
}

/* ── 16. TRUST BADGES (hero compartido) ─────────────────────*/
.trust-badges {
  margin-top: 3rem;
  display: flex;
  gap: 2rem;
  flex-wrap: wrap;
  opacity: 0.9;
}

.trust-badge {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.9rem;
}

.trust-badge i {
  font-size: 1.4rem;
  color: rgba(255,255,255,0.85);
}

/* ── 17. UTILIDADES VARIAS ──────────────────────────────────*/
.input-center { text-align: center; }
.label-area-cliente { padding-top: 5px; }
.btn-sesion { color: #b53737 !important; }

/* ── 18. PRINT BASE ─────────────────────────────────────────*/
@media print {
  .whatsapp-float,
  header .navbar,
  footer { display: none !important; }
}
