/*
   Hands-on Project 3-5
   Sung Kim | 6-14-26 | IST-239-W01
   Program: Cell Phone Sales Bar Chart

   Purpose:
   This stylesheet formats the bar chart table including layout, spacing,
   colors, and visual representation of sales data using colored table cells.

   Filename: styles.css
   Related: project03-05.html, project03-05.js
*/

/* Universal selector: applies box model fix */
* {
   -moz-box-sizing: border-box;
   -webkit-box-sizing: border-box;
   box-sizing: border-box;
}

/* Reset all default browser styling */
html, body, div, span, applet, object, iframe,
h1, h2, h3, h4, h5, h6, p, blockquote, pre,
a, abbr, acronym, address, big, cite, code,
del, dfn, em, img, ins, kbd, q, s, samp,
small, strike, strong, sub, sup, tt, var,
b, u, i, center,
dl, dt, dd, ol, ul, li,
fieldset, form, label, legend,
table, caption, tbody, tfoot, thead, tr, th, td,
article, aside, canvas, details, embed,
figure, figcaption, footer, header, hgroup,
menu, nav, output, ruby, section, summary,
time, mark, audio, video {
   margin: 0;
   padding: 0;
   border: 0;
   font-size: 100%;
   font: inherit;
   vertical-align: baseline;
}

/* Ensures HTML5 elements display correctly */
article, aside, details, figcaption, figure,
footer, header, hgroup, menu, nav, section {
   display: block;
}

/* Body layout */
body {
   line-height: 1;
   max-width: 960px;
   margin: 0 auto;
   background: white;
   font-family: Arial, Helvetica, sans-serif;
}

/* Remove list styling */
ol, ul {
   list-style: none;
}

/* Header styling */
header {
   background: #FFE373;
   width: 100%;
   color: black;
   font-size: 48px;
   text-align: center;
   line-height: 1.5em;
   border: 1px solid black;
}

/* Main content area */
article {
   width: 960px;
   text-align: center;
   background: #BFA230;
   padding-bottom: 20px;
   border: 1px solid black;
}

/* Table styling */
table {
   border-collapse: collapse;
   margin: 0 auto 20px;
}

/* Table caption styling */
table caption {
   font-size: 2em;
   font-weight: bold;
   color: #FFE373;
   text-shadow: 1px 1px black;
   margin: 20px 0;
}

/* Row header cells */
table th {
   font-weight: normal;
   text-align: right;
   width: 190px;
   background-color: #FFE373;
   padding-right: 10px;
}

/* Data cells (bar segments) */
table td {
   width: 12px;
   height: 25px;
}

/* Header row styling */
table thead td {
   font-size: 1.2em;
   text-align: center;
   padding-bottom: 10px;
}

/* Phone group 1 color */
td.group1 { background-color: hsl(299,75%,80%); }
/* Phone group 2 color */
td.group2 { background-color: hsl(299,75%,65%); }
/* Phone group 3 color */
td.group3 { background-color: hsl(299,75%,50%); }
/* Phone group 4 color */
td.group4 { background-color: hsl(299,75%,35%); }
/* Phone group 5 color */
td.group5 { background-color: hsl(299,75%,20%); }