.DS_Store files & empty folders

I'm exploring the possibilities for a scripted / automated way of deleting, not just individual empty folders, but nests of empty folders. I've been wrestling in my very noob way with Hazel, Automator, ScriptEditor and even shell scripts; and combinations of the above. Nothing seems to do it. The best I've managed this way is deleting the empty folder/s in the bottom layer of the "nest". But nothing will work on the empty parent / grandparent folders.
One idea I've picked up is that it could be to do with .DS_Store files in the folders, meaning the System doesn't recognise the files as empty. So first question: Is there a way to have Hazel delete those files?
Second more general question: Spotlight and Finder seem to me to lack any obvious way of scripting the removal of nested empty files. Is there something I'm missing with Hazel that might get me there?
One idea I've picked up is that it could be to do with .DS_Store files in the folders, meaning the System doesn't recognise the files as empty. So first question: Is there a way to have Hazel delete those files?
Second more general question: Spotlight and Finder seem to me to lack any obvious way of scripting the removal of nested empty files. Is there something I'm missing with Hazel that might get me there?