/*
.contact {
  background: #57556E;
}

.agenda {
  background: #DE0048;
}

.sorties {
  background: #158AB5;
}

.kids {
  background: #8FCB00;
}

.parents {
  background: #77007E;
}

.announcements {
  background: #FF8000;
}
*/

.navigation {
  .--active {

    &.accueil,
    &.contact {
      .navigation__link {
        .navigation__label {
          color: var(--contact-color) !important;
        }
      }
    }

    &.agenda {
      .navigation__link {
        .navigation__label {
          color: var(--agenda-color) !important;
        }
      }
    }

    &.sorties {
      .navigation__link {
        .navigation__label {
          color: var(--sorties-color) !important;
        }
      }
    }

    &.kids {
      .navigation__link {
        .navigation__label {
          color: var(--kids-color) !important;
        }
      }
    }

    &.parents {
      .navigation__link {
        .navigation__label {
          color: var(--parents-color) !important;
        }
      }
    }

    &.announcements {
      .navigation__link {
        .navigation__label {
          color: var(--announcements-color) !important;
        }
      }
    }
  }

  :not(.--active) {
    &.contact {
      &:hover {
        .navigation__link {
          .navigation__label {
            color: var(--contact-color);
          }
        }
      }
    }

    &.agenda {
      &:hover {
        .navigation__link {
          .navigation__label {
            color: var(--agenda-color);
          }
        }
      }
    }

    &.sorties {
      &:hover {
        .navigation__link {
          .navigation__label {
            color: var(--sorties-color);
          }
        }
      }
    }

    &.kids {
      &:hover {
        .navigation__link {
          .navigation__label {
            color: var(--kids-color);
          }
        }
      }
    }

    &.parents {
      &:hover {
        .navigation__link {
          .navigation__label {
            color: var(--parents-color);
          }
        }
      }
    }

    &.announcements {
      &:hover {
        .navigation__link {
          .navigation__label {
            color: var(--announcements-color);
          }
        }
      }
    }

    &.accueil,
    &.contact,
    &.agenda,
    &.sorties,
    &.kids,
    &.parents,
    &.announcements {
      &.navigation__link {
        background: transparent;
      }

      &.navigation__line_item {
        display: none;
      }
    }
  }

  .navigation__list {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: flex-end;
    padding: 0;
    gap: 32px;

    .navigation__item {
      list-style: none;

      .navigation__link {
        display: block;
        padding: 8px 0;
        text-align: center;
        text-decoration: none;

        .navigation__label {
          color: var(--e-global-color-text);
          transition: color .0s ease-in-out;
          white-space: nowrap;
        }
      }
    }
  }
}


.navigation-class {
  .navigation__line {
    display: flex;
    flex-direction: column;

    .navigation__line_item {
      display: flex;
      flex-direction: column;
      align-items: stretch;
      justify-content: center;
      width: 100%;
      min-height: 12px;
      border-radius: 8px;

      &.contact {
        .navigation__line_list {
          .navigation__line_item_category {
            &.--active {
              background-color: #57556E;
            }

            &:not(.--active) {
              background-color: #57556E;

              &:hover {
                background-color: #57556E;
              }
            }
          }
        }
      }

      &.agenda {
        .navigation__line_list {
          .navigation__line_item_category {
            &.--active, &:hover {
              background-color: #DE0048;
            }

            &:not(.--active) {
              background-color: #DE0048;

              &:hover {
                background-color: #DE0048;
              }
            }
          }
        }
      }

      &.sorties {
        .navigation__line_list {
          .navigation__line_item_category {
            &.--active {
              background-color: #54C0EB;
            }

            &:not(.--active) {
              background-color: #158AB5;

              &:hover {
                background-color: #54C0EB;
              }
            }
          }
        }
      }

      &.kids {
        .navigation__line_list {
          .navigation__line_item_category {
            &.--active {
              background-color: #81E12B;
            }

            &:not(.--active) {
              background-color: #8FCB00;

              &:hover {
                background-color: #81E12B;
              }
            }
          }
        }
      }

      &.parents {
        .navigation__line_list {
          .navigation__line_item_category {
            &.--active {
              background-color: #ab61af;
            }

            &:not(.--active) {
              background-color: #77007E;

              &:hover {
                background-color: #ab61af;
              }
            }
          }
        }
      }

      &.announcements {
        .navigation__line_list {
          .navigation__line_item_category {
            &.--active {
              background-color: #FFAE5E;
            }

            &:not(.--active) {
              background-color: #FF8000;

              &:hover {
                background-color: #FFAE5E;
              }
            }
          }
        }
      }

      img {
        width: 100%;
        height: auto;
        /* border-radius: 8px; */
      }

      .navigation__line_list {
        display: grid;
        padding: 0;
        grid-auto-flow: column;
        width: 100%;
        min-height: 125px;
        gap: 2px;
        user-select: none;

        .navigation__line_item_category {
          list-style: none;
          display: flex;
          flex-direction: column;
          align-items: center;
          justify-content: center;
          padding: 6px;
          transition: background-color .3s ease-in-out;
          cursor: pointer;

          a {
            height: 100%;
            width: 100%;
            text-decoration: none;
            display: flex;
            flex-direction: column;
            align-items: center;
            justify-content: center;
            gap: 6px;
            font-family: var(--general-font-family);

            &:hover {
              color: #DE0048;
            }

            span {
              font-size: .9rem;
              font-weight: bold;
              text-align: center;
              color: #FCFCFC;
              white-space: nowrap;
            }

            .navigation__line_icon {
              background-color: #F5F6F7;
              mask-repeat: no-repeat;
              mask-size: contain;
              mask-position: center;
              background-size: cover;
              background-repeat: no-repeat;
              background-position: center;
              height: 70%;
              width: 70%;
            }
          }

          &:not(.category) {
            justify-content: center;

            a {
              span {
                color: #FCFCFC;
              }
            }
          }

          &.category {
            a {
              span {
                text-transform: uppercase;

              }
            }
          }
        }
      }

      .navigation__line_category_name {
        display: flex;
        flex-direction: row;
        justify-content: space-evenly;
        align-items: center;
        min-height: 36px;


        li {
          list-style: none;
          text-transform: uppercase;

          &.--active, &:hover {
            border-top: 2px solid transparent;
            border-bottom: 2px solid #FCFCFC;
          }

          a {
            font-size: .8rem;
            font-weight: bold;
            text-align: center;
            color: #FCFCFC;

          }
        }


        &.agenda {
          background-color: #DE0048;
        }

        &.sorties {
          background-color: #54C0EB;
        }

        &.kids {
          background-color: #81E12B;

        }

        &.parents {
          background-color: #ab61af;
        }

        &.announcements {
          background-color: #FFAE5E;
        }

      }
    }
  }
}


.navigation__line_sublist {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  align-items: center;

  li {
    text-align: center;
  }

  a {
    text-decoration: none;
    color: #FCFCFC;
    font-size: .8rem;

    &:hover {
      color: #DE0048;
    }
  }
}

.navigation__links {
  display: flex;
  flex-direction: row;
  justify-content: space-evenly;
  width: 100%;
  gap: 12px;
  padding: 12px 0 24px;
  background-color: var(--e-global-color-accent);
  transform: translateY(calc(102vh + 100%));
}

.navigation__link_row {
  display: flex;
  flex-direction: column;
  gap: 6px;
}


.navigation__link_row div {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.navigation__link_label {
  font-size: 14px;
  font-weight: 700;
  color: #FCFCFC;
  text-decoration: none;
}

.navigation__link_row a {
  text-decoration: none;
  color: #FCFCFC;
  font-weight: 200;
  font-size: 13px;
}

.navigation__link_social_icons {
  display: flex !important;
  flex-direction: row !important;
  gap: 12px;
  align-items: center !important;
  justify-content: center;
  padding: 12px 0;

  svg {
    width: 24px;
    height: 24px;
    fill: #FCFCFC;
  }
}

.navigation__open_button {
  &:not(.--active) {
    .navigation-icon {
      &:hover {
        justify-content: space-around;
      }
    }
  }

  .navigation-icon {
    width: 31px;
    height: 25px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    transition: transform 0.3 ease-in-out;

    &:hover {
      cursor: pointer;
    }

    .bar {
      background-color: var(--e-global-color-text);
      width: 100%;
      height: 5px;
      display: block;
      transition: opacity 0.3s ease-in-out, transform 0.3s ease-in-out, background-color 0.3s ease-in-out;
    }
  }

  &.--active {
    .navigation-icon {
      transform: rotate(90deg);
    }

    .bar {
      background-color: #DE0048;

      &:nth-child(1) {
        transform: rotate(45deg) translateY(7px) translateX(7px);
      }

      &:nth-child(2) {
        opacity: 0;
        transform: rotate(180deg);
      }

      &:nth-child(3) {
        transform: rotate(-45deg) translateY(-7px) translateX(7px);
      }
    }
  }
}

.navigation__breadcrumbs {
  padding: 0 0 6px 0;
  a {
    text-decoration: none;
  }

  .navigation__breadcrumbs-separator {
    margin: 0;
  }
}

@media only screen and (min-width: 767px) {
  .--hide-on-desktop {
    display: none;
  }
  .navigation__phone {
    display: none;
  }
  .--image-hide-on-mobile {
    display: none;
  }
}

@media only screen and (max-width: 769px) {
  .--image-hide-on-desktop {
    display: none;
  }
}

@media only screen and (max-width: 769px) {
  .navigation {
    position: fixed;
    left: 0;
    top: 0;
    height: -webkit-fill-available;
    width: 102vw;
    z-index: 999;
    background-color: #fff;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    align-items: center;
    transform: translateY(-100%);
    margin: -6px;

    /* Adjust for mobile view */
    .navigation__list {
      flex-direction: column;
      align-items: center;
      justify-content: center;
      margin-right: 0;
      flex: 1;
      width: 100%;
      gap: 0;
    }
  }

  .navigation__open {
    transform: translateY(0);
    top: auto;

    .navigation__links {
      transform: translateY(0);
    }

  }

  .navigation__line {
    display: none;
  }

  .navigation__item {
    margin: 0;
    width: 100%;
    text-align: center;
    background-color: transparent;
    border-radius: 3px;

    &.--active {
      .navigation__link {
        .navigation__label {
          font-weight: bold;
        }
      }
    }

    .navigation__link {
      padding: 8px;
    }
  }
}

@media only screen and (max-width: 769px) and (max-height: 700px) {
  .navigation {
    overflow: auto;
    justify-content: center;
    display: flex;
    flex-direction: column;
    height: -webkit-fill-available;
    padding-top: 100px;

    .navigation__list{
      margin: 32px 0;
      gap: 6px;
      
    }

    .navigation__links {
      transform: translateY(calc(150vh + 100%));
    }

    &.navigation__open {
      .navigation__links {
        transform: translateY(0);
      }
    }
  }

  #ad-Leaderboard.hidden {
    display: none;
  }
}


@media only screen and (max-width: 769px) and (max-height: 650px) {
  .navigation {
    padding-top: 50px;
  }
}


@media only screen and (max-width: 769px) and (max-height: 500px) {
  .navigation {
    padding-top: 150px;
  }

  .navigation__links {
    padding-bottom: 70px;
  }
}

@media only screen and (max-width: 769px) and (max-height: 450px) {
  .navigation {
    padding-top: 230px;
  }
}