How to bind a button to a percentage of the height of the background?
Guys, we encountered a problem when performing the following tasks:
This: is the background on the website (picture) in which to insert animated button in a particular place: a little above the middle of the screen in the picture background there is a special place rendered.
The problem is that the image scaling depending on the aspect ratio. For scaling of background we use the property "background-size: cover" which scales the image proportionally so that its width or height equal to height or width of the block. Accordingly, if the width does not fit parametry image, the picture is placed at the height and width is clipped. Similarly, in the case where the height does not fit, then only the height is clipped.
Sootvetstvenno place on the picture (background) jump a little higher, a little lower relative to the page. Because of this, the button on the right place to put it, maybe it's always different at different aspect ratio.