Blocking the light from a window that spans up to the ceiling
If you want a complete solution for the whole window, or want to block the light just at the top, you can tape aluminum foil on the whole window or just at the top of the glass.  I did that once in a room that got so much sun that it was always too hot.  It took the temperature down about 10 degrees.