Sales of iPhones, the company’s best-selling product, were up 13.5% to $44.58 billion, beating analyst expectations of $40.22 billion.