removed usage of "cardvector" and internally restructured storage of cards