KNACSS/sass/base/_layout.scss

41 lines
703 B
SCSS
Raw Normal View History

/* ---------------------------- */
/* ==Layout classes */
/* ----------------------------- */
2014-05-07 10:45:47 +02:00
/* Global container */
.layout-maxed {
display: grid;
2017-09-06 14:25:58 +02:00
@each $key,
$value in $breakpoints {
@media (min-width: #{$value}) {
grid-template-columns:
minmax($spacer-small, 1fr)
minmax(auto, $value)
minmax($spacer-small, 1fr);
}
}
2017-10-16 16:03:25 +02:00
}
/* Center all children */
.layout-maxed > * {
grid-column: 2;
2013-09-12 11:59:14 +02:00
}
2014-05-07 10:45:47 +02:00
/* Hero box */
.layout-hero {
grid-column: 1 / -1;
display: grid;
grid-template-columns: inherit;
2013-09-12 11:59:14 +02:00
}
2014-05-07 10:45:47 +02:00
.layout-hero > * {
grid-column: 2;
2013-09-12 11:59:14 +02:00
}
2014-05-07 10:45:47 +02:00
/* Hero image */
.layout-hero-img {
grid-column: 1 / -1;
justify-self: center;
max-width: 100%;
}