Congrats on learning CSS - responsive design is all about making things adapt to what the browser can display to make things show up as well as they can.
Flexbox is useful for responsive design because it has some built-in smarts for making boxes flexible, there are some ways you can use flexbox that can help you content adjust in size, or wrap when it needs to.
CSS grid layout is also very useful for layout in general, and also responsive layout. It's the newest, easiest way to describe layouts in CSS and it also lets you keep your HTML simple. Changing different grid settings inside CSS media queries can be a very powerful way to control what happens to your layout.
And lastly, CSS media queries are probably the biggest feature that helps you build responsive layouts. CSS media queries are conditional rules that wrap an entire stylesheet of CSS rules, and will only apply those rules to the document while the condition is true. You can target conditions based on the browser viewport's dimensions (width, height) as well as some support for what features the browser might have as well.
Here are some free resources that can help you learn responsive web design and CSS grid: