Many modern buildings are indeed wasteful, maybe they could use half the AC. But comparing to traditional buildings which were grand public spaces may be a bit misleading -- that mosque in Cairo may well occupy the space of 100 apartments, and provide cool shady space where the occupants of 10 of them can sit, and zero bedrooms.