/* ============================================================
   AUTH PAGES SHARED STYLES
   Login, Signup, Verify, Forgot/Reset Password
   ============================================================ */

.auth-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 5rem 1.5rem 3rem;
}

.auth-container {
  width: 100%;
  max-width: 440px;
  animation: fadeInUp 0.5s ease;
}

/* ---- Auth Card ---- */
.auth-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: calc(var(--radius) * 1.5);
  padding: 2.5rem;
  position: relative;
  overflow: hidden;
}

.auth-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: var(--gradient-primary);
}

.auth-card::after {
  content: '';
  position: absolute;
  top: -100px; right: -100px;
  width: 300px; height: 300px;
  background: radial-gradient(circle, rgba(0,255,136,0.04), transparent 70%);
  pointer-events: none;
}

[data-theme="light"] .auth-card::after {
  background: radial-gradient(circle, rgba(0,85,204,0.04), transparent 70%);
}

/* ---- Auth Header ---- */
.auth-header {
  text-align: center;
  margin-bottom: 2rem;
}

.auth-logo {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  text-decoration: none;
  margin-bottom: 1.5rem;
}

.auth-logo .logo-placeholder {
  width: 40px; height: 40px;
  border-radius: 10px;
  background: var(--gradient-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 900;
  font-size: 0.8rem;
  color: #000;
}

.auth-logo span {
  font-weight: 800;
  font-size: 1.1rem;
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.auth-title {
  font-size: 1.6rem;
  font-weight: 900;
  letter-spacing: -0.02em;
  margin-bottom: 0.4rem;
}

.auth-subtitle {
  font-size: 0.875rem;
  color: var(--text-secondary);
}

/* ---- Error/Success Banners ---- */
.auth-error-banner,
.auth-success-banner {
  display: none;
  align-items: flex-start;
  gap: 0.75rem;
  padding: 0.875rem 1rem;
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
  margin-bottom: 1.25rem;
  line-height: 1.5;
}

.auth-error-banner.visible,
.auth-success-banner.visible {
  display: flex;
}

.auth-error-banner {
  background: rgba(255,68,102,0.08);
  border: 1px solid rgba(255,68,102,0.25);
  color: #ff6688;
}

.auth-success-banner {
  background: rgba(0,255,136,0.08);
  border: 1px solid rgba(0,255,136,0.25);
  color: var(--accent-primary);
}

[data-theme="light"] .auth-error-banner { color: #cc2244; }
[data-theme="light"] .auth-success-banner { color: var(--accent-primary); }

/* ---- Auth Form ---- */
.auth-form {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.auth-submit {
  margin-top: 1.25rem;
  height: 46px;
  font-size: 0.95rem;
}

/* ---- Auth Footer ---- */
.auth-footer {
  text-align: center;
  margin-top: 1.5rem;
  font-size: 0.85rem;
  color: var(--text-secondary);
}

.auth-footer a {
  color: var(--text-accent);
  font-weight: 600;
  text-decoration: none;
}

.auth-footer a:hover { text-decoration: underline; }

.auth-divider {
  display: flex;
  align-items: center;
  gap: 1rem;
  color: var(--text-muted);
  font-size: 0.8rem;
  margin: 1.25rem 0;
}

.auth-divider::before,
.auth-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--border-color);
}

/* ---- Password Strength ---- */
.password-strength {
  margin-top: 0.5rem;
}

.strength-bar {
  height: 3px;
  background: var(--border-color);
  border-radius: 2px;
  overflow: hidden;
  margin-bottom: 0.3rem;
}

.strength-fill {
  height: 100%;
  border-radius: 2px;
  transition: width 0.3s ease, background 0.3s ease;
  width: 0;
}

.strength-fill.weak { background: #ff4466; width: 25%; }
.strength-fill.fair { background: #ffc800; width: 50%; }
.strength-fill.good { background: #00ccff; width: 75%; }
.strength-fill.strong { background: #00ff88; width: 100%; }

.strength-label {
  font-size: 0.7rem;
  color: var(--text-muted);
}

/* ---- OTP / Code Input ---- */
.otp-container {
  display: flex;
  gap: 0.5rem;
  justify-content: center;
  margin: 1rem 0;
}

.otp-input {
  width: 48px; height: 56px;
  text-align: center;
  font-size: 1.4rem;
  font-weight: 700;
  font-family: var(--font-mono);
  background: var(--bg-input);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  color: var(--text-primary);
  outline: none;
  transition: var(--transition);
}

.otp-input:focus {
  border-color: var(--accent-primary);
  box-shadow: 0 0 0 3px rgba(0,255,136,0.1);
}

/* ---- Verify Success/Error Cards ---- */
.verify-card {
  text-align: center;
  padding: 1rem 0;
}

.verify-icon {
  font-size: 3rem;
  margin-bottom: 1rem;
  display: block;
}

.verify-card h2 {
  font-size: 1.4rem;
  font-weight: 800;
  margin-bottom: 0.5rem;
}

.verify-card p {
  font-size: 0.875rem;
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
  line-height: 1.6;
}

/* ---- Spinner in button ---- */
.btn .spinner {
  width: 16px; height: 16px;
  border: 2px solid rgba(0,0,0,0.25);
  border-top-color: #000;
  border-radius: 50%;
  animation: spin 0.6s linear infinite;
  display: inline-block;
  flex-shrink: 0;
}

/* ---- Step Indicator (signup) ---- */
.auth-steps {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  margin-bottom: 1.75rem;
}

.auth-step {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--text-muted);
}

.auth-step.active { color: var(--text-accent); }
.auth-step.done { color: var(--accent-primary); }

.step-dot {
  width: 24px; height: 24px;
  border-radius: 50%;
  background: var(--bg-input);
  border: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.65rem;
  font-weight: 800;
  flex-shrink: 0;
}

.auth-step.active .step-dot {
  background: var(--gradient-primary);
  border-color: transparent;
  color: #000;
}

.auth-step.done .step-dot {
  background: rgba(0,255,136,0.15);
  border-color: rgba(0,255,136,0.3);
  color: var(--accent-primary);
}

.step-connector-line {
  flex: 1;
  height: 1px;
  background: var(--border-color);
  max-width: 40px;
}

/* ---- Admin Login Special ---- */
.admin-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.3rem 0.75rem;
  background: rgba(255,200,0,0.08);
  border: 1px solid rgba(255,200,0,0.2);
  border-radius: 100px;
  font-size: 0.7rem;
  font-weight: 700;
  color: #ffc800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 1rem;
}

/* ---- Responsive ---- */
@media (max-width: 480px) {
  .auth-card { padding: 1.75rem 1.25rem; }
  .auth-title { font-size: 1.4rem; }
}
