<reasoning_content>
*   Goal: Implement priority-based job scheduling for a `JobQueue`.
    *    Requirements:
        1.  `add_job` needs an optional `priority` param (default 0).
        2.  Higher priority jobs first.
        3.  Same priority $\rightarrow$ FIFO order.
        4.  `get_next_job()` $\rightarrow$ returns tuple `(name, data)` or `None`.
    *    Priority Levels: 0 (Normal), 1 (High), 2 (Critical).
    *    Order: Higher value = higher priority (2 > 1 > 0). *Wait, usually "Priority 1" is highest, but the prompt says 2 is Critical and 0 is Normal, so higher number means higher priority.*

    *   To handle priority + FIFO, a heap (Priority Queue) is the standard choice.
    *   Heap element: `(priority, entry_count, job_name, job_data)`.
    *   Why `entry_count`? To maintain FIFO order for same priority values (since heaps aren't stable).
    *   Python's `heapq` implements a min-heap.
    *   Requirement says Higher priority (2) goes before Lower (0).
    *   To use a min-heap for high priority values, I should store the priority as a negative value (e.g., -2, -1, 0).
    *   Alternatively, since there are only 3 levels, I could use a list of lists, but a heap is more general and standard.

    *Let's re-read:*
    "Higher priority jobs should be processed before lower priority jobs"
    Priority levels: 0: Normal, 1: High, 2: Critical.
    So, 2 must come out before 1, which comes before 0.

    *Refined logic:*
    - `heapq` is a min-heap.
    - Store entries as `(-priority, sequence_number, job_name, job_data)`.
    - `sequence_number` ensures FIFO.

    ```python
    import heapq

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

        def add_job(self, name: str, data: dict, priority: int = 0):
            # Use negative priority because heapq is a min-heap
            # counter ensures FIFO for same priority
            heapq.heappush(self.heap, (-priority, self.counter, name, data))
            self.counter += 1

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

    - Requirements check:
        1. `add_job` with `priority`? Yes.
        2. Higher priority first? Yes (negative value makes 2 smaller than 1).
        3. Same priority FIFO? Yes (counter).
        4. `get_next_job` signature? Yes.

    *Wait, let me double check the "Higher priority" wording.*
    "Higher priority jobs should be processed before lower priority jobs"
    If priority is 0, 1, 2.
    2 is "Critical" (Higher priority than 1).
    So 2 must be popped first.
    In a min-heap: `-2 < -1 < 0`. So `-2` comes out first. Correct.

    - Just the code.
    - Use `heapq`.

    Wait, I should probably use a `dataclass` or just a list? A list/tuple is fine.
    Wait, the example shows `queue = JobQueue()`. I need to define the class.

    Code:
    ```python
    import heapq

    class JobQueue:
        def __init__(self):
            self.heap = []
            self.count = 0

        def add_job(self, name: str, data: dict, priority: int = 0):
            # heapq is a min-heap. We negate priority to make
            # higher numbers (Critical=2) come out first.
            heapq.heappush(self.heap, (-priority, self.count, name, data))
            self.count += 1

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

    Wait, one detail: "Higher priority jobs should be processed before lower priority jobs".
    Priority levels: 0: Normal, 1: High, 2: Critical.
    If I use `(-priority, self.count)`, then:
    - Critical (2) -> `-2`
    - High (1) -> `-1`
    - Normal (0) -> `0`
    Sorted: `-2, -1, 0`. Correct.

    Let's check if there's a simpler way without negative numbers?
    I could use a list of 3 lists: `[[], [], []]`.
    `queue[priority].append(...)`.
    `get_next_job` checks from index 2 down to 0.
    But `heapq` is more "standard" for a priority queue.

    One final check on requirements:
    `get_next_job() -> tuple[str, dict] | None`
    The return type hint is specified. I should include it.

    ```python
    import heapq
    from typing import Tuple, Dict, Optional

    class JobQueue:
        def __init__(self):
            self.heap = []
            self.count = 0

        def add_job(self, name: str, data: dict, priority: int = 0):
            # Use negative priority to turn min-heap into max-priority
            # Use count to ensure FIFO for equal priorities
            heapq.heappush(self.heap, (-priority, self.count, name, data))
            self.count += 1

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

    Wait, the prompt doesn't specify `typing` imports, but it uses `tuple[str, dict] | None`. This is Python 3.10+ syntax. I should stick to that.

    Final code block looks good.

    One more check:
    `queue.add_job("normal", {"type": " normal"}, priority=0)`
    `queue.add_job("critical", {"type": "critical"}, priority=2)`
    `queue.add_job("high", {"type": "high"}, priority=1)`
    `get_next_job()` -> `("critical", {"type": "critical"})`

    The order in heap:
    1. `(-0, 0, "normal", ...)`
    2. `(-2, 1, "critical", ...)`
    3. `(-1, 2, "high", ...)`
    Min heap state: `[(-2, 1, "critical"), (-1, 2, "high"), (-0, 0, "normal")]`
    Pop gives `-2`. Correct.

    Wait, the prompt says "Higher priority jobs should be processed before lower priority jobs".
    Usually "Priority 1" is highest in many systems, but here "Priority 2" is "Critical" and "Priority 0" is "Normal".
    So Priority 2 > Priority 1 > Priority 0.
    The logic holds.

    The type hint `tuple[str, dict] | None` is exactly what I should use.
</reasoning_content>

<content>
```python
import heapq

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

    def add_job(self, name: str, data: dict, priority: int = 0):
        # Use negative priority because heapq is a min-heap.
        # A higher priority number (e.g., 2) becomes a smaller 
        # negative number (-2), ensuring it is popped first.
        # self.counter ensures FIFO order for jobs with the same priority.
        heapq.heappush(self.heap, (-priority, self.counter, name, data))
        self.counter += 1

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