67710548ec
On mobile the on-screen keyboard overlays the layout viewport instead of resizing it (iOS Safari always; Android Chrome under its default interactive-widget=resizes-visual). The dashboard shell is a fixed h-dvh column, so the xterm host's bounding box never changed when the keyboard opened: fit() computed identical (cols, rows), no RESIZE reached the PTY, and the Ink input line — drawn at the bottom of the grid — stayed hidden under the keyboard. Fix, in three parts: 1. Keyboard-inset handling (new web/src/lib/keyboard-inset.ts). computeKeyboardInset() measures the layout-viewport region obscured by the keyboard via window.visualViewport (innerHeight - vv.height - vv.offsetTop, with an 80px floor so collapsing URL-bar chrome doesn't thrash the grid). ChatPage applies it as bottom padding on the terminal wrapper, which shrinks the host → the existing ResizeObserver/fit path recomputes rows and sends RESIZE → Ink redraws the input line above the keyboard. Listens on both vv resize and scroll (offsetTop changes arrive as scroll events on iOS). 2. interactive-widget=resizes-content in the viewport meta. Android Chrome 108+ then resizes the layout viewport natively and the JS inset computes ~0 (harmless no-op); iOS ignores the directive and takes the JS path. 3. Scroll pinning. iOS auto-scrolls the page to reveal xterm's hidden textarea on focus, which drags the fixed shell offscreen. While a keyboard inset is active we pin window/scrollingElement scroll back to 0 and term.scrollToBottom() so the freshly-resized input line stays in view. Unit tests cover the inset math (thresholds, offsetTop, rotation races, fractional geometry, non-finite guards). Grid-level behavior needs a real device pass — DevTools emulation doesn't model keyboard insets.