I did a lot of calculating five years ago when we were planning a family trip, and I came up with a rule-of-thumb round figure of $100/person/day for everything other than room. I think rooms averaged out about the same (double occupancy), so I allocated about $800/day for four of us, in addition to air fare. It’d probably be more now. Barcelona wasn’t on the list; I don’t know how it compares with other European cities.
Of course, you can get by much more frugally, depending on how you handle meals, local transportation, etc. Where you stay is a big factor: luxury hotel vs. hostel, modest hotel room vs. couch surfing. So it would be hard for us to guess on your behalf.
Last summer as a graduation gift I gave my son a $5000 budget for a trip to Europe, all-inclusive, and I figured he’d be lucky to get 3 weeks out of it. He did some very careful shopping and planning on air fare from Boston, accommodations, intercity travel, etc., and managed to stretch it to four full weeks. Also, typically for him, he succeeded in spending just about every cent without going over budget.