@charset "utf-8";

/*
   New Perspectives on HTML5 and CSS3, 7th Edition
   Tutorial 3
   Case Problem 1
   
   Layout styles for Slate and Pencil Tutoring
   Author: Angel Guzman
   Date:   2/28/2025
   
   Filename: sp_layout.css

*/

/* Window and Body Styles */

html {
   height: 100%;
}

body {
   width: 95%;
   min-width: 640px;
   max-width: 960px;
   margin-left: auto;
   margin-right: auto;
   min-height: 100%;
}

header, nav, ul, li, a {
   box-sizing: border-box;
}

/* Row Styles */

.row::after {
   content: "";
   display: table;
   clear: both;
}

/* Page Header Styles */

header img {
   display: block;
   width: 70%;
   float: left;
}

header nav {
   float: left;
   width: 30%;
   padding-left: 2%;
   padding-right: 2%;
}

header nav a {
   display: block;
   width: 100%;
}

/* Horizontal Navigation List Styles */

nav.horizontal li {
   display: block;
   float: left;
   width: 12.5%;
}

/* Topics Styles */

ul#topics li {
   display: block;
   float: left;
   width: 20%;
   margin-left: 0%;
   margin-right: 1.5%;
}

ul#topics li:first-of-type {
   margin-left: 7.75%;
}

ul#topics li:last-of-type {
   margin-right: 7.75%;
}

ul#topics li img {
   display: block;
   width: 50%;
   margin-left: auto;
   margin-right: auto;
}

/* HR Styles */

hr {
   width: 50%;
}

/* Customer Comment Styles */

ul#comments {
   width: 75%;
   margin-left: auto;
   margin-right: auto;
   margin-bottom: 40px;
}

ul#comments li {
   display: block;
   width: 50%;
   float: left;
   margin-bottom: 30px;
}

ul#comments li img {
   display: block;
   width: 20%;
   float: left;
   margin-left: 5%;
   margin-right: 5%;
}

ul#comments li p {
   float: left;
   width: 70%;
}

/* Footer Styles */

footer {
   clear: both;
}
