What exactly did you replace ? You cannot use OR in the group definition with values 0-100.
I didn’t follow your code but to rely on auto computed group state is an approach destined to fail for a number of reasons (value range being one of these, non-consistent behavior among devices being another one). You need to work on each member’s individual state instead.
Just FWIW, here’s a framework:
Granted it’s not elegant in terms of code, but as a matter of fact it is easier in the shutter use context to not use groups as there’s many “but what if” exceptions to apply to ever-differing groups of devices only.