/* ===== CSS VARIABLES ===== */
:root {
  --primary-color: #39ff14;
  --dark-bg: #1e1e1e;
  --light-bg: #ffffff;
  --secondary-bg: #f5f5f5;
  --text-dark: #333333;
  --text-light: #ffffff;
  --text-gray: #666666;
  --shadow: rgba(0, 0, 0, 0.1);
  --transition: all 0.3s ease;
  --border-radius: 12px;
}

/* Dark theme variables */
[data-theme="dark"] {
  --light-bg: #2a2a2a;
  --secondary-bg: #1e1e1e;
  --text-dark: #ffffff;
  --text-gray: #cccccc;
  --shadow: rgba(255, 255, 255, 0.1);
}

/* ===== RESET & BASE STYLES ===== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: "Poppins", sans-serif;
  line-height: 1.6;
  color: var(--text-dark);
  background-color: var(--light-bg);
  transition: var(--transition);
  overflow-x: hidden;
}

/* ===== NAVBAR STYLES ===== */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  padding: 1rem 0;
  transition: var(--transition);
  background: rgba(255, 255, 255, 0.15); /* Más transparente para glass */
  backdrop-filter: blur(15px);
  -webkit-backdrop-filter: blur(15px); /* Safari */
  border-bottom: 1px solid rgba(255, 255, 255, 0.25); /* Línea sutil */
}

.navbar.scrolled {
  background: rgba(255, 255, 255, 0.8); /* Claro */
  box-shadow: 0 2px 20px var(--shadow);
}

/* ✅ Modo oscuro: mantiene el glass oscuro al hacer scroll */
[data-theme="dark"] .navbar.scrolled {
  background: rgba(30, 30, 30, 0.8);
  box-shadow: 0 2px 20px var(--shadow);
}

.nav-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo {
  font-size: 1.8rem;
  font-weight: 800;
  color: var(--primary-color);
  text-decoration: none;
  transition: var(--transition);
}

.logo:hover {
  text-shadow: 0 0 20px var(--primary-color);
}

.nav-menu {
  display: flex;
  list-style: none;
  gap: 2rem;
  align-items: center;
}

.nav-link {
  text-decoration: none;
  color: var(--text-dark);
  font-weight: 500;
  transition: var(--transition);
  position: relative;
}

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

.nav-link::after {
  content: "";
  position: absolute;
  width: 0;
  height: 2px;
  bottom: -5px;
  left: 0;
  background: var(--primary-color);
  transition: var(--transition);
}

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

.cta-button {
  background: var(--primary-color);
  color: var(--dark-bg);
  padding: 0.8rem 1.5rem;
  border: none;
  border-radius: var(--border-radius);
  font-weight: 600;
  text-decoration: none;
  transition: var(--transition);
  cursor: pointer;
  box-shadow: 0 0 20px rgba(57, 255, 20, 0.3);
}

.cta-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 5px 25px rgba(57, 255, 20, 0.5);
}

.nav-toggles {
  display: flex;
  gap: 1rem;
  align-items: center;
}

.toggle-button {
  background: none;
  border: 1px solid var(--text-gray);
  color: var(--text-dark);
  padding: 0.5rem;
  border-radius: 6px;
  cursor: pointer;
  transition: var(--transition);
  font-size: 0.9rem;
  min-width: 40px;
}

.toggle-button:hover {
  border-color: var(--primary-color);
  color: var(--primary-color);
}

.hamburger {
  display: none;
  flex-direction: column;
  cursor: pointer;
  gap: 3px;
}

.hamburger span {
  width: 25px;
  height: 3px;
  background: var(--text-dark);
  transition: var(--transition);
}

/* ===== HERO SECTION ===== */
.hero {
  min-height: 100vh;
  padding-top: 100px; /* ✅ Evita que el navbar tape el hero */
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  background: linear-gradient(
    135deg,
    var(--light-bg) 0%,
    var(--secondary-bg) 100%
  );
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1000 1000"><defs><pattern id="pattern" x="0" y="0" width="50" height="50" patternUnits="userSpaceOnUse"><circle cx="25" cy="25" r="2" fill="%2339FF14" opacity="0.1"/></pattern></defs><rect width="100%" height="100%" fill="url(%23pattern)"/></svg>');
  opacity: 0.3;
  z-index: 1;
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: 800px;
  margin: 0 auto;
  padding: 0 2rem;
  opacity: 0;
  transform: translateY(30px);
  animation: fadeUp 1s ease forwards;
}

@keyframes fadeUp {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.hero h1 {
  font-size: clamp(2.5rem, 5vw, 4rem);
  font-weight: 800;
  margin-bottom: 1rem;
  background: linear-gradient(
    135deg,
    var(--text-dark) 0%,
    var(--primary-color) 100%
  );
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  line-height: 1.2;
}

.hero p {
  font-size: 1.2rem;
  color: var(--text-gray);
  margin-bottom: 2rem;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

.hero-cta {
  background: var(--primary-color);
  color: var(--dark-bg);
  padding: 1rem 2rem;
  border: none;
  border-radius: var(--border-radius);
  font-size: 1.1rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
  text-decoration: none;
  display: inline-block;
  box-shadow: 0 10px 30px rgba(57, 255, 20, 0.3);
  animation: pulse 2s infinite;
}

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

.hero-cta:hover {
  transform: translateY(-3px);
  box-shadow: 0 15px 35px rgba(57, 255, 20, 0.5);
}

/* ===== SECTION STYLES ===== */
.section {
  padding: 5rem 0;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
}

.section-title {
  text-align: center;
  margin-bottom: 3rem;
}

.section-title h2 {
  font-size: 2.5rem;
  font-weight: 700;
  margin-bottom: 1rem;
  color: var(--text-dark);
}

.section-title p {
  font-size: 1.1rem;
  color: var(--text-gray);
  max-width: 600px;
  margin: 0 auto;
}

/* ===== SOLUTIONS SECTION ===== */
.solutions-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 2rem;
  margin-top: 3rem;
}

.solution-card {
  background: var(--light-bg);
  padding: 2rem;
  border-radius: var(--border-radius);
  text-align: center;
  transition: var(--transition);
  box-shadow: 0 5px 15px var(--shadow);
  border: 1px solid transparent;
  opacity: 0;
  transform: translateY(20px);
}

.solution-card.animate {
  opacity: 1;
  transform: translateY(0);
}

.solution-card:hover {
  transform: translateY(-10px);
  border-color: var(--primary-color);
  box-shadow: 0 15px 35px rgba(57, 255, 20, 0.2);
}

.solution-icon {
  font-size: 3rem;
  color: var(--primary-color);
  margin-bottom: 1rem;
  transition: var(--transition);
}

.solution-card:hover .solution-icon {
  transform: scale(1.1);
  filter: drop-shadow(0 0 10px var(--primary-color));
}

.solution-card h3 {
  font-size: 1.3rem;
  margin-bottom: 1rem;
  color: var(--text-dark);
}

.solution-card p {
  color: var(--text-gray);
  line-height: 1.6;
}

/* ===== BENEFITS SECTION ===== */
.benefits {
  background: var(--secondary-bg);
}

.benefits-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
  margin-top: 3rem;
}

.benefit-item {
  text-align: center;
  padding: 1.5rem;
  opacity: 0;
  transform: translateY(20px);
  transition: var(--transition);
}

.benefit-item.animate {
  opacity: 1;
  transform: translateY(0);
}

.benefit-icon {
  font-size: 2.5rem;
  color: var(--primary-color);
  margin-bottom: 1rem;
}

.benefit-item h3 {
  font-size: 1.2rem;
  margin-bottom: 0.5rem;
  color: var(--text-dark);
}

.benefit-item p {
  color: var(--text-gray);
  font-size: 0.9rem;
}

/* ===== TESTIMONIALS SECTION ===== */
.testimonials-container {
  position: relative;
  max-width: 800px;
  margin: 0 auto;
  overflow: hidden;
  border-radius: var(--border-radius);
}

.testimonial-slide {
  background: var(--light-bg);
  padding: 3rem;
  text-align: center;
  border-radius: var(--border-radius);
  box-shadow: 0 10px 30px var(--shadow);
  display: none;
}

.testimonial-slide.active {
  display: block;
  animation: slideIn 0.5s ease;
}

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

.testimonial-text {
  font-size: 1.1rem;
  font-style: italic;
  margin-bottom: 1.5rem;
  color: var(--text-dark);
  line-height: 1.6;
}

.testimonial-author {
  font-weight: 600;
  color: var(--primary-color);
  margin-bottom: 0.5rem;
}

.testimonial-company {
  color: var(--text-gray);
  font-size: 0.9rem;
}

.testimonial-metrics {
  display: flex;
  justify-content: center;
  gap: 2rem;
  margin-top: 2rem;
  flex-wrap: wrap;
}

.metric {
  text-align: center;
}

.metric-number {
  font-size: 2rem;
  font-weight: 700;
  color: var(--primary-color);
  display: block;
}

.metric-label {
  font-size: 0.9rem;
  color: var(--text-gray);
}

/* ===== PROCESS SECTION ===== */
.process-timeline {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
  margin-top: 3rem;
  position: relative;
}

.process-step {
  text-align: center;
  padding: 2rem;
  background: var(--light-bg);
  border-radius: var(--border-radius);
  box-shadow: 0 5px 15px var(--shadow);
  position: relative;
  opacity: 0;
  transform: translateY(20px);
  transition: var(--transition);
}

.process-step.animate {
  opacity: 1;
  transform: translateY(0);
}

.step-number {
  width: 60px;
  height: 60px;
  background: var(--primary-color);
  color: var(--dark-bg);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  font-weight: 700;
  margin: 0 auto 1rem;
  box-shadow: 0 5px 15px rgba(57, 255, 20, 0.3);
}

.process-step h3 {
  font-size: 1.2rem;
  margin-bottom: 1rem;
  color: var(--text-dark);
}

.process-step p {
  color: var(--text-gray);
  line-height: 1.6;
}

/* ===== PRICING SECTION ===== */
.pricing {
  background: var(--secondary-bg);
}

.pricing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
  margin-top: 3rem;
}

.pricing-card {
  background: var(--light-bg);
  padding: 2.5rem;
  border-radius: var(--border-radius);
  text-align: center;
  position: relative;
  transition: var(--transition);
  box-shadow: 0 5px 15px var(--shadow);
  opacity: 0;
  transform: translateY(20px);
}

.pricing-card.animate {
  opacity: 1;
  transform: translateY(0);
}

.pricing-card.featured {
  transform: scale(1.05);
  border: 2px solid var(--primary-color);
  box-shadow: 0 15px 35px rgba(57, 255, 20, 0.2);
}

.pricing-card.featured::before {
  content: "Más Popular";
  position: absolute;
  top: -10px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--primary-color);
  color: var(--dark-bg);
  padding: 0.5rem 1rem;
  border-radius: var(--border-radius);
  font-size: 0.8rem;
  font-weight: 600;
}

[data-lang="en"] .pricing-card.featured::before {
  content: "Most Popular";
}

.pricing-header h3 {
  font-size: 1.5rem;
  margin-bottom: 0.5rem;
  color: var(--text-dark);
}

.pricing-price {
  font-size: 2.5rem;
  font-weight: 700;
  color: var(--primary-color);
  margin-bottom: 1rem;
}

.pricing-price span {
  font-size: 1rem;
  color: var(--text-gray);
}

.pricing-features {
  list-style: none;
  margin: 2rem 0;
  text-align: left;
}

.pricing-features li {
  padding: 0.5rem 0;
  color: var(--text-gray);
  position: relative;
  padding-left: 1.5rem;
}

.pricing-features li::before {
  content: "✓";
  color: var(--primary-color);
  font-weight: 600;
  position: absolute;
  left: 0;
}

/* ===== CTA FINAL SECTION ===== */
.cta-final {
  background: linear-gradient(135deg, var(--dark-bg) 0%, #2a2a2a 100%);
  color: var(--text-light);
  text-align: center;
  position: relative;
  overflow: hidden;
}

.cta-final::before {
  content: "";
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(
    circle,
    rgba(57, 255, 20, 0.1) 0%,
    transparent 70%
  );
  animation: rotate 20s linear infinite;
}

@keyframes rotate {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}

.cta-final .container {
  position: relative;
  z-index: 2;
}

.cta-final h2 {
  font-size: 2.5rem;
  margin-bottom: 1rem;
  background: linear-gradient(135deg, #ffffff 0%, var(--primary-color) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.cta-final p {
  font-size: 1.2rem;
  margin-bottom: 2rem;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
  color: #cccccc;
}

/* ===== CONTACT FORM ===== */
.contact-form {
  max-width: 600px;
  margin: 0 auto;
  background: var(--light-bg);
  padding: 2.5rem;
  border-radius: var(--border-radius);
  box-shadow: 0 10px 30px var(--shadow);
}

.form-group {
  margin-bottom: 1.5rem;
}

.form-group label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: 500;
  color: var(--text-dark);
}

.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  padding: 1rem;
  border: 1px solid #ddd;
  border-radius: var(--border-radius);
  font-family: inherit;
  font-size: 1rem;
  transition: var(--transition);
  background: var(--light-bg);
  color: var(--text-dark);
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--primary-color);
  box-shadow: 0 0 0 3px rgba(57, 255, 20, 0.1);
}

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

.form-submit {
  width: 100%;
  background: var(--primary-color);
  color: var(--dark-bg);
  padding: 1rem;
  border: none;
  border-radius: var(--border-radius);
  font-size: 1.1rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
}

.form-submit:hover {
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(57, 255, 20, 0.3);
}

/* ===== FOOTER ===== */
.footer {
  background: var(--dark-bg);
  color: var(--text-light);
  padding: 3rem 0 1rem;
}

.footer-content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
  margin-bottom: 2rem;
}

.footer-section h3 {
  margin-bottom: 1rem;
  color: var(--primary-color);
}

.footer-section p,
.footer-section a {
  color: #cccccc;
  text-decoration: none;
  margin-bottom: 0.5rem;
  display: block;
  transition: var(--transition);
}

.footer-section a:hover {
  color: var(--primary-color);
}

.social-links {
  display: flex;
  gap: 1rem;
}

.social-links a {
  width: 40px;
  height: 40px;
  background: var(--primary-color);
  color: var(--dark-bg);
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: var(--transition);
}

.social-links a:hover {
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(57, 255, 20, 0.3);
}

.footer-bottom {
  text-align: center;
  padding-top: 2rem;
  border-top: 1px solid #333;
  color: #999;
}

/* ===== RESPONSIVE DESIGN ===== */
@media (max-width: 768px) {
  .nav-menu {
    position: fixed;
    top: 80px;
    left: -100%;
    width: 100%;
    height: calc(100vh - 80px);
    background: var(--light-bg);
    flex-direction: column;
    justify-content: flex-start;
    align-items: center;
    transition: var(--transition);
    padding-top: 2rem;
    box-shadow: 0 2px 20px var(--shadow);
  }

  .nav-menu.active {
    left: 0;
  }

  .hamburger {
    display: flex;
  }

  .hamburger.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
  }

  .hamburger.active span:nth-child(2) {
    opacity: 0;
  }

  .hamburger.active span:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -6px);
  }

  .nav-toggles {
    order: -1;
    gap: 0.5rem;
  }

  .hero h1 {
    font-size: 2.5rem;
  }

  .hero p {
    font-size: 1rem;
  }

  .section {
    padding: 3rem 0;
  }

  .section-title h2 {
    font-size: 2rem;
  }

  .solutions-grid,
  .benefits-grid,
  .pricing-grid {
    grid-template-columns: 1fr;
  }

  .process-timeline {
    grid-template-columns: 1fr;
  }

  .testimonial-metrics {
    flex-direction: column;
    gap: 1rem;
  }

  .pricing-card.featured {
    transform: none;
  }

  .contact-form {
    margin: 0 1rem;
    padding: 2rem;
  }
}

@media (max-width: 480px) {
  .nav-container {
    padding: 0 1rem;
  }

  .container {
    padding: 0 1rem;
  }

  .hero-content {
    padding: 0 1rem;
  }

  .hero h1 {
    font-size: 2rem;
  }

  .solution-card,
  .contact-form {
    padding: 1.5rem;
  }

  .testimonial-slide {
    padding: 2rem;
  }

  .cta-final h2 {
    font-size: 2rem;
  }
}

/* ===== UTILITY CLASSES ===== */
.fade-in {
  opacity: 0;
  transform: translateY(20px);
  transition: all 0.6s ease;
}

.fade-in.animate {
  opacity: 1;
  transform: translateY(0);
}

.hidden {
  display: none;
}

/* ===== LOADING ANIMATION ===== */
.loading {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: var(--light-bg);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  transition: opacity 0.5s ease;
}

.loading-spinner {
  width: 50px;
  height: 50px;
  border: 3px solid #f3f3f3;
  border-top: 3px solid var(--primary-color);
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

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