@import '@/assets/vars';

.swal2-popup {
  background-color: $dark !important;

  .swal2-title {
    color: $brand !important;
  }
  .swal2-content {
    color: $light !important;
  }
}

@import '@/../node_modules/bootstrap/scss/bootstrap';

html,
body {
  background-color: $dark;
  padding: 0;
  margin: 0;
  font-size: 16px;
  width: 100%;
  height: 100%;
}

html.swal2-shown.swal2-height-auto {
  body.swal2-shown.swal2-height-auto {
    height: 100% !important;
  }
}
.dropdown-toggle {
  padding: 0.6rem 2.5rem !important;
}
#app {
  font-family: $Quicksand;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  background-color: $dark;
  height: 100%;

  .info-container {
    position: absolute;
    bottom: 5%;
    display: flex;

    .info-item {
      color: #ffffff;
      font-family: $Quicksand;
      font-size: 1.15rem;
      font-weight: 700;
      display: flex;
      align-items: center;
      line-height: 1;

      &:hover {
        cursor: pointer;
        color: $brand;
        svg {
          path {
            fill: $brand;
          }
        }
      }

      svg {
        margin-right: 1rem;
      }

      span {
        font-weight: 400;
      }
    }
  }

  &.loggedIn {
    display: grid;
    grid-template-columns: 1fr 5fr;
  }

  #nav {
    display: flex;
    flex-direction: column;
    width: 100%;
    height: 100%;
    background-color: #354960;
    padding-top: 50px;

    a {
      color: #ffffff;
      font-family: $Quicksand;
      font-size: 1rem;
      font-weight: 700;
      padding: 0.5rem 2rem;
      text-decoration: none;

      &:hover {
        color: $brand;

        svg {
          path {
            fill: $brand;
          }
        }
      }
    }

    .nav-button {
      align-items: center;
      svg {
        width: 1rem;
        height: 1rem;
        path {
          fill: #fff;
        }
        margin-right: 1rem;
      }
    }
  }

  #screen-view {
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    z-index: 11;

    .container.flexed {
      height: 100%;
      display: flex;
      flex-direction: column;
      justify-content: center;
    }
  }
}

#networkSelector {
  position: absolute;
  top: 5%;
  right: 10%;
  color: #fff;
  z-index: 9999;
}

.title {
  color: $brand;
  font-family: $Quicksand;
  font-size: 2.75rem;
  font-weight: 700;
}
.subtitle {
  font-family: $Quicksand;
  font-size: 1.5rem;
  font-weight: 400;
  line-height: 2.125rem;
  color: $brand;
}

p {
  font-family: $Quicksand;
  font-size: 0.85rem;
  font-weight: 400;
  color: #fff;
}

.actions-container {
  display: flex;
  margin-top: 4rem;
}
.button {
  border-radius: 0.188rem;
  border: 0.063rem solid $light;
  color: $light;
  font-family: $Quicksand;
  font-size: 0.813rem;
  font-weight: 700;
  padding: 1rem;
  display: flex;
  justify-content: center;
  align-items: center;

  &:not(--last-of-type) {
    margin-right: 2rem;
  }

  &:hover {
    cursor: pointer;
    background-color: $light;
    color: $dark;
    text-decoration: none;

    svg path {
      fill: $dark;
    }
  }
}
.dropdown-menu {
  outline: none;
}
#dropdown-aria {
  padding: 0;
  margin: 0;
}
.login {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;

  .zilliqa {
    position: absolute;
    top: 0;
    right: 10%;
    height: 100%;
  }

  h2 {
    color: #ffffff;
    font-family: $Quicksand;
    font-size: 1.5rem;
    font-weight: 400;
    line-height: 2.125rem;
  }

  .actions-container {
    display: flex;
    margin-top: 4rem;
  }
  .button {
    border-radius: 0.188rem;
    border: 0.063rem solid $light;
    color: $light;
    font-family: $Quicksand;
    font-size: 0.813rem;
    font-weight: 700;
    padding: 2rem;
    display: flex;
    justify-content: center;
    align-items: center;

    &:not(--last-of-type) {
      margin-right: 2rem;
    }

    &:hover {
      cursor: pointer;
      background-color: $light;
      color: $dark;
    }
  }
  .login {
    width: 100%;
    height: 100%;

    .container {
      width: 30%;
      margin-left: 10%;
    }

    .zilliqa {
      position: absolute;
      top: 0;
      right: 10%;
      height: 100%;
    }
  }
}

#networkSelector {
  font-family: $Quicksand;
  font-size: 0.85rem;
  font-weight: 400;
  color: #ffffff;
  display: flex;

  .logout-button {
    padding-right: 1rem;
    border-right: 1px solid $brand;
    a {
      color: #fff;
    }
  }

  .dropdown {
    padding-left: 1rem;
    position: relative;

    span {
      color: $brand;
    }
    &:hover {
      .dropdown-list {
        display: block;
      }
    }
    .dropdown-list {
      display: none;

      position: absolute;
      z-index: 99;
      background-color: #fff;

      a {
        color: $dark;
        cursor: pointer;

        &:hover {
          color: $brand;
        }
      }
    }
  }
}

.owner-badge {
  border-radius: 0.375rem;
  background-color: $light;
  color: $dark;
  padding: 1rem;
  font-family: $Quicksand;
  font-size: 0.75rem;
  font-weight: 400;
  position: relative;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;

  .name {
    font-weight: 700;
  }
}

.create-wallet {
  height: 100%;
  .owners-container {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    grid-gap: 20px;

    .owner {
      border-radius: 0.375rem;
      background-color: #354960;
      padding: 1rem;
      color: #ffffff;
      font-family: $Quicksand;
      font-size: 0.75rem;
      font-weight: 400;
      position: relative;
      white-space: nowrap;
      overflow: hidden;
      text-overflow: ellipsis;

      .name {
        font-weight: 700;
      }

      .overlay {
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;

        z-index: 2;
        background-color: transparentize(
          lighten(map-get($theme-colors, 'danger'), 10),
          0.2
        );
        align-items: center;
        justify-content: center;
        border-radius: 0.375rem;
        display: none;
        cursor: pointer;
      }

      &:hover {
        .overlay {
          display: flex;
        }
      }
    }
    .add-owner {
      border-radius: 0.375rem;
      background-color: $light;
      color: $dark;
      font-family: $Quicksand;
      font-size: 0.75rem;
      font-weight: 700;
      display: flex;
      align-items: center;
      justify-content: center;
      padding: 1rem 3rem;
      transition: all 0.3s ease-in-out;

      &:hover {
        cursor: pointer;
        background-color: lighten(map-get($theme-colors, 'success'), 40);
      }
    }
  }

  .signature-input {
    display: flex;

    input {
      width: 52px;
      height: 38px;
    }
    .controller {
      border-radius: 0.375rem;
      border: 0.063rem solid #707070;
      background-color: $light;
      width: 38px;
      height: 38px;
      justify-content: center;
      align-items: center;
      display: flex;

      &:not(:first-of-type) {
        margin-left: 0.5rem;
      }

      margin-right: 0.5rem;

      &:hover {
        cursor: pointer;
        opacity: 0.9;
      }
    }
  }

  input {
    border-radius: 0.375rem;
    padding-left: 14px;
    height: 38px;
    border: 0;
  }
}

.btn {
  border-radius: 0.375rem;
  padding: 1rem 4rem;
  color: $dark;
  font-family: $Quicksand;
  font-size: 0.75rem;
  font-weight: 700;
}

.wallet {
  height: 100%;
  padding-top: 50px;

  .heading {
    display: flex;
    justify-content: space-between;
    align-items: center;

    .filters {
      color: #ffffff;
      font-size: 0.85rem;
      font-weight: 400;

      span {
        font-weight: 700;
        cursor: pointer;
      }
    }
  }
}

.btn {
  &.btn-outline-secondary {
    color: $light;

    &:hover {
      color: $dark;
    }
  }
  &.btn-outline-primary {
    color: $brand;

    &:hover {
      color: $light;
    }
  }
}

.add-funds-form {
  border-radius: 0.688rem;
  background-color: $gray;
  padding: 2rem;
  min-width: 300px;
  max-width: 500px;
  width: 100%;
}

.big-form {
  display: grid;
  grid-template-columns: 1fr 4fr;
  row-gap: 1rem;
  font-size: 0.85rem;
  font-weight: 700;
  color: #fff;
  align-items: center;

  input {
    border-radius: 0.375rem;
    background-color: #ffffff;

    color: $dark;
    font-size: 0.85rem;
    font-weight: 700;
    padding: 0.5rem;
  }
}

.tabs-component-tabs {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  justify-content: space-between;

  & > .tabs-component-tab + .is-active > a {
    background-color: $brand;
    color: $light;
  }

  & > .tabs-component-tab {
    & > a {
      padding: 10px;
      text-decoration: none;
      border-radius: 0.375rem;
      font-size: 1rem;
      font-family: "Quicksand", sans-serif;
      font-weight: 700;
    }
  }
}

.advanced-options {
  display: flex;

  .option {
    display: flex;
    color: #fff;
    align-items: center;

    input {
      border-radius: 0.375rem;
      background-color: #ffffff;

      color: $dark;
      font-size: 0.85rem;
      font-weight: 700;
      padding: 0.5rem;
      margin-left: 1rem;
    }

    &:not(:first-of-type) {
      margin-left: 1rem;
    }
  }
}

.modal-mask {
  position: fixed;
  z-index: 9998;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.5);
  display: table;
  transition: opacity 0.3s ease;
}

.modal-wrapper {
  display: table-cell;
  vertical-align: middle;
}

.modal-container {
  width: 500px;
  margin: 0px auto;
  padding: 20px 30px;
  background-color: #fff;
  border-radius: 2px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.33);
  transition: all 0.3s ease;
  font-family: Helvetica, Arial, sans-serif;
}

.modal-header h3 {
  margin-top: 0;
  color: #42b983;
}

.modal-body {
  margin: 20px 0;
}

.modal-default-button {
  float: right;
}

/*
 * The following styles are auto-applied to elements with
 * transition="modal" when their visibility is toggled
 * by Vue.js.
 *
 * You can easily play with the modal transition by editing
 * these styles.
 */

.modal-enter {
  opacity: 0;
}

.modal-leave-active {
  opacity: 0;
}

.modal-enter .modal-container,
.modal-leave-active .modal-container {
  -webkit-transform: scale(1.1);
  transform: scale(1.1);
}

.wallet-card {
  position: relative;
  .actions {
    position: absolute;
    top: 5%;
    right: 5%;
    display: flex;

    .action {
      svg {
        path {
          fill: #5a728d;
        }
      }

      &:hover {
        svg {
          path {
            fill: $light;
          }
        }
      }
    }

    .pallete {
      margin-right: 0.5rem;
    }

    .pallete-colors {
      margin-right:0.25rem;
      display: flex;
      align-items:center;
      padding-top:4px;
      display: none;
      &.open {
        display: flex;
      }
      .color {
        width: 11px;
        height: 11px;
        border-radius: 50%;
        border: 1px solid #fff;
        margin-right: 0.25rem;

        &:hover {
          border:2px solid #fff;
        }
      }
    }

    .pin.isPinned {
      svg path {
        fill: #fff;
      }
    }
  }
}

.transactions-list {
  .transaction {
    border-radius: 6px;
    background-color: $light;
    display: flex;
    padding: 1rem;
    font-size: 0.85rem;

    .item:not(:last-of-type) {
      margin-right: 0.5rem;
      border-right: 1px solid lighten($gray, 40);
      padding-right: 0.5rem;
    }

    .transfer {
      .details {
        display: flex;
      }
    }

    .address-text {
      max-width: 150px;
      overflow: hidden;
      text-overflow: ellipsis;
    }

    .amount {
      border-right: 0 !important;
      flex-grow: 1;
    }

    .actions {
      display: grid;
      grid-template-columns: 1fr 1fr 1fr;
      justify-content: space-between;
      align-items: center;

      .secondary-actions {
        display: flex;
        justify-content: flex-end;
        padding-right: 1rem;

        .unsign {
          border-radius: 4px;
          background-color: #edc557;
          width: 26px;
          height: 26px;
          display: flex;
          align-items: center;
          justify-content: center;
          cursor: pointer;
        }

        .sign {
          border-radius: 4px;
          background-color: #5fafff;
          width: 26px;
          height: 26px;
          display: flex;
          align-items: center;
          justify-content: center;
          cursor: pointer;
        }
      }
      .main-actions {
        .action {
          border-radius: 4px;
          background-color: #5fafff;
          height: 26px;
          display: flex;
          align-items: center;
          justify-content: center;
          cursor: pointer;
          font-weight: 700;
          color: $dark;
          font-size: 0.75rem;
          min-width: 90px;

          img {
            height: 0.7rem;
            margin-right: 0.25rem;
          }

          &.execute {
            background-color: #3ee0ae;
          }

          &.sign {
            background-color: #5fafff;
          }

          &.unsign {
            background-color: #edc557;
          }
        }
      }
    }
  }
}

#app {
  .navToggler {
    display: none;
  }
}

.dashboard-screen {
   .wallet-card {
      .actions {
        display: none;
      }
    }
}

@media screen and(max-width: 600px) {
  img.zilliqa {
    display: none;
  }
  .modal-container {
    width: 80%;
  }

  .login .actions-container {
    flex-wrap: wrap;

    .button {
      margin-bottom: 1rem;
    }
  }

  #app {
    grid-template-columns: 1fr !important;
    padding-top: 10%;

    .navToggler {
      position: fixed;
      top: 2rem;
      left: 1rem;
      display: block;
      z-index: 9999;

      svg {
        path {
          fill: #fff;
        }
      }
    }
  }

  #app #nav {
    position: fixed;
    top: 0;
    width: 60%;
    z-index: 9998;
    transform: translateX(-100%);
    transition: all 0.5s ease-in-out;

    &.active {
      transform: translateX(0);
    }
  }

  .dashboard-screen {
    display: flex !important;
    flex-direction: column !important;
  }

  .create-wallet {
    padding-bottom: 1rem;
    .owners-container {
      grid-template-columns: 1fr;
    }
    .advanced-options {
      flex-direction: column;

      .option {
        margin-left: 0 !important;
        margin-bottom: 1rem;
      }
    }
  }
}

.pallete-blue {
  background-color: #074b96 !important;
}
.pallete-purple {
  background-color: #590796 !important;
}
.pallete-green {
  background-color: #0a574b !important;
}
.pallete-black {
  background-color: #000000 !important;
}
