/* Loading Screen Styles - Solo para la página de inicio */

/* Loading Screen */
.loading-screen {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, #90d624 0%, #7bb820 50%, #90d624 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  opacity: 1;
  visibility: visible;
  transition: opacity 0.8s ease-out, visibility 0.8s ease-out;
}

.loading-screen.fade-out {
  opacity: 0;
  visibility: hidden;
}

.loading-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2rem;
  animation: loadingFadeIn 1s ease-out;
}

.loading-logo {
  animation: logoFloat 3s ease-in-out infinite;
}

.loading-logo-img {
  height: 80px;
  width: auto;
  filter: brightness(0) invert(1);
  opacity: 0.9;
}

.loading-spinner {
  position: relative;
  width: 60px;
  height: 60px;
}

.spinner-ring {
  position: absolute;
  width: 100%;
  height: 100%;
  border: 3px solid transparent;
  border-top: 3px solid rgba(255, 255, 255, 0.8);
  border-radius: 50%;
  animation: spin 1.5s linear infinite;
}

.spinner-ring:nth-child(1) {
  animation-delay: 0s;
  border-top-color: rgba(255, 255, 255, 1);
}

.spinner-ring:nth-child(2) {
  animation-delay: 0.3s;
  border-top-color: rgba(255, 255, 255, 0.6);
  transform: scale(0.8);
}

.spinner-ring:nth-child(3) {
  animation-delay: 0.6s;
  border-top-color: rgba(255, 255, 255, 0.4);
  transform: scale(0.6);
}

.loading-text {
  display: flex;
  align-items: center;
  gap: 0.2rem;
  font-size: 16px;
  font-weight: 300;
  color: rgba(255, 255, 255, 0.9);
  letter-spacing: 0.5px;
}

.loading-dot {
  animation: dotPulse 1.5s ease-in-out infinite;
}

.loading-dot:nth-child(1) {
  animation-delay: 0s;
}

.loading-dot:nth-child(2) {
  animation-delay: 0.2s;
}

.loading-dot:nth-child(3) {
  animation-delay: 0.4s;
}

.loading-dot:nth-child(4) {
  animation-delay: 0.6s;
}

/* Animations */
@keyframes loadingFadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes logoFloat {
  0%, 100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-10px);
  }
}

@keyframes spin {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

@keyframes dotPulse {
  0%, 100% {
    opacity: 0.3;
    transform: scale(1);
  }
  50% {
    opacity: 1;
    transform: scale(1.1);
  }
}

/* Hide main content during loading - Solo para la página de inicio */
body.loading {
  overflow: hidden;
}

body.loading .hero-header,
body.loading main,
body.loading footer {
  opacity: 0;
  transition: opacity 0.5s ease-in;
}

body.loaded .hero-header,
body.loaded main,
body.loaded footer {
  opacity: 1;
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .loading-logo-img {
    height: 60px;
  }
  
  .loading-spinner {
    width: 50px;
    height: 50px;
  }
  
  .loading-text {
    font-size: 14px;
  }
}

@media (max-width: 480px) {
  .loading-logo-img {
    height: 50px;
  }
  
  .loading-spinner {
    width: 40px;
    height: 40px;
  }
  
  .loading-text {
    font-size: 12px;
  }
} 