/* ---- Live Grid ---- */
    .live-grid {
      flex: 1;
      display: grid;
      gap: 2px;
      padding: 2px;
      overflow: auto;
      min-height: 0;
      align-content: stretch;
    }

    .stream-cell {
      position: relative;
      background: #000;
      display: flex;
      align-items: center;
      justify-content: center;
      overflow: hidden;
      border: 1px solid transparent;
      transition: border-color 0.2s;
    }

    .stream-cell.active-border {
      border-color: var(--accent);
    }

    .stream-cell img {
      width: 100%;
      height: 100%;
      object-fit: contain;
    }

    .stream-overlay {
      position: absolute;
      top: 8px;
      left: 10px;
      font-size: 12px;
      color: #ccc;
      text-shadow: 0 1px 3px rgba(0, 0, 0, 0.8);
      pointer-events: none;
      z-index: 2;
    }

    .playback-tile-btn {
      height: 24px;
      min-width: 40px;
      font-size: 11px;
      border: 1px solid var(--accent);
      color: var(--accent);
      background: rgba(0, 184, 148, 0.15);
      border-radius: 4px;
      cursor: pointer;
      padding: 0 8px;
    }

    .playback-tile-btn.stop {
      border-color: var(--danger);
      color: var(--danger);
      background: rgba(231, 76, 60, 0.15);
    }

    .stream-close {
      position: absolute;
      top: 6px;
      right: 8px;
      width: 22px;
      height: 22px;
      background: rgba(0, 0, 0, 0.5);
      border: none;
      border-radius: 4px;
      color: #ccc;
      font-size: 14px;
      cursor: pointer;
      display: flex;
      align-items: center;
      justify-content: center;
      z-index: 10;
      transition: background 0.15s;
    }

    .stream-close:hover {
      background: rgba(231, 76, 60, 0.6);
      color: #fff;
    }

    .empty-state {
      flex: 1;
      display: flex;
      flex-direction: column;
      align-items: center;
      justify-content: center;
      color: var(--text-dim);
      gap: 12px;
      font-size: 14px;
    }

    .empty-icon {
      font-size: 48px;
      opacity: 0.3;
    }
