/* ============================================
   INDEX - PÁGINA PRINCIPAL - SOLVEX GROUP
   Estilos específicos de la página de inicio
   ============================================ */

/* Animaciones específicas de barras del gráfico */
@keyframes growBar1 { 
  from { height: 0; opacity: 0; } 
  to { height: 60%; opacity: 1; } 
}

@keyframes growBar2 { 
  from { height: 0; opacity: 0; } 
  to { height: 80%; opacity: 1; } 
}

@keyframes growBar3 { 
  from { height: 0; opacity: 0; } 
  to { height: 70%; opacity: 1; } 
}

@keyframes growBar4 { 
  from { height: 0; opacity: 0; } 
  to { height: 90%; opacity: 1; } 
}

/* ========================================
   HERO SECTION
======================================== */
.hero-section {
  min-height: 100vh;
  display: flex;
  align-items: center;
  position: relative;
  overflow: hidden;
  background: var(--primary-solvex);
  padding: 120px 0 80px 0;
}

.hero-section::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-image: 
    radial-gradient(circle at 20% 50%, rgba(255,255,255,0.1) 0%, transparent 50%),
    radial-gradient(circle at 80% 80%, rgba(255,255,255,0.05) 0%, transparent 50%),
    radial-gradient(circle at 40% 20%, rgba(255,255,255,0.08) 0%, transparent 50%);
  animation: floatBackground 20s ease-in-out infinite;
}

.hero-section::after {
  content: '';
  position: absolute;
  bottom: 0;         /* Posicionado en la parte inferior */
  left: 0;
  right: 0;
  height: 1px;       /* Línea fina de 1px */
  background: linear-gradient(90deg, transparent, rgba(0, 200, 150, 0.2), transparent);
  z-index: 3;        /* Para que esté por encima del contenido */
}

.hero-container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 20px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
  position: relative;
  z-index: 2;
}

/* Contenido del Hero */
.hero-content {
  animation: slideInLeft 1s ease-out;
}

.hero-title {
  font-size: clamp(2.5rem, 5vw, 4rem);
  color: var(--text-light);
  margin-bottom: 20px;
  line-height: 1.2;
  font-weight: 700;
  animation: fadeIn 1s ease-out 0.3s both;
}

.hero-subtitle {
  font-size: clamp(1.2rem, 2vw, 1.5rem);
  color: rgba(255,255,255,0.9);
  margin-bottom: 30px;
  line-height: 1.4;
  animation: fadeIn 1s ease-out 0.5s both;
}

.hero-subtitle a {
  color: var(--primary-color);
  text-decoration: underline;
  font-weight: 600;
  transition: var(--transition);
}

.hero-subtitle a:hover {
  color: var(--white);
  text-decoration: none;
}

/* Lista de beneficios */
.hero-benefits {
  list-style: none;
  margin: 30px 0;
  animation: fadeIn 1s ease-out 0.7s both;
}

.hero-benefits li {
  color: var(--text-light);
  padding: 10px 0;
  display: flex;
  align-items: center;
  font-size: 1.1rem;
}

.hero-benefits li::before {
  content: '✓';
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  background: var(--accent-color);
  color: white;
  border-radius: 50%;
  margin-right: 15px;
  font-weight: bold;
  flex-shrink: 0;
}

/* Botones CTA */
.hero-buttons {
  display: flex;
  gap: 20px;
  margin-top: 40px;
  margin-bottom: 20px;
  flex-wrap: wrap;
  animation: fadeIn 1s ease-out 0.9s both;
}

/* Botones específicos del hero */
.btn {
  padding: 15px 35px;
  border-radius: 50px;
  font-size: 1.1rem;
  font-weight: 600;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  transition: var(--transition);
  position: relative;
  overflow: hidden;
  cursor: pointer;
  border: none;
}

.btn-primary {
  background: var(--white);
  color: var(--primary-color);
  box-shadow: var(--shadow-medium);
}

.btn-primary:hover {
  background: var(--primary-solvex);
  transform: translateY(-3px);
  box-shadow: var(--shadow-heavy);
}

.btn-secondary {
  background: transparent;
  color: var(--text-light);
  border: 2px solid var(--text-light);
}

.btn-secondary:hover {
  background: var(--white);
  color: var(--primary-color);
  transform: translateY(-3px);
}

/* Visual/Imagen del Hero */
.hero-visual {
  position: relative;
  animation: slideInRight 1s ease-out;
}

.hero-image-container {
  position: relative;
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 30px 60px rgba(0,0,0,0.3);
  background: white;
  padding: 40px;
  width: 100%;
}

/* ========================================
   DASHBOARD INTERACTIVO
======================================== */
.dashboard-preview {
  background: linear-gradient(180deg, var(--light-bg) 0%, var(--white) 100%);
  border-radius: var(--border-radius);
  padding: 30px;
  min-height: 400px;
}

.dashboard-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 30px;
  padding-bottom: 20px;
  border-bottom: 2px solid #e0e0e0;
}

.dashboard-title {
  font-size: 1.5rem;
  color: var(--primary-solvex);
  font-weight: 600;
}

.dashboard-status {
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--accent-green-hover);
  color: var(--white);
  padding: 8px 16px;
  border-radius: 20px;
  font-size: 0.9rem;
}

.status-dot {
  width: 8px;
  height: 8px;
  background: var(--white);
  border-radius: 50%;
  animation: pulse 2s infinite;
}

/* Métricas del dashboard */
.dashboard-metrics {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-bottom: 30px;
}

.metric-card {
  background: var(--white);
  padding: 20px;
  border-radius: var(--border-radius);
  box-shadow: var(--shadow-light);
  text-align: center;
  transition: var(--transition);
}

.metric-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-medium);
}

.metric-value {
  font-size: 2rem;
  font-weight: 700;
  color: var(--primary-color);
  margin-bottom: 5px;
}

.metric-label {
  color: #666;
  font-size: 0.9rem;
}

/* ========================================
   SECCIÓN DE SERVICIOS
======================================== */
.services-preview {
  width: 100vw;
  position: relative;
  left: 50%;
  right: 50%;
  margin-left: -50vw;
  margin-right: -50vw;
  padding: 70px 20px 60px;
  background: var(--light-bg);
  margin-top: 0;
}

.services-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 240px));
  gap: 20px;
  margin-top: 40px;
  justify-content: center;
}

@media (max-width: 1024px) {
  .services-grid {
    grid-template-columns: repeat(2, minmax(0, 260px));
    gap: 18px;
  }
}

@media (max-width: 600px) {
  .services-grid {
    grid-template-columns: minmax(0, 320px);
    gap: 15px;
  }
  
  .service-card {
    min-height: 180px;
  }
}

.service-card {
  background: var(--white);
  padding: 30px 20px 25px;
  border-radius: var(--border-radius);
  text-align: center;
  transition: var(--transition);
  box-shadow: var(--shadow-light);
  min-height: 220px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  position: relative;
  overflow: hidden;
  text-decoration: none;
  color: inherit;
}

.service-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--primary-color), var(--accent-color));
  transform: scaleX(0);
  transition: transform 0.3s ease;
}

.service-card:hover::before {
  transform: scaleX(1);
}

.service-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-medium);
}

.service-icon {
  font-size: 2.2rem;
  margin-bottom: 12px;
}

.service-card h3 {
  color: var(--primary-solvex);
  margin-bottom: 8px;
  font-size: 1.15rem;
  font-weight: 600;
}

.service-card p {
  color: var(--secondary-solvex);
  font-size: 0.95rem;
  line-height: 1.5;
  margin-bottom: 18px;
  min-height: 45px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.service-btn {
  background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
  color: var(--white);
  padding: 10px 24px;
  border-radius: 25px;
  font-size: 0.95rem;
  text-decoration: none;
  display: inline-block;
  transition: var(--transition);
  font-weight: 600;
  box-shadow: var(--shadow-light);
  position: relative;
  overflow: hidden;
}

.service-btn::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: rgba(255,255,255,0.2);
  transition: left 0.3s ease;
}

.service-btn:hover::before {
  left: 100%;
}

.service-btn:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-medium);
}

/* ========================================
   GRÁFICO DEL DASHBOARD
======================================== */
/* Gráfico del dashboard */
.chart-container {
  position: relative;
  height: 120px;
  background: #f5f5f5;
  border-radius: var(--border-radius);
  margin-top: 20px;
  overflow: hidden;
}

.chart-background {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, rgba(76,175,80,0.1) 0%, rgba(0,121,107,0.1) 100%);
  border-radius: var(--border-radius);
}

.chart-bar {
  position: absolute;
  bottom: 0;
  width: 15%;
  border-radius: 5px 5px 0 0;
  box-shadow: 0 -2px 10px rgba(76,175,80,0.3);
}

.bar-1 {
  left: 10%;
  height: 60%;
  background: linear-gradient(to top, var(--accent-color), #66BB6A);
  animation: growBar1 1.5s ease-out 0.7s both;
}

.bar-2 {
  left: 30%;
  height: 80%;
  background: linear-gradient(to top, var(--primary-color), #26A69A);
  animation: growBar2 1.5s ease-out 0.9s both;
}

.bar-3 {
  left: 50%;
  height: 70%;
  background: linear-gradient(to top, var(--accent-color), #66BB6A);
  animation: growBar3 1.5s ease-out 1.1s both;
}

.bar-4 {
  left: 70%;
  height: 90%;
  background: linear-gradient(to top, var(--primary-color), #26A69A);
  animation: growBar4 1.5s ease-out 1.3s both;
}

/* ========================================
   COMPONENTES ADICIONALES
======================================== */
.hero-contact {
  color: rgba(255,255,255,0.85);
  font-size: 0.9rem;
  line-height: 1.6;
  margin-top: 20px;
  animation: fadeIn 1s ease-out 1s both;
}

.hero-contact a {
  color: inherit;
  text-decoration: none;
}

.hero-contact a:hover {
  color: var(--text-light);
}

.services-header {
  text-align: center;
  margin-bottom: 40px;
}

.services-title {
  font-size: 2.2rem;
  color: var(--primary-solvex);
  margin-bottom: 15px;
  font-weight: 700;
}

.services-subtitle {
  font-size: 1.1rem;
  color: var(--secondary-solvex);
  max-width: 600px;
  margin: 0 auto;
}

/* ========================================
   ESTILOS PARA ICONOS
======================================== */
i {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.contact-section i {
  margin-right: var(--icon-spacing);
  width: 1.2rem;
  text-align: center;
}

.btn i {
  margin-right: var(--icon-spacing);
}

.service-icon i {
  font-size: inherit;
  color: var(--primary-color);
}

/* ========================================
   RESPONSIVE DESIGN
======================================== */
@media (max-width: 968px) {
  .hero-container {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .hero-visual {
    display: none;
  }

  .hero-buttons {
    justify-content: center;
  }

  .dashboard-metrics {
    grid-template-columns: 1fr;
  }
  
  .hero-section {
    padding: 80px 0 60px 0;
  }

  .hamburger {
    display: block;
  }

  nav ul {
    position: fixed;
    top: 70px;
    left: 0;
    background: var(--white);
    width: 100%;
    flex-direction: column;
    align-items: center;
    padding: 1rem 0;
    box-shadow: var(--shadow-medium);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    z-index: 1000;
  }

  nav ul.active {
    display: flex !important;
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
  }
}

@media (max-width: 768px) {
  .footer-container {
    flex-direction: column;
    gap: 2.5rem;
  }

  .header-container {
    padding: 1rem;
  }

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

  .hero-subtitle {
    font-size: 1.1rem;
  }

  .services-title {
    font-size: 2rem;
  }

  .cta-title {
    font-size: 2rem;
  }

  .cta-description {
    font-size: 1rem;
  }
}