:root {
  --base-width: 1920;
  --inner-base-width: 1860;
  --padding-outside: calc(calc(53 / var(--base-width)) * 100vw);
  
  --gap-width: 20;
  --columns: 12;
  --all-gaps: calc(var(--gap-width) * calc(var(--columns) + 1));
  --grid-column-width: calc(calc(calc(calc(var(--inner-base-width) - var(--all-gaps)) / var(--columns)) / var(--inner-base-width)) * 100%);

  --gap: calc(calc(var(--gap-width) / var(--base-width)) * 100cqw);

  --grid-gap: calc(var(--gap-width) / var(--base-width) * 100%);

  --color-super-dark-blue: rgb(10, 32, 64);
}

@media (min-width: 768px) {
  .navbar {
    & nav {
      grid-template-columns: auto 1fr auto;
      grid-template-rows: 70px;
      max-width: calc(var(--base-width) * 1px);
      margin: auto;
      column-gap: 1%;
      row-gap: 0;
      container-type: inline-size;

      & >:first-child {
        padding-left: var(--padding-outside);
        justify-self: start;
      }

      & >:last-child {
        padding-right: var(--padding-outside);
        justify-self: end;
      }

      .nav-collapse {
        height: 100%;
      }

      & .nav {
        justify-content: end;
        row-gap: 0;
        column-gap: 0;
        height: 100%;

        & li {
          display: block;
          height: 100%;

          & a {
            font-size: calc(1700cqw / var(--base-width));
            font-weight: 500;
            color: white;
            display: block;
            align-content: center;
            height: 100%;
            padding: 0 1cqw;
            transition: 0.15s all ease-in-out;

            &:hover {
              background-color: rgba(255, 255, 255, 0.15);
            }
          }
        }
      }
    }
  }

  & .navbar-search {
    & .search-query {
      font-family: var(--font-secondary);
      font-size: 16px;
      color: white;
      background: rgba(255, 255, 255, 0.15);
      border: 1px solid rgba(255, 255, 255, 0.25);
      min-width: 140px;
      height: 40px;
      border-radius: 40px;
      padding: 0 10px 0 30px;
    }
  }

  .featured-title {
    font-size: 46px;
    margin: 3cqw;
  }

  .thumbnail {
    border: none;
    display: grid;
    grid-template-columns: 1fr;
    grid-template-rows: 1fr auto;

    & > img {
      opacity: 1;

      &:nth-child(1) {
        grid-column: 1 / 1;
        grid-row: 1 / 1;
      }

      &:nth-child(2) {
        grid-column: 1 / 1;
        grid-row: 1 / 1;
        opacity: 0;
      }
    }

    & > h3 {
      grid-column: 1 / 1;
      grid-row: 2 / 2;
    }
  }

  .vehicle-item {
    & h3 {
      position: initial;
      font-size: calc(2400cqw / var(--base-width));
      color: var(--color-dark-blue);
    }

    &:hover {
      & h3 {
        display: block;
      }

      .thumbnail {
        box-shadow: none;

        &:hover {
          box-shadow: none;
        }
      }
      
      &:has(img:nth-child(2)) {
        .thumbnail {
          box-shadow: none;

          & > img:nth-child(1) {
            opacity: 0;
          }

          & > img:nth-child(2) {
            opacity: 1;
          }
        }
      }
    }
  }

  ul.vehicleList.thumbnails {
    max-width: 1920px;
    margin: auto;
    container-type: inline-size;
    padding-bottom: 7cqw;
  }

  a#printInventoryBtn {
    border-radius: 5cqw;
  }

  select#selectMake {
    border-radius: 5cqw;
    background-image: none;
    line-height: initial;
    padding: 10px 35px;
    height: auto;
  }

  a#printInventoryBtn {
    background-color: white;
    border: 1px solid var(--color-dark-blue);
    color: var(--color-dark-blue);
    padding: 10px 35px;

    &:hover {
      background-color: var(--color-super-dark-blue);
      color: white;
    }
  }

  .select-wrapper {
    position: relative;
    display: inline-block;
    margin-right: 16px;

    .select-make {
      appearance: none;
      -webkit-appearance: none;
      -moz-appearance: none;
      padding-right: 30px;
    }

    .angle-icon {
      position: absolute;
      right: 36px;
      top: 50%;
      transform: translateY(-50%);
      pointer-events: none;
      color: white;
    }
  }

  .vehicle-footer-links {
    text-align: center;

    & a.button.btn-primary-blue {
      background-color: var(--color-dark-blue);
      border: 1px solid var(--color-dark-blue);
      color: white;
      padding: 10px 35px;
      border-radius: 5cqw;
      text-transform: uppercase;
      font-size: 17px;
      margin-right: 16px;

      &:hover {
        background-color: var(--color-super-dark-blue);
        color: white;
      }
    }

    & a.button.btn-secondary-white {
      background-color: white;
      border: 1px solid var(--color-dark-blue);
      color: var(--color-dark-blue);
      padding: 10px 35px;
      border-radius: 5cqw;
      text-transform: uppercase;
      font-size: 17px;

      &:hover {
        background-color: var(--color-super-dark-blue);
        color: white;
      }
    }
  }



  footer {
    padding: 140px 0 40px;
    color: white;
    display: grid;
    grid-template-columns: 1fr repeat(12, var(--grid-column-width)) 1fr;
    gap: var(--grid-gap);
    max-width: calc(var(--inner-base-width) * 1px);
    margin: auto;
    container-type: inline-size;

    a {
      color: white;

      &:visited,
      &:active,
      &:hover {
        color: white;
      }
    }

    & .logo-container {
      grid-column: 2 / span 2;
      grid-row-start: 1;
    }

    & nav {
      font-size: calc(1900cqw / var(--base-width));
      display: contents;

      & > ul {
        display: contents;

        & > li {
          display: grid;
          grid-template-columns: subgrid;
          grid-template-rows: subgrid;
          grid-row: 1 / span 2;

          & > ul {
            display: flex;
            flex-flow: column wrap;
          }
        }
      }

      & ul {
        list-style: none;
        margin: 0;
        padding: 0;
        grid-column-end: span 2;
        grid-row-start: 2;

        & li {
          margin: 0;
          padding: 0;
          text-transform: none;
          font-weight: normal;
          font-size: calc(1900cqw / var(--base-width));
          font-family: var(--font-main);

          & a,
          &:not(:has(a)) {
            font-family: var(--font-main);
            display: block;
            padding: calc(var(--gap) / 2);
            margin-left: calc(var(--gap) * -0.5);
          }

          & a:hover {
            background-color: rgba(255, 255, 255, 0.1);
          }
        }

        &.footer-menu {
          & > li {
            

            &:nth-child(1) {
              grid-column-start: 6
            }

            &:nth-child(2) {
              grid-column-start: 8
            }

            &:nth-child(3) {
              grid-column-start: 10
            }

            &:nth-child(4) {
              grid-column-start: 12
            }
          }
        }
      }

      & .menu-category {
        text-transform: uppercase;
        font-weight: bold;
        font-size: calc(1700cqw / var(--base-width));
        font-family: var(--font-secondary);
        margin: 0;
        padding: 0;
        grid-row-start: 1;
        align-self: end;
      }
    }

    & > ul {
      grid-column: 2 / -2;
      list-style: none;
      display: flex;
      flex-flow: row wrap;
      gap: var(--gap);
      margin: 0;
      font-size: calc(1600cqw / var(--base-width));
    }

    .social-media {
      & ul {
        display: flex;
        flex-flow: row wrap;
        justify-content: space-between;

        & a {
          font-size: calc(3000cqw / var(--base-width));
        }
      }
    }
  }

  #gform_wrapper_3 {
    background: white;
    
    & > * {
      max-width: 1920px;
      margin: auto;
    }
  }
}
