@ -31,4 +31,72 @@ You can deploy, or publish your terrarium on the web using Azure Static Web Apps
3. Walk through the wizard creating your app. Make sure you set the app root to either be `/solution` or the root of your codebase. There's no API in this app, so don't worry about adding that. A github folder will be created in your forked repository that will help Azure Static Web Apps' build services, build and publish your app to a new URL.
---
## 💡 Real-World Flexbox Example: Navigation Bar
Flexbox is commonly used in creating responsive navigation bars. Here's a real-world example:
### HTML
```html
<navclass="navbar">
<divclass="logo">MySite</div>
<ulclass="nav-links">
<li><ahref="#">Home</a></li>
<li><ahref="#">About</a></li>
<li><ahref="#">Contact</a></li>
</ul>
</nav>
### CSS
.navbar {
display: flex;
justify-content: space-between; /* Push logo to left, links to right */
align-items: center;
padding: 10px 20px;
background-color: #1e1e1e;
color: white;
}
.nav-links {
display: flex;
gap: 15px;
list-style: none;
}
---
## 🧭 Understanding Flexbox with a Real-World Analogy
Think of **Flexbox** as packing a **suitcase** with flexible compartments.
- Each item (child element) adjusts its size and position based on available space.
- If there's extra room, items expand to fill it.
- If space is tight, they shrink or wrap to stay inside the container.
Just like how you might align socks, shirts, and shoes neatly in rows, Flexbox helps align items in a row or column—**with flexibility**.