added card model and controller and random functionality