Is there some trick that you can use with CSS to get %-sized elements scale towards their own center, rather than towards the corner?
Constraints:
- Element can be absolutely positioned anywhere on page and it should still work
- Element size is relative to the page width/height
Here's an image that will hopefully help illustrate the issue:
As far as I can tell there's no solution for this other than doing it with JavaScript.
Note that I'm only looking for pure HTML/CSS solutions without using any JS for this question (although if you know a JS library for this, please do leave a comment).