/* Loading Page Styles */
.loading-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(255, 255, 255, 0.95);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 9999;
  backdrop-filter: blur(5px);
}

.loading-container {
  text-align: center;
  padding: 2rem;
  background: white;
  border-radius: 15px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
  max-width: 300px;
}

.loading-spinner {
  width: 60px;
  height: 60px;
  border: 4px solid #e3e3e3;
  border-top: 4px solid #28a745;
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin: 0 auto 1rem;
}

.loading-dots {
  display: inline-block;
  position: relative;
  width: 80px;
  height: 80px;
  margin: 0 auto 1rem;
}

.loading-dots div {
  position: absolute;
  top: 33px;
  width: 13px;
  height: 13px;
  border-radius: 50%;
  background: #28a745;
  animation-timing-function: cubic-bezier(0, 1, 1, 0);
}

.loading-dots div:nth-child(1) {
  left: 8px;
  animation: dots1 0.6s infinite;
}

.loading-dots div:nth-child(2) {
  left: 8px;
  animation: dots2 0.6s infinite;
}

.loading-dots div:nth-child(3) {
  left: 32px;
  animation: dots2 0.6s infinite;
}

.loading-dots div:nth-child(4) {
  left: 56px;
  animation: dots3 0.6s infinite;
}

.loading-text {
  color: #333;
  font-size: 1.1rem;
  font-weight: 500;
  margin-bottom: 0.5rem;
}

.loading-subtext {
  color: #666;
  font-size: 0.9rem;
}

/* Animações */
@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

@keyframes dots1 {
  0% {
    transform: scale(0);
  }
  100% {
    transform: scale(1);
  }
}

@keyframes dots3 {
  0% {
    transform: scale(1);
  }
  100% {
    transform: scale(0);
  }
}

@keyframes dots2 {
  0% {
    transform: translate(0, 0);
  }
  100% {
    transform: translate(24px, 0);
  }
}

/* Loading para botões */
.btn-loading {
  position: relative;
  pointer-events: none;
}



/* Loading inline */
.loading-inline {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.loading-inline .spinner-small {
  width: 20px;
  height: 20px;
  border: 2px solid #e3e3e3;
  border-top: 2px solid #28a745;
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

/* Variações de cor */
.loading-primary .loading-spinner {
  border-top-color: #007bff;
}

.loading-primary .loading-dots div {
  background: #007bff;
}

.loading-success .loading-spinner {
  border-top-color: #28a745;
}

.loading-success .loading-dots div {
  background: #28a745;
}

.loading-warning .loading-spinner {
  border-top-color: #ffc107;
}

.loading-warning .loading-dots div {
  background: #ffc107;
}

/* Responsivo */
@media (max-width: 768px) {
  .loading-container {
    max-width: 250px;
    padding: 1.5rem;
  }
  
  .loading-text {
    font-size: 1rem;
  }
  
  .loading-subtext {
    font-size: 0.8rem;
  }
}