Refactoring time calculations to use IsPast property