\documentclass[11pt]{article}
% =========================================================
% BASIC PAGE SETUP
% =========================================================
% geometry controls page margins and paper layout
\usepackage[margin=1in]{geometry}
% =========================================================
% FONT SETUP
% =========================================================
% Choose ONE font route depending on your compiler.
%
% ROUTE A: If compiling with XeLaTeX or LuaLaTeX
% Uncomment the next block for Arial / Times New Roman if installed
%
% \usepackage{fontspec}
% \setmainfont{Arial} % Main body font
% % \setmainfont{Times New Roman}
% % \setsansfont{Arial}
% % \setmonofont{Courier New}
%
% ROUTE B: If compiling with pdfLaTeX
% Use a Times-like font:
\usepackage{newtxtext,newtxmath}
%
% If you want an Arial-like sans serif look in pdfLaTeX, use:
% \usepackage[scaled]{helvet}
% \renewcommand{\familydefault}{\sfdefault}
%
% Notes:
% - pdfLaTeX cannot directly use system fonts like Arial.
% - XeLaTeX/LuaLaTeX can use installed system fonts directly.
% - For most academic work, Times-like fonts are easiest and safest.
% =========================================================
% MATH PACKAGES
% =========================================================
\usepackage{amsmath,amssymb,mathtools}
\usepackage{physics} % convenient derivatives, abs{}, etc.
\usepackage{siunitx} % proper SI unit formatting
% =========================================================
% SPACING CONTROLS
% =========================================================
\usepackage{setspace}
% Choose ONE global line spacing option:
% \singlespacing
% \onehalfspacing
% \doublespacing
% Or define a custom line spacing:
% \setstretch{1.15}
% \setstretch{1.2}
% \setstretch{1.3}
% Paragraph indentation and spacing:
\setlength{\parindent}{0pt} % no paragraph indent
\setlength{\parskip}{0.5em} % vertical space between paragraphs
% Notes:
% - parindent controls the horizontal indent at a new paragraph
% - parskip controls vertical space between paragraphs
% - Usually use either indentation OR visible paragraph spacing, not both
% =========================================================
% LIST / ITEMIZE / ENUMERATE GLOBAL SPACING
% =========================================================
\usepackage{enumitem}
% Global default list settings:
\setlist{
topsep=0.4em, % space above and below the whole list
itemsep=0.2em, % space between items
parsep=0pt, % space between paragraphs within an item
partopsep=0pt, % extra space when list starts a new paragraph
leftmargin=2em % indentation from the left margin
}
% If you want different spacing for specific list types:
% \setlist[itemize]{itemsep=0.25em, topsep=0.4em}
% \setlist[enumerate]{itemsep=0.25em, topsep=0.4em}
% =========================================================
% HEADER / FOOTER CONTROLS
% =========================================================
\usepackage{fancyhdr}
\pagestyle{fancy}
\fancyhf{} % clear all header/footer fields
% Customize these as needed:
\lhead{Document Title or Course Name}
\rhead{Section / Topic / Author}
\cfoot{\thepage}
% Optional: remove the header line
% \renewcommand{\headrulewidth}{0pt}
% Optional: remove the footer line
% \renewcommand{\footrulewidth}{0pt}
% =========================================================
% OPTIONAL BUT VERY USEFUL PACKAGES
% =========================================================
\usepackage{xcolor} % colors
\usepackage{graphicx} % figures/images
\usepackage{booktabs} % nicer tables
\usepackage{array} % improved tables
\usepackage{caption} % caption formatting
\usepackage{hyperref} % clickable links and refs
% Hyperref setup
\hypersetup{
colorlinks=true,
linkcolor=blue,
urlcolor=blue,
citecolor=blue
}
% =========================================================
% SECTION TITLE SPACING (OPTIONAL)
% =========================================================
% If you want control over section spacing:
% \usepackage{titlesec}
% \titlespacing*{\section}{0pt}{1.0em}{0.4em}
% \titlespacing*{\subsection}{0pt}{0.8em}{0.3em}
% =========================================================
% SIUNITX OPTIONAL SETTINGS
% =========================================================
\sisetup{
per-mode=symbol,
detect-all
}
% =========================================================
% DOCUMENT STARTS
% =========================================================
\begin{document}
\title{Your Title Here}
\author{Your Name}
\date{\today}
\maketitle
This is a sample paragraph to test the formatting.
\section{Example Section}
Here is a paragraph after a section heading.
\begin{itemize}
\item First bullet item
\item Second bullet item
\item Third bullet item
\end{itemize}
\begin{enumerate}
\item First numbered item
\item Second numbered item
\end{enumerate}
An inline unit example: \SI{25}{W/m^2.K}
\end{document}