h1, h2, h3, h4, h5, h6 {
  margin-top: 0;
}

iframe {
  border: 0;
}

.d-none {
  display: none;
}

/*NOTE: Favour Bootstrap's sr-only over this.*/
/*ADA -- American Disability Act -- from https://www.w3.org/WAI/tutorials/forms/labels/#note-on-hiding-elements*/
.ada-label {
  border: 0;
  clip: rect(0 0 0 0);
  height: 1px;
  margin: -1px;
  overflow: hidden;
  padding: 0;
  position: absolute;
  width: 1px;
}

.ada-unique-content {
  display: none;
}

/*legal terms text*/
.legal-terms {
  p {
    font-style: italic;
    font-size: 11px;
    text-align: center;
  }
}

.plain-button {
  display: inline-block;
  background: none;
  border: none;
  padding: 0;
}

.error-explanation {
  padding: 7px;
  margin-bottom: 20px;
  h2 {
    display: none;
  }
  ul {
    padding-left: 1em;
    li {
      font-size: 12px;
      list-style: square;
    }
  }
}

.easy-autocomplete-container {
  left: 0;
  position: absolute;
  width: 100%;
  z-index: 3;

  ul {
    .eac-category {
      font-weight: bold;
      font-style: normal;
    }

    li {
      padding: 10px;
      margin: 0;

      .eac-item {
        .autocomplete-value {
          text-decoration: underline;
        }

        .autocomplete-count {
          float: right;
        }

        display: block;
        word-break: normal;

        & > a > i {
          height: 23px;
        }
      }
    }
  }
}

/*header and footer*/
.block-layout {
  color: #ffffff;
  margin: 0;
  position: relative;
  a, h1, h2, h3, h4, h5, h6 {
    color: #ffffff;
  }
  a:hover {
    color: #ffffff;
  }

  .block-header-social-links {
    text-align: right;
    a {
      display: inline-block;
      margin-left: 2em;
      text-decoration: none;
      color: #ffffff;
    }
    i {
      font-size: 28px;
    }
  }

  .block-logo {
    img {
      max-height: 50px;
    }
  }
}

.block-header {
  position: relative;

  .block-header-social-links {
    padding: 15px 0;
    min-height: 60px;
  }

  .block-logo {
    min-height: 60px;
    position: relative;
    img {
      vertical-align: middle;
      position: absolute;
      top: 0;
      bottom: 0;
      margin: auto;
    }
  }
}

.block-footer {
  padding: 40px 0;
}

.block-full-width-iframe > iframe {
  width: 100% !important;
}

.block-image-text {
  top: 50%;
  -webkit-transform: translateY(-50%);
  -moz-transform: translateY(-50%);
  -ms-transform: translateY(-50%);
  -o-transform: translateY(-50%);
  transform: translateY(-50%);
  vertical-align: top;
}

/*cover*/
.block-image-cover {
  .block-image-text {
    position: relative;
    top: 50%;
  }
}

/*uncropped, full width*/

.block-image-uncropped-full-width {
  position: relative;

  .block-image-text {
    position: absolute;
    text-align: center;
    width: 100%;
    left: 0;
    z-index: 5;
  }
  &:after {
    content: '\A';
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
  }
}

.image-uncropped-full-width {
  width: 100%;
}

.block-user-html {
  .img-circle {
    max-width: 100%;
  }
  .social-links {
    display: inline-block;
  }
}

.on-page-invisible-image {
  display: none;
}

/*page rows*/
.page-row {
  .page-row-container {
    position: relative;
  }

  .container-fluid {
    .block-image {
      margin-left: -15px;
      margin-right: -15px;
    }
  }

  .block-placeholder {
    text-align: center;
    img {
      max-width: 100%;
    }
  }

  .post-block-image {
    img {
      width: 100%;
    }
  }

  .page-block {
    img {
      max-width: 100%;
      max-height: 100%;
    }

    iframe {
      max-width: 100%;
      max-height: 100%;
    }
  }
}

.page-row:last-child {
  padding-bottom: 0;
}

/*blocks*/
.linked-block-image {
  cursor: pointer;
}

.block-image-cover {
  background-size: cover;
  height: 540px;
  background-position: center;
  background-repeat: no-repeat;
}

.job-component-icon-and-text {
  > i {
    width: 1.75rem;
  }
}

.block-links {
  .block-part-title {
    font-weight: bold;
  }

  .block-part-link {
    .thumbnail-url {
      max-height: 150px;
      max-width: 100%;
    }
  }
}

.block-posts {
  .post {
    margin-bottom: 34px;
    h3.post-title {
      margin-top: 0;
      margin-bottom: 0;
      color: inherit;
    }
    span.post-field {
      margin-right: 10px;
    }
    a:hover {
      text-decoration: none;
    }
  }
}

.block-post-search-form {
  .fix-autocomplete {
    padding: 0 !important;
    margin: 0;
    border-width: 0;
  }
}

.block-jobs {
  &.block-jobs-fixed-height {
    max-height: 700px;
    overflow-y: scroll;
    overflow-x: hidden;
    padding-right: 20px;
  }

  .job {
    margin-bottom: 34px;
    h3.job-title {
      margin-top: 0;
      margin-bottom: 0;
      color: inherit;
    }
    span.job-field {
      margin-right: 10px;
    }
    a:hover {
      text-decoration: none;
    }

    .job-favourited {
      margin-top: 10px;
      display: inline-block;
    }
  }

  .jobs-list {
    .job-hidden-field {
      display: none;
    }
  }

  table {
    .job-favourited {
      float: right
    }
  }
}

.job-component-details {
  font-size: 90%;
  .job-component-list {
    ul {
      list-style: none;
      padding-left: 0;
      margin-left: 0;
      margin-bottom: 0;
    }
    li,a {
      transition: none;

      &.collapsing {
        transition: none;
      }
    }
    .more, .less {
      font-weight: bold;
      .fa {
        margin-right: 0.25rem;
      }

    }
  }
}

.block-job-description {
  .job-description-controls {
    margin-bottom: 20px;

    .btn {
      padding: 5px 10px !important;
      line-height: normal;
    }
  }
  .job-position-description-document {
    margin-bottom: 10px;
  }
  .job-video-top, .job-video-bottom {
    margin-bottom: 10px;
    margin-top: 15px;
  }
}

.block-job-search-results {
  .clear-filters-button {
    margin-bottom: 5px;
  }

  .job-search-filter-groups {
    .list-unstyled {
      max-height: 13em;
      overflow-y: scroll;
      scrollbar-width: thin;
      position: relative;
    }

    .list-unstyled::-webkit-scrollbar {
      visibility: hidden;
      width: 7px;
      border-radius: 7px;
      background: rgb(209, 209, 208);
    }

    .list-unstyled::-webkit-scrollbar-thumb {
      visibility: hidden;
      background: rgb(125, 125, 125);
      width: 7px;
      border-radius: 7px;
      height: 30px;
    }

    .list-unstyled:hover::-webkit-scrollbar {
      visibility: inherit;
    }

    .list-unstyled:hover::-webkit-scrollbar-thumb {
      visibility: inherit;
    }

    padding: 1em calc(1em - 3px);
    h4 {
      font-weight: bold;
      font-size: 16px;
      margin-bottom: 5px;
      padding-left: 3px;
    }

    .search-filter{
      padding-left: 3px;
    }

    label {
      font-size: 14px;
      font-weight: normal;
      overflow: hidden;
      white-space: nowrap;
      max-width: calc(100% - 40px);
      text-overflow: ellipsis;
      padding-left: 3px;
    }

    li {
      margin-bottom: 0.0em;
    }

    &[data-show-counts=false] {
      label {
        max-width: inherit;
      }
    }
  }

  .job-search-tags {
    ul {
      margin: 0;
      padding: 0;
    }

    .search-tag {
      a {
        margin-left: 5px;
        color: white;
      }
    }

    .label {
      line-height: inherit;
    }

    li {
      padding: 0;
      margin: 0 10px 15px 0;
      display: block;
      float: left
    }
  }

  .job-search-results {
    .job-search-control {
      margin-bottom: 15px;
    }

    .job-search-results-sub-search-actions {
      flex-wrap: nowrap;
    }

    .job-search-results-active-filters {
      margin-bottom: 1rem;

      .active-filter {
        margin-left: 0.25rem;
      }

      .close-button {
        padding-left: 0.25rem;
        cursor: pointer;
      }
    }

    .job-search-filter {
      margin-bottom: 30px;
    }

    .job-search-results-filter {
      flex: 1;
      max-width: 100%;
    }

    .job-search-collapse {
      font-size: 12px;
    }

    table, .table-counts {
      font-size: 90%;
    }
    .pagination {
      margin-top: 0;
    }

    .job-search-filter-groups {
      width: 14em;
    }

    .job-search-results-department, .job-search-results-employment-type, .job-search-results-category, .job-search-results-category-group, .job-search-results-location-group, .job-search-results-location {
      width: 14em;
      ul {
        margin: 0;
        padding: 0;

        li {
          list-style: none;
          margin: 0;
          padding: 0;
        }
      }
    }

    .job-search-results-location {
      ul {
        transition: none;

        &.collapsing {
          transition: none;
        }
      }
      .job-search-results-location-toggle {
        float: right;
        &.collapsed {
          i:before {
            content: "\f106";
          }
        }
      }
    }

    .job-search-dropdown-filters {
      padding: 0.75em 0;

      .filters-list {
        padding-left: 0;
        list-style: none;
      }

      .filters-list > li {
        display: inline-block;
        padding-right: 5px;
        padding-left: 0;
      }

      .job-search-filter-selectize {
        width: 150px;
        font-size: 13px;
      }
    }

    .job-search-results-content {
      .table > tbody > tr {
        cursor: pointer;
      }
    }

    .job-search-results-card-col {
      margin-bottom: 30px;
      display: flex;
      align-items: stretch;
    }

    .job-search-results-card {
      flex: 1;
    }
  }

  .job-search-results-dropdown {
    margin: 0 .05rem .75rem auto;

    .job-search-results-sort-by-dropdown {
      font-size: 0.9rem;
      float: right;
    }
  }
  .job-search-results-dropdown:focus-within .dropdown-menu {
    display: block;
  }
}

@media (max-width: 767px) {
   .job-search-results.job-search-top-filters, .job-search-results.job-search-side-filters {
    .job-search-results-location {
      width: inherit;
      .job-search-results-location-toggle {
        float: right;
        i:before {
          transition: all 0.5s;
        }
        &.active i {
          -webkit-transform: rotate(180deg);
          -moz-transform: rotate(180deg);
          transform: rotate(180deg);
        }
      }
    }

     .job-search-dropdown-filters {
       .filters-list {
         padding: 0;
         margin: 0;
       }

       .filters-list > li {
         display: block;
         padding: 0 0 10px 0;

         select {
           width: 100%;
         }
       }
     }

    .job-search-results-content {
      .job-search-results-title {
        font-size: 110%;
      }

      /* Force table to not be like tables anymore */
      table, thead, tbody, th, td, tr {
        display: block;
      }

      .table > thead > tr {
        border: 1px solid #ccc;
      }

      .table > tbody > tr {
        border-bottom: 1px solid #ccc;
        padding: 0.5em 0;
      }

      .table > thead > tr > th {
        position: absolute;
        top: -9999px;
        left: -9999px;
      }

      .table > tbody > tr > td {
        border: none;
        position: relative;
        padding: 0;
      }

      .table > tbody > tr > td:before {
        position: absolute;
        top: 6px;
        left: 6px;
        width: 45%;
        padding-right: 10px;
        white-space: nowrap;
      }
    }
  }
}

.team-member-bio {
  small {
    display: block;
    margin: 0 auto;
  }
  .team-member-image {
    max-width: 100%;
    width: 100px;
    height: 100px;
  }
  .name {
    display: block;
  }

  .title {
    display: block;
  }

  .bio p, .bio ul, .bio li {
    text-align: justify;
  }
}

/*media queries*/
@media (max-width: 767px) {
  .block-layout {
    .block-header-social-links {
      a {
        margin-left: 10px;
      }
    }
  }
}

@media (min-width: 767px) {
  .col-md-6, .col-md-4, .col-md-8 {
    .block-image-cover {
      height: 400px;
    }
  }
}

@media (max-width: 1199px) {
  .block-image-cover {
    height: 440px;
  }
}

@media (max-width: 767px) {
  .block-image-cover {
    height: 260px;
  }

  .col-md-4, .col-md-8 {
    .block-image-cover {
      margin-bottom: 30px;
    }
  }

  /*not working - would like to stop the margin on the last one*/
  .col-md- *:last-child {
    .block-image-cover {
      margin-bottom: 0;
    }
  }
}

@media (min-width: 768px) {
  .job-search-results-dropdown-filter-col {
    flex: 0 0 20%;
    max-width: 20%;
  }

  .job-search-results-card-col {
    flex: 0 0 50%;
    max-width: 50%;
  }
}

#kiosk_mode_active {
  position: fixed;
  top: 0;
  right: 0;
  z-index: 1000;
  padding: 2px;
  border-radius: 0;
  text-align: center;
}

.visible-in-kiosk-mode {
  visibility: hidden;
}

.kiosk-mode {
  .visible-in-kiosk-mode {
    visibility: visible;
  }
  .hide-in-kiosk-mode {
    display: none;
  }
}

.tracking-inactive {
  .hide-when-tracking-inactive {
    display: none;
  }
}

.btn-linkedin-connect {
  background: none;
  color: inherit;
  border: none;
  padding: 0;
  font: inherit;
  cursor: pointer;
  outline: inherit;
}