body {
  font-family: 'Poppins', sans-serif;
}

/* Efectos para las tarjetas de cursos */
.course-card {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  background: linear-gradient(145deg, #f3f4f6, #e0e7ff);
  border-radius: 16px;
  overflow: hidden;
  position: relative;
}

.course-card:hover {
  transform: scale(1.05);
  box-shadow: 0 20px 30px rgba(0, 0, 0, 0.2);
}

.course-card img {
  transition: transform 0.3s ease;
}

.course-card:hover img {
  transform: scale(1.1);
}

/* Animaciones de entrada */
.fade-in {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Botones de ejercicios */
.exercise-btn {
  background: linear-gradient(to right, #3b82f6, #1e3a8a);
  color: white;
  padding: 0.75rem 1.5rem;
  border-radius: 9999px;
  transition: background 0.3s ease;
}

.exercise-btn:hover {
  background: linear-gradient(to right, #1e3a8a, #3b82f6);
}
/* Estilos para el sistema de ejercicios */
.exercise-container {
  display: none;
}

.exercise-container:first-child {
  display: block;
}

/* Mejoras para la verificación de respuestas */
.feedback-message {
  font-size: 0.875rem;
  margin-top: 0.25rem;
  display: block;
}

.general-feedback {
  font-weight: 500;
}

/* Estilos para los botones de navegación */
.next-btn, .prev-btn {
  transition: all 0.3s ease;
}

.next-btn:hover, .prev-btn:hover {
  transform: translateY(-2px);
}

/* Mejoras para las redes sociales */
.social-container {
  display: flex;
  justify-content: center;
}

.social-container a {
  transition: transform 0.3s ease;
}

.social-container a:hover {
  transform: scale(1.1);
}
/* Estilos para el sistema de ejercicios */
.exercises-main-container {
  max-width: 800px;
  margin: 0 auto;
  padding: 2rem;
}

.exercise-container {
  display: none;
  background: white;
  border-radius: 0.5rem;
  padding: 1.5rem;
  margin-bottom: 1rem;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.exercise-progress {
  text-align: center;
  margin-bottom: 1rem;
  font-weight: 500;
  color: #4b5563;
}

.answer-input {
  border: 1px solid #d1d5db;
  padding: 0.5rem;
  border-radius: 0.25rem;
  width: 100%;
  max-width: 200px;
}

.feedback-message {
  margin-top: 0.5rem;
  font-size: 0.875rem;
}

.general-feedback {
  margin-top: 1rem;
  font-weight: 500;
}
/* Sistema de ejercicios mejorado */
.exercise-container {
  display: none;
  background: white;
  border-radius: 0.5rem;
  padding: 1.5rem;
  margin-bottom: 1rem;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
  border: 1px solid #e5e7eb;
}

.exercise-container h3 {
  color: #1f2937;
  margin-bottom: 1rem;
}

.answer-input {
  border: 1px solid #d1d5db;
  padding: 0.5rem 0.75rem;
  border-radius: 0.375rem;
  width: 100%;
  max-width: 300px;
  transition: all 0.2s;
}

.answer-input:focus {
  outline: none;
  border-color: #3b82f6;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.border-green-500 {
  border-color: #10b981;
}

.bg-green-50 {
  background-color: #ecfdf5;
}

.border-red-500 {
  border-color: #ef4444;
}

.bg-red-50 {
  background-color: #fef2f2;
}

.feedback-message {
  display: inline-block;
  margin-left: 0.5rem;
  font-size: 0.875rem;
  margin-top: 0.25rem;
}

.score-container {
  background-color: #f8fafc;
  padding: 1rem;
  border-radius: 0.5rem;
}

[disabled] {
  opacity: 0.5;
  cursor: not-allowed;
}
body {
  font-family: 'Poppins', sans-serif;
}

/* Efectos para las tarjetas de cursos */
.course-card {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  background: linear-gradient(145deg, #f3f4f6, #e0e7ff);
  border-radius: 16px;
  overflow: hidden;
  position: relative;
}

.course-card:hover {
  transform: scale(1.05);
  box-shadow: 0 20px 30px rgba(0, 0, 0, 0.2);
}

.course-card img {
  transition: transform 0.3s ease;
}

.course-card:hover img {
  transform: scale(1.1);
}

/* Animaciones de entrada */
.fade-in {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Botones de ejercicios */
.exercise-btn {
  background: linear-gradient(to right, #3b82f6, #1e3a8a);
  color: white;
  padding: 0.75rem 1.5rem;
  border-radius: 9999px;
  transition: background 0.3s ease;
}

.exercise-btn:hover {
  background: linear-gradient(to right, #1e3a8a, #3b82f6);
}

/* Sistema de ejercicios completo */
.exercises-main-container {
  max-width: 800px;
  margin: 2rem auto;
  padding: 2rem;
  background: #f8fafc;
  border-radius: 0.5rem;
  box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

.exercise-container {
  display: none;
  background: white;
  border-radius: 0.5rem;
  padding: 1.5rem;
  margin-bottom: 1.5rem;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
  border: 1px solid #e5e7eb;
}

.exercise-container h3 {
  color: #1f2937;
  margin-bottom: 1rem;
  font-size: 1.25rem;
}

.exercise-progress {
  text-align: center;
  margin-bottom: 1.5rem;
  font-weight: 600;
  color: #4b5563;
  font-size: 1.1rem;
}

.answer-input {
  border: 1px solid #d1d5db;
  padding: 0.5rem 0.75rem;
  border-radius: 0.375rem;
  width: 100%;
  max-width: 300px;
  transition: all 0.2s;
  font-family: 'Poppins', sans-serif;
}

.answer-input:focus {
  outline: none;
  border-color: #3b82f6;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.border-green-500 {
  border-color: #10b981;
}

.bg-green-50 {
  background-color: #ecfdf5;
}

.border-red-500 {
  border-color: #ef4444;
}

.bg-red-50 {
  background-color: #fef2f2;
}

.feedback-message {
  display: inline-block;
  margin-left: 0.5rem;
  font-size: 0.875rem;
  margin-top: 0.5rem;
}

.score-container {
  background-color: #f8fafc;
  padding: 1rem;
  border-radius: 0.5rem;
  text-align: center;
  margin-bottom: 1.5rem;
}

.score-container .score {
  font-weight: 700;
  color: #3b82f6;
}

.exercise-nav {
  display: flex;
  justify-content: space-between;
  margin-top: 2rem;
}

.prev-btn, .next-btn {
  transition: all 0.3s ease;
  padding: 0.75rem 1.5rem;
  border-radius: 0.375rem;
  font-weight: 600;
}

.prev-btn {
  background-color: #4b5563;
  color: white;
}

.next-btn {
  background-color: #3b82f6;
  color: white;
}

.prev-btn:hover, .next-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

[disabled] {
  opacity: 0.5;
  cursor: not-allowed;
}

/* Mejoras para las redes sociales */
.social-container {
  display: flex;
  justify-content: center;
  gap: 1rem;
}

.social-container a {
  transition: transform 0.3s ease;
}

.social-container a:hover {
  transform: scale(1.1);
}
.exercises-main-container {
  max-width: 800px;
  margin: 2rem auto;
  padding: 2rem;
  background: white;
  border-radius: 10px;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.exercise-container {
  margin-bottom: 2rem;
  padding: 1.5rem;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  transition: all 0.3s ease;
}

.exercise-container:hover {
  border-color: #4299e1;
  box-shadow: 0 2px 4px rgba(66, 153, 225, 0.2);
}

.answer-input {
  width: 100%;
  padding: 0.75rem;
  border: 2px solid #cbd5e0;
  border-radius: 6px;
  font-size: 1rem;
}

.answer-input:focus {
  outline: none;
  border-color: #4299e1;
}

.correct {
  background-color: #f0fff4;
  border-color: #68d391;
}

.incorrect {
  background-color: #fff5f5;
  border-color: #fc8181;
}
.dba-badge {
  background-color: #e9d8fd;
  color: #553c9a;
  padding: 8px 12px;
  border-radius: 6px;
  font-size: 0.85rem;
  margin-bottom: 15px;
  display: inline-block;
  font-weight: 500;
  border-left: 3px solid #553c9a;
}
/* Estilos para el modal de puntuación */
.score-modal-overlay {
  animation: fadeIn 0.3s ease-out;
}

.score-modal {
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
}

.circle-chart-circle {
  transition: stroke-dasharray 0.6s ease;
  animation: circle-chart-fill 1s reverse;
}

@keyframes circle-chart-fill {
  to { stroke-dasharray: 0 100; }
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

/* Animación de confeti */
.confetti {
  position: fixed;
  width: 10px;
  height: 10px;
  background-color: #f0f;
  opacity: 0.7;
  animation: confetti-fall 5s linear forwards;
}

@keyframes confetti-fall {
  0% {
    transform: translateY(-100px) rotate(0deg);
    opacity: 1;
  }
  100% {
    transform: translateY(100vh) rotate(720deg);
    opacity: 0;
  }
}
/* ===== ESTILOS BASE RESPONSIVE ===== */
body {
  font-family: 'Poppins', sans-serif;
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

.container {
  width: 100%;
  padding-right: 1rem;
  padding-left: 1rem;
  margin-right: auto;
  margin-left: auto;
}

/* ===== BREAKPOINTS ===== */
/* Pantallas pequeñas (móviles) */
@media (max-width: 640px) {
  .container {
    max-width: 100%;
    padding-right: 0.75rem;
    padding-left: 0.75rem;
  }
}

/* Pantallas medianas (tablets) */
@media (min-width: 641px) and (max-width: 1024px) {
  .container {
    max-width: 90%;
  }
}

/* Pantallas grandes (escritorios) */
@media (min-width: 1025px) {
  .container {
    max-width: 1200px;
  }
}

/* ===== TARJETAS DE CURSOS RESPONSIVE ===== */
.courses-grid {
  display: grid;
  grid-template-columns: repeat(1, 1fr);
  gap: 1.5rem;
  margin: 2rem 0;
}

@media (min-width: 640px) {
  .courses-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .courses-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (min-width: 1280px) {
  .courses-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

.course-card {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  background: linear-gradient(145deg, #f3f4f6, #e0e7ff);
  border-radius: 16px;
  overflow: hidden;
  position: relative;
  height: 100%;
  display: flex;
  flex-direction: column;
}

.course-card:hover {
  transform: scale(1.03);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.15);
}

.course-card img {
  transition: transform 0.3s ease;
  width: 100%;
  height: 180px;
  object-fit: cover;
}

@media (min-width: 768px) {
  .course-card img {
    height: 200px;
  }
}

.course-card:hover img {
  transform: scale(1.05);
}

.course-content {
  padding: 1.25rem;
  flex-grow: 1;
  display: flex;
  flex-direction: column;
}

/* ===== SISTEMA DE EJERCICIOS RESPONSIVE ===== */
.exercises-main-container {
  max-width: 100%;
  margin: 1rem auto;
  padding: 1.25rem;
  background: white;
  border-radius: 10px;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
}

@media (min-width: 640px) {
  .exercises-main-container {
    padding: 1.5rem;
    margin: 1.5rem auto;
  }
}

@media (min-width: 768px) {
  .exercises-main-container {
    max-width: 800px;
    padding: 2rem;
    margin: 2rem auto;
  }
}

.exercise-container {
  margin-bottom: 1.5rem;
  padding: 1.25rem;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  transition: all 0.3s ease;
}

@media (min-width: 640px) {
  .exercise-container {
    padding: 1.5rem;
    margin-bottom: 2rem;
  }
}

.exercise-container:hover {
  border-color: #4299e1;
  box-shadow: 0 2px 4px rgba(66, 153, 225, 0.1);
}

.exercise-progress {
  text-align: center;
  margin-bottom: 1.25rem;
  font-weight: 500;
  color: #4b5563;
  font-size: 1rem;
}

@media (min-width: 640px) {
  .exercise-progress {
    font-size: 1.1rem;
    margin-bottom: 1.5rem;
  }
}

.answer-input {
  width: 100%;
  max-width: 100%;
  padding: 0.75rem;
  border: 2px solid #cbd5e0;
  border-radius: 6px;
  font-size: 1rem;
  margin-bottom: 0.75rem;
}

@media (min-width: 640px) {
  .answer-input {
    max-width: 300px;
  }
}

.answer-input:focus {
  outline: none;
  border-color: #4299e1;
}

/* ===== BOTONES RESPONSIVE ===== */
.exercise-btn {
  background: linear-gradient(to right, #3b82f6, #1e3a8a);
  color: white;
  padding: 0.75rem 1.25rem;
  border-radius: 9999px;
  transition: background 0.3s ease;
  border: none;
  cursor: pointer;
  font-size: 0.9rem;
  width: 100%;
  margin: 0.5rem 0;
}

@media (min-width: 640px) {
  .exercise-btn {
    width: auto;
    margin: 0 0.5rem;
  }
}

.exercise-btn:hover {
  background: linear-gradient(to right, #1e3a8a, #3b82f6);
}

.exercise-nav {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-top: 1.5rem;
}

@media (min-width: 640px) {
  .exercise-nav {
    flex-direction: row;
    justify-content: space-between;
  }
}

.prev-btn, .next-btn {
  transition: all 0.3s ease;
  padding: 0.75rem 1.25rem;
  border-radius: 0.375rem;
  font-weight: 600;
  border: none;
  cursor: pointer;
  font-size: 0.9rem;
  width: 100%;
}

@media (min-width: 640px) {
  .prev-btn, .next-btn {
    width: auto;
    padding: 0.75rem 1.5rem;
  }
}

.prev-btn {
  background-color: #4b5563;
  color: white;
  order: 2;
}

.next-btn {
  background-color: #3b82f6;
  color: white;
  order: 1;
}

@media (min-width: 640px) {
  .prev-btn {
    order: 1;
  }
  .next-btn {
    order: 2;
  }
}

.prev-btn:hover, .next-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

/* ===== FEEDBACK Y PUNTUACIÓN RESPONSIVE ===== */
.feedback-message {
  display: block;
  margin: 0.5rem 0;
  font-size: 0.875rem;
}

.score-container {
  background-color: #f8fafc;
  padding: 1rem;
  border-radius: 0.5rem;
  text-align: center;
  margin-bottom: 1.5rem;
}

.score-container .score {
  font-weight: 700;
  color: #3b82f6;
  font-size: 1.5rem;
}

/* ===== REDES SOCIALES RESPONSIVE ===== */
.social-container {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 1rem;
  margin: 1.5rem 0;
}

.social-container a {
  transition: transform 0.3s ease;
  display: inline-block;
  padding: 0.5rem;
}

.social-container a:hover {
  transform: scale(1.1);
}

/* ===== ANIMACIONES ===== */
.fade-in {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ===== MODAL RESPONSIVE ===== */
.score-modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(0, 0, 0, 0.5);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 1000;
  padding: 1rem;
  animation: fadeIn 0.3s ease-out;
}

.score-modal {
  background: white;
  border-radius: 12px;
  padding: 1.5rem;
  width: 100%;
  max-width: 400px;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.25);
}

/* ===== BADGE RESPONSIVE ===== */
.dba-badge {
  background-color: #e9d8fd;
  color: #553c9a;
  padding: 0.5rem 0.75rem;
  border-radius: 6px;
  font-size: 0.8rem;
  margin-bottom: 1rem;
  display: inline-block;
  font-weight: 500;
  border-left: 3px solid #553c9a;
}

@media (min-width: 640px) {
  .dba-badge {
    padding: 0.6rem 1rem;
    font-size: 0.85rem;
  }
}

/* Estados deshabilitados */
[disabled] {
  opacity: 0.5;
  cursor: not-allowed;
}

/* Variantes de feedback */
.correct {
  background-color: #f0fff4;
  border-color: #68d391;
}

.incorrect {
  background-color: #fff5f5;
  border-color: #fc8181;
}

.border-green-500 {
  border-color: #10b981;
}

.bg-green-50 {
  background-color: #ecfdf5;
}

.border-red-500 {
  border-color: #ef4444;
}

.bg-red-50 {
  background-color: #fef2f2;
}

/* Animaciones de gráficos circulares */
.circle-chart-circle {
  transition: stroke-dasharray 0.6s ease;
  animation: circle-chart-fill 1s reverse;
}

@keyframes circle-chart-fill {
  to { stroke-dasharray: 0 100; }
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

/* Animación de confeti */
.confetti {
  position: fixed;
  width: 10px;
  height: 10px;
  background-color: #f0f;
  opacity: 0.7;
  animation: confetti-fall 5s linear forwards;
}

@keyframes confetti-fall {
  0% {
    transform: translateY(-100px) rotate(0deg);
    opacity: 1;
  }
  100% {
    transform: translateY(100vh) rotate(720deg);
    opacity: 0;
  }
}
    /* Estilos para el menú hamburguesa */
    .hamburger-menu {
      display: none;
      flex-direction: column;
      justify-content: space-around;
      width: 2rem;
      height: 2rem;
      background: transparent;
      border: none;
      cursor: pointer;
      padding: 0;
      z-index: 10;
    }
    
    .hamburger-menu:focus {
      outline: none;
    }
    
    .hamburger-line {
      width: 2rem;
      height: 0.25rem;
      background: white;
      border-radius: 10px;
      transition: all 0.3s linear;
      position: relative;
      transform-origin: 1px;
    }
    
    .mobile-nav {
      position: fixed;
      top: 0;
      right: 0;
      height: 100vh;
      width: 0;
      background: linear-gradient(to bottom, #3b82f6, #1e40af);
      z-index: 40;
      overflow-x: hidden;
      transition: width 0.3s ease;
      padding-top: 5rem;
    }
    
    .mobile-nav.open {
      width: 70%;
    }
    
    .mobile-nav-links {
      display: flex;
      flex-direction: column;
      align-items: center;
      gap: 2rem;
    }
    
    .mobile-nav-links a {
      color: white;
      text-decoration: none;
      font-size: 1.2rem;
      font-weight: 500;
      opacity: 0;
      transform: translateX(50px);
      transition: all 0.3s ease;
    }
    
    .mobile-nav.open .mobile-nav-links a {
      opacity: 1;
      transform: translateX(0);
    }
    
    .overlay {
      position: fixed;
      top: 0;
      left: 0;
      width: 100%;
      height: 100%;
      background: rgba(0, 0, 0, 0.5);
      z-index: 30;
      opacity: 0;
      visibility: hidden;
      transition: all 0.3s ease;
    }
    
    .overlay.open {
      opacity: 1;
      visibility: visible;
    }
    
    /* Media queries para responsividad */
    @media (max-width: 768px) {
      .hamburger-menu {
        display: flex;
      }
      
      nav:not(.mobile-nav) {
        display: none;
      }
      
      .header-cta {
        display: none;
      }
    }
/* ===== TOGGLE DE TEMA ===== */
.theme-toggle-container {
  display: flex;
  align-items: center;
  margin-right: 1rem;
}

.theme-toggle {
  position: relative;
  display: inline-block;
  width: 60px;
  height: 34px;
}

.theme-toggle input {
  opacity: 0;
  width: 0;
  height: 0;
}

.slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #ccc;
  transition: .4s;
  border-radius: 34px;
}

.slider:before {
  position: absolute;
  content: "";
  height: 26px;
  width: 26px;
  left: 4px;
  bottom: 4px;
  background-color: white;
  transition: .4s;
  border-radius: 50%;
}

input:checked + .slider {
  background-color: #3b82f6;
}

input:checked + .slider:before {
  transform: translateX(26px);
}

/* Iconos para el toggle */
.slider:after {
  content: "☀️";
  position: absolute;
  left: 8px;
  top: 6px;
  font-size: 14px;
  opacity: 0;
  transition: opacity 0.2s;
}

input:not(:checked) + .slider:after {
  opacity: 1;
}

.slider:before {
  content: "🌙";
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  background-color: transparent;
}

/* Responsive para el toggle */
@media (max-width: 768px) {
  .theme-toggle-container {
    margin-right: 0.5rem;
  }
  
  .theme-toggle {
    width: 50px;
    height: 28px;
  }
  
  .slider:before {
    height: 20px;
    width: 20px;
  }
  
  input:checked + .slider:before {
    transform: translateX(22px);
  }
}

/* ===== ESTILOS PARA ESTADÍSTICAS ===== */
.user-stats {
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.stat-item {
  padding: 1rem;
  border-radius: 0.5rem;
  background: rgba(255, 255, 255, 0.05);
}

.dark-mode .stat-item {
  background: rgba(0, 0, 0, 0.2);
}

/* ===== MEJORAS DE ACCESIBILIDAD ===== */
@media (prefers-reduced-motion: reduce) {
  .fade-in {
    transition: none;
  }
  
  .score-modal {
    transition: none;
  }
  
  .slider {
    transition: none;
  }
}

/* ===== ESTILOS PARA PROGRESO ANTERIOR ===== */
.previous-progress {
  animation: slideInDown 0.5s ease-out;
}

@keyframes slideInDown {
  from {
    opacity: 0;
    transform: translateY(-20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ===== MEJORAS RESPONSIVAS ===== */
@media (max-width: 640px) {
  .user-stats .grid {
    grid-template-columns: repeat(2, 1fr);
  }
  
  .stat-value {
    font-size: 1.5rem;
  }
}