html, body {
    margin: 0;
    padding: 0;
    background: #000;
    overflow: hidden;
    height: 100%;
    font-family: monospace;
    color: #fff;
  }
  .stage {
    position: fixed;
    inset: 0;
    display: grid;
    place-items: center;
  }
  .wrapper {
    position: relative;
    max-width: 100vw;
    max-height: 100vh;
  }
  /* Mirror both video and canvas so left feels left */
  video, canvas {
    display: block;
    max-width: 100vw;
    max-height: 100vh;
    transform: scaleX(-1);
  }
  canvas {
    position: absolute;
    inset: 0;
    pointer-events: none;
  }
  #status {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 14px;
    opacity: 0.8;
  }
  /* Related links, kept small so the webcam stays the focus */
  .links {
    position: fixed;
    top: 12px;
    right: 12px;
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 8px;
    z-index: 10;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    font-size: 13px;
  }
  .links a {
    color: #fff;
    text-decoration: none;
    background: rgba(0, 0, 0, 0.55);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 6px;
    padding: 6px 10px;
  }
  .links a:hover { background: rgba(255, 60, 60, 0.35); }
  .links a:first-child { border-color: rgba(255, 80, 80, 0.7); }
