/* ============================================
   Casa Infantil AMMI - Design System
   Identidad visual basada en Manual de Marca AMMI
   ============================================ */

/* ===== CSS Variables ===== */
:root {
  /* Colors - AMMI Brand Manual */
  --primary: #00AEEF;
  /* Cyan - principal */
  --primary-light: #e0f4fd;
  --primary-foreground: #ffffff;

  --secondary: #EC008C;
  /* Magenta - acentos */
  --secondary-light: #fce0ef;
  --secondary-foreground: #ffffff;

  --accent: #8DC63F;
  /* Verde - esperanza */
  --accent-light: #e8f5d6;
  --accent-foreground: #ffffff;

  --purple: #92278F;
  /* Púrpura - complemento */
  --purple-light: #f0e0f0;

  --background: #ffffff;
  /* Blanco limpio */
  --foreground: #333333;
  /* Texto oscuro */
  --foreground-muted: #939598;
  /* Gris manual */

  --white: #ffffff;
  --border: #e5e5e5;

  /* Typography */
  --font-display: 'Cabin Sketch', cursive;
  --font-body: 'Lora', Georgia, serif;

  /* Spacing */
  --container-max: 1200px;
  --section-py: 5rem;
  --section-py-lg: 8rem;

  /* Transitions */
  --transition-fast: 0.2s ease;
  --transition-normal: 0.3s ease;
  --transition-slow: 0.5s ease;

  /* Shadows */
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.08);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.1);
  --shadow-lg: 0 8px 30px rgba(0, 0, 0, 0.12);

  /* Border Radius */
  --radius-sm: 0.5rem;
  --radius-md: 1rem;
  --radius-lg: 1.5rem;
  --radius-xl: 2rem;
}

/* ===== Reset & Base ===== */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 100px;
  /* Offset for fixed header */
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.7;
  color: var(--foreground);
  background-color: var(--background);
}

img {
  max-width: 100%;
  height: auto;
  display: block;
  border-radius: var(--radius-lg);
}

a {
  color: inherit;
  text-decoration: none;
}

ul,
ol {
  list-style: none;
}

button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none;
}

/* ===== Typography ===== */
h1,
h2,
h3,
h4 {
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.2;
  color: var(--foreground);
}

h1 {
  font-size: clamp(2.25rem, 5vw, 3.5rem);
  letter-spacing: -0.02em;
}

h2,
.section-title {
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  margin-bottom: 1.5rem;
}

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

h4 {
  font-size: 1.125rem;
  margin-bottom: 0.5rem;
}

p {
  margin-bottom: 1rem;
}

.text-primary {
  color: var(--primary);
}

.text-secondary {
  color: var(--secondary);
}

.text-accent {
  color: var(--accent);
}

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

.font-semibold {
  font-weight: 600;
}

.section-subtitle {
  font-size: 1.125rem;
  color: var(--foreground-muted);
  max-width: 600px;
  margin: 0 auto 3rem;
}

/* ===== Container ===== */
.container {
  width: 100%;
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 1.5rem;
}

@media (min-width: 768px) {
  .container {
    padding: 0 2rem;
  }
}

/* ===== Buttons ===== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.75rem 1.5rem;
  font-size: 1rem;
  font-weight: 600;
  border-radius: var(--radius-sm);
  transition: all var(--transition-normal);
  cursor: pointer;
  white-space: nowrap;
}

.btn-lg {
  padding: 1rem 2rem;
  font-size: 1.0625rem;
}

.btn-primary {
  background-color: var(--primary);
  color: var(--primary-foreground);
}

.btn-primary:hover {
  background-color: #0098d1;
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

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

.btn-outline:hover {
  background-color: var(--secondary-light);
}

.btn-secondary {
  background-color: var(--secondary);
  color: var(--secondary-foreground);
}

.btn-secondary:hover {
  background-color: #c70076;
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.btn-white {
  background-color: var(--white);
  color: var(--primary);
}

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

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

.btn-outline-white:hover {
  background-color: rgba(255, 255, 255, 0.1);
}

.btn .icon {
  width: 1.25rem;
  height: 1.25rem;
}

/* Header */
header {
  background-color: var(--white);
  box-shadow: var(--shadow-sm);
  position: sticky;
  top: 0;
  z-index: 1000;
  transition: padding 0.3s ease, box-shadow 0.3s ease;
}

header.scrolled {
  box-shadow: var(--shadow-md);
  padding: 0.5rem 0;
}

/* ===== Navbar ===== */
.navbar {
  padding: 1rem 0;
  transition: all var(--transition-normal);
}

.navbar.scrolled {
  background-color: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  box-shadow: var(--shadow-sm);
}

.navbar-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

/* Logo */
.logo {
  display: flex;
  align-items: center;
}

.logo img {
  height: 50px;
  width: auto;
  transition: transform 0.3s ease;
}

.logo img:hover {
  transform: scale(1.05);
}

@media (min-width: 768px) {
  .logo img {
    height: 60px;
  }
}

/* Footer Logo */
.footer-logo {
  max-width: 200px;
  height: auto;
  margin-bottom: 1rem;
  display: block;
}

/* Navigation — oculto en móvil (se abre con el botón hamburguesa); flex en ≥768px */
.nav-links {
  list-style: none;
  display: none;
  gap: 2rem;
  align-items: center;
}

.nav-link {
  font-weight: 500;
  transition: color var(--transition-fast);
  position: relative;
}

.nav-link:hover {
  color: var(--primary);
}

/* Dropdown Menu */
.dropdown {
  position: relative;
}

.dropdown-menu {
  position: absolute;
  top: 100%;

  left: 0;
  background: var(--white);
  box-shadow: var(--shadow-md);
  border-radius: var(--radius-sm);

  padding: 0.5rem 0;
  min-width: 180px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
  transition: all var(--transition-fast);
  z-index: 100;
}

.dropdown:hover .dropdown-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.dropdown-item {
  display: block;
  padding: 0.75rem 1.5rem;
  color: var(--text-base);
  transition: background-color var(--transition-fast), color var(--transition-fast);
}

.dropdown-item:hover {
  background-color: var(--background);
  color: var(--primary);
}

.mobile-menu-btn {
  display: flex;
  flex-direction: column;
  gap: 5px;
  padding: 0.5rem;
}

.mobile-menu-btn span {
  width: 24px;
  height: 2px;
  background-color: var(--foreground);
  transition: all var(--transition-fast);
}

.mobile-menu-btn.active span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}

.mobile-menu-btn.active span:nth-child(2) {
  opacity: 0;
}

.mobile-menu-btn.active span:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -5px);
}

@media (min-width: 768px) {
  .nav-links {
    display: flex;
  }

  .mobile-menu-btn {
    display: none;
  }
}

/* Mobile Menu */
.nav-links.active {
  display: flex;
  flex-direction: column;
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: var(--white);
  padding: 2rem;
  box-shadow: var(--shadow-md);
  gap: 1.5rem;
}

/* ===== Carousel Section ===== */
.carousel {
  position: relative;
  height: 50vh;
  width: 100%;
  margin: 0 auto;
  overflow: hidden;
  background-color: var(--foreground);
}

@media (min-width: 768px) {
  .carousel {
    height: 60vh;
  }
}

.carousel-track-container {
  height: 100%;
  width: 100%;
  position: relative;
}

.carousel-track {
  padding: 0;
  margin: 0;
  list-style: none;
  position: relative;
  height: 100%;
  width: 100%;
}

.carousel-slide {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  transition: opacity 0.8s ease-in-out;
  z-index: 1;
}

.carousel-slide.current-slide {
  opacity: 1;
  z-index: 2;
}

.carousel-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

/* Gradient Overlay */
.carousel-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(to bottom,
      rgba(0, 0, 0, 0.1) 0%,
      rgba(0, 0, 0, 0.4) 50%,
      rgba(0, 0, 0, 0.6) 100%);
  z-index: 3;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
}

.carousel-title {
  font-family: var(--font-display);
  font-size: clamp(2rem, 6vw, 4rem);
  color: var(--white);
  text-align: center;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
  animation: fadeUp 1s ease-out;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(15px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Glassmorphism Navigation Buttons */
.carousel-button {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.25);
  cursor: pointer;
  z-index: 10;
  border-radius: 50%;
  width: 2.5rem;
  height: 2.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s ease, transform 0.2s ease;
  color: var(--white);
}

.carousel-button:hover {
  background: rgba(255, 255, 255, 0.3);
}

.carousel-button:active {
  transform: translateY(-50%) scale(0.95);
}

.carousel-button svg {
  width: 1.25rem;
  height: 1.25rem;
}

.carousel-button--left {
  left: 12px;
}

.carousel-button--right {
  right: 12px;
}

@media (min-width: 768px) {
  .carousel-button {
    width: 3rem;
    height: 3rem;
  }

  .carousel-button svg {
    width: 1.5rem;
    height: 1.5rem;
  }

  .carousel-button--left {
    left: 24px;
  }

  .carousel-button--right {
    right: 24px;
  }
}

/* Progress Bar */
.carousel-progress {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 3px;
  background: rgba(255, 255, 255, 0.2);
  z-index: 10;
}

.carousel-progress-bar {
  height: 100%;
  background: var(--white);
  width: 0%;
  animation: progressFill 5s linear infinite;
}

@keyframes progressFill {
  from {
    width: 0%;
  }

  to {
    width: 100%;
  }
}

/* Dot Indicators (simplified) */
.carousel-nav {
  position: absolute;
  bottom: 16px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 10px;
  z-index: 10;
}

.carousel-indicator {
  border: 0;
  border-radius: 50%;
  width: 8px;
  height: 8px;
  background: rgba(255, 255, 255, 0.4);
  cursor: pointer;
  transition: background 0.2s ease, transform 0.2s ease;
}

.carousel-indicator.current-slide {
  background: var(--white);
  transform: scale(1.3);
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  .carousel-slide {
    transition: none;
  }

  .carousel-title {
    animation: none;
  }

  .carousel-progress-bar {
    animation: none;
    width: 100%;
  }
}

/* ===== Hero Section ===== */
.hero {
  padding-top: 8rem;
  padding-bottom: 5rem;
  background: linear-gradient(180deg, var(--background) 0%, var(--white) 100%);
  overflow: hidden;
}

@media (min-width: 768px) {
  .hero {
    padding-top: 12rem;
    padding-bottom: 8rem;
  }
}

.hero-grid {
  display: grid;
  gap: 3rem;
  align-items: center;
}

@media (min-width: 768px) {
  .hero-grid {
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
  }
}

.hero-content {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.hero-text {
  font-size: 1.125rem;
  color: var(--foreground-muted);
  line-height: 1.8;
}

.hero-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

.hero-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  padding-top: 2rem;
  border-top: 1px solid var(--border);
}

.stat-number {
  font-family: var(--font-display);
  font-size: 2rem;
  font-weight: 700;
}

.stat-label {
  font-size: 0.875rem;
  color: var(--foreground-muted);
  margin: 0;
}

.hero-image {
  display: none;
}

@media (min-width: 768px) {
  .hero-image {
    display: block;
  }

  .hero-image img {
    box-shadow: var(--shadow-lg);
  }
}

/* ===== Journey Section ===== */
.journey {
  padding: var(--section-py) 0;
  background: linear-gradient(180deg, var(--white) 0%, var(--background) 100%);
}

@media (min-width: 768px) {
  .journey {
    padding: var(--section-py-lg) 0;
  }
}

.journey-nav {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  margin-bottom: 3rem;
  flex-wrap: wrap;
}

@media (min-width: 768px) {
  .journey-nav {
    gap: 1rem;
  }
}

.journey-nav-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  padding: 1rem 1.25rem;
  border-radius: var(--radius-md);
  background: var(--white);
  transition: all var(--transition-normal);
  border: 2px solid transparent;
}

.journey-nav-btn:hover {
  border-color: var(--primary-light);
}

.journey-nav-btn.active {
  border-color: var(--primary);
  background: var(--primary-light);
}

.journey-nav-icon {
  width: 2rem;
  height: 2rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

.journey-nav-icon svg {
  width: 1.5rem;
  height: 1.5rem;
  color: var(--primary);
}

.journey-nav-text {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--foreground);
}

/* Journey Stages */
.journey-stage {
  display: none;
  animation: fadeIn 0.5s ease;
}

.journey-stage.active {
  display: block;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.journey-stage-content {
  display: grid;
  gap: 2rem;
  align-items: center;
  background: var(--white);
  border-radius: var(--radius-xl);
  padding: 2rem;
  box-shadow: var(--shadow-md);
}

@media (min-width: 768px) {
  .journey-stage-content {
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    padding: 3rem;
  }
}

.journey-stage-label {
  font-size: 0.875rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.journey-stage-title {
  font-size: 1.75rem;
  margin-bottom: 1rem;
}

.journey-narrative {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-style: italic;
  color: var(--foreground);
  padding: 1.5rem;
  margin: 1.5rem 0;
  background: var(--background);
  border-left: 4px solid var(--primary);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
}

.journey-description {
  color: var(--foreground-muted);
  font-size: 1.0625rem;
  margin: 0;
}

.journey-stage-image img {
  border-radius: var(--radius-lg);
}

.journey-intro {
  max-width: 800px;
  margin: 0 auto 3rem;
  text-align: center;
}

.journey-philosophy {
  margin-top: 1.5rem;
  font-size: 1.125rem;
  color: var(--foreground);
  line-height: 1.7;
}

.journey-philosophy p {
  margin-bottom: 1rem;
}

/* ===== Manifesto Section ===== */
.manifesto {
  padding: var(--section-py) 0;
  background: var(--white);
}

@media (min-width: 768px) {
  .manifesto {
    padding: var(--section-py-lg) 0;
  }
}

.manifesto-content {
  max-width: 800px;
  margin: 0 auto;
  text-align: center;
}

.manifesto-text {
  font-size: 1.125rem;
  color: var(--foreground-muted);
  line-height: 1.9;
}

.manifesto-text p {
  margin-bottom: 1.5rem;
}

.manifesto-highlight {
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--foreground);
}

/* ===== Approach Section ===== */
.approach {
  padding: var(--section-py) 0;
  background: linear-gradient(180deg, var(--white) 0%, var(--background) 100%);
}

@media (min-width: 768px) {
  .approach {
    padding: var(--section-py-lg) 0;
  }
}

.approach-grid {
  display: grid;
  gap: 1.5rem;
  margin-top: 3rem;
}

@media (min-width: 640px) {
  .approach-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .approach-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

.approach-card {
  background: var(--white);
  border-radius: var(--radius-lg);
  padding: 2rem;
  box-shadow: var(--shadow-sm);
  transition: all var(--transition-normal);
}

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

.approach-icon {
  width: 3rem;
  height: 3rem;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1rem;
}

.approach-icon svg {
  width: 1.5rem;
  height: 1.5rem;
}

.bg-primary-light {
  background-color: var(--primary-light);
}

.bg-secondary-light {
  background-color: var(--secondary-light);
}

.bg-accent-light {
  background-color: var(--accent-light);
}

.approach-card p {
  color: var(--foreground-muted);
  font-size: 0.9375rem;
  margin: 0;
}

/* ===== Family Connection Section ===== */
.family-connection {
  padding: var(--section-py) 0;
  background: linear-gradient(180deg, var(--white) 0%, var(--background) 100%);
}

@media (min-width: 768px) {
  .family-connection {
    padding: var(--section-py-lg) 0;
  }
}

.family-grid {
  display: grid;
  gap: 3rem;
  align-items: center;
}

@media (min-width: 768px) {
  .family-grid {
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
  }

  .family-content {
    order: 1;
  }

  .family-image {
    order: 2;
  }
}

.family-intro {
  font-size: 1.125rem;
  color: var(--foreground-muted);
  margin-bottom: 2rem;
}

.family-list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.family-list li {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
}

.check-icon {
  width: 1.5rem;
  height: 1.5rem;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--white);
  font-size: 0.75rem;
  font-weight: 700;
  flex-shrink: 0;
  margin-top: 0.125rem;
}

.bg-primary {
  background-color: var(--primary);
}

.bg-secondary {
  background-color: var(--secondary);
}

.bg-accent {
  background-color: var(--accent);
}

.family-image img {
  box-shadow: var(--shadow-lg);
}

/* ===== Impact Section ===== */
.impact {
  padding: var(--section-py) 0;
  background: var(--white);
}

@media (min-width: 768px) {
  .impact {
    padding: var(--section-py-lg) 0;
  }
}

.impact-stats {
  display: grid;
  gap: 2rem;
  margin: 3rem 0;
}

@media (min-width: 768px) {
  .impact-stats {
    grid-template-columns: repeat(3, 1fr);
    gap: 3rem;
  }
}

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

.impact-number {
  font-family: var(--font-display);
  font-size: 3.5rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
}

@media (min-width: 768px) {
  .impact-number {
    font-size: 4rem;
  }
}

.impact-label {
  font-size: 1.0625rem;
  color: var(--foreground-muted);
  margin: 0;
}

.impact-message {
  background: linear-gradient(135deg, var(--primary-light) 0%, var(--secondary-light) 100%);
  border-radius: var(--radius-xl);
  padding: 3rem;
  text-align: center;
}

.impact-message p {
  font-size: 1.25rem;
  color: var(--foreground-muted);
  margin: 0;
  line-height: 1.8;
}

/* ===== Hope Section ===== */
.hope {
  padding: var(--section-py) 0;
  background: linear-gradient(180deg, var(--white) 0%, var(--background) 100%);
}

@media (min-width: 768px) {
  .hope {
    padding: var(--section-py-lg) 0;
  }
}

.hope-grid {
  display: grid;
  gap: 3rem;
  align-items: center;
}

@media (min-width: 768px) {
  .hope-grid {
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
  }
}

.hope-content {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.hope-content p {
  font-size: 1.125rem;
  color: var(--foreground-muted);
  line-height: 1.8;
  margin: 0;
}

.hope-image img {
  box-shadow: var(--shadow-lg);
}

/* ===== CTA Section ===== */
.cta {
  padding: var(--section-py) 0;
  background: var(--primary);
  text-align: center;
}

@media (min-width: 768px) {
  .cta {
    padding: var(--section-py-lg) 0;
  }
}

.cta-title {
  color: var(--white);
  margin-bottom: 1.5rem;
}

.cta-text {
  font-size: 1.25rem;
  color: rgba(255, 255, 255, 0.9);
  max-width: 700px;
  margin: 0 auto 2rem;
  line-height: 1.8;
}

.cta-buttons {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 1rem;
  padding-top: 1rem;
}

/* ===== Footer ===== */
.footer {
  background: var(--background);
  padding: 3rem 0 2rem;
  border-top: 1px solid var(--border);
}

.footer-grid {
  display: grid;
  gap: 2rem;
  margin-bottom: 2rem;
}

@media (min-width: 768px) {
  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }

  .footer-contact {
    text-align: right;
  }
}

.footer-logo {
  font-family: var(--font-display);
  color: var(--primary);
  margin-bottom: 0.5rem;
}

.footer-tagline {
  font-size: 0.875rem;
  color: var(--foreground-muted);
  margin: 0;
}

.footer-contact h4 {
  font-family: var(--font-body);
  color: var(--foreground);
  margin-bottom: 0.5rem;
}

.footer-contact p {
  font-size: 0.875rem;
  color: var(--foreground-muted);
  margin: 0;
}

.footer-contact a {
  transition: color var(--transition-fast);
}

.footer-contact a:hover {
  color: var(--primary);
}

.footer-location {
  font-size: 0.75rem;
}

.footer-bottom {
  border-top: 1px solid var(--border);
  padding-top: 2rem;
  text-align: center;
}

.footer-bottom p {
  font-size: 0.875rem;
  color: var(--foreground-muted);
  margin: 0;
}

/* ===== Animations ===== */
.fade-in {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ===== Utilities ===== */
@media (max-width: 767px) {
  .hide-mobile {
    display: none !important;
  }
}

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

/* ============================================
   Subpage Styles (moved from inline <style>)
   ============================================ */

/* ===== Page Hero (Subpages) ===== */
.page-hero {
  color: var(--white);
  padding: 8rem 0 4rem;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.page-hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg, rgba(0, 0, 0, 0.2) 0%, rgba(0, 0, 0, 0) 100%);
  z-index: 1;
}

.page-hero .container {
  position: relative;
  z-index: 2;
}

.page-hero h1 {
  font-size: 3.5rem;
  margin-bottom: 1rem;
}

.page-hero p {
  font-size: 1.25rem;
  max-width: 600px;
  margin: 0 auto;
  opacity: 0.9;
}

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

/* ===== Timeline (Historia) ===== */
.timeline {
  position: relative;
  max-width: 800px;
  margin: 0 auto;
  padding: 2rem 0;
}

.timeline::after {
  content: '';
  position: absolute;
  width: 2px;
  background-color: var(--secondary-light);
  top: 0;
  bottom: 0;
  left: 50%;
  margin-left: -1px;
}

.timeline-item {
  padding: 10px 40px;
  position: relative;
  width: 50%;
  opacity: 0;
  transform: translateY(20px);
  transition: all 0.6s ease;
}

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

.timeline-item::after {
  content: '';
  position: absolute;
  width: 20px;
  height: 20px;
  right: -10px;
  background-color: var(--white);
  border: 4px solid var(--secondary);
  top: 15px;
  border-radius: 50%;
  z-index: 1;
}

.left {
  left: 0;
}

.right {
  left: 50%;
}

.left::before {
  content: " ";
  height: 0;
  position: absolute;
  top: 22px;
  width: 0;
  z-index: 1;
  right: 30px;
  border: medium solid white;
  border-width: 10px 0 10px 10px;
  border-color: transparent transparent transparent white;
}

.right::before {
  content: " ";
  height: 0;
  position: absolute;
  top: 22px;
  width: 0;
  z-index: 1;
  left: 30px;
  border: medium solid white;
  border-width: 10px 10px 10px 0;
  border-color: transparent white transparent transparent;
}

.right::after {
  left: -10px;
}

.timeline-content {
  padding: 20px 30px;
  background-color: white;
  position: relative;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-md);
}

.timeline-year {
  color: var(--secondary);
  font-weight: 800;
  font-size: 1.5rem;
  margin-bottom: 0.5rem;
  font-family: var(--font-display);
}

@media screen and (max-width: 600px) {
  .timeline::after {
    left: 31px;
  }

  .timeline-item {
    width: 100%;
    padding-left: 70px;
    padding-right: 25px;
  }

  .timeline-item::after {
    left: 21px;
  }

  .left::after,
  .right::after {
    left: 21px;
  }

  .right {
    left: 0;
  }

  .left::before,
  .right::before {
    left: 60px;
    border: medium solid white;
    border-width: 10px 10px 10px 0;
    border-color: transparent white transparent transparent;
  }
}

/* ===== Team Grid (Equipo) ===== */
.team-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
  padding: 4rem 0;
}

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

.team-img-container {
  width: 100%;
  height: 300px;
  background-color: #eee;
  border-radius: var(--radius-md);
  margin-bottom: 1rem;
  overflow: hidden;
  position: relative;
}

.team-img-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: var(--background);
  font-size: 3rem;
}

.team-name {
  font-family: var(--font-display);
  font-size: 1.25rem;
  color: var(--secondary);
}

.team-title {
  color: var(--primary);
  font-size: 0.9rem;
  font-weight: 700;
}

/* ===== Member Cards (Patronato) ===== */
.grid-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 2rem;
  padding: 4rem 0;
}

.member-card {
  background: var(--white);
  padding: 2rem;
  border-radius: var(--radius-lg);
  text-align: center;
  box-shadow: var(--shadow-sm);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

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

.member-avatar {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  background-color: var(--secondary-light);
  margin: 0 auto 1.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2.5rem;
  color: var(--secondary);
  font-family: var(--font-display);
}

.member-name {
  font-family: var(--font-display);
  font-size: 1.5rem;
  color: var(--secondary);
  margin-bottom: 0.5rem;
}

.member-role {
  color: var(--primary);
  font-weight: 700;
  text-transform: uppercase;
  font-size: 0.875rem;
  margin-bottom: 1rem;
  letter-spacing: 1px;
}

/* ===== Logos Grid (Socios) ===== */
.logos-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 3rem;
  align-items: center;
  padding: 4rem 0;
  text-align: center;
}

.logo-placeholder {
  height: 100px;
  background-color: #f0f0f0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  color: var(--foreground-muted);
  border: 2px dashed #ddd;
  border-radius: var(--radius-md);
  opacity: 0.7;
  transition: opacity 0.3s ease;
}

.logo-placeholder:hover {
  opacity: 1;
}

/* Logos reales de aliados */
.socio-logo {
  height: 130px;
  background: var(--white);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.socio-logo:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-md);
}

.socio-logo img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}

/* ===== Animación escalonada (stagger) para grids al hacer scroll ===== */
[data-stagger] > * {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

[data-stagger].in > * {
  opacity: 1;
  transform: none;
}

[data-stagger].in > *:nth-child(1) { transition-delay: 0s; }
[data-stagger].in > *:nth-child(2) { transition-delay: 0.08s; }
[data-stagger].in > *:nth-child(3) { transition-delay: 0.16s; }
[data-stagger].in > *:nth-child(4) { transition-delay: 0.24s; }
[data-stagger].in > *:nth-child(5) { transition-delay: 0.32s; }
[data-stagger].in > *:nth-child(6) { transition-delay: 0.40s; }
[data-stagger].in > *:nth-child(7) { transition-delay: 0.48s; }
[data-stagger].in > *:nth-child(8) { transition-delay: 0.56s; }

@media (prefers-reduced-motion: reduce) {
  [data-stagger] > * {
    opacity: 1;
    transform: none;
    transition: none;
  }
}

/* Salvaguarda: si JavaScript está deshabilitado, el contenido SIEMPRE visible */
@media (scripting: none) {
  [data-stagger] > * {
    opacity: 1;
    transform: none;
  }
}

/* ===== Verse & Values (Ministerio) ===== */
.verse-card {
  background-color: white;
  padding: 3rem;
  margin: 4rem auto;
  max-width: 800px;
  border-left: 5px solid var(--accent);
  box-shadow: var(--shadow-md);
  font-family: var(--font-display);
  font-size: 1.5rem;
  line-height: 1.6;
  color: var(--secondary);
  text-align: center;
}

.values-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
  margin-bottom: 4rem;
}

.value-item h3 {
  color: var(--accent);
  margin-bottom: 0.5rem;
}

/* ===== Join Options (Ser AMMI) ===== */
.join-options {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
  margin: -3rem 0 4rem;
  position: relative;
  z-index: 10;
}

.join-card {
  background: white;
  padding: 2.5rem;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  text-align: center;
  transition: transform 0.3s ease;
}

.join-card:hover {
  transform: translateY(-10px);
}

.icon-circle {
  width: 80px;
  height: 80px;
  background: var(--background);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  margin: 0 auto 1.5rem;
}

.requirements-list {
  text-align: left;
  margin: 1.5rem 0;
  padding-left: 1.5rem;
}

.requirements-list li {
  margin-bottom: 0.5rem;
}

/* ===== Blog ===== */
.blog-hero {
  background-color: var(--background);
  padding: 8rem 0 4rem;
  text-align: center;
}

.blog-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 2rem;
  padding: 4rem 0;
}

.blog-card {
  background: white;
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  display: flex;
  flex-direction: column;
}

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

.blog-img {
  height: 200px;
  background-color: #eee;
  object-fit: cover;
  width: 100%;
}

.blog-content {
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.blog-tag {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--primary);
  font-weight: 700;
  margin-bottom: 0.5rem;
}

.blog-title {
  font-size: 1.25rem;
  margin-bottom: 0.75rem;
}

.btn-link {
  color: var(--primary);
  margin-top: auto;
  font-weight: 600;
  transition: color var(--transition-fast);
}

.btn-link:hover {
  text-decoration: underline;
}

/* ===== Article (Blog Posts) ===== */
.article-hero {
  background-size: cover;
  background-position: center;
  color: white;
  padding: 10rem 0 6rem;
  text-align: center;
}

.article-content {
  max-width: 800px;
  margin: 0 auto;
  padding: 4rem 1.5rem;
  font-size: 1.125rem;
  line-height: 1.8;
  color: var(--foreground);
}

.article-content h2 {
  margin-top: 2.5rem;
  color: var(--primary);
}

.article-content p {
  margin-bottom: 1.5rem;
}

.article-content img {
  width: 100%;
  border-radius: var(--radius-md);
  margin: 2rem 0;
}

.author-box {
  background: #f9fafb;
  padding: 2rem;
  border-radius: var(--radius-md);
  margin-top: 4rem;
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

.author-img {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background: #ddd;
}

/* ===== Testimonials ===== */
.testimonial-slider {
  max-width: 900px;
  margin: 4rem auto;
  position: relative;
  padding: 2rem;
  background: white;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  text-align: center;
}

.testimonial-slide {
  display: none;
  animation: fadeIn 0.5s ease;
}

.testimonial-slide.active {
  display: block;
}

.quote-icon {
  font-size: 4rem;
  color: var(--primary-light);
  line-height: 1;
  margin-bottom: 1rem;
  font-family: serif;
}

.testimonial-text {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-style: italic;
  color: var(--foreground);
  margin-bottom: 2rem;
  line-height: 1.6;
}

.testimonial-author {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
}

.author-avatar {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background-color: var(--background);
  object-fit: cover;
}

.author-info h4 {
  margin: 0;
  color: var(--primary);
}

.author-info p {
  margin: 0;
  font-size: 0.9rem;
  color: var(--foreground-muted);
}

.slider-controls {
  display: flex;
  justify-content: center;
  gap: 1rem;
  margin-top: 2rem;
}

.control-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--background);
  cursor: pointer;
  transition: background 0.3s;
}

.control-dot.active {
  background: var(--primary);
}

/* ===== Transparency Grid ===== */
.transparency-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 2rem;
  padding: 2rem 0;
}

.transparency-card {
  background: var(--white);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  cursor: pointer;
  transition: transform var(--transition-normal), box-shadow var(--transition-normal);
}

.transparency-card:hover {
  transform: scale(1.05);
  box-shadow: var(--shadow-lg);
}

.transparency-img {
  width: 100%;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background-color: #f0f0f0;
}

.transparency-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 0;
}

.transparency-info {
  padding: 1.25rem;
  text-align: center;
}

.transparency-info h3 {
  font-family: var(--font-display);
  font-size: 1.125rem;
  color: var(--purple);
  margin-bottom: 0.25rem;
}

.transparency-info p {
  font-size: 0.875rem;
  color: var(--foreground-muted);
  margin: 0 0 0.25rem;
}

/* Card as link (PDF download) */
a.transparency-card {
  display: block;
  text-decoration: none;
  color: inherit;
}

.transparency-info p a {
  color: var(--primary);
  text-decoration: underline;
}

/* ===== About / Quiénes somos ===== */
.about {
  padding: 5rem 0;
  background-color: var(--background);
}

.about-content {
  max-width: 800px;
  margin: 0 auto;
}

.about-text {
  font-size: 1.0625rem;
  line-height: 1.8;
  color: var(--foreground-muted);
  margin-top: 1.25rem;
}

/* ===== Donaciones en especie ===== */
.especie-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 1.5rem;
  padding: 2rem 0;
}

.especie-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
  text-align: center;
}

.especie-item img {
  width: 72px;
  height: 72px;
  object-fit: contain;
}

.especie-item span {
  font-size: 0.95rem;
  color: var(--foreground);
}

/* ===== Lightbox ===== */
.lightbox-overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.85);
  z-index: 2000;
  align-items: center;
  justify-content: center;
}

.lightbox-overlay.active {
  display: flex;
}

.lightbox-img {
  max-width: 90vw;
  max-height: 90vh;
  object-fit: contain;
  border-radius: var(--radius-sm);
}

.lightbox-close {
  position: absolute;
  top: 1.5rem;
  right: 1.5rem;
  background: none;
  border: none;
  color: var(--white);
  font-size: 2.5rem;
  cursor: pointer;
  line-height: 1;
  transition: transform var(--transition-fast);
}

.lightbox-close:hover {
  transform: scale(1.2);
}

/* ===== WhatsApp Contact Widget ===== */
.wa-widget {
  position: fixed;
  bottom: 1.25rem;
  right: 1.25rem;
  z-index: 1000;
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  background: #25d366;
  color: #fff;
  padding: 0.85rem 1.15rem;
  border-radius: 999px;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.25);
  text-decoration: none;
  font-family: var(--font-body);
  font-weight: 700;
  animation: waPulse 2.5s infinite;
  transition: transform 0.25s ease, box-shadow 0.25s ease, background 0.25s ease;
}

.wa-widget:hover {
  background: #1ebe5b;
  transform: translateY(-2px);
  box-shadow: 0 8px 26px rgba(0, 0, 0, 0.3);
}

.wa-widget-icon {
  width: 28px;
  height: 28px;
  fill: currentColor;
  flex-shrink: 0;
}

.wa-widget-label {
  white-space: nowrap;
  font-size: 0.95rem;
}

@keyframes waPulse {
  0%   { box-shadow: 0 0 0 0 rgba(37, 211, 102, 0.55); }
  70%  { box-shadow: 0 0 0 14px rgba(37, 211, 102, 0); }
  100% { box-shadow: 0 0 0 0 rgba(37, 211, 102, 0); }
}

/* Compacto (solo ícono) en móvil — tap target cómodo de 56px */
@media (max-width: 768px) {
  .wa-widget {
    bottom: 1rem;
    right: 1rem;
    width: 56px;
    height: 56px;
    padding: 0;
    justify-content: center;
  }
  .wa-widget-label { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  .wa-widget { animation: none; }
}

/* ===== Ajustes de comodidad en móvil ===== */
/* Salvaguarda contra scroll horizontal accidental */
html, body { overflow-x: hidden; }

@media (max-width: 767px) {
  /* Botones grandes: que el texto envuelva y nunca excedan el ancho */
  .btn {
    max-width: 100%;
    white-space: normal;
    text-align: center;
  }
  .btn-lg {
    width: 100%;
  }
  .hero-buttons,
  .cta-buttons {
    flex-direction: column;
    align-items: stretch;
  }
  /* No tapar el último contenido con el widget de WhatsApp */
  .footer { padding-bottom: 6rem; }
}