/*
 * Keep the Principal screen inside the Telegram viewport.  Earlier visual
 * rules gave the page-scroll element the height of its content; on short
 * Android screens that put the support actions below a non-scrollable shell.
 */
.app-shell.vp-home-active{
  height:100dvh!important;
  min-height:0!important;
  max-height:100dvh!important;
}

.app-shell.vp-home-active>.page-scroll{
  height:calc(100dvh - 70px - env(safe-area-inset-bottom))!important;
  min-height:0!important;
  max-height:calc(100dvh - 70px - env(safe-area-inset-bottom))!important;
  overflow-x:hidden!important;
  overflow-y:auto!important;
  overscroll-behavior-y:contain!important;
  -webkit-overflow-scrolling:touch;
  padding-bottom:calc(88px + env(safe-area-inset-bottom))!important;
}

/* Older Android WebViews do not support dvh. */
@supports not (height:100dvh){
  .app-shell.vp-home-active{height:100vh!important;max-height:100vh!important;}
  .app-shell.vp-home-active>.page-scroll{
    height:calc(100vh - 70px - env(safe-area-inset-bottom))!important;
    max-height:calc(100vh - 70px - env(safe-area-inset-bottom))!important;
  }
}

.app-shell.vp-home-active>.page-scroll>.home-screen.vp-emerald-live{
  min-height:0!important;
  height:auto!important;
  max-height:none!important;
}
