/* ═══════════════════════════════════════════════════════════
   Projetare — Auth Pages (Login / Register)
   ═══════════════════════════════════════════════════════════ */

* { margin: 0; padding: 0; box-sizing: border-box; }

:root {
  --bg-primary: #0A0F1A;
  --bg-card: #111827;
  --bg-input: #0D1520;
  --accent: #FF6B2B;
  --accent-hover: #E55A1A;
  --accent-gradient: linear-gradient(135deg, #FF6B2B, #E55A1A);
  --border: #1E2D42;
  --text-primary: #FFFFFF;
  --text-secondary: #8899AA;
  --text-muted: #556677;
  --red: #E74C3C;
  --font: 'Syne', sans-serif;
  --font-mono: 'Space Mono', monospace;
  --radius: 16px;
  --radius-md: 10px;
  --ease: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

body {
  font-family: var(--font);
  background: var(--bg-primary);
  color: var(--text-primary);
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

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

.auth-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 40px 32px;
}

.auth-logo {
  text-align: center;
  margin-bottom: 32px;
}

.auth-logo svg {
  margin-bottom: 12px;
}

.auth-logo h1 {
  font-size: 28px;
  font-weight: 700;
  letter-spacing: -0.5px;
}

.auth-subtitle {
  color: var(--text-muted);
  font-size: 13px;
  font-family: var(--font-mono);
  margin-top: 4px;
}

.auth-form {
  display: none;
}

.auth-form.active {
  display: block;
}

.auth-form h2 {
  font-size: 20px;
  font-weight: 600;
  margin-bottom: 8px;
}

.trial-info {
  color: var(--accent);
  font-size: 13px;
  font-family: var(--font-mono);
  margin-bottom: 20px;
}

.form-group {
  margin-bottom: 16px;
}

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

.form-group input {
  width: 100%;
  padding: 12px 14px;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  font-family: var(--font);
  font-size: 14px;
  transition: border-color var(--ease);
}

.form-group input:focus {
  outline: none;
  border-color: var(--accent);
}

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

/* ── Password field with eye toggle ── */
.input-password {
  position: relative;
  display: flex;
  align-items: center;
}

.input-password input {
  flex: 1;
  padding-right: 48px;
}

.btn-eye {
  position: absolute;
  right: 12px;
  top: 0;
  bottom: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: none;
  border: none;
  outline: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 0;
  margin: 0;
  width: 28px;
  -webkit-appearance: none;
  appearance: none;
  transition: color var(--ease);
}

.btn-eye:hover {
  color: var(--accent);
}

.btn-eye svg {
  pointer-events: none;
}

.auth-erro {
  color: var(--red);
  font-size: 13px;
  min-height: 20px;
  margin-bottom: 8px;
}

.btn-auth {
  width: 100%;
  padding: 14px;
  background: var(--accent-gradient);
  color: white;
  border: none;
  border-radius: var(--radius-md);
  font-family: var(--font);
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: opacity var(--ease), transform var(--ease);
}

.btn-auth:hover {
  opacity: 0.9;
  transform: translateY(-1px);
}

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

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

.auth-switch {
  text-align: center;
  margin-top: 20px;
  font-size: 13px;
  color: var(--text-secondary);
}

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

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

/* Loading spinner on button */
.btn-auth.loading {
  pointer-events: none;
  opacity: 0.7;
}

.btn-auth.loading::after {
  content: '';
  display: inline-block;
  width: 16px;
  height: 16px;
  border: 2px solid rgba(255,255,255,0.3);
  border-top-color: white;
  border-radius: 50%;
  margin-left: 8px;
  animation: spin 0.6s linear infinite;
  vertical-align: middle;
}

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