// ========================================== // SWIPER // ========================================== .swiper-container { height: 400px; width: 100%; padding-bottom: 85px; } .swiper-wrapper2 { // enough width to have off screen slides partially visible width: 73.8%; will-change: transform; @media (min-width: map-get($breakpoints, 'sm')) { width: 100%; } } .swiper-slide2 { width: 100%; background-color: white; overflow: hidden; &.swiper-slide2-active, &.swiper-slide2-duplicate-active { .slide-image { transform: scale3d(1, 1, 1); } } @media (min-width: map-get($breakpoints, 'sm')) { width: 50%; } @media (min-width: map-get($breakpoints, 'md')) { width: 33.333333%; &.swiper-slide2-next, &.swiper-slide2-prev, &.swiper-slide2-duplicate-next, &.swiper-slide2-duplicate-prev { .slide-image { transform: scale3d(1, 1, 1); } } } @media (min-width: map-get($breakpoints, 'lg')) { width: 25%; } } .swiper-pagination { position: relative; display: flex; justify-content: center; align-items: center; height: 85px; // chained selector hack to handle very specific overrides &#{&} { bottom: 0; } } .swiper-pagination-bullet { background: $theme-color; width: 22px; height: 4px; border-radius: 0; transition: opacity 1s ease; &#{&}#{&} { margin: 0; } @media (min-width: map-get($breakpoints, 'md')) { width: 40px; } } // ========================================== // SLIDES // ========================================== .slide-image { height: 500px; width: 500px; background-repeat: no-repeat; background-size: cover; background-position: center; transform: scale3d(1.3, 1.3, 1); // 3d to hardware accelerate backface-visibility: hidden; will-change: transform; transition: transform 1400ms ease; } .slide-content { padding: 0 2.2rem; display: flex; flex-direction: column; height: 100%; h4 { font-size: 25px; font-weight: 400; margin: 0 0 1rem; padding-top: 2.8rem; flex-grow: 0; } p { display: flex; line-height: 1.8; margin-top: 0; font-size: 14px; flex-grow: 1; } footer { display: flex; justify-content: space-between; width: 100%; padding-bottom: 2.8rem; font-size: 14px; color: #c2c0e0; } a { color: $theme-color; font-size: 12px; font-weight: 700; text-decoration: none; border-bottom: 3px solid currentColor; padding-bottom: 3px; } }