/* =================================
   FUNDACIÓN ALENU - SISTEMA DE DISEÑO v2.0
   ================================= */

/* -----------------------------------
   VARIABLES DE DISEÑO (CSS Custom Properties)
   ----------------------------------- */
:root {
  /* === PALETA CLARA - Temperatura cálida orgánica === */
  --bg:             #f8f6f2;
  --bg-subtle:      #eae6e1;
  --surface:        #ffffff;
  --surface-raised: #fdfdfd;
  --border:         rgba(51, 47, 43, 0.12);
  --text:           #2a2622;
  --text-muted:     #5a544e;
  --text-faint:     #8a827a;

  /* Acentos - Naranja principal + azul secundario */
  --accent:         #ff6f00;
  --accent-hover:   #ff851a;
  --accent-subtle:  rgba(255, 111, 0, 0.08);
  --secondary:      #3b82f6;
  --secondary-hover: #5a9bff;
  --secondary-subtle: rgba(59, 130, 246, 0.08);

  /* === TIPOGRAFÍA === */
  --font-display: 'Playfair Display', Georgia, serif;
  --font-body:    'Lora', 'Times New Roman', serif;
  --font-ui:      'Inter', -apple-system, BlinkMacSystemFont, sans-serif;

  --text-xs:    0.75rem;
  --text-sm:    0.875rem;
  --text-base:  1rem;
  --text-lg:    1.125rem;
  --text-xl:    1.25rem;
  --text-2xl:   1.5rem;
  --text-3xl:   1.875rem;
  --text-4xl:   2.25rem;

  /* === ESPACIADO === */
  --space-1:   0.25rem;
  --space-2:   0.5rem;
  --space-3:   0.75rem;
  --space-4:   1rem;
  --space-5:   1.25rem;
  --space-6:   1.5rem;
  --space-8:   2rem;
  --space-10:  2.5rem;
  --space-12:  3rem;
  --space-16:  4rem;
  --space-24:  6rem;

  /* === MOTION === */
  --ease-out:    cubic-bezier(0.16, 1, 0.3, 1);
  --ease-in-out: cubic-bezier(0.87, 0, 0.13, 1);
  --duration-fast:   150ms;
  --duration-base:   250ms;
  --duration-slow:   400ms;
  --duration-slower: 600ms;

  /* === SOMBRAS === */
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.08), 0 1px 2px rgba(0, 0, 0, 0.04);
  --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.06), 0 10px 15px rgba(0, 0, 0, 0.08);
  --shadow-lg: 0 10px 15px rgba(0, 0, 0, 0.06), 0 20px 40px rgba(0, 0, 0, 0.12);

  /* === BORDER RADIUS === */
  --radius-sm:   4px;
  --radius-md:   8px;
  --radius-lg:   12px;
  --radius-xl:   16px;
  --radius-2xl:  20px;
  --radius-full: 9999px;

  /* === RGB (sin alpha) para rgba() en backgrounds === */
  --accent-rgb:     255, 111, 0;
  --secondary-rgb:  59, 130, 246;
  --text-rgb:       42, 38, 34;

  /* === SIZES === */
  --size-logo:      120px;
  --size-logo-lg:   200px;
  --size-button:    44px;
  --height-card:    200px;

  /* === NOISE GRAIN === */
  --noise: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.65' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.02'/%3E%3C/svg%3E");
}

/* -----------------------------------
   MODO OSCURO - Prefers + Data attribute
   ----------------------------------- */
@media (prefers-color-scheme: dark) {
  :root {
    --bg:             #0c0b09;
    --bg-subtle:      #141210;
    --surface:        #1a1814;
    --surface-raised: #201e1a;
    --border:         rgba(255, 255, 255, 0.08);
    --text:           #f0ece4;
    --text-muted:     #9a9088;
    --text-faint:     #6a6058;
    --accent:         #ff851a;
    --accent-hover:   #ffa04d;
    --accent-subtle:  rgba(255, 133, 26, 0.12);
    --secondary:      #5a9bff;
    --secondary-hover: #7bb3ff;
    --secondary-subtle: rgba(90, 155, 255, 0.12);
    --accent-rgb:     255, 133, 26;
    --secondary-rgb:  90, 155, 255;
    --text-rgb:       240, 236, 228;
  }
}

[data-theme="dark"] {
  --bg:             #0c0b09;
  --bg-subtle:      #141210;
  --surface:        #1a1814;
  --surface-raised: #201e1a;
  --border:         rgba(255, 255, 255, 0.08);
  --text:           #f0ece4;
  --text-muted:     #9a9088;
  --text-faint:     #6a6058;
  --accent:         #ff851a;
  --accent-hover:   #ffa04d;
  --accent-subtle:  rgba(255, 133, 26, 0.12);
  --secondary:      #5a9bff;
  --secondary-hover: #7bb3ff;
  --secondary-subtle: rgba(90, 155, 255, 0.12);
  --accent-rgb:     255, 133, 26;
  --secondary-rgb:  90, 155, 255;
  --text-rgb:       240, 236, 228;
}

/* -----------------------------------
   RESET & BASE
   ----------------------------------- */
*, *::before, *::after {
  box-sizing: border-box;
}

* {
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  font-size: var(--text-base);
  line-height: 1.6;
  color: var(--text);
  background: var(--bg);
  background-image: var(--noise);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* -----------------------------------
   OPTIMIZACIÓN PARA DISPOSITIVOS GAMA BAJA
   Desactiva decoraciones CPU-costosas en móviles
   ----------------------------------- */
@media (hover: none) and (max-width: 767px) {
  :root {
    --noise: none; /* Sin texture en móviles */
  }

  body {
    background-image: none;
  }

  /* Desactiva círculos decorativos geométricos */
  .geo-ring,
  .geo-ring-2,
  section::before {
    display: none;
  }

  /* Reduce sombras complejas */
  .card,
  .testimonio-card,
  .encuadrada {
    box-shadow: none;
    border: 1px solid var(--border);
  }

  .carousel-dots {
    display: none; /* Menos elementos DOM */
  }

  /* Tipografía más legible sin fuentes externas */
  body {
    font-family: Georgia, 'Times New Roman', serif;
  }
}

/* Todas las secciones pueden albergar decoraciones pseudo */
section {
  position: relative;
  isolation: isolate;
  scroll-margin-top: var(--space-16);
}

/* Saltar a contenido - accesibilidad */
.skip-link {
  position: absolute;
  top: -100%;
  left: var(--space-4);
  padding: var(--space-2) var(--space-4);
  background: var(--accent);
  color: white;
  z-index: 1000;
  border-radius: var(--radius-sm);
  font-family: var(--font-ui);
  font-weight: 500;
  text-decoration: none;
  transition: top var(--duration-fast) var(--ease-out);
}

.skip-link:focus {
  top: var(--space-2);
}

/* -----------------------------------
   CONTENEDOR - Layout limpio SIN flex
   ----------------------------------- */
.container {
  max-width: min(90%, 1200px);
  margin-inline: auto;
  padding-inline: var(--space-4);
}

/* Secciones alternan fondo para ritmo visual */
main > section:nth-of-type(even) {
  background: var(--bg-subtle);
  padding: var(--space-16) var(--space-4);
  margin-inline: calc(-1 * var(--space-4));
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

main > section:nth-of-type(odd) {
  padding-block: var(--space-16);
}

/* -----------------------------------
   TIPOGRAFÍA & JERARQUÍA
   ----------------------------------- */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.02em;
  color: var(--text);
  margin-block: var(--space-4);
}

h1 {
  font-size: var(--text-4xl);
  color: var(--accent);
  text-align: center;
  margin-bottom: var(--space-8);
}

h2 {
  font-size: var(--text-3xl);
  color: var(--accent);
  text-align: left;
  margin-bottom: var(--space-4);
}

/* Subrayado geométrico solo en h2 de contenido */
.row > div > h2 {
  position: relative;
  display: inline-block;
}

.row > div > h2::after {
  content: '';
  position: absolute;
  bottom: -6px;
  left: 0;
  width: 48px;
  height: 3px;
  background: var(--accent);
  border-radius: 2px;
}

h3 {
  font-size: var(--text-2xl);
  color: var(--accent);
  text-align: left;
  margin-bottom: var(--space-3);
}

h4 {
  font-size: var(--text-xl);
  color: var(--text);
}

/* Párrafos de texto común - NO son tarjetas */
p {
  margin-bottom: var(--space-3);
  text-align: justify;
  line-height: 1.7;
}

ul {
  margin-bottom: var(--space-4);
  padding-left: var(--space-6);
}

li {
  margin-bottom: var(--space-2);
  line-height: 1.6;
}

strong {
  color: var(--accent);
  font-weight: 600;
}

/* -----------------------------------
   DECORACIONES GEOMÉTRICAS — Círculos concéntricos
   ----------------------------------- */
section::before {
  content: '';
  position: absolute;
  border-radius: 50%;
  z-index: -1;
  pointer-events: none;
}

/* Círculo decorativo grande, fondo-calado, en secciones pares */
section:nth-of-type(even)::before {
  width: min(60vw, 500px);
  height: min(60vw, 500px);
  background: radial-gradient(circle at center, rgba(var(--accent-rgb), 0.04) 0%, transparent 65%);
  top: -15%;
  right: -10%;
}

/* Círculo decorativo secundario en secciones nones (incluyendo hero) */
section:nth-of-type(odd)::before {
  width: min(40vw, 350px);
  height: min(40vw, 350px);
  background: radial-gradient(circle at center, rgba(var(--secondary-rgb), 0.04) 0%, transparent 65%);
  bottom: -10%;
  left: -8%;
}

/*-----------------------------------
   TARJETAS - Solo con clase .card
   ----------------------------------- */
.card {
  background: var(--surface);
  border-radius: var(--radius-lg);
  padding: var(--space-6);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  transition: transform var(--duration-base) var(--ease-out),
              box-shadow var(--duration-base) var(--ease-out);
}

.card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.card--compact {
  padding: var(--space-4);
}

/* -----------------------------------
   IMÁGENES - Estándar consistente
   ----------------------------------- */
img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* Imágenes con marco estilizado */
.encuadrada {
  border: 1px solid var(--border);
  border-radius: var(--radius-2xl);
  box-shadow: var(--shadow-sm);
  width: 100%;
  height: auto;
  max-height: 420px;
  object-fit: cover;
  object-position: center;
  transition: transform var(--duration-base) var(--ease-out),
              box-shadow var(--duration-base) var(--ease-out),
              border-color var(--duration-fast) var(--ease-out);
}

.encuadrada:hover {
  transform: scale(1.02);
  box-shadow: var(--shadow-md);
  border-color: var(--accent);
}

.encuadrada--panoramica {
  max-height: 280px;
}

.encuadrada--vertical {
  max-height: 500px;
  object-position: center top;
}

.encuadrada--cuadrada {
  max-height: 400px;
}

/* Subtítulo en header (ex H1) */
.header-subtitle {
  font-family: var(--font-ui);
  font-size: var(--text-sm);
  color: var(--text-muted);
  text-align: center;
  margin-bottom: var(--space-4);
  letter-spacing: 0.03em;
}

/* Logo redondo - clickeable */
.rounded-logo {
  border-radius: var(--radius-full);
  width: var(--size-logo);
  height: var(--size-logo);
  object-fit: cover;
  object-position: center;
  border: 2px solid var(--accent);
  cursor: pointer;
  transition: transform var(--duration-base) var(--ease-out);
}

.rounded-logo.enlarged {
  width: var(--size-logo-lg);
  height: var(--size-logo-lg);
}

.rounded-logo:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

/* -----------------------------------
   LAYOUT - Grid para filas (remplaza Bootstrap)
   ----------------------------------- */
.row {
  display: grid;
  gap: var(--space-8);
  align-items: start;
}

@media (min-width: 768px) {
  .row {
    grid-template-columns: repeat(12, 1fr);
    gap: var(--space-8);
  }

  .row > div {
    grid-column: span 6;
  }

  /* Sección mision-vision y objetivos: 3 divs, span 4 cada uno */
  #mision-vision > div,
  #objetivos > div {
    grid-column: span 4;
  }

  /* Override: secciones con 2 columnas (imagen + texto) usar 5/7 */
  #quienes-somos > div:first-child,
  #principios > div:first-child,
  #servicios > div:first-child {
    grid-column: span 5;
  }
  #quienes-somos > div:last-child,
  #principios > div:last-child,
  #servicios > div:last-child {
    grid-column: span 7;
  }

  /* Sección apoyar: 3 columnas, distribución 4/4/4 */
  #apoyar > div {
    grid-column: span 4;
  }

  /* La galería: título + wrapper ocupan todo el ancho */
  #galeria > * {
    grid-column: 1 / -1;
  }
}

/* -----------------------------------
   CARRUSELES POR CATEGORÍA
   ----------------------------------- */
.carousel-section {
  margin-bottom: var(--space-8);
  padding: var(--space-6);
  background: var(--surface);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  transition: opacity var(--duration-slower) var(--ease-out),
              transform var(--duration-slower) var(--ease-out);
}

#galeria.visible .carousel-section:nth-child(n+2) {
  animation: fadeSection calc(var(--duration-slower) * 0.6) var(--ease-out) backwards;
}
#galeria.visible .carousel-section:nth-child(2) { animation-delay: 80ms; }
#galeria.visible .carousel-section:nth-child(3) { animation-delay: 160ms; }
#galeria.visible .carousel-section:nth-child(4) { animation-delay: 240ms; }
#galeria.visible .carousel-section:nth-child(5) { animation-delay: 320ms; }
#galeria.visible .carousel-section:nth-child(6) { animation-delay: 400ms; }
#galeria.visible .carousel-section:nth-child(7) { animation-delay: 480ms; }
#galeria.visible .carousel-section:nth-child(8) { animation-delay: 560ms; }
#galeria.visible .carousel-section:nth-child(9) { animation-delay: 640ms; }

@keyframes fadeSection {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}

.carousel-title {
  font-size: var(--text-xl);
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--text);
  margin-bottom: var(--space-1);
  display: flex;
  align-items: center;
  gap: var(--space-2);
}

.carousel-subtitle {
  font-size: var(--text-sm);
  color: var(--text-muted);
  margin-bottom: var(--space-4);
  font-family: var(--font-ui);
}

.carousel {
  position: relative;
  overflow: hidden;
}

.carousel-track {
  display: flex;
  gap: var(--space-4);
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  padding: var(--space-2) 0;
}

.carousel-track::-webkit-scrollbar {
  display: none;
}

.carousel-item {
  flex: 0 0 auto;
  width: clamp(200px, 28vw, 280px);
  scroll-snap-align: start;
  border-radius: var(--radius-xl);
  overflow: hidden;
  cursor: pointer;
  transition: transform var(--duration-base) var(--ease-out),
              box-shadow var(--duration-base) var(--ease-out);
  background: var(--bg-subtle);
}

.carousel-item:hover {
  transform: translateY(-3px) scale(1.02);
  box-shadow: var(--shadow-lg);
}

.carousel-item img {
  width: 100%;
  aspect-ratio: 4/3;
  height: clamp(150px, 21vw, 210px);
  object-fit: cover;
  display: block;
  border-radius: var(--radius-xl);
  border: 1px solid var(--border);
  background: var(--bg-subtle);
}

.carousel-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 36px;
  height: 36px;
  border-radius: var(--radius-full);
  background: var(--surface);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-md);
  cursor: pointer;
  font-size: var(--text-xl);
  line-height: 1;
  color: var(--text);
  z-index: 2;
  transition: background var(--duration-fast) var(--ease-out),
              color var(--duration-fast) var(--ease-out),
              transform var(--duration-fast) var(--ease-out);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
}

.carousel:hover .carousel-btn {
  opacity: 1;
  pointer-events: auto;
}

.carousel-btn:hover {
  background: var(--accent);
  color: white;
  transform: translateY(-50%) scale(1.1);
}

.carousel-btn:focus-visible {
  opacity: 1;
  pointer-events: auto;
}

.carousel-btn--prev { left: var(--space-1); }
.carousel-btn--next { right: var(--space-1); }

.carousel-dots {
  display: flex;
  justify-content: center;
  gap: var(--space-2);
  margin-top: var(--space-3);
  flex-wrap: wrap;
}

.carousel-dot {
  width: 8px;
  height: 8px;
  border-radius: var(--radius-full);
  background: var(--border);
  border: none;
  cursor: pointer;
  padding: 0;
  transition: background var(--duration-fast) var(--ease-out),
              transform var(--duration-fast) var(--ease-out);
}

.carousel-dot.active {
  background: var(--accent);
  transform: scale(1.4);
}

.carousel-dot:hover {
  background: var(--accent-hover);
  transform: scale(1.2);
}

@media (max-width: 768px) {
  .carousel-section {
    padding: var(--space-4);
    margin-bottom: var(--space-6);
  }

  .carousel-item {
    width: 70vw;
  }

  .carousel-item img {
    height: clamp(180px, 50vw, 260px);
  }

  .carousel-btn {
    display: none;
  }
}

@media (max-width: 480px) {
  .carousel-item {
    width: 80vw;
  }
}

@media (max-width: 767px) {
  p {
    text-align: left;
  }

  .theme-toggle {
    top: auto;
    bottom: var(--space-4);
    right: var(--space-4);
  }

  .encuadrada {
    max-height: none;
    object-fit: none;
  }

  .encuadrada--panoramica {
    max-height: none;
  }

  .encuadrada--vertical {
    max-height: none;
    object-position: center;
  }

  .row {
    gap: var(--space-6);
  }

  main > section:nth-of-type(even) {
    padding: var(--space-12) var(--space-4);
  }

  main > section:nth-of-type(odd) {
    padding-block: var(--space-12);
  }
}

/* -----------------------------------
   LIGHTBOX
   ----------------------------------- */
.lightbox-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.92);
  z-index: 9999;
  cursor: pointer;
  padding: var(--space-6);
}

.lightbox-overlay.active {
  display: flex;
  align-items: center;
  justify-content: center;
}

.lightbox-overlay img {
  max-width: 100%;
  max-height: 90vh;
  object-fit: contain;
  border-radius: var(--radius-md);
}

.lightbox-close {
  position: absolute;
  top: var(--space-4);
  right: var(--space-6);
  font-size: var(--text-4xl);
  color: #fff;
  cursor: pointer;
  line-height: 1;
  opacity: 0.7;
  transition: opacity var(--duration-fast) var(--ease-out);
  background: transparent;
  border: none;
  font-family: var(--font-ui);
}

.lightbox-close:hover,
.lightbox-close:focus-visible {
  opacity: 1;
}

.lightbox-close:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
  border-radius: var(--radius-sm);
}

/* -----------------------------------
   TOGGLE MODO OSCURO - Botón flotante
   ----------------------------------- */
.theme-toggle {
  position: fixed;
  top: var(--space-4);
  right: var(--space-4);
  z-index: 1000;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-full);
  width: var(--size-button);
  height: var(--size-button);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background var(--duration-fast) var(--ease-out),
              transform var(--duration-fast) var(--ease-out);
  box-shadow: var(--shadow-sm);
}

.theme-toggle:hover {
  background: var(--accent-subtle);
  transform: scale(1.05);
}

.theme-toggle:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.theme-toggle svg {
  width: 20px;
  height: 20px;
  fill: var(--accent);
}

/* -----------------------------------
    TRANSPARENCIA / IMPACTO
    ----------------------------------- */
.impact-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: var(--space-4);
  margin-top: var(--space-4);
}

.impact-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-6) var(--space-4);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-2xl);
  text-align: center;
  transition: transform var(--duration-base) var(--ease-out),
              box-shadow var(--duration-base) var(--ease-out);
}

.impact-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}

.impact-number {
  font-family: var(--font-display);
  font-size: var(--text-4xl);
  font-weight: 800;
  color: var(--accent);
  line-height: 1;
}

.impact-label {
  font-family: var(--font-ui);
  font-size: var(--text-sm);
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.donation-progress {
  grid-column: 1 / -1;
  margin-top: var(--space-6);
  padding: var(--space-6);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
}

.donation-progress-label {
  text-align: center;
  font-family: var(--font-ui);
  font-size: var(--text-sm);
  color: var(--text-muted);
  margin-bottom: var(--space-3);
}

.progress-bar {
  width: 100%;
  height: 12px;
  background: var(--bg-subtle);
  border-radius: var(--radius-full);
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--accent), var(--secondary));
  border-radius: var(--radius-full);
  transition: width 1s var(--ease-out);
}

.donation-progress-stats {
  display: flex;
  justify-content: space-between;
  font-family: var(--font-ui);
  font-size: var(--text-xs);
  color: var(--text-muted);
  margin-top: var(--space-2);
  margin-bottom: 0;
}

.donation-progress-stats span:first-child {
  color: var(--accent);
  font-weight: 600;
}

/* -----------------------------------
    FOOTER — Divisor geométrico
    ----------------------------------- */
footer {
  background: var(--bg-subtle);
  padding: var(--space-16) 0 var(--space-12);
  margin-top: 0;
  position: relative;
}

/* Línea geométrica decorativa superior */
footer::before {
  content: '';
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: min(90%, 1200px);
  height: 1px;
  background: linear-gradient(
    to right,
    transparent 0%,
    var(--accent) 20%,
    var(--secondary) 50%,
    var(--accent) 80%,
    transparent 100%
  );
}

footer h2 {
  text-align: center;
  margin-bottom: var(--space-8);
}

footer h2::after {
  left: 50%;
  transform: translateX(-50%);
}

footer p {
  text-align: center;
  color: var(--text-muted);
  font-size: var(--text-sm);
  margin-bottom: var(--space-2);
}

footer p:last-child {
  margin-top: var(--space-8);
  font-size: var(--text-xs);
  color: var(--text-faint);
}

footer .footer-inner {
  max-width: 1200px;
  margin-inline: auto;
  padding-inline: var(--space-6);
}

/* -----------------------------------
    CONTACT FORM
    ----------------------------------- */
.contact-form {
  max-width: 500px;
  margin: var(--space-10) auto;
  background: var(--surface);
  border-radius: var(--radius-2xl);
  border: 1px solid var(--border);
  overflow: hidden;
}

.form-header {
  text-align: center;
  padding: var(--space-6) var(--space-6) var(--space-2);
}

.form-header h3 {
  margin: 0 0 var(--space-1);
  font-size: var(--text-xl);
  font-family: var(--font-display);
  color: var(--text);
}

.form-header p {
  margin: 0;
  font-size: var(--text-sm);
  color: var(--text-muted);
  font-family: var(--font-ui);
  text-align: center;
}

.form-body {
  padding: 0 var(--space-6) var(--space-6);
}

.form-group {
  margin-bottom: var(--space-4);
}

.form-group label {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  font-family: var(--font-ui);
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--text);
  margin-bottom: var(--space-1);
}

.form-group label svg {
  stroke: var(--text-muted);
  flex-shrink: 0;
}

.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  padding: var(--space-3) var(--space-4);
  font-family: var(--font-body);
  font-size: var(--text-base);
  color: var(--text);
  background: var(--bg);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-lg);
  transition: border-color var(--duration-fast) var(--ease-out),
              box-shadow var(--duration-fast) var(--ease-out);
  appearance: none;
}

.form-group select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%238a827a' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  padding-right: 36px;
  cursor: pointer;
}

.form-group input::placeholder,
.form-group textarea::placeholder {
  color: var(--text-faint);
  font-size: var(--text-sm);
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-subtle);
}

.form-btn {
  width: 100%;
  padding: var(--space-3) var(--space-6);
  background: var(--accent);
  color: white;
  border: none;
  border-radius: var(--radius-full);
  font-family: var(--font-ui);
  font-size: var(--text-base);
  font-weight: 600;
  cursor: pointer;
  transition: transform var(--duration-fast) var(--ease-out),
              box-shadow var(--duration-fast) var(--ease-out);
  margin-top: var(--space-2);
}

.form-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(var(--accent-rgb), 0.35);
}

.form-btn:active {
  transform: scale(0.97);
}

.form-btn:focus-visible {
  outline: 2px solid var(--text);
  outline-offset: 2px;
}

@media (max-width: 767px) {
  .contact-form {
    margin: var(--space-6) calc(-1 * var(--space-4));
    border-radius: var(--radius-lg);
  }

  .form-header {
    padding: var(--space-5) var(--space-4) var(--space-2);
  }

  .form-body {
    padding: 0 var(--space-4) var(--space-5);
  }
}

/* -----------------------------------
    FLOATING ACTION BUTTONS (CTA + WhatsApp)
    ----------------------------------- */
.fab-bar {
  position: fixed;
  bottom: var(--space-6);
  right: var(--space-6);
  z-index: 900;
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  opacity: 0;
  transform: translateY(20px);
  transition: opacity var(--duration-slow) var(--ease-out),
              transform var(--duration-slow) var(--ease-out);
  pointer-events: none;
}

.fab-bar.visible {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

.fab-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  border-radius: var(--radius-full);
  border: none;
  cursor: pointer;
  text-decoration: none;
  box-shadow: var(--shadow-lg);
  transition: transform var(--duration-fast) var(--ease-out),
              box-shadow var(--duration-fast) var(--ease-out);
  position: relative;
}

.fab-btn:hover {
  transform: scale(1.1);
  box-shadow: 0 12px 28px rgba(0,0,0,0.2);
}

.fab-btn:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

.fab-btn svg {
  width: 28px;
  height: 28px;
}

.fab-btn--whatsapp {
  background: #25D366;
  color: white;
}

.fab-btn--whatsapp:hover {
  background: #20bd5a;
}

.fab-btn--donate {
  background: var(--accent);
  color: white;
}

.fab-btn--donate:hover {
  background: var(--accent-hover);
}

.fab-label {
  position: absolute;
  right: calc(100% + 12px);
  background: var(--surface);
  color: var(--text);
  padding: var(--space-1) var(--space-3);
  border-radius: var(--radius-md);
  font-family: var(--font-ui);
  font-size: var(--text-sm);
  font-weight: 500;
  white-space: nowrap;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border);
  opacity: 0;
  transform: translateX(8px);
  transition: opacity var(--duration-fast) var(--ease-out),
              transform var(--duration-fast) var(--ease-out);
  pointer-events: none;
}

.fab-btn:hover .fab-label {
  opacity: 1;
  transform: translateX(0);
}

@media (max-width: 767px) {
  .fab-bar {
    bottom: var(--space-4);
    right: var(--space-4);
    gap: var(--space-2);
    flex-direction: row-reverse;
  }

  .fab-btn {
    width: 48px;
    height: 48px;
  }

  .fab-btn svg {
    width: 24px;
    height: 24px;
  }

  .fab-label {
    display: none;
  }
}

.footer-copy {
  margin-top: var(--space-8);
  font-size: var(--text-xs);
  color: var(--text-faint);
  text-align: center;
}

/* -----------------------------------
    ACCESIBILIDAD - Focus visible
    ----------------------------------- */
:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

:focus:not(:focus-visible) {
  outline: none;
}

/* Links accesibles */
a {
  color: var(--secondary);
  text-decoration: underline;
  transition: color var(--duration-fast) var(--ease-out);
}

a:hover {
  color: var(--secondary-hover);
}

/* -----------------------------------
   REDISEÑO 2026 — TRANSPARENCIA (fuera de main)
   ----------------------------------- */
#transparencia {
  padding: var(--space-16) var(--space-4);
  max-width: min(90%, 1200px);
  margin-inline: auto;
  background: var(--bg);
}

#transparencia .impact-grid {
  margin-top: var(--space-6);
}

/* -----------------------------------
   REDISEÑO 2026 — HERO CON IMAGEN
   ----------------------------------- */
#hero {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 85vh;
  overflow: hidden;
  isolation: isolate;
  background: var(--bg);
}

.hero-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.hero-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 30%;
}

.hero-bg::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(
    180deg,
    rgba(0,0,0,0.60) 0%,
    rgba(0,0,0,0.45) 35%,
    rgba(0,0,0,0.65) 100%
  );
}

.hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
  padding: var(--space-8) var(--space-4);
  max-width: 800px;
  margin: 0 auto;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-1) var(--space-4);
  background: rgba(255,255,255,0.15);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(255,255,255,0.2);
  border-radius: var(--radius-full);
  font-family: var(--font-ui);
  font-size: var(--text-xs);
  color: #fff;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin-bottom: var(--space-4);
}

.hero-tagline {
  font-family: var(--font-display);
  font-size: clamp(2rem, 5.5vw, 4rem);
  font-weight: 800;
  color: #fff;
  line-height: 1.15;
  letter-spacing: -0.03em;
  margin-bottom: var(--space-4);
  border: none;
  padding: 0;
  max-width: 700px;
  margin-inline: auto;
  text-shadow: 0 2px 20px rgba(0,0,0,0.3);
}

.hero-sub {
  font-family: var(--font-body);
  font-size: clamp(1rem, 2vw, 1.25rem);
  color: rgba(255,255,255,0.85);
  line-height: 1.6;
  max-width: 560px;
  margin: 0 auto var(--space-6);
}

.hero-stats {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: var(--space-3);
  margin-bottom: var(--space-6);
}

.stat-item {
  font-family: var(--font-ui);
  font-size: var(--text-xs);
  color: #fff;
  text-align: center;
  line-height: 1.4;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: var(--space-3) var(--space-5);
  background: rgba(255,255,255,0.1);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: var(--radius-lg);
  min-width: 140px;
  box-shadow: 0 4px 20px rgba(0,0,0,0.1);
  transition: transform var(--duration-base) var(--ease-out),
              background var(--duration-base) var(--ease-out);
}

.stat-item:hover {
  transform: translateY(-4px);
  background: rgba(255,255,255,0.18);
}

.stat-item strong {
  display: block;
  font-family: var(--font-display);
  font-size: var(--text-3xl);
  color: #fff;
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.1;
  margin-bottom: var(--space-1);
}

.hero-cta {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-4) var(--space-10);
  background: var(--accent);
  color: #fff;
  border: none;
  border-radius: var(--radius-full);
  font-family: var(--font-ui);
  font-size: var(--text-lg);
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  box-shadow: 0 8px 30px rgba(var(--accent-rgb), 0.4);
  transition: transform var(--duration-fast) var(--ease-out),
              box-shadow var(--duration-fast) var(--ease-out);
}

.hero-cta:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 40px rgba(var(--accent-rgb), 0.5);
}

.hero-cta:active {
  transform: scale(0.97);
}

.hero-cta-arrow {
  transition: transform var(--duration-fast) var(--ease-out);
}

.hero-cta:hover .hero-cta-arrow {
  transform: translateX(4px);
}

.hero-meta {
  font-family: var(--font-ui);
  font-size: var(--text-xs);
  color: rgba(255,255,255,0.6);
  text-align: center;
  margin-top: var(--space-3);
  margin-bottom: 0;
  letter-spacing: 0.02em;
}

@media (max-width: 767px) {
  #hero {
    min-height: 75vh;
  }

  .hero-tagline {
    font-size: clamp(1.5rem, 7vw, 2rem);
  }

  .hero-sub {
    font-size: var(--text-sm);
  }

  .stat-item {
    flex: 1 1 calc(50% - var(--space-3));
    min-width: 0;
    padding: var(--space-3);
  }

  .stat-item strong {
    font-size: var(--text-2xl);
  }

  .hero-stats {
    gap: var(--space-2);
  }
}

/* -----------------------------------
   REDISEÑO 2026 — CÓMO APOYAR (3 TARJETAS)
   ----------------------------------- */
#apoyar {
  padding: var(--space-16) var(--space-4);
  max-width: min(90%, 1200px);
  margin-inline: auto;
}

.apoyar-header {
  text-align: center;
  margin-bottom: var(--space-12);
}

.apoyar-header h2 {
  text-align: center;
  margin-bottom: var(--space-2);
}

.apoyar-header h2::after {
  left: 50%;
  transform: translateX(-50%);
}

.apoyar-header p {
  text-align: center;
  color: var(--text-muted);
  font-size: var(--text-lg);
  max-width: 500px;
  margin: 0 auto;
}

.apoyar-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: var(--space-6);
  align-items: start;
}

.apoyar-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-2xl);
  padding: var(--space-8) var(--space-6);
  text-align: center;
  position: relative;
  transition: transform var(--duration-base) var(--ease-out),
              box-shadow var(--duration-base) var(--ease-out);
}

.apoyar-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.apoyar-card--featured {
  border: 2px solid var(--accent);
  box-shadow: 0 0 0 1px var(--accent), var(--shadow-md);
}

.apoyar-badge {
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--accent);
  color: #fff;
  font-family: var(--font-ui);
  font-size: var(--text-xs);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: var(--space-1) var(--space-4);
  border-radius: var(--radius-full);
}

.apoyar-icon {
  font-size: 2.5rem;
  margin-bottom: var(--space-3);
  line-height: 1;
}

.apoyar-card h3 {
  font-family: var(--font-display);
  font-size: var(--text-xl);
  color: var(--text);
  margin-bottom: var(--space-2);
}

.apoyar-amount {
  font-family: var(--font-ui);
  font-size: var(--text-lg);
  font-weight: 700;
  color: var(--accent);
  margin-bottom: var(--space-3);
  text-align: center;
}

.apoyar-desc {
  font-size: var(--text-sm);
  color: var(--text-muted);
  line-height: 1.6;
  margin-bottom: var(--space-5);
  text-align: center;
}

.apoyar-bank {
  background: var(--bg-subtle);
  border-radius: var(--radius-lg);
  padding: var(--space-3);
  margin-bottom: var(--space-4);
}

.apoyar-bank strong {
  display: block;
  font-family: var(--font-ui);
  font-size: var(--text-sm);
  color: var(--text);
  margin-bottom: var(--space-1);
}

.apoyar-bank span {
  font-size: var(--text-xs);
  color: var(--text-muted);
  font-family: var(--font-ui);
  word-break: break-all;
}

.apoyar-copy {
  width: 100%;
  padding: var(--space-3);
  background: var(--surface);
  border: 2px solid var(--accent);
  border-radius: var(--radius-full);
  color: var(--accent);
  font-family: var(--font-ui);
  font-size: var(--text-sm);
  font-weight: 600;
  cursor: pointer;
  transition: background var(--duration-fast) var(--ease-out),
              color var(--duration-fast) var(--ease-out);
}

.apoyar-copy:hover {
  background: var(--accent);
  color: #fff;
}

.apoyar-copy.copied {
  background: #22c55e;
  color: #fff;
  border-color: #22c55e;
}

.apoyar-btn {
  display: block;
  width: 100%;
  padding: var(--space-3);
  background: var(--accent);
  color: #fff;
  border: none;
  border-radius: var(--radius-full);
  font-family: var(--font-ui);
  font-size: var(--text-sm);
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: background var(--duration-fast) var(--ease-out),
              transform var(--duration-fast) var(--ease-out);
}

.apoyar-btn:hover {
  background: var(--accent-hover);
  transform: translateY(-2px);
}

.apoyar-btn--outline {
  background: transparent;
  border: 2px solid var(--accent);
  color: var(--accent);
}

.apoyar-btn--outline:hover {
  background: var(--accent);
  color: #fff;
}

@media (max-width: 767px) {
  #apoyar {
    padding: var(--space-12) var(--space-4);
  }

  .apoyar-header {
    margin-bottom: var(--space-8);
  }

  .apoyar-grid {
    gap: var(--space-4);
  }

  .apoyar-card {
    padding: var(--space-6) var(--space-4);
  }
}

/* -----------------------------------
   REDISEÑO 2026 — SERVICIOS CON ICONOS
   ----------------------------------- */
.service-item {
  display: flex;
  gap: var(--space-4);
  padding: var(--space-4) var(--space-5);
  margin-bottom: var(--space-3);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  transition: transform var(--duration-base) var(--ease-out),
              box-shadow var(--duration-base) var(--ease-out);
}

.service-item:hover {
  transform: translateX(4px);
  box-shadow: var(--shadow-md);
  border-color: var(--accent);
}

.service-icon {
  flex-shrink: 0;
  width: 44px;
  height: 44px;
  background: var(--accent-subtle);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  color: var(--accent);
}

.service-text {
  flex: 1;
}

.service-text strong {
  display: block;
  font-family: var(--font-ui);
  font-size: var(--text-base);
  color: var(--text);
  margin-bottom: var(--space-1);
}

.service-text span {
  font-size: var(--text-sm);
  color: var(--text-muted);
  line-height: 1.6;
}

/* -----------------------------------
   REDISEÑO 2026 — TESTIMONIOS MEJORADOS
   ----------------------------------- */
.testimonio-card {
  background: var(--surface);
  border-radius: var(--radius-2xl);
  padding: var(--space-6);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  position: relative;
  transition: transform var(--duration-base) var(--ease-out),
              box-shadow var(--duration-base) var(--ease-out);
}

.testimonio-card::before {
  content: '"';
  position: absolute;
  top: var(--space-3);
  right: var(--space-4);
  font-family: var(--font-display);
  font-size: 4rem;
  line-height: 1;
  color: var(--border);
  pointer-events: none;
}

.testimonio-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.testimonio-card--donante {
  border-color: var(--secondary);
  background: linear-gradient(135deg, var(--secondary-subtle), var(--surface));
}

.testimonio-header {
  display: flex;
  gap: var(--space-3);
  align-items: center;
  margin-bottom: var(--space-4);
}

.testimonio-avatar {
  width: 52px;
  height: 52px;
  border-radius: var(--radius-full);
  object-fit: cover;
  border: 2px solid var(--accent);
}

.testimonio-avatar--icon {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  border-color: var(--secondary);
  background: var(--secondary-subtle);
}

.testimonio-nombre {
  font-family: var(--font-ui);
  font-size: var(--text-base);
  color: var(--text);
  margin: 0;
  font-weight: 600;
}

.testimonio-rol {
  font-family: var(--font-ui);
  font-size: var(--text-xs);
  color: var(--text-muted);
  margin: 0;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.testimonio-texto {
  margin: 0;
  font-style: italic;
  line-height: 1.7;
  color: var(--text);
  position: relative;
  padding-left: 0;
  border-left: none;
}

.testimonio-texto p {
  margin: 0;
  font-size: var(--text-sm);
}

/* -----------------------------------
   REDISEÑO 2026 — FOOTER MEJORADO
   ----------------------------------- */
.footer-bank {
  text-align: center;
  margin: var(--space-8) auto;
  padding: var(--space-6);
  background: linear-gradient(135deg, var(--accent-subtle), var(--surface));
  border: 1px solid rgba(var(--accent-rgb), 0.2);
  border-radius: var(--radius-xl);
  max-width: 500px;
  position: relative;
}

.footer-bank::before {
  content: '💳';
  position: absolute;
  top: -14px;
  left: 50%;
  transform: translateX(-50%);
  font-size: 1.5rem;
  background: var(--bg-subtle);
  padding: 0 var(--space-2);
}

.footer-bank p {
  text-align: center;
  margin-bottom: var(--space-1);
  font-family: var(--font-ui);
  font-size: var(--text-sm);
}

.footer-bank strong {
  font-size: var(--text-base);
}

.btn-copy {
  margin-top: var(--space-3);
  padding: var(--space-2) var(--space-5);
  background: var(--accent);
  border: none;
  border-radius: var(--radius-full);
  color: #fff;
  font-family: var(--font-ui);
  font-size: var(--text-sm);
  font-weight: 600;
  cursor: pointer;
  transition: transform var(--duration-fast) var(--ease-out),
              box-shadow var(--duration-fast) var(--ease-out);
}

.btn-copy:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 14px rgba(var(--accent-rgb), 0.3);
}

.btn-copy.copied {
  background: #22c55e;
}

/* -----------------------------------
   REDISEÑO 2026 — ANIMACIONES ESCALONADAS
   ----------------------------------- */
.animate-on-scroll {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 700ms var(--ease-out),
              transform 700ms var(--ease-out);
}

.animate-on-scroll.visible {
  opacity: 1;
  transform: translateY(0);
}

.stagger-item {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 500ms var(--ease-out),
              transform 500ms var(--ease-out);
}

.stagger-item.visible {
  opacity: 1;
  transform: translateY(0);
}

.stagger-item:nth-child(1) { transition-delay: 0ms; }
.stagger-item:nth-child(2) { transition-delay: 80ms; }
.stagger-item:nth-child(3) { transition-delay: 160ms; }
.stagger-item:nth-child(4) { transition-delay: 240ms; }
.stagger-item:nth-child(5) { transition-delay: 320ms; }
.stagger-item:nth-child(6) { transition-delay: 400ms; }
.stagger-item:nth-child(7) { transition-delay: 480ms; }
.stagger-item:nth-child(8) { transition-delay: 560ms; }

/* Reveal en cascada para cards */
.cascade-card {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 600ms var(--ease-out),
              transform 600ms var(--ease-out);
}

.cascade-card.visible {
  opacity: 1;
  transform: translateY(0);
}

/* -----------------------------------
   REDISEÑO 2026 — NAV MEJORADA
   ----------------------------------- */
nav ul {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-1);
  list-style: none;
  padding: 0;
  margin: var(--space-4) 0;
  justify-content: center;
}

nav a {
  color: var(--text-muted);
  text-decoration: none;
  font-family: var(--font-ui);
  font-weight: 500;
  font-size: var(--text-sm);
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius-full);
  transition: background var(--duration-fast) var(--ease-out),
              color var(--duration-fast) var(--ease-out);
}

nav a:hover,
nav a:focus-visible {
  background: var(--accent-subtle);
  color: var(--accent);
}

.nav-toggle {
  display: none;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: var(--space-2) var(--space-3);
  font-size: var(--text-xl);
  cursor: pointer;
  color: var(--text);
  line-height: 1;
  transition: background var(--duration-fast) var(--ease-out);
}

.nav-toggle:hover {
  background: var(--accent-subtle);
}

.nav-toggle:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

@media (max-width: 767px) {
  .nav-toggle {
    display: block;
    margin: var(--space-2) auto;
  }

  nav ul {
    display: none;
    flex-direction: column;
    align-items: center;
    gap: var(--space-2);
  }

  nav.open ul {
    display: flex;
  }
}

@media (min-width: 768px) {
  .nav-toggle {
    display: none !important;
  }

  nav ul {
    display: flex !important;
  }
}

/* -----------------------------------
    CONTACT CARDS — versión pulida
    ----------------------------------- */
.contact-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: var(--space-3);
  margin: var(--space-6) 0;
}

.contact-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-5) var(--space-3);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  text-decoration: none;
  color: var(--text);
  font-size: var(--text-sm);
  transition: transform var(--duration-fast) var(--ease-out),
              box-shadow var(--duration-fast) var(--ease-out),
              border-color var(--duration-fast) var(--ease-out);
}

.contact-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
  border-color: var(--accent);
}

.contact-card svg {
  color: var(--accent);
  width: 24px;
  height: 24px;
}

.contact-card strong {
  font-family: var(--font-ui);
  font-size: var(--text-xs);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.contact-card span {
  font-size: var(--text-xs);
  color: var(--text-muted);
  text-align: center;
}

/* -----------------------------------
   MODO ECONÓMICO - Dispositivos gama baja / 3G
   ----------------------------------- */
@media (hover: none) and (max-width: 767px) {
  body {
    background-image: none !important;
  }

  .hero-bg,
  section::before, section::after {
    display: none;
  }

  #hero {
    min-height: auto;
    background: var(--bg);
    padding: var(--space-16) var(--space-4);
  }

  .hero-badge {
    background: var(--accent-subtle);
    color: var(--accent);
    border-color: var(--accent);
    backdrop-filter: none;
  }

  .hero-tagline {
    color: var(--text);
    text-shadow: none;
  }

  .hero-sub {
    color: var(--text-muted);
  }

  .stat-item {
    background: var(--surface);
    color: var(--text-muted);
    border-color: var(--border);
    backdrop-filter: none;
  }

  .stat-item strong {
    color: var(--accent);
  }

  .carousel-item {
    width: 75vw;
  }

  .carousel-item img {
    height: clamp(160px, 45vw, 220px);
  }

  .carousel-btn {
    display: none;
  }

  .rounded-logo {
    cursor: default;
  }

  .rounded-logo.enlarged {
    width: var(--size-logo);
    height: var(--size-logo);
  }

  .stat-item {
    min-width: 140px;
    padding: var(--space-3) var(--space-4);
  }

  .hero-meta {
    color: var(--text-muted);
  }
}

/* -----------------------------------
   REDUCIR MOVIMIENTO - WCAG
   ----------------------------------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  .carousel-section {
    opacity: 1;
    transform: none;
    animation: none;
  }

  .carousel-btn {
    display: none;
  }
}

/* -----------------------------------
   PREFERIR CONTRASTE ALTO - WCAG
   ----------------------------------- */
@media (prefers-contrast: more) {
  :root {
    --border: rgba(0, 0, 0, 0.25);
    --text-muted: var(--text);
  }

  .card, .encuadrada, .carousel-item img {
    border-width: 2px;
  }

  :focus-visible {
    outline-width: 3px;
  }
}

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

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

.image-container {
  margin-bottom: var(--space-4);
}



