Mass dependence of light-nucleus production in ultrarelativistic heavy-ion collisions