@font-face { font-family: "JB"; src: url("/fonts/jb-400.woff2") format("woff2"); font-weight: 400; font-display: block; }
@font-face { font-family: "JB"; src: url("/fonts/jb-700.woff2") format("woff2"); font-weight: 700; font-display: block; }
:root { --bg: #1a1b26; --fg: #c0caf5; --accent: #7aa2f7; color-scheme: dark; }
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; background: var(--bg); overflow: hidden; }
body { display: flex; flex-direction: column; height: 100dvh; transition: background-color .3s; }
#screen { flex: 1; min-height: 0; padding: 6px 8px; }
#screen .xterm { height: 100%; }
#screen .xterm-viewport { background: transparent !important; overflow: hidden !important; }
#status {
  position: fixed; inset: 0; display: grid; place-items: center; z-index: 5;
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  color: var(--fg); font: 15px/1.5 "JB", ui-monospace, monospace; text-align: center; padding: 24px;
}
#status[hidden] { display: none; }
#status b { color: var(--accent); }
#status a { color: var(--accent); }
#keys { display: none; gap: 4px; padding: 6px 6px calc(6px + env(safe-area-inset-bottom)); overflow-x: auto;
  background: color-mix(in srgb, var(--bg) 80%, #000); border-top: 1px solid color-mix(in srgb, var(--fg) 18%, transparent); }
#keys button {
  flex: 0 0 auto; min-width: 44px; min-height: 40px; padding: 0 10px; border-radius: 6px;
  border: 1px solid color-mix(in srgb, var(--fg) 25%, transparent);
  background: color-mix(in srgb, var(--bg) 70%, var(--fg) 8%); color: var(--fg);
  font: 600 14px "JB", ui-monospace, monospace; touch-action: manipulation; -webkit-tap-highlight-color: transparent; user-select: none;
}
#keys button:active { background: var(--accent); color: var(--bg); }
#keys button:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; }
@media (pointer: coarse) { #keys { display: flex; } #screen { padding: 2px 2px; } }
@media (prefers-reduced-motion: reduce) { body { transition: none; } }
