Lattice-polarization effects on electron-gas charge densities in ionic superlattices