I've done a fair bit of searching, but not come across any recent, useful answers.
My question is whether it's possible to pass variables from HTML (possibly using data attributes) into CSS?
My use case is that I have brand pages that I'd like to use a media query to show vendor-specific backgrounds for each brand using media queries. I know you can't use media queries in inline CSS, but I equally don't want to create ~100 media queries in my style sheet.
On my HTML page, I can access an object for the vendor background URL, so it would be great if I could pass these into a single CSS media query somehow without doing any JavaScript.