/* Loader Styles */
html.is-loading {
  overflow: hidden !important;
  height: 100% !important;
}

html.is-loading body {
  overflow: hidden !important;
  height: 100% !important;
  margin: 0;
  padding: 0;
  visibility: hidden;
  opacity: 0;
  transition: opacity 0.5s ease-in-out;
}

html:not(.is-loading) body {
  visibility: visible;
  opacity: 1;
}

.app-loader {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: #1a1a1a;
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 9999;
  transition: opacity 0.5s ease-out, visibility 0.5s ease-out;
  opacity: 1;
}

.app-loader.hidden {
  opacity: 0;
  pointer-events: none;
}

.loader-box {
  text-align: center;
  color: #ffffff;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
  width: 280px;
  padding: 30px;
  border-radius: 12px;
  background: rgba(0, 0, 0, 0.7);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.loader-logo {
  width: 120px;
  height: auto;
  margin: 0 auto 25px;
  display: block;
  animation: pulse 2s infinite ease-in-out;
}

.progress-track {
  width: 100%;
  height: 6px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 3px;
  margin: 0 auto 15px;
  overflow: hidden;
  position: relative;
}

.progress-bar {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, #4a6cf7, #6e56ff);
  border-radius: 3px;
  transition: width 0.3s ease-out;
  position: relative;
  overflow: hidden;
}

.progress-bar::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(
    90deg,
    rgba(255, 255, 255, 0) 0%,
    rgba(255, 255, 255, 0.6) 50%,
    rgba(255, 255, 255, 0) 100%
  );
  animation: shimmer 2s infinite linear;
  transform: translateX(-100%);
}

.progress-text {
  font-size: 14px;
  color: rgba(255, 255, 255, 0.8);
  font-weight: 500;
  letter-spacing: 0.5px;
  margin-top: 15px;
  text-transform: uppercase;
  font-size: 12px;
  opacity: 0.9;
}

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

@keyframes shimmer {
  100% {
    transform: translateX(100%);
  }
}

/* Fallback for older browsers */
@supports not (backdrop-filter: blur(8px)) {
  .loader-box {
    background: rgba(0, 0, 0, 0.85);
  }
}

