We tend to go B&B not HB or AI, because I don't like buffets for lunch or dinner, I prefer to eat somewhere where I can sit outside and be served local food.
What we do is get a big late breakfast and then have just one other proper meal out at a restaurant each day, whether this be at lunch or dinner (in Spain 'lunchtime' is generally around 2-4 pm anyway, which is when I find I am ready for it after by big breakfast at about 9-10 am).
At lunchtime, Menu del Dia is a good option as you can get 2 courses plus a drink for less than 10 euro pp. For the other meal each day, that will be either tapas in the evening after a big lunch, or a big icecream instead of lunch followed by a proper evening meal, or something like chips or a slice of pizza.
We also go to the supermarket to stock up on drinks, snacks, ice creams, along with bread, cheese, olives etc (a room with at least a fridge or preferably a kitchenette is preferable) much cheaper than buying ready made sandwiches, drinks or icecreams while out and about. I find this way to be slightly cheaper than all but the most bargain basement AI but the food and experience is nicer.
This way might not work if you are big eaters who like three large meals each day, don't generally bother with much for breakfast or absolutely hate foreign supermarkets (I quite like them) but it's what we've found works for us.
I've found that unless you pay a lot, the food quality in AI isn't that great, but in contrast, AI can be good if you've got fussy eaters who will pick up chips or whatever off a buffet, but are likely to turn their noses up at unfamiliar supermarket or restaurant food, or if you don't want the bother of a couple of supermarket trips or the minimal food prep etc.