Implement login functionality in the new architecture.