@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap');

:root {
  /* --- COLORES --- */
  --c-bg: #ffffff;
  --c-bg-muted: #f5f5f7;
  --c-text-main: #1d1d1f;
  --c-text-muted: #86868b;
  --c-border: #e5e5ea;
  --c-btn-bg: #000000;
  --c-btn-text: #ffffff;

  /* --- TIPOGRAFÍA (Tamaños) --- */
  --text-xs: 11px;
  --text-sm: 0.875rem; /* 14px */
  --text-base: 1rem;   /* 16px */
  --text-h2: clamp(1.5rem, 4vw, 2.5rem); /* Aumentado para parecerse más a la foto */
  --text-h1: clamp(1.75rem, 3.5vw, 2.75rem);

  /* --- TIPOGRAFÍA (Pesos) --- */
  --fw-regular: 400;
  --fw-medium: 500;
  --fw-semibold: 600;
  --fw-bold: 700;

  /* --- ESPACIADOS (Regla de oro) --- */
  --space-2xs: 5px;   
  --space-xs: 8px;
  --space-sm: 10px;
  --space-md: 12px;
  --space-lg: 16px;   
  --space-xl: 20px;   
  --space-2xl: 40px;  
  --space-3xl: 50px;  
  --space-4xl: 80px;  
  --space-5xl: 100px; 

  /* --- SOMBRAS (Elevación) --- */
  --shadow-sm: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -2px rgba(0, 0, 0, 0.03);
  --shadow-md: 0 10px 15px -3px rgba(0, 0, 0, 0.05), 0 4px 6px -4px rgba(0, 0, 0, 0.03);
  --shadow-lg: 0 20px 40px -8px rgba(0, 0, 0, 0.08), 0 8px 16px -4px rgba(0, 0, 0, 0.04);
}

body {
  font-family: 'Inter', sans-serif;
  margin: 0;
  padding: 0;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  background-color: var(--c-bg);
  color: var(--c-text-main);
}

@keyframes tech-pan-breathe {
  0% { 
    background-position: 0 0; 
    opacity: 0.3; 
  }
  50% { 
    opacity: 0.6; 
  }
  100% { 
    background-position: 32px 32px; 
    opacity: 0.3; 
  }
}

/* Patrón de Cruces (Data Grid) */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  z-index: -2;
  pointer-events: none;
  background-image: url('data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMzIiIGhlaWdodD0iMzIiIHZpZXdCb3g9IjAgMCAzMiAzMiIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj48cGF0aCBkPSJNMTYgMTN2Nk0xMyAxNmg2IiBzdHJva2U9IiNlNWU1ZWEiIHN0cm9rZS13aWR0aD0iMSIvPjwvc3ZnPg==');
  background-size: 32px 32px;
  /* Máscara de profundidad: Centro transparente, medio visible, bordes desvanecidos */
  -webkit-mask-image: radial-gradient(ellipse at center, transparent 15%, black 55%, transparent 100%);
  mask-image: radial-gradient(ellipse at center, transparent 15%, black 55%, transparent 100%);
  animation: tech-pan-breathe 30s linear infinite;
}

/* Resplandor Glassmorphism (Volumen de luz) */
body::after {
  content: '';
  position: fixed;
  inset: 0;
  z-index: -3;
  pointer-events: none;
  background: radial-gradient(circle at 60% 30%, #ffffff 0%, #f0f2f5 50%, var(--c-bg) 100%);
  filter: blur(120px);
}

/* El Hero ocupa solo su espacio de contenido, padding da respiro */
.hero {
  padding: var(--space-3xl) var(--space-xl) var(--space-2xl); /* 50px 20px 40px */
  display: flex;
  flex-direction: column;
  align-items: center; /* Centrar todo el contenido */
}

/* 1. El Carrusel Infinito (Marquee) */
.marquee-container {
  overflow: hidden;
  max-width: 700px;
  margin: 0 auto var(--space-3xl); /* 0 auto 50px */
  width: 100%;
  mask-image: linear-gradient(to right, transparent, black 15%, black 85%, transparent);
  -webkit-mask-image: linear-gradient(to right, transparent, black 15%, black 85%, transparent);
}

.marquee-track {
  display: flex;
  gap: var(--space-lg); /* 16px */
  width: max-content;
  animation: scroll 25s linear infinite;
}

.marquee-pill {
  border: 1px solid var(--c-border);
  border-radius: 999px;
  padding: var(--space-2xs) var(--space-md); /* 5px 12px */
  font-size: var(--text-xs); /* 11px */
  color: var(--c-text-muted);
  white-space: nowrap;
}

@keyframes scroll {
  from {
    transform: translateX(0);
  }
  to {
    /* Mueve exacto el 50% menos la mitad del gap para el loop perfecto */
    transform: translateX(calc(-50% - (var(--space-lg) / 2))); 
  }
}

/* 2. Textos */
.hero h1 {
  font-size: var(--text-h1);
  font-weight: var(--fw-semibold);
  letter-spacing: -0.04em;
  line-height: 1.05;
  max-width: 700px;
  margin: 0 auto var(--space-lg); /* 0 auto 16px */
  text-align: center;
  color: var(--c-text-main);
}

.hero p {
  font-size: var(--text-sm);
  font-weight: var(--fw-regular);
  color: var(--c-text-muted);
  max-width: 700px;
  margin: 0 auto var(--space-2xl); /* 0 auto 40px */
  text-align: center;
  line-height: 1.4;
}

/* 3. Botón Reutilizable (Estilo PrimaryButton) */
.btn {
  background: #242424;
  color: #ffffff;
  padding: 14px 24px;
  border-radius: 16px;
  font-weight: 600;
  font-size: 15px;
  letter-spacing: -0.025em;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  white-space: nowrap;
  margin: 0 auto;
  box-shadow: inset 0px 2px 0px 0px rgba(255,255,255,0.15);
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
  cursor: pointer;
}

.btn::before {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(255, 255, 255, 0.05);
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
}

.btn:hover {
  background: #111111;
}

.btn:hover::before {
  opacity: 1;
}

.btn:active {
  transform: scale(0.98);
}

/* 4. Sección de Video */
.video-section {
  padding: 0 var(--space-xl) var(--space-5xl); /* 0px 20px 100px */
  display: flex;
  justify-content: center;
}

.video-wrapper {
  width: 80%;
  max-width: 1200px;
  border-radius: var(--space-xl); /* 20px */
  overflow: hidden; 
  box-shadow: var(--shadow-lg); /* Sombra Apple gran jerarquía */
}

.video-wrapper video {
  width: 100%;
  display: block; 
  object-fit: cover;
}

/* 5. Mid CTA */
.mid-cta {
  padding: var(--space-5xl) var(--space-xl) var(--space-5xl); /* Restaurar espaciado inferior */
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.mid-cta h2 {
  font-size: var(--text-h2);
  color: var(--c-text-main);
  font-weight: var(--fw-regular);
  line-height: 1;
  letter-spacing: -0.05em;
  margin: 0 auto var(--space-4xl); /* Espacio antes del botón */
}

.mid-cta h2 strong {
  font-weight: var(--fw-bold);
}

/* 6. FAQ Section */
.faq-section {
  padding: var(--space-5xl) var(--space-xl) var(--space-5xl); /* Espaciado enorme = 200px (100 de mid-cta + 100 de faq-section) */
  display: flex;
  justify-content: center;
}

.faq-container {
  width: 100%;
  max-width: 700px;
}

details {
  background-color: var(--c-bg-muted);
  border-radius: var(--space-md);
  margin-bottom: var(--space-sm);
  overflow: hidden;
  box-shadow: var(--shadow-md); /* Sombra Apple para desplegables */
}

summary {
  padding: var(--space-lg) var(--space-xl);
  font-weight: var(--fw-medium);
  font-size: var(--text-base);
  color: var(--c-text-main);
  cursor: pointer;
  list-style: none;
  display: flex;
  align-items: center;
}

summary::-webkit-details-marker {
  display: none;
}

summary::before {
  content: '+';
  font-weight: var(--fw-regular);
  font-size: 1.25rem;
  color: var(--c-text-muted);
  margin-right: var(--space-md);
  transition: transform 0.4s ease;
  line-height: 1;
}

details[open] summary::before {
  transform: rotate(45deg);
}

.faq-content-wrapper {
  height: 0;
  overflow: hidden;
  transition: height 0.4s ease-out; /* Transición manejada exacto por JS */
}

.faq-content {
  padding: 0 var(--space-xl) var(--space-xl) calc(var(--space-xl) + var(--space-md) + 0.6rem);
}

.faq-content p {
  color: var(--c-text-muted);
  font-size: var(--text-sm);
  line-height: 1.5;
  margin: 0;
}

/* 6.5 Pricing Section */
.pricing-section {
  padding: 0 var(--space-xl) var(--space-5xl);
  display: flex;
  flex-direction: column;
  align-items: center;
}

.pricing-header {
  text-align: center;
  margin-bottom: var(--space-3xl);
  max-width: 600px;
}

.pricing-header h2 {
  font-size: var(--text-h2);
  color: var(--c-text-main);
  font-weight: var(--fw-bold);
  margin: 0 0 var(--space-sm) 0;
  letter-spacing: -0.05em;
}

.pricing-header p {
  font-size: var(--text-base);
  color: var(--c-text-muted);
  line-height: 1.5;
  margin: 0;
}

.pricing-cards {
  display: flex;
  flex-direction: column;
  gap: var(--space-xl);
  width: 100%;
  max-width: 1000px;
  justify-content: center;
}

@media (min-width: 768px) {
  .pricing-cards {
    flex-direction: row;
    flex-wrap: wrap;
  }
}

.pricing-card {
  display: flex;
  flex-direction: column;
  position: relative;
  padding: var(--space-2xl) var(--space-xl);
  border-radius: 20px;
  border: 1px solid var(--c-border);
  background-color: var(--c-bg);
  transition: all 0.3s ease;
  width: 100%;
  box-sizing: border-box;
}

@media (min-width: 768px) {
  .pricing-card {
    width: 300px;
  }
}

@media (min-width: 1024px) {
  .pricing-card {
    width: 320px;
  }
}

.pricing-card:hover {
  border-color: #d1d1d6;
  box-shadow: var(--shadow-sm);
}

.pricing-card-header {
  margin-bottom: var(--space-2xl);
  margin-top: var(--space-xs);
  text-align: center;
}

.pricing-card-header h4 {
  font-size: 20px;
  font-weight: var(--fw-bold);
  color: var(--c-text-main);
  margin: 0 0 var(--space-xs) 0;
}

.pricing-price {
  display: flex;
  justify-content: center;
  align-items: flex-end;
  gap: 4px;
}

.price-value {
  font-size: 32px;
  font-weight: var(--fw-bold);
  color: var(--c-text-main);
  line-height: 1;
}

.price-period {
  font-size: var(--text-sm);
  color: var(--c-text-muted);
  font-weight: var(--fw-medium);
  margin-bottom: 4px;
}

.pricing-features {
  flex-grow: 1;
  margin-bottom: var(--space-2xl);
}

.pricing-feature {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--space-md) 0;
  border-bottom: 1px solid #f5f5f7;
}

.feature-name {
  font-size: var(--text-sm);
  color: var(--c-text-muted);
}

.feature-value {
  font-size: var(--text-sm);
  font-weight: var(--fw-bold);
  color: var(--c-text-main);
}

.pricing-action {
  margin-top: auto;
}

.pricing-action .btn {
  width: 100%;
  box-sizing: border-box;
  padding: var(--space-md) var(--space-xl);
}

/* 7. Footer Gigante */
.giant-footer {
  width: 100%;
  overflow: hidden; 
  padding-top: var(--space-5xl);
  display: flex;
  flex-direction: column;
  align-items: center;
  container-type: inline-size; /* Hechizo avanzado para medir sin contar la barra de scroll */
}

.footer-top {
  width: 100%; 
  padding: 0 var(--space-xl);
  box-sizing: border-box;
  color: var(--c-text-muted);
  font-size: var(--text-xs); 
  text-align: left;
}

.giant-footer h2 {
  font-size: 19.3cqi; 
  font-weight: var(--fw-medium); 
  letter-spacing: -0.06em; 
  line-height: 0.82; /* Un poco más de aire para no cortarle los pies a la 'p' */
  margin: 0;
  margin-right: -0.06em; 
  padding: 0;
  text-align: center;
  white-space: nowrap;
  
  /* Magia de degradado en el texto */
  background: linear-gradient(to bottom, var(--c-text-main) 50%, var(--c-bg) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  color: transparent;
}
