$(A\cap B)\cup C = A \cap (B\cup C)$ if and only if $C \subset A$
It’s a little easier to go the other way: $A\cap(B\cup C)=(A\cap B)\cup(A\cap C)$, and you’d like to show that this equals $(A\cap B)\cup C$ if and only if $C\subseteq A$.
- Suppose first that $C\subseteq A$; how can you simplify $A\cap C$?
- Now suppose that $C\nsubseteq A$; then there is some $c\in C\setminus A$. Show that this $c$ is an element of $(A\cap B)\cup C$ but not of $(A\cap B)\cup(A\cap C)$, so that these two sets cannot be equal.
Your Venn diagrams show what happens when $C\subseteq A$, so they’re useful in proving one direction of the desired result: if $C\subseteq A$, then the two sets are equal. To see how you might prove the other direction, i.e., that if $C\nsubseteq A$, then the two sets are not equal, you’d do better to look at a Venn diagram showing $C\nsubseteq A$.
Here is a full algebraic proof. Let's first expand the definitions:
\begin{align} & (A \cap B) \cup C = A \cap (B \cup C) \\ \equiv & \;\;\;\;\;\text{"set extensionality"} \\ & \langle \forall x :: x \in (A \cap B) \cup C \;\equiv\; x \in A \cap (B \cup C) \rangle \\ \equiv & \;\;\;\;\;\text{"definition of $\;\cap\;$ and $\;\cap\;$, both twice"} \\ & \langle \forall x :: (x \in A \land x \in B) \lor x \in C \;\equiv\; x \in A \land (x \in B \lor x \in C) \rangle \\ \end{align}
Now we have a choice to make: do we distribute $\;\lor\;$ over $\;\land\;$ in the left hand side, or $\;\land\;$ over $\;\lor\;$ in the right hand side? Since this expression is completely symmetric, we arbitrarily choose to distribute on the left hand side, and continue our logical simplification after that:
\begin{align} \equiv & \;\;\;\;\;\text{"distribute $\;\lor\;$ over $\;\land\;$ on left hand side"} \\ & \langle \forall x :: (x \in A \lor x \in C) \land (x \in B \lor x \in C) \;\equiv\; x \in A \land (x \in B \lor x \in C) \rangle \\ \equiv & \;\;\;\;\;\text{"extract common conjunct out of $\;\equiv\;$"} \\ & \langle \forall x :: x \in B \lor x \in C \;\Rightarrow\; (x \in A \lor x \in C \equiv x \in A \rangle \\ \equiv & \;\;\;\;\;\text{"simplify one way of rewriting $\;\Rightarrow\;$"} \\ & \langle \forall x :: x \in B \lor x \in C \;\Rightarrow\; (x \in C \Rightarrow x \in A) \rangle \\ \equiv & \;\;\;\;\;\text{"combine both antecedents"} \\ & \langle \forall x :: (x \in B \lor x \in C) \land x \in C \;\Rightarrow\; x \in A \rangle \\ \equiv & \;\;\;\;\;\text{"simplify antecedent: use $\;x \in C\;$ in other side of $\;\land\;$"} \\ & \langle \forall x :: x \in C \;\Rightarrow\; x \in A \rangle \\ \end{align}
Now we only have to wrap up:
\begin{align} \equiv & \;\;\;\;\;\text{"definition of $\;\subseteq\;$"} \\ & C \subseteq A \\ \end{align}