Refactored to sort cards at initialisation