// Rem output with px fallback @mixin font-size($sizeValue: 1) { font-size: ($sizeValue * 16) * 1px; font-size: $sizeValue * 1rem; } // Box shadow @mixin box-shadow { box-shadow: $box__shadow_mobile; @include media-breakpoint-up(lg) { box-shadow: $box__shadow; } } // Center block @mixin center-block { display: block; margin-left: auto; margin-right: auto; } // Clearfix @mixin clearfix { content: ""; display: table; table-layout: fixed; } // Clear after (not all clearfix need this also) @mixin clearfix-after { clear: both; } @mixin reset-container { max-width: inherit; padding-left: 0; padding-right: 0; } @mixin reset-list { padding: 0; margin: 0; list-style: none; } @mixin font-awesome-icon { display: inline-block; font: normal normal normal 14px/1 FontAwesome; font-size: inherit; -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; } @mixin btn { line-height: 1; display: inline-block; max-width: 100%; padding: $button__indents; cursor: pointer; text-align: center; overflow: hidden; vertical-align: top; white-space: nowrap; text-overflow: ellipsis; border: $button__border; transition: .3s; text-transform: uppercase; @include font-size(1); font-weight: 400; letter-spacing: 2.56px; @include border-radius(); } @mixin btn-hover{ &:hover, .invert &:hover { transform: translateX(2px) translateY(3px) translateZ(0); box-shadow: none; } } @mixin terms-style() { @include font-size(1.25); margin: 0 3px 8px; border: 1px solid; padding: 0 5px; display: inline-block; @include border-radius; &:hover { box-shadow: none; transform: translateX(2px) translateY(3px) translateZ(0); } } @mixin material-icon { font-family: 'Material Icons'; font-weight: normal; font-style: normal; display: inline-block; line-height: 1; text-transform: none; letter-spacing: normal; word-wrap: normal; white-space: nowrap; direction: ltr; /* Support for all WebKit browsers. */ -webkit-font-smoothing: antialiased; /* Support for Firefox. */ -moz-osx-font-smoothing: grayscale; /* Support for IE. */ font-feature-settings: 'liga'; } @mixin linear-icon { font-family: 'Linearicon'; speak: none; font-style: normal; font-weight: normal; font-variant: normal; text-transform: none; line-height: 1; /* Enable Ligatures */ -webkit-font-feature-settings: "liga"; -moz-font-feature-settings: "liga=1"; -moz-font-feature-settings: "liga"; -ms-font-feature-settings: "liga" 1; -o-font-feature-settings: "liga"; font-feature-settings: "liga"; /* Better Font Rendering */ -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; } // Optional hyphenation @mixin hyphens($mode: auto) { word-wrap: break-word; -webkit-hyphens: $mode; -moz-hyphens: $mode; -ms-hyphens: $mode; // IE10+ -o-hyphens: $mode; hyphens: $mode; } @mixin word-wrap { overflow-wrap: break-word; word-wrap: break-word; } // .hentry, .widget @mixin card { @include border-radius; } // Resize anything @mixin resizable($direction) { resize: $direction; // Options: horizontal, vertical, both overflow: auto; // Per CSS3 UI, `resize` only applies when `overflow` isn't `visible` } // tiles class @mixin tiles( $class_name, $property, $ratio: 1, $breakpoints: $grid-breakpoints, $gutter: $grid-gutter-width, $columns: $grid-columns ) { .#{$class_name}{ @each $breakpoint, $size in $breakpoints{ @if $breakpoint!='xs' and $breakpoint!='sm' { @include media-breakpoint-up( $breakpoint ) { @if $property=='width' { width: percentage($ratio/$columns); } @else { $padding:($size - map-get($container-max-widths, $breakpoint))/2; #{$property}: #{($size - $padding)/$columns*$ratio}; } } } @else { @include media-breakpoint-up( $breakpoint ) { @if $property=='width' { #{$property}: 100%; } @else { #{$property}: 300px; } } } } } } // Triangle @mixin triangle($dir, $w, $h, $clr) { width: 0; height: 0; border-style: solid; @if $dir == top { border-width: 0 $w/2 $h $w/2; border-color: transparent transparent $clr transparent; } @else if $dir == bottom { border-width: $h $w/2 0 $w/2; border-color: $clr transparent transparent transparent; } @else if $dir == left { border-width: $h/2 $w $h/2 0; border-color: transparent $clr transparent transparent; } @else if $dir == right { border-width: $h/2 0 $h/2 $w; border-color: transparent transparent transparent $clr; } @else if $dir == top_left { border-width: $w $w 0 0; border-color: $clr transparent transparent transparent; } @else if $dir == top_right { border-width: 0 $w $w 0; border-color: transparent $clr transparent transparent; } @else if $dir == bottom_right { border-width: 0 0 $w $w; border-color: transparent transparent $clr transparent; } @else if $dir == bottom_left { border-width: $w 0 0 $w; border-color: transparent transparent transparent $clr; } } // Opacity @mixin opacity($opacity) { opacity: $opacity; // IE8 filter $opacity-ie: ($opacity * 100); filter: #{alpha(opacity=$opacity-ie)}; } // Widgets area selectors @mixin contents-area( $parent-symbol:true ) { @if $parent-symbol { .before-content-area &, .after-content-area &, .footer-area--fullwidth &, .tm_pb_column_4_4 & { @content; } } @else { .before-content-area, .after-content-area, .footer-area--fullwidth, .tm_pb_column_4_4 { @content; } } } @mixin loop-area( $parent-symbol:true ) { @if $parent-symbol { .before-loop-area &, .after-loop-area &, .tm_pb_column_2_3 &, .tm_pb_column_3_4 &, .tm_pb_column_1_2 & { @content; } } @else { .before-loop-area, .after-loop-area, .tm_pb_column_2_3, .tm_pb_column_3_4, .tm_pb_column_1_2 { @content; } } } @mixin sidebars-area( $parent-symbol:true ) { @if $parent-symbol { .sidebar &, .tm_pb_column_1_4 &, .tm_pb_column_1_3 &, .footer-area:not(.footer-area--fullwidth) & { @content; } } @else { .sidebar, .tm_pb_column_1_4, .tm_pb_column_1_3, .footer-area:not(.footer-area--fullwidth) { @content; } } } // Custom grid indent @mixin grid-indent( $indent: $grid-gutter-width/2, $child-indent-type: 'padding', $child-selector: '> *' ) { margin-left: - $indent; margin-right: - $indent; @if $child-indent-type=='padding' or $child-indent-type=='margin' { #{$child-selector} { #{$child-indent-type}-left: $indent; #{$child-indent-type}-right: $indent; } } @else { #{$child-selector} { padding-left: $indent; padding-right: $indent; } } } // Responsive css @mixin responsive_css( $property, $value, $sm:null, $md:null, $lg:null, $xl:null ) { #{$property}: #{$value}; @if $sm != null { @include media-breakpoint-up(sm) { #{$property}: #{$sm}; } } @if $md != null { @include media-breakpoint-up(md) { #{$property}: #{$md}; } } @if $lg != null { @include media-breakpoint-up(lg) { #{$property}: #{$lg}; } } @if $xl != null { @include media-breakpoint-up(xl) { #{$property}: #{$xl}; } } } @import "transform"; @import "border-radius"; @import "flex";