Pretty sure it's just the difference between "food", as in something meant to be eaten (food in general terms), and "dish" / "meal", can also be "cuisine".
If it's been cooked/prepared or is a type of cuisine, use りょうり. If it's just "food" more broadly, use たべもの.
It's not that complicated, but I've never had to explain it to anyone so I'm sorry if my explanation sucks :D
PS: Read the dictionary entry more carefully and you'll probably get it 料理
I think using meal or dish just muddles things. I think of it like this:
たべもの food, something to eat
りょうり cooking, cuisine
So if you are specifically asked about りょうり as opposed to たべもの, your partner wants to know what kind of food you like, rather than just a specific food.
りょうり means cooking but also cooked food. In most japanese definition, you can find a part similar to cooking/cuisine but also: また、そのたべもの Which basically just means "Or, that food" (which we just talk about). There is a lot of japanese word that works like that with that expression "また、その" So it can be used to talk about the process or the result. You can use it to talk about cooking (the action as in りょうりする), the different type cooking or a dish. In your question, it can be both (a type of cooking or a specific meal/dish) On the other hand, you can't use it to talk about raw food.