/* http://meyerweb.com/eric/tools/css/reset/ 
   v2.0 | 20110126
   License: none (public domain)
*/

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;
}
/* HTML5 display-role reset for older browsers */
article, aside, details, figcaption, figure, 
footer, header, hgroup, menu, nav, section {
	display: block;
}
body {
	line-height: 1;
}
ol, ul {
	list-style: none;
}
blockquote, q {
	quotes: none;
}
blockquote:before, blockquote:after,
q:before, q:after {
	content: '';
	content: none;
}
table {
	border-collapse: collapse;
	border-spacing: 0;
}

/* End of reset */




:root {  /* setting custom variables for easy uniform colors and fonts, and for easy changing through javascript */
    --win-lose1:#fffc3a;
    --win-lose2:#8c8f00;
    --white: #FFFFFF;
    --lt-gray: #F8F8F8;
    --gray: #999;
    --drk-gray: #333333;
    --lt-green: #90EE90;
    --drk-green: #006400;
    --lt-blue: #ADD8E6;
    --drk-blue: #00008B;
    --red: #FF0000;
    --yellow: #FFFF00;
    --orange: #FFA500;
    --purple: #800080;
    --pink: #FF69B4;
    --teal: #008080;
    --lime: #00FF00;
    --cyan: #00FFFF;
    --magenta: #FF00FF;
    --lt-brown: #D2B48C;
    --drk-brown: #5C4033;
    --black: #222222;
    --primary-font: Arial, sans-serif;
    --secondary-font: Helvetica, sans-serif;
}

body { /* general styles for the page */
    background-color: var(--lt-gray);
    margin: 0;
    font-family: var(--primary-font);
    width: 1280px;
    margin-left: auto;
    margin-right: auto;
    color: var(--black);
}


/*heading styles*/
h1{
    font-size: 3rem;
    font-weight: bold;
    text-align: center;
}

header {
    background-color: var(--lt-gray);
    padding: 20px;
}

header nav {
    display: block;
    justify-content: space-between;
    align-items: center;
}

header nav ul {
    list-style: none;
    padding: 0;
    display: flex;
    gap: 20px;
    justify-content: center;
    width: auto;
}

/* some nav settings */
header nav ul li a{
    display: block;
    text-decoration: none;
    padding:10px;
    width:150px;
    font-weight: bolder;
    font-size: 1.5rem;
    background-color: var(--lime);
    color: var(--drk-gray);
    border: 4px dotted var(--drk-blue);
}

/* some header nav styles and placement */
header nav ul li{
    align-items: center;
    text-align: center;
}

header button{
    width: 60px;
    height: 60px;
    border-radius: 50%;
    font-size: 2rem;
    background-color: var(--gray);

    position: fixed;
    right:20px;
    top:20px;
    border: 3px solid var(--black);

    display: flex;
    align-items: center;
    justify-content: center;
}

/* color mode changer*/
#theme-toggle {
    padding: 10px;
    cursor: pointer;
}

/* image under the navigation */
#header-image{
    width: 1280px;
}


/* padding for sections */
#home, #products, #game, #contact #company-description{
    padding: 40px 20px;
}

/* headings for sections */
#products h2, #game h2, #contact h2, #company-description h2{
    text-align: center;
    font-weight: bold;
    font-size: 2rem;
    padding: 20px 0;
}

/* company description styles */
#company-description{
    background-color: var(--lt-brown);
    margin-top: -5px;
}
#company-description p{
    padding: 30px;
    padding-top: 0;
    text-align: center;
    width: 800px;
    justify-content: center;
    margin: 0 auto;
    font-size: 1.5em;
}

/* product controls section */
#product-controls {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-bottom: 20px;
}

/* switching product display buttons */
.product-btn {
    padding: 10px 20px;
    cursor: pointer;
    font-size: 1.5rem;
    font-weight: bold;
    background-color: var(--lt-blue);
}

/* sets a grid for displaying products */
#product-display {
    text-align: center;
    display: grid;
    grid:
        "img head" 120px
        "img body" 130px
        "img list" 200px
        /300px 620px;
    gap: 10px;
    justify-content: center;
}

/* image should fit in it's section, a little taller */
#product-image {
    width: 300px;
    height: 500px;
    object-fit: cover;
    justify-self: end;
    grid-area: img;
}

/* product name style */
#product-name {
    height: 100px;
    grid-area: head;
    font-size: 2.3rem;
    font-weight: bold;
    letter-spacing: .05em;
    padding-top: 50px;
}

/* product description style */
#product-description {
    height: auto;
    grid-area: body;
    font-size: 1.5em;
    margin-left: 15px;
}

/* The unordered list that applies when viewing obstacles */
#obstacle-list{
    margin-top: -50px;
    font-size: larger;
    text-align: left;
    padding-left: 30px;
}

/* styles for each element on the unordered list */
#obstacle-list li{
    margin-top: 40px;
}

/* just for the obstacles, not the obstacle description */
#obstacle-list strong{
    font-weight: bold;
}

/* game section with a bit more than just single color */
#game {
    text-align: center;
    background-color: var(--cyan);
    background: linear-gradient(to right,
      var(--lt-gray) calc(50% - 600px),   /* left side outer color */
      var(--cyan) calc(50% - 100px),   /* start inner color */
      var(--cyan) calc(50% + 100px),   /* end inner color */
      var(--lt-gray) calc(50% + 600px)    /* right side outer color */
    );
}

/* all paragraph text */
#game p{
    padding: 5px;
    font-size: 1.2rem;
}

/* paragraph text sibling to another*/
#game p + p{
    padding-bottom: 20px;
}

/* input box for guess*/
#guess-input {
    width: 100px;
    padding: 5px;
}

/* submit button for game styles */
#guess-submit {
    padding: 5px 10px;
    cursor: pointer;
    margin-bottom: 10px;
}

/* making a circular oval that allows for a more flashy win or lose showing, colors change based on win lose or wrong input */
#game p:last-of-type{
    visibility: hidden;    /*keeps the space there, or can use display: none; but that needs to be under flex or important */
    display: flex;
    justify-content: center;
    align-items: center;
    width: 400px;
    height: 100px;
    margin: 0 auto;
    margin-top: 20px;
    color: #000;
    
    background: radial-gradient(
        ellipse at center,
        var(--win-lose1) 30%,
        var(--win-lose2) 100%
    );
    border-radius: 50%; 
}


/* contact form styles */
#contact-form {
    max-width: 600px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

#contact-form label,  #contact-form legend{
    font-weight: bold;
}

#contact-form legend{
    padding-bottom: 8px;
}

#contact-form input, #contact-form textarea {
    padding: 8px;
    border: 2px solid #ccc;
}

#contact-form textarea {
    resize: vertical;
    height: 80px; /* comment area size */
}

#contact-form fieldset {
    border: none;
    padding-bottom: 10px;
}

#contact-form button {
    padding: 10px;
    cursor: pointer;
}

/* for changing the color of the star * in labels */
#contact-form label span, #contact-form legend span{
    color: var(--red);
}

/* user feedback under input box styles */
.input-error{
    margin-top: -8px;
    margin-bottom: 5px;
}

/* gives red border to any input box that fails during submit by giving this class*/
#contact-form .error-input {
    border: 2.5px solid var(--red) !important;
}

/* displays the result, being accepted or needing to fix the form will be displayed with the same style */
#form-result {
    text-align: center;
    line-height: 25px;
    margin: auto;
    margin-top: 15px;
    padding-bottom: 20px;
    font-weight: bolder;
    max-width: 650px;
    align-self: center;
}

/* footer styles */
footer {
    background-color: var(--lime);
    text-align: center;
    padding: 10px;
    color: #000;
}