As for the ideal I mostly ripped the ideal from the ep itself more or less just altered the end result of the devises heres the ep of the cartoon Grossology that had such a similar concept
https://www.youtube.com/watch?v=PofJoL9KZTs note misremembered a minor detail from not seeing it for so long (I found out the misremembering fact from googling to find the ep )
As for sleep trouble I'm generally a insomniac