// QR Code Alternatives modal styles

.qr-alternatives-overlay {
  z-index: 1000;
  position: fixed;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  overflow-y: auto;
  background-color: rgba(0, 0, 0, 0.4);
  padding: 40px 10px;
  display: flex;
  align-items: flex-start;
  justify-content: center;
}

.qr-alternatives-modal {
  border-radius: 15px;
  margin: auto;
  background-color: var(--pgw-color-background-primary);
  position: relative;
  outline: 0;
  width: 100%;
  max-width: 400px;
  padding: 15px;
  font-weight: 500;
  font-size: 14px;
  color: var(--pgw-color-text-primary);
  box-shadow: 0px 5px 15px rgba(0, 0, 0, 0.15);
}

.qr-alternatives-title {
  font-size: 16px;
  font-weight: 700;
  margin: 0;
  padding-bottom: 10px;
  color: var(--pgw-color-text-primary);
}

.qr-alternatives-close {
  position: absolute;
  right: 0;
  top: 0;
  cursor: pointer;
  outline: none;
  box-shadow: none !important;
  color: var(--pgw-color-text-primary) !important;
  font-size: 24px;
  line-height: 32px;
  padding: 5px 10px;
  margin: 0;
  text-decoration: none;

  &:hover {
    text-decoration: none;
    color: var(--pgw-color-black) !important;
  }
}

.qr-alternatives-description {
  font-size: 12px;
  line-height: 1.5;
  color: var(--pgw-color-black);
  margin: 0 0 20px 0;
  font-weight: 400;
}

.qr-alternatives-options-label {
  font-size: 12px;
  font-weight: 400;
  margin-bottom: 12px;
  color: var(--pgw-color-text-primary);
}

.qr-alternatives-section {
  margin-bottom: 8px;
  border-radius: 8px;
  overflow: visible;

  &:last-child {
    margin-bottom: 0;
  }
}

.qr-alternatives-section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  cursor: pointer;
  transition: background-color 0.2s;

  span {
    font-weight: 600;
    font-size: 14px;
  }

  .chevron-icon {
    width: 16px;
    height: 16px;
    transition: transform 0.25s;
  }

  &.open .chevron-icon {
    transform: rotate(180deg);
  }
}

.qr-alternatives-section-content {
  padding-left: 10px;
  padding-top: 5px;
  margin: 5px 0;
  border-left: 1px solid var(--pgw-border-color);
  position: relative;
  overflow: visible;
}

p.qr-alternatives-section-description {
  font-size: 12px;
  line-height: 1.5;
  color: var(--pgw-color-black);
  margin: 0 0 16px 0;
  font-weight: 400;
  margin-bottom: 5px;
}

.qr-alternatives-select {
  width: 100%;
  padding: 12px 16px;
  font-size: 14px;
  border: 1px solid var(--pgw-border-color);
  border-radius: 8px;
  background-color: var(--pgw-color-background-secondary);
  color: var(--pgw-color-text-primary);
  margin-bottom: 16px;
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23666' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 16px center;

  &:focus {
    outline: none;
    border-color: var(--pgw-color-primary);
  }
}

.qr-alternatives-button {
  white-space: pre-line;
  font-weight: 600;
  cursor: pointer;
  background-color: var(--pgw-color-primary);
  color: var(--pgw-color-black);
  outline: 0;
  box-shadow: none !important;
  color: var(--pgw-color-text-primary);
  border-radius: var(--pgw-default-radius-1);
  border: none;
  display: inline-block;
  padding: 8px 16px;
  vertical-align: middle;
  text-align: center;
  font-size: 12px;

  &:hover:not(:disabled) {
    opacity: 0.9;
  }

  &:disabled {
    opacity: 0.5;
    cursor: not-allowed;
  }
}

.qr-alternatives-qr-container {
  display: flex;
  justify-content: center;
  padding: 16px 0;

  img {
    max-width: 180px;
    height: auto;
  }
}

.qr-alternatives-dropdown {
  margin-bottom: 16px;
  position: relative;

  .forumpay-pgw-dropdown-list {
    position: relative;
    max-height: 200px;
    margin-top: 8px;
    border: 1px solid var(--pgw-border-color);
    border-radius: 8px;
    background-color: var(--pgw-color-background-primary);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  }

  .forumpay-pgw-dropdown-field {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    cursor: pointer;
    transition: background-color 0.2s;
    justify-content: start;

    &:hover,
    &.active-field {
      background-color: var(--pgw-color-background-tertiary);
    }

    .wallet-icon {
      width: 60px;
      height: 25px;
      object-fit: contain;
      flex-shrink: 0;
    }

    span {
      font-size: 12px;
      color: var(--pgw-color-text-primary);
    }
  }

  .forumpay-pgw-dropdown-selected {
    display: flex;
    align-items: center;
    gap: 12px;

    .wallet-icon {
      width: 24px;
      height: 24px;
      object-fit: contain;
    }

    span {
      font-size: 12px;
      font-weight: 500;
      color: var(--pgw-color-text-primary);
    }
  }
}

.qr-alternatives-loading {
  padding: 20px;
  text-align: center;
  color: var(--pgw-color-gray-2);
  font-size: 14px;
}

.qr-alternatives-no-wallets {
  padding: 20px;
  text-align: center;
  color: var(--pgw-color-gray-2);
  font-size: 14px;
  font-style: italic;
}
