/* VARIABLES DE DISEÑO: Colores, tiempos de transición, curvas de animación */
:root {
  --primary: #00b37a; /* Verde principal */
  --primary-dark: #003d82; /* Azul oscuro para contrastes */
  --secondary: #333; /* Gris oscuro para fondos */
  --accent: #ff6b00; /* Naranja para énfasis o íconos */
  --accent-light: #ff8c33; /* Versión clara del acento */
  --light: #f8f9fa; /* Fondo claro general */
  --dark: #212529; /* Texto oscuro */
  --gray: #6c757d; /* Texto secundario o inactivo */
  --light-gray: #e9ecef; /* Bordes o fondos sutiles */
  --transition-speed: 600ms; /* Velocidad por defecto de transiciones */
  --easing: cubic-bezier(
    0.25,
    0.46,
    0.45,
    0.94
  ); /* Curva suave para animaciones */
}

/* RESETEO BÁSICO */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: "Roboto", sans-serif;
  line-height: 1.6;
  color: var(--dark);
  background-color: var(--light);
}

/* CONTENEDOR GENERAL */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

/* TITULOS */
h1,
h2,
h3 {
  font-family: "Montserrat", sans-serif;
  font-weight: 700;
  margin-bottom: 1rem;
  color: var(--primary-dark);
}

h1 {
  font-size: 2.5rem;
  line-height: 1.2;
}

h2 {
  font-size: 2rem;
  border-bottom: 2px solid var(--accent);
  padding-bottom: 0.5rem;
}

h3 {
  font-size: 1.5rem;
  color: var(--primary);
}

h4 {
  font-size: 1.2rem;
  color: var(--primary-dark);
}

/* PÁRRAFOS */
p {
  margin-bottom: 1.2rem;
  font-size: 1.1rem;
}

.subtitle {
  font-size: 1.3rem;
  max-width: 800px;
  margin: 0 auto;
  opacity: 0.9;
  color: rgba(255, 255, 255, 0.9); /* Texto claro sobre fondo oscuro */
}

/* ENCABEZADO DE PÁGINA */
header {
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: white;
  padding: 60px 0 80px;
  text-align: center;
  margin-bottom: 40px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

/* BLOQUE DESTACADO DE FUNCIONES */
.feature-container {
  background: white;
  border-radius: 12px;
  padding: 40px;
  margin: 40px 0;
  box-shadow: 0 5px 25px rgba(0, 0, 0, 0.08);
}

.feature-header {
  display: flex;
  align-items: center;
  margin-bottom: 30px;
  padding-bottom: 20px;
  border-bottom: 2px solid var(--primary);
}

.feature-icon {
  font-size: 3rem;
  color: var(--primary);
  margin-right: 25px;
  min-width: 60px;
  text-align: center;
}

/* CONTENIDO EN DOS COLUMNAS */
.feature-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 30px;
  margin-bottom: 40px;
}

.feature-section {
  margin-bottom: 30px;
}

/* LISTA DE BENEFICIOS */
.benefits-list {
  list-style-type: none;
  padding-left: 0;
}

.benefits-list li {
  position: relative;
  padding-left: 30px;
  margin-bottom: 15px;
  font-size: 1.05rem;
}

.benefits-list li::before {
  content: "\f00c"; /* Check de Font Awesome */
  font-family: "Font Awesome 6 Free";
  font-weight: 900;
  color: var(--accent);
  position: absolute;
  left: 0;
}

/*  LÍNEA DE TIEMPO */
.timeline {
  position: relative;
  max-width: 1000px;
  margin: 40px auto;
  padding: 20px 0;
}

.timeline::before {
  content: "";
  position: absolute;
  width: 3px;
  background: linear-gradient(to bottom, var(--primary), var(--accent));
  top: 0;
  bottom: 0;
  left: 50%;
  margin-left: -1.5px;
  border-radius: 3px;
}

.timeline-item {
  padding: 10px 40px;
  position: relative;
  width: 50%;
  box-sizing: border-box;
}

.timeline-item:nth-child(odd) {
  left: 0;
}
.timeline-item:nth-child(even) {
  left: 50%;
}

.timeline-content {
  padding: 25px;
  background: white;
  border-radius: 8px;
  box-shadow: 0 3px 15px rgba(0, 0, 0, 0.08);
  border-left: 4px solid var(--accent);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.timeline-content:hover {
  transform: translateY(-3px);
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.12);
}

.timeline-item::before {
  content: "";
  position: absolute;
  width: 20px;
  height: 20px;
  background-color: white;
  border: 3px solid var(--accent);
  border-radius: 50%;
  top: 20px;
  z-index: 1;
}

/* Posicionamiento de puntos de la línea de tiempo */
.timeline-item:nth-child(odd)::before {
  right: -10px;
}
.timeline-item:nth-child(even)::before {
  left: -10px;
}

/* CARRUSEL DE IMÁGENES */
.carousel-container {
  width: 100%;
  max-width: 1000px;
  margin: 40px auto;
  position: relative;
}

.carousel {
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.15);
}

.carousel-inner {
  height: 500px;
  background-color: var(--dark);
  overflow: hidden;
  position: relative;
}

.carousel-item {
  position: absolute;
  width: 100%;
  height: 100%;
  opacity: 0;
  transition: opacity var(--transition-speed) var(--easing);
}

.carousel-item.active {
  opacity: 1;
  z-index: 1;
}

.carousel-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: blur(2px);
  transition: filter 0.7s ease;
}

.carousel-item.active img {
  filter: blur(0);
}

/* TEXTO SOBRE IMAGEN */
.carousel-caption {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.911), transparent);
  color: rgba(245, 236, 236, 0.885);
  padding: 30px;
  text-align: center;
  transform: translateY(20px);
  opacity: 0;
  z-index: 2;
  transition: transform 0.5s ease, opacity 0.5s ease;
}

.carousel-item.active .carousel-caption {
  transform: translateY(0);
  opacity: 1;
}

/* CONTROLES DEL CARRUSEL */
.carousel-control {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(255, 255, 255, 0.9);
  color: var(--primary);
  width: 50px;
  height: 50px;
  border-radius: 50%;
  font-size: 1.25rem;
  cursor: pointer;
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 10;
  transition: all 0.3s ease;
}

.carousel-control:hover {
  transform: translateY(-50%) scale(1.1);
}

.carousel-control.prev {
  left: 20px;
}
.carousel-control.next {
  right: 20px;
}

/* INDICADORES (puntos del carrusel) */
.carousel-indicators {
  position: absolute;
  bottom: 20px;
  left: 0;
  right: 0;
  display: flex;
  justify-content: center;
  gap: 12px;
  z-index: 10; /* indicador de carrusel */
}

.indicator {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.5);
  cursor: pointer;
  transition: all 0.3s ease;
  opacity: 0.7;
}

.indicator.active {
  background: var(--accent);
  transform: scale(1.2);
  opacity: 1;
}

/* BOTÓN DE VOLVER */
.back-button {
  display: inline-flex;
  align-items: center;
  background: var(--primary);
  color: white;
  padding: 12px 25px;
  border-radius: 50px;
  font-weight: 500;
  transition: all 0.3s ease;
  margin: 40px auto;
  box-shadow: 0 4px 8px rgba(0, 86, 179, 0.2);
  text-decoration: none;
}

.back-button i {
  margin-right: 8px;
}

.back-button:hover {
  background: var(--primary-dark);
  transform: translateY(-2px);
}

/* PIE DE PÁGINA */
footer {
  background: var(--secondary);
  color: white;
  text-align: center;
  padding: 30px 0;
  margin-top: 60px;
}

footer p {
  margin-bottom: 0.5rem;
  opacity: 0.8;
}

/* RESPONSIVE DESIGN: Ajustes por tamaño de pantalla */
@media (max-width: 992px) {
  .carousel-inner {
    height: 450px;
  }
  .timeline::before {
    left: 31px;
  }
  .timeline-item {
    width: 100%;
    padding-left: 70px;
  }
  .timeline-item:nth-child(even) {
    left: 0;
  }
  .timeline-item::before {
    left: 21px;
  }
}

@media (max-width: 768px) {
  .feature-content {
    grid-template-columns: 1fr;
  }
  .carousel-inner {
    height: 400px;
  }
  .header {
    padding: 40px 0 60px;
  }
}

@media (max-width: 576px) {
  .carousel-inner {
    height: 350px;
  }
  .indicator {
    width: 10px;
    height: 10px;
  }
  .back-button {
    padding: 10px 20px;
    font-size: 0.9rem;
  }
}
