/*  JavaScript 7th Edition
    Chapter 5
    Project 05-03

    Filename: styles.css
*/

/* General page reset and background styles */
body {
   background-color: #f4f4f9;
   font-family: Arial, sans-serif;
   line-height: 1.6;
   color: #333;
   margin: 0;
   padding: 0;
}

header {
   background-color: #2c3e50;
   color: #fff;
   padding: 20px;
   text-align: center;
}

header h1 {
   margin: 0;
   font-size: 2rem;
}

article {
   max-width: 800px;
   margin: 30px auto;
   background: #fff;
   padding: 30px;
   box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
   border-radius: 8px;
}

/* Styles for the dynamically built Table of Contents */
h2 {
   color: #2c3e50;
   border-bottom: 2px solid #ecf0f1;
   padding-bottom: 8px;
   margin-top: 25px;
}

#toc {
   background-color: #f8f9fa;
   border: 1px solid #e2e8f0;
   border-left: 5px solid #3498db;
   padding: 15px 15px 15px 40px;
   margin-bottom: 30px;
   border-radius: 4px;
   list-style-type: decimal;
}

#toc li {
   margin-bottom: 8px;
}

#toc a {
   color: #3498db;
   text-decoration: none;
   font-weight: bold;
   transition: color 0.2s ease-in-out;
}

#toc a:hover {
   color: #2980b9;
   text-decoration: underline;
}

/* Main content styling area */
#source_doc {
   margin-top: 20px;
}

#source_doc p {
   margin-bottom: 20px;
   text-align: justify;
}

hr {
   border: 0;
   height: 1px;
   background: #ccc;
   margin: 40px 0;
}