When the cap is sealed, the bird and the bottle form a sealed system. As long as the bird is not accelerating up or down (ie sitting on the floor or flying level) the center of mass of the system is moving with a constant vertical velocity. Then the net force on system is zero - the upwards force on the bottom of the bottle from the scale (which is the weight that the scale actually measures) must exactly cancel out the weight of gravity.
On the otherhand, if the bird is accelerating downwards, then so is the center of mass. The net force on the system must be a small downwards force - so the upwards force from the scale is slightly less than the gravity force on the system. Thus the scale reads a smaller weight than the weight of the sitting bird in the bottle. Similarly, if the bird is accelerating upwards, the net force is also upwards - the scale reads a higher weight than the sitting bird.
Physically, what is happening is that when the bird is flying steadily, it is pushing air downwards with its wings to keep it up in the air. This causes a wind to flow downwards which impacts the bottom of the bottle, pushing it down. This downwards flow of air also creates a slight vacuum above the wings, which creates a small force downwards on the ceiling of the bottle.
The downwards force from the air on the bottle pushes down with exactly the weight of the bird (if the bird is not accelerating), making the scale push upwards with an extra force.
When the cap is opened, the system stops being closed and the parts really do need to be considered sperarately, but we can get an idea about what happens by thinking about it a little:
- 1)If the bird is "in" the open bottle but very, very, far above the tops of the walls of the bottle, only a small amount of its down draft will be felt by the bottle - making the bottle approximately its empty weight.
2) If the bird is sitting on the floor of the bottle, the bottle feels its whole weight.
3) If the bird is flying in the bottle, then although all of its downdraft should hit the floor of the bottle, the small downwards force on the ceiling created by the slight vacuum made by the wings is absent, making the bottle lighter than the closed bottle.