Absolutely you can do 3 squares for under $40 per person per day. If you're staying at the Tesoro (formerly known as the Costa Real, formerly Plaza Las Glorias), you can take walk to Ninos Heroes (I think) where there's the Aramburo Plaza with a small grocery store, and you can stock up on breakfasty-(or luncheony, if you prefer) things. Or, take the local bus (looks like school bus) to the CCC or Soriana (think Super-Walmart-on-steroids) & stock up. The rooms are likely to have either a minifridge or a minibar, where you can put cold stuff.
From the Tesoro, go across the street to Marina Blvd, then, head W. At the corner of Ave CSL, there's a local sandwich shop (Tortas). As you head N on Ave CSL, you'll see some outdoor taquerias etc. which are good for lunch/dinner, and relatively inexpensive because they're away from the Marina. Or, walk NE on Marina Blvd all the way to the "Stop Light" You'll see a bunch of places offering breakfasts for under $5.
Lunch at Solomon's Landing on the Marina is one of our favorite places. Under $10 (3 fish tacos + lemonade, tax & tip).
For $25, you can get a good dinner at the Fish House. (Or, eat at an inexpensive taco stand for dinner, or maybe El Coral on Marina Blvd & get a dessert at the Sea Queen; on Ave CSL near Marina Blvd).
Take some time & walk inside town, at least 1-2 blocks away from Marina Blvd. You'll see lots of taco stands & similar low-key shops, much more reasonably priced than on the Marina.
If you pay cash & do multiple dives, many local dive shops will offer you a discount. (Put the discount back into the tip for the DM & boat captain).
If you're not locked into the Tesoro (unless they gave you a killer deal), you may get a better deal by staying away from the waterfront, but in town. Everything is pretty much walking distance (except the Costco & CCC/Soriana). Lodging drops by half by not being on the waterfront. (Of course, this advice may be too late).
Have a great trip! We want a trip report & photos when you get back!
edit added: Hey, if your friend wants to spring for my airfare, I'll go too & show you all the food!