/* ==========================================
   Rapid Route – Auth Pages (Login / Register)
   ========================================== */

.auth-body { min-height: 100vh; display: flex; align-items: stretch; }

.auth-wrapper {
  display: flex;
  min-height: 100vh;
  width: 100%;
  position: relative;
  z-index: 1;
}

/* --- Left Panel --- */
.auth-panel-left {
  flex: 1;
  display: flex;
  flex-direction: column;
  padding: 3rem;
  background: linear-gradient(135deg, rgba(108,99,255,0.12) 0%, rgba(10,10,26,0.5) 100%);
  border-right: 1px solid var(--border-glass);
  backdrop-filter: blur(10px);
  position: relative;
  overflow: hidden;
  min-height: 100vh;
}

.auth-panel-left::before {
  content: '';
  position: absolute;
  width: 600px; height: 600px;
  background: radial-gradient(circle, rgba(108,99,255,0.15), transparent 70%);
  top: -100px; left: -100px;
  pointer-events: none;
}

.auth-panel-left::after {
  content: '';
  position: absolute;
  width: 400px; height: 400px;
  background: radial-gradient(circle, rgba(255,107,107,0.08), transparent 70%);
  bottom: -50px; right: -100px;
  pointer-events: none;
}

.auth-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-main);
  font-size: 1.4rem;
  font-weight: 800;
  letter-spacing: -0.5px;
  margin-bottom: auto;
  position: relative;
  z-index: 1;
}

.auth-panel-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 4rem 0;
  position: relative;
  z-index: 1;
}

.auth-panel-content h1 {
  font-size: clamp(2rem, 3.5vw, 3rem);
  font-weight: 900;
  line-height: 1.15;
  letter-spacing: -1px;
  margin-bottom: 1rem;
}

.auth-panel-content p {
  font-family: var(--font-body);
  font-size: 1rem;
  color: var(--text-secondary);
  line-height: 1.7;
  margin-bottom: 2.5rem;
  max-width: 380px;
}

.auth-features { display: flex; flex-direction: column; gap: 1rem; }

.auth-feat {
  display: flex;
  align-items: center;
  gap: 1rem;
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text-primary);
}

.auth-feat-icon {
  width: 36px; height: 36px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.auth-panel-deco {
  position: relative;
  z-index: 1;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--text-muted);
  border-top: 1px solid var(--border-subtle);
  padding-top: 1.5rem;
}

/* --- Right Panel --- */
.auth-panel-right {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 3rem 2rem;
  background: rgba(10,10,26,0.4);
  backdrop-filter: blur(20px);
}

.auth-form-card {
  width: 100%;
  max-width: 460px;
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-xl);
  padding: 2.5rem;
  box-shadow: var(--shadow-card);
  animation: fadeInUp 0.6s ease both;
}

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

.auth-form-header h2 {
  font-size: 1.8rem;
  font-weight: 800;
  letter-spacing: -0.5px;
  margin-bottom: 0.4rem;
}

.auth-form-header p {
  font-family: var(--font-body);
  color: var(--text-secondary);
  font-size: 0.9rem;
}

/* Alert */
.auth-alert {
  padding: 0.85rem 1rem;
  border-radius: var(--radius-md);
  font-size: 0.9rem;
  font-weight: 500;
  margin-bottom: 1.5rem;
  border: 1px solid rgba(255,107,107,0.4);
  background: rgba(255,107,107,0.08);
  color: #FF8A8A;
}

.auth-alert.success {
  border-color: rgba(67,233,123,0.4);
  background: rgba(67,233,123,0.08);
  color: var(--green);
}

/* Form */
.auth-form { display: flex; flex-direction: column; gap: 1.2rem; margin-bottom: 1.5rem; }

.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }

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

.form-label {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text-secondary);
  letter-spacing: 0.3px;
}

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

.input-icon {
  position: absolute;
  left: 14px;
  color: var(--text-muted);
  pointer-events: none;
  flex-shrink: 0;
}

.form-input {
  width: 100%;
  background: rgba(255,255,255,0.05);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-md);
  padding: 0.75rem 1rem 0.75rem 2.8rem;
  color: var(--text-primary);
  font-family: var(--font-main);
  font-size: 0.95rem;
  font-weight: 500;
  outline: none;
  transition: var(--transition-fast);
}

.form-input::placeholder { color: var(--text-muted); font-weight: 400; }

.form-input:focus {
  border-color: rgba(108, 99, 255, 0.6);
  background: rgba(108, 99, 255, 0.05);
  box-shadow: 0 0 0 3px rgba(108, 99, 255, 0.12);
}

.form-input.error { border-color: rgba(255,107,107,0.6); }

.toggle-password {
  position: absolute;
  right: 12px;
  color: var(--text-muted);
  padding: 4px;
  border-radius: 6px;
  transition: var(--transition-fast);
}

.toggle-password:hover { color: var(--text-primary); background: rgba(255,255,255,0.06); }

.field-error {
  font-size: 0.8rem;
  color: #FF8A8A;
  font-weight: 500;
  padding-left: 2px;
  min-height: 0;
  display: block;
}

/* Password Strength */
.password-strength {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-top: 0.3rem;
}

.strength-bar {
  flex: 1;
  height: 4px;
  background: rgba(255,255,255,0.08);
  border-radius: 2px;
  overflow: hidden;
}

.strength-fill {
  height: 100%;
  width: 0%;
  border-radius: 2px;
  transition: var(--transition);
}

.strength-weak .strength-fill { width: 33%; background: var(--red); }
.strength-medium .strength-fill { width: 66%; background: var(--orange); }
.strength-strong .strength-fill { width: 100%; background: var(--green); }

#strengthLabel { font-size: 0.75rem; color: var(--text-muted); font-weight: 500; white-space: nowrap; }

/* Form Check */
.form-check {
  display: flex;
  align-items: flex-start;
  gap: 0.7rem;
  font-size: 0.85rem;
  color: var(--text-secondary);
  line-height: 1.5;
}

.form-check input[type="checkbox"] {
  width: 16px; height: 16px;
  flex-shrink: 0;
  margin-top: 2px;
  accent-color: var(--purple);
  cursor: pointer;
}

.link-inline { color: var(--purple-light); text-decoration: underline; text-decoration-color: rgba(108,99,255,0.4); }
.link-inline:hover { color: var(--purple); }

/* Submit Button */
.btn-auth {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  width: 100%;
  padding: 0.9rem;
  background: linear-gradient(135deg, var(--purple), var(--purple-dark));
  color: white;
  font-family: var(--font-main);
  font-size: 1rem;
  font-weight: 700;
  border-radius: var(--radius-md);
  border: 1px solid rgba(108,99,255,0.4);
  cursor: pointer;
  transition: var(--transition);
  box-shadow: 0 4px 20px rgba(108,99,255,0.35);
  margin-top: 0.5rem;
}

.btn-auth:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 28px rgba(108,99,255,0.5);
}

.btn-auth:active { transform: translateY(0); }

.btn-auth:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
}

.btn-auth-outline {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  padding: 0.85rem;
  background: transparent;
  color: var(--text-primary);
  font-family: var(--font-main);
  font-size: 0.95rem;
  font-weight: 600;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-glass);
  cursor: pointer;
  transition: var(--transition);
}

.btn-auth-outline:hover { background: var(--bg-glass); border-color: rgba(255,255,255,0.25); }

/* Divider */
.auth-divider {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin: 1.2rem 0;
  color: var(--text-muted);
  font-size: 0.85rem;
}

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

/* Guest Link */
.auth-guest-link {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  margin-top: 1rem;
  font-size: 0.88rem;
  color: var(--text-muted);
  font-weight: 500;
  transition: var(--transition-fast);
}

.auth-guest-link:hover { color: var(--purple-light); }

/* Responsive */
@media (max-width: 900px) {
  .auth-panel-left { display: none; }
  .auth-panel-right { flex: 1; padding: 2rem 1.5rem; min-height: 100vh; background: transparent; }
  .auth-form-card { background: rgba(255,255,255,0.05); }
}

@media (max-width: 480px) {
  .form-row { grid-template-columns: 1fr; }
  .auth-form-card { padding: 2rem 1.5rem; }
}
