Independence of $A$ and $B$ implies the independence of $\neg A$ and $B$

Does the following apply? $$P(A\mid B)=P(A)\implies P(\neg A\mid B)=P(\neg A)$$

My rough answer is that suppose $A$ is the probability of rainy and $B$ is the probability of toothache. Then both $P(A\mid B)=P(A)$ and $P(\neg A\mid B)=P(\neg A)$ apply. But can we prove this mathematically?


$𝑃(¬𝐴|𝐵)$

= $1 - 𝑃(𝐴|𝐵)$

= $1 - 𝑃(𝐴)$, from given $P(A|B) = P(A)$

= $𝑃(¬𝐴)$, Q.E.D.


Firstly, $$p(A|B)=p(A)\implies \frac{p(A\cap B)}{p(B)}=p(A)\implies p(A\cap B)=p(A)p(B)$$ Then, $$p(A'|B)=\frac{p(A'\cap B)}{p(B)}$$ $$=\frac{p(B)-p(A\cap B)}{p(B)}$$ $$=1-\frac{p(A)p(B)}{p(B)}$$ $$=1-p(A)=p(A')$$