/* ==========================================================================
   Aprende Ya - Premium Custom Stylesheet
   Design Inspiration: Startup SaaS, Notion, Duolingo, Glassmorphic Dashboards
   ========================================================================== */

/* --- Fonts Import --- */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600&family=Manrope:wght@400;600;700;800&family=Poppins:wght@400;500;600;700;800&display=swap');

/* --- Design Tokens & Variables --- */
:root {
  /* Color Palette (Modern Tech & Corporate Education) */
  --primary: hsl(220, 95%, 52%);
  --primary-rgb: 36, 107, 243;
  --primary-dark: hsl(220, 100%, 40%);
  --primary-light: hsl(220, 100%, 96%);
  --cyan: hsl(182, 100%, 42%);
  --cyan-rgb: 0, 206, 214;
  --cyan-light: hsl(182, 100%, 96%);
  --accent: hsl(260, 90%, 65%); /* Subtle purple highlights */
  
  /* Neutral Grays */
  --dark: hsl(222, 47%, 11%);
  --dark-light: hsl(217, 30%, 18%);
  --dark-rgb: 15, 23, 42;
  --gray: hsl(215, 16%, 47%);
  --gray-medium: hsl(213, 27%, 84%);
  --gray-light: hsl(210, 40%, 96%);
  --white: hsl(0, 0%, 100%);
  --success: hsl(142, 72%, 40%);
  --error: hsl(350, 85%, 55%);

  /* Glassmorphism & Shadow Properties */
  --glass-bg: rgba(255, 255, 255, 0.75);
  --glass-bg-hover: rgba(255, 255, 255, 0.9);
  --glass-border: rgba(255, 255, 255, 0.6);
  --glass-border-rgb: 255, 255, 255;
  --backdrop-blur: blur(16px);
  
  --shadow-sm: 0 4px 12px rgba(15, 23, 42, 0.03);
  --shadow-md: 0 12px 36px -12px rgba(15, 23, 42, 0.08);
  --shadow-lg: 0 30px 60px -15px rgba(15, 23, 42, 0.12);
  --shadow-glow: 0 0 25px rgba(36, 107, 243, 0.25);
  --shadow-cyan: 0 0 25px rgba(0, 206, 214, 0.25);
  
  /* Borders and Border Radius */
  --radius-sm: 8px;
  --radius-md: 16px;
  --radius-lg: 24px;
  --radius-xl: 32px;
  --transition-fast: 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-smooth: 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
  --transition-bounce: 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}

/* --- Smooth Scroll and General Resets --- */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: 'Inter', sans-serif;
  background-color: var(--gray-light);
  color: var(--dark-light);
  overflow-x: hidden;
  line-height: 1.6;
}

h1, h2, h3, h4, h5, h6 {
  font-family: 'Poppins', sans-serif;
  color: var(--dark);
  font-weight: 700;
  line-height: 1.25;
}

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

button, input, select, textarea {
  font-family: inherit;
  font-size: inherit;
  outline: none;
  border: none;
}

button {
  cursor: pointer;
  background: none;
}

ul {
  list-style: none;
}

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

/* --- Loader Animation --- */
#app-loader {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: var(--dark);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  z-index: 9999;
  transition: opacity var(--transition-smooth), visibility var(--transition-smooth);
}

.loader-spinner {
  width: 60px;
  height: 60px;
  border: 4px solid rgba(255, 255, 255, 0.1);
  border-left-color: var(--cyan);
  border-radius: 50%;
  animation: spin 1s cubic-bezier(0.5, 0.1, 0.5, 0.9) infinite;
  box-shadow: var(--shadow-cyan);
}

.loader-text {
  margin-top: 20px;
  font-family: 'Poppins', sans-serif;
  color: var(--white);
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
  animation: pulse 1.5s infinite ease-in-out;
}

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

@keyframes pulse {
  0%, 100% { opacity: 0.5; transform: scale(0.98); }
  50% { opacity: 1; transform: scale(1.02); }
}

/* --- Background Premium Gradients --- */
.gradient-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  z-index: -1;
  pointer-events: none;
}

.gradient-shape {
  position: absolute;
  border-radius: 50%;
  filter: blur(120px);
  opacity: 0.15;
  mix-blend-mode: multiply;
}

.shape-1 {
  top: -10%;
  right: -5%;
  width: 500px;
  height: 500px;
  background: var(--primary);
  animation: float-slow 20s infinite ease-in-out alternate;
}

.shape-2 {
  top: 30%;
  left: -10%;
  width: 600px;
  height: 600px;
  background: var(--cyan);
  animation: float-slow 25s infinite ease-in-out alternate-reverse;
}

.shape-3 {
  bottom: 10%;
  right: 10%;
  width: 450px;
  height: 450px;
  background: var(--accent);
  animation: float-slow 18s infinite ease-in-out alternate;
}

@keyframes float-slow {
  0% { transform: translate(0, 0) scale(1); }
  100% { transform: translate(40px, 30px) scale(1.1); }
}

/* --- Header Section (Glassmorphic Bar) --- */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  transition: all var(--transition-smooth);
  padding: 20px 0;
}

.site-header.scrolled {
  background-color: var(--glass-bg);
  backdrop-filter: var(--backdrop-blur);
  -webkit-backdrop-filter: var(--backdrop-blur);
  border-bottom: 1px solid var(--glass-border);
  padding: 12px 0;
  box-shadow: var(--shadow-sm);
}

.header-container {
  width: 90%;
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

/* Brand/Logo Design */
.brand-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: 'Manrope', sans-serif;
  font-weight: 800;
  font-size: 1.5rem;
  color: var(--dark);
}

.logo-icon {
  width: 40px;
  height: 40px;
  background: linear-gradient(135deg, var(--primary), var(--cyan));
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--white);
  font-family: 'Poppins', sans-serif;
  font-weight: 800;
  font-size: 1.3rem;
  box-shadow: var(--shadow-glow);
  position: relative;
  overflow: hidden;
}

.logo-icon::after {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: linear-gradient(to bottom right, rgba(255,255,255,0.3), rgba(255,255,255,0));
  transform: rotate(30deg);
}

.logo-text span {
  background: linear-gradient(135deg, var(--primary), var(--cyan));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* Nav Menu Styles */
.nav-menu {
  display: flex;
  align-items: center;
  gap: 30px;
}

.nav-link {
  font-weight: 500;
  font-size: 0.95rem;
  color: var(--dark-light);
  position: relative;
  padding: 6px 0;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--primary), var(--cyan));
  transition: var(--transition-fast);
}

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

.nav-link:hover::after {
  width: 100%;
}

.nav-cta {
  background: linear-gradient(135deg, var(--primary), var(--cyan));
  color: var(--white) !important;
  font-weight: 600;
  padding: 10px 22px;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-glow);
  transition: transform var(--transition-bounce), box-shadow var(--transition-fast);
}

.nav-cta:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(36, 107, 243, 0.4);
}

/* Hamburger Menu Icon */
.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  width: 28px;
  cursor: pointer;
  z-index: 1001;
}

.toggle-bar {
  width: 100%;
  height: 3px;
  background-color: var(--dark);
  border-radius: 2px;
  transition: all var(--transition-smooth);
}

/* Responsive Mobile Navigation */
@media (max-width: 991px) {
  .nav-toggle {
    display: flex;
  }
  
  .nav-menu {
    position: fixed;
    top: 0;
    right: -100%;
    width: 300px;
    height: 100vh;
    background-color: rgba(255, 255, 255, 0.95);
    backdrop-filter: var(--backdrop-blur);
    -webkit-backdrop-filter: var(--backdrop-blur);
    border-left: 1px solid var(--glass-border);
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 35px;
    transition: right var(--transition-smooth);
    box-shadow: var(--shadow-lg);
  }
  
  .nav-menu.active {
    right: 0;
  }
  
  .nav-toggle.active .bar-1 {
    transform: rotate(45deg) translate(6px, 6px);
  }
  
  .nav-toggle.active .bar-2 {
    opacity: 0;
  }
  
  .nav-toggle.active .bar-3 {
    transform: rotate(-45deg) translate(5px, -5px);
  }
}

/* --- Hero Section --- */
.hero-section {
  position: relative;
  padding: 160px 0 100px;
  background-color: var(--gray-light);
  overflow: hidden;
}

.hero-container {
  width: 90%;
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 40px;
  align-items: center;
}

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

.hero-tag {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--primary-light);
  color: var(--primary);
  padding: 8px 16px;
  border-radius: 100px;
  font-weight: 600;
  font-size: 0.85rem;
  margin-bottom: 24px;
  border: 1px solid rgba(36, 107, 243, 0.1);
  animation: fadeInDown 0.8s var(--transition-bounce);
}

.hero-tag i {
  color: var(--cyan);
  font-size: 1rem;
}

.hero-title {
  font-size: clamp(2.5rem, 5vw, 3.8rem);
  font-weight: 800;
  letter-spacing: -1.5px;
  margin-bottom: 20px;
  animation: fadeInUp 0.8s 0.2s cubic-bezier(0.25, 0.8, 0.25, 1) both;
}

.hero-title span {
  background: linear-gradient(135deg, var(--primary) 0%, var(--cyan) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-subtitle {
  font-size: clamp(1rem, 2vw, 1.25rem);
  color: var(--gray);
  margin-bottom: 36px;
  max-width: 580px;
  animation: fadeInUp 0.8s 0.3s cubic-bezier(0.25, 0.8, 0.25, 1) both;
}

.hero-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: 48px;
  animation: fadeInUp 0.8s 0.4s cubic-bezier(0.25, 0.8, 0.25, 1) both;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 14px 28px;
  border-radius: var(--radius-md);
  font-weight: 600;
  transition: all var(--transition-bounce);
}

.btn-primary {
  background: linear-gradient(135deg, var(--primary) 0%, var(--cyan) 100%);
  color: var(--white);
  box-shadow: var(--shadow-glow);
}

.btn-primary:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 30px rgba(36, 107, 243, 0.35);
}

.btn-secondary {
  background-color: var(--white);
  color: var(--dark);
  border: 1px solid var(--gray-medium);
  box-shadow: var(--shadow-sm);
}

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

/* Stats Badges */
.hero-stats {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
  animation: fadeInUp 0.8s 0.5s cubic-bezier(0.25, 0.8, 0.25, 1) both;
}

.stat-box {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  backdrop-filter: var(--backdrop-blur);
  -webkit-backdrop-filter: var(--backdrop-blur);
  padding: 18px 24px;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  transition: transform var(--transition-fast), box-shadow var(--transition-fast);
}

.stat-box:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.stat-number {
  font-size: 2.2rem;
  font-weight: 800;
  color: var(--primary);
  line-height: 1.1;
  margin-bottom: 4px;
  font-family: 'Manrope', sans-serif;
  background: linear-gradient(135deg, var(--primary), var(--cyan));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.stat-label {
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--gray);
}

/* Hero Right: Premium Visual Graphics */
.hero-graphic {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 400px;
}

.graphic-container {
  position: relative;
  width: 100%;
  max-width: 420px;
  height: 420px;
}

.graphic-circle {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 320px;
  height: 320px;
  border: 2px dashed rgba(36, 107, 243, 0.15);
  border-radius: 50%;
  animation: rotate-circle 40s linear infinite;
}

.graphic-core {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 220px;
  height: 220px;
  background: linear-gradient(135deg, var(--primary-light), var(--cyan-light));
  border: 1px solid var(--glass-border);
  box-shadow: var(--shadow-md);
  border-radius: var(--radius-lg);
  display: flex;
  align-items: center;
  justify-content: center;
}

.graphic-core i {
  font-size: 6rem;
  background: linear-gradient(135deg, var(--primary), var(--cyan));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: breathe 4s ease-in-out infinite;
}

/* Premium Floating Dashboard Badges */
.floating-badge {
  position: absolute;
  background: var(--glass-bg);
  backdrop-filter: var(--backdrop-blur);
  -webkit-backdrop-filter: var(--backdrop-blur);
  border: 1px solid var(--glass-border);
  padding: 12px 18px;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-md);
  display: flex;
  align-items: center;
  gap: 12px;
  z-index: 3;
  transition: transform var(--transition-bounce);
}

.floating-badge:hover {
  transform: scale(1.05);
}

.badge-icon {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--white);
}

.badge-icon.blue { background: var(--primary); }
.badge-icon.cyan { background: var(--cyan); }
.badge-icon.purple { background: var(--accent); }

.badge-details h4 {
  font-size: 0.85rem;
  font-weight: 700;
  line-height: 1.1;
  color: var(--dark);
}

.badge-details p {
  font-size: 0.75rem;
  color: var(--gray);
}

.badge-1 {
  top: 10%;
  left: -5%;
  animation: float 6s ease-in-out infinite alternate;
}

.badge-2 {
  bottom: 12%;
  right: -5%;
  animation: float 7s ease-in-out infinite alternate-reverse;
}

.badge-3 {
  bottom: 45%;
  right: -12%;
  animation: float 5s ease-in-out infinite alternate 1s;
}

@keyframes rotate-circle {
  0% { transform: translate(-50%, -50%) rotate(0deg); }
  100% { transform: translate(-50%, -50%) rotate(360deg); }
}

@keyframes breathe {
  0%, 100% { transform: scale(0.95); opacity: 0.95; }
  50% { transform: scale(1.05); opacity: 1; }
}

@keyframes float {
  0% { transform: translateY(0); }
  100% { transform: translateY(-15px); }
}

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

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

/* Responsive Hero Layout */
@media (max-width: 991px) {
  .hero-container {
    grid-template-columns: 1fr;
    text-align: center;
  }
  
  .hero-subtitle {
    margin-left: auto;
    margin-right: auto;
  }
  
  .hero-buttons {
    justify-content: center;
  }
  
  .hero-graphic {
    order: -1;
    min-height: 350px;
  }
  
  .graphic-container {
    max-width: 320px;
    height: 320px;
    margin: 0 auto;
  }
  
  .graphic-circle {
    width: 250px;
    height: 250px;
  }
  
  .graphic-core {
    width: 170px;
    height: 170px;
  }
  
  .badge-1 { top: 0; left: -10%; }
  .badge-2 { bottom: 0; right: -10%; }
  .badge-3 { bottom: 40%; right: -15%; }
}

/* --- Section Formatting (Common) --- */
.section-wrapper {
  padding: 100px 0;
  position: relative;
}

/* --- SPA Dynamic Section Switching --- */
.site-section {
  display: none;
  opacity: 0;
  transform: translateY(15px);
  transition: opacity 0.4s ease-out, transform 0.4s ease-out;
}

.site-section.active-section {
  display: block;
  opacity: 1;
  transform: translateY(0);
  animation: sectionFadeIn 0.5s cubic-bezier(0.25, 0.8, 0.25, 1) forwards;
}

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

.section-container {
  width: 90%;
  max-width: 1200px;
  margin: 0 auto;
}

.section-header {
  text-align: center;
  margin-bottom: 60px;
}

.section-subtitle {
  display: inline-block;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 2px;
  font-weight: 700;
  color: var(--primary);
  margin-bottom: 12px;
}

.section-title {
  font-size: clamp(2rem, 3.5vw, 2.5rem);
  font-weight: 800;
  color: var(--dark);
  margin-bottom: 16px;
  letter-spacing: -0.5px;
}

.section-desc {
  font-size: 1.05rem;
  color: var(--gray);
  max-width: 600px;
  margin: 0 auto;
}

/* --- Quiénes Somos Section --- */
.about-section {
  background-color: var(--white);
}

.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
}

.about-content h3 {
  font-size: 1.8rem;
  margin-bottom: 20px;
  line-height: 1.3;
}

.about-text {
  color: var(--gray);
  margin-bottom: 30px;
}

.about-features {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
}

.about-feature-item {
  display: flex;
  gap: 12px;
}

.about-feature-icon {
  flex-shrink: 0;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background-color: var(--cyan-light);
  color: var(--cyan);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.85rem;
}

.about-feature-text h4 {
  font-size: 0.95rem;
  font-weight: 600;
  margin-bottom: 4px;
}

.about-feature-text p {
  font-size: 0.85rem;
  color: var(--gray);
}

/* timeline component */
.about-timeline {
  position: relative;
  padding-left: 20px;
  border-left: 2px solid var(--gray-light);
}

.timeline-card {
  position: relative;
  background: var(--gray-light);
  border: 1px solid var(--gray-medium);
  padding: 20px;
  border-radius: var(--radius-md);
  margin-bottom: 25px;
  transition: all var(--transition-fast);
  box-shadow: var(--shadow-sm);
}

.timeline-card:hover {
  transform: translateX(5px);
  background: var(--white);
  border-color: var(--primary);
  box-shadow: var(--shadow-md);
}

.timeline-card::before {
  content: '';
  position: absolute;
  top: 24px;
  left: -27px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background-color: var(--white);
  border: 3px solid var(--primary);
  transition: background-color var(--transition-fast);
}

.timeline-card:hover::before {
  background-color: var(--cyan);
}

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

.timeline-card h4 {
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 6px;
}

.timeline-card p {
  font-size: 0.85rem;
  color: var(--gray);
}

@media (max-width: 991px) {
  .about-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }
  
  .about-timeline {
    margin-top: 20px;
  }
}

/* --- Nuestros Cursos Section --- */
.courses-section {
  background-color: var(--gray-light);
}

/* Modern Tab Filters */
.courses-filter {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 45px;
}

.filter-btn {
  background-color: var(--white);
  color: var(--gray);
  border: 1px solid var(--gray-medium);
  font-size: 0.9rem;
  font-weight: 600;
  padding: 10px 24px;
  border-radius: 100px;
  transition: all var(--transition-fast);
  box-shadow: var(--shadow-sm);
}

.filter-btn:hover {
  color: var(--primary);
  border-color: var(--primary-light);
  background-color: var(--primary-light);
}

.filter-btn.active {
  background: linear-gradient(135deg, var(--primary) 0%, var(--cyan) 100%);
  color: var(--white);
  border-color: transparent;
  box-shadow: var(--shadow-glow);
}

/* Courses Grid Dashboard */
.courses-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 30px;
  margin-bottom: 50px;
}

.course-card {
  background: var(--white);
  border: 1px solid var(--gray-medium);
  border-radius: var(--radius-lg);
  padding: 30px;
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  transition: all var(--transition-bounce);
  position: relative;
  overflow: hidden;
}

.course-card::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 4px;
  background: linear-gradient(90deg, var(--primary), var(--cyan));
  transform: scaleX(0);
  transform-origin: left;
  transition: transform var(--transition-smooth);
}

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

.course-card:hover::after {
  transform: scaleX(1);
}

.course-icon-container {
  width: 50px;
  height: 50px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  margin-bottom: 24px;
  transition: transform var(--transition-bounce);
}

.course-card:hover .course-icon-container {
  transform: scale(1.1) rotate(5deg);
}

/* Palette variations for dynamic subjects */
.badge-blue { background-color: var(--primary-light); color: var(--primary); }
.badge-cyan { background-color: var(--cyan-light); color: var(--cyan); }
.badge-purple { background-color: rgba(139, 92, 246, 0.1); color: var(--accent); }

.course-level {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 8px;
}

.course-card h4 {
  font-size: 1.25rem;
  margin-bottom: 12px;
  color: var(--dark);
}

.course-description {
  font-size: 0.88rem;
  color: var(--gray);
  margin-bottom: 24px;
  flex-grow: 1;
}

.course-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 18px;
  border-top: 1px solid var(--gray-light);
}

.course-meta {
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--gray);
  display: flex;
  align-items: center;
  gap: 6px;
}

.course-link {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--primary);
  display: inline-flex;
  align-items: center;
  gap: 4px;
  cursor: pointer;
}

.course-link i {
  transition: transform var(--transition-fast);
}

.course-link:hover i {
  transform: translateX(4px);
}

/* Callout grid item asking for custom subject */
.course-card-custom {
  background: linear-gradient(135deg, var(--dark) 0%, var(--dark-light) 100%);
  color: var(--white);
  border-color: transparent;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  padding: 40px 30px;
}

.course-card-custom h4 {
  color: var(--white);
  font-size: 1.4rem;
  margin-bottom: 12px;
}

.course-card-custom p {
  font-size: 0.9rem;
  color: var(--gray-medium);
  margin-bottom: 24px;
}

.course-card-custom .btn {
  width: 100%;
}

/* --- ¿Por qué elegirnos? Section --- */
.why-section {
  background-color: var(--white);
}

.why-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 30px;
}

.why-card {
  background: var(--gray-light);
  border: 1px solid var(--gray-medium);
  border-radius: var(--radius-md);
  padding: 30px;
  transition: all var(--transition-fast);
}

.why-card:hover {
  background: var(--white);
  border-color: var(--primary);
  transform: translateY(-5px);
  box-shadow: var(--shadow-md);
}

.why-icon {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background: var(--white);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  box-shadow: var(--shadow-sm);
  margin-bottom: 20px;
  transition: background-color var(--transition-fast), color var(--transition-fast);
}

.why-card:hover .why-icon {
  background: linear-gradient(135deg, var(--primary), var(--cyan));
  color: var(--white);
}

.why-card h4 {
  font-size: 1.15rem;
  margin-bottom: 10px;
}

.why-card p {
  font-size: 0.88rem;
  color: var(--gray);
}

/* --- Simuladores y Recursos Section --- */
.simulator-section {
  background-color: var(--gray-light);
}

.simulator-box {
  background: var(--white);
  border: 1px solid var(--gray-medium);
  border-radius: var(--radius-xl);
  padding: 50px;
  box-shadow: var(--shadow-lg);
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 50px;
  align-items: center;
  position: relative;
  overflow: hidden;
}

.simulator-box::before {
  content: '';
  position: absolute;
  top: -20%;
  right: -20%;
  width: 350px;
  height: 350px;
  background: radial-gradient(circle, var(--cyan-light) 0%, transparent 70%);
  z-index: 1;
  pointer-events: none;
}

.simulator-info {
  position: relative;
  z-index: 2;
}

.simulator-info h3 {
  font-size: 2.2rem;
  margin-bottom: 18px;
}

.simulator-info p {
  color: var(--gray);
  margin-bottom: 30px;
}

.simulator-badges {
  display: flex;
  flex-direction: column;
  gap: 15px;
  margin-bottom: 35px;
}

.sim-badge-item {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 0.95rem;
  font-weight: 500;
}

.sim-badge-item i {
  color: var(--success);
  font-size: 1.1rem;
}

/* Premium Dashboard UI Mockup */
.simulator-mockup {
  position: relative;
  background: var(--dark);
  border-radius: var(--radius-lg);
  padding: 24px;
  box-shadow: var(--shadow-lg);
  border: 1px solid rgba(255, 255, 255, 0.1);
  overflow: hidden;
  z-index: 2;
}

.mockup-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-bottom: 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.15);
  margin-bottom: 20px;
}

.mockup-controls {
  display: flex;
  gap: 6px;
}

.mockup-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}
.dot-red { background-color: var(--error); }
.dot-yellow { background-color: hsl(45, 100%, 50%); }
.dot-green { background-color: var(--success); }

.mockup-title {
  color: var(--gray-medium);
  font-family: 'Poppins', sans-serif;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.5px;
}

.mockup-body {
  color: var(--white);
}

.mockup-question-box {
  background: var(--dark-light);
  border-radius: var(--radius-md);
  padding: 16px;
  border: 1px solid rgba(255, 255, 255, 0.05);
  margin-bottom: 16px;
}

.mockup-q-tag {
  display: inline-block;
  background: var(--primary);
  color: var(--white);
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  padding: 2px 8px;
  border-radius: 4px;
  margin-bottom: 8px;
}

.mockup-q-text {
  font-size: 0.9rem;
  font-weight: 500;
  font-family: 'Poppins', sans-serif;
  color: var(--white);
}

.mockup-options {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.mockup-option {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  font-size: 0.8rem;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.mockup-option:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: var(--cyan);
}

.mockup-option-idx {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
}

@media (max-width: 991px) {
  .simulator-box {
    grid-template-columns: 1fr;
    padding: 30px;
    gap: 30px;
  }
}

/* Live Simulator Modal Container */
/* Live Simulator Modal Container - SaaS Dashboard Edition */
.sim-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(15, 23, 42, 0.6);
  backdrop-filter: var(--backdrop-blur);
  -webkit-backdrop-filter: var(--backdrop-blur);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2000;
  opacity: 0;
  visibility: hidden;
  transition: all var(--transition-smooth);
}

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

.sim-modal-container {
  background: var(--white);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-xl);
  width: 90%;
  max-width: 960px; /* Wider for full dynamic split screen dashboard */
  height: 85vh; /* Standard SaaS dashboard viewport */
  box-shadow: var(--shadow-lg);
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: row;
  transform: scale(0.9);
  transition: transform var(--transition-bounce);
}

.sim-modal.active .sim-modal-container {
  transform: scale(1);
}

/* Modal Sidebar: Question Navigator Panel */
.sim-modal-sidebar {
  width: 280px;
  flex-shrink: 0;
  background-color: var(--gray-light);
  border-right: 1px solid var(--gray-medium);
  padding: 30px 24px;
  display: flex;
  flex-direction: column;
  gap: 20px;
  overflow-y: auto;
}

.sim-sidebar-title {
  font-family: 'Poppins', sans-serif;
  font-weight: 700;
  font-size: 1rem;
  color: var(--dark);
  display: flex;
  align-items: center;
  gap: 8px;
}

.sim-sidebar-subtitle {
  font-size: 0.8rem;
  color: var(--gray);
  line-height: 1.4;
  border-bottom: 1px dashed var(--gray-medium);
  padding-bottom: 12px;
}

.sim-nav-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
}

.sim-nav-btn {
  height: 42px;
  border-radius: var(--radius-sm);
  background-color: var(--white);
  border: 1px solid var(--gray-medium);
  font-family: 'Poppins', sans-serif;
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--dark);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all var(--transition-fast);
}

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

.sim-nav-btn.active {
  border-color: var(--primary);
  box-shadow: 0 0 0 2px var(--primary);
  color: var(--primary);
}

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

.sim-nav-btn.correct {
  background-color: hsl(142, 70%, 94%);
  border-color: var(--success);
  color: var(--success);
}

.sim-nav-btn.incorrect {
  background-color: hsl(350, 70%, 94%);
  border-color: var(--error);
  color: var(--error);
}

/* Modal Main Body (Content Viewport) */
.sim-modal-main {
  flex-grow: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  position: relative;
}

.sim-modal-close {
  position: absolute;
  top: 18px;
  right: 20px;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  color: var(--white);
  cursor: pointer;
  transition: all var(--transition-fast);
  z-index: 10;
}

.sim-modal-close:hover {
  background-color: var(--error);
  color: var(--white);
}

.sim-modal-header {
  background: var(--dark);
  color: var(--white);
  padding: 20px 30px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-shrink: 0;
}

.sim-header-details {
  display: flex;
  flex-direction: column;
}

.sim-modal-title {
  color: var(--white);
  font-size: 1.15rem;
  margin-bottom: 2px;
}

.sim-modal-subtitle {
  color: var(--gray-medium);
  font-size: 0.8rem;
}

/* Glowing digital countdown clock timer */
#sim-timer-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background-color: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.15);
  padding: 6px 14px;
  border-radius: 100px;
  font-family: 'Poppins', sans-serif;
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--cyan);
  box-shadow: 0 0 15px rgba(0, 206, 214, 0.2);
  text-shadow: 0 0 10px rgba(0, 206, 214, 0.3);
}

.sim-modal-body {
  padding: 30px;
  overflow-y: auto;
  flex-grow: 1;
}

.sim-question-text {
  font-family: 'Poppins', sans-serif;
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 24px;
  color: var(--dark);
  line-height: 1.4;
}

.sim-options-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 20px;
}

.sim-option-card {
  border: 1px solid var(--gray-medium);
  background-color: var(--white);
  padding: 14px 20px;
  border-radius: var(--radius-md);
  font-size: 0.95rem;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 15px;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.sim-option-card:hover {
  border-color: var(--primary);
  background-color: var(--primary-light);
}

.sim-option-card.selected {
  border-color: var(--primary);
  background-color: var(--primary-light);
  box-shadow: 0 0 0 2px var(--primary);
}

.sim-option-letter {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background-color: var(--gray-light);
  color: var(--dark);
  font-weight: 700;
  font-size: 0.85rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition-fast);
}

.sim-option-card:hover .sim-option-letter {
  background-color: var(--primary);
  color: var(--white);
}

.sim-option-card.selected .sim-option-letter {
  background-color: var(--primary);
  color: var(--white);
}

.sim-option-card.correct {
  border-color: var(--success);
  background-color: hsl(142, 70%, 96%);
}
.sim-option-card.correct .sim-option-letter {
  background-color: var(--success);
  color: var(--white);
}

.sim-option-card.incorrect {
  border-color: var(--error);
  background-color: hsl(350, 70%, 96%);
}
.sim-option-card.incorrect .sim-option-letter {
  background-color: var(--error);
  color: var(--white);
}

.sim-explanation-box {
  background-color: var(--gray-light);
  border-left: 4px solid var(--primary);
  padding: 16px;
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  font-size: 0.88rem;
  margin-top: 20px;
  display: none;
  animation: fadeIn 0.4s var(--transition-fast);
}

.sim-explanation-box.correct {
  border-left-color: var(--success);
}

.sim-explanation-box.incorrect {
  border-left-color: var(--error);
}

.sim-explanation-title {
  font-weight: 700;
  margin-bottom: 4px;
}

.sim-explanation-text {
  color: var(--gray);
}

/* Premium Dynamic Scorecard Layout */
.sim-scorecard {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 20px 0;
  animation: fadeIn 0.6s var(--transition-bounce) both;
}

.sim-score-badge {
  background: var(--primary-light);
  color: var(--primary);
  padding: 6px 16px;
  border-radius: 100px;
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 15px;
}

.sim-score-circle {
  width: 140px;
  height: 140px;
  border-radius: 50%;
  border: 10px solid var(--gray-medium);
  border-top-color: var(--primary);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  font-family: 'Manrope', sans-serif;
  margin-bottom: 24px;
  box-shadow: var(--shadow-glow);
  animation: spinCircle 1.2s ease-out;
}

.sim-score-percent {
  font-size: 2.2rem;
  font-weight: 800;
  color: var(--dark);
  line-height: 1.1;
}

.sim-score-label {
  font-size: 0.75rem;
  color: var(--gray);
  font-weight: 600;
}

.sim-score-title {
  font-size: 1.6rem;
  margin-bottom: 10px;
}

.sim-score-desc {
  color: var(--gray);
  max-width: 480px;
  font-size: 0.95rem;
  margin-bottom: 30px;
  line-height: 1.5;
}

.sim-score-grid {
  display: flex;
  gap: 20px;
  margin-bottom: 35px;
  width: 100%;
  max-width: 450px;
}

.sim-score-item {
  flex: 1;
  background-color: var(--gray-light);
  border: 1px solid var(--gray-medium);
  padding: 12px;
  border-radius: var(--radius-md);
  display: flex;
  flex-direction: column;
}

.sim-score-val {
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--dark);
}

.sim-score-item.green .sim-score-val { color: var(--success); }
.sim-score-item.red .sim-score-val { color: var(--error); }

.sim-score-lbl {
  font-size: 0.75rem;
  color: var(--gray);
  font-weight: 500;
  margin-top: 2px;
}

@keyframes spinCircle {
  from { transform: rotate(-90deg); }
  to { transform: rotate(0deg); }
}

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

/* ==========================================
   RESPONSIVE LAYOUT FOR SIMULATOR MODAL
   ========================================== */
@media (max-width: 768px) {
  .sim-modal-container {
    flex-direction: column;
    height: 90vh;
    max-width: 95%;
  }

  .sim-modal-sidebar {
    width: 100%;
    border-right: none;
    border-bottom: 1px solid var(--gray-medium);
    padding: 16px 20px;
    gap: 12px;
    overflow-y: hidden;
    overflow-x: auto;
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: flex-start;
  }

  .sim-sidebar-title {
    font-size: 0.85rem;
    white-space: nowrap;
    margin-bottom: 0;
  }

  .sim-sidebar-subtitle {
    display: none; /* Hide description on mobile */
  }

  .sim-nav-grid {
    display: flex;
    flex-direction: row;
    gap: 8px;
    overflow-x: auto;
    padding-bottom: 4px;
  }

  .sim-nav-btn {
    height: 36px;
    width: 36px;
    flex-shrink: 0;
    font-size: 0.8rem;
  }

  .sim-modal-header {
    padding: 15px 20px;
  }

  .sim-modal-title {
    font-size: 1rem;
  }

  #sim-timer-badge {
    padding: 4px 10px;
    font-size: 0.8rem;
  }

  .sim-modal-body {
    padding: 20px;
  }

  .sim-question-text {
    font-size: 1rem;
    margin-bottom: 18px;
  }
}

/* --- Testimonios Section --- */
.testimonials-section {
  background-color: var(--white);
  overflow: hidden;
}

.testimonials-carousel-wrapper {
  position: relative;
  width: 100%;
}

.testimonials-carousel {
  display: flex;
  gap: 30px;
  cursor: grab;
  user-select: none;
  padding: 10px;
  transition: transform 0.1s ease-out;
}

.testimonials-carousel:active {
  cursor: grabbing;
}

.testimonial-card {
  flex-shrink: 0;
  width: 380px;
  background-color: var(--gray-light);
  border: 1px solid var(--gray-medium);
  padding: 36px;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  transition: all var(--transition-smooth);
}

.testimonial-card:hover {
  background-color: var(--white);
  border-color: var(--primary);
  box-shadow: var(--shadow-md);
  transform: translateY(-4px);
}

.test-stars {
  color: hsl(45, 100%, 50%);
  display: flex;
  gap: 4px;
  margin-bottom: 20px;
}

.test-text {
  font-size: 0.95rem;
  color: var(--gray);
  font-style: italic;
  margin-bottom: 28px;
}

.test-profile {
  display: flex;
  align-items: center;
  gap: 16px;
}

.test-avatar {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--primary-light);
}

.test-info h4 {
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: 2px;
}

.test-info p {
  font-size: 0.78rem;
  color: var(--primary);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.carousel-indicators {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-top: 40px;
}

.indicator-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background-color: var(--gray-medium);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.indicator-dot.active {
  background-color: var(--primary);
  transform: scale(1.3);
}

@media (max-width: 576px) {
  .testimonial-card {
    width: 290px;
    padding: 24px;
  }
}

/* --- Ubicación Section --- */
.location-section {
  background-color: var(--gray-light);
}

.location-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 50px;
  align-items: center;
}

.map-container {
  border-radius: var(--radius-xl);
  overflow: hidden;
  border: 1px solid var(--gray-medium);
  box-shadow: var(--shadow-lg);
  height: 400px;
  position: relative;
  background-color: var(--white);
}

.map-container iframe {
  width: 100%;
  height: 100%;
  border: 0;
}

.location-info-card {
  background: var(--white);
  border: 1px solid var(--gray-medium);
  padding: 40px;
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-md);
}

.location-info-card h3 {
  font-size: 1.8rem;
  margin-bottom: 24px;
}

.location-details-list {
  display: flex;
  flex-direction: column;
  gap: 24px;
  margin-bottom: 35px;
}

.location-detail-item {
  display: flex;
  gap: 16px;
}

.location-icon {
  flex-shrink: 0;
  width: 44px;
  height: 44px;
  border-radius: var(--radius-md);
  background-color: var(--primary-light);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
}

.location-text h4 {
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: 4px;
}

.location-text p {
  font-size: 0.88rem;
  color: var(--gray);
}

@media (max-width: 991px) {
  .location-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }
}

/* --- Contacto Section --- */
.contact-section {
  background-color: var(--white);
}

.contact-grid {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 50px;
  align-items: stretch;
}

.contact-info-panel {
  background: linear-gradient(135deg, var(--dark) 0%, var(--dark-light) 100%);
  color: var(--white);
  padding: 50px;
  border-radius: var(--radius-xl);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  position: relative;
  overflow: hidden;
}

.contact-info-panel::before {
  content: '';
  position: absolute;
  bottom: -10%;
  left: -10%;
  width: 250px;
  height: 250px;
  background: radial-gradient(circle, rgba(0, 206, 214, 0.15) 0%, transparent 70%);
  z-index: 1;
}

.contact-panel-content {
  position: relative;
  z-index: 2;
}

.contact-info-panel h3 {
  color: var(--white);
  font-size: 2rem;
  margin-bottom: 16px;
}

.contact-info-panel p {
  color: var(--gray-medium);
  margin-bottom: 40px;
}

.contact-list {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.contact-item {
  display: flex;
  align-items: center;
  gap: 16px;
}

.contact-item-icon {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-md);
  background-color: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: var(--cyan);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
}

.contact-item-text p {
  margin-bottom: 0;
  font-size: 0.9rem;
  color: var(--gray-medium);
}

.contact-item-text h4 {
  color: var(--white);
  font-size: 1.1rem;
  font-weight: 600;
}

.contact-social-box {
  margin-top: 40px;
}

.contact-social-box h4 {
  color: var(--white);
  font-size: 0.95rem;
  margin-bottom: 16px;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.social-links {
  display: flex;
  gap: 12px;
}

.social-link {
  width: 36px;
  height: 36px;
  border-radius: var(--radius-sm);
  background-color: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: var(--white);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition-fast);
}

.social-link:hover {
  background-color: var(--primary);
  border-color: transparent;
  color: var(--white);
  transform: translateY(-2px);
}

/* Contact Form CSS (Floating Labels) */
.contact-form-panel {
  background: var(--gray-light);
  border: 1px solid var(--gray-medium);
  padding: 50px;
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-sm);
}

.form-title {
  font-size: 1.6rem;
  margin-bottom: 30px;
}

.contact-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.form-group {
  position: relative;
}

.form-input {
  width: 100%;
  padding: 16px 20px;
  background-color: var(--white);
  border: 1px solid var(--gray-medium);
  border-radius: var(--radius-md);
  font-size: 0.95rem;
  color: var(--dark);
  transition: all var(--transition-fast);
}

.form-input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(36, 107, 243, 0.1);
}

.form-label {
  position: absolute;
  top: 50%;
  left: 20px;
  transform: translateY(-50%);
  color: var(--gray);
  font-size: 0.95rem;
  pointer-events: none;
  transition: all var(--transition-fast);
  background-color: transparent;
  padding: 0 4px;
}

.form-input:focus ~ .form-label,
.form-input:not(:placeholder-shown) ~ .form-label {
  top: 0;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--primary);
  background-color: var(--white);
  transform: translateY(-50%);
  padding: 2px 8px;
  border-radius: 4px;
}

/* For select drop down and text area */
.form-group select {
  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml;utf8,<svg fill='%236b7280' height='24' viewBox='0 0 24 24' width='24' xmlns='http://www.w3.org/2000/svg'><path d='M7 10l5 5 5-5z'/></svg>");
  background-repeat: no-repeat;
  background-position: right 16px center;
}

.form-group textarea.form-input {
  min-height: 120px;
  resize: vertical;
}

.form-group textarea.form-input ~ .form-label {
  top: 24px;
  transform: none;
}

.form-group textarea.form-input:focus ~ .form-label,
.form-group textarea.form-input:not(:placeholder-shown) ~ .form-label {
  top: 0;
  transform: translateY(-50%);
}

.form-error-msg {
  font-size: 0.78rem;
  color: var(--error);
  font-weight: 500;
  margin-top: 4px;
  display: none;
}

.form-input.invalid {
  border-color: var(--error) !important;
}

.form-input.invalid ~ .form-label {
  color: var(--error) !important;
}

/* Form Success Modal */
.form-success-overlay {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  background-color: var(--white);
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border-radius: var(--radius-xl);
  padding: 40px;
  z-index: 10;
  opacity: 0;
  visibility: hidden;
  transition: all var(--transition-smooth);
}

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

.success-check-icon {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background-color: hsl(142, 70%, 96%);
  color: var(--success);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 3rem;
  margin-bottom: 24px;
  box-shadow: 0 8px 24px rgba(16, 185, 129, 0.15);
  animation: scaleBounce 0.6s var(--transition-bounce) both;
}

@keyframes scaleBounce {
  0% { transform: scale(0.6); opacity: 0; }
  100% { transform: scale(1); opacity: 1; }
}

@media (max-width: 991px) {
  .contact-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }
}

/* --- Floating WhatsApp Button --- */
.whatsapp-float {
  position: fixed;
  bottom: 30px;
  right: 30px;
  width: 60px;
  height: 60px;
  background-color: hsl(142, 70%, 45%);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--white);
  font-size: 2rem;
  box-shadow: 0 10px 25px rgba(16, 185, 129, 0.35);
  z-index: 999;
  cursor: pointer;
  transition: transform var(--transition-bounce), background-color var(--transition-fast);
}

.whatsapp-float::before, .whatsapp-float::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 100%;
  height: 100%;
  border-radius: 50%;
  border: 1px solid hsl(142, 70%, 45%);
  opacity: 0.8;
  z-index: -1;
  animation: pulse-ring 2.5s infinite ease-out;
}

.whatsapp-float::after {
  animation-delay: 1.2s;
}

.whatsapp-float:hover {
  transform: scale(1.08) translateY(-3px);
  background-color: hsl(142, 70%, 40%);
}

@keyframes pulse-ring {
  0% { width: 100%; height: 100%; opacity: 0.8; }
  100% { width: 170%; height: 170%; opacity: 0; }
}

/* --- Footer --- */
.site-footer {
  background-color: var(--dark);
  color: var(--gray-medium);
  padding: 80px 0 30px;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.2fr repeat(3, 0.6fr);
  gap: 40px;
  margin-bottom: 60px;
}

.footer-brand {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.footer-brand .brand-logo {
  color: var(--white);
}

.footer-desc {
  font-size: 0.9rem;
  color: var(--gray);
  max-width: 280px;
}

.footer-socials {
  display: flex;
  gap: 10px;
}

.footer-col-title {
  color: var(--white);
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: 24px;
  position: relative;
  padding-bottom: 8px;
}

.footer-col-title::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 25px;
  height: 2px;
  background: var(--cyan);
}

.footer-links {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.footer-link-item a {
  font-size: 0.9rem;
  color: var(--gray);
}

.footer-link-item a:hover {
  color: var(--cyan);
  padding-left: 4px;
}

.footer-contact-info {
  display: flex;
  flex-direction: column;
  gap: 16px;
  font-size: 0.9rem;
}

.footer-contact-item {
  display: flex;
  gap: 12px;
  align-items: flex-start;
}

.footer-contact-item i {
  color: var(--cyan);
  margin-top: 3px;
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  padding-top: 30px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 20px;
}

.footer-bottom p {
  font-size: 0.85rem;
  color: var(--gray);
}

.footer-bottom-links {
  display: flex;
  gap: 24px;
}

.footer-bottom-links a {
  font-size: 0.85rem;
  color: var(--gray);
}

.footer-bottom-links a:hover {
  color: var(--cyan);
}

@media (max-width: 991px) {
  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 40px;
  }
}

@media (max-width: 576px) {
  .footer-grid {
    grid-template-columns: 1fr;
  }
  
  .footer-bottom {
    flex-direction: column;
    text-align: center;
  }
}

/* --- Scroll Reveal Animations Class --- */
.reveal {
  opacity: 0;
  transform: translateY(35px) scale(0.98);
  transition: opacity 0.8s cubic-bezier(0.25, 1, 0.5, 1), transform 0.8s cubic-bezier(0.25, 1, 0.5, 1);
}

.reveal.active {
  opacity: 1;
  transform: translateY(0) scale(1);
}

/* ==========================================================================
   Aprende Ya - Advanced SPA Routing & Dynamic EPN Quiz Styles
   ========================================================================== */

/* SPA single-page routing visibility */
.site-section:not(.active-section),
#inicio:not(.active-section),
#quienes-somos:not(.active-section),
#por-que-elegirnos:not(.active-section),
#cursos:not(.active-section),
#simuladores:not(.active-section),
#testimonios:not(.active-section),
#ubicacion:not(.active-section),
#contacto:not(.active-section) {
  display: none !important;
}

/* Force reveal children inside active section to be beautifully displayed instantly */
.active-section .reveal, 
.active-section.reveal {
  opacity: 1 !important;
  transform: translateY(0) scale(1) !important;
  transition: opacity 0.4s ease-out, transform 0.4s ease-out !important;
}

/* Premium Empty State Fallback Cards */
.empty-state-card {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-lg);
  padding: 50px 30px;
  text-align: center;
  max-width: 600px;
  margin: 40px auto;
  box-shadow: var(--shadow-md);
  backdrop-filter: var(--backdrop-blur);
  transition: var(--transition-smooth);
  animation: fadeInUp 0.6s ease-out;
}

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

.empty-state-icon {
  font-size: 3.5rem;
  color: var(--cyan);
  margin-bottom: 20px;
  animation: pulse-glow 2s infinite ease-in-out;
}

.empty-state-card h3 {
  font-size: 1.8rem;
  margin-bottom: 12px;
  color: var(--dark);
}

.empty-state-card p {
  color: var(--gray);
  font-size: 1.05rem;
  line-height: 1.6;
}

@keyframes pulse-glow {
  0%, 100% { opacity: 0.7; transform: scale(1); }
  50% { opacity: 1; transform: scale(1.08); filter: drop-shadow(0 0 10px rgba(0, 206, 214, 0.4)); }
}

/* Dynamic simulator navigator button grid */
.sim-nav-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(42px, 1fr));
  gap: 8px;
  margin-top: 15px;
  max-height: 280px;
  overflow-y: auto;
  padding-right: 4px;
}

.sim-nav-btn {
  height: 42px;
  border-radius: var(--radius-sm);
  background: var(--gray-light);
  border: 1px solid var(--gray-medium);
  color: var(--dark);
  font-weight: 600;
  font-size: 0.9rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition-fast);
}

.sim-nav-btn:hover {
  background: var(--white);
  border-color: var(--primary);
  transform: translateY(-2px);
}

.sim-nav-btn.active {
  background: var(--primary-light) !important;
  border-color: var(--primary) !important;
  box-shadow: var(--shadow-glow) !important;
  color: var(--primary) !important;
  transform: scale(1.05);
}

.sim-nav-btn.correct {
  background: rgba(16, 185, 129, 0.15) !important;
  border-color: var(--success) !important;
  color: var(--success) !important;
}

.sim-nav-btn.incorrect {
  background: rgba(239, 68, 68, 0.15) !important;
  border-color: var(--error) !important;
  color: var(--error) !important;
}

/* responsive mobile sidebar collapse for EPN simulator */
@media (max-width: 768px) {
  .sim-workspace-container {
    flex-direction: column !important;
    height: auto !important;
    max-height: none !important;
  }
  .sim-modal-sidebar {
    width: 100% !important;
    border-right: none !important;
    border-bottom: 1px solid rgba(0, 0, 0, 0.08) !important;
    padding: 15px !important;
    flex-shrink: 0 !important;
  }
  .sim-nav-grid {
    display: flex !important;
    flex-direction: row !important;
    overflow-x: auto !important;
    padding-bottom: 8px !important;
    gap: 8px !important;
    white-space: nowrap !important;
    scrollbar-width: thin;
    max-height: none !important;
  }
  .sim-nav-btn {
    flex: 0 0 42px !important;
  }
  .sim-modal-main {
    flex: 1 !important;
    overflow-y: auto !important;
  }
}

/* Keyframes for scorecard entry */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
