@import "variables";
@import "mixins/link";

:host {
  .marketing-content-bottom {
    display: flex;
    flex-direction: column;
    gap: 12px;
    align-items: center;
    justify-content: center;

    .link {
      display: inline-flex;
      align-items: center;
      gap: 6px;
      text-decoration: none;
      color: #dce0ee;
      font-size: 12px;

      &:hover {
        text-decoration: underline;
        cursor: pointer;
        color: #fff;
      }
    }

    .community-links {
      .link {
        margin: 0 12px;
        text-decoration: none;

        &:hover {
          cursor: pointer;

          .text {
            text-decoration: underline;
          }
        }

        i {
          color: $blue-300 !important;
        }
      }
    }

    ntkme-github-button {
      ::ng-deep a.gh-btn, ::ng-deep a.social-count {
        text-decoration: none;
        color: $blue-800;

        &:hover {
          color: #000;
          font-weight: bold;
        }
      }
    }
  }

  .login-form {
    color: $blue-200;
    flex-direction: column;
    overflow: auto;

    background: white;
    flex: 1;
    padding: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;

    &.dark-theme {
      background-image: url(../../assets/infinity_anim--on_light.svg), linear-gradient(100deg, #22408a 6%, #09173c 82%);
      background-size: contain;
      background-position: center;
      background-repeat: no-repeat;
    }

    @media(max-width: 420px) {
      max-width: unset;
      height: 100vh;
      width: 100vw;
      padding-top: 30px;
    }

    .login-section {
      display: flex;
      flex: 1;
      padding: 24px 0;
      text-align: center;

      @media(max-width: 655px) {
        overflow: unset;
      }

      .logo {
        width: 150px;
      }

      .login-title {
        font-weight: 500;
        font-size: 20px;
        color: #ffffff;
        max-width: 320px;
        min-height: 30px;
        white-space: pre-line;
      }

      .login-notice {
        color: #fff;
        margin-bottom: 5px;
      }

      section {
        width: 320px;
        margin: auto;
      }

      .login-error {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 24px;
      }
    }

    .username-input {
      margin-bottom: 12px;

      input {
        background-color: #ffffff;
        color: $blue-500;
        width: 100%;
        padding-left: 12px;
        height: 36px;
      }

      //input:-webkit-autofill,
      //input:-internal-autofill-previewed,
      //input:-internal-autofill-selected {
      //  -webkit-box-shadow: 0 0 0 30px $blue-800 inset !important;
      //  -webkit-text-fill-color: white !important;
      //}
    }

    label {
      display: block;
      text-align: left;
      font-size: 12px;
      margin-bottom: 0;
      margin-top: 2px;
    }

    .btn {
      position: relative;
      display: flex;
      justify-content: center;
      align-items: center;
      width: 100%;
      height: 36px;
      margin: 32px 0;
      font-size: 14px;
      font-weight: 500;
      border: 0; /* this was 1px earlier */
      opacity: unset;

      &:hover {
        border: 0 solid transparent; /* this was 1px earlier */
      }

      .spinner {
        position: absolute;
        left: 75px;
      }

      i {
        font-size: 20px;
        position: relative;
        top: -1px;
      }

      .btn-text {
        display: inline-flex;
        width: 130px;
        white-space: nowrap;
      }
    }

    .separator {
      display: flex;
      justify-content: center;
      color: $blue-250;
      font-size: 11px;

      .line {
        width: 104px;
        margin-bottom: 10px;
      }
    }

    .terms-of-use {
      display: inline-block;
      width: 210px;
      font-size: 12px;
      color: $blue-500;
      @include link();
    }
  }

  &.dark-theme {
    .login-form .terms-of-use {
      color: $blue-200;

      a[href] {
        color: $neon-yellow;
      }
    }
  }
}


.circle {
  margin: 0 auto 40px;
  width: 80px;
  height: 80px;
  border-radius: 100%;
  border: 10px solid rgba(255, 255, 255, 0.5);
  border-top-color: #FFFFFF;
  animation: spin 1s infinite linear;
  @keyframes spin {
    100% {
      transform: rotate(360deg);
    }
  }

  mat-spinner {
    --mdc-circular-progress-active-indicator-color: #FFFFFF;
  }
}

.errors {
  width: 250px;
  max-height: 100px;
  overflow: auto;
  margin-top: 16px;
  color: #ff6f81;
  text-align: left;
}

.other-email {
  margin-top: 16px;
  text-align: left;
}


.banner {
  color: $blue-400;
  padding: 24px;
  text-align: left;
  font-size: 12px;
}

:host-context(.mobile) {
  .login-form {
    padding-top: 64px;
  }
}

