Sales at retailers rose in June as Americans bought more new cars and spent more online during Amazon’s annual summer sales event, signaling steady growth in the U.S. economy.