I want a div to be below its sibling, if the browser window is big enough or
to be at the bottom. The div1 doesn’t have a static height of course.
This image is how I want to position div2 if the browser window is big

The following is how I want div2 to be positioned if the browser window is small.

You’re describing a “sticky footer“.