Bug fix: handle when time remaining is 0