Virtual keyboard scroll

Hi

I have put a simple chat system in my app.

For now, when the virtual keyboard triggers, it destroys my layout. The input field is fixed at the bottom, so it is covered by the keyboard, and the chat windows if above the display space.

Does anyone have a simple css scheme to make this setup more user friendly? What is the best pratice?

Thanks

In addition, I see different behaviors between iOS and Android. On Android it looks ok.

How do you guys manage this?