The flex property allows available space to be distributed proportionaly. Eg flex:2; will take up twice as much space as flex:1; and all flex sized items will fill any available space.
flex