.promotion-codes {
  border-top: 1px solid var(--custom-border-color);
  margin: 0 2rem 1rem;
  padding-top: 1rem;

  & > div {
    display: flex;
    gap: 0.5rem;
    margin: 0 0 0.75rem;
    padding: 0;

    & label {
      position: absolute;
      width: 1px;
      height: 1px;
      padding: 0;
      margin: -1px;
      overflow: hidden;
      clip: rect(0, 0, 0, 0);
      border: 0;
    }

    & input[type="text"] {
      flex: 1;
      margin: 0;
      text-align: left;
    }

    & button {
      flex: 0;
      padding: 0 1rem;

      &[disabled] {
        background-color: var(--custom-text-background-color-hover);
        color: #bbb;
        cursor: default;
      }
    }
  }

  & ul:not(.error-list) {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    list-style-type: none;
    padding: 0;

    & li {
      align-items: stretch;
      background-color: #333;
      border-radius: 1rem;
      color: white;
      display: inline-flex;
      font-size: 0.75rem;
      padding: 0 0 0 0.25rem;

      &.not_found {
        background-color: var(--danger-color);
      }

      &.unavailable {
        background-color: var(--custom-text-color-muted);
      }

      & span {
        padding: 0.25rem;
        word-break: break-all;
      }

      & button {
        background-color: transparent;
        border-radius: 0 1rem 1rem 0;
        display: block;
        padding: 0;
        width: 1.5rem;
      }
    }
  }
}

.pseudo-form {
  & .promotion-codes {
    border-top: none;
    margin: 0;
    padding: 0;
  }
}
