.container-img{height:100%;margin:15px auto;overflow:hidden;position:relative;width:100%}.container-img:before{content:" ";display:block;padding-top:100%;width:100%}.img-src{background-position:50%;background-repeat:no-repeat;background-size:contain;height:100%;left:0;position:absolute;top:0;width:100%}