/* following is global removal of pre-defined set margin or padding */
* {
  margin: 0;
  padding: 0;
}

/* following is the main page styling - e.g. background-color */
html,
body {
  min-width: 290px;
  background-color: beige;
  color: #4d4e53;
  font-family: 'Open Sans', Arial, sans-serif;
  line-height: 1;
  margin: 0;
}

/* following sets space when linking to header from navbar, so as to not cover header */
html {
  scroll-padding-top: 8.5rem;
}

.ipf-logo {
  display: flex;
  justify-content: center;
  width: 100%;
  height: auto;
  margin: 30px 0 30px 0;
}

/* following is the navbar section, starting with styling of first header which is in navbar */
.firstHeader {
  background-image: linear-gradient(60deg, #e41013 15%, gray 30%, #00225a 10%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  padding: 15px;
  border-top: solid 1px rgba(0, 22, 22, 0.4);
  border-bottom: solid 1px white;
  border-left: solid 1px white
}

#navbar {
  border-right: solid 2px rgba(0, 22, 22, 0.4);
}

#navbar,
header ul {
  margin: 0;
  padding: 0;
  width: 250px;
  text-align: center;
  position: fixed;
  height: 100%;
}

#navbar ul {
  height: 100%;
  margin: 0;
  padding: 0;
  width: 250px;
  text-align: center;
  position: fixed;
  height: 100%;
  overflow: auto;
}

#navbar ul li {
  color: #4d4e53;
  background-color: #33265f;
  border-top: solid 1px white;
  border-bottom: solid 1px white;
  border-left: solid 1px white;
}

#navbar ul li:nth-child(1) {
  /* background-color: #e41013; */
  background-image: linear-gradient(45deg, #e41013 0%, #e41013 25%, #33265f 80%, #33265f 100%);
}

#navbar a:nth-child() {
  color: #e41013;
}

#navbar ul li:nth-child(6) {
  border-bottom: solid 2px rgba(0, 22, 22, 0.4);
}

#navbar a {
  padding: 16px;
  color: #fff;
  text-decoration: none;
  cursor: pointer;
  display: block;
}

#navbar a:hover {

  color: white;
  background-color: #e41013;
  text-decoration: none;
  cursor: pointer;
  line-height: 2;
}

#navbar li:hover {
  background-color: #e41013;
}

#navbar a:hover {
  color: white;
}

/* following is main-doc section styling */
#main-doc {
  text-align: left;
  /* position: relative;
  word-break: normal;
  word-wrap: normal; */
  line-height: 1.5;
  padding: 20px;
  /* margin: 10px; */
  margin-left: 300px;
  /* margin-right: 30px; */
  border-radius: 5px;
  height: 100%;
}

main {
  overflow-y: auto;
}

#main-doc header {
  color: black;
  margin: 10px;
  text-align: center;
  font-size: 1.3em;
  font-weight: thin;
}

#main-doc header {
  text-align: left;
  margin: 0px;
}

section article {
  color: #4d4e53;
  margin: 15px;
  font-size: 0.96em;
}

code.tab {
  margin-left: 50px;
}

span.tab2 {
  margin-left: 40px;
}

/* following is 1st image of Guidelines of Knurling distances - Under Equip. & Specifications */
.lifting-images {
  display: flex;
  justify-content: flex-start;
  margin-top: 25px;
  margin-bottom: 25px;
  padding: 0;
}

/* following is styling for 2nd image on page, which has the 3 powerlifting lifts */
#three-lifts {
  width: 95%;
  max-width: 400px;
}

/* following is styling of 1st table of the 3 major lifts: Squat, Bench press, and Deadlift */
.table-container {
  margin: .5em auto;
  width: 100%;
  border-collapse: collapse;
}

.flex-table-header {
  background-color: rgba(200, 200, 200, 0.8);
}

td {
  border: 1px solid black;
  padding: 0.5em;
}

th {
  padding: 0.5em;
  border: 1px solid black;
}

.red-strike,
.red-span {
  color: red;
}

/* following is styling for 2nd table on site. Table consistis of referees signals for the required 3 lifts. */
.table-container-2 {
  border-collapse: collapse;
  margin-top: 15px;
}

/* the following is styling changes for smaller monitors & mobile devices & tablets */
@media only screen and (max-width: 1000px) {

  .ipf-logo {
    display: flex;
  }

  .main-logo {
    max-width: 400px;
    text-align: center;
  }
}

@media only screen and (max-width: 840px) {
  .ipf-logo {
    display: flex;
  }

  .main-logo {
    max-width: 400px;
    text-align: center;
  }
}

@media only screen and (max-width: 778px) {

  #navbar {
    border: 0;
  }

  .firstHeader {
    display: none;
    border: 0;
  }

  #navbar ul {
    width: 100%;
    height: auto;
    position: fixed;
    text-align: center;
    margin: 0;
    padding: 0;
    top: 0;
    border-right: 0;
    list-style-type: none;
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
  }

  #navbar ul li {
    width: 48%;
    background-color: #33265f;
  }

  #navbar ul li:nth-child(1) {
    border-top: solid 1px white;
    border-right: solid 1px white;
  }

  #navbar ul li:nth-child(2) {
    border-top: solid 2px white;
    border-left: solid 1px white;
  }

  #navbar ul li:nth-child(3) {
    border-right: solid 1px white;
  }

  #navbar ul li:nth-child(4) {
    border-left: solid 1px white;
  }

  #navbar ul li:nth-child(5) {
    border-right: solid 1px white;
  }

  #navbar ul li:nth-child(6) {
    border-bottom: solid 1px white;
    border-left: solid 1px white;
  }

  /* @media (hover: hover) and (pointer: fine) {
    #navbar li,
    #navbar a: none;
  } */

  #main-doc {
    margin-left: 0px;
    margin-top: 160px;
    margin-left: 15px;
  }
}

@media only screen and (max-width: 778px) {
  #knurling {
    width: 300px;
  }
}

@media only screen and (max-width: 430px) {

  .ipf-logo {
    display: flex;
  }

  .main-logo {
    max-width: 280px;
    text-align: center;
  }

  /* following changes width of images while mobile 430px or less */
  #knurling {
    width: 240px;
  }

  /* following changes navbar font-size in mobile 430px or smaller */
  #navbar li {
    font-size: .9em;
  }

  #navbar a {
    margin: 0;
    padding: 10px;
  }

  /* following styles main-logo image in mobile 430px wide or narrower*/
  #main-doc {
    margin: 90px 8px 30px 8px;
  }

  /* following is styling of 1st table of the 3 major lifts: Squat, Bench press, and Deadlift */
  .table-container,
  td {
    margin: .5em auto;
    width: 100%;
    border-collapse: collapse;
  }

  .first {
    background-color: red;
    color: #fff;
    display: flex;
    order: 1;
  }

  .second {
    background-color: #fff;
    display: flex;
    order: 2;
  }

  .third {
    background-color: #382a62;
    color: #fff;
    display: flex;
    order: 3;
  }
}

@media only screen and (max-height: 400px) {
  html {
    scroll-padding-top: 3em;
  }

  #main-doc {
    margin: 50px 8px 30px 8px;
  }

  li {
    margin: 0;
    padding: 0;
  }

  #navbar li {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    max-width: 100px;
    margin: 0;
    padding: 10px 2px;
    font-size: .9em;
  }

  #navbar li:nth-child(1) {
    border-left: 0;
  }

  #navbar li a {
    margin: 0;
    padding: 0;
  }

  nav {
    display: flex;
    align-items: center;

  }

  #navbar {
    border: 0;
  }

  .ipf-logo {
    display: block;
    margin-left: 50px;
  }

  .firstHeader {
    display: none;
  }
}