How to automatically apply (and override this application) h1 color to h2+

hi, i’m looking for the way to automatically change color for headings going after their parent heading

What I’m trying to do

for example, i have this:

# <font color=FF0000>Anger</font>
## Issues
People who express anger might be het brood
## How to deal with
If you feel anger, you need het brood eten

i would want h2 to be automatically applied with color their parent heading has (as you can see, #00FF00 color). it would be even better if i could make it more complex: for example, h1 color applies its own color to the lesser headings (h2, h3, etc), and then h2 obviously will be a parent for the lesse headings still (h3, h4, etc). and i would also want to know how, if possible, could i override the parent heading color

Things I have tried

tried googling, tried searching it – i did not find anything. me myself can’t do this, i am just a beginner in this whole thing called Obsidian
would be even better if this can be done via .css file or smth like that, i guess. also, would be better if you could specify how can i do that only for specific files, not for each and every one