functioning countdown with refresh