/* Global Styles */
html, body {
  margin: 0;
  padding: 0;
}

::selection {
  background: #F04F23;
  color: #D1D3D4;
}

body {
  background: #fff;
  color: #231F20;
  font-size: 18px;
  line-height: 1.2;
  font-family: "Spectral", serif;
  font-weight: 400;
  font-style: normal;
}

/* Typography */
h1, h2, h3, p.cta, .menu-items li, .case strong {
  font-family: "Teko", sans-serif;
  font-optical-sizing: auto;
  font-weight: 700;
  font-style: normal;
  text-transform: uppercase;
  margin: 0;
  line-height: 1.1;
  color: #F04F23;
  width: 100%;
  text-align: center;
}

h1::before, h1::after,
h2::before, h2::after {
  content: "";
  display: table;
}

h1::before, h2::before {
  margin-bottom: -0.085em;
}

h1::after, h2::after {
  margin-top: -0.228em;
}

h2 {
  font-size: 34px;
}

h3 {
  font-size: 24px;
}

a {
  color: #F04F23;
  text-decoration: none;
}

a:hover {
  color: #B23817;
}

p {
  margin-top: 0.5em;
}

/* Layout */
.contain {
  max-width: 960px;
  margin: 0 auto;
}

/* Header */
header {
  width: 100%;
  margin-bottom: 60px;
  background: url("img/header.jpg") center no-repeat;
  background-size: cover;
  border-bottom: 48px solid #F04F23;
}

header h1 {
  font-size: 36px;
  color: #D1D3D4;
  margin-bottom: -38px;
}

header .contain {
  height: 280px;
  display: flex;
  flex-direction: row;
  justify-content: center;
  align-items: flex-end;
}

header .logo {
  margin-bottom: -90px;
  margin-left: -40px;
}

header .logo img {
  max-width: 220px;
  height: auto;
}

/* Welcome Section */
#welcome {
  margin-bottom: 20px;
}

#welcome .contain {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
}

#welcome .text {
  max-width: 620px;
}

#welcome .photo img {
  max-width: 275px;
  height: auto;
  border-radius: 50%;
}

/* Services Section */
#services {
  background: url("img/safety-tread.jpg") top repeat-x;
  color: #fff;
  padding: 30px 0;
  margin-bottom: 30px;
  text-align: center;
}

#services .servicelist {
  margin: 30px auto;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
}

#services .service {
  max-width: 33%;
  text-align: center;
}

#services .service h3 {
  color: #fff;
}

#services .service p {
  max-width: 220px;
  margin: 0 auto;
}

#services .service img {
  max-width: 160px;
  height: auto;
  border-radius: 50%;
  margin-bottom: 10px;
}

#services p.cta {
  font-size: 30px;
}


/* About Section */
#about {
  margin-bottom: 20px;
}

#about .contain {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
}

#about .text {
  max-width: 620px;
}

#about .photo img {
  max-width: 275px;
  height: auto;
  border-radius: 50%;
}

.certifications {
  display: flex;
  justify-content: center;
  align-items: center;
}

.certifications img {
  max-width: 33%;
  max-height: 120px;
  margin: 0 10px;
}

/* Rates Section */
#rates {
  background: url("img/safety-tread.jpg") top repeat-x;
  color: #fff;
  padding: 30px 0;
  margin-bottom: 30px;
  text-align: center;
}

#rates .ratelist {
  margin: 30px auto;
  max-height: 500px;
  display: flex;
  flex-direction: column;
  flex-wrap: wrap;
  justify-content: flex-start;
  align-content: space-between;
  align-items: flex-start;
}

#rates .rate {
  max-width: 45%;
  text-align: left;
  margin-bottom: 10px;
}

#rates h3 {
  color: #fff;
}

/* Contact Section */
#contact {
  padding-top: 30px;
}

#contact .contain {
  padding-bottom: 30px;
  display: flex;
  justify-content: center;
  align-items: center;
}

#contact .logo img {
  max-width: 220px;
  height: auto;
}

#contact .text {
  margin-left: 30px;
  text-align: center;
}

#contact p {
  font-family: "Teko", sans-serif;
  font-optical-sizing: auto;
  font-weight: 700;
  font-style: normal;
  text-transform: uppercase;
  margin: 20px auto;
  line-height: 1.2;
  font-size: 30px;
}

#contact .legal {
  font-size: 16px;
  margin-top: 20px;
}

.social img {
  max-width: 54px;
  height: auto;
  margin: 0 10px;
}

#contact::after,
#contact.secondary::before {
  content: "";
  background: url("img/safety-tread.jpg") top repeat-x;
  height: 80px;
  display: block;
}

/* Seconary Page */

#moreservices .servicelist,
#cases .caselist {
  display: flex;
  flex-direction: column;
  flex-wrap: nowrap;
  justify-content: flex-start;
  align-content: stretch;
  align-items: center;
}

#moreservices .servicelist .service,
#cases .caselist .case {
  display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    justify-content: flex-start;
    align-content: stretch;
    align-items: center;
    margin:20px auto;
}

#moreservices .servicelist .service img,
#cases .caselist .case img {
  max-width:160px;
  height:auto;
  border-radius:50%;
  margin-right:45px;
}

#moreservices h3 {
  color:#231F20;
  text-align: left;
}

.case strong {
  font-size:24px;
  color:#231F20;
}

#contact.secondary .contain {
  padding-top:30px;
}

/* Menu */
.nav-container {
  position: relative;
}

.hamburger-menu {
  position: absolute;
  top: 20px;
  right: 20px;
  z-index: 100;
  cursor: pointer;
}

.hamburger-icon {
  width: 30px;
  height: 20px;
  position: relative;
}

.hamburger-icon span {
  display: block;
  position: absolute;
  height: 3px;
  width: 100%;
  background: #fff;
  border-radius: 3px;
  transition: all 0.3s ease;
}

.hamburger-icon span:nth-child(1) { top: 0; }
.hamburger-icon span:nth-child(2) { top: 8px; }
.hamburger-icon span:nth-child(3) { top: 16px; }

.hamburger-icon.active span:nth-child(1) {
  transform: rotate(45deg);
  top: 8px;
}

.hamburger-icon.active span:nth-child(2) {
  opacity: 0;
}

.hamburger-icon.active span:nth-child(3) {
  transform: rotate(-45deg);
  top: 8px;
}

.menu-items {
  display: none;
  position: absolute;
  top: 40px;
  right: 20px;
  background: #fff;
  padding: 0;
  list-style-type: none;
  min-width: 150px;
}

.menu-items li {
  border: 2px solid #231F20;
  font-size: 24px;
}

.menu-items li a {
  display: block;
  padding: 5px 20px;
  text-decoration: none;
  color: #231F20;
}

.menu-items li:hover {
  background: #231F20;
}

.menu-items li:hover a {
  color: #fff;
}

.menu-items.active {
  display: block;
}

/* Media Queries */
@media (max-width: 1080px) {
  .contain {
    max-width: 90%;
  }

  header .contain {
    height: auto;
    flex-direction: column;
    justify-content: space-around;
    align-items: center;
  }

  header .logo {
    margin: 20px auto;
  }

  header {
    border-bottom: none;
    margin-bottom: 30px;
    overflow:hidden;
  }

  header h1 {
    margin-bottom: 0;
    background: #F04F23;
    width: 95%;
    padding: 10px 100px;
    font-size: 28px;
  }

  header .logo img {
    max-width: 180px;
  }

  #welcome .contain,
  #about .contain {
    flex-direction: column;
    align-items: center;
  }

  #services {
    background-size: cover;
  }

  #services .servicelist {
    flex-direction: column;
    align-items: center;
  }

  #services .service {
    max-width: 100%;
    margin: 20px auto;
  }

  #services .service p {
    max-width: none;
  }

  #about .photo img {
    width: 275px;
    max-width: 95%;
  }

  #rates .ratelist {
    max-height: none;
    flex-wrap: nowrap;
    align-items: center;
  }

  #rates .rate {
    max-width: 600px;
  }

  #rates {
    background-size: cover;
  }

  #contact .contain {
    flex-direction: column;
  }

  #contact .logo img {
    max-width: 160px;
  }

  #contact .text {
    margin-left: 0;
  }

  #contact p {
    font-size: 22px;
  }
}

@media (max-width: 800px) {
#moreservices .servicelist .service,
#cases .caselist .case {
    flex-direction: column;
}

#moreservices .servicelist .service img,
#cases .caselist .case img {
  max-width:180px;
  margin-right:0;
}

#moreservices h3 {
  text-align: center;
  margin-top:20px;
}
}

@media (max-width: 420px) {
  .certifications {
    flex-wrap: wrap;
  }

  .certifications img {
    max-width: 80%;
    margin: 20px auto;
  }
}
