Can I use Craft CMS for a large custom web application? I know the easy answer is "yes", but let me elaborate: 

Say I want to create a community for grocery shoppers. I let bloggers and other influencers design their own menus that define which ingredients end up in the users' shopping carts. 

The users pick the menus that interest them, and based on factors like number of people in the family etc, the right quantity of ingredients are added to the cart. When the user is ready, she clicks purchase, and an order is sent to the nearest (or selected) grocery store. 

I have developed sytems of similar complexity earlier in my career, but then by using my own CMS system- which of course let me do whatever I wanted. 

My question is - would Craft CMS be suitable for this kind of task? Is it in fact more than a website CMS? Is it really scalable?
Craft isn't opinionated on how your site works; it just organizes and outputs your content however you want it to. You have 100% control over your HTML whether you want to use templates or dish out the data for some framework like React, Vue, etc (using the Element API plugin). So that should answer your question: yes it is more than just a website CMS because it simply manages your content, not the means you choose to collect and output that content like a website, app, etc.

However, Craft out of the box obviously isn't customized to all the extra functionality you described above, so you're going to need to write your own custom module in PHP to do these things. You can use Pluginfactory to start your scaffolding.

Off the top of my head, based on what you said, it sounds like you'll eventually need to buy Craft Commerce. Your users will create an account in Craft. The bloggers/influencers will need their own user group, and they will submit a form that will create an entry in a channel called "Menus". Your general users will be in their own user group and can choose among those Menus entries. You get an unlimited number of channels, categories, purchasables, etc, and they can all be related to each other within an entry, product, etc, so go nuts and keep everything modular for reuse. Your custom plugin/module will need to handle figuring out the number of ingredients and any other customization.

That's all just my interpretation of what you wrote, so obviously you'll want to look into this stuff yourself. But I don't think you have to go reading up extensively on a bunch of stuff before finally deciding to start. You can download Craft Commerce for free (you don't have to pay for a license until you push it up to your server), and you can always start exploring custom plugin/module development. Getting your hands dirty with the code is the way to answer your question, but if you're worried about investing your time in all this just to find out that Craft prohibits you from realizing your idea, I can assure you that's not the case, and you're not going to have to make it happen by having to hack around the system like some lame Wordpress site. Craft is made to be incredibly flexible for anything that needs content managed, and that includes your idea.