<reasoning_content>
*   Goal: Implement priority-based job scheduling.
    *   Requirements:
        1.  `add_job` must accept an optional `priority` parameter (default 0).
        2.  Higher priority jobs come first.
        3.  Same priority jobs follow FIFO order.
        4.  `get_next_job()` returns the highest priority job or `None`.
    *   Priority levels: 0 (Normal), 1 (High), 2 (Critical).
    *   Output format: Only Python code, no explanations.

    *   I need a data structure that maintains order based on priority and insertion time (FIFO for same priority).
    *   A common way to implement a priority queue in Python is using `heapq`.
    *   `heapq` is a min-heap. To make it act as a max-heap for priority, I can store priorities as negative values (e.g., 2 becomes -2).
    *   To handle FIFO for same priority, I need a counter (sequence number) to break ties.

    *   `self.queue = []`
    *   `self.counter = 0`
    *   `add_job(name, data, priority=0)`:
        *   Priority values are 0, 1, 2.
        *   Since `heapq` is min-heap, use `-priority`.
        *   Store tuple: `(-priority, self.counter, name, data)`.
        *   Increment `self.counter`.
        *   `heapq.heappush(self.queue, item)`.
    *   `get_next_job()`:
        *   If `self.queue` is empty, return `None`.
        *   Otherwise, `heapq.heappop(self.queue)`.
        *   Return `(name, data)`.

    *   `Priority: 0 (Normal), 1 (High), 2 (Critical)`.
    *   If I use negative numbers:
        *   Critical (2) -> -2
        *   High (1) -> -1
        *   Normal (0) -> 0
    *   Min-heap order: -2, then -1, then 0. This correctly places Critical first.

    ```python
    import heapq

    class JobQueue:
        def __init__(self):
            self.queue = []
            self.counter = 0

        def add_job(self, name: str, data: dict, priority: int = 0):
            # Using negative priority for max-heap behavior with heapq
            # Using counter to maintain FIFO for same priority
            heapq.heappush(self.queue, (-priority, self.counter, name, data))
            self.counter += 1

        def get_next_job(self) -> tuple[str, dict] | None:
            if not self.queue:
                return None
            priority_neg, counter, name, data = heapq.heappop(self.queue)
            return (name, data)
    ```

    *   `add_job` accepts optional `priority` (default=0). Check.
    *   Higher priority jobs processed before lower. Check (using negative values in min-heap).
    *   Same priority maintain FIFO order. Check (using `self.counter`).
    *   `get_next_job()` returns `tuple[str, dict] | None`. Check.

    *   Include type hints as seen in the prompt's example.
</reasoning_content>

<content>
```python
import heapq

class JobQueue:
    def __init__(self):
        self.queue = []
        self.counter = 0

    def add_job(self, name: str, data: dict, priority: int = 0):
        # Use negative priority to turn heapq (min-heap) into a max-heap behavior
        # Counter ensures FIFO order for jobs with the same priority
        heapq.heappush(self.queue, (-priority, self.counter, name, data))
        self.counter += 1

    def get_next_job(self) -> tuple[str, dict] | None:
        if not self.queue:
            return None
        
        _, _, name, data = heapq.heappop(self.queue)
        return (name, data)
```
</content>