finished authentication and formatting for login and pages