Fatimah spent 1/4 of her money on 8 cookies and 2 muffins. A muffin cost three times as much as a cookie. She bought some more cookies with 2/7 of her remaining money. How many cookies did Fatimah buy altogether? ​