| 1 |
// CHECKED: |
| 2 |
@import "./mixins"; |
| 3 |
|
| 4 |
.layout-flex { |
| 5 |
display: flex; |
| 6 |
flex-wrap: wrap; |
| 7 |
gap: calc(var(--gap, 15) * 1px); |
| 8 |
@include for(".betterdocs-category-grid-three-wrapper") { |
| 9 |
@include if(".betterdocs-category-grid-inner-wrapper", ".layout-3") { |
| 10 |
display: grid; |
| 11 |
gap: calc(var(--gap, 48) * 1px); |
| 12 |
.betterdocs-single-category-wrapper { |
| 13 |
margin-top: 10px; |
| 14 |
margin-bottom: 10px; |
| 15 |
} |
| 16 |
} |
| 17 |
} |
| 18 |
// row-gap: 30px; |
| 19 |
// column-gap: 30px; |
| 20 |
@for $i from 1 through 12 { |
| 21 |
&.docs-col-#{$i}, |
| 22 |
&.betterdocs-column-#{$i} { |
| 23 |
grid-template-columns: repeat(#{$i}, 1fr); |
| 24 |
@include responsive-below("small-laptop") { |
| 25 |
@if ($i >= 3) { |
| 26 |
grid-template-columns: repeat(3, 1fr); |
| 27 |
} @else { |
| 28 |
grid-template-columns: repeat(#{$i}, 1fr); |
| 29 |
} |
| 30 |
} |
| 31 |
@include responsive("tablet") { |
| 32 |
@if ($i >= 2) { |
| 33 |
grid-template-columns: repeat(2, 1fr); |
| 34 |
} @else { |
| 35 |
grid-template-columns: repeat(#{$i}, 1fr); |
| 36 |
} |
| 37 |
} |
| 38 |
@include responsive("phone") { |
| 39 |
grid-template-columns: 1fr; |
| 40 |
} |
| 41 |
} |
| 42 |
} |
| 43 |
} |
| 44 |
.masonry { |
| 45 |
@for $i from 1 through 12 { |
| 46 |
&.docs-col-#{$i}, |
| 47 |
&.betterdocs-column-#{$i} { |
| 48 |
.betterdocs-single-category-wrapper { |
| 49 |
@include responsive-below("small-laptop") { |
| 50 |
@if ($i >= 3) { |
| 51 |
width: 30% !important; |
| 52 |
margin-left: 10px; |
| 53 |
margin-right: 10px; |
| 54 |
} |
| 55 |
} |
| 56 |
@include responsive("tablet") { |
| 57 |
@if ($i >= 3) { |
| 58 |
width: 45% !important; |
| 59 |
margin-left: 15px; |
| 60 |
margin-right: 15px; |
| 61 |
} |
| 62 |
} |
| 63 |
@include responsive("phone") { |
| 64 |
width: 100% !important; |
| 65 |
margin: 0px; |
| 66 |
} |
| 67 |
} |
| 68 |
} |
| 69 |
} |
| 70 |
} |
| 71 |
|
| 72 |
.betterdocs-single-category-wrapper { |
| 73 |
flex: 1 0 calc((100% / var(--column, 3)) - (var(--gap, 15) * 1px)); |
| 74 |
} |
| 75 |
|
| 76 |
@media only screen and (min-width: 1025px) { |
| 77 |
.betterdocs-blocks-grid { |
| 78 |
display: grid; |
| 79 |
@for $i from 1 through 6 { |
| 80 |
.betterdocs-column-desktop-#{$i} { |
| 81 |
grid-template-columns: repeat(#{$i}, 1fr); |
| 82 |
} |
| 83 |
} |
| 84 |
} |
| 85 |
} |
| 86 |
|
| 87 |
@media only screen and (max-width: 1024px) and (min-width: 766px) { |
| 88 |
.betterdocs-blocks-grid { |
| 89 |
display: grid; |
| 90 |
@for $i from 1 through 6 { |
| 91 |
.betterdocs-column-tab-#{$i} { |
| 92 |
grid-template-columns: repeat(#{$i}, 1fr); |
| 93 |
} |
| 94 |
} |
| 95 |
} |
| 96 |
} |
| 97 |
|
| 98 |
@media only screen and (max-width: 767px) { |
| 99 |
.betterdocs-blocks-grid { |
| 100 |
display: grid; |
| 101 |
@for $i from 1 through 6 { |
| 102 |
.betterdocs-column-mobile-#{$i} { |
| 103 |
grid-template-columns: repeat(#{$i}, 1fr); |
| 104 |
} |
| 105 |
} |
| 106 |
} |
| 107 |
.betterdocs-single-category-wrapper { |
| 108 |
flex: 1 0 calc((100% / 2) - (var(--gap, 15) * 1px)); |
| 109 |
} |
| 110 |
.betterdocs-category-grid-wrapper .betterdocs-single-category-wrapper { |
| 111 |
flex: 1 0 calc((100% / 1) - (var(--gap, 15) * 1px)); |
| 112 |
} |
| 113 |
} |
| 114 |
|
| 115 |
@media only screen and (max-width: 500px) { |
| 116 |
.betterdocs-single-category-wrapper { |
| 117 |
flex: 1 0 calc((100% / 1) - (var(--gap, 15) * 1px)); |
| 118 |
} |
| 119 |
} |
| 120 |
|