.hide {
  display: none;
}

.container {
  position: fixed;
  z-index: var(--cookie-consent-index);
  top: 0;
  right: 0;
  width: 100%;
  height: 100vh;
  background: var(--cookie-consent-overlay-bg, rgba(255, 255, 255, 0.5));
  @include flex-align(center, center);
}

.modalContent {
  background-color: white;
  box-shadow: 0px 8px 8px -4px rgba(27, 27, 28, 0.02), 0px 20px 24px -4px rgba(27, 27, 28, 0.05);
  padding: var(--cookieModal-mobile-padding, 1.6rem 1.6rem 3.2rem);
  max-width: 63.4rem;
  margin: 0 auto;
  height: 100vh;
  overflow-y: scroll;

  @include min(tablet) {
    height: auto;
  }

  .modalCookieHeader {
    display: flex;
    position: relative;
    padding-bottom: 1.6rem;
    border-bottom: 1.5px solid #dedede;

    > img {
      width: var(--cookieModal-mobile-img-width, 12.1rem);
      height: var(--cookieModal-mobile-img-height, 3.2rem);
    }

    > button {
      position: absolute;
      right: 2px;
      top: 2px;
    }
  }

  .modalTextHeader {
    margin-top: 1.6rem;
    margin-bottom: 1.6rem;

    span {
      font-size: var(--cookieModal-mobile-privacy-size, 1.6rem);
      font-weight: var(--cookieModal-mobile-privacy-weight, 700);
      line-height: var(--cookieModal-mobile-privacy-Lineheight, 2.7rem);
      color: var(--cookieModal-mobile-privacy-color, #1c1a28);
    }
    p {
      font-weight: 400;
      font-size: var(--cookieModal-mobile-privacy-text-size, 1.4rem);
      line-height: var(--cookieModal-mobile-privacy-text-Lineheight, 2.2rem);
      color: var(--cookieModal-mobile-privacy-text-color, #515156);
      margin-top: var(--cookieModal-mobile-privacy-text-margin-top, 1.6rem);
    }
  }

  .cookieLink {
    margin: 0px 3px;
    color: var(--cookieModal-cookieLink-color, #165af8);
    font-weight: var(--cookieModal-cookieLink-weight, 600);
    text-decoration: var(--cookieModal-cookieLink-underline, underline);
  }

  .modalButtons {
    display: flex;
    flex-direction: column;
    padding: var(--cookieModal-button-padding, 0rem);
    gap: var(--cookieModal-button-gap, 0.8rem);

    button {
      display: flex;
      align-items: center;
      gap: var(--cookieModal-mobile-button-gap, 0.8rem);
      height: var(--cookieModal-mobile-button-height, 4rem);
      text-align: center;
      font-size: var(--cookieModal-mobile-button-size, 1.4rem);
      font-weight: var(--cookieModal-mobile-button-weight, 700);
      line-height: var(--cookieModal-mobile-button-lineHeight, 2.2rem);
      text-transform: capitalize;
      padding: var(--cookieModal-mobile-button-padding, 0.8rem 1.6rem);
      border-radius: var(--cookieModal-mobile-button-radius, 10rem);
      background-color: var(--cookieModal-mobile-button-bg);
      color: var(--cookieModal-mobile-button-color, white) !important;

      &:last-child {
        background-color: var(--cookieModal-mobile-second-button-bg, white);
        border: var(--cookieModal-mobile-second-button-border, 2px solid #262629);
        color: var(--cookieModal-mobile-second-button-color, #262629) !important;

        &:hover {
          background: none;
        }
      }
    }
  }

  .mainBox {
    padding-top: 1.4rem;

    .mainTitle {
      display: flex;
      align-items: center;
      justify-content: space-between;
      font-weight: var(--cookieModal-mainTitle-weight, 700);
      font-size: var(--cookieModal-mainTitle-size, 1.6rem);
      line-height: var(--cookieModal-mainTitle-lineHeight, 2.7rem);
      margin-bottom: var(--cookieModal-mainTitle-margin-bottom, 1.6rem);
      color: var(--cookieModal-mainTitle-color, #1b1b1c);

      @include min(tablet) {
        font-size: var(--cookieModal-desktop-mainTitle-size, 1.6rem);
        line-height: var(--cookieModal-desktop-mainTitle-lineHeight, 2.7rem);
      }
    }
  }

  .menageArrow {
    transform: rotate(180deg);
  }

  .lastButton {
    padding-top: 1.6rem;

    > button {
      background-color: var(--cookieModal-mobile-button-bg, #6e33e5);
      padding: var(--cookieModal-mobile-button-padding, 0.8rem 1.6rem);
      border-radius: var(--cookieModal-mobile-button-radius, 10rem);
      height: var(--cookieModal-mobile-button-height, 4rem);
      width: 100%;
      margin-bottom: 0px;
      color: var(--cookieModal-mobile-button-color, white) !important;
      font-size: var(--cookieModal-mobile-button-size, 1.4rem);
      font-weight: var(--cookieModal-mobile-button-weight, 700);
      line-height: var(--cookieModal-mobile-button-lineHeight, 2.2rem);
      text-transform: capitalize;
    }
  }

  @include min(tablet) {
    border-radius: 1.6rem;
    padding: var(--cookieModal-desktop-padding, 2.4rem);
    overflow-y: scroll;
    max-height: 98vh;
    &::-webkit-scrollbar {
      width: 3px;
    }
    &::-webkit-scrollbar-track {
      background: transparent;
    }
    &::-webkit-scrollbar-thumb {
      background: #888;
      border-radius: 10px;
    }
    &::-webkit-scrollbar-thumb:hover {
      background: #555;
    }
    .modalCookieHeader {
      justify-content: center;
      padding-bottom: 2.4rem;
      border: none;
      > img {
        width: var(--cookieModal-desktop-img-width, 15.1rem);
        height: var(--cookieModal-desktop-img-height, 4rem);
      }
      > button {
        right: -16px;
        top: -16px;
      }
    }
    .modalTextHeader {
      margin-top: 0px;
      margin-bottom: 0px;
      font-size: var(--cookieModal-privacy-size, 1.6rem);

      > span {
        font-size: var(--cookieModal-desktop-privacy-size, 1.6rem);
        line-height: var(--cookieModal-desktop-privacy-Lineheight, 2.7rem);
      }
    }
    .modalButtons {
      flex-direction: row;
      padding: var(--cookieModal-desktop-button-padding, 1.6rem 0px);
      gap: var(--cookieModal-desktop-button-gap, 0.8rem);

      button {
        margin-bottom: 0px;
      }
    }
    .mainBox {
      padding-top: 8px;
    }
    .lastButton {
      padding-bottom: 0rem;
      > button {
        width: auto;
      }
    }
  }
}

.modalContentTwo {
  padding: 1.6rem;
  display: flex;
  flex-direction: column;
  background-color: white;

  @include min(tablet) {
    padding: 3.2rem;
    border-radius: 1.6rem;
  }

  .modalCookieHeader {
    justify-content: start;
    padding-bottom: 2.4rem;
    border: none;
    > span {
      color: #1b1b1c;
      font-size: 2rem;
      font-weight: 700;
      line-height: 2.8rem;
      text-transform: capitalize;
      width: 90%;

      @include min(tablet) {
        width: 100%;
        font-size: 2.4rem;
        line-height: 3.2rem;
      }
    }
    @include min(tablet) {
      padding-bottom: 3.2rem;
    }
  }

  .modalTextHeader {
    margin: 0rem;
    > p {
      color:  #515156;
      font-size: 16px;
      font-weight: 400;
      line-height: 27px;
      margin: 0rem;
    }
  }

  .modalButtons {
    order: 3;
    padding: 0rem;
    padding-top: 2.4rem;
    flex-direction: column-reverse;

    @include min(tablet) {
      gap: 0.8rem;
      padding-top: 3.2rem;
      flex-direction: row-reverse;
    }

    > button {
      width: 100%;
      padding: 1.6rem 2.4rem;
      height: 5.6rem;
      font-size: 1.8rem;
      font-weight: 700;
      line-height: 2.6rem;
      text-transform: capitalize;

      &:last-child {
        margin-left: 0rem;
      }
    }
  }

  .mainBox {
    margin-top: 2.4rem;
    padding-top: 0rem;
    max-height: 5.6rem;
    overflow: hidden;
    background-color: #f4f4f4;
    border-radius: 0.8rem;
    padding: 0.8rem;

    @include min(tablet) {
      margin-top: 3.2rem;
      padding: 1.6rem;
    }

    > span {
      padding: 0.8rem;
      @include min(tablet) {
        padding: 0rem;
      }
    }

    > div {
      > div {
        background-color: white;

        > div:last-child {
          background-color: #f4f4f4;
        }
      }
    }
  }


  .mainBoxStyleTwoFullHeight {
    max-height: unset !important;
    overflow: unset;
  }
}
