I Want to create this layout:
With the title in the black box, using titlesec. But I just have got this result:
And I can not move down the number page...
Here is my code:
\documentclass{book}
\usepackage[a4paper,right=1cm, left=1cm,bottom=1cm,top=1cm]{geometry}
\pagestyle{plain}
\usepackage[pagestyles]{titlesec}
\usepackage{lipsum}
\pagestyle{plain}
\renewpagestyle{plain}{
\widenhead[1cm][1cm]{1.5cm}{1.5cm}
\sethead[\LARGE\bfseries\thepage][][]{}{}{\LARGE\bfseries\thepage}%
}
\newpagestyle{main}{
\widenhead[1cm][1cm]{1.5cm}{1.5cm}
\sethead[\LARGE\bfseries\thepage][][]{}{}{\LARGE\bfseries\thepage}%
}
\begin{document}
\pagestyle{main}
\chapter{Here}
\section{here}
\lipsum[1-20]
\chapter{Here}
\lipsum[1-20]
\end{document}
I tried solutions with background, but I could not prevent it to run into empty pages and chapter (plain) pages.


