/* ==========================================================================
   ENO TRANSFORMACIÓN INTELIGENTE - HOJA DE ESTILOS PRINCIPAL (style.css)
   Diseño: Premium Dark Glassmorphism, Neon Accents, Responsive, 3D Animations
   ========================================================================== */

/* --- 1. CONFIGURACIÓN DEL SISTEMA DE DISEÑO --- */
:root {
  /* Tipografías */
  --font-headers: 'Outfit', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;

  /* Paleta de Colores HSL (Neon y Premium) */
  --bg-main: 222 47% 6%;         /* #020617 (Slate 950) */
  --bg-sidebar: 224 71% 4%;      /* #010413 (Deep dark slate) */
  --bg-card: 222 47% 11%;        /* #090e24 */
  --bg-glass: 222 47% 11% / 0.55; /* Transparencia con blur */
  --border-glass: 255 255 255 / 0.07;
  --border-glass-focus: 255 255 255 / 0.15;

  /* Colores Acento */
  --color-primary: 161 94% 30%;   /* #047857 (Emerald 700) */
  --color-primary-glow: 162 84% 42%; /* #10b981 (Emerald 500) */
  --color-blue: 217 91% 60%;      /* #3b82f6 (Electric Blue) */
  --color-blue-glow: 213 94% 68%; /* #60a5fa (Light Blue) */
  --color-purple: 263 90% 51%;    /* #7c3aed (Deep Purple) */
  --color-purple-glow: 262 89% 65%; /* #a78bfa (Violet Glow) */
  --color-danger: 0 84% 60%;      /* #ef4444 */
  --color-warning: 38 92% 50%;    /* #f59e0b */

  /* Colores de Texto */
  --text-primary: 210 40% 98%;   /* Blanco sedoso */
  --text-secondary: 215 20% 74%; /* Gris claro */
  --text-muted: 217 10% 50%;     /* Gris oscuro */

  /* Espaciado y Bordes */
  --radius-sm: 8px;
  --radius-md: 16px;
  --radius-lg: 24px;
  --radius-xl: 32px;
  --transition-fast: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-normal: 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-slow: 0.6s cubic-bezier(0.4, 0, 0.2, 1);
  --shadow-neon-green: 0 0 20px hsla(162, 84%, 42%, 0.15);
  --shadow-neon-blue: 0 0 20px hsla(217, 91%, 60%, 0.15);
  --shadow-neon-purple: 0 0 20px hsla(263, 90%, 51%, 0.15);
  
  --sidebar-width: 280px;
}

/* --- 2. RESETS Y ESTILOS GENERALES --- */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
  background-color: hsl(var(--bg-main));
}

body {
  font-family: var(--font-body);
  background-color: hsl(var(--bg-main));
  color: hsl(var(--text-primary));
  min-height: 100vh;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  line-height: 1.6;
}

/* Barra de desplazamiento personalizada */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}
::-webkit-scrollbar-track {
  background: hsl(var(--bg-main));
}
::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.1);
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: rgba(255, 255, 255, 0.2);
}

/* --- 3. LAYOUT / ESTRUCTURA DE LA APP (SPA) --- */
.app-container {
  display: flex;
  min-height: 100vh;
  position: relative;
}

/* Sidebar Desktop */
.sidebar {
  width: var(--sidebar-width);
  background-color: hsl(var(--bg-sidebar));
  border-right: 1px solid rgba(var(--border-glass));
  position: fixed;
  top: 0;
  bottom: 0;
  left: 0;
  z-index: 100;
  display: flex;
  flex-direction: column;
  padding: 2rem 1.5rem;
  transition: var(--transition-normal);
}

.logo-area {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 3rem;
}

.logo-icon {
  background: linear-gradient(135deg, hsl(var(--color-primary-glow)), hsl(var(--color-blue-glow)));
  color: #020617;
  font-family: var(--font-headers);
  font-weight: 800;
  font-size: 1.25rem;
  width: 42px;
  height: 42px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-sm);
  box-shadow: 0 4px 15px rgba(16, 185, 129, 0.3);
}

.logo-text {
  display: flex;
  flex-direction: column;
}

.logo-title {
  font-family: var(--font-headers);
  font-weight: 700;
  font-size: 1.15rem;
  line-height: 1.1;
  letter-spacing: -0.5px;
}

.logo-subtitle {
  font-size: 0.75rem;
  color: hsl(var(--color-primary-glow));
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
}

.nav-menu {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  flex-grow: 1;
}

.nav-link {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.85rem 1rem;
  color: hsl(var(--text-secondary));
  text-decoration: none;
  border-radius: var(--radius-md);
  font-weight: 500;
  font-size: 0.95rem;
  transition: var(--transition-fast);
  border: 1px solid transparent;
}

.nav-icon {
  width: 20px;
  height: 20px;
  fill: currentColor;
}

.nav-link:hover {
  color: hsl(var(--text-primary));
  background-color: rgba(255, 255, 255, 0.03);
}

.nav-link.active {
  color: hsl(var(--text-primary));
  background: rgba(16, 185, 129, 0.08);
  border: 1px solid rgba(16, 185, 129, 0.25);
  box-shadow: var(--shadow-neon-green);
}

.sidebar-footer {
  margin-top: auto;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.footer-site-link {
  font-size: 0.8rem;
  color: hsl(var(--text-muted));
  text-decoration: none;
  transition: var(--transition-fast);
  text-align: center;
}

.footer-site-link:hover {
  color: hsl(var(--color-primary-glow));
}

.footer-whatsapp-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  background-color: #25d366;
  color: #000;
  text-decoration: none;
  font-size: 0.85rem;
  font-weight: 700;
  padding: 0.75rem;
  border-radius: var(--radius-md);
  transition: var(--transition-fast);
  box-shadow: 0 4px 15px rgba(37, 211, 102, 0.2);
}

.footer-whatsapp-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(37, 211, 102, 0.3);
}

.w-icon {
  width: 18px;
  height: 18px;
}

/* Contenido Principal */
.main-content {
  flex-grow: 1;
  margin-left: var(--sidebar-width);
  padding: 3rem 4rem;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* Cabeceras y Pestañas móviles */
.mobile-header {
  display: none;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.5rem;
  background-color: hsl(var(--bg-sidebar));
  border-bottom: 1px solid rgba(var(--border-glass));
  position: sticky;
  top: 0;
  z-index: 101;
}

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

.logo-icon-sm {
  background: linear-gradient(135deg, hsl(var(--color-primary-glow)), hsl(var(--color-blue-glow)));
  color: #020617;
  font-family: var(--font-headers);
  font-weight: 800;
  font-size: 0.9rem;
  padding: 4px 6px;
  border-radius: 4px;
}

.logo-title-sm {
  font-family: var(--font-headers);
  font-weight: 700;
  font-size: 0.95rem;
}

.menu-toggle {
  background: none;
  border: none;
  color: hsl(var(--text-primary));
  cursor: pointer;
}

.mobile-nav-bar {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background-color: hsl(var(--bg-sidebar));
  backdrop-filter: blur(20px);
  border-top: 1px solid rgba(var(--border-glass));
  z-index: 99;
  justify-content: space-around;
  padding: 0.6rem 0.25rem;
}

.mobile-nav-link {
  display: flex;
  flex-direction: column;
  align-items: center;
  color: hsl(var(--text-secondary));
  text-decoration: none;
  font-size: 0.65rem;
  font-weight: 500;
  gap: 0.25rem;
  transition: var(--transition-fast);
}

.mobile-nav-icon {
  width: 20px;
  height: 20px;
}

.mobile-nav-link.active {
  color: hsl(var(--color-primary-glow));
}

/* --- 4. CLASES DE COMPONENTES DE INTERFAZ GENERALES (GLASSMORPHISM) --- */
.card {
  background: hsl(var(--bg-glass));
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(var(--border-glass));
  border-radius: var(--radius-lg);
  padding: 2rem;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.25);
  transition: border-color var(--transition-fast), transform var(--transition-fast), box-shadow var(--transition-fast);
  position: relative;
  overflow: hidden;
}

.card:hover {
  border-color: rgba(var(--border-glass-focus));
}

/* Botones Premium */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.85rem 1.75rem;
  border-radius: var(--radius-md);
  font-family: var(--font-headers);
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  transition: var(--transition-fast);
  text-decoration: none;
  border: none;
  gap: 0.5rem;
}

.btn-sm {
  padding: 0.55rem 1.15rem;
  font-size: 0.85rem;
  border-radius: var(--radius-sm);
}

.btn-primary {
  background: linear-gradient(135deg, hsl(var(--color-primary-glow)), #059669);
  color: #020617;
  box-shadow: 0 4px 15px rgba(16, 185, 129, 0.25);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(16, 185, 129, 0.4);
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.05);
  color: hsl(var(--text-primary));
  border: 1px solid rgba(var(--border-glass));
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(var(--border-glass-focus));
  transform: translateY(-2px);
}

.btn-whatsapp {
  background-color: #25d366;
  color: #000;
  font-weight: 700;
}

.btn-whatsapp:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(37, 211, 102, 0.3);
}

.btn-circle {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(var(--border-glass));
  color: hsl(var(--text-primary));
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: var(--transition-fast);
}

.btn-circle:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(var(--border-glass-focus));
  transform: scale(1.05);
}

.btn-circle:disabled {
  opacity: 0.3;
  cursor: not-allowed;
  transform: none;
}

/* SPA View Controller */
.app-view {
  display: none;
  opacity: 0;
  transition: opacity var(--transition-normal) ease;
  flex-grow: 1;
}

.app-view.active {
  display: flex;
  flex-direction: column;
  opacity: 1;
}

/* Headers de Vistas */
.view-header {
  margin-bottom: 2.5rem;
}

.header-badge {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: hsl(var(--color-primary-glow));
  margin-bottom: 0.75rem;
  background: rgba(16, 185, 129, 0.08);
  padding: 4px 12px;
  border-radius: 50px;
  border: 1px solid rgba(16, 185, 129, 0.15);
}

.view-title {
  font-family: var(--font-headers);
  font-weight: 800;
  font-size: 2.5rem;
  letter-spacing: -1px;
  line-height: 1.2;
  margin-bottom: 0.75rem;
  background: linear-gradient(135deg, hsl(var(--text-primary)) 40%, rgba(255, 255, 255, 0.7));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.view-subtitle {
  color: hsl(var(--text-secondary));
  font-size: 1.1rem;
  max-width: 800px;
}

.section-title {
  font-family: var(--font-headers);
  font-size: 1.5rem;
  font-weight: 700;
  margin-top: 3rem;
  margin-bottom: 1.5rem;
  position: relative;
  display: inline-block;
}

/* --- 5. DETALLE VISTA 1: INICIO (DASHBOARD) --- */
.welcome-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: linear-gradient(135deg, rgba(30, 41, 59, 0.7), rgba(9, 14, 36, 0.9)), url('ENO-TRANSFORMACIÓN EMPRESARIAL.png');
  background-size: cover;
  background-position: center;
  border-left: 5px solid hsl(var(--color-primary-glow));
}

.welcome-content {
  max-width: 65%;
  z-index: 2;
}

.welcome-content h2 {
  font-family: var(--font-headers);
  font-size: 1.75rem;
  margin-bottom: 0.75rem;
  color: hsl(var(--text-primary));
}

.welcome-content p {
  color: hsl(var(--text-secondary));
  margin-bottom: 1.5rem;
}

.welcome-actions {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

.welcome-badge-glow {
  width: 120px;
  height: 120px;
  color: rgba(16, 185, 129, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  position: absolute;
  right: 5%;
  top: 50%;
  transform: translateY(-50%);
  transition: var(--transition-slow);
  z-index: 1;
}

.welcome-banner:hover .welcome-badge-glow {
  transform: translateY(-50%) rotate(15deg) scale(1.1);
  color: rgba(16, 185, 129, 0.2);
}

.welcome-badge-glow svg {
  width: 140px;
  height: 140px;
}

/* Grid de Estadísticas */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
  margin-top: 2rem;
}

.stat-card {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  padding: 1.5rem;
}

.stat-icon {
  width: 52px;
  height: 52px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
}

.stat-icon svg {
  width: 24px;
  height: 24px;
}

.icon-blue {
  background: rgba(59, 130, 246, 0.1);
  border: 1px solid rgba(59, 130, 246, 0.2);
  color: hsl(var(--color-blue-glow));
}

.icon-emerald {
  background: rgba(16, 185, 129, 0.1);
  border: 1px solid rgba(16, 185, 129, 0.2);
  color: hsl(var(--color-primary-glow));
}

.icon-purple {
  background: rgba(139, 92, 246, 0.1);
  border: 1px solid rgba(139, 92, 246, 0.2);
  color: hsl(var(--color-purple-glow));
}

.stat-info {
  display: flex;
  flex-direction: column;
}

.stat-value {
  font-family: var(--font-headers);
  font-size: 1.6rem;
  font-weight: 800;
  line-height: 1.1;
  color: hsl(var(--text-primary));
}

.stat-label {
  font-size: 0.8rem;
  color: hsl(var(--text-secondary));
  margin-top: 2px;
}

/* Objetivos del Camino de Aprendizaje */
.objectives-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
}

.objective-card {
  padding: 2rem;
  border-top: 3px solid transparent;
}

.objective-card:nth-child(1) { border-top-color: hsl(var(--color-blue-glow)); }
.objective-card:nth-child(2) { border-top-color: hsl(var(--color-purple-glow)); }
.objective-card:nth-child(3) { border-top-color: hsl(var(--color-primary-glow)); }

.obj-number {
  font-family: var(--font-headers);
  font-size: 3rem;
  font-weight: 800;
  line-height: 1;
  opacity: 0.15;
  display: block;
  margin-bottom: 0.5rem;
}

.objective-card h3 {
  font-family: var(--font-headers);
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
}

.objective-card p {
  color: hsl(var(--text-secondary));
  font-size: 0.9rem;
}

/* Banner de Mentoría */
.cta-mentorship {
  margin-top: 3rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: linear-gradient(135deg, rgba(139, 92, 246, 0.1), rgba(16, 185, 129, 0.05));
  border: 1px solid rgba(139, 92, 246, 0.25);
  box-shadow: var(--shadow-neon-purple);
  gap: 2rem;
}

.cta-info h3 {
  font-family: var(--font-headers);
  font-size: 1.4rem;
  margin-bottom: 0.5rem;
}

.cta-info p {
  color: hsl(var(--text-secondary));
  font-size: 0.95rem;
  max-width: 650px;
}

.cta-actions-vertical {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  min-width: 250px;
}

/* --- 6. DETALLE VISTA 2: CENTRO MULTIMEDIA (BIBLIOTECA) --- */
.media-tabs {
  display: flex;
  gap: 0.5rem;
  overflow-x: auto;
  padding-bottom: 0.5rem;
  margin-bottom: 2rem;
  border-bottom: 1px solid rgba(var(--border-glass));
  scrollbar-width: none;
}
.media-tabs::-webkit-scrollbar {
  display: none;
}

.media-tab {
  background: none;
  border: none;
  color: hsl(var(--text-secondary));
  font-family: var(--font-headers);
  font-weight: 600;
  font-size: 0.9rem;
  padding: 0.6rem 1.25rem;
  border-radius: 50px;
  cursor: pointer;
  white-space: nowrap;
  transition: var(--transition-fast);
}

.media-tab:hover {
  color: hsl(var(--text-primary));
  background: rgba(255, 255, 255, 0.03);
}

.media-tab.active {
  color: #020617;
  background: hsl(var(--color-primary-glow));
  box-shadow: var(--shadow-neon-green);
}

/* Resources Grid */
.resources-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 2rem;
}

.resource-card {
  display: flex;
  flex-direction: column;
  height: 100%;
}

.resource-badge {
  position: absolute;
  top: 1.25rem;
  right: 1.25rem;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  padding: 4px 10px;
  border-radius: 4px;
}

.badge-video { background: rgba(59, 130, 246, 0.15); color: hsl(var(--color-blue-glow)); border: 1px solid rgba(59, 130, 246, 0.3); }
.badge-audio { background: rgba(245, 158, 11, 0.15); color: hsl(var(--color-warning)); border: 1px solid rgba(245, 158, 11, 0.3); }
.badge-document { background: rgba(139, 92, 246, 0.15); color: hsl(var(--color-purple-glow)); border: 1px solid rgba(139, 92, 246, 0.3); }
.badge-image { background: rgba(16, 185, 129, 0.15); color: hsl(var(--color-primary-glow)); border: 1px solid rgba(16, 185, 129, 0.3); }

.resource-icon-wrap {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.25rem;
}

.resource-card h3 {
  font-family: var(--font-headers);
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 0.75rem;
  line-height: 1.3;
}

.resource-card p {
  color: hsl(var(--text-secondary));
  font-size: 0.88rem;
  flex-grow: 1;
  margin-bottom: 1.5rem;
}

/* Reproductores Multimedia Integrados y Premium */
.video-player-container {
  width: 100%;
  aspect-ratio: 16/9;
  border-radius: var(--radius-md);
  overflow: hidden;
  background-color: #000;
  margin-bottom: 1rem;
  border: 1px solid rgba(var(--border-glass));
}

.video-player-container video {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Audio Player Custom Premium */
.audio-player-container {
  background: rgba(0, 0, 0, 0.25);
  border-radius: var(--radius-md);
  padding: 1.25rem;
  border: 1px solid rgba(var(--border-glass));
  margin-bottom: 1rem;
}

.audio-info {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.75rem;
}

.audio-title-sm {
  font-size: 0.8rem;
  font-weight: 600;
  color: hsl(var(--color-warning));
}

.audio-speed-control {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(var(--border-glass));
  color: hsl(var(--text-primary));
  font-size: 0.75rem;
  padding: 2px 6px;
  border-radius: 4px;
  cursor: pointer;
}

.audio-controls {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.audio-timeline-wrap {
  flex-grow: 1;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.audio-time {
  font-size: 0.7rem;
  font-family: monospace;
  color: hsl(var(--text-secondary));
  min-width: 32px;
}

.audio-slider {
  flex-grow: 1;
  -webkit-appearance: none;
  appearance: none;
  height: 4px;
  border-radius: 2px;
  background: rgba(255, 255, 255, 0.1);
  outline: none;
  cursor: pointer;
}

.audio-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: hsl(var(--color-warning));
  cursor: pointer;
  box-shadow: 0 0 5px rgba(245, 158, 11, 0.5);
  transition: transform 0.1s;
}

.audio-slider::-webkit-slider-thumb:hover {
  transform: scale(1.2);
}

.btn-play-audio {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: none;
  background: hsl(var(--color-warning));
  color: #000;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: var(--transition-fast);
}

.btn-play-audio:hover {
  transform: scale(1.08);
}

/* Image Infographic Cards */
.img-thumb-container {
  width: 100%;
  aspect-ratio: 16/10;
  border-radius: var(--radius-md);
  overflow: hidden;
  background-color: rgba(255, 255, 255, 0.02);
  margin-bottom: 1rem;
  border: 1px solid rgba(var(--border-glass));
  position: relative;
  cursor: zoom-in;
}

.img-thumb-container img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition-normal);
}

.img-thumb-container:hover img {
  transform: scale(1.05);
}

.img-overlay-hover {
  position: absolute;
  inset: 0;
  background: rgba(2, 6, 23, 0.4);
  backdrop-filter: blur(2px);
  opacity: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity var(--transition-fast);
}

.img-thumb-container:hover .img-overlay-hover {
  opacity: 1;
}

.img-overlay-hover svg {
  width: 32px;
  height: 32px;
  color: hsl(var(--text-primary));
}

/* --- 7. DETALLE VISTA 3: TARJETAS DE ESTUDIO & QUIZ --- */
.module-switcher-container {
  display: flex;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(var(--border-glass));
  border-radius: var(--radius-md);
  padding: 0.35rem;
  max-width: 450px;
  margin-bottom: 2.5rem;
}

.switcher-btn {
  flex-grow: 1;
  background: none;
  border: none;
  color: hsl(var(--text-secondary));
  font-family: var(--font-headers);
  font-weight: 600;
  font-size: 0.9rem;
  padding: 0.75rem 1rem;
  border-radius: calc(var(--radius-md) - 4px);
  cursor: pointer;
  transition: var(--transition-fast);
}

.switcher-btn.active {
  background: rgba(255, 255, 255, 0.06);
  color: hsl(var(--text-primary));
  border: 1px solid rgba(255, 255, 255, 0.05);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.15);
}

.switcher-area {
  display: none;
  opacity: 0;
  transition: opacity var(--transition-normal);
}

.switcher-area.active {
  display: block;
  opacity: 1;
}

/* Filtros de Tarjetas */
.cards-filter-bar {
  display: flex;
  gap: 1rem;
  margin-bottom: 2rem;
  flex-wrap: wrap;
}

.search-box {
  flex-grow: 1;
  min-width: 250px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(var(--border-glass));
  border-radius: var(--radius-md);
  padding: 0.75rem 1rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  color: hsl(var(--text-secondary));
}

.search-box input {
  background: none;
  border: none;
  outline: none;
  color: hsl(var(--text-primary));
  width: 100%;
  font-family: var(--font-body);
  font-size: 0.9rem;
}

.select-box-wrapper {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(var(--border-glass));
  border-radius: var(--radius-md);
  padding: 0 1rem;
  display: flex;
  align-items: center;
}

.select-box-wrapper select {
  background: none;
  border: none;
  outline: none;
  color: hsl(var(--text-secondary));
  font-family: var(--font-body);
  font-size: 0.9rem;
  padding: 0.75rem 0;
  cursor: pointer;
  width: 100%;
}

.select-box-wrapper select option {
  background-color: #0b0f19;
  color: hsl(var(--text-primary));
}

/* Estructura Mazo de Flashcards 3D */
.flashcard-deck-wrapper {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2rem;
  max-width: 600px;
  margin: 0 auto;
}

.flashcard-container {
  perspective: 1000px;
  width: 100%;
  aspect-ratio: 3/2;
}

.flashcard {
  width: 100%;
  height: 100%;
  position: relative;
  transform-style: preserve-3d;
  transition: transform var(--transition-slow);
  cursor: pointer;
}

.flashcard.flipped {
  transform: rotateY(180deg);
}

.flashcard-face {
  position: absolute;
  width: 100%;
  height: 100%;
  backface-visibility: hidden;
  border-radius: var(--radius-lg);
  padding: 2.5rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.4);
  border: 1px solid rgba(var(--border-glass));
}

.flashcard-front {
  background: linear-gradient(135deg, rgba(30, 41, 59, 0.7), rgba(15, 23, 42, 0.95));
  border-left: 4px solid hsl(var(--color-blue-glow));
}

.flashcard-back {
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.05), rgba(9, 14, 36, 0.98));
  transform: rotateY(180deg);
  border-left: 4px solid hsl(var(--color-primary-glow));
}

.card-category {
  font-size: 0.75rem;
  text-transform: uppercase;
  font-weight: 700;
  letter-spacing: 2px;
  color: hsl(var(--color-blue-glow));
  margin-bottom: auto;
}

.flashcard-back .card-category {
  color: hsl(var(--color-primary-glow));
}

.card-question-text {
  font-family: var(--font-headers);
  font-size: 1.45rem;
  font-weight: 700;
  line-height: 1.4;
  margin: auto 0;
  color: hsl(var(--text-primary));
}

.card-answer-text {
  font-family: var(--font-body);
  font-size: 1.2rem;
  font-weight: 500;
  line-height: 1.5;
  margin: auto 0;
  color: hsl(var(--text-secondary));
}

.card-tap-instruction {
  font-size: 0.75rem;
  color: hsl(var(--text-muted));
  margin-top: auto;
  letter-spacing: 0.5px;
}

.card-index-indicator {
  position: absolute;
  bottom: 1.25rem;
  right: 1.5rem;
  font-size: 0.75rem;
  color: hsl(var(--text-muted));
  font-family: monospace;
}

/* Controles del mazo */
.deck-controls {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  gap: 1rem;
}

.card-action-buttons {
  display: flex;
  gap: 0.75rem;
}

.deck-progress {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 1rem;
}

.deck-progress-bar {
  flex-grow: 1;
  height: 6px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 3px;
  overflow: hidden;
}

.deck-progress-fill {
  height: 100%;
  background: linear-gradient(90deg, hsl(var(--color-blue-glow)), hsl(var(--color-primary-glow)));
  border-radius: 3px;
  transition: width var(--transition-fast);
}

#deck-progress-text {
  font-size: 0.75rem;
  font-family: monospace;
  color: hsl(var(--text-secondary));
  min-width: 80px;
  text-align: right;
}

/* Modo Quiz */
.quiz-setup-card {
  max-width: 550px;
  margin: 2rem auto;
  text-align: center;
}

.quiz-setup-card h2 {
  font-family: var(--font-headers);
  margin-bottom: 0.75rem;
}

.quiz-setup-card p {
  color: hsl(var(--text-secondary));
  margin-bottom: 1.5rem;
}

.quiz-options-setup {
  display: flex;
  justify-content: center;
  margin-bottom: 1.5rem;
}

.quiz-active-wrapper {
  max-width: 700px;
  margin: 0 auto;
}

.quiz-header-status {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.75rem;
}

.quiz-question-indicator {
  font-size: 0.8rem;
  font-weight: 700;
  color: hsl(var(--color-blue-glow));
}

.quiz-timer {
  font-size: 0.85rem;
  font-family: monospace;
  color: hsl(var(--text-secondary));
  background: rgba(255, 255, 255, 0.03);
  padding: 2px 8px;
  border-radius: 4px;
  border: 1px solid rgba(var(--border-glass));
}

.quiz-progress-bar {
  height: 6px;
  background-color: rgba(255, 255, 255, 0.05);
  border-radius: 3px;
  overflow: hidden;
  margin-bottom: 2rem;
}

.quiz-progress-fill {
  height: 100%;
  background: hsl(var(--color-blue-glow));
  border-radius: 3px;
  transition: width var(--transition-fast);
}

.quiz-question-card {
  margin-bottom: 2rem;
}

.quiz-question-text {
  font-family: var(--font-headers);
  font-size: 1.35rem;
  font-weight: 700;
  line-height: 1.4;
}

.quiz-options-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.85rem;
  margin-bottom: 2rem;
}

.quiz-opt-btn {
  width: 100%;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(var(--border-glass));
  padding: 1.15rem 1.5rem;
  border-radius: var(--radius-md);
  color: hsl(var(--text-secondary));
  font-family: var(--font-body);
  font-size: 0.95rem;
  font-weight: 500;
  text-align: left;
  cursor: pointer;
  transition: var(--transition-fast);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.quiz-opt-btn:hover:not(:disabled) {
  border-color: rgba(var(--border-glass-focus));
  background: rgba(255, 255, 255, 0.06);
  color: hsl(var(--text-primary));
  transform: translateY(-1px);
}

.quiz-opt-btn:disabled {
  cursor: not-allowed;
}

/* Estados de selección en Quiz */
.quiz-opt-btn.correct {
  background: rgba(16, 185, 129, 0.1) !important;
  border-color: rgba(16, 185, 129, 0.4) !important;
  color: hsl(var(--text-primary)) !important;
  box-shadow: 0 0 15px rgba(16, 185, 129, 0.1);
}

.quiz-opt-btn.wrong {
  background: rgba(239, 68, 68, 0.1) !important;
  border-color: rgba(239, 68, 68, 0.4) !important;
  color: hsl(var(--text-primary)) !important;
}

.quiz-opt-btn::after {
  content: '';
  display: inline-block;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.15);
  flex-shrink: 0;
  margin-left: 1rem;
}

.quiz-opt-btn.correct::after {
  border-color: #10b981;
  background-color: #10b981;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23000'%3E%3Cpath d='M9 16.17L4.83 12l-1.42 1.41L9 19 21 7l-1.41-1.41L9 16.17z'/%3E%3C/svg%3E");
  background-size: 12px;
  background-repeat: no-repeat;
  background-position: center;
}

.quiz-opt-btn.wrong::after {
  border-color: #ef4444;
  background-color: #ef4444;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23fff'%3E%3Cpath d='M19 6.41L17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z'/%3E%3C/svg%3E");
  background-size: 10px;
  background-repeat: no-repeat;
  background-position: center;
}

.quiz-footer-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  min-height: 50px;
}

.quiz-feedback-banner {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 600;
  font-size: 0.95rem;
}

.quiz-feedback-banner.correct { color: hsl(var(--color-primary-glow)); }
.quiz-feedback-banner.wrong { color: #ef4444; }

.feedback-icon {
  display: inline-flex;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  align-items: center;
  justify-content: center;
  font-weight: bold;
}

.quiz-feedback-banner.correct .feedback-icon { background: rgba(16, 185, 129, 0.1); }
.quiz-feedback-banner.wrong .feedback-icon { background: rgba(239, 68, 68, 0.1); }

/* Pantalla de Resultados de Quiz */
.quiz-results-box {
  max-width: 550px;
  margin: 0 auto;
}

.quiz-results-card {
  max-width: 500px;
  margin: 0 auto;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.5rem;
}

.results-glowing-circle {
  width: 140px;
  height: 140px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(16, 185, 129, 0.15) 30%, transparent 70%);
  border: 4px solid hsl(var(--color-primary-glow));
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-neon-green);
}

.results-score-num {
  font-family: var(--font-headers);
  font-size: 2.25rem;
  font-weight: 800;
  line-height: 1;
  color: hsl(var(--text-primary));
}

.results-score-label {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  color: hsl(var(--color-primary-glow));
  letter-spacing: 1px;
  margin-top: 4px;
}

.quiz-results-card h2 {
  font-family: var(--font-headers);
  font-size: 1.75rem;
}

.quiz-results-card p {
  color: hsl(var(--text-secondary));
  font-size: 0.95rem;
  line-height: 1.5;
}

.results-actions {
  display: flex;
  gap: 1rem;
  width: 100%;
}

.results-actions .btn {
  flex-grow: 1;
}

/* --- 8. DETALLE VISTA 4: AUTODIAGNÓSTICO --- */
.diagnostic-wizard {
  max-width: 700px;
  margin: 0 auto;
}

.wizard-header {
  margin-bottom: 2rem;
}

.wizard-steps-indicator {
  font-size: 0.8rem;
  font-weight: 700;
  color: hsl(var(--color-primary-glow));
  text-transform: uppercase;
  letter-spacing: 1.5px;
  margin-bottom: 0.5rem;
}

.wizard-progress-bar {
  height: 6px;
  background-color: rgba(255, 255, 255, 0.05);
  border-radius: 3px;
  overflow: hidden;
}

.wizard-progress-fill {
  height: 100%;
  background: hsl(var(--color-primary-glow));
  border-radius: 3px;
  transition: width var(--transition-fast);
}

.wizard-question-text {
  font-family: var(--font-headers);
  font-size: 1.4rem;
  font-weight: 700;
  margin-bottom: 2rem;
  line-height: 1.35;
}

.wizard-options-list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-bottom: 2rem;
}

.diag-opt-btn {
  width: 100%;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(var(--border-glass));
  border-radius: var(--radius-md);
  padding: 1.25rem 1.5rem;
  color: hsl(var(--text-secondary));
  font-family: var(--font-body);
  font-size: 0.95rem;
  line-height: 1.45;
  text-align: left;
  cursor: pointer;
  transition: var(--transition-fast);
}

.diag-opt-btn:hover {
  border-color: rgba(var(--border-glass-focus));
  background: rgba(255, 255, 255, 0.05);
  color: hsl(var(--text-primary));
  transform: translateX(4px);
}

.diag-opt-btn.selected {
  background: rgba(16, 185, 129, 0.08) !important;
  border-color: hsl(var(--color-primary-glow)) !important;
  color: hsl(var(--text-primary)) !important;
  font-weight: 500;
  box-shadow: var(--shadow-neon-green);
}

.wizard-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-top: 1px solid rgba(var(--border-glass));
  padding-top: 1.5rem;
}

.wizard-hint {
  font-size: 0.75rem;
  color: hsl(var(--text-muted));
}

/* Pantalla del Reporte Generado del Plan */
.diagnostic-report-wrapper {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.report-alert-glowing {
  display: flex;
  align-items: center;
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.08), rgba(9, 14, 36, 0.95));
  border: 1px solid rgba(16, 185, 129, 0.25);
  box-shadow: var(--shadow-neon-green);
  gap: 1.5rem;
  padding: 1.5rem 2rem;
}

.report-alert-glowing.card-digital {
  border-color: rgba(59, 130, 246, 0.25);
  box-shadow: var(--shadow-neon-blue);
  background: linear-gradient(135deg, rgba(59, 130, 246, 0.08), rgba(9, 14, 36, 0.95));
}
.report-alert-glowing.card-business {
  border-color: rgba(139, 92, 246, 0.25);
  box-shadow: var(--shadow-neon-purple);
  background: linear-gradient(135deg, rgba(139, 92, 246, 0.08), rgba(9, 14, 36, 0.95));
}
.report-alert-glowing.card-ai {
  border-color: rgba(16, 185, 129, 0.25);
  box-shadow: var(--shadow-neon-green);
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.08), rgba(9, 14, 36, 0.95));
}

.report-badge-icon {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.04);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.6rem;
}

.report-overview {
  flex-grow: 1;
}

.report-top-label {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: hsl(var(--text-secondary));
}

.report-result-title {
  font-family: var(--font-headers);
  font-size: 1.6rem;
  font-weight: 800;
  line-height: 1.2;
}

.report-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
}

.report-card-detail {
  display: flex;
  flex-direction: column;
}

.report-card-detail h3, .report-card-timeline h3 {
  font-family: var(--font-headers);
  font-size: 1.35rem;
  margin-bottom: 1rem;
}

.report-body-text {
  color: hsl(var(--text-secondary));
  font-size: 0.95rem;
  line-height: 1.6;
  margin-bottom: 2rem;
}

/* Caja de Proyecto Especial */
.custom-project-box {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(var(--border-glass));
  border-radius: var(--radius-md);
  padding: 1.25rem 1.5rem;
  border-left: 4px solid hsl(var(--color-purple-glow));
  margin-top: auto;
}

.project-tag {
  font-size: 0.65rem;
  font-weight: 700;
  color: hsl(var(--color-purple-glow));
  letter-spacing: 1px;
  display: block;
  margin-bottom: 4px;
}

.custom-project-box h4 {
  font-family: var(--font-headers);
  font-size: 1.05rem;
  font-weight: 700;
  margin-bottom: 4px;
}

.custom-project-box p {
  color: hsl(var(--text-secondary));
  font-size: 0.85rem;
  line-height: 1.4;
}

/* Línea de tiempo interactiva */
.report-card-timeline {
  display: flex;
  flex-direction: column;
}

.report-card-timeline .sub-text {
  font-size: 0.85rem;
  color: hsl(var(--text-muted));
  margin-bottom: 1.5rem;
}

.timeline-steps {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  position: relative;
  padding-left: 1.5rem;
}

.timeline-steps::before {
  content: '';
  position: absolute;
  top: 8px;
  bottom: 8px;
  left: 4px;
  width: 2px;
  background: rgba(255, 255, 255, 0.08);
}

.timeline-item {
  position: relative;
}

.timeline-item::before {
  content: '';
  position: absolute;
  top: 6px;
  left: -22px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: hsl(var(--color-primary-glow));
  border: 2px solid #020617;
  box-shadow: 0 0 8px hsl(var(--color-primary-glow));
}

.timeline-phase {
  font-size: 0.75rem;
  font-weight: 700;
  color: hsl(var(--color-primary-glow));
  text-transform: uppercase;
  margin-bottom: 2px;
  display: block;
}

.timeline-desc {
  font-size: 0.88rem;
  color: hsl(var(--text-secondary));
  line-height: 1.45;
}

/* Acciones Finales Reporte */
.report-ctas {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.report-ctas h3 {
  font-family: var(--font-headers);
  font-size: 1.25rem;
}

.report-ctas p {
  color: hsl(var(--text-secondary));
  font-size: 0.9rem;
  margin-bottom: 0.5rem;
}

.report-ctas-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1rem;
}

/* --- 9. DETALLE VISTA 5: JUEGO DE EMPAREJAR CONCEPTOS --- */
.game-wrapper {
  max-width: 600px;
  margin: 2rem auto;
  text-align: center;
}

.game-play-panel {
  max-width: 800px;
  margin: 0 auto;
}

.game-metrics {
  display: flex;
  justify-content: space-between;
  margin-bottom: 1rem;
}

.metric-box {
  display: flex;
  flex-direction: column;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(var(--border-glass));
  padding: 0.5rem 1.25rem;
  border-radius: var(--radius-md);
  min-width: 120px;
  text-align: center;
}

.metric-label {
  font-size: 0.7rem;
  color: hsl(var(--text-secondary));
  text-transform: uppercase;
  font-weight: 600;
}

.metric-value {
  font-family: var(--font-headers);
  font-size: 1.4rem;
  font-weight: 800;
  line-height: 1.1;
  margin-top: 2px;
}

.text-glow-emerald { color: hsl(var(--color-primary-glow)); text-shadow: 0 0 10px rgba(16, 185, 129, 0.3); }
.text-glow-blue { color: hsl(var(--color-blue-glow)); text-shadow: 0 0 10px rgba(59, 130, 246, 0.3); }

.game-progress-bar {
  height: 6px;
  background-color: rgba(255, 255, 255, 0.05);
  border-radius: 3px;
  overflow: hidden;
  margin-bottom: 2rem;
}

.game-progress-fill {
  height: 100%;
  background: linear-gradient(90deg, hsl(var(--color-primary-glow)), hsl(var(--color-blue-glow)));
  border-radius: 3px;
  transition: width 1s linear;
}

/* Tablero de Columnas de Juego */
.game-board-grid {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 2rem;
  margin-bottom: 2rem;
}

.board-column h3 {
  font-family: var(--font-headers);
  font-size: 1rem;
  margin-bottom: 1rem;
  color: hsl(var(--text-secondary));
}

.board-nodes {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.game-node {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(var(--border-glass));
  border-radius: var(--radius-md);
  padding: 1rem 1.25rem;
  color: hsl(var(--text-secondary));
  font-size: 0.88rem;
  font-weight: 500;
  text-align: left;
  cursor: pointer;
  transition: var(--transition-fast);
  line-height: 1.4;
  min-height: 64px;
  display: flex;
  align-items: center;
}

.game-node:hover:not(.matched) {
  border-color: rgba(var(--border-glass-focus));
  background: rgba(255, 255, 255, 0.06);
  color: hsl(var(--text-primary));
  transform: translateY(-1px);
}

.game-node.selected {
  background: rgba(59, 130, 246, 0.1) !important;
  border-color: hsl(var(--color-blue-glow)) !important;
  color: hsl(var(--text-primary)) !important;
  box-shadow: var(--shadow-neon-blue);
}

.game-node.matched {
  opacity: 0.25;
  cursor: not-allowed;
  background: rgba(16, 185, 129, 0.05);
  border-color: rgba(16, 185, 129, 0.1);
  text-decoration: line-through;
  transform: none;
}

.game-node.wrong {
  background: rgba(239, 68, 68, 0.1) !important;
  border-color: #ef4444 !important;
  color: hsl(var(--text-primary)) !important;
}

/* Pantalla de Resultados de Juego */
.game-result-panel {
  max-width: 500px;
  margin: 0 auto;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.5rem;
}

/* --- 10. MODAL LIGHTBOX GLOBAL (ZOOM DE IMÁGENES) --- */
.modal-lightbox {
  position: fixed;
  inset: 0;
  background-color: rgba(2, 6, 23, 0.95);
  backdrop-filter: blur(8px);
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  transition: opacity var(--transition-normal);
}

.modal-lightbox.hidden {
  display: none;
  opacity: 0;
}

.lightbox-close {
  position: absolute;
  top: 1.5rem;
  right: 1.5rem;
  background: none;
  border: none;
  color: hsl(var(--text-primary));
  cursor: pointer;
  transition: var(--transition-fast);
  padding: 4px;
}

.lightbox-close:hover {
  transform: scale(1.1);
  color: hsl(var(--color-primary-glow));
}

.lightbox-content {
  max-width: 90vw;
  max-height: 80vh;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.lightbox-content img {
  max-width: 100%;
  max-height: 72vh;
  object-fit: contain;
  border-radius: var(--radius-md);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.lightbox-caption {
  margin-top: 1rem;
  font-family: var(--font-headers);
  font-size: 1.1rem;
  font-weight: 600;
  color: hsl(var(--text-primary));
  text-align: center;
}

/* --- 11. SISTEMA DE TOAST NOTIFICATIONS --- */
.toast-container {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  z-index: 3000;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.toast {
  background: rgba(15, 23, 42, 0.9);
  backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  padding: 1rem 1.5rem;
  border-radius: var(--radius-md);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
  color: hsl(var(--text-primary));
  font-size: 0.88rem;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  min-width: 280px;
  max-width: 400px;
  animation: slideIn var(--transition-fast) forwards;
  border-left: 4px solid hsl(var(--color-blue-glow));
}

.toast.toast-success { border-left-color: hsl(var(--color-primary-glow)); }
.toast.toast-error { border-left-color: #ef4444; }

@keyframes slideIn {
  from { transform: translateX(100%); opacity: 0; }
  to { transform: translateX(0); opacity: 1; }
}

/* --- 12. MENÚ DRAWER MÓVIL --- */
.menu-overlay {
  position: fixed;
  inset: 0;
  background-color: rgba(2, 6, 23, 0.7);
  backdrop-filter: blur(4px);
  z-index: 1000;
  display: none;
}

.menu-overlay.active {
  display: block;
}

.menu-drawer {
  position: fixed;
  top: 0;
  bottom: 0;
  right: -300px;
  width: 280px;
  background-color: hsl(var(--bg-sidebar));
  z-index: 1001;
  display: flex;
  flex-direction: column;
  padding: 1.5rem;
  transition: right var(--transition-normal);
  border-left: 1px solid rgba(var(--border-glass));
}

.menu-drawer.active {
  right: 0;
}

.drawer-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 2.5rem;
}

.logo-drawer {
  background: linear-gradient(135deg, hsl(var(--color-primary-glow)), hsl(var(--color-blue-glow)));
  color: #020617;
  font-family: var(--font-headers);
  font-weight: 800;
  font-size: 1.1rem;
  padding: 4px 8px;
  border-radius: var(--radius-sm);
}

.drawer-close {
  background: none;
  border: none;
  color: hsl(var(--text-primary));
  cursor: pointer;
}

.drawer-menu {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  flex-grow: 1;
}

.drawer-link {
  display: block;
  padding: 0.85rem 1rem;
  color: hsl(var(--text-secondary));
  text-decoration: none;
  font-family: var(--font-headers);
  font-size: 1rem;
  font-weight: 600;
  border-radius: var(--radius-md);
  transition: var(--transition-fast);
}

.drawer-link:hover {
  background-color: rgba(255, 255, 255, 0.03);
  color: hsl(var(--text-primary));
}

.drawer-link.active {
  background-color: rgba(16, 185, 129, 0.08);
  color: hsl(var(--color-primary-glow));
}

.drawer-footer {
  margin-top: auto;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.drawer-site {
  text-align: center;
  font-size: 0.8rem;
  color: hsl(var(--text-muted));
}

/* --- 13. CLASES DE UTILERÍA (SOPORTE DE LOGICA) --- */
.hidden {
  display: none !important;
}

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

.w-full {
  width: 100%;
}

/* --- 14. ADAPTACIÓN RESPONSIVA (MEDIA QUERIES) --- */

/* Tablet y pantallas medianas (Widescreen to tablet) */
@media (max-width: 1024px) {
  :root {
    --sidebar-width: 240px;
  }
  .main-content {
    padding: 3rem 2.5rem;
  }
  .view-title {
    font-size: 2.15rem;
  }
  .report-grid {
    grid-template-columns: 1fr;
  }
}

/* Mobile Layout - Menú de navegación inferior, ocultar barra lateral */
@media (max-width: 768px) {
  body {
    padding-bottom: 70px; /* Espacio para barra de navegación móvil */
  }
  .sidebar {
    transform: translateX(-100%); /* Ocultar sidebar en móviles */
    pointer-events: none;
  }
  .main-content {
    margin-left: 0;
    padding: 1.5rem 1.25rem;
  }
  
  .mobile-header {
    display: flex;
  }
  .mobile-nav-bar {
    display: flex;
  }
  
  .welcome-banner {
    flex-direction: column;
    align-items: flex-start;
    padding: 1.5rem;
    gap: 1.5rem;
  }
  .welcome-content {
    max-width: 100%;
  }
  .welcome-badge-glow {
    display: none;
  }
  
  .cta-mentorship {
    flex-direction: column;
    align-items: stretch;
    padding: 1.5rem;
  }
  .cta-actions-vertical {
    min-width: 100%;
  }
  
  .view-title {
    font-size: 1.85rem;
  }
  
  .cards-filter-bar {
    flex-direction: column;
    align-items: stretch;
  }
  .search-box, .select-box-wrapper, .select-box-wrapper select {
    width: 100%;
  }
  
  .deck-controls {
    flex-direction: column;
    gap: 1rem;
  }
  .deck-controls .btn-circle {
    display: none; /* En móvil se puede deslizar o tocar botones centrales */
  }
  .card-action-buttons {
    width: 100%;
  }
  .card-action-buttons .btn {
    flex-grow: 1;
  }
  
  .flashcard-container {
    aspect-ratio: 1.3/1;
  }
  .card-question-text {
    font-size: 1.15rem;
  }
  .card-answer-text {
    font-size: 0.95rem;
  }
  
  .quiz-results-card {
    padding: 1.5rem;
  }
  .results-actions {
    flex-direction: column;
  }
  
  .report-ctas-grid {
    grid-template-columns: 1fr;
  }
  .game-board-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
  
  .toast-container {
    left: 1rem;
    right: 1rem;
    bottom: 5rem;
  }
  .toast {
    min-width: 100%;
  }
}

/* Print Styles (Para guardar PDF de diagnóstico de forma limpia) */
@media print {
  body {
    background: #fff;
    color: #000;
  }
  .sidebar, .mobile-header, .mobile-nav-bar, .menu-drawer, .menu-overlay, .btn, .report-ctas, .welcome-banner, .stats-grid, .objectives-grid, .cta-mentorship, .view-header .header-badge {
    display: none !important;
  }
  .main-content {
    margin-left: 0 !important;
    padding: 0 !important;
  }
  .app-view {
    display: none !important;
  }
  #view-diagnostico {
    display: block !important;
    opacity: 1 !important;
  }
  #diagnostic-wizard-container {
    display: none !important;
  }
  #diagnostic-report-container {
    display: block !important;
  }
  .card {
    background: none !important;
    border: none !important;
    box-shadow: none !important;
    padding: 0 !important;
    color: #000 !important;
  }
  .report-alert-glowing {
    border: 2px solid #000 !important;
    background: none !important;
    color: #000 !important;
  }
  .report-result-title {
    color: #000 !important;
  }
  .custom-project-box {
    border: 1px solid #000 !important;
    background: none !important;
    color: #000 !important;
  }
  .timeline-steps::before {
    background: #000 !important;
  }
  .timeline-item::before {
    background: #000 !important;
    border: 2px solid #fff !important;
  }
  .timeline-phase {
    color: #000 !important;
  }
  .timeline-desc {
    color: #333 !important;
  }
}
