Analysis of longitudinal data in the presence of informative observational times and a dependent terminal event with application to medical cost data