:root {
  --primary: #00f7ff;
  --secondary: #7700ff;
  --accent: #ff00c8;
  --dark: #0a0a1a;
  --darker: #050510;
  --light: #ffffff;
  --glass: rgba(255, 255, 255, 0.05);
  --glass-border: rgba(255, 255, 255, 0.1);
  --glass-hover: rgba(255, 255, 255, 0.1);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
  background: linear-gradient(135deg, var(--darker) 0%, var(--dark) 100%);
  color: var(--light);
  min-height: 100vh;
  overflow-x: hidden;
  line-height: 1.6;
}

body::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background:
    radial-gradient(circle at 20% 30%, rgba(119, 0, 255, 0.15) 0%, transparent 50%),
    radial-gradient(circle at 80% 70%, rgba(0, 247, 255, 0.1) 0%, transparent 50%),
    radial-gradient(circle at 40% 80%, rgba(255, 0, 200, 0.1) 0%, transparent 50%);
  pointer-events: none;
  z-index: -1;
}

/* Hide Flutter default splash */
#splash {
  display: none;
}


/* Advanced Preloader Styles - FIXED BACKGROUND */
.advanced-preloader {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  /* Use the same gradient as body to prevent flash */
  background: linear-gradient(135deg, var(--darker) 0%, var(--dark) 100%);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 9999;
  transition: opacity 0.5s ease-out;
}

/* Rest of your CSS remains the same */
.preloader-content {
  text-align: center;
  max-width: 600px;
  width: 90%;
}

.logo-container {
  position: relative;
  width: 120px;
  height: 120px;
  margin: 0 auto 40px;
}

.logo-backdrop {
  position: absolute;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  background: conic-gradient(var(--primary), var(--secondary), var(--accent), var(--primary));
  animation: rotate 3s linear infinite;
  filter: blur(10px);
  opacity: 0.7;
}

.logo-backdrop::after {
  content: '';
  position: absolute;
  inset: 5px;
  background: var(--dark);
  border-radius: 50%;
  filter: blur(10px);
}

.logo-img {
  position: relative;
  width: 100%;
  height: 100%;
  object-fit: contain;
  border-radius: 50%;
  z-index: 2;
  filter: drop-shadow(0 0 15px var(--primary));
}

.progress-container {
  width: 100%;
  height: 6px;
  background: var(--glass);
  border-radius: 10px;
  overflow: hidden;
  margin: 30px 0;
  position: relative;
}

.progress-bar {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, var(--secondary), var(--primary));
  border-radius: 10px;
  transition: width 0.3s ease;
  position: relative;
  overflow: hidden;
}

.progress-bar::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
  animation: shimmer 2s infinite;
}

.loading-text {
  font-size: 1.2rem;
  margin-bottom: 20px;
  font-weight: 300;
  letter-spacing: 1px;
  color: var(--light);
  text-shadow: 0 0 10px var(--primary);
  height: 30px;
}

.loading-dots {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-bottom: 40px;
}

.dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--primary);
  opacity: 0.6;
  animation: pulse 1.5s infinite ease-in-out;
}

.dot:nth-child(2) {
  animation-delay: 0.2s;
}

.dot:nth-child(3) {
  animation-delay: 0.4s;
}

.feature-highlights {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-top: 30px;
}

.feature {
  background: var(--glass);
  border: 1px solid var(--glass-border);
  border-radius: 16px;
  padding: 20px;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  transition: all 0.3s ease;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.feature:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 20px rgba(0, 247, 255, 0.1);
  border-color: var(--primary);
}

.feature-icon {
  width: 30px;
  height: 30px;
  color: var(--primary);
  margin-bottom: 15px;
  filter: drop-shadow(0 0 5px var(--primary));
}

.feature span {
  font-size: 0.9rem;
  font-weight: 300;
}

/* Animations */
@keyframes rotate {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}

@keyframes pulse {
  0%, 100% {
    transform: scale(1);
    opacity: 0.6;
  }
  50% {
    transform: scale(1.2);
    opacity: 1;
  }
}

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

@keyframes float {
  0%, 100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-10px);
  }
}

/* Responsive Design */
@media (max-width: 768px) {
  .feature-highlights {
    grid-template-columns: 1fr;
  }

  .logo-container {
    width: 100px;
    height: 100px;
  }

  .loading-text {
    font-size: 1rem;
  }
}