:root {
  --font-primary: "Geist", "Inter", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

/* ── RESET ─────────────────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html, body { height: 100%; }
body {
  font-family: var(--font-primary);
  -webkit-font-smoothing: antialiased;
  color: #0a0a0a;
  background-color: #eef2ff;
  /* Diagonal grid lines */
  background-image:
    linear-gradient(45deg,  rgba(99,102,241,.07) 1px, transparent 1px),
    linear-gradient(-45deg, rgba(99,102,241,.07) 1px, transparent 1px);
  background-size: 90px 90px;
}
a { text-decoration: none; color: inherit; }

/* ── LAYOUT ────────────────────────────────────────────────────────────────── */
.login-layout {
  display: flex;
  min-height: 100vh;
  align-items: center;
  justify-content: center;
  gap: 80px;
  padding: 40px 48px;
}

/* ── LEFT ──────────────────────────────────────────────────────────────────── */
.login-left {
  flex: 1;
  max-width: 420px;
}
.login-brand {
  display: inline-block;
  margin-bottom: 32px;
}
.login-logo {
  height: 36px;
  width: auto;
  display: block;
}
.login-tagline {
  font-size: 32px;
  font-weight: 700;
  color: #0a0a0a;
  letter-spacing: -.02em;
  line-height: 1.2;
}

/* ── RIGHT ─────────────────────────────────────────────────────────────────── */
.login-right {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
}

/* ── CARD ──────────────────────────────────────────────────────────────────── */
.login-card {
  background: #fff;
  border-radius: 16px;
  padding: 36px 40px;
  width: 420px;
  box-shadow: 0 4px 6px rgba(0,0,0,.04), 0 12px 40px rgba(0,0,0,.08);
}
.login-card__title {
  font-size: 22px;
  font-weight: 700;
  color: #0a0a0a;
  letter-spacing: -.02em;
  margin-bottom: 24px;
}

/* ── FIELDS ────────────────────────────────────────────────────────────────── */
.login-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 16px;
}
.login-label {
  font-size: 13px;
  font-weight: 500;
  color: #374151;
}
.login-input {
  width: 100%;
  padding: 11px 14px;
  font-family: var(--font-primary);
  font-size: 14px;
  color: #0a0a0a;
  background: #f3f4f8;
  border: 1.5px solid transparent;
  border-radius: 8px;
  outline: none;
  transition: border-color 0.18s ease, background 0.18s ease;
}
.login-input::placeholder { color: #9ca3af; }
.login-input:focus {
  border-color: #6366f1;
  background: #fff;
}
.login-input.is-error { border-color: #ef4444; background: #fff; }

/* ── ERROR ─────────────────────────────────────────────────────────────────── */
.login-error {
  font-size: 13px;
  color: #ef4444;
  margin-bottom: 12px;
}
.login-error[hidden] { display: none; }

/* ── PRIMARY BUTTON ────────────────────────────────────────────────────────── */
.login-btn-primary {
  width: 100%;
  padding: 14px;
  background: #0f0f2d;
  color: #fff;
  border: none;
  border-radius: 8px;
  font-family: var(--font-primary);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.18s ease;
  margin-bottom: 14px;
}
.login-btn-primary:hover { background: #1a1a40; }
.login-btn-primary:disabled { background: #d1d5db; cursor: not-allowed; }

/* ── FORGOT ────────────────────────────────────────────────────────────────── */
.login-forgot {
  font-size: 13px;
  color: #6b7280;
  margin-bottom: 20px;
}
.login-forgot a {
  color: #0a0a0a;
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 2px;
}

/* ── DIVIDER ───────────────────────────────────────────────────────────────── */
.login-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
  font-size: 13px;
  color: #9ca3af;
}
.login-divider::before,
.login-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: #e5e7eb;
}

/* ── OAUTH BUTTONS ─────────────────────────────────────────────────────────── */
.login-oauth-btn {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 11px 14px;
  background: #fff;
  border: 1.5px solid #e5e7eb;
  border-radius: 8px;
  font-family: var(--font-primary);
  font-size: 14px;
  font-weight: 500;
  color: #0a0a0a;
  cursor: pointer;
  margin-bottom: 10px;
  transition: border-color 0.18s ease, background 0.18s ease;
}
.login-oauth-btn:hover {
  border-color: #9ca3af;
  background: #fafafa;
}
.login-oauth-btn:last-of-type { margin-bottom: 20px; }

/* ── SIGN UP ───────────────────────────────────────────────────────────────── */
.login-signup {
  font-size: 13px;
  color: #6b7280;
  text-align: center;
}
.login-signup a {
  color: #0a0a0a;
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 2px;
}

/* ── LEGAL ─────────────────────────────────────────────────────────────────── */
.login-legal {
  font-size: 12px;
  color: #9ca3af;
  text-align: center;
  max-width: 380px;
  line-height: 1.6;
}
.login-legal a {
  color: #6b7280;
  text-decoration: underline;
  text-underline-offset: 2px;
}

/* ── RESPONSIVE ────────────────────────────────────────────────────────────── */
@media (max-width: 820px) {
  .login-layout {
    flex-direction: column;
    gap: 32px;
    padding: 40px 24px;
    align-items: stretch;
  }
  .login-left { max-width: none; text-align: center; }
  .login-brand { margin: 0 auto 20px; }
  .login-tagline { font-size: 24px; }
  .login-card { width: 100%; max-width: 440px; margin: 0 auto; padding: 28px 24px; }
  .login-right { align-items: stretch; }
  .login-legal { margin: 0 auto; }
}
