\documentclass{article}
\usepackage[most]{tcolorbox}
\usepackage{lipsum}
\newtcbtheorem[auto counter]{mytheorem}{Theorem}{%
enhanced,
empty,
coltitle=black,
fonttitle=\bfseries,
lefttitle=1cm,
attach boxed title to top left={xshift=15mm},
overlay={\draw (title.west)-|([yshift=15mm]frame.south west);
\draw ([yshift=-15mm]frame.north east)--([yshift=5mm]frame.south east)--([xshift=-5mm]frame.south east)--++(180:2cm);
\draw ([yshift=3mm]frame.south east)--([xshift=-3mm]frame.south east);}
}{th}
\begin{document}
\begin{mytheorem}{}{a}
\lipsum[1]
\end{mytheorem}
\begin{mytheorem}{Second theorem}{b}
As you can see in Theorem~\ref{th:a} \dots
\lipsum[1]
\end{mytheorem}
\end{document}