/* ═══════════════════════════════════════
   FACTUURAPP — auth.css
   ═══════════════════════════════════════ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --ink:         #16162a;
  --ink-soft:    #5a5a7a;
  --paper:       #f4f2ed;
  --accent:      #c9a96e;
  --accent-dark: #a07840;
  --border:      #ddd8cc;
  --green:       #3d7a52;
  --danger:      #c0392b;
  --font-body:   'DM Sans', system-ui, sans-serif;
  --font-display:'DM Serif Display', Georgia, serif;
  --font-mono:   'DM Mono', monospace;
}

html, body { height: 100%; font-family: var(--font-body); color: var(--ink);
  background: var(--ink); -webkit-font-smoothing: antialiased; }

.auth-page { min-height: 100vh; display: grid; grid-template-columns: 1fr 1fr; }

/* LEFT BRAND PANEL */
.auth-brand { background: var(--ink);
  background-image: radial-gradient(ellipse at 30% 40%, rgba(201,169,110,.2) 0%, transparent 60%);
  display: flex; flex-direction: column; align-items: flex-start; justify-content: center;
  padding: 4rem; gap: 2rem; }
.auth-brand-logo { display: flex; align-items: center; gap: .75rem; }
.auth-brand-logo span { font-family: var(--font-display); font-size: 1.5rem; color: white; }
.auth-brand-tagline { font-family: var(--font-display); font-size: clamp(1.8rem,3vw,2.4rem);
  color: white; line-height: 1.2; }
.auth-brand-tagline em { color: var(--accent); font-style: italic; }
.auth-brand-perks { list-style: none; display: flex; flex-direction: column; gap: .6rem; }
.auth-brand-perks li { font-size: .9rem; color: rgba(255,255,255,.6);
  display: flex; align-items: center; gap: .6rem; }
.auth-brand-perks li::before { content: '✓'; color: var(--accent); font-weight: 700; }
.auth-brand-price { background: rgba(201,169,110,.12); border: 1px solid rgba(201,169,110,.3);
  border-radius: 10px; padding: 1.25rem 1.5rem; }
.auth-brand-price strong { display: block; font-family: var(--font-display); font-size: 1.8rem;
  color: var(--accent); }
.auth-brand-price span { font-size: .82rem; color: rgba(255,255,255,.45);
  font-family: var(--font-mono); }

/* RIGHT FORM PANEL */
.auth-form-panel { background: var(--paper); display: flex; align-items: center;
  justify-content: center; padding: 3rem 2rem; }
.auth-form-box { width: 100%; max-width: 420px; }
.auth-form-box h1 { font-family: var(--font-display); font-size: 1.9rem;
  color: var(--ink); margin-bottom: .4rem; }
.auth-form-box .auth-sub { font-size: .9rem; color: var(--ink-soft); margin-bottom: 2rem; }
.auth-form-box .auth-sub a { color: var(--accent-dark); text-decoration: none; font-weight: 500; }

/* FORM FIELDS */
.field { display: flex; flex-direction: column; gap: .3rem; margin-bottom: 1rem; }
label { font-family: var(--font-mono); font-size: .68rem; font-weight: 400;
  color: var(--ink-soft); letter-spacing: .07em; text-transform: uppercase; }
input[type="email"], input[type="password"], input[type="text"] {
  font-family: var(--font-body); font-size: .92rem; color: var(--ink);
  background: white; border: 1.5px solid var(--border); border-radius: 6px;
  padding: .62rem .8rem; outline: none; width: 100%;
  transition: border-color .18s, box-shadow .18s; }
input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(201,169,110,.18); }

.btn-submit { width: 100%; background: var(--ink); color: white; font-family: var(--font-body);
  font-size: .95rem; font-weight: 600; padding: .8rem; border: none; border-radius: 8px;
  cursor: pointer; margin-top: .5rem; transition: background .18s, transform .15s; }
.btn-submit:hover { background: #252545; transform: translateY(-1px); }
.btn-submit:disabled { opacity: .6; cursor: not-allowed; transform: none; }

.divider { display: flex; align-items: center; gap: .75rem; margin: 1.25rem 0;
  color: var(--ink-soft); font-size: .8rem; }
.divider::before, .divider::after { content: ''; flex: 1; height: 1px; background: var(--border); }

/* ALERTS */
.alert { padding: .75rem 1rem; border-radius: 6px; font-size: .85rem;
  margin-bottom: 1rem; display: none; }
.alert.show { display: block; }
.alert-error   { background: #fdf0ef; border: 1px solid #f5c6c2; color: var(--danger); }
.alert-success { background: #edf5f0; border: 1px solid var(--green); color: var(--green); }
.alert-info    { background: #f0f4ff; border: 1px solid #b8c8f0; color: #3050a0; }

/* LOADING SPINNER */
.spinner { display: inline-block; width: 16px; height: 16px; border: 2px solid rgba(255,255,255,.3);
  border-top-color: white; border-radius: 50%; animation: spin .6s linear infinite;
  vertical-align: middle; margin-right: .4rem; }
@keyframes spin { to { transform: rotate(360deg); } }

/* BACK LINK */
.back-link { display: inline-flex; align-items: center; gap: .4rem; font-size: .82rem;
  color: var(--ink-soft); text-decoration: none; margin-bottom: 2rem; transition: color .18s; }
.back-link:hover { color: var(--ink); }

/* RESPONSIVE */
@media (max-width: 768px) {
  .auth-page { grid-template-columns: 1fr; }
  .auth-brand { display: none; }
  .auth-form-panel { background: var(--ink); }
  .auth-form-box { background: var(--paper); padding: 2.5rem 2rem; border-radius: 16px; }
}
