Electronic structure and magnetic properties of the spin-1/2 Heisenberg magnet Bi2CuO4