*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }

:root {
  --bg: #fafaf9;
  --ink: #111110;
  --muted: #78716c;
  --border: #e5e3df;
  --accent: #111110;
  --accent2: #a07850;
  --surface: #ffffff;
  --serif: 'Cormorant Garamond', Georgia, serif;
  --sans: 'Inter', sans-serif;
}

body {
  font-family: var(--sans);
  background: var(--bg);
  color: var(--ink);
  height: 100vh;
  overflow: hidden;
}

.auth-split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  height: 100vh;
}

/* LEFT */
.auth-left {
  background: var(--ink);
  color: white;
  padding: 3rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.auth-brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.brand-mark {
  width: 40px;
  height: 40px;
  background: var(--accent2);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  font-size: 0.85rem;
  color: white;
  letter-spacing: 0.05em;
}

.auth-brand span {
  font-size: 1rem;
  font-weight: 500;
  letter-spacing: 0.03em;
}

.auth-hero h1 {
  font-family: var(--serif);
  font-size: clamp(2.2rem, 3.5vw, 3.2rem);
  line-height: 1.15;
  margin-bottom: 1rem;
  font-weight: 400;
}

.auth-hero h1 em { color: var(--accent2); font-style: italic; }

.auth-hero p {
  font-size: 0.9rem;
  color: rgba(255,255,255,0.55);
  max-width: 36ch;
  line-height: 1.7;
  font-weight: 300;
}

.auth-features {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}

.feat {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  font-size: 0.85rem;
  color: rgba(255,255,255,0.65);
}

.feat-icon { font-size: 1rem; }

/* RIGHT */
.auth-right {
  background: var(--surface);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  overflow-y: auto;
}

.auth-box { width: 100%; max-width: 400px; }

.auth-tabs {
  display: flex;
  gap: 0;
  background: var(--bg);
  border-radius: 10px;
  padding: 4px;
  margin-bottom: 2rem;
  border: 1px solid var(--border);
}

.tab {
  flex: 1;
  padding: 0.6rem;
  border: none;
  background: transparent;
  border-radius: 8px;
  font-family: var(--sans);
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--muted);
  cursor: pointer;
  transition: all 0.2s;
}

.tab.active {
  background: white;
  color: var(--ink);
  box-shadow: 0 1px 4px rgba(0,0,0,0.08);
}

.auth-form h2 {
  font-family: var(--serif);
  font-size: 1.7rem;
  font-weight: 600;
  margin-bottom: 0.3rem;
}

.form-sub { font-size: 0.85rem; color: var(--muted); margin-bottom: 1.75rem; }

.field { display: flex; flex-direction: column; gap: 0.4rem; margin-bottom: 1rem; position: relative; }

.field label { font-size: 0.8rem; font-weight: 500; color: var(--ink); }

.field input {
  padding: 0.7rem 0.9rem;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-family: var(--sans);
  font-size: 0.9rem;
  color: var(--ink);
  background: var(--bg);
  outline: none;
  transition: border-color 0.2s;
}

.field input:focus { border-color: var(--ink); background: white; }

.forgot {
  font-size: 0.75rem;
  color: var(--muted);
  text-decoration: none;
  text-align: right;
  margin-top: 0.25rem;
}

.forgot:hover { color: var(--accent2); }

.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 0.75rem; }

.error-msg {
  font-size: 0.8rem;
  color: #dc2626;
  min-height: 1.2rem;
  margin-bottom: 0.5rem;
}

.btn-auth {
  width: 100%;
  padding: 0.85rem;
  background: var(--ink);
  color: white;
  border: none;
  border-radius: 8px;
  font-family: var(--sans);
  font-size: 0.9rem;
  font-weight: 500;
  cursor: pointer;
  transition: opacity 0.2s, transform 0.2s;
  margin-bottom: 1.25rem;
}

.btn-auth:hover { opacity: 0.85; transform: translateY(-1px); }

.divider {
  text-align: center;
  position: relative;
  margin-bottom: 1.25rem;
}

.divider::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 0;
  right: 0;
  height: 1px;
  background: var(--border);
}

.divider span {
  position: relative;
  background: white;
  padding: 0 0.75rem;
  font-size: 0.75rem;
  color: var(--muted);
}

.social-auth { display: grid; grid-template-columns: 1fr 1fr; gap: 0.75rem; }

.btn-social {
  padding: 0.7rem;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: white;
  font-family: var(--sans);
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--ink);
  cursor: pointer;
  transition: background 0.2s, border-color 0.2s;
}

.btn-social:hover { background: var(--bg); border-color: var(--ink); }

.terms {
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  font-size: 0.78rem;
  color: var(--muted);
  margin-bottom: 1rem;
  line-height: 1.5;
}

.terms input { margin-top: 3px; accent-color: var(--ink); }

.terms a { color: var(--accent2); text-decoration: none; }

.hidden { display: none; }

@media (max-width: 768px) {
  body { overflow: auto; }
  .auth-split { grid-template-columns: 1fr; height: auto; }
  .auth-left { padding: 2rem; min-height: 40vh; }
  .auth-right { padding: 2rem 1.5rem; }
}