Updates the templates to properly use the layout, and redirect to review document after successfully logging in.