Fix card hierarchy