\RequirePackage{xcolor}

\DeclareOption{colorblind_safe}{
    \definecolor{blue}  {RGB}{ 68, 119, 170}
    \definecolor{cyan}  {RGB}{102, 204, 238}
    \definecolor{green} {RGB}{ 34, 136,  51}
    \definecolor{yellow}{RGB}{204, 187,  68}
    \definecolor{red}   {RGB}{238, 102, 119}
    \definecolor{purple}{RGB}{170,  51, 119}
    \definecolor{grey}  {RGB}{187, 187, 187}
    \colorlet{emphcolor}{purple}
}
\ProcessOptions\relax

\definecolor{dvipsForestGreen}{RGB}{ 34, 139,  34}
\colorlet{originalgreen}{green}
\colorlet{green}{dvipsForestGreen}
\colorlet{emphcolor}{magenta}

\definecolor{KAISTLightBlue}{RGB}{95, 190, 235}
\definecolor{KAISTBlue}{RGB}{20, 135, 200}
\definecolor{KAISTDarkBlue}{RGB}{0, 65, 145}
\definecolor{KAISTMediumBlue}{RGB}{0, 65, 135}

\usetheme[secheader]{Boadilla}
\usecolortheme[named=KAISTDarkBlue]{structure}
\setbeamercolor{palette primary}{use=structure,bg=KAISTDarkBlue!60!white}
\setbeamercolor{palette secondary}{use=structure,bg=KAISTDarkBlue!80!white}
\setbeamercolor{palette tertiary}{use=structure,bg=KAISTDarkBlue}
\setbeamercolor{block body}{bg=KAISTDarkBlue!10!white}
\setbeamercolor{block title}{bg=KAISTDarkBlue!25!white}
%\setbeamercolor{palette quaternary}{use=structure,bg=black}
\setbeamercolor{frametitle}{fg=KAISTDarkBlue}
\usefonttheme[onlymath]{serif}
\usefonttheme[onlylarge]{structurebold}

\setbeamertemplate{bibliography item}{\insertbiblabel}
\setbeamertemplate{theorems}[numbered]
\addtobeamertemplate{theorem begin}{\normalfont}{}
\theoremstyle{plain}
\newtheorem{exmp}{Example}
\newtheorem{rmrk}{Remark}
\newtheorem*{my_fact}{Fact}
\newtheorem{claim}[theorem]{Claim}
\newtheorem{asmp}{Assumption}
\newtheorem*{asmp*}{Assumption}

\AtBeginSection[]
{
  \begin{frame}
    \frametitle{Contents}
    \tableofcontents[currentsection]
  \end{frame}
}

% Different numbering for Theorems, Examples, Definition, and Lemma
% Should be used with /notheorems/ option
\makeatletter
\ifbeamer@blocks
	\relax
\else
    \ifbeamer@countsect
      \newtheorem{theorem}{Theorem}[section]
    \else
      \newtheorem{theorem}{Theorem}
    \fi
    \newtheorem{corollary}{Corollary}
    \newtheorem{fact}{Fact}
    \newtheorem{lemma}{Lemma}
    \newtheorem{problem}{Problem}
    \newtheorem{solution}{Solution}

    \theoremstyle{definition}
    \newtheorem{definition}{Definition}

    \theoremstyle{example}
    \newtheorem{example}{{Example}}

\fi
\makeatother