% set pdf and title page metadata
\author[\authorshort]{\authorlong}
\title[\titleshort]{\titlelong}
\subtitle{\titlesub}

% set title page metadata
\logo{\includegraphics[height=7.5em]{../../cnam}}
\institute[\instituteshort]{\institutelong}
\date[\typeshort \dateshort]{\typelong\\\datelong}

% pdf
\hypersetup{
pdfinfo={
Creator={XeLaTeX / beamer},
},
}

% set theme
\usetheme{Berkeley}
% set theme color
\usecolortheme{seahorse}
% set background image
\usebackgroundtemplate{\includegraphics[width=\paperwidth]{../../paper}}

% remove navigation symbols
\beamertemplatenavigationsymbolsempty

% set page numbering
\addtobeamertemplate{navigation symbols}{}{
\color{black}\normalsize\textbf\insertframenumber}

% handle multiple columns
\usepackage{multicol}

% set environments

% set frame with automatic title
\newenvironment{frm}{\begin{frame}\frametitle{%
\insertsectionhead\\
\ifx\insertsubsection\empty\else
\insertsubsectionhead
\ifx\insertsubsubsection\empty\else
\ / \insertsubsubsectionhead
\fi\fi
}}{\end{frame}}
