/* Reset and base styles */
* {
  box-sizing: border-box;
}

body, html {
  margin: 0;
  padding: 0;
  height: 100%;
  overflow: hidden;
}

/* Loading screen */
#loading-screen {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  z-index: 9999;
  background-color: var(--background-color);
  transition: opacity 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

#loading-screen.hidden {
  opacity: 0;
  pointer-events: none;
}

.loading-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

/* Logo */
.loading-logo {
  width: 80px;
  height: 80px;
  margin: 0 auto 16px;
  background-image: var(--logo-image);
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
}

/* Typography */
.loading-title {
  color: var(--text-color);
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  font-size: 24px;
  font-weight: 700;
  margin: 0 0 8px;
}

.loading-subtitle {
  color: var(--text-secondary);
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  font-size: 12px;
  font-weight: 400;
  margin: 0 0 16px;
}

/* Progress bar */
.progress-container {
  width: 190px;
  height: 2px;
  background: var(--border-color);
  border-radius: 2px;
  overflow: hidden;
}

.progress-bar {
  height: 100%;
  background: var(--accent-color);
  border-radius: 2px;
  width: 0%;
  transition: width 0.3s ease;
}

/* Accessibility */
@media (prefers-reduced-motion: reduce) {
  #loading-screen {
    transition: none;
  }
}

@media (max-width: 480px) {
  .loading-title {
    font-size: 20px;
  }

  .loading-logo {
    width: 64px;
    height: 64px;
  }
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}