Also, knowing the scope, I wonder how to get the rules that apply to it.
You can always use the exact scope as the “rule”. Scopes work a bit like CSS selectors.
...
Oh, i didn't mean that. I meant finding the definition in the theme editor that applies to a certain rule/scope.