Let's say I have a very large box with a magnet attached to the outside. Inside the box there is a perfect mirror on each side.
I open my box and quickly shoot in one photon before shutting it. After some time the photon reaches a side of the box and is reflected. From the momentum of the photon the box receives an impulse causing it to move however the box is gradually slowed down by the magnet attached to it which is inside a coil. This is also how the electricity is produced. The box has now been slowed to a halt and the photon is yet to reach the other side.
Once the photon does hit the other side of the now stationary box it'll create another impulse and hence the cycle repeats creating electricity forever. Brilliant!
So what idea have I overlooked that makes my design flawed and me silly?