Made the modal dialog responsive and cleanups