<!-- RUBY-BACKUP · part 47 -->
w.addEventListener('load', waitForRunLine);
    // Fallback: also start after a delay
    setTimeout(waitForRunLine, 2000);
  }

  try{ console.log('[hook-manager] watching for runLine'); }catch(e){}
})();


===== FILE: public/ruby-backup/index.html =====
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no">
<title>Ruby</title>
<style>
  /* ============ FOUNDATION ============ */
  html, body {
    margin: 0; padding: 0; height: 100%;
    overflow: hidden; background: #0b0906;
  }
  #view {
    position: fixed; inset: 0;
    width: 100%; height: 100%;
    display: block; touch-action: none;
  }
  #vign {
    position: fixed; inset: 0; pointer-events: none;
    background: radial-gradient(ellipse at center, transparent 55%, rgba(0,0,0,0.55) 100%);
  }
  #boot {
    position: fixed; inset: 0; z-index: 10;
    display: flex; align-items: center; justify-content: center;
    background: #0b0906; color: #ffd700;
    font: 15px/1.6 Georgia, serif; letter-spacing: 3px;
    padding: 0 24px; text-align: center;
  }

  /* ============ THE OS MENU — all buttons live here ============ */
  #os-menu {
    position: fixed; bottom: 90px; left: 50%;
    transform: translateX(-50%);
    z-index: 9999; display: none;
    flex-direction: row; flex-wrap: wrap;
    gap: 14px; justify-content: center; align-items: center;
    max-height: 50vh; overflow-y: auto;
    padding: 16px; max-width: 92vw;
    background: rgba(10,8,4,0.92);
    border-radius: 20px; border: 2px solid #8a6a1c;
  }
  #os-menu.open { display: flex; }
  #os-menu button {
    width: 56px; height: 56px;
    min-width: 56px; min-height: 56px; flex-shrink: 0;
    border-radius: 50%; margin: 0; padding: 0;
    cursor: pointer; -webkit-tap-highlight-color: transparent;
    font-size: 22px; line-height: 1;
  }
  #os-toggle {
    position: fixed; right: 14px; bottom: 14px;
    width: 56px; height: 56px; border-radius: 50%;
    background: rgba(20,14,6,0.72); border: 2px solid #d8a920;
    color: #ffd700; font-size: 24px; z-index: 10000;
    cursor: pointer; -webkit-tap-highlight-color: transparent; padding: 0;
  }

  /* ============ BUTTON FOUNDATION — gold on dark ============ */
  .rbtn {
    border-radius: 50%;
    background: rgba(20,14,6,0.72); border: 1px solid #d8a920;
    color: #ffd700; cursor: pointer;
    -webkit-tap-highlight-color: transparent; padding: 0;
  }
  .rbtn:active { background: #d8a920; color: #111; }
  .rbtn.on { background: #d8a920; border-color: #d8a920; color: #111; }
  .rbtn svg { width: 24px; height: 24px; display: block; margin: 0 auto; }

  /* ============ CODE BAR — the line to punch in ============ */
  #solidbar {
    position: fixed; top: 40px; left: 10px; right: 64px;
    z-index: 20; display: flex; gap: 6px;
  }
  #solidinput {
    flex: 1; height: 28px; border-radius: 14px;
    border: 1px solid #ffd700; background: rgba(0,0,0,0.6);
    color: #ffd700; padding: 0 10px; font-size: 12px;
  }
  #solidsend {
    height: 28px; padding: 0 12px; border-radius: 14px;
    border: 1px solid #ffd700; background: #ffd700;
    color: #000; font-weight: bold; font-size: 12px;
  }
  #codebtn {
    position: fixed; left: 14px; bottom: 14px;
    width: 46px; height: 46px; border-radius: 50%; z-index: 10;
    background: rgba(20,12,4,0.72); border: 1px solid rgba(255,215,0,0.55);
    color: #ffd700; font: 600 20px/46px Georgia, serif; text-align: center;
    cursor: pointer; padding: 0;
    box-shadow: 0 0 10px rgba(255,215,0,0.25), inset 0 0 8px rgba(255,215,0,0.12);
  }
  #codetext {
    position: fixed; top: 108px; left: 50%; transform: translateX(-50%);
    max-width: 88%; z-index: 8; text-align: center;
    opacity: 0; transition: opacity .4s, transform .9s; pointer-events: none;
  }
  #codetext.show { opacity: 1; }
  #codetext-code {
    color: #ffd700; font: 16px/1.5 ui-monospace, Menlo, monospace;
    text-shadow: 0 2px 8px #000; white-space: pre-wrap; word-break: break-word;
  }

  /* ============ WALK — the body ============ */
  #joy {
    position: fixed; left: 18px; bottom: 86px;
    width: 100px; height: 100px; border-radius: 50%;
    border: 2px solid #8a6a1c; background: rgba(20,14,6,0.4);
    z-index: 5; display: none; touch-action: none;
  }
  #joyknob {
    position: absolute; left: 50%; top: 50%;
    width: 44px; height: 44px; margin: -22px 0 0 -22px;
    border-radius: 50%;
    background: radial-gradient(circle at 30% 30%, #ffd700, #8a6a1c);
    box-shadow: 0 0 8px rgba(255,215,0,0.5);
  }

  /* ============ CHAT — the room ============ */
  #dock { position: fixed; left: 0; right: 0; bottom: 0; display: none; z-index: 9; }
  #dock.open { display: block; }
  #chatrow {
    display: none; background: transparent;
    border: 1px solid #8a6a1c; border-radius: 12px;
    overflow: hidden; margin: 0 auto 8px; max-width: 340px;
  }
  #chatrow.open { display: flex; }
  #chatinput {
  