\documentclass[french]{article}
\usepackage[T1]{fontenc}
\usepackage{babel}
\usepackage[table]{xcolor}
\usepackage{lmodern}
\usepackage{emerald}
\usepackage{eso-pic}
\usepackage[urlcolor=blue,colorlinks=true]{hyperref}
\usepackage[margin=1cm,bottom=2.5cm]{geometry}
\usepackage{titlesec}
\usepackage{fancyhdr}
\usepackage{tikz}
	\usetikzlibrary {decorations.pathmorphing , shapes.geometric , calc}
\usepackage{pas-math}
\usepackage{multicol}
\usepackage{cellspace}
\setlength{\cellspacebottomlimit}{4pt}
\setlength{\cellspacetoplimit}{4pt}
\usepackage{eurosym,numprint,esvect}

% Couleurs

\definecolor{bleuciel}{HTML}{45b5f4}
\definecolor{bleu}{HTML}{0e3e59}
\definecolor{orangesanguine}{HTML}{b43f0b}
\definecolor{vert}{HTML}{287f13}

% styles des titres

%%% Titre de la fiche

\renewcommand{\title}[1]{%
\begin{center}
\begin{tikzpicture}
\node[fill=bleuciel,ellipse,decorate,decoration={random steps,segment length=3pt,amplitude=2pt}, align=center,inner ysep=5mm, inner xsep=0pt,ball color=bleuciel] (titre) {\ECFJD\Huge #1};
\node[below] (auteur) at (titre.south) {\ECFJD Une fiche de cours de Stéphane Pasquet - Mise à jour : \today};
\node[below] at (auteur.south) {(\url{https://courspasquet.fr})\qquad\qquad(\url{https://mathweb.fr})};
\end{tikzpicture}
\end{center}
}

%%% section

\titleformat{\section}[block]
{\ECFJD\fontsize{16}{14}\selectfont\color{bleu}}
{\thesection}
{1em}
{\ECFJD}
\setlength{\parindent}{0pt}

%%% subsection

\titleformat{\subsection}[block]
{\ECFJD\fontsize{12}{12}\selectfont\color{orangesanguine}}
{\thesubsection}
{1em}
{\ECFJD}
\setlength{\parindent}{0pt}

%%% paragraph

\titleformat{\paragraph}[runin]
{\ECFJD\color{vert}}{\theparagraph}{1em}{}

%%% pied et tête de page

\renewcommand{\headrulewidth}{0pt}
\lhead{}
\cfoot{\ECFJD\Large\color{white}\fcolorbox{bleu}{bleu}{\thepage}}
\renewcommand{\headrulewidth}{0pt}


\begin{document}

\pagestyle{fancy}

\AddToShipoutPictureBG
{%
	\put(\LenToUnit{5mm},\LenToUnit{5mm})
	{%
		\begin{tikzpicture}
		\draw[fill=yellow!10,draw,thick,decorate,decoration = {random steps}] (0,0) rectangle +(\dimexpr\paperwidth-10mm,\dimexpr\paperheight-10mm);
		\end{tikzpicture}
	}
}


\title{Applications du produit scalaire}

\subsection*{Formule d'Al-Kashi}
\begin{minipage}{0.5\linewidth}
\[
\boxed{a^2=b^2+c^2-2bc\cos\widehat{\text{A}}}
\]
\end{minipage}
\begin{minipage}{0.5\linewidth}
\begin{center}
\begin{tikzpicture}
\draw (0,0) node[below left] {A}  -- (5,0) node[midway,below] {$c$} node[below right] {B}  -- (40:2.5) node[above] {C} -- (0,0) node[midway,above left] {$b$};
\draw[red,very thick] (5,0) -- (40:2.5) node[midway,above] {$a$};
\draw[very thick,red] (0.5,0) arc(0:40:0.5cm);
\node[scale=0.8,red] at (20:0.8cm) {$\widehat{\text{A}}$};
\end{tikzpicture}
\end{center}
\end{minipage}

\subsection*{Théorème de la médiane}
\begin{minipage}{0.5\linewidth}
\[
\boxed{\text{MA}^2+\text{MB}^2=\dfrac{1}{2}\text{AB}^2+2\text{MI}^2}
\]
\end{minipage}
\begin{minipage}{0.5\linewidth}
\begin{center}
\begin{tikzpicture}
\draw (0,0) node[below left] {A} -- (6,0) node[below right] {B} -- (4,2) node[above] {M} -- cycle;
\draw[red] (3,0) node[below] {I} -- (4,2);
\node[red,scale=0.75] at (1.5,0) {\textbf{//}};
\node[red,scale=0.75] at (4.5,0) {\textbf{//}};
\end{tikzpicture}
\end{center}
\end{minipage}

\subsection*{Lignes de niveau}

Pour tous points A, B et M du plan, avec I milieu de [AB].

\begin{multicols}{2}
\[
\boxed{\vv{MA}\cdot\vv{MB}= MI^2-\dfrac{1}{4}AB^2}
\]
\columnbreak
\[
\boxed{\vv{MA}\cdot\vv{MB}=0 \iff M\text{ est sur le cercle de diamètre [AB]}}
\]
\end{multicols}

\subsection*{Centre de gravité}
$G$ centre de gravité du triangle $ABC$, $M$ est un point quelconque du plan.

\medskip

\begin{minipage}{0.25\linewidth}
\[
\boxed{\vv{GA}+\vv{GB}+\vv{GC}=\vv{0}}
\]
\end{minipage}
\begin{minipage}{0.25\linewidth}
\[
\boxed{\vv{MA}+\vv{MB}+\vv{MC}=3\vv{MG}}
\]
\end{minipage}
\begin{minipage}{0.5\linewidth}
\[
\boxed{MA^2+MB^2+MC^2=3MG^2+GA^2+GB^2+GC^2}
\]
\end{minipage}

\subsection*{\'Equation cartésienne d'un cercle de centre $\Omega\coord{a}{b}$ et de rayon $r$}
\[
\boxed{(x-a)^2+(y-b)^2=r^2}
\]

\subsection*{Vecteur normal et vecteur directeur à une droite $(d)\,:\, ax+by+c=0$}
\[
\boxed{\text{Vecteur normal : }\vv{n}\dbinom{a}{b}}
\qquad
\boxed{\text{Vecteur directeur : }\vv{u}\dbinom{-b}{a}}
\]
\end{document}