The constants and variables in CSS are really starting to be missed. Writing a CSS CSS generator in PHP is somehow broken. Can invent some CSS Interpreter, which will take a certain document (* .csx), already similar in syntax to CSS, with only some additional instructions - and interpret these instructions, issuing the output CSS.
By the way, this would be a logical development of static CSS files, as PHP became the development of the idea of HTML in static files.
It's funny you can get out with the help of XML / XSL, but with the editor there is a problem, an editor or a profile for something separately will have to be rolled.