/* ========================================
   VARIABLES CSS PRINCIPALES
======================================== */
:root {
  /* Colores principales */
  --primary-lighter: hsl(206, 62%, 75%);
  --primary-light: #567c8d;
  --primary-main: #2b7bb8;
  --primary-dark: #1e376d;
  --primary-darker: hsl(221, 57%, 17%);
  --gris-perla: #E6E6E8;
  --azul-pizarra: #5B7B9A;
  --verde: #00ffae;
  
  /* Gradientes unificados */
  --accent-gradient: linear-gradient(135deg, #8c1c40, #c9164f);
  --accent-gradient-hover: linear-gradient(135deg, #9b1643, #eb0335);
  --primary-gradient: linear-gradient(135deg, var(--primary-main), var(--primary-dark));
  --primary-gradient-reverse: linear-gradient(135deg, var(--primary-dark), var(--primary-main));
  --light-gradient: linear-gradient(135deg, var(--gris-perla), white);
  --border-gradient: linear-gradient(135deg, var(--primary-main), var(--primary-light));
  
  /* Sombras unificadas */
  --shadow-sm: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
  --shadow-md: 0 10px 25px -5px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
  --shadow-lg: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
  --shadow-xl: 0 20px 40px -10px rgba(0, 0, 0, 0.12);
  --shadow-hover: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
  --shadow-primary: 0 8px 25px rgba(43, 123, 184, 0.3);
  --shadow-primary-hover: 0 12px 35px rgba(43, 123, 184, 0.4);
  --shadow-accent: 0 4px 15px rgba(216, 60, 84, 0.4);
  --shadow-accent-hover: 0 6px 20px rgba(216, 60, 84, 0.5);
  --shadow-red: 0 12px 40px rgba(235, 3, 53, 0.15);
  --shadow-blue: 0 8px 30px rgba(43, 123, 184, 0.15);
  --shadow-blue-hover: 0 20px 50px rgba(43, 123, 184, 0.25);
  
  /* Transiciones unificadas */
  --transition-fast: all 0.2s ease;
  --transition-default: all 0.3s ease;
  --transition-smooth: all 0.4s ease;
  --transition-hover: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  --transition-slide: all 0.4s ease-out;
  
  /* Transforms unificados */
  --hover-lift-sm: translateY(-2px);
  --hover-lift-md: translateY(-5px);
  --hover-lift-lg: translateY(-8px);
  --hover-scale-sm: scale(1.02);
  --hover-scale-md: scale(1.05);
  --hover-scale-lg: scale(1.1);
}

/* ========================================
   RESET Y BASE
======================================== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: 'Poppins', sans-serif;
}

*::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

*::-webkit-scrollbar-track {
  background-color: var(--primary-darker);
}

*::-webkit-scrollbar-thumb {
  background: var(--primary-main);
  border-radius: 2rem;
}

body {
  line-height: 1.5;
  color: black;
  background-color: white;
}

/* ========================================
   ANIMACIONES GLOBALES
======================================== */
@keyframes float {
  0%, 100% { transform: translateY(0px); }
  50% { transform: translateY(-20px); }
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.8; }
}

@keyframes pulse-ring {
  0% { transform: scale(1); opacity: 1; }
  100% { transform: scale(1.3); opacity: 0; }
}

@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes infiniteScroll {
  0% { transform: translateX(100vw); }
  100% { transform: translateX(-50vw); }
}

@keyframes gradient {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

@keyframes wave {
  0% { transform: translateX(-50%) translateZ(0) scaleY(1); }
  50% { transform: translateX(-25%) translateZ(0) scaleY(0.55); }
  100% { transform: translateX(0) translateZ(0) scaleY(1); }
}

/* ========================================
   LAYOUT Y CONTENEDORES
======================================== */
.container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 1rem;
}

/* Clases compartidas para fondos de sección */
.section-wave-bg {
  position: relative;
  background-image: url('../images/wave-gradient.png');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

.section-wave-bg::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #f8fafc;
}

.section-wave-bg.proceso-variant::before {
  background-color: #f8fafcc9;
}

.section-with-container {
  padding: 3rem 0;
}

.container-relative {
  position: relative;
  z-index: 1;
}

/* ========================================
   HEADER
======================================== */

.header {
  position: fixed;
  top: 1rem;
  left: 50%;
  transform: translateX(-50%);
  width: 90%;
  max-width: 1200px;
  background: rgba(17, 25, 40, 0.55);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 50;
  border-radius: 0.8rem;
  transition: all 0.4s ease;
  border: 1px solid rgba(255, 255, 255, 0.1);
  padding: 0.5rem;
}

.header.scroll-down {
  transform: translate(-50%, -100%);
  opacity: 0;
}

.header.scroll-up {
  transform: translate(-50%, 0);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

.logo {
  height: 2.25rem;
  width: 2.25rem;
  padding: 0.15rem;
  background-color: rgb(255, 255, 255);
  border-radius: 0.55rem;
  box-shadow: var(--shadow-sm);
  transition: var(--transition-default);
}

.nav-container {
  padding: 0.5rem 1rem;
  margin: 0 auto;
}

.nav-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.nav-left {
  display: flex;
  align-items: center;
  gap: 2.5rem;
}

.nav-links {
  display: none;
}

@media (min-width: 768px) {
  .nav-links {
    display: flex;
    gap: 2rem;
  }
}

.nav-links a {
  color: rgba(255, 255, 255, 0.7);
  text-decoration: none;
  font-size: 0.875rem;
  font-weight: 500;
  transition: color 0.2s;
  padding: 0.5rem 0;
}

.nav-links a:hover {
  color: rgba(255, 255, 255, 1);
}

.nav-right {
  display: flex;
  align-items: center;
  gap: 1rem;
}



/* ========================================
   TIPOGRAFÍA Y TÍTULOS
======================================== */
.hero h1 {
  font-size: 4rem;
  font-weight: 800;
  line-height: 1.1;
  margin-bottom: -1rem;
  letter-spacing: -0.025em;
}

/* Títulos unificados para todas las secciones */
.features h2,
.testimonials h2,
.pricing h2,
.education h2,
.proceso h2,
.faq h2,
.roi-comparison h2,
.legal h2 {
  font-size: 2.25rem;
  font-weight: 800;
  color: black;
  text-align: center;
  margin-bottom: 1rem;
}

.section-description {
  text-align: center;
  color: var(--primary-dark);
  font-size: 1.25rem;
  max-width: 36rem;
  margin: 0 auto 1rem auto;
}

.hero-subtitle {
  font-size: 1.2rem;
  max-width: 36rem;
  margin: 0 auto 2rem;
}

.trial-info {
  font-size: 0.875rem;
}

/* ========================================
   BOTONES UNIFICADOS
======================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.5rem 1rem;
  border-radius: 0.375rem;
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  transition: var(--transition-fast);
  border: none;
}

.btn-primary {
  background: var(--accent-gradient);
  color: white;
  transition: var(--transition-default);
}

.btn-primary:hover {
  background: var(--accent-gradient-hover);
  box-shadow: var(--shadow-hover);
  transform: var(--hover-lift-sm);
}

/* Botones grandes con animación */
.btn-primary-lg,
.btn-formacion-lg {
  display: inline-block;
  padding: 1.2rem 2.5rem;
  font-size: 1.1rem;
  font-weight: 600;
  color: #ffffff;
  border: none;
  border-radius: 2px;
  text-transform: uppercase;
  letter-spacing: 1px;
  cursor: pointer;
  transition: var(--transition-default);
  position: relative;
  overflow: hidden;
  z-index: 1;
  animation: float 5s infinite;
}

.btn-primary-lg {
  background: var(--accent-gradient);
  box-shadow: var(--shadow-accent);
}

.btn-formacion-lg {
  background: var(--primary-gradient);
  box-shadow: 0 4px 15px rgba(100, 181, 246, 0.4);
}

.btn-primary-lg::before,
.btn-formacion-lg::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  transition: var(--transition-slide);
  z-index: -1;
}

.btn-primary-lg::before {
  background-color: #b93347;
}

.btn-formacion-lg::before {
  background-color: var(--primary-main);
}

.btn-primary-lg:hover::before,
.btn-formacion-lg:hover::before {
  left: 0;
}

.btn-primary-lg:hover {
  transform: var(--hover-lift-sm);
  box-shadow: var(--shadow-accent-hover);
  background: var(--accent-gradient-hover);
}

.btn-formacion-lg:hover {
  transform: var(--hover-lift-sm);
  box-shadow: 0 6px 20px rgba(100, 181, 246, 0.5);
}

.btn-primary-lg:active,
.btn-formacion-lg:active {
  transform: translateY(1px);
}

.btn-outline {
  background-color: transparent;
  border: 1px solid rgba(0, 0, 0, 0.3);
  color: black;
}

.btn-outline:hover {
  border-color: var(--primary-main);
  color: var(--primary-main);
}

.btn-full {
  width: 100%;
}

.btn-submit {
  background: var(--primary-gradient);
  color: white;
  transition: all 0.3s ease;
  }

.btn-submit:hover {
  background: linear-gradient(135deg, #193166, #1f669c);
  box-shadow: var(--shadow-hover);
  transform: translateY(-2px);
}

/* ========================================
   SECCIONES PRINCIPALES
======================================== */

/* Hero Section */
.hero {
  padding: 8rem 0 4rem;
  text-align: center;
  position: relative;
  color: white;
  overflow: hidden;
}

.background-video {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: -1;
}

.hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(0, 2, 37, 0.7);
  z-index: 0;
}

.hero h1,
.hero-subtitle,
.cta-container,
.trial-info {
  position: relative;
  z-index: 1;
}

.cta-container {
  margin-bottom: 1rem;
}

/* Trusted By Section */
.trusted-by {
  padding: 2rem 0;
  position: relative;
  background-color: #f8fafc;
  overflow: hidden;
}

.trusted-by::before {
  content: '';
  position: absolute;
  width: 100%;
  height: 100%;
  top: 0;
  left: 0;
  background-image: radial-gradient(#1e88e5 1px, transparent 1px);
  background-size: 50px 50px;
  opacity: 0.1;
  animation: float 6s ease-in-out infinite;
}

.trusted-by-title {
  text-align: center;
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  color: black;
  margin-bottom: 0.5rem;
}

.logo-grid {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 3rem;
  flex-wrap: wrap;
  position: relative;
  z-index: 1;
}

.client-logo {
  height: 4rem;
  opacity: 0.7;
  transition: all 0.4s ease;
  filter: grayscale(10%);
}

.client-logo:hover {
  opacity: 0.9;
  filter: grayscale(0%);
  transform: scale(1.05);
}

/* Demo Video Section */
.demo-video {
  padding: 4rem 0;
  position: relative;
  overflow: hidden;
}

.video-container {
  position: relative;
  width: 100%;
  max-width: 1000px;
  margin: 0 auto;
  background: rgba(255, 255, 255, 0.9);
  border-radius: 0.55rem;
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  backdrop-filter: blur(10px);
  border: 1px solid var(--primary-lighter);
  transition: var(--transition-default);
}

.video-container:hover {
  box-shadow: 0 5px 25px -2px rgba(0, 0, 0, 0.2), 0 10px 10px -2px rgba(0, 0, 0, 0.14);
}

.demo-player {
  width: 100%;
  display: block;
  aspect-ratio: 16 / 9;
  object-fit: cover;
}

.youtube-container {
  position: relative;
  width: 100%;
  padding-bottom: 56.25%;
  height: 0;
  overflow: hidden;
}

.youtube-container iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}

/* ========================================
   FEATURES SECTION
======================================== */
.features {
  display: flex;
  width: 100%;
  text-align: center;
  justify-content: center;
  margin-bottom: 2rem;
}

/* .features::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #f8fafc;
} */

.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 2rem;
}

.feature-card {
  text-align: center;
  padding: 2.5rem;
  background-color: white;
  border-radius: 0.7rem;
  box-shadow: var(--shadow-md);
  transition: var(--transition-default);
  border: 1px solid rgba(43, 123, 184, 0.1);
  position: relative;
  overflow: hidden;
}

.feature-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: var(--border-gradient);
  opacity: 0;
  transition: var(--transition-default);
}

.feature-card:hover {
  transform: var(--hover-lift-lg);
  box-shadow: 0 20px 40px -10px rgba(43, 123, 184, 0.15), 0 8px 16px -4px rgba(0, 0, 0, 0.1);
  border-color: rgba(43, 123, 184, 0.2);
}

.feature-card:hover::before {
  opacity: 1;
}

.feature-icon {
  background: var(--primary-gradient);
  color: white;
  width: 4.5rem;
  height: 4.5rem;
  border-radius: 0.75rem;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 2rem auto;
  box-shadow: var(--shadow-primary);
  transition: var(--transition-default);
}

.feature-card:hover .feature-icon {
  transform: var(--hover-scale-lg);
  box-shadow: var(--shadow-primary-hover);
}

.feature-card h3 {
  color: black;
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: 1rem;
}

.feature-card p {
  color: var(--primary-dark);
  text-align: justify;
  line-height: 1.7;
  font-size: 1rem;
  margin: 0;
}

.icon {
  width: 2rem;
  height: 2rem;
}

/* ========================================
   ROI COMPARISON SECTION
======================================== */
.roi-comparison {
  padding: 4rem 0;
  background: white;
  position: relative;
}

.roi-comparison .section-description {
  color: var(--primary-dark);
  text-align: center;
  font-size: 1rem;
  margin-bottom: 2.5rem;
}

.comparison-container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  max-width: 900px;
  margin: 0 auto;
}

.comparison-card {
  background: white;
  border-radius: 0.6rem;
  padding: 1.5rem;
  position: relative;
  transition: var(--transition-hover);
  min-height: 420px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

.comparison-card.traditional {
  border: 1px solid rgba(235, 3, 53, 0.3);
  z-index: 1;
}

.comparison-card.traditional:hover {
  transform: var(--hover-lift-lg) var(--hover-scale-sm);
  box-shadow: var(--shadow-red);
  border-color: rgba(235, 3, 53, 0.6);
}

.comparison-card.optimized {
  border: 2px solid var(--primary-main);
  box-shadow: var(--shadow-blue);
  z-index: 2;
  transform: translateX(-50px);
}

.comparison-card.optimized:hover {
  transform: translateX(-50px) translateY(-12px) scale(1.03);
  box-shadow: var(--shadow-blue-hover);
  border-color: var(--primary-dark);
}

.card-header {
  margin-bottom: 1.5rem;
  position: relative;
}

.card-header h3 {
  font-size: 1.3rem;
  font-weight: 700;
  margin-bottom: 0.25rem;
  color: var(--primary-dark);
}

.optimized .card-header h3 {
  color: var(--primary-main);
}

.card-subtitle {
  font-size: 0.8rem;
  color: var(--primary-dark);
  margin-bottom: 1rem;
  opacity: 0.7;
}

.premium-badge {
  position: absolute;
  top: 1rem;
  right: 1rem;
  background: var(--primary-gradient);
  color: white;
  padding: 0.4rem 0.8rem;
  border-radius: 0.35rem;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 1px;
  box-shadow: 0 2px 8px rgba(43, 123, 184, 0.4);
  transition: var(--transition-default);
}

.comparison-card.optimized:hover .premium-badge {
  transform: var(--hover-scale-lg) rotate(-1deg);
  box-shadow: 0 4px 15px rgba(43, 123, 184, 0.6);
  background: var(--primary-gradient-reverse);
}

.metrics-container {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.metric-item {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem;
  background: var(--gris-perla);
  border-radius: 0.35rem;
  transition: var(--transition-default);
  border: 1px solid rgba(43, 123, 184, 0.1);
}

.comparison-card:hover .metric-item {
  transform: translateX(5px);
}

.comparison-card.traditional:hover .metric-item {
  background: rgba(235, 3, 53, 0.05);
  border-color: rgba(235, 3, 53, 0.2);
}

.comparison-card.optimized:hover .metric-item {
  background: rgba(43, 123, 184, 0.08);
  border-color: rgba(43, 123, 184, 0.3);
}

.optimized .metric-item {
  background: rgba(43, 123, 184, 0.05);
  border-left: 3px solid var(--primary-main);
}

.metric-icon {
  background: var(--accent-gradient);
  color: white;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 0.35rem;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: var(--transition-default);
}

.optimized .metric-icon {
  background: var(--primary-main);
}

.comparison-card:hover .metric-icon {
  transform: var(--hover-scale-lg) rotate(1deg);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.comparison-card.traditional:hover .metric-icon {
  background: var(--accent-gradient-hover);
}

.comparison-card.optimized:hover .metric-icon {
  background: var(--primary-dark);
}

.metric-content {
  flex: 1;
}

.metric-content h4 {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--primary-dark);
  margin-bottom: 0.25rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  opacity: 0.8;
}

.metric-value {
  font-size: 2.2rem;
  font-weight: 700;
  color: var(--primary-dark);
  margin-bottom: 0.1rem;
  line-height: 1;
  transition: var(--transition-default);
}

.comparison-card:hover .metric-value {
  transform: var(--hover-scale-md);
}

.optimized .metric-value {
  color: var(--primary-main);
}

.metric-label {
  font-size: 0.75rem;
  color: var(--primary-dark);
  line-height: 1.2;
  opacity: 0.6;
}

.improvement {
  display: inline-block;
  background: var(--azul-pizarra);
  color: white;
  padding: 0.2rem 0.5rem;
  border-radius: 0.3rem;
  font-size: 0.7rem;
  font-weight: 700;
  margin-left: 0.5rem;
  transition: var(--transition-default);
}

.comparison-card.optimized:hover .improvement {
  transform: var(--hover-scale-lg);
  background: var(--primary-main);
  animation: pulse 2s infinite;
}

.result-badge {
  margin-top: 1.5rem;
  padding: 1rem;
  border-radius: 0.35rem;
  text-align: left;
  font-size: 0.85rem;
  line-height: 1.4;
}

.traditional-result {
  background: rgba(235, 3, 53, 0.1);
  border: 1px solid rgba(235, 3, 53, 0.3);
  color: var(--primary-dark);
}

.optimized-result {
  background: rgba(43, 123, 184, 0.1);
  border: 1px solid var(--primary-main);
  color: var(--primary-dark);
}

.bonus {
  display: block;
  margin-top: 0.3rem;
  color: var(--azul-pizarra);
  font-weight: 700;
  font-size: 0.8rem;
}

/* ========================================
   LEGAL SECTION - CARTAS CON EFECTO DE GIRO 3D
======================================== */
.legal {
  padding: 4rem 0;
  background: white;
  position: relative;
}

.legal-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
  margin-top: 3rem;
  max-width: 1400px;
  margin-left: auto;
  margin-right: auto;
  align-items: start;
}

.legal-card {
  background: transparent;
  border-radius: 1.5rem;
  position: relative;
  height: 300px;
  perspective: 1000px;
  cursor: pointer;
}

/* Ocultar el input checkbox */
.legal-toggle-input {
  display: none;
}

/* Contenedor interno de la carta */
.legal-card-inner {
  position: relative;
  width: 100%;
  height: 100%;
  text-align: center;
  transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
  transform-style: preserve-3d;
  display: block;
  cursor: pointer;
}

/* Efecto de giro cuando está marcado */
.legal-toggle-input:checked + .legal-card-inner {
  transform: rotateY(180deg);
}

/* Estilos para ambas caras de la carta */
.legal-card-front,
.legal-card-back {
  position: absolute;
  width: 100%;
  height: 100%;
  backface-visibility: hidden;
  border-radius: 1.5rem;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  border: 1px solid rgba(43, 123, 184, 0.1);
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 2rem;
  background: white;
}

/* Cara frontal */
.legal-card-front {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
}

/* Cara trasera */
.legal-card-back {
  transform: rotateY(180deg);
  background: linear-gradient(135deg, rgba(43, 123, 184, 0.05) 0%, rgba(43, 123, 184, 0.02) 100%);
  border: 2px solid rgba(43, 123, 184, 0.2);
  padding: 0;
}

/* Efecto hover en la carta */
.legal-card:hover .legal-card-front {
  transform: translateY(-4px);
  box-shadow: 0 12px 30px rgba(43, 123, 184, 0.15);
  border-color: rgba(43, 123, 184, 0.2);
}

.legal-card:hover .legal-card-back {
  transform: rotateY(180deg) translateY(-4px);
  box-shadow: 0 12px 30px rgba(43, 123, 184, 0.15);
  border-color: rgba(43, 123, 184, 0.3);
}

/* Icono de la carta */
.legal-icon {
  background: var(--primary-gradient);
  color: white;
  width: 4rem;
  height: 4rem;
  border-radius: 1.25rem;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1.5rem auto;
  box-shadow: 0 4px 15px rgba(43, 123, 184, 0.3);
  transition: all 0.3s ease;
}

.legal-card:hover .legal-icon {
  transform: scale(1.05);
  box-shadow: 0 6px 20px rgba(43, 123, 184, 0.4);
}

/* Título de la carta */
.legal-card-title {
  text-align: center;
  margin-bottom: 1rem;
}

.legal-card-title h3 {
  color: var(--primary-dark);
  font-size: 1.3rem;
  font-weight: 700;
  margin: 0 0 0.5rem 0;
  line-height: 1.3;
}

.legal-summary {
  color: #64748b;
  font-size: 0.95rem;
  line-height: 1.5;
  margin: 0;
  opacity: 0.9;
  text-align: center;
}


/* Contenido de la cara trasera */
.legal-card-content {
  text-align: left;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  padding: 2rem;
}

.legal-card-content h3 {
  color: var(--primary-main);
  font-size: 1.3rem;
  font-weight: 700;
  margin: 0 0 1rem 0;
  line-height: 1.3;
  text-align: center;
  width: 100%;
}

.legal-card-content p {
  color: var(--primary-dark);
  line-height: 1.7;
  font-size: 1rem;
  margin: 0;
  text-wrap: stable;
  opacity: 0.9;
  width: 100%;
}

/* Efectos cuando la carta está girada */
.legal-toggle-input:checked + .legal-card-inner .legal-card-front {
  box-shadow: 0 8px 25px rgba(43, 123, 184, 0.2);
  border-color: rgba(43, 123, 184, 0.3);
}

.legal-toggle-input:checked + .legal-card-inner .legal-card-back {
  box-shadow: 0 8px 25px rgba(43, 123, 184, 0.2);
  border-color: rgba(43, 123, 184, 0.3);
}


/* Responsive para tablet */
@media (max-width: 1024px) {
  .legal-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
    max-width: 1000px;
  }
  
  .legal-card {
    height: 280px;
  }
}

/* Responsive para móvil */
@media (max-width: 768px) {
  .legal-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
    margin-top: 2rem;
    max-width: 100%;
    padding: 0 1rem;
  }
  
  .legal-card {
    height: 250px;
  }
  
  .legal-card-front,
  .legal-card-back {
    padding: 1.5rem;
  }
  
  .legal-icon {
    width: 3rem;
    height: 3rem;
    margin-bottom: 1rem;
  }
  
  .legal-card-title h3 {
    font-size: 1.2rem;
  }
  
  .legal-summary {
    font-size: 0.9rem;
  }
  
  .legal-card-content h3 {
    font-size: 1.2rem;
  }
  
  .legal-card-content p {
    font-size: 0.95rem;
  }
}

@media (max-width: 480px) {
  .legal-card {
    height: 220px;
  }
  
  .legal-card-front,
  .legal-card-back {
    padding: 1.25rem;
  }
  
  .legal-icon {
    width: 2.5rem;
    height: 2.5rem;
    margin-bottom: 0.75rem;
  }
  
  .legal-card-title h3 {
    font-size: 1.1rem;
  }
  
  .legal-summary {
    font-size: 0.85rem;
  }
  
  .legal-card-content h3 {
    font-size: 1.1rem;
  }
  
  .legal-card-content p {
    font-size: 0.9rem;
  }
  
}

/* ========================================
   TESTIMONIALS SECTION
======================================== */
.testimonials {
  padding: 5rem 0;
  overflow: hidden;
}

.container-testimonials {
  max-width: 100%;
  margin: 0 auto;
  padding: 0;
  text-align: center;
}

.testimonials-wrapper {
  position: relative;
  overflow: hidden;
  margin-top: 1rem;
  height: 22rem;
  mask: linear-gradient(90deg, transparent, white 20%, white 80%, transparent);
  -webkit-mask: linear-gradient(90deg, transparent, white 20%, white 80%, transparent);
}

.testimonials-track {
  display: flex;
  gap: 2rem;
  position: relative;
  width: max-content;
  will-change: transform;
}

.testimonial-card {
  flex: 0 0 auto;
  width: 40vw;
  min-width: 40vw;
  height: max-content;
  background-color: white;
  border-radius: 0.6rem;
  padding: 2rem;
  transition: var(--transition-default);
  box-shadow: var(--shadow-sm);
  position: absolute;
  animation: infiniteScroll 90s linear infinite;
}

.testimonial-card:nth-child(1) { animation-delay: -2s; }
.testimonial-card:nth-child(2) { animation-delay: -32s; }
.testimonial-card:nth-child(3) { animation-delay: -62s; }

.testimonial-card:hover {
  transform: var(--hover-lift-md);
  box-shadow: var(--shadow-lg);
}

.testimonial-content {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.testimonial-text {
  color: black;
  font-size: 1.125rem;
  line-height: 1.75;
  font-style: italic;
  text-align: justify;
}

.testimonial-author {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.author-image {
  width: 60px;
  height: 60px;
  border-radius: 30%;
  background: var(--primary-gradient);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 24px;
  font-weight: bold;
  text-transform: uppercase;
  box-shadow: 0 4px 15px rgba(102, 159, 234, 0.3);
}

.author-info h4 {
  color: black;
  font-weight: 600;
  font-size: 1rem;
  margin: 0;
  text-align: left;
}

.author-info p {
  color: var(--primary-dark);
  font-size: 0.875rem;
  margin: 0;
  text-align: left;
}

/* ========================================
   PROCESO SECTION
======================================== */
.proceso {
  /* Utiliza clases compartidas para fondo: .section-wave-bg.proceso-variant .section-with-container */
  display: flex;
  width: 100%;
  text-align: center;
  justify-content: center;
  margin-bottom: 2rem;
}

.proceso-container {
  /* Extiende .container con modificaciones específicas */
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
  text-align: center;
}

.proceso-flow {
  display: flex;
  justify-content: space-between;
  align-items: stretch;
  gap: 2rem;
  margin-top: 4rem;
  position: relative;
}

.proceso-step {
  flex: 1;
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  max-width: 350px;
}

.step-number {
  width: 4rem;
  height: 4rem;
  background: var(--primary-gradient);
  color: white;
  border-radius: 30%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  font-weight: 800;
  margin-bottom: 1.5rem;
  box-shadow: var(--shadow-primary);
  transition: var(--transition-smooth);
  position: relative;
  z-index: 3;
}

.step-number::before {
  content: '';
  position: absolute;
  width: 120%;
  height: 120%;
  border: 2px solid rgba(43, 123, 184, 0.2);
  border-radius: 30%;
  animation: pulse-ring 2s infinite;
}

.step-content {
  background: white;
  border-radius: 0.75rem;
  padding: 2rem;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
  transition: var(--transition-smooth);
  border: 1px solid rgba(43, 123, 184, 0.1);
  position: relative;
  z-index: 2;
}

.step-content:hover {
  transform: var(--hover-lift-lg);
  box-shadow: var(--shadow-xl);
  border-color: rgba(43, 123, 184, 0.2);
}

.step-icon {
  width: 4rem;
  height: 4rem;
  background: var(--light-gradient);
  border-radius: 0.6rem;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1.5rem;
  transition: var(--transition-default);
  border: 2px solid rgba(43, 123, 184, 0.1);
}

.step-icon .icon {
  width: 2rem;
  height: 2rem;
  color: var(--primary-main);
}

.step-content:hover .step-icon {
  background: var(--primary-gradient);
  border-color: var(--primary-main);
  transform: var(--hover-scale-lg);
}

.step-content:hover .step-icon .icon {
  color: white;
}

.step-content h3 {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--primary-dark);
  margin-bottom: 1rem;
}

.step-content p {
  color: var(--primary-dark);
  line-height: 1.6;
  opacity: 0.8;
  text-align: justify;
}

.step-connector {
  position: absolute;
  top: 2rem;
  right: -1rem;
  width: 2rem;
  height: 2px;
  background: linear-gradient(90deg, var(--primary-main), transparent);
  z-index: 1;
}

.step-connector::after {
  content: '';
  position: absolute;
  right: -8px;
  top: -3px;
  width: 0;
  height: 0;
  border-left: 8px solid var(--primary-main);
  border-top: 4px solid transparent;
  border-bottom: 4px solid transparent;
}

.proceso-step:last-child .step-connector {
  display: none;
}

.proceso-step:hover .step-number {
  transform: var(--hover-scale-lg);
  box-shadow: var(--shadow-primary-hover);
}

/* ========================================
   PRICING SECTION
======================================== */

.pricing {
  padding: 3rem 0;
  position: relative;
  background-image: url('../images/wave-gradient2.png');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

.pricing::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #f8fafcde;
}

.pricing .container {
    position: relative;
    z-index: 1;
}

.pricing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 0.35fr));
  gap: 2rem;
  margin-top: 4rem;
  justify-content: center;
}

.pricing-card {
  background-color: white;
  border-radius: 0.6rem;
  padding: 2rem;
  border: 1px solid var(--primary-lighter);
  display: flex;
  flex-direction: column;
  transition: transform 0.2s, box-shadow 0.2s;
}

.pricing-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.15), 0 4px 6px -2px rgba(0, 0, 0, 0.1);
}

.pricing-card.featured {
  border-color: var(--primary-main);
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
}

.pricing-card.featured:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.15), 0 4px 6px -2px rgba(0, 0, 0, 0.1);
}

.pricing-card h3 {
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.pricing-description {
  color: var(--primary-dark);
  font-size: 0.875rem;
  margin-bottom: 2rem;
}

.pricing-amount {
  margin-bottom: 2rem;
}

.pricing-amount .amount {
  font-size: 2.25rem;
  font-weight: 800;
}

.pricing-amount .period {
  color: var(--primary-dark);
}

.pricing-features {
  list-style: none;
  margin-bottom: 2rem;
  flex-grow: 1;
}

.pricing-features li {
  color: var(--primary-dark);
  font-size: 0.875rem;
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
}

.pricing-features li::before {
  content: "✓";
  color: var(--primary-main);
  margin-right: 0.5rem;
  font-weight: bold;
}

.pricing-features li.feature-x::before {
  content: "✗";
  color: red;
}

/* ========================================
   EDUCATION SECTION
======================================== */
.education {
  padding: 3rem 0;
  position: relative;
  overflow: hidden;
  background-color: #050530;
}

.background-img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
}

.section-header {
  text-align: center;
  max-width: 800px;
  margin: 0 auto;
}

.section-title {
  color: #ffffff;
  font-size: 3.5rem;
  font-weight: 700;
  margin-bottom: 1rem;
  letter-spacing: 1px;
  position: relative;
  display: inline-block;
  margin-top: -1rem;
}

.section-title::after {
  content: '';
  position: absolute;
  bottom: -10px;
  left: 50%;
  transform: translateX(-50%);
  width: 80px;
  height: 4px;
  background-color: var(--primary-main);
}

.section-tagline {
  color: var(--primary-main);
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 1rem;
  letter-spacing: 2px;
  text-transform: uppercase;
}

.section-paragraph {
  color: #ffffff;
  font-size: 1.1rem;
  margin: 0 auto 3rem;
  max-width: 700px;
  opacity: 0.9;
  line-height: 1.7;
}

.cta-container {
  margin: 3rem auto 0;
  text-align: center;
}

/* ========================================
   CTA FINAL
======================================== */
.cta-final {
  align-items: center;
  display: grid;
  justify-content: center;
  margin: 3rem;
}

/* ========================================
   FAQ SECTION
======================================== */

.faq {
  padding: 3rem 0;
}

.faq h2 {
  font-size: 2.25rem;
  font-weight: 800;
  text-align: center;
  margin-bottom: 3rem;
}

.faq-list {
  max-width: 800px;
  margin: 0 auto;
}

.faq-item {
  border-bottom: 1px solid var(--primary-lighter);
}

.faq-question {
  width: 100%;
  background: none;
  border: none;
  text-align: left;
  padding: 1.5rem 0;
  font-size: 1.125rem;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  transition: color 0.3s ease;
}

.faq-question:hover {
  color: var(--primary-main);
}

.faq-icon {
  font-size: 1.5rem;
  transition: transform 0.3s ease;
}

.faq-item.active .faq-icon {
  transform: rotate(45deg);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease, padding 0.3s ease;
}

.faq-item.active .faq-answer {
  max-height: 1000px;
  padding-bottom: 1.5rem;
}

.faq-answer p {
  margin-bottom: 1rem;
  color: var(--primary-dark);
  line-height: 1.6;
}

/* ========================================
   FOOTER
======================================== */

.footer {
  background-color: var(--primary-darker);
  color: var(--primary-lighter);
  padding: 4rem 0;
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 4rem;
  margin-bottom: 3rem;
}

.footer-brand p {
  font-size: 0.875rem;
  margin-top: 1rem;
}

.footer-links h3 {
  font-size: 0.875rem;
  font-weight: 600;
  color: white;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 1rem;
}

.footer-links ul {
  list-style: none;
}

.footer-links a {
  color: var(--primary-lighter);
  text-decoration: none;
  font-size: 0.875rem;
  display: block;
  margin-bottom: 0.75rem;
  transition: color 0.2s;
}

.footer-links a:hover {
  color: white;
}

.footer-mid {
  text-align: center;
  padding-top: 2rem;
  border-top: 1px solid var(--primary-lighter);
}

.footer-mid p {
  color: var(--primary-lighter);
  font-size: 0.875rem;
}

.container-footer-juan {
    width: 90%;
    max-width: 1400px;
    margin: 0 auto;
}

.social-icons-footer-juan {
    display: flex;
    gap: 1rem;
    align-items: center;
    justify-content: center;
}

.social-icon-footer-juan {
    color: white;
    font-size: 1.5rem;
    transition: color 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 3rem;
    height: 3rem;
    opacity: 0.8;
}

.social-icon-footer-juan:hover {
    color: var(--primary-main);
}

.social-icon-footer-juan img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

@media (max-width: 768px) {
    .container-footer-juan {
        flex-direction: column;
        text-align: center;
    }

    .social-icons-footer-juan {
        margin-top: 1rem;
    }
}

.footer-bottom {
  text-align: center;
  padding-top: 2rem;
  border-top: 1px solid var(--primary-darker);
}

.footer-bottom p {
  color: var(--primary-lighter);
  font-size: 0.875rem;
}

.card-footer {
  color: var(--primary-dark);
  font-size: 0.9rem;
}

/* ========================================
   RESPONSIVE DESIGN
======================================== */
@media (max-width: 768px) {
  .hero h1 {
    font-size: 2rem;
    line-height: 1.2;
    margin-bottom: 0.5rem;
  }

  .hero-subtitle {
    font-size: 1.125rem;
    padding: 0 1rem;
  }

  .logo-grid {
    gap: 2rem;
  }

  .client-logo {
    height: 1.5rem;
  }

  /* Ocultar sección ROI comparison en móvil */
  .roi-comparison {
    display: none;
  }

  /* Testimonios en móvil - diseño vertical estático */
  .testimonials-wrapper {
    display: block;
    height: auto;
    mask: none;
    -webkit-mask: none;
    overflow: visible;
  }

  .testimonials-track {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    width: 100%;
    position: static;
  }

  .testimonial-card {
    position: static;
    animation: none;
    width: 100%;
    min-width: auto;
    max-width: 100%;
    margin: 0;
    padding: 1.5rem;
  }

  .testimonial-text {
    font-size: 1rem;
  }

  .proceso-flow {
    flex-direction: column;
    gap: 3rem;
  }

  .step-connector {
    display: none;
  }

  .proceso-step {
    max-width: 100%;
  }

  .section-title {
    font-size: 2.5rem;
  }

  .section-paragraph {
    font-size: 1rem;
    padding: 0 10px;
  }
}

@media (max-width: 534px) {
  .hero h1 {
    font-size: 1.75rem;
    line-height: 1.3;
    margin-bottom: 0.5rem;
    letter-spacing: -0.02em;
  }
  
  .hero-subtitle {
    font-size: 0.9rem;
    padding: 0 1rem;
  }
}

/* ========================================
   UTILIDADES
======================================== */
section:first-of-type {
  padding-top: 8rem;
}

.animate-fadeInUp {
  animation: fadeInUp 0.6s ease-out;
}

.animate-pulse {
  animation: pulse 2s infinite;
}
