Foundation Grid System
The Foundation grid system has 12 columns.
If you don't need 12 columns, you can combine some columns to create wider columns.

The Foundation grid system is responsive. Columns automatically resize based on screen size. On large screens there may be three columns, while on small screens there may be three single columns arranged in order.
Grid Columns
The Foundation grid system has three columns:
.small(mobile).medium(tablet devices).large(computer devices: laptops, desktops)
The above classes can be combined to create more flexible layouts
Basic Grid Structure
The following is a basic Foundation grid structure example:
Example
<
div
class=
"row"
<
div
class="small|medium|large-num columns"
<
/div
<
/div
<
div
class=
"row"
<
div
class="small|medium|large-num columns"
<
/div
<
div
class="small|medium|large-num columns"
<
/div
<
div
class="small|medium|large-num columns"
<
/div
<
/div
<
div
class=
"row"...
<
/div
First, create a row ( "small-12 columns" .small-12 yellow "small-8 columns" .small-8 beige "small-4 columns" .small-4 gray "large-9 small-8 columns" .small-8 .large-9 pink "large-3 small-4 columns" .small-4 .large-3 orange Try it » In the example, the first row's The second row creates two columns, In the third row we added two extra columns ( The following table summarizes the Foundation grid system across multiple devices: | | Small devices
Maximum grid ( < style .row { max-width: 100%; } < /style Try it » If you use the default max-width, but want the background color to span the entire page width, you can use Try it »small-num, medium-num and large-num class. Note: the number of columns num must add up to 12:
Example
<
div
class=
"row"
<
div
class=<
/div
<
/div
<
div
class=
"row"
<
div
class=<
/div
<
div
class=<
/div
<
/div
<
div
class=
"row"
<
div
class=<
/div
<
div
class=<
/div
<
/div.small-12, which creates 12 columns (100% width).
.small-4 has a width of 33.3%,.small-8 has a width of 66.6%..large-3 and .large-9). This means that on large screen sizes, the columns become 25% (.large-3) and 75% (.large-9) ratio. At the same time we also specified the column ratio on small screens as 33% (.small-4) and 66% (.small-8). This combination is very helpful for display effects on different screens.Grid Options
Phones (<40.0625em (640px)) | Medium devices
Tablets (>=40.0625em (640px)) | Large devices
Laptops & Desktops (>=64.0625em (1025px)) | | --- | --- | --- | --- | | Grid behavior | Always horizontal | Starts collapsed, horizontal above the breakpoint | Starts collapsed, horizontal above the breakpoint | | Class Prefix | .small-* | .medium-* | .large-* | | Number of Classes | 12 | 12 | 12 | | Nesting Allowed | Yes | Yes | Yes | | Offsets | Yes | Yes | Yes | | Column ordering | Yes | Yes | Yes |
Wide Screens
.row) width is 62.5rem. On widescreen, when the width is greater than 62.5rem, columns will not span the page width even if the width is set to 100%. But you can reset max-width via CSS:Example
.row to wrap the entire container and specify the background color you need:Example