/* ======= VARIABLES GLOBALES ======= */
:root {
  --color-green: #00a86b;
  --color-purple: #6a0dad;
  --color-light-green: #e6f7f2;
  --color-light-purple: #f0e6fa;
  --color-white: #ffffff;
  --color-black: #333333;
  --color-light-gray: #f4f4f4;
  --color-dark-gray: #333333;
  --color-gray: #64748b;
  --font-size-base: 16px;
  --spacing-base: 1rem;
  --transition-base: all 0.3s ease-in-out;
  --transition-fast: all 0.2s ease;
  --transition-slow: all 0.5s ease;
  --border-radius-sm: 6px;
  --border-radius-md: 10px;
  --border-radius-lg: 15px;
  --border-radius-xl: 30px;
  --shadow-sm: 0 2px 5px rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 15px rgba(106, 13, 173, 0.3);
  --shadow-lg: 0 8px 25px rgba(0, 0, 0, 0.15);
  --shadow-xl: 0 12px 35px rgba(0, 0, 0, 0.2);
  --shadow-light: 0 2px 10px rgba(0, 0, 0, 0.1);
  --shadow-heavy: 0 5px 20px rgba(0, 0, 0, 0.2);
  --gradient-primary: linear-gradient(135deg, var(--color-purple), var(--color-green));
  --gradient-secondary: linear-gradient(135deg, var(--color-light-purple), var(--color-light-green));
  --font-family: "Poppins", sans-serif;
  --line-height: 1.6;
  --h1-size: clamp(1.8rem, 4vw, 2.5rem);
  --h2-size: clamp(1.6rem, 3.5vw, 2.2rem);
  --h3-size: clamp(1.3rem, 3vw, 1.8rem);
  --p-size: clamp(0.95rem, 2vw, 1.1rem);
  --title-color: var(--color-purple);
  --subtitle-color: var(--color-dark-gray);
  --text-color: var(--color-black);
  --text-light-color: #64748b;
  --glass-bg: rgba(255, 255, 255, 0.25);
  --glass-border: rgba(255, 255, 255, 0.18);
}

/* ======= RESET Y BASE ======= */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: var(--font-family);
  line-height: var(--line-height);
  color: var(--text-color);
  background-color: var(--color-white);
  min-height: 100vh;
  overflow-x: hidden;
}

a {
  text-decoration: none;
  color: inherit;
  transition: var(--transition-fast);
}

ul {
  list-style: none;
}

img {
  max-width: 100%;
  height: auto;
}

/* ======= HEADER Y NAVEGACIÓN ======= */
header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(20px);
  padding: 1rem var(--spacing-base);
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: var(--shadow-md);
  border-bottom: 1px solid var(--glass-border);
}

.logo {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.logo h1 {
  margin: 0;
  font-size: clamp(1.2rem, 3vw, 1.5rem);
  color: var(--title-color);
  font-weight: 700;
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* Menú hamburguesa */
#menu-toggle {
  display: block;
  background: var(--gradient-primary);
  border: none;
  cursor: pointer;
  padding: 0.8rem;
  border-radius: 50%;
  box-shadow: var(--shadow-md);
  transition: var(--transition-base);
  z-index: 1001;
}

#menu-toggle:hover {
  transform: scale(1.05);
  box-shadow: var(--shadow-lg);
}

#menu-toggle span {
  display: block;
  width: 25px;
  height: 3px;
  background-color: var(--color-white);
  margin: 4px 0;
  border-radius: 3px;
  transition: var(--transition-base);
}

#menu-toggle.open span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}

#menu-toggle.open span:nth-child(2) {
  opacity: 0;
}

#menu-toggle.open span:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -5px);
}

/* Navegación */
#main-nav {
  display: none;
  flex-direction: column;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(20px);
  position: absolute;
  top: 100%;
  left: 0;
  width: 100%;
  box-shadow: var(--shadow-lg);
  padding: var(--spacing-base);
  border-radius: 0 0 var(--border-radius-md) var(--border-radius-md);
  border: 1px solid var(--glass-border);
}

#main-nav.active {
  display: flex;
  animation: slideDown 0.3s ease-out;
}

#main-nav ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  margin-bottom: var(--spacing-base);
}

#main-nav ul li a {
  text-decoration: none;
  color: var(--text-color);
  font-weight: 500;
  font-size: 1rem;
  padding: 0.75rem var(--spacing-base);
  display: block;
  transition: var(--transition-base);
  border-radius: var(--border-radius-sm);
  position: relative;
  overflow: hidden;
}

#main-nav ul li a::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  height: 100%;
  width: 0;
  background: var(--gradient-primary);
  transition: width 0.3s ease;
  z-index: -1;
}

#main-nav ul li a:hover::before,
#main-nav ul li a.active::before {
  width: 100%;
}

#main-nav ul li a:hover,
#main-nav ul li a.active {
  color: var(--color-white);
  transform: translateX(5px);
}

.user-actions {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  padding-top: var(--spacing-base);
  border-top: 1px solid var(--glass-border);
}

.btn-acceso {
  background: var(--gradient-primary);
  color: var(--color-white);
  padding: 0.75rem 1.5rem;
  text-decoration: none;
  border-radius: var(--border-radius-xl);
  font-weight: 600;
  transition: var(--transition-base);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  text-align: center;
  box-shadow: var(--shadow-md);
  font-size: 0.9rem;
}

.btn-acceso:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

/* ======= ANIMACIONES ======= */
@keyframes slideDown {
  from {
    opacity: 0;
    transform: translateY(-20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes spin {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

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

/* ======= RESPONSIVE ======= */
@media (min-width: 768px) {
  #menu-toggle {
    display: none;
  }

  #main-nav {
    display: flex !important;
    flex-direction: row;
    position: static;
    box-shadow: none;
    width: auto;
    background-color: transparent;
    padding: 0;
    align-items: center;
    backdrop-filter: none;
    border: none;
  }

  #main-nav ul {
    flex-direction: row;
    gap: 2rem;
    margin-bottom: 0;
  }

  #main-nav ul li a {
    padding: 0.5rem 0;
  }

  .user-actions {
    flex-direction: row;
    padding-top: 0;
    border-top: none;
    margin-left: 2rem;
  }
}

/* ======= HERO SECTION ======= */
.hero {
  position: relative;
  height: 100vh;
  min-height: 800px;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

.carousel {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
}

.slide {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  opacity: 0;
  transition: opacity 1s ease-in-out;
  will-change: opacity;
}

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

.slide-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    45deg,
    rgba(106, 13, 173, 0.7) /* Purple overlay */,
    rgba(0, 168, 107, 0.7) /* Green overlay */,
    rgba(106, 13, 173, 0.7)
  ); /* Purple overlay */
  background-size: 300% 300%;
  animation: gradientAnimation 8s ease infinite;
}

@keyframes gradientAnimation {
  0% {
    background-position: 0% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
  100% {
    background-position: 0% 50%;
  }
}

.contenido-hero {
  position: relative;
  z-index: 3;
  width: 100%;
  max-width: 1200px;
  padding: 0 2rem;
  text-align: center;
  color: var(--color-white);
}

.hero-text {
  margin: 0 auto;
  max-width: 800px;
}

.typing-container {
  min-height: 120px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.typing-container h2 {
  font-size: clamp(2rem, 5vw, 3.5rem);
  line-height: 1.2;
  margin-bottom: 1.5rem;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.typing {
  display: block;
  opacity: 0;
  animation: typingFadeIn 0.5s forwards;
  animation-delay: calc(var(--typing-order) * 0.5s);
}

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

.hero-subtitle {
  font-size: clamp(1rem, 2vw, 1.5rem);
  margin: 0 auto 2rem;
  max-width: 600px;
  opacity: 0.9;
  text-shadow: 0 1px 5px rgba(0, 0, 0, 0.2);
  animation: fadeInUp 1s ease-out 1s both;
}

.hero-cta {
  display: flex;
  justify-content: center;
  gap: 1.5rem;
  margin-top: 2rem;
  animation: fadeInUp 1s ease-out 1.5s both;
}

.btn-hero {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 1rem 2rem;
  border-radius: var(--border-radius-xl);
  font-weight: 600;
  font-size: 1rem;
  transition: var(--transition-base);
  box-shadow: var(--shadow-md);
}

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

.btn-primary:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-lg);
}

/* Carousel Controls */
.carousel-controls {
  position: absolute;
  top: 50%;
  left: 0;
  right: 0;
  transform: translateY(-50%);
  display: flex;
  justify-content: space-between;
  padding: 0 2rem;
  z-index: 4;
  pointer-events: none;
}

.carousel-prev,
.carousel-next {
  pointer-events: auto;
  background: rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(10px);
  color: var(--color-white);
  width: 50px;
  height: 50px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  border: none;
  cursor: pointer;
  transition: var(--transition-base);
  box-shadow: var(--shadow-sm);
}

.carousel-prev:hover,
.carousel-next:hover {
  background: rgba(255, 255, 255, 0.3);
  transform: scale(1.1);
}

.carousel-indicators {
  position: absolute;
  bottom: 2rem;
  left: 0;
  right: 0;
  display: flex;
  justify-content: center;
  gap: 0.75rem;
  z-index: 4;
}

.indicator {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.5);
  border: none;
  cursor: pointer;
  transition: var(--transition-base);
  padding: 0;
}

.indicator.active {
  background: var(--color-white);
  transform: scale(1.2);
}

/* Floating icons */
.floating-icons {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 2;
}

.floating-icon {
  position: absolute;
  color: rgba(255, 255, 255, 0.15);
  font-size: clamp(1.5rem, 3vw, 2.5rem);
  animation: float 10s infinite ease-in-out;
  opacity: 0;
  animation-delay: 2s;
}

@keyframes float {
  0%,
  100% {
    transform: translateY(0) rotate(0deg);
    opacity: 0.15;
  }
  50% {
    transform: translateY(-20px) rotate(5deg);
    opacity: 0.25;
  }
}

.icon-1 {
  top: 15%;
  left: 10%;
  animation-delay: 2.2s;
}
.icon-2 {
  top: 70%;
  left: 15%;
  animation-delay: 2.4s;
}
.icon-3 {
  top: 40%;
  left: 80%;
  animation-delay: 2.6s;
}
.icon-4 {
  top: 80%;
  left: 75%;
  animation-delay: 2.8s;
}
.icon-5 {
  top: 30%;
  left: 50%;
  animation-delay: 3s;
}
.icon-6 {
  top: 60%;
  left: 40%;
  animation-delay: 3.2s;
}

/* Scroll down button */
.scroll-down {
  position: absolute;
  bottom: 1.5rem;
  left: 50%;
  transform: translateX(-50%);
  color: var(--color-white);
  font-size: 1.5rem;
  animation: bounce 2s infinite;
  z-index: 4;
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(5px);
  width: 50px;
  height: 50px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  border: none;
  cursor: pointer;
  transition: var(--transition-base);
}

.scroll-down:hover {
  background: rgba(255, 255, 255, 0.2);
  transform: translateX(-50%) scale(1.1);
}

@keyframes bounce {
  0%,
  20%,
  50%,
  80%,
  100% {
    transform: translateY(0) translateX(-50%);
  }
  40% {
    transform: translateY(-15px) translateX(-50%);
  }
  60% {
    transform: translateY(-7px) translateX(-50%);
  }
}

/* Responsive */
@media (max-width: 768px) {
  .hero {
    min-height: 700px;
  }

  .carousel-controls {
    padding: 0 1rem;
  }

  .carousel-prev,
  .carousel-next {
    width: 40px;
    height: 40px;
  }

  .typing-container {
    min-height: 100px;
  }

  .hero-cta {
    flex-direction: column;
    gap: 1rem;
  }

  .btn-hero {
    width: 100%;
    max-width: 300px;
    margin: 0 auto;
  }
}

@media (max-width: 480px) {
  .hero {
    min-height: 600px;
  }

  .contenido-hero {
    padding: 0 1.5rem;
  }

  .typing-container h2 {
    margin-bottom: 1rem;
  }

  .hero-subtitle {
    margin-bottom: 1.5rem;
  }

  .floating-icon {
    display: none;
  }

  .scroll-down {
    width: 40px;
    height: 40px;
    font-size: 1.2rem;
  }
}

/* Section Styles */
.section-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 5rem 2rem;
}

.section-header {
  text-align: center;
  margin-bottom: 3rem;
}

.section-title {
  position: relative;
  display: inline-block;
  padding-bottom: 0.5rem;
}

.section-title::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 50px;
  height: 3px;
  background-color: var(--color-green);
}

.section-subtitle {
  color: var(--color-gray);
  max-width: 700px;
  margin: 0 auto 1rem;
}

.section-divider {
  height: 1px;
  background-color: rgba(0, 0, 0, 0.1);
  margin: 2rem auto;
  max-width: 100px;
}

/* Benefits Section */
.contenedor-beneficios {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
}

.beneficio-card {
  background-color: var(--color-white);
  border-radius: 10px;
  padding: 2rem;
  text-align: center;
  box-shadow: var(--shadow-light);
  transition: var(--transition-fast);
  position: relative;
  overflow: hidden;
}

.beneficio-card:hover {
  transform: translateY(-10px);
  box-shadow: var(--shadow-heavy);
}

.beneficio-icon-container {
  margin-bottom: 1.5rem;
}

.icon-circle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background-color: var(--color-light-green);
  color: var(--color-green);
  font-size: 1.8rem;
}

.beneficio-card:nth-child(2n) .icon-circle {
  background-color: var(--color-light-purple);
  color: var(--color-purple);
}

.beneficio-hover {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: var(--color-green);
  color: var(--color-white);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  opacity: 0;
  transition: var(--transition-fast);
  border-radius: 10px;
}

.beneficio-card:hover .beneficio-hover {
  opacity: 1;
}

/* Courses Section */
.curso-tabs {
  display: flex;
  justify-content: center;
  gap: 1rem;
  margin-bottom: 2rem;
  flex-wrap: wrap;
}

.tab-btn {
  padding: 0.5rem 1.5rem;
  border-radius: 30px;
  background-color: var(--color-light-green);
  color: var(--color-green);
  border: none;
  cursor: pointer;
  transition: var(--transition-fast);
  font-weight: 500;
}

.tab-btn.active {
  background-color: var(--color-green);
  color: var(--color-white);
}

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

.curso-card {
  background-color: var(--color-white);
  border-radius: 10px;
  overflow: hidden;
  box-shadow: var(--shadow-light);
  transition: var(--transition-fast);
}

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

.curso-img-container {
  position: relative;
  height: 200px;
  overflow: hidden;
}

.curso-imagen {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: var(--transition-slow);
}

.curso-card:hover .curso-imagen {
  transform: scale(1.1);
}

.curso-badge {
  position: absolute;
  top: 1rem;
  right: 1rem;
  background-color: var(--color-purple);
  color: var(--color-white);
  padding: 0.3rem 0.8rem;
  border-radius: 30px;
  font-size: 0.8rem;
  font-weight: 600;
}

.curso-content {
  padding: 1.5rem;
}

.curso-meta {
  display: flex;
  gap: 1rem;
  margin: 0.5rem 0;
  font-size: 0.9rem;
  color: var(--color-gray);
}

/* ======= SISTEMA DE MODALES MEJORADO ======= */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.8);
  backdrop-filter: blur(5px);
  z-index: 9998;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
}

.modal-overlay.active {
  opacity: 1;
  visibility: visible;
}

.curso-detalle-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
}

.curso-detalle-modal.active {
  opacity: 1;
  visibility: visible;
}

.modal-content {
  background: var(--color-white);
  border-radius: var(--border-radius-lg);
  max-width: 900px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  position: relative;
  box-shadow: var(--shadow-xl);
  transform: scale(0.9);
  opacity: 0;
  transition: all 0.3s ease;
}

.curso-detalle-modal.active .modal-content {
  transform: scale(1);
  opacity: 1;
}

.modal-close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  background: rgba(0, 0, 0, 0.1);
  border: none;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: var(--transition-fast);
  z-index: 10;
}

.modal-close:hover {
  background: rgba(0, 0, 0, 0.2);
  transform: scale(1.1);
}

.modal-close i {
  font-size: 1.2rem;
  color: var(--color-gray);
}

.modal-header {
  padding: 2rem 2rem 1rem;
  text-align: center;
  border-bottom: 1px solid var(--color-light-gray);
}

.modal-header h2 {
  font-size: clamp(1.5rem, 3vw, 2rem);
  color: var(--color-purple);
  margin-bottom: 0.5rem;
  line-height: 1.3;
}

.modal-subtitle {
  color: var(--color-gray);
  font-size: 1.1rem;
  margin: 0;
}

.modal-body {
  padding: 2rem;
}

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

.curso-info-box {
  background: linear-gradient(135deg, var(--color-light-green), var(--color-light-purple));
  padding: 1.5rem;
  border-radius: var(--border-radius-md);
  border-left: 4px solid var(--color-green);
  transition: var(--transition-fast);
}

.curso-info-box:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-light);
}

.curso-info-box h3 {
  color: var(--color-purple);
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 1.2rem;
}

.curso-info-box h3 i {
  color: var(--color-green);
  font-size: 1.1rem;
}

.curso-list {
  list-style: none;
  padding: 0;
}

.curso-list li {
  margin-bottom: 0.8rem;
  position: relative;
  padding-left: 1.5rem;
  line-height: 1.5;
}

.curso-list li::before {
  content: "✓";
  position: absolute;
  left: 0;
  top: 0;
  color: var(--color-green);
  font-weight: bold;
  font-size: 1.1rem;
}

.curso-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1.5rem;
  margin-top: 2rem;
}

.stat-item {
  background: var(--color-white);
  padding: 1.5rem;
  border-radius: var(--border-radius-md);
  text-align: center;
  box-shadow: var(--shadow-sm);
  border: 2px solid var(--color-light-purple);
  transition: var(--transition-fast);
}

.stat-item:hover {
  border-color: var(--color-purple);
  transform: translateY(-2px);
}

.stat-item i {
  font-size: 2rem;
  color: var(--color-green);
  margin-bottom: 1rem;
}

.stat-item h4 {
  color: var(--color-purple);
  margin-bottom: 0.5rem;
  font-size: 1.1rem;
}

.stat-item p {
  color: var(--color-gray);
  margin: 0;
  line-height: 1.4;
}

.modal-footer {
  padding: 1.5rem 2rem 2rem;
  display: flex;
  gap: 1rem;
  justify-content: center;
  border-top: 1px solid var(--color-light-gray);
}

.modal-action {
  background: var(--gradient-primary);
  color: var(--color-white);
  padding: 0.75rem 2rem;
  border-radius: var(--border-radius-xl);
  border: none;
  cursor: pointer;
  font-weight: 600;
  transition: var(--transition-base);
  box-shadow: var(--shadow-md);
}

.modal-action:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

/* Available Courses */
.filtros-cursos {
  display: flex;
  gap: 1rem;
  margin-bottom: 2rem;
  flex-wrap: wrap;
  justify-content: center;
}

.filtro-group {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.filtro-select {
  padding: 0.5rem 1rem;
  border-radius: 5px;
  border: 1px solid #ddd;
  background-color: var(--color-white);
}

/* About Us */
.quienes-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
}

.quienes-timeline {
  position: relative;
  padding-left: 2rem;
}

.quienes-timeline::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  width: 3px;
  background-color: var(--color-purple);
}

.timeline-item {
  position: relative;
  margin-bottom: 2rem;
  padding-left: 1.5rem;
}

.timeline-item::before {
  content: "";
  position: absolute;
  top: 0.5rem;
  left: -0.5rem;
  width: 15px;
  height: 15px;
  border-radius: 50%;
  background-color: var(--color-green);
  border: 3px solid var(--color-purple);
}

.timeline-year {
  font-weight: 700;
  color: var(--color-purple);
  margin-bottom: 0.5rem;
}

.quienes-valores {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.valores-item {
  background-color: var(--color-light-purple);
  padding: 1.5rem;
  border-radius: 10px;
  border-left: 4px solid var(--color-purple);
}

.valores-item h3 {
  color: var(--color-purple);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.quienes-cta {
  text-align: center;
  margin-top: 3rem;
}

/* Gallery */
.galeria-contenedor {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 1.5rem;
}

.galeria-item {
  position: relative;
  border-radius: 8px;
  overflow: hidden;
  height: 200px;
}

.galeria-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: var(--transition-slow);
}

.galeria-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(106, 13, 173, 0.7);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: var(--transition-fast);
}

.galeria-overlay i {
  color: var(--color-white);
  font-size: 2rem;
}

.galeria-item:hover .galeria-overlay {
  opacity: 1;
}

.galeria-item:hover img {
  transform: scale(1.1);
}

.galeria-cta {
  text-align: center;
  margin-top: 3rem;
}

/* Loader */
.loader-container {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: var(--color-white);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  transition: var(--transition-slow);
}

.loader-container.loaded {
  opacity: 0;
  pointer-events: none;
}

.loader-spinner {
  width: 50px;
  height: 50px;
  border: 5px solid var(--color-light-purple);
  border-top-color: var(--color-purple);
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin-bottom: 1rem;
}

.loader-progress {
  font-weight: 600;
  color: var(--color-purple);
  margin-bottom: 0.5rem;
}

.loader-message {
  color: var(--color-gray);
}

/* ======= ESTILOS DE BOTONES ======= */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.75rem 1.75rem;
  border-radius: var(--border-radius-xl);
  font-weight: 600;
  font-size: 1rem;
  transition: var(--transition-base);
  cursor: pointer;
  border: none;
  text-align: center;
  box-shadow: var(--shadow-sm);
  position: relative;
  overflow: hidden;
}

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

.btn-secondary:hover {
  background: var(--color-light-purple);
  transform: translateY(-3px);
  box-shadow: var(--shadow-light);
}

.btn-ver-mas {
  background: var(--gradient-primary);
  color: var(--color-white);
  padding: 0.75rem 2rem;
  border-radius: var(--border-radius-xl);
  font-weight: 600;
  text-decoration: none;
  transition: var(--transition-base);
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  box-shadow: var(--shadow-md);
}

.btn-ver-mas:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-lg);
}

.btn-curso {
  background: var(--gradient-primary);
  color: var(--color-white);
  padding: 0.5rem 1.5rem;
  border-radius: var(--border-radius-xl);
  font-weight: 600;
  border: none;
  cursor: pointer;
  transition: var(--transition-base);
  width: 100%;
  margin-top: 1rem;
  box-shadow: var(--shadow-sm);
}

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

/* ======= TÍTULOS MEJORADOS ======= */
h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: "Poppins", sans-serif;
  font-weight: 700;
  line-height: 1.3;
  margin-top: 0;
  color: var(--color-purple);
  position: relative;
}

h1 {
  font-size: clamp(1.8rem, 4vw, 2.5rem);
  background: linear-gradient(135deg, var(--color-purple), var(--color-green));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 0.5rem;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

h2.section-title {
  font-size: clamp(1.8rem, 4vw, 2.3rem);
  text-align: center;
  margin-bottom: 1.5rem;
  padding-bottom: 1rem;
  position: relative;
}

h2.section-title::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 80px;
  height: 4px;
  background: linear-gradient(90deg, var(--color-purple), var(--color-green));
  border-radius: 2px;
}

h3 {
  font-size: clamp(1.3rem, 3vw, 1.6rem);
  margin-bottom: 1rem;
  color: var(--color-dark-gray);
}

.hero h2 {
  font-size: clamp(2rem, 6vw, 3.5rem);
  color: var(--color-white);
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
  margin-bottom: 1.5rem;
  line-height: 1.2;
}

.beneficio-card h3 {
  font-size: 1.4rem;
  color: var(--color-purple);
  margin-bottom: 1rem;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid var(--color-light-green);
}

.curso-content h3 {
  font-size: 1.4rem;
  background: linear-gradient(135deg, var(--color-purple), var(--color-green));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 0.8rem;
}

/* Responsive */
@media (max-width: 992px) {
  .quienes-grid {
    grid-template-columns: 1fr;
  }

  .timeline-item::before {
    left: -0.4rem;
  }

  .modal-content {
    margin: 1rem;
    max-height: 95vh;
  }

  .curso-contenido {
    grid-template-columns: 1fr;
  }

  .curso-stats {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .hero {
    height: auto;
    padding: 8rem 0 4rem;
  }

  .hero-text h2 {
    font-size: 2.2rem;
  }

  .hero-subtitle {
    font-size: 1.2rem;
  }

  .hero-cta {
    flex-direction: column;
    align-items: center;
  }

  .modal-header {
    padding: 1.5rem 1.5rem 1rem;
  }

  .modal-body {
    padding: 1.5rem;
  }

  .modal-footer {
    padding: 1rem 1.5rem 1.5rem;
    flex-direction: column;
  }

  .curso-detalle-modal {
    padding: 1rem;
  }
}

@media (max-width: 576px) {
  .hero-text h2 {
    font-size: 1.8rem;
  }

  .hero-subtitle {
    font-size: 1rem;
  }

  .section-container {
    padding: 3rem 1rem;
  }

  .filtros-cursos {
    flex-direction: column;
    align-items: stretch;
  }

  .modal-close {
    top: 0.5rem;
    right: 0.5rem;
    width: 35px;
    height: 35px;
  }

  .modal-header h2 {
    font-size: 1.5rem;
    padding-right: 3rem;
  }
}

/* Animaciones adicionales para modales */
@keyframes modalFadeIn {
  from {
    opacity: 0;
    transform: scale(0.8) translateY(-50px);
  }
  to {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

@keyframes overlayFadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

.curso-detalle-modal.active {
  animation: modalFadeIn 0.4s ease-out;
}

.modal-overlay.active {
  animation: overlayFadeIn 0.3s ease-out;
}

/* Scroll personalizado para modales */
.modal-content::-webkit-scrollbar {
  width: 8px;
}

.modal-content::-webkit-scrollbar-track {
  background: var(--color-light-gray);
  border-radius: 4px;
}

.modal-content::-webkit-scrollbar-thumb {
  background: var(--color-purple);
  border-radius: 4px;
}

.modal-content::-webkit-scrollbar-thumb:hover {
  background: var(--color-green);
}
