[proofplan]
We prove the stronger assertion that $r \notin A$ for every $\mu$-null Borel set $A$ coded in the ground model $M$. Given such an $A$, we form the dense set of random forcing conditions whose representatives avoid $A$. Since this dense set is coded in $M$, the $M$-genericity of $r$ ensures that the generic filter meets it, yielding a positive-measure condition containing $r$ and disjoint from $A$. The inclusion $N \subseteq A$ then gives $r \notin N$.
[/proofplan]
[step:Fix the random forcing convention and the null Borel set]
Let $\mu$ denote the standard product probability measure on $2^{\mathbb{N}}$. Let $\mathbb{P}^M$ denote the random forcing notion in $M$: its conditions are Borel sets $B \subseteq 2^{\mathbb{N}}$ coded in $M$ with $\mu(B)>0$, and $C \leq B$ means $\mu(C \setminus B)=0$. Equivalently, conditions may be identified modulo $\mu$-null symmetric difference; the order is inclusion modulo null sets. In this proof we use Borel representatives and the standard interpretation of a random real $r$ over $M$: if $B \in \mathbb{P}^M$ is a Borel representative of a condition in the associated generic filter $G_r$, then $r \in B$ after replacing representatives, when necessary, by equivalent Borel representatives from the filter convention.
Let $A \subseteq 2^{\mathbb{N}}$ be a Borel set with a Borel code in $M$ such that $\mu(A)=0$ and $N \subseteq A$. It is enough to prove $r \notin A$, because then $r \notin N$ follows from $N \subseteq A$.
[/step]
[step:Build the dense family of conditions avoiding $A$]
Define $D_A := \{B \in \mathbb{P}^M : B \cap A = \varnothing\}$.
We claim that $D_A$ is dense in $\mathbb{P}^M$. Let $B \in \mathbb{P}^M$ be arbitrary. Define $C := B \setminus A$. Since $B$ and $A$ are Borel subsets of $2^{\mathbb{N}}$, the set $C$ is Borel. Since $A$ is $\mu$-null, countable additivity of $\mu$ gives $\mu(C) = \mu(B \setminus A) = \mu(B) > 0$. Thus $C \in \mathbb{P}^M$. Also $C \cap A = \varnothing$, so $C \in D_A$, and $C \leq B$ because $C \subseteq B$. Hence every condition has a stronger condition in $D_A$, proving density.
[guided]
The purpose of this step is to turn the statement “$A$ is null” into a dense requirement for the generic real. Define $D_A := \{B \in \mathbb{P}^M : B \cap A = \varnothing\}$. A condition in $D_A$ is a positive-measure Borel set that completely avoids $A$. If the generic real is captured by such a condition, it cannot lie in $A$.
We verify density. Take an arbitrary condition $B \in \mathbb{P}^M$, so $B$ is a Borel subset of $2^{\mathbb{N}}$ coded in $M$ and $\mu(B)>0$. Remove the null set $A$ by defining $C := B \setminus A$. The set $C$ is Borel because Borel sets are closed under set difference. Since $A$ has measure zero, removing $A$ from $B$ does not change the measure of $B$: the sets $B \setminus A$ and $B \cap A$ are disjoint, $B = (B \setminus A) \cup (B \cap A)$, and $B \cap A \subseteq A$, so $\mu(B \cap A)=0$. Therefore $\mu(B)=\mu(B \setminus A)+\mu(B \cap A)=\mu(C)$. Since $\mu(B)>0$, we get $\mu(C)>0$, so $C$ is again a valid random forcing condition. Moreover $C \subseteq B$, hence $C \leq B$, and by construction $C \cap A=\varnothing$. Thus every condition $B$ can be strengthened to a condition $C$ that avoids $A$, which proves that $D_A$ is dense in $\mathbb{P}^M$.
[/guided]
[/step]
[step:Use genericity to meet the dense family]
Because $A$ has a Borel code in $M$, the set $D_A$ is definable in $M$ from that code and the random forcing relation in $M$. More explicitly, the sufficient ZFC fragment satisfied by $M$ proves that Borel codes are closed under Boolean operations, including set difference; hence for each Borel code for $B$ in $M$, the code for $B \setminus A$ is also in $M$. Thus the definition of $D_A$ is carried out inside $M$, and $D_A \in M$.
Let $G_r \subseteq \mathbb{P}^M$ be the $M$-generic filter associated to the random real $r$. Since $D_A$ is dense in $\mathbb{P}^M$ and belongs to $M$, genericity gives $G_r \cap D_A \neq \varnothing$. Choose a Borel representative $B \in G_r \cap D_A$ according to the convention fixed above, so $r \in B$. Since $B \in D_A$, we also have $B \cap A=\varnothing$. Therefore $r \notin A$.
[/step]
[step:Pass from the null Borel superset to the original set]
We have proved that $r \notin A$. Since $N \subseteq A$, membership $r \in N$ would imply $r \in A$. Therefore $r \notin N$. This proves that every random real over $M$ avoids every subset of $2^{\mathbb{N}}$ contained in a null Borel set coded in $M$.
[/step]