Photoabsorption cross sections of sodium clusters: electronic and geometrical effects