I have a div that has background:transparent, along with border. Underneath this div, I have more elements.
div
background:transparent
border
Curre
I think the event.stopPropagation(); should be mentioned here as well. Add this to the Click function of your button.
event.stopPropagation();
Prevents the event from bubbling up the DOM tree, preventing any parent handlers from being notified of the event.