/*
  Global Styles for ELITE
  Paleta principal (HEX):
  - Azul profundo: #00049a
  - Azul medio:   #2b85ff
  - Azul claro:   #5ad0ff
  - Neutro claro: #efefef

  Semántica de marca:
  - Confianza  -> #00049a
  - Calma      -> #5ad0ff
  - Seguridad  -> #2b85ff
  - Profesionalismo -> #efefef predominante con acentos #00049a

  Tipografías:
  - Principal: Nexa Heavy (titulares)
  - Complementaria: Nexa Extra Light (cuerpo)
  Nota: Si Nexa no está instalada en el servidor/navegador, se usan fallbacks.
*/

/* Importar Nexa desde CDN */
@import url('https://fonts.cdnfonts.com/css/nexa');

/* Carga de tipografías (si cuentas con archivos locales, ajusta las URLs) */
/* Ejemplo de fuentes locales (coméntalo si no las tienes): */
/*
@font-face {
  font-family: 'Nexa Heavy';
  src: url('/assets/fonts/NexaHeavy.woff2') format('woff2'),
       url('/assets/fonts/NexaHeavy.woff') format('woff');
  font-weight: 800;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'Nexa Extra Light';
  src: url('/assets/fonts/NexaExtraLight.woff2') format('woff2'),
       url('/assets/fonts/NexaExtraLight.woff') format('woff');
  font-weight: 200;
  font-style: normal;
  font-display: swap;
}
*/

/* Variables del sistema */
:root {
  /* Paleta principal */
  --blue-deep: #00049a;
  /* Confianza */
  --blue-mid: #2b85ff;
  /* Seguridad */
  --blue-soft: #5ad0ff;
  /* Calma */
  --neutral-100: #efefef;
  /* Profesionalismo */
  --white: #ffffff;
  --black: #000000;

  /* Derivados y estados */
  --text-on-dark: #ffffff;
  --text-on-light: #0d1b2a;
  --border-color: #d9d9d9;
  --shadow-1: 0 1px 3px rgba(0, 0, 0, .12);
  --shadow-2: 0 10px 20px rgba(0, 0, 0, .12);

  /* Tipografías */
  --font-title: 'Nexa', 'Montserrat', 'Segoe UI', Arial, sans-serif;
  --font-body: 'Nexa', 'Montserrat', 'Segoe UI', Arial, sans-serif;

  /* Escala tipográfica */
  --fs-xs: 0.75rem;
  --fs-sm: 0.875rem;
  --fs-base: 1rem;
  --fs-lg: 1.125rem;
  --fs-xl: 1.25rem;
  --fs-2xl: 1.5rem;
  --fs-3xl: 1.875rem;
  --fs-4xl: 2.25rem;
  --fs-5xl: 3rem;

  /* Radios y foco */
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 14px;
  --focus-ring: 0 0 0 3px rgba(43, 133, 255, 0.35);

  /* Botones */
  --btn-py: .625rem;
  --btn-px: 1rem;
  --btn-fw: 700;
}

/* Reset básico */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  font-size: 100%;
}

body {
  margin: 0;
  color: #0d1b2a;
  background-color: var(--neutral-100);
  font-family: var(--font-body);
  font-weight: 300;
  /* Nexa Light */
  font-size: var(--fs-lg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Asegurar peso y familia para <strong> */
strong,
b {
  font-family: var(--font-title);
  font-weight: 700; /* fuerza negrita incluso si la fuente no trae bold */
}

/* Enlaces */
a {
  color: var(--blue-mid);
  text-decoration: none;
}

a:hover {
  color: var(--blue-deep);
  text-decoration: underline;
}

/* Titulares y texto */
h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--font-title);
  color: var(--blue-deep);
  margin: 0 0 .5em 0;
  line-height: 1.2;
  font-weight: 700;
}

h1 {
  font-size: clamp(2rem, 4vw, var(--fs-5xl));
}

h2 {
  font-size: clamp(1.75rem, 3vw, var(--fs-4xl));
}

h3 {
  font-size: clamp(1.5rem, 2.5vw, var(--fs-3xl));
}

h4 {
  font-size: var(--fs-2xl);
}

h5 {
  font-size: var(--fs-xl);
}

h6 {
  font-size: var(--fs-lg);
}

p {
  margin: 0 0 1em 0;
}

/* Utilidades de color y tipografía */
.text-deep {
  color: var(--blue-deep) !important;
}

.text-mid {
  color: var(--blue-mid) !important;
}

.text-soft {
  color: var(--blue-soft) !important;
}

.text-muted {
  color: #6b7280 !important;
}

.bg-deep {
  background-color: var(--blue-deep) !important;
  color: var(--text-on-dark) !important;
}

.bg-mid {
  background-color: var(--blue-mid) !important;
  color: var(--text-on-dark) !important;
}

.bg-soft {
  background-color: var(--blue-soft) !important;
  color: #00324d !important;
}

.bg-light {
  background-color: var(--neutral-100) !important;
  color: var(--text-on-light) !important;
}

.bg-white {
  background-color: var(--white) !important;
  color: var(--text-on-light) !important;
}

/* Layout helpers */
.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1rem;
}

.section {
  padding: 2.5rem 0;
}

/* Botones */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .5rem;
  padding: var(--btn-py) var(--btn-px);
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  background-color: transparent;
  color: inherit;
  font-family: var(--font-title);
  font-size: var(--fs-base);
  font-weight: var(--btn-fw);
  line-height: 1;
  text-decoration: none;
  cursor: pointer;
  user-select: none;
  transition: background-color .2s ease, color .2s ease, border-color .2s ease, box-shadow .2s ease, transform .02s ease;
}

.btn:focus-visible {
  outline: none;
  box-shadow: var(--focus-ring);
}

.btn:active {
  transform: translateY(1px);
}

.btn[disabled],
.btn[aria-disabled="true"],
.btn:disabled {
  opacity: .6;
  cursor: not-allowed;
  box-shadow: none;
}

/* Variantes */
.btn-primary {
  background-color: var(--blue-deep);
  border-color: var(--blue-deep);
  color: var(--white);
}

.btn-primary:hover {
  background-color: #000387;
  border-color: #000387;
}

.btn-secondary {
  background-color: var(--blue-mid);
  border-color: var(--blue-mid);
  color: var(--white);
}

.btn-secondary:hover {
  background-color: #2074e6;
  border-color: #2074e6;
}

.btn-tertiary {
  background-color: var(--blue-soft);
  border-color: var(--blue-soft);
  color: #00324d;
}

.btn-tertiary:hover {
  background-color: #47c8ff;
  border-color: #47c8ff;
}

.btn-outline-primary {
  background: transparent;
  color: var(--blue-deep);
  border-color: var(--blue-deep);
}

.btn-outline-primary:hover {
  background: rgba(0, 4, 154, .08);
}

.btn-outline-secondary {
  background: transparent;
  color: var(--blue-mid);
  border-color: var(--blue-mid);
}

.btn-outline-secondary:hover {
  background: rgba(43, 133, 255, .1);
}

.btn-outline-tertiary {
  background: transparent;
  color: var(--blue-soft);
  border-color: var(--blue-soft);
}

.btn-outline-tertiary:hover {
  background: rgba(90, 208, 255, .12);
}

.btn-sm {
  padding: .45rem .75rem;
  font-size: var(--fs-sm);
  border-radius: calc(var(--radius-sm) - 2px);
}

.btn-lg {
  padding: .85rem 1.25rem;
  font-size: var(--fs-lg);
  border-radius: var(--radius-md);
}

/* WhatsApp button icon override to match phone style */
.btn-whatsapp {
  position: relative;
}
.btn-whatsapp svg {
  display: none !important;
}
.btn-whatsapp::before {
  content: none !important;
  display: none !important;
}

/* CTA WhatsApp card: replace inline SVG with Bootstrap Icon glyph */
.cta-whatsapp .rounded-circle svg {
  display: none !important;
}
.cta-whatsapp .rounded-circle::before {
  content: "\F618"; /* bi-whatsapp */
  font-family: "bootstrap-icons" !important;
  font-size: 1rem;
  line-height: 1;
}

/* CTA Call card: replace inline SVG with Bootstrap Icon glyph */
.cta-call .rounded-circle svg { display: none !important; }
.cta-call .rounded-circle::before {
  content: "\F5C1"; /* bi-telephone */
  font-family: "bootstrap-icons" !important;
  font-size: 1rem;
  line-height: 1;
}

/* CTA Form card: replace inline SVG with Bootstrap Icon glyph */
.cta-form .rounded-circle svg { display: none !important; }
.cta-form .rounded-circle::before {
  content: "\F3B5"; /* bi-clipboard-check */
  font-family: "bootstrap-icons" !important;
  font-size: 1rem;
  line-height: 1;
}

/* Normalizar iconos en círculos de CTA para diseño consistente */
.card .rounded-circle svg {
  width: 16px;
  height: 16px;
  stroke: currentColor;
  fill: none;
  stroke-width: 2;
}

/* Accident types: nuevo estilo para Font Awesome */
.accident-icon i {
  font-size: 18px;
  line-height: 1;
  color: var(--blue-deep);
}

/* Normalizar iconos en botones primarios y outline del hero */
.hero .btn svg {
  width: 18px;
  height: 18px;
  stroke: currentColor;
  fill: none;
  stroke-width: 2;
}

.btn-block {
  width: 100%;
  display: inline-flex;
}

/* Tarjetas */
.card {
  background: var(--white);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-1);
}

.card-header {
  padding: 1rem 1rem .5rem;
  border-bottom: 1px solid var(--border-color);
  font-family: var(--font-title);
  color: var(--blue-deep);
}

.card-body {
  padding: 1rem;
}

/* Formularios */
input[type="text"],
input[type="email"],
input[type="password"],
select,
textarea {
  width: 100%;
  padding: .55rem .7rem;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  background: var(--white);
  color: #0d1b2a;
  font-family: var(--font-body);
  font-size: var(--fs-base);
  transition: border-color .2s ease, box-shadow .2s ease;
}

input:focus,
select:focus,
textarea:focus {
  outline: none;
  border-color: var(--blue-mid);
  box-shadow: var(--focus-ring);
}

/* Tablas */
table {
  border-collapse: collapse;
  width: 100%;
}

th,
td {
  padding: .625rem .75rem;
  border-bottom: 1px solid var(--border-color);
  text-align: left;
}

thead th {
  background: rgba(43, 133, 255, .08);
  color: var(--blue-deep);
  font-family: var(--font-title);
  font-weight: 800;
}

/* Helpers de espaciado */
.mt-0 {
  margin-top: 0 !important
}

.mt-1 {
  margin-top: .25rem !important
}

.mt-2 {
  margin-top: .5rem !important
}

.mt-3 {
  margin-top: 1rem !important
}

.mb-0 {
  margin-bottom: 0 !important
}

.mb-1 {
  margin-bottom: .25rem !important
}

.mb-2 {
  margin-bottom: .5rem !important
}

.mb-3 {
  margin-bottom: 1rem !important
}

.pt-0 {
  padding-top: 0 !important
}

.pt-1 {
  padding-top: .25rem !important
}

.pt-2 {
  padding-top: .5rem !important
}

.pt-3 {
  padding-top: 1rem !important
}

.pb-0 {
  padding-bottom: 0 !important
}

.pb-1 {
  padding-bottom: .25rem !important
}

.pb-2 {
  padding-bottom: .5rem !important
}

.pb-3 {
  padding-bottom: 1rem !important
}

/* Secciones con fondo de marca */
.section--brand {
  background: linear-gradient(180deg, rgba(0, 4, 154, .08) 0%, rgba(43, 133, 255, .08) 100%);
}

.section--dark {
  background: var(--blue-deep);
  color: var(--text-on-dark);
}

/* Utilidades adicionales */
.object-fit-cover {
  object-fit: cover;
}

.badge {
  display: inline-block;
  padding: .15rem .5rem;
  border-radius: 999px;
  font-size: var(--fs-sm);
}

.badge-success {
  background: #eaf7ef;
  color: #2e7d32;
}

.badge-mid {
  background: rgba(43, 133, 255, .12);
  color: var(--blue-deep);
}

.badge-soft {
  background: rgba(90, 208, 255, .18);
  color: #00324d;
}

/* Footer responsive fixes: prevent long email overflow on mobile */
.site-footer .contact-email,
.site-footer .contact-email a {
  overflow-wrap: anywhere;
  word-break: break-word;
}

@media (max-width: 767.98px) {
  .site-footer .contact-email,
  .site-footer .contact-email a {
    font-size: 0.95rem;
    display: inline-block;
    max-width: 100%;
  }
}

