/* Base reset and layout */
body, html {
  margin: 0;
  padding: 0;
  height: 100%;
  background: black;
  overflow: hidden;
  cursor: none;
  font-family: 'Segoe UI', sans-serif;
}

/* Container for everything */
.overlay-container {
  position: relative;
  width: 100vw;
  height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 20px; /* Adjusted gap for better spacing */
}

/* Smoke video background */
.smoke-video {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 1;
  opacity: 0.65;
  mix-blend-mode: screen;
  pointer-events: none;
}

/* Particle canvas */
#particle-canvas {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 2;
  pointer-events: none;
}

/* Logo container */
.logo-container {
  position: relative;
  z-index: 4;
  text-align: center;
}

.logo-container img {
  width: 180px; /* Reduced size to prevent overflow */
  height: auto;
  filter: drop-shadow(0 0 20px #00aaff);
  animation: pulseLogo 2.2s infinite ease-in-out;
}

/* Pulsing logo animation */
@keyframes pulseLogo {
  0%, 100% { transform: scale(1.7); }
  50% { transform: scale(1.55); }
}

/* Login/signup box */
.auth-box {
  position: relative;
  z-index: 3;
  background: rgba(0, 0, 0, 0.75);
  padding: 70px 50px 50px; /* Increased padding for signup form */
  border-radius: 15px;
  box-shadow: 0 0 30px #00aaff99;
  text-align: center;
  backdrop-filter: blur(12px);
  max-width: 350px;
  width: 90%;
  transition: transform 0.4s ease, box-shadow 0.4s ease;
}

.auth-box:hover {
  transform: translateY(-5px);
  box-shadow: 0 0 40px #00aaffcc;
}

/* Input container for better animation control */
.input-container {
  position: relative;
  margin: 12px 0;
}

/* Inputs styling */
.auth-box input, .auth-box select {
  width: 100%;
  padding: 14px 16px;
  border: none;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.2);
  color: white;
  font-size: 1rem;
  transition: all 0.4s ease;
}

.auth-box input:focus, .auth-box select:focus {
  outline: none;
  background: rgba(255, 255, 255, 0.25);
  box-shadow: 0 0 10px #00aaff;
  transform: scale(1.02);
}

.auth-box input::placeholder, .auth-box select:invalid {
  color: #ddd;
  transition: opacity 0.4s;
}

.auth-box input:focus::placeholder, .auth-box select:focus:invalid {
  opacity: 0.4;
}

/* Select styling for dropdown */
.auth-box select {
  appearance: none;
  background-image: url('data:image/svg+xml;utf8,<svg fill="%23ddd" height="24" viewBox="0 0 24 24" width="24" xmlns="http://www.w3.org/2000/svg"><path d="M7 10l5 5 5-5z"/></svg>');
  background-repeat: no-repeat;
  background-position: right 10px center;
}

/* Error message styling */
.error-message {
  color: #ff4d4d;
  font-size: 0.85rem;
  min-height: 1.4rem;
  margin-top: 6px;
  display: block;
  text-align: left;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.error-message:not(:empty) {
  opacity: 1;
}

/* Buttons container */
.auth-box .buttons {
  display: flex;
  gap: 12px;
  margin-top: 20px;
}

/* Buttons style */
.auth-box button {
  flex: 1;
  padding: 12px 0;
  border: none;
  border-radius: 10px;
  font-weight: bold;
  font-size: 1rem;
  cursor: pointer;
  background: linear-gradient(45deg, #1C2526, #4A4E69);
  color: white;
  transition: all 0.4s ease;
  position: relative;
  overflow: hidden;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.auth-box button::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.2),
    transparent
  );
  transition: 0.6s;
}

.auth-box button:hover::before {
  left: 100%;
}

.auth-box button:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 20px rgba(74, 78, 105, 0.5);
  background: linear-gradient(45deg, #2A3233, #5A5E7A);
}

/* Alternate button style (Sign Up / Back to Login) */
.auth-box button.alt {
  background: transparent;
  border: 2px solid #4A4E69;
}

.auth-box button.alt:hover {
  background: linear-gradient(45deg, #1C2526, #4A4E69);
  border-color: transparent;
  box-shadow: 0 8px 20px rgba(74, 78, 105, 0.5);
}

/* Custom metallic-blue glowing mouse cursor */
.custom-cursor {
  width: 10px;
  height: 10px;
  background: #00aaff;
  border-radius: 50%;
  position: fixed;
  pointer-events: none;
  z-index: 999;
  transform: translate(-50%, -50%);
  box-shadow:
    0 0 15px #00aaff,
    0 0 25px #33ccff,
    0 0 35px #0088cc;
  animation: bluePulse 1.8s infinite ease-in-out;
  mix-blend-mode: screen;
}

/* Animations */
@keyframes bluePulse {
  0% { box-shadow: 0 0 12px #00aaff; }
  50% { box-shadow: 0 0 25px #33ccff; }
  100% { box-shadow: 0 0 12px #0088cc; }
}

/* Responsive design */
@media (max-width: 600px) {
  .logo-container img {
    width: 140px;
  }

  .auth-box {
    padding: 50px 20px 20px;
    max-width: 300px;
  }

  .auth-box input, .auth-box select {
    padding: 12px 14px;
    font-size: 0.95rem;
  }

  .auth-box button {
    padding: 10px 0;
    font-size: 0.95rem;
  }

  .overlay-container {
    gap: 10px;
  }
}