US stocks have opened higher, driven up by gains in Apple that pointed to its recovery from a dip in sales as it rolls out AI features.