%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%% This is a class file for the SMYRNA JOURNAL OF NATURAL AND DATA SCIENCE
%% Author: Celal Cem SARIOĞLU (Dokuz Eylul University, Faculty of Science, Department of Mathematics)
%% Email: celalcem.sarioglu@deu.edu.tr
%% Please do not change the file and use it for any other journals without permission.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\NeedsTeXFormat{LaTeX2e}
\ProvidesClass{sjndsart}[27/01/2025, v1.0]
\RequirePackage{ifthen}
\RequirePackage{calc}
\AtEndOfClass{\RequirePackage{microtype}}
\DeclareOption*{\PassOptionsToClass{\CurrentOption}{article}}
\ProcessOptions*
\LoadClass{article}
\RequirePackage{ifpdf}

%%FONTS

%\RequirePackage{times}      % Loads the Times-Roman Fonts
%\RequirePackage{mathptmx}   % Loads the Times-Roman Math Fonts

%%USEFUL PACKAGES

\RequirePackage[utf8]{inputenc}
\RequirePackage{amsmath,amsfonts,amssymb}
\RequirePackage{graphicx,xcolor}
\RequirePackage{subcaption}
\RequirePackage{booktabs}
\RequirePackage[english]{babel}
\RequirePackage{latexsym,amssymb,amsmath,amsthm,color}
\RequirePackage{enumitem}
\RequirePackage[T1]{fontenc}
\RequirePackage[all]{xy}
\RequirePackage{palatino}
\RequirePackage{indentfirst}
\RequirePackage{lipsum}
\RequirePackage{epstopdf}
\renewcommand*\sfdefault{ppl}

\setlength{\fboxrule}{1pt}

\definecolor{color1}{RGB}{0,0,90} % sections 0,0,90
\definecolor{color2}{RGB}{0,0,0} % abstract 0,0,0
\definecolor{color3}{RGB}{0,110,45} % title 0,110, 45

%%MARGINS
	  	
\RequirePackage[left=2cm,%
right=2cm,%
top=2.25cm,%
bottom=2.25cm,%
headheight=11pt,%
a4paper]{geometry}%
				



%%FIGURES AND TABLES CAPTIONS

\RequirePackage[labelfont={bf,sf,small},labelsep=period,justification=raggedright]{caption}
\setlength{\abovecaptionskip}{0pt}
\setlength{\belowcaptionskip}{0pt}
				



%%PAGE HEADER
\RequirePackage{fancyhdr}
\RequirePackage{lastpage}
\pagestyle{fancy}

\fancyhead{} % clear all header fields
%\fancyhead[CO,CE]{\small \@ShortAuthors\ / Smyrna J. of Nature and Data Sci.\ \@Numbers}
\fancyhead[CE]{\@ShortAuthors}
\fancyhead[CO]{\@ShortTitle}
\fancyhead[LE,RO]{\thepage}
\fancyfoot{} % clear all footer fields
%\fancyfoot[CE,CO]{\small\bfseries --- \thepage/\pageref{LastPage} ---}
%\fancyfoot[LO,CE]{}
%\fancyfoot[CO,RE]{}
\renewcommand{\headrulewidth}{0.1pt}
\renewcommand{\footrulewidth}{0pt}



%%SECTION/SUBSECTION/PARAGRAPH SET-UP

\RequirePackage[explicit]{titlesec}
\titleformat{\section}[hang]
  {\large\bfseries}
  {}
  {0em}
  {\parbox{\dimexpr\linewidth-2\fboxsep\relax}{\arabic{section}. #1}}
  []
\titleformat{name=\section,numberless}
  {\large\bfseries}
  {}
  {0em}
  {\parbox{\dimexpr\linewidth-2\fboxsep\relax}{#1}}
  []
\titleformat{\subsection}
  {\bfseries}
  {\large\thesubsection}
  {0.5em}
  {#1}
  []
\titleformat{\subsubsection}
  {\bfseries}
  {\thesubsubsection}
  {0.5em}
  {#1}
  []
\titleformat{\paragraph}[runin]
  {\small\bfseries}
  {}
  {0em}
  {#1}
\titlespacing*{\section}{0pc}{3ex \@plus4pt \@minus3pt}{5pt}
\titlespacing*{\subsection}{0pc}{2.5ex \@plus3pt \@minus2pt}{0pt}
\titlespacing*{\subsubsection}{0pc}{2ex \@plus2.5pt \@minus1.5pt}{0pt}
\titlespacing*{\paragraph}{0pc}{1.5ex \@plus2pt \@minus1pt}{10pt}



%%MULTIPLE AUTHOR

\newcount\@authcnt
\newcount\@tmpcnt\@tmpcnt\z@

\def\@affiliation{%
  \ifnum\@tmpcnt<\@authcnt
   \global\advance\@tmpcnt1
    \raggedright \csname @auth\romannumeral\the\@tmpcnt\endcsname\hfill\\%
   \let\next\@affiliation \vskip1pt
  \else
   \let\next\relax
  \fi
\next}
	
\newcommand{\affiliation}[1]{%
    \global\advance\@authcnt1
    \expandafter\gdef\csname @auth\romannumeral\the\@authcnt\endcsname
    {#1}}

\def\recaccdate#1#2#3{%
	\gdef\@recaccdate{%
		\par\footnotetext{\hspace*{-14pt}\noindent\itshape \textbf{Received :} #1,\ \textbf{Accepted :} #2,\ \textbf{Available online :} #3
\vskip5pt%
}}}
\let\@recaccdate\@empty

%%TITLEPAGE

\newcommand{\FullTitle}[1]{\def\@FullTitle{#1}}
\newcommand{\ShortTitle}[1]{\def\@ShortTitle{#1}}
\newcommand{\DOI}[1]{\def\@DOI{#1}}
\newcommand{\Authors}[1]{\def\@Authors{#1}}
\newcommand{\citem}[1]{\def\@citem{#1}}
\newcommand{\ShortAuthors}[1]{\def\@ShortAuthors{#1}}
\newcommand{\JournalTitle}[1]{\def\@JournalTitle{#1}}
\newcommand{\Numbers}[1]{\def\@Numbers{#1}}
\newcommand{\Abstract}[1]{\def\@Abstract{#1}}
\newcommand{\Keywords}[1]{\def\@Keywords{#1}}
\newcommand{\Subjects}[1]{\def\@Subjects{#1}}

\newcommand{\keywordname}{\small Keywords:~}
%\newcommand{\subjname}{\small AMS Subject Classification (2020):~}
% PROLUGE

\def\address#1#2{\vskip16pt\noindent\sc{#1 \\ \textbf{Address:}} \normalfont #2}
\def\email#1{\noindent\sc{\textbf{e-mail:}} \normalfont #1}

\renewcommand{\@maketitle}{%
%\twocolumn[{%
{%
\thispagestyle{empty}\label{FirstPage}%
\vskip-36pt
\noindent\begin{minipage}{0.8\textwidth}
\raggedright\Large\bfseries\textsc\@JournalTitle\\\vspace{0.2cm}
\raggedright\small\bfseries\@DOI \\\vspace{0.1cm}
\raggedright\small\bfseries\textsc\@Numbers\ - Research Article \\\vspace{0.1cm}
\raggedright\small\bfseries\textsc ISSN: xxxx-yyyy \\
\vspace{0.15cm}
\raggedright\small\bfseries\textsc \copyright SJNDS\\
\end{minipage}
\hfill
\begin{minipage}{0.2\textwidth}\raggedleft
\includegraphics[scale=0.1]{sjnds_logo.png}\vspace{1.2cm}
\end{minipage}


\vskip20pt%
{\centering \bfseries\fontsize{18}{22}\selectfont \@FullTitle\par}%
\vskip10pt%
{\centering \fontsize{11}{15}\selectfont  \@Authors\par}%
\vskip18pt%
%
\parbox{\textwidth-12\fboxsep-2\fboxrule}{\centering%
%
\parbox{\textwidth-14\fboxsep-2\fboxrule}{%
\ifx\@Keywords\@empty%
\textbf{\abstractname}\\\@Abstract%
\else%
\textbf{\abstractname}\\{\small\@Abstract}\\%
\noindent\rule{\textwidth-14\fboxsep-2\fboxrule}{0.5pt}\par\textbf{\itshape\keywordname}{\small\itshape \@Keywords}\\[4pt]%
%\textbf{\itshape\subjname}{\small\itshape \@Subjects}\\[4pt]%
{\small\itshape * Corresponding author}
\fi%
}%
%
\@recaccdate
\vskip4pt%
\begingroup%
\raggedright\small%
\footnotesize\@affiliation\par%
\endgroup%%
}%
%
\vskip25pt%
{\lineskip 1.5em {\noindent\@recaccdate}\par}
}%
}

%%REFERENCES

