/* Shared tab navigation and tab content structure. */
.tabbed_content {
  position: relative;
  width: 100%;

  & .content_tabs {
    position: relative;
    max-width: 1024px;
    margin: 10px auto;
    display: grid;
    grid-auto-flow: row dense;
    grid-gap: 5px;
    grid-template-columns: repeat(2, 1fr);
    user-select: none;
    line-height: 0;
    font-size: 0;

    &.full_width {
      width: 100%;
      max-width: 100%;
    }

    &.rows_2 {
      grid-template-columns: repeat(2, 1fr);
    }

    &.rows_3 {
      grid-template-columns: repeat(3, 1fr);
    }

    &.rows_4 {
      grid-template-columns: repeat(4, 1fr);
    }

    &.rows_5 {
      grid-template-columns: repeat(5, 1fr);
    }

    &.rows_6 {
      grid-template-columns: repeat(6, 1fr);
    }

    &.rows_7 {
      grid-template-columns: repeat(7, 1fr);
    }

    &.rows_8 {
      grid-template-columns: repeat(8, 1fr);
    }

    &.rows_9 {
      grid-template-columns: repeat(9, 1fr);
    }

    &.rows_10 {
      grid-template-columns: repeat(10, 1fr);
    }

    & .content_tab {
      position: relative;
      display: inline-block;
      box-sizing: border-box;
      padding: 5px 10px 5px 50px;
      border: 1px solid var(--balter-primary-color);
      border-left-width: 3px;
      border-radius: 0;
      border-top-color: transparent;
      border-left-color: transparent;
      border-right-color: transparent;
      background-color: rgba(255, 255, 255, 0.4);
      color: #333333;
      cursor: pointer;
      font-size: 16px;
      font-weight: 600;
      line-height: 25px;
      text-align: left;
      text-shadow: 2px 5px 1px rgba(232, 232, 232, 0.43);
      transition: 0.2s all ease;
      vertical-align: top;

      & i,
      & img {
        position: absolute;
        display: block;
        left: 7px;
        top: 2px;
        width: 30px;
        height: 30px;
        vertical-align: text-bottom;
        transition: 0.3s all ease;
      }

      @media only screen and (max-width: 400px) {
        width: calc(100% - 10px);
      }

      &:hover {
        border-color: var(--balter-primary-color);
        background-color: rgba(255, 255, 255, 0.6);
      }

      &.active {
        cursor: default;
        border-color: var(--balter-primary-color);
        background-color: var(--balter-white);
        color: var(--balter-black-1);
        text-shadow: 0 0 0 rgba(0, 0, 0, 0);

        & img,
        & i {
          left: 2px;
          top: -5px;
          width: 35px;
          height: 35px;
          color: var(--balter-white);
          filter: drop-shadow(3px 3px 2px rgba(0, 0, 0, 0.5));
        }
      }

      &.disabled_by_person_type {
        display: none !important;
        transform: scale(0);
      }

      &.hidded {
        display: none !important;
      }

      &.rows_2 {
        grid-column: span 2;
      }

      &.rows_3 {
        grid-column: span 3;
      }

      &.rows_4 {
        grid-column: span 4;
      }

      &.rows_5 {
        grid-column: span 5;
      }
    }

    &.hidded {
      display: none;
    }
  }

  & .content_structure {
    position: relative;
    font-size: 14px;
    line-height: 24px;

    & .tab {
      position: relative;
      display: none;

      & .intab_title {
        margin: 0 0 10px;
        padding: 10px;
        border-left: 4px solid #6BA553;
        background-color: var(--balter-white);
        font-size: 18px;
        font-weight: 700;
        line-height: 30px;

        & img {
          position: relative;
          display: inline-block;
          height: 30px;
          margin-right: 10px;
          overflow: hidden;
          padding: 0;
          border-radius: 0 4px 4px 0;
          background-color: var(--balter-white);
          color: #333333;
          text-align: center;
          vertical-align: top;
        }

        & .text {
          position: relative;
          display: inline-block;
          min-width: 40px;
          margin: 4px 10px;
          font-size: 16px;
          line-height: 20px;
          text-align: center;
          vertical-align: top;
        }
      }

      &.active {
        display: block;
      }

      &.disabled_by_person_type {
        display: none !important;
        transform: scale(0);
      }

      & .tabbed_nav {
        position: relative;
        margin: 20px 20px 0;

        & .tabbed_nav__prev {
          position: relative;
          float: left;
          padding: 0 20px;
          border-radius: 5px;
          background-color: #FFF6DE;
          cursor: pointer;
          font-size: 20px;
          line-height: 40px;
        }

        & .tabbed_nav__next {
          position: relative;
          float: right;
          padding: 0 20px;
          border-radius: 5px;
          background-color: #D8FFDD;
          cursor: pointer;
          font-size: 20px;
          line-height: 40px;
        }
      }
    }
  }
}
