.auth-container {
  flex: 1;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 3rem 1.5rem;
  position: relative;
  z-index: 10;
}

.auth-card {
  width: 100%;
  max-width: 440px;
  background: rgba(14, 18, 27, 0.75);
  backdrop-filter: blur(20px);
  border: 1px solid var(--card-border);
  border-radius: 20px;
  padding: 2.5rem 2rem;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
}

.auth-header {
  text-align: center;
  margin-bottom: 2rem;
}

.auth-header h2 {
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--text-main);
  margin-bottom: 0.5rem;
  letter-spacing: -0.5px;
}

.auth-header p {
  color: var(--text-muted);
  font-size: 0.9rem;
  line-height: 1.4;
}

.alert {
  padding: 0.85rem 1rem;
  border-radius: 10px;
  font-size: 0.875rem;
  margin-bottom: 1.5rem;
}

.alert-danger {
  background: rgba(244, 63, 94, 0.12);
  border: 1px solid rgba(244, 63, 94, 0.3);
  color: #fca5a5;
}

.auth-form {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.form-group label {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-main);
}

.label-wrapper {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.forgot-link {
  font-size: 0.8rem;
  color: var(--primary);
  text-decoration: none;
  font-weight: 500;
}

.forgot-link:hover {
  text-decoration: underline;
}

.form-group input {
  width: 100%;
  padding: 0.8rem 1rem;
  background: rgba(7, 9, 14, 0.8);
  border: 1px solid var(--card-border);
  border-radius: 10px;
  color: var(--text-main);
  font-size: 0.95rem;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.form-group input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px var(--primary-glow);
}

.password-input-wrapper {
  position: relative;
  display: flex;
  align-items: center;
}

.btn-toggle-pw {
  position: absolute;
  right: 0.75rem;
  background: none;
  border: none;
  cursor: pointer;
  opacity: 0.6;
  font-size: 0.9rem;
  transition: opacity 0.2s;
}

.btn-toggle-pw:hover {
  opacity: 1;
}

.btn-block {
  width: 100%;
  padding: 0.85rem;
  margin-top: 0.5rem;
  font-size: 1rem;
}

.auth-footer {
  margin-top: 2rem;
  text-align: center;
  border-top: 1px solid var(--card-border);
  padding-top: 1.25rem;
}

.auth-footer p {
  color: var(--text-muted);
  font-size: 0.775rem;
  line-height: 1.4;
}

.loading-overlay {
  position: fixed;
  inset: 0;
  background: rgba(10, 15, 29, 0.85);
  backdrop-filter: blur(8px);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 99999;
}

.loading-box {
  background: rgba(15, 23, 42, 0.95);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 16px;
  padding: 36px 32px;
  text-align: center;
  max-width: 400px;
  width: 90%;
  box-shadow: 0 20px 45px rgba(0, 0, 0, 0.6);
  color: #ffffff;
  animation: fadeIn 0.25s ease-out;
}

.loading-spinner {
  width: 48px;
  height: 48px;
  margin: 0 auto 16px;
  border: 4px solid rgba(56, 189, 248, 0.2);
  border-top-color: #38bdf8;
  border-radius: 50%;
  animation: spin 0.85s linear infinite;
}

.loading-box h3 {
  margin: 0 0 8px;
  font-size: 1.25rem;
  color: #38bdf8;
}

.loading-box p {
  margin: 0;
  font-size: 0.9rem;
  color: #94a3b8;
  line-height: 1.5;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

@keyframes fadeIn {
  from { opacity: 0; transform: scale(0.96); }
  to { opacity: 1; transform: scale(1); }
}

@media (max-width: 480px) {
  .auth-card {
    padding: 1.75rem 1.25rem;
  }
}
