added sorting and countdown