/* =============================================
   UNBAN.LIVE - Auth Styles (Login/Register)
   ============================================= */

/* Auth Page Layout */
.auth-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px 20px;
  position: relative;
}

.auth-container {
  width: 100%;
  max-width: 440px;
  position: relative;
  z-index: 1;
}

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

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

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

.auth-logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--text-primary);
  text-decoration: none;
  margin-bottom: 24px;
}

.auth-logo .logo-icon {
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--gradient-primary);
  border-radius: var(--radius-md);
}

.auth-logo .logo-icon svg {
  width: 24px;
  height: 24px;
  color: white;
}

.auth-logo .logo-text {
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.auth-header h1 {
  font-size: 1.75rem;
  margin-bottom: 8px;
}

.auth-header p {
  color: var(--text-secondary);
  font-size: 0.9375rem;
}

/* Form Styles */
.auth-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.form-group {
  margin-bottom: 0;
}

.form-group label {
  display: block;
  margin-bottom: 8px;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--text-secondary);
}

.input-wrapper {
  position: relative;
}

.input-wrapper .input-icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  width: 20px;
  height: 20px;
  color: var(--text-muted);
  pointer-events: none;
  transition: color var(--transition-fast);
}

.input-wrapper input {
  width: 100%;
  padding: 14px 14px 14px 46px;
  font-family: inherit;
  font-size: 1rem;
  color: var(--text-primary);
  background: var(--bg-input);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  outline: none;
  transition: all var(--transition-fast);
}

.input-wrapper input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.15);
}

.input-wrapper input:focus + .input-icon,
.input-wrapper input:focus ~ .input-icon {
  color: var(--primary);
}

.input-wrapper input::placeholder {
  color: var(--text-muted);
}

/* Password Toggle */
.toggle-password {
  position: absolute;
  right: 14px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  padding: 4px;
  cursor: pointer;
  color: var(--text-muted);
  transition: color var(--transition-fast);
}

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

.toggle-password svg {
  width: 20px;
  height: 20px;
}

.input-wrapper input[type="password"] ~ .toggle-password .eye-off,
.input-wrapper input[type="text"] ~ .toggle-password .eye-on {
  display: none;
}

.input-wrapper input[type="password"] ~ .toggle-password .eye-on,
.input-wrapper input[type="text"] ~ .toggle-password .eye-off {
  display: block;
}

/* Has password toggle - extra padding */
.input-wrapper.has-toggle input {
  padding-right: 46px;
}

/* Error State */
.input-wrapper.has-error input {
  border-color: var(--error);
}

.input-wrapper.has-error .input-icon {
  color: var(--error);
}

.field-error {
  display: block;
  margin-top: 6px;
  font-size: 0.8125rem;
  color: var(--error);
  opacity: 0;
  transform: translateY(-4px);
  transition: all var(--transition-fast);
}

.field-error.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Checkbox */
.checkbox-wrapper {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  cursor: pointer;
}

.checkbox-wrapper input[type="checkbox"] {
  display: none;
}

.checkbox-custom {
  width: 20px;
  height: 20px;
  min-width: 20px;
  border: 2px solid var(--border-color);
  border-radius: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition-fast);
  margin-top: 2px;
}

.checkbox-custom svg {
  width: 12px;
  height: 12px;
  color: white;
  opacity: 0;
  transform: scale(0.5);
  transition: all var(--transition-fast);
}

.checkbox-wrapper input:checked + .checkbox-custom {
  background: var(--gradient-primary);
  border-color: var(--primary);
}

.checkbox-wrapper input:checked + .checkbox-custom svg {
  opacity: 1;
  transform: scale(1);
}

.checkbox-label {
  font-size: 0.875rem;
  color: var(--text-secondary);
  line-height: 1.5;
}

.checkbox-label a {
  color: var(--primary-light);
}

.checkbox-label a:hover {
  text-decoration: underline;
}

/* Form Alert */
.form-alert {
  padding: 12px 16px;
  border-radius: var(--radius-md);
  font-size: 0.875rem;
  display: none;
  align-items: center;
  gap: 10px;
}

.form-alert.visible {
  display: flex;
}

.form-alert.error {
  background: rgba(239, 68, 68, 0.1);
  border: 1px solid rgba(239, 68, 68, 0.3);
  color: #FCA5A5;
}

.form-alert.success {
  background: rgba(16, 185, 129, 0.1);
  border: 1px solid rgba(16, 185, 129, 0.3);
  color: #6EE7B7;
}

/* Submit Button */
.auth-form .btn-primary {
  width: 100%;
  padding: 16px;
  font-size: 1rem;
  margin-top: 8px;
}

/* Divider */
.auth-divider {
  display: flex;
  align-items: center;
  gap: 16px;
  margin: 24px 0;
}

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

.auth-divider span {
  font-size: 0.8125rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* Auth Footer */
.auth-footer {
  text-align: center;
  margin-top: 24px;
  padding-top: 24px;
  border-top: 1px solid var(--border-light);
}

.auth-footer p {
  font-size: 0.9375rem;
  color: var(--text-secondary);
}

.auth-footer a {
  color: var(--primary-light);
  font-weight: 500;
}

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

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

.back-link:hover {
  color: var(--primary-light);
}

.back-link svg {
  width: 16px;
  height: 16px;
}

/* Password Strength Indicator */
.password-strength {
  display: flex;
  gap: 4px;
  margin-top: 8px;
}

.strength-bar {
  flex: 1;
  height: 3px;
  background: var(--border-color);
  border-radius: 2px;
  transition: background var(--transition-fast);
}

.strength-bar.weak { background: var(--error); }
.strength-bar.medium { background: var(--warning); }
.strength-bar.strong { background: var(--success); }

.strength-text {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-top: 4px;
}

/* Responsive */
@media (max-width: 480px) {
  .auth-card {
    padding: 32px 24px;
  }
  
  .auth-header h1 {
    font-size: 1.5rem;
  }
}
