@import url('/assets/css/fonts.css');
@import url('/assets/css/forms.css');

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  /* Change default 16px font size to 10px.
   * The 62.5% trick makes it easier to scale values without
   * worrying about the type of device used to view the content.
   */
  font-size: 62.5%;
}

:root {
  --light: #ffffff;
  --dark: #141414;
  --md-gray: #616161;
  --dk-gray: #424242;
  --blog-card: #212121;
  --lime: #adea50;
  --dk-lime: #3b5b0b;
  --cyan: #38d6df;
  --dk-cyan: #0e5558;
  --purple: #a36df5;
  --dk-purple: #4c0cac;

  /*-- forms --*/
  --form-text: #374151;
  --form-border: #d1d5db;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  /* Change default 16px font size to 10px.
   * The 62.5% trick makes it easier to scale values without
   * worrying about the type of device used to view the content.
   */
  font-size: 62.5%;
}

body {
  background-color: var(--dark);
  color: var(--light);
  font-family: 'Raleway', sans-serif;
  font-size: 1.6rem;
}

/* This is how we push the footer to the bottom */
/* the footer needs the property: "margin-top: auto;" */
.flex-wrapper {
  display: flex;
  min-height: 100vh;
  flex-direction: column;
  justify-content: flex-start;
}

/* --- Utility Classes --- */

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.hidden {
  display: none;
}

.container {
  width: 100%;
  margin-left: auto;
  margin-right: auto;
  /*padding: 2.4rem;*/
}

main,
.inner-container {
  width: 100%;
  max-width: 1200px;
  margin-left: auto;
  margin-right: auto;
  padding: 2.4rem;
}

ul .no-style {
  li { list-style-type: none; }
}

.cols-1 {
  display: grid;
  grid-template-columns: repeat(1, minmax(0, 1fr));
}

.cols-2 {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.cols-3 {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

@media (max-width: 992px) {
  .cols-2,
  .cols-3 {
    display: grid;
    grid-template-columns: repeat(1, minmax(0, 1fr));
    gap: 4rem;
  }
}

/* --- Header --- */

.header__dark {
  background-color: var(--dark);
  padding-bottom: 1.8rem;
  position: sticky;
  top: 0;
}

header {
  width: 100%;
  padding: 2.4rem;
  z-index: 100;

  .container {
    max-width: 1200px;
    margin: 0 auto;
  }

  .navbar {
    width: 100%;
    left: 0;
    z-index: 95;
    position: sticky;
    top: 0;

    div {
      display: flex;

      .navbar-left {
        width: 100%;
        display: flex;
        justify-content: start;
        align-items: center;

        #menu__toggle {
          opacity: 0;
        }
        #menu__toggle:checked + .menu__btn > span {
          transform: rotate(45deg);
        }
        #menu__toggle:checked + .menu__btn > span::before {
          top: 0;
          transform: rotate(0deg);
          background-color: var(--purple);
        }
        #menu__toggle:checked + .menu__btn > span::after {
          top: 0;
          transform: rotate(90deg);
          background-color: var(--purple);
        }
        #menu__toggle:checked ~ .menu__box {
          left: 0 !important;
        }
        .menu__btn {
          position: fixed;
          top: 35px;
          left: 24px;
          width: 26px;
          height: 26px;
          cursor: pointer;
          z-index: 1;
        }
        .menu__btn > span,
        .menu__btn > span::before,
        .menu__btn > span::after {
          display: block;
          position: absolute;
          width: 100%;
          height: 2px;
          background-color: var(--purple);
          transition-duration: .25s;
        }
        .menu__btn > span::before {
          content: '';
          top: -8px;
        }
        .menu__btn > span::after {
          content: '';
          top: 8px;
        }

        .menu__box {
          display: block;
          position: fixed;
          top: 0;
          right: -100%;
          width: 100%;
          height: 100%;
          margin: 0;
          padding: 6rem 0;
          background-color: var(--dark);
          box-shadow: 2px 2px 6px rgba(0, 0, 0, .4);
          transition-duration: .25s;

          .menu__container {
            width: 100%;
            max-width: 80rem;
            margin: 2.5rem auto;

            .menu__inner {
              width: 100%;
              max-width: 80rem;
              display: grid;
              align-items: start;
              grid-template-columns: repeat(2, minmax(0, 1fr));
              gap: 6rem;

              div {
                display: grid;
                grid-template-columns: repeat(1, minmax(0, 1fr));

                .heading a {
                  margin-top: 2.5rem;
                  font-weight: 900;
                  font-size: 4rem;
                  line-height: 1.1em;
                  text-decoration: none;
                  color: var(--light);
                }

                .menu-item__title a {
                  text-decoration: none;
                  color: var(--light);
                  font-size: 3.2rem;
                  font-weight: 300;
                }

                .menu-item__sub-title a {
                  text-decoration: none;
                  color: var(--light);
                  font-size: 2.3rem;
                  font-weight: 300;
                  margin-left: 2rem;
                }

                .menu-item__subtext { font-weight: 300; }

                .menu__products .menu-item__subtext { color: var(--cyan); }
                .menu__webdev .menu-item__subtext { color: var(--lime); }
                .menu__custom .menu-item__subtext { color: var(--purple); }

                ul {
                  display: grid;
                  align-items: center;
                  list-style: none;
                  margin-left: 0;

                  li {
                    /*display: block;*/
                    padding: 1.5rem 0;
                    color: var(--light);
                    text-decoration: none;
                    transition-duration: .25s;
                  }
                }
              }

              ul.socials {
                width: fit-content;
                display: grid;
                grid-template-columns: repeat(3, minmax(0, 1fr));
                list-style: none;
                gap: 2rem;
                margin: 2rem 0;

                li {
                  background-color: var(--cyan);
                  padding: 1.6rem;
                  border-radius: 0.4rem;
                  a {
                    text-decoration: none; color: var(--dark);
                    svg { width: 2.8rem; height: 2.3rem; }
                  }
                }
              }
            }
          }
        }
      }

      a {
        img.logo {
          margin-top: -1rem;
          margin-left: 2rem;
          width: 15rem;
        }
      }

      .primary-nav {
        width: 100%;
        display: none;
        justify-content: end;
        align-items: center;

        ul {
          display: inline-flex;
          align-items: center;
          list-style: none;
          li {
            padding: 0.4rem 1rem;
            border-radius: 0.6rem;

            a {
              color: var(--light);
              text-decoration: none;
              text-transform: uppercase;
              font-weight: 600;
            }

            a:hover {
              color: var(--cyan);
            }
          }
        }
      }
    }

    .work-with-us {
      display: none;
    }
  }
}

@media (min-width: 768px) {
  header {
    .navbar {
      div {
        .primary-nav {
          display: flex;
        }
      }

      .work-with-us {
        display: flex;
        justify-content: end;

        a.btn {
          background-color: var(--dark);
          color: var(--light);
          text-transform: uppercase;
          font-weight: 500;
          text-decoration: none;
          border: 2px solid var(--light);
          padding: 1.5rem 2rem;
          margin-right: 1rem;
        }

        a.btn:hover {
          color: var(--lime);
          border-color: var(--lime);
        }
      }
    }
  }
  .menu__inner {
    gap: 2rem;
  }
  .services-cta {
    display: none;
  }
}

@media (max-width: 992px) {
  header {
    & .navbar {
      & div {
        & .navbar-left {
          & .menu__box {
            padding-top: 2.2rem;
            & .menu__container {
              width: 100%;
              margin: 1rem auto;
              height: 100%;
              overflow-y: scroll;

              .menu__inner {
                width: 100%;
                height: 100%;
                margin: 1.5rem auto;
                display: grid;
                grid-template-columns: repeat(1, minmax(0, 1fr));
                gap: 1.8rem;
                align-items: center;

                div {
                  width: fit-content;
                  margin: 0 auto;

                  .heading a {
                    margin-top: -2rem;
                  }
                }
                .socials {
                  grid-column: span 1;
                  margin: 2rem auto 6rem;
                }
              }
            }
          }
        }
      }
    }
  }
}
/* --- Footer --- */
footer {
  background-color: var(--dark);
  color: var(--light);
  /* need this to keep footer at the bottom */
  margin-top: auto;
  padding: 2.4rem;

  .container {
    width: 100%;
    max-width: 1200px;
    display: grid;
    align-items: center;
    grid-template-rows: repeat(1, minmax(0, 1fr));

    .links {
      display: flex;
      align-items: center;
      justify-content: space-between;

      .socials {
        a {
          text-decoration: none;
          color: var(--light);
          svg {
            display: inline;
            width: 3.8rem;
            height: 3.8rem;
            fill: currentColor;
          }
          svg.twitter {
            width: 3.2rem;
            height: 3.6rem;
          }
        }
      }

      .cta {
        display: grid;
        grid-template-rows: repeat(1, minmax(0, 1fr));
        justify-content: left;
        width: fit-content;

        p {
          text-transform: revert;
          font-weight: 300;
          font-size: 1.6rem;
          margin-bottom: 1.5rem;
        }

        #subscribe-form {
          display: inline-flex;
          gap: 0.3rem;
          width: 100%;
          margin-bottom: 0;

          input[type="text"] {
            padding: 1rem 1.2rem;
            line-height: 1.6rem;
            font-size: 1.4rem;
          }

          input[type="submit"] {
            color: var(--light);
            background-color: var(--purple);
            border: none;
            padding: 0.5rem 1rem;
            border-radius: 0.4rem;
          }
        }
      }

      .infos {
        .legal {
          display: flex;
          justify-content: left;
          width: fit-content;

          a {
            color: var(--light);
            text-decoration: none;
            padding: 0 0.5rem;
            font-weight: 500;
          }
        }
      }
    }
  }
}

@media (max-width: 992px) {
  footer .container {
    justify-content: center;

    .links {
      display: grid;
      gap: 2rem;

      .socials, .site, .infos {
        justify-self: center;
      }

      .cta p {
        text-align: center;
      }
    }
  }
}

/* ==================== */
/* --- Main Content --- */
main {
  h1 {
    text-align: center;
    font-size: 5.4rem;
  }
  .intro {
    max-width: 80rem;
    margin: 2rem auto 4rem;
    text-align: center;
    font-size: 1.8rem;
    font-weight: 300;
    line-height: 2.8rem;
  }
}

@media (max-width: 600px) {
  main h1.well-met { font-size: 3.5rem; }
}

/*-- Our Services --*/
.services {
  margin-bottom: 6rem;

  div {
    align-items: center;
    justify-items: center;
    text-align: center;

    /* a { */
    div {
      text-decoration: none;

      svg {
        width: 10rem;
        height: 10rem;
        margin-bottom: 1rem;
      }

      h3 {
        text-align: center;
        font-size: 2.4rem;
        font-weight: 300;
        color: var(--light);
      }

      h4 {
        text-align: center;
        font-size: 1.6rem;
        font-weight: 300;
      }
    }
  }
  .products {
    svg { color: var(--cyan); fill: currentColor; }
    .services__products { color: var(--cyan); }
  }
  .webdev {
    svg { color: var(--lime); fill: currentColor; }
    .services__webdev { color: var(--lime); }
  }
  .custom {
    svg { color: var(--purple); fill: currentColor; }
    .services__custom { color: var(--purple); }
  }
}

.services-cta {
  max-width: 80rem;
  margin: 2rem auto 4rem;
  text-align: center;
  font-size: 1.8rem;
  font-weight: 300;
  line-height: 2.8rem;

  a.btn {
    background-color: var(--dark);
    color: var(--light);
    text-transform: uppercase;
    font-weight: 500;
    text-decoration: none;
    border: 2px solid var(--light);
    padding: 1.5rem 2rem;
    margin-right: 1rem;
  }
}

/*-- About Roadie --*/
.team {
  margin: auto auto 4rem;
  gap: 4rem;
  width: 100%;
  max-width: fit-content;

  #steven {
    border: 1px solid var(--cyan);
    border-radius: 0.4rem;
  }
  #nancy {
    border: 1px solid var(--lime);
    border-radius: 0.4rem;
  }

  #steven,
  #nancy {
    display: grid;
    justify-items: center;
    padding: 1.5rem;
    gap: 3.5rem;

    img {
      width: 100%;
      max-width: 35rem;
      border-radius: 0.4rem;
    }
    p {
      width: 100%;
      max-width: 33rem;
      text-align: center;
      font-size: 1.6rem;
      line-height: 2.4rem;
      font-weight: 300;
      margin-top: -2rem;
    }
  }
}

/*-- Contact Us --*/
.contact {
  gap: 6rem;
  margin: 6rem auto;

  form {
    textarea {
      font-family: 'Raleway', sans-serif;
      font-weight: 500;
      min-height: 12rem;
    }
    input[type="submit"] {
      padding: 1.5rem 2.3rem;
      background-color: var(--lime);
      color: var(--dark);
      border: none;
      border-radius: 0.4rem;
      font-size: clamp(1.9rem,1.85345rem + 0.133vw,2rem);
    }
  }

  p {
    font-size: clamp(1.6rem,1.50655rem + 0.267vw,1.8rem);
    text-align: center;
    font-weight: 300;
  }

  h2 {
    font-weight: 600;
    font-size: 2.4rem;
    text-align: center;
    padding: 2rem 0;
  }

  ul {
    width: fit-content;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    list-style: none;
    gap: 2rem;
    margin: 2rem auto;

    li {
      background-color: var(--cyan);
      padding: 1.6rem;
      border-radius: 0.4rem;
      a {
        text-decoration: none; color: var(--dark);
        svg { width: 2.8rem; height: 2.8rem; }
      }
    }
  }
}

/* ===== BLOG ===== */

.blog {

  img {
    width: 100%;
    vertical-align: middle;
  }

  button.card_btn {
    margin-top: 2rem;
    padding: 0.8rem;
    font-size: 14px;
    text-transform: uppercase;
    border-radius: 4px;
    font-weight: 400;
    display: block;
    width: 100%;
    cursor: pointer;
    border: 1px solid rgba(255, 255, 255, 0.35);
    background-color: rgba(255, 255, 255, 0.2);
    text-align: center;
    text-decoration: none;
  }

  .cards {
    display: flex;
    flex-wrap: wrap;
    list-style: none;
    margin: 4rem 0;
    padding: 0;
  }

  .cards_item {
    display: flex;
    padding: 1rem;
  }

  ul li:nth-child(3n + 1) {
    .card_image { background: var(--cyan); }
    .card_content { background-color: var(--blog-card); }
    .card_title, .card_text { color: var(--light); }
    button.card_btn a { color: var(--light); }
  }
  ul li:nth-child(3n + 2) {
    .card_image { background: var(--lime); }
    .card_content { background-color: var(--blog-card); }
    .card_title, .card_text { color: var(--light); }
    button.card_btn a { color: var(--light); }
  }
  ul li:nth-child(3n + 3) {
    .card_image { background: var(--purple); }
    .card_content { background-color: var(--blog-card); }
    .card_title, .card_text { color: var(--light); }
    button.card_btn a { color: var(--light); }
  }

  .card {
    border-radius: 0.4rem;
    box-shadow: 0 20px 40px -14px rgba(0, 0, 0, 0.25);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    a { text-decoration: none; width: 70%; }
  }

  .card_image {
    position: relative;
    display: grid;
  }

  .overlay {
    position: absolute;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
  }

  .card_title {
    color: var(--dark);
    font-size: 1.9rem;
    font-weight: 600;
    letter-spacing: 1.2px;
    text-transform: capitalize;
    margin-top: 2rem;
    text-align: center;
  }

  .card_content {
    padding: 1rem 1.6rem;
    height: 100%;
    display: grid;
    grid-template-columns: repeat(1, minmax(0, 1fr));
    div:last-child {
      display: flex;
      align-items: flex-end;
      height: 100%;
    }
  }

  .card_text {
    color: var(--dark);
    font-size: 1.4rem;
    line-height: 1.5;
    margin-bottom: 2rem;
    font-weight: 400;
    display: flex;
    align-items: center;
    height: 100%;
  }

  @media (min-width: 40rem) {
    .cards_item {
      width: 50%;
    }
  }

  @media (min-width: 56rem) {
    .cards { gap: 0.333%; }
    .cards_item {
      width: 33%;
    }
    ul li:nth-child(9n + 1),
    ul li:nth-child(9n + 6),
    ul li:nth-child(9n + 8) {
      .card_image { background: var(--cyan); }
      .card_content { background-color: var(--blog-card); }
      .card_title, .card_text { color: var(--light); }
      button.card_btn a { color: var(--light); }
    }
    ul li:nth-child(9n + 2),
    ul li:nth-child(9n + 4),
    ul li:nth-child(9n + 9) {
      .card_image { background: var(--lime); }
      .card_content { background-color: var(--blog-card); }
      .card_title, .card_text { color: var(--light); }
      button.card_btn a { color: var(--light); }
    }
    ul li:nth-child(9n + 3),
    ul li:nth-child(9n + 5),
    ul li:nth-child(9n + 7) {
      .card_image { background: var(--purple); }
      .card_content { background-color: var(--blog-card); }
      .card_title, .card_text { color: var(--light); }
      button.card_btn a { color: var(--light); }
    }
  }
}

.post__header-wrap {
  width: 100%;
  background: var(--dark);
  color: var(--light);
  /*position: fixed;*/
  /*top: 120px;*/

  .post-inner {
    text-align: center;
  }
}

.post-wrapper {
  width: 100%;
  .post-inner {
    width: 100%;
    max-width: 120rem;
    margin: 0 auto;
  }
}

.article {
  background: var(--light);
  color: var(--dark);
  font-size: 1.8rem;
}

.article__header {
  padding-bottom: 2rem;

  div {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;

    svg { padding: 0 2rem; height: 15rem; }
    h1 { min-width: fit-content; padding: 1.5rem; }
  }

}

.article__content {
  padding: 4.5rem 2rem;

  div { padding: 1.5rem 0; }

  p { padding: 1.5rem 0; }
}

.who-are-we {
  div { margin: -2rem auto; }

  img {
    padding: 1.2rem;
    width: 100%;
    max-width: 30rem;
    height: auto;
  }
  img.left-align {
    float: left;
    display:inline-block;
  }
  img.right-align {
    float: right;
    display:inline-block;
  }
}

@media (max-width: 600px) {
  img {
    min-width: 100%;
  }
  img.right-align, img.left-align { float: unset; padding: 1.2rem 0; }
}
