Fix card total calculation