/* ═══════════════════════════════════════════════
   FileLift — Auth Pages (login / signup)
═══════════════════════════════════════════════ */

.auth-page {
  min-height: 100vh;
  background: var(--bg-dark);
  display: flex;
  flex-direction: column;
}

/* ── Auth Main ── */
.auth-main {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 100px 20px 60px;
}

.auth-card {
  background: #1E2D45;
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 20px;
  padding: 48px 44px;
  width: 100%;
  max-width: 460px;
  box-shadow: 0 24px 64px rgba(0,0,0,0.5);
}

.auth-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  margin-bottom: 32px;
  justify-content: center;
}

.auth-logo span {
  font-size: 1.4rem;
  font-weight: 800;
  color: var(--text-primary);
  letter-spacing: -0.5px;
}

.auth-title {
  font-size: 1.75rem;
  font-weight: 800;
  color: #F1F5F9;
  text-align: center;
  margin-bottom: 6px;
}

.auth-subtitle {
  font-size: 0.95rem;
  color: #94A3B8;
  text-align: center;
  margin-bottom: 28px;
}

/* ── Tab Switcher ── */
.auth-tabs {
  display: flex;
  background: #0F172A;
  border-radius: 10px;
  padding: 4px;
  margin-bottom: 28px;
  border: 1px solid rgba(255,255,255,0.12);
}

.auth-tab-btn {
  flex: 1;
  padding: 10px;
  border: none;
  background: transparent;
  color: var(--text-muted);
  font-family: inherit;
  font-size: 0.9rem;
  font-weight: 600;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s;
}

.auth-tab-btn.active {
  background: var(--accent);
  color: #fff;
}

/* ── Form Fields ── */
.auth-form .form-group {
  margin-bottom: 18px;
}

.auth-form label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  color: #CBD5E1;
  margin-bottom: 7px;
  letter-spacing: 0.01em;
}

.auth-form input {
  width: 100%;
  padding: 13px 16px;
  background: #0F172A;
  border: 1.5px solid rgba(255,255,255,0.18);
  border-radius: 10px;
  color: #F1F5F9;
  font-family: inherit;
  font-size: 0.95rem;
  transition: border-color 0.2s, box-shadow 0.2s;
  box-sizing: border-box;
}

.auth-form input:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(249,115,22,0.12);
}

.auth-form input.error {
  border-color: #EF4444;
}

.auth-form input::placeholder {
  color: var(--text-muted);
  opacity: 0.6;
}

/* Phone step 2 */
.phone-step2 {
  display: none;
}

.phone-step2.visible {
  display: block;
}

/* ── Remember Me ── */
.auth-remember {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 22px;
}

.auth-remember input[type="checkbox"] {
  width: 16px;
  height: 16px;
  accent-color: var(--accent);
  cursor: pointer;
}

.auth-remember label {
  font-size: 0.875rem;
  color: var(--text-muted);
  cursor: pointer;
  margin: 0;
}

/* ── Submit Button ── */
.auth-submit {
  width: 100%;
  padding: 14px;
  border: none;
  border-radius: 10px;
  background: var(--accent);
  color: #fff;
  font-family: inherit;
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.2s, transform 0.15s;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-bottom: 20px;
}

.auth-submit:hover {
  background: var(--accent-hover);
  transform: translateY(-1px);
}

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

/* ── Error / Info Messages ── */
.auth-error {
  background: rgba(239,68,68,0.1);
  border: 1px solid rgba(239,68,68,0.3);
  border-radius: 8px;
  padding: 11px 14px;
  color: #FCA5A5;
  font-size: 0.875rem;
  margin-bottom: 16px;
  display: none;
}

.auth-error.visible { display: block; }

.auth-info {
  background: rgba(249,115,22,0.08);
  border: 1px solid rgba(249,115,22,0.2);
  border-radius: 8px;
  padding: 11px 14px;
  color: var(--accent);
  font-size: 0.875rem;
  margin-bottom: 16px;
  display: none;
}

.auth-info.visible { display: block; }

/* ── Footer Link ── */
.auth-footer {
  text-align: center;
  font-size: 0.875rem;
  color: var(--text-muted);
}

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

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

/* ── Divider ── */
.auth-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 20px 0;
  color: var(--text-muted);
  font-size: 0.8rem;
}

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

/* ── Spinner ── */
.auth-spinner {
  width: 18px;
  height: 18px;
  border: 2px solid rgba(255,255,255,0.3);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
  display: none;
}

.auth-spinner.visible { display: block; }

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

/* ── Nav user menu ── */
.nav-user-menu {
  display: none;
  align-items: center;
  gap: 10px;
}

.nav-user-label {
  font-size: 0.85rem;
  color: var(--text-secondary);
  font-weight: 500;
  max-width: 160px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.btn-sm {
  padding: 7px 14px !important;
  font-size: 0.82rem !important;
}

/* ── Responsive ── */
@media (max-width: 520px) {
  .auth-card {
    padding: 32px 24px;
    border-radius: 16px;
  }
  .auth-title { font-size: 1.5rem; }
}
