Ah - what you’re seeing here is that theme.css
is special in that the %color:Primary%
syntax is being replaced from your theme colors. (This would be a good feature request - make all css files support anvil’s theme color syntax)
If I were doing this I might use css vars
My theme.css would probably be a bunch of vars like
:root {
--primary: %color:Primary%; /* Or just the raw value */
}
And then inside theme_md3.css
I would replace the use of %color:Primary%
with
var(--primary)