How to enqueu php files with custom variable & conditionals?

From the enqueue point of view it doesn’t matter if it points to genuine static CSS file or endpoint that dynamically generates it.

However there is a massive performance implication. Loading PHP engine (and worse — WordPress core on top) is much much more resource intensive than serving static file.

Your end goal shouldn’t be converting this, but getting rid of this altogether. If that is a standalone site (and not theme meant for redistribution) it should be pretty easy to generate desired modification once and serve them as static files from that point.