/* -------------------------------------------------------------
   ESTILOS GENERALES, RESET Y ACCESIBILIDAD
   Sitio Web Legasa Seguros
   ------------------------------------------------------------- */

@import url('variables.css');

/* --- Resets Estándar --- */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  scroll-padding-top: 130px; /* Compensación para el menú pegajoso (sticky header) */
}

body {
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.6;
  color: var(--color-text-main);
  background-color: var(--color-bg-light);
  overflow-x: hidden;
}

/* --- Accesibilidad de Foco (Keyboard Focus Outline) --- */
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
[tabindex]:focus-visible {
  outline: var(--focus-outline);
  outline-offset: var(--focus-outline-offset);
}

/* --- Soporte para Reducción de Movimiento (A11y) --- */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  
  *, *::before, *::after {
    animation-delay: -1ms !important;
    animation-duration: 1ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0s !important;
    scroll-behavior: auto !important;
  }
}

/* --- Tipografía y Títulos --- */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-title);
  font-weight: 700;
  color: var(--color-primary);
  line-height: 1.25;
}

h1 {
  font-size: clamp(2rem, 5vw, 3.25rem);
}

h2 {
  font-size: clamp(1.5rem, 4vw, 2.25rem);
  margin-bottom: 1rem;
}

h3 {
  font-size: clamp(1.25rem, 3vw, 1.5rem);
  margin-bottom: 0.75rem;
}

p {
  margin-bottom: 1rem;
  color: var(--color-text-muted);
}

/* --- Clases de Ayuda / Utilidades --- */
.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

.text-center {
  text-align: center;
}

.section-padding {
  padding: 5rem 0;
}

/* Ajustes para móviles en padding general */
@media (max-width: 767px) {
  .section-padding {
    padding: 3.5rem 0;
  }
}
