/* ========================================
   AUTH PAGES STYLES
   Login, Register, Forgot Password
   ======================================== */

.auth-page {
  min-height: 100vh;
  display: flex;
  background: linear-gradient(135deg, var(--bg-gradient-start) 0%, var(--bg-gradient-end) 100%);
}

/* Layout split */
.auth-container {
  display: flex;
  width: 100%;
  min-height: 100vh;
}

/* Left side - Branding */
.auth-brand {
  flex: 1;
  background: linear-gradient(135deg, #1c1917 0%, #292524 100%);
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 60px;
  position: relative;
  overflow: hidden;
}

.auth-brand::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -50%;
  width: 100%;
  height: 200%;
  background: radial-gradient(circle, rgba(37, 99, 235, 0.1) 0%, transparent 50%);
  animation: float 20s ease-in-out infinite;
}

.auth-brand::after {
  content: '';
  position: absolute;
  bottom: -30%;
  left: -30%;
  width: 80%;
  height: 80%;
  background: radial-gradient(circle, rgba(139, 115, 85, 0.08) 0%, transparent 50%);
  animation: float 25s ease-in-out infinite reverse;
}

@keyframes float {
  0%, 100% { transform: translate(0, 0) rotate(0deg); }
  25% { transform: translate(2%, -2%) rotate(1deg); }
  50% { transform: translate(0, -4%) rotate(0deg); }
  75% { transform: translate(-2%, -2%) rotate(-1deg); }
}

.auth-brand-content {
  position: relative;
  z-index: 1;
  max-width: 480px;
}

.auth-brand-logo {
  width: 180px;
  height: auto;
  margin-bottom: 40px;
}

.auth-brand-title {
  font-size: 40px;
  font-weight: 800;
  color: #ffffff;
  line-height: 1.2;
  margin-bottom: 20px;
}

.auth-brand-title span {
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent-tertiary) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.auth-brand-text {
  font-size: 18px;
  color: rgba(255, 255, 255, 0.7);
  line-height: 1.7;
  margin-bottom: 40px;
}

.auth-brand-features {
  list-style: none;
}

.auth-brand-feature {
  display: flex;
  align-items: center;
  gap: 12px;
  color: rgba(255, 255, 255, 0.8);
  font-size: 15px;
  margin-bottom: 16px;
}

.auth-brand-feature-icon {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: rgba(37, 99, 235, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent-tertiary);
  font-size: 16px;
}

/* Right side - Form */
.auth-form-side {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px;
  position: relative;
}

.auth-form-container {
  width: 100%;
  max-width: 440px;
}

.auth-form-header {
  text-align: center;
  margin-bottom: 40px;
}

.auth-logo-mobile {
  display: none !important;
  width: 80px;
  height: 80px;
  margin: 0 auto 24px;
  border-radius: 16px;
}

.auth-form-title {
  font-size: 28px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 8px;
}

.auth-form-subtitle {
  font-size: 15px;
  color: var(--text-muted);
}

/* Form Card */
.auth-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 36px;
  box-shadow: var(--shadow-lg);
}

.auth-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

/* Password visibility toggle */
.password-toggle {
  position: absolute;
  right: 16px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: color var(--transition-fast);
}

.password-toggle:hover {
  color: var(--text);
}

/* Remember me & Forgot password */
.auth-options {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}

.remember-me {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  color: var(--text-muted);
  cursor: pointer;
}

.remember-me input {
  width: 18px;
  height: 18px;
  accent-color: var(--accent);
  cursor: pointer;
}

.forgot-link {
  font-size: 14px;
  color: var(--accent);
  font-weight: 500;
}

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

/* Social login */
.social-login {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.btn-social {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  width: 100%;
  padding: 14px 20px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 12px;
  font-size: 15px;
  font-weight: 500;
  color: var(--text);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.btn-social:hover {
  background: var(--bg-card);
  border-color: var(--text-muted);
  box-shadow: var(--shadow-sm);
}

.btn-social svg {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

/* Auth footer */
.auth-footer {
  text-align: center;
  margin-top: 24px;
  font-size: 14px;
  color: var(--text-muted);
}

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

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

/* Success/Error states */
.auth-message {
  padding: 16px 20px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 20px;
  animation: slideUp 0.3s ease-out;
}

.auth-message-icon {
  font-size: 20px;
  flex-shrink: 0;
}

.auth-message-text {
  font-size: 14px;
  line-height: 1.5;
}

.auth-message-success {
  background: var(--accent-green-soft);
  color: #166534;
  border: 1px solid rgba(34, 197, 94, 0.2);
}

.auth-message-error {
  background: var(--accent-red-soft);
  color: #991b1b;
  border: 1px solid rgba(239, 68, 68, 0.2);
}

/* Back link */
.auth-back {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--text-muted);
  font-size: 14px;
  margin-bottom: 24px;
  transition: color var(--transition-fast);
}

.auth-back:hover {
  color: var(--accent);
}

/* Theme toggle on auth pages */
.auth-theme-toggle {
  position: absolute;
  top: 24px;
  right: 24px;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: var(--bg-card);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--text-muted);
  transition: all var(--transition-fast);
}

.auth-theme-toggle:hover {
  background: var(--accent);
  border-color: var(--accent);
  color: white;
}

/* Password strength indicator */
.password-strength {
  margin-top: 8px;
}

.password-strength-bar {
  height: 4px;
  background: var(--border);
  border-radius: 2px;
  overflow: hidden;
  margin-bottom: 6px;
}

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

.password-strength-fill.weak {
  width: 25%;
  background: var(--accent-red);
}

.password-strength-fill.fair {
  width: 50%;
  background: var(--accent-orange);
}

.password-strength-fill.good {
  width: 75%;
  background: #eab308;
}

.password-strength-fill.strong {
  width: 100%;
  background: var(--accent-green);
}

.password-strength-text {
  font-size: 12px;
  color: var(--text-muted);
}

/* Responsive */
@media (max-width: 1024px) {
  .auth-brand {
    display: none;
  }
  
  .auth-form-side {
    flex: 1;
    padding: 24px;
  }
  
  .auth-logo-mobile {
    display: block !important;
  }
  
  .auth-form-container {
    max-width: 100%;
  }
  
  .auth-card {
    padding: 28px;
    border-radius: 16px;
  }
}

@media (max-width: 480px) {
  .auth-form-side {
    padding: 16px;
  }
  
  .auth-card {
    padding: 24px 20px;
  }
  
  .auth-form-title {
    font-size: 24px;
  }
  
  .auth-options {
    flex-direction: column;
    align-items: flex-start;
  }
}
