I'm facing a problem that I can't seem to solve. I have a div with a background image.
<div class="a"></div>
I want to make a specific point of this background image clickable. I know I can achieve this by adding a div with a z-index, making it clickable, and positioning it using position:absolute, like this:
<div class="b">
<a class="clickablePoint" href="#"></a>
</div>
However, how can I ensure that this clickable point stays in the same position when I resize the window, especially if my background image needs to be responsive with background-size:100% auto?
Is there a way to calculate the height of the background image in real-time when resizing the window? Or perhaps another method I should consider? :(