:root { color-scheme: light; font-family: Arial,sans-serif; } * { box-sizing: border-box; } html, body, #viewport { width: 100%; height: 100%; margin: 0; overflow: hidden; } #viewport { touch-action: none; user-select: none; cursor: grab; outline: none; background: #fff; } #viewport:active { cursor: grabbing; } #viewport > svg { display: block; width: 100%; height: 100%; overflow: hidden; } #state { position: fixed; left: 50%; top: 50%; transform: translate(-50%,-50%); color: #333; font-size: 14px; text-align: center; } #state:empty { display: none; }