\whatsnote_provide_module:n { layout }

\bool_if:NTF \g__whatsnote_darkmode_bool
  {
    \pagecolor{black!90}
    \color{black!10}
    \tl_set:Nn \l__whats_darkmode_fading_tl {!30}
    \AtBeginDocument{\color_select:n{black!10}}
  }
  { \tl_new:N \l__whats_darkmode_fading_tl }

\def\@makechapterhead#1
  {
    \vspace*{ -25\p@ }
    {
      \parindent \z@ \raggedright \normalfont
      \int_compare:nNnT { \c@secnumdepth } > { \m@ne }
        {
          \if@mainmatter
            \parbox { 16ex }
              {
                \centering
                \@setfontsize\HUGE{30}{40} \normalfont\bfseries
                \textcolor{darkgray}{\thechapter}
                \vskip6\p@
                \normalsize \bfseries\sffamily\scshape
                \textcolor{darkgray}{\@chapapp}
              }
          \fi
        }
      \interlinepenalty\@M \hspace*{2.5ex}
      \parbox { \dim_eval:n { \linewidth - 21ex } } { \huge \bfseries #1 }
      \par\nobreak
      \vskip 45\p@
    }
  }

\def\@makeschapterhead#1
  {
    \renewcommand*{\thesection}{\arabic{section}}
    \renewcommand*{\theproblem}{\arabic{problem}}
    \setcounter{section}{0}
    \setcounter{problem}{0}
      {
        \centering
        \parindent \z@
        \normalfont
        \interlinepenalty\@M
        \huge \bfseries #1\par\nobreak
        \vskip 40\p@
      }
  }

\NewDocumentEnvironment{textfig}{O{7 \c_colon_str 2}}
  {
    \group_begin:
    \seq_set_split:Nee \l__whats_textfig_ratio_seq {\c_colon_str} {#1}
    \vspace{4.5pt plus 1.5pt minus 1.5pt} \noindent
    \minipage
      {
        \fp_eval:n
          {
            .96*\seq_item:Nn \l__whats_textfig_ratio_seq {1}/
              (
                \seq_item:Nn \l__whats_textfig_ratio_seq {1} + 
                \seq_item:Nn \l__whats_textfig_ratio_seq {2}
              )
          }\dimexpr \linewidth
      }
  }
  {
    \endminipage
    \vspace{4.5pt plus 1.5pt minus 1.5pt} \par
    \group_end:
  }

\NewDocumentCommand \textfigsplit {}
  {
    \endminipage
    \hspace{.02\linewidth}
    \minipage
      {
        \fp_eval:n
          {
            .96*\seq_item:Nn \l__whats_textfig_ratio_seq {2}/
              (
                \seq_item:Nn \l__whats_textfig_ratio_seq {1} + 
                \seq_item:Nn \l__whats_textfig_ratio_seq {2}
              )
          }\dimexpr \linewidth
      } 
  }

\RequirePackage{ tasks, multirow, multicol }
\settasks { label = \sffamily\Alph*., item-indent = 2.5em, label-offset = .5pt }

\RequirePackage[inline]{enumitem}

\RequirePackage{fancyhdr}

\endinput
