\documentclass[12pt]{book}

\usepackage{amsmath}
\usepackage{amsfonts}
\usepackage{amssymb}
\usepackage{amsthm}
\usepackage{tikz}
\usepackage{tikz-cd}
\usepackage{color}
\usepackage{framed}
\usepackage{eurosym}
\usepackage{url}
\usepackage[foot=1.5cm, hmargin=2.5cm,vmargin=2.5cm, includefoot]{geometry}
\usepackage{xspace}
\usepackage{longtable}
\usepackage{fancyhdr}
\usepackage{caption}
\usepackage{bookmark}
\usepackage{lettrine}
\usepackage{graphicx}
\usepackage{float}
\usepackage{hyperref}
\usepackage{makeidx}
\usepackage[nottoc,notlot,notlof,notindex,section]{tocbibind}

\hypersetup{colorlinks=true, linkcolor=[rgb]{1,0,0}}

\begin{document}

\title{sub-sup}
\author{Matteo}

\maketitle

\tableofcontents

\section{sub-sup}

$a_{b}$

$a^{c}$

$a_{b}^{c}$

$a_{(b)}$

$a^{(c)}$

$a_{(b)}^{(c)}$

\end{document}
