Example J - background-size: contain;
Click here for Example M - background-size: cover;