A bakery sells cookies and muffins. Altogether, they sell 45 items in a day. If they had sold 15 more cookies, the number of cookies sold would be three times the number of muffins sold. How many cookies did the bakery sell? Let's think step by step and output the final answer within \boxed{}.
user