
/* the purpose of container is to set the width of the entire grid */
.grid-container {
    width: 100%;
    max-width: 1200px;
}

.grid-container * {
    box-sizing: border-box;
}

/* the purpose of the row element is to keep the columns inside it from overflowing onto other rows */

.row:before,
.row:after {
    content: "";
    display: table;
    clear: both;
}

/* if columns are empty, to prevent from stacking on top of each other, give columns a min-height of 1px */
[class*='col-'] {
    float: left;
    min-height: 1px;
    
    /* 6-column */
    width: 16.66%;
    
    /* gutter */
    padding: 12px;
}

.col-1 {
    width: 16.66%;
}

.col-2 {
    width: 33.33%;
}

.col-3 {
    width: 50%; 
}

.col-4 {
    width: 66.664%; 
}

.col-5 {
    width: 83.33%; 
}

.col-6 {
    width: 100%; 
}

@media all and (max-width: 900px) {
    .col-1 { width: 33.33%; }
    .col-2 { width: 50%; }
    .col-3 { width: 83.33%; }
    .col-4 { width: 100%; }
    .col-5 { width: 100%; }
    .col-6 { width: 100%; }
}

.row .col-2:last-of-type {
    width: 100%;
}

.row .col-5 ~ .col-1 {
    width: 100%;
}

@media all and (max-width: 650px) {
    .col-1 { width: 50%; }
    .col-2 { width: 100%; }
    .col-3 { width: 100%; }
    .col-4 { width: 100%; }
    .col-5 { width: 100%; }
    .col-6 { width: 100%; }
}


/*-----------------------------------------------------------------*/
body {
    background: Aquamarine;
}

div.outline {
    margin: 0 auto;
    text-align: center;
}

div.outline .row {
    margin-top: 1em;
}

.row div {
    border: 1px solid #ccc;
    background: LightSeaGreen;
}
