In a bear market, it's easy to feel like nothing in your portfolio is working for you. 2022 has been particularly tough for investors, because both stocks and bonds have fallen sharply, causing losses even for those who typically have a more conservative investing strategy.

However, there are still some stocks that are hitting all-time highs even amid all the macroeconomic uncertainty. With strong businesses and good prospects ahead, it's even possible that these high-performing stocks will continue to enjoy share-price gains in 2023.

Here, you'll learn more about how Ulta Beauty (ULTA 1.73%) and Steel Dynamics (STLD -0.59%) have managed to hit new record levels in the past couple of days and why they might be poised to head even higher in the year to come.

Finding a new normal

Shares of Ulta Beauty have defied the gravity of the bear market, posting new all-time highs at regular intervals throughout 2022. So far for the year, Ulta stock is up 16%, and investors seem increasingly excited about the beauty salon business going into the holiday season.

The latest move higher for Ulta stock came after the salon and cosmetics retailer reported its third-quarter financial results for the period ending Oct. 29. The company saw a continuing boom in sales, with revenue jumping 17% to $2.34 billion. Comparable sales grew 14.6% year over year, and earnings of $5.34 per share compared favorably to year-earlier profits of $3.94 per share.

Those numbers were good enough to lead Ulta to boost its full-year 2022 projections substantially. The company increased its guidance for sales by $250 million to $300 million, expecting as much as $10 billion for the year. Similarly, earnings guidance got a $1.70-to-$1.90-per-share boost to a new range of $22.60 to $22.90 per share.

Ulta has benefited from consumers returning to work and leisure activities after the lockdowns early in the pandemic. Just the ability to enjoy the salon experience is a luxury that customers don't take for granted after what happened in 2020 and 2021, and by tapping into people's needs for connection, Ulta has put itself in a prime position to keep reaping rewards into 2023 and beyond.

Steeling its resolve

The steel industry has seen plenty of ups and downs over the long haul, but the gains that some players in steelmaking have seen are surprising. Steel Dynamics stands out even among steel stocks, though, with year-to-date gains of 78% sending the stock to an all-time high.

Steel Dynamics has benefited from favorable conditions that are helping the entire industry. After long pandemic-related delays in construction projects, builders are looking to work off their backlogs, and that's supporting demand for materials like steel.

Even as the global economy has stayed sluggish, the prospects for the Chinese economy to heat back up once COVID-related restrictions get relaxed have looked promising for steel stocks.

Also, Steel Dynamics in particular is doing well because of its electric arc furnace manufacturing methods. By using recycled materials and avoiding some of the worst emissions from steelmakers using more traditional production methods, Steel Dynamics has attracted the attention of companies seeking to emphasize sustainability.

The need for infrastructure could help support strong steel demand for years to come. Even if higher interest rates result in slowing activity in real estate development and other economically sensitive industries, Steel Dynamics appears to be in a strong position to keep realizing gains.

Bucking the trend

Even in a down market, there will always be stocks that move higher. Steel Dynamics and Ulta Beauty have a lot going for their businesses, and that could bring further gains for shareholders in the long run.