I am trying to attain the following style of customized horizontal rule for my document.
I tried the following LATEX code.
\documentclass{article}
\usepackage[utf8]{inputenc}
\usepackage[top=1cm, left=1cm, right=1cm, bottom=1.5cm]{geometry}
\usepackage{xcolor,lipsum}
\begin{document}
\lipsum[1]\\
{\color{gray} \rule{4.85 cm}{2 pt}}\ {\color{lightgray} \rule{\linewidth}{2 pt}}
\lipsum[1]
\end{document}
This gives the following satisfying result but I am unable to break the rule from crossing the line width. How to solve this issue? Is there any other way to get this type of horizontal rule?