* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Poppins', sans-serif;
  background-color: #0F0F0F;
  color: #FFFFFF;
  line-height: 1.6;
}

.signup-login-container {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  padding: 0 20px;
}

/* Header */
.header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 15px;
  background-color: #1A1A1A;
  border-bottom: 1px solid #333;
  width: 100%;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
}

.logo-text {
  font-size: 28px;
  font-weight: 700;
  color: #00FF99;
  text-transform: uppercase;
  letter-spacing: 2px;
}

.logo-placeholder {
  width: 40px;
  height: 40px;
  background-color: #1A1A1A;
  border-radius: 50%;
  border: 2px solid #00FF99;
}

.home-btn {
  color: #00FF99;
  text-decoration: none;
  font-size: 14px;
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 5px 10px;
  border: 1px solid #00FF99;
  border-radius: 5px;
  transition: all 0.3s ease;
}

.home-btn:hover {
  background-color: #00FF99;
  color: #0F0F0F;
  transform: translateY(-1px);
  box-shadow: 0 2px 4px rgba(0, 255, 153, 0.3);
}

.home-btn i {
  font-size: 16px;
}

/* Main Content – tighter vertical centering */
.auth-main {
  flex: 1;
  display: flex;
  justify-content: center;
  align-items: flex-start;
  padding: 50px 20px 80px;     /* reduced top padding */
}

.auth-card {
  background: #1A1A1A;
  padding: 32px 28px;           /* reduced padding overall */
  border-radius: 10px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.5);
  width: 100%;
  max-width: 450px;
  text-align: center;
  animation: fadeIn 0.5s ease-in;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(-20px); }
  to { opacity: 1; transform: translateY(0); }
}

.auth-title {
  font-size: 28px;
  font-weight: 600;
  color: #00FF99;
  margin-bottom: 8px;           /* tighter */
}

.auth-subtitle {
  font-size: 14px;
  color: #888;
  margin-bottom: 16px;          /* tighter */
}

.toggle-buttons {
  display: flex;
  gap: 10px;
  margin-bottom: 16px;          /* tighter */
}

.toggle-btn {
  background: #2D2D2D;
  color: #FFFFFF;
  border: none;
  padding: 10px 20px;
  border-radius: 5px;
  cursor: pointer;
  font-size: 14px;
  font-weight: 500;
  transition: all 0.3s ease;
}

.toggle-btn.active {
  background: linear-gradient(90deg, #00FF99, #00CC80);
  color: #0F0F0F;
  transform: scale(1.05);
}

.toggle-btn:hover {
  background: #3D3D3D;
}

.auth-form {
  display: flex;
  flex-direction: column;
  gap: 15px;
  opacity: 1;
  transition: opacity 0.3s ease-in-out;
}

.auth-form.hidden {
  display: none;                /* stronger hiding – prevents layout influence */
}

/* ─── Multi-step signup only ──────────────────────────────────────── */
#signup-container {
  display: none;                /* default hidden */
}

#signup-container:not(.hidden) {
  display: block;
  min-height: 340px;            /* only apply when visible – smaller value */
}

#signup-toggle.active ~ #signup-container {
  display: block;               /* show when signup toggle is active */
}

.step {
  display: flex;
  flex-direction: column;
  gap: 15px;
  transition: opacity 0.4s ease;
}

.step.hidden {
  display: none;
}

.step-buttons {
  display: flex;
  gap: 12px;
  justify-content: space-between;
  margin-top: 20px;
}

.auth-btn.secondary {
  background: #2D2D2D;
  color: #FFFFFF;
  border: 1px solid #444;
}

.auth-btn.secondary:hover {
  background: #3D3D3D;
  border-color: #666;
  transform: translateY(-1px);
}

/* Form Groups */
.form-group {
  text-align: left;
  margin-top: 4px;              /* very small top margin – first group almost touches toggle */
}

.form-group:first-child {
  margin-top: 0;                /* first one has no top margin */
}

.form-group label {
  display: block;
  font-size: 14px;
  color: #BBBBBB;
  margin-bottom: 5px;
}

.form-group input,
.form-group select {
  width: 100%;
  padding: 12px 40px 12px 12px;
  border: 1px solid #333;
  border-radius: 5px;
  background-color: #222222;
  color: #FFFFFF;
  font-size: 14px;
  transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.form-group input:focus,
.form-group select:focus {
  border-color: #00FF99;
  box-shadow: 0 0 0 3px rgba(0, 255, 153, 0.15);
  outline: none;
}

.form-group select {
  appearance: none;
  background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%2300FF99'%3e%3cpath d='M7 10l5 5 5-5z'/%3e%3c/svg%3e");
  background-repeat: no-repeat;
  background-position: right 12px center;
  background-size: 18px;
}

.form-group select option[disabled] {
  color: #888;
}

.error {
  font-size: 12px;
  color: #FF4444;
  display: block;
  margin-top: 5px;
  height: 15px;
}

.auth-btn {
  background: linear-gradient(90deg, #00FF99, #00CC80);
  color: #0F0F0F;
  border: none;
  padding: 12px;
  border-radius: 5px;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
}

.auth-btn:hover {
  background: linear-gradient(90deg, #00CC80, #00FF99);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 255, 153, 0.3);
}

.forgot-password {
  display: block;
  text-align: right;
  color: #00FF99;
  font-size: 12px;
  text-decoration: none;
  margin-top: 8px;
  transition: color 0.3s ease;
}

.forgot-password:hover {
  color: #00CC80;
}

/* Footer */
.footer {
  padding: 20px 0;
  border-top: 1px solid #1A1A1A;
  max-width: 1200px;
  margin: 0 auto;
  width: 100%;
}

.footer-legal {
  font-size: 12px;
  color: #888;
  text-align: center;
}

/* Responsive */
@media (max-width: 768px) {
  .auth-main {
    padding: 40px 15px 60px;
  }
  
  .auth-card {
    padding: 24px 20px;
  }
  
  .auth-title {
    font-size: 24px;
  }
  
  .auth-subtitle {
    font-size: 13px;
  }
  
  #signup-container:not(.hidden) {
    min-height: 380px;          /* slightly more on mobile when needed */
  }
}

@media (min-width: 1024px) {
  .auth-main {
    padding: 70px 20px 100px;
  }
}