I do not want to inherit the child opacity from the parent in CSS.
I have one div which is the parent, and I have another div inside the first div which is the child
Opacity is not actually inherited in CSS. It's a post-rendering group transform. In other words, if a What exactly you want to do here depends on the exact rendering you're looking for, which is not clear from the question.