/**
 * WGS Team Members — guides slider (home) and grid (team page).
 * Ported from the "WP Team Showcase and Slider" design-2 / design-3 output
 * and the theme overrides that were applied on top of it.
 */

.wgs-team,
.wgs-team * {
	box-sizing: border-box;
}

/* ---------- Card: shared ---------- */

.wgs-team-card__media {
	position: relative;
	overflow: hidden;
	background: #f1f1f1;
}

.wgs-team-card__image {
	position: absolute;
	top: 0;
	left: 0;
	width: 100% !important;
	height: 100% !important;
	object-fit: cover;
	object-position: top center;
	transition: all 0.2s ease-in-out 0s;
}

/* Hidden until Magnific Popup is available (see team-members.js) */
.wgs-team-card__popup-link {
	display: none;
}

.wgs-team--popups .wgs-team-card__popup-link {
	position: absolute;
	top: 0;
	left: 0;
	z-index: 2;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	height: 100%;
	color: #fff;
	font-size: 30px;
	text-decoration: none !important;
	opacity: 0;
	transform: scale(1);
	transition: 0.3s ease-in-out;
}

.wgs-team--popups .wgs-team-card__media:hover .wgs-team-card__popup-link,
.wgs-team--popups .wgs-team-card__popup-link:focus {
	color: #fff;
	opacity: 1;
	transform: scale(1.4);
}

.wgs-team-card__name {
	font-size: 24px;
	line-height: 34px;
}

.wgs-team-link {
	display: inline-block;
	width: 35px;
	padding: 5px 10px;
	background: #555;
	color: #fff !important;
	text-align: center;
	transition: background-color 200ms linear;
}

.wgs-team-link:hover,
.wgs-team-link:focus {
	background: #3498db;
}

/* ---------- Slider (design-2) ---------- */

.wgs-team-slider {
	position: relative;
	padding-bottom: 30px;
}

/* Before Slick starts, or without it: a wrapping row of cards */
.wgs-team-slider:not(.slick-initialized) {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
}

.wgs-team-slider:not(.slick-initialized) > .wgs-team-card {
	width: 33.3333%;
}

.wgs-team-card--slider {
	padding: 0 10px;
	text-align: center;
}

.wgs-team-card--slider .wgs-team-card__media {
	width: 250px;
	max-width: 100%;
	height: 250px;
	margin: 0 auto;
	border-radius: 100%;
}

.wgs-team-card--slider .wgs-team-card__image {
	border-radius: 100%;
}

.wgs-team-card__overlay {
	position: absolute;
	right: 0;
	bottom: 0;
	left: 0;
	padding: 10px 5px;
	background: rgba(0, 0, 0, 0.5);
	color: #fff;
	text-align: center;
}

.wgs-team-card__bio {
	margin: 5px 0;
	padding: 10px 3px;
}

.wgs-team-card__bio p {
	margin: 0;
	text-align: center;
}

.wgs-team-card__links {
	margin-bottom: 10px;
	text-align: center;
}

/* Slick structure, scoped so it does not depend on the theme's slick rules */
.wgs-team-slider.slick-slider {
	user-select: none;
	touch-action: pan-y;
	-webkit-tap-highlight-color: transparent;
}

.wgs-team-slider .slick-list {
	position: relative;
	display: block;
	margin: 0;
	padding: 0;
	overflow: hidden;
	transform: translate3d(0, 0, 0);
}

.wgs-team-slider .slick-track {
	position: relative;
	top: 0;
	left: 0;
	display: block;
	margin-right: auto;
	margin-left: auto;
	visibility: visible;
	transform: translate3d(0, 0, 0);
}

.wgs-team-slider .slick-track::before,
.wgs-team-slider .slick-track::after {
	display: table;
	content: '';
}

.wgs-team-slider .slick-track::after {
	clear: both;
}

.wgs-team-slider .slick-slide {
	display: block;
	float: left;
	height: 100%;
	min-height: 1px;
	outline: none;
}

/* Scoped under .wgs-team-slider: BeTheme's `.button-default button` rule
   (white text, 14px, padding) otherwise wins and hides the chevrons. */
.wgs-team-slider .wgs-team-slider__arrow {
	position: absolute;
	top: 50%;
	z-index: 99;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 20px;
	height: 26px;
	margin: -30px 0 0 !important;
	padding: 0 !important;
	border: 0 !important;
	border-radius: 0 !important;
	background: transparent !important;
	box-shadow: none !important;
	color: #333;
	font-size: 26px;
	line-height: 26px;
	cursor: pointer;
}

.wgs-team-slider .wgs-team-slider__arrow i {
	color: inherit;
	font-size: inherit;
	line-height: inherit;
}

.wgs-team-slider .wgs-team-slider__arrow--prev {
	left: -8px;
}

.wgs-team-slider .wgs-team-slider__arrow--next {
	right: -8px;
}

/* ---------- Grid (design-3, 4 columns) ---------- */

.wgs-team-grid {
	display: flex;
	flex-wrap: wrap;
	margin: 0;
}

.wgs-team-card--grid {
	width: 100%;
	margin-bottom: 30px;
	border-right: 1px solid #e8e8e8;
	border-left: 1px solid #e8e8e8;
}

.wgs-team-card--grid .wgs-team-card__media {
	width: 100%;
	height: 240px;
}

.wgs-team-card--grid .wgs-team-card__name {
	padding: 10px;
	border-bottom: 1px solid #e8e8e8;
	text-align: center;
	text-transform: uppercase;
	transition: background-color 200ms linear;
}

.wgs-team-card--grid:hover .wgs-team-card__name {
	background: #86c50d;
	color: #fff;
}

@media only screen and (min-width: 641px) {
	.wgs-team-card--grid {
		width: 25%;
		border-right: 0;
	}

	.wgs-team-card--grid:nth-child(4n),
	.wgs-team-card--grid:last-child {
		border-right: 1px solid #e8e8e8;
	}
}

@media only screen and (max-width: 959px) {
	.wgs-team-slider:not(.slick-initialized) > .wgs-team-card {
		width: 50%;
	}
}

@media only screen and (max-width: 640px) {
	.wgs-team-slider:not(.slick-initialized) > .wgs-team-card {
		width: 100%;
	}
}

/* ---------- Popup ---------- */

/* Kept hidden on the page without relying on the theme's Magnific CSS */
.wgs-team-popup.mfp-hide {
	display: none !important;
}

.wgs-team-popup {
	position: relative;
	width: 100%;
	max-width: 500px;
	margin: 40px auto;
	padding: 0;
	background: #fff;
	line-height: normal;
	text-align: left;
}

.wgs-team-popup__header {
	position: relative;
	height: 400px;
	overflow: hidden;
	background-color: #f1f1f1;
	background-position: center top;
	background-repeat: no-repeat;
	background-size: cover;
	color: #fff;
}

.wgs-team-popup__info {
	position: absolute;
	bottom: 0;
	left: 0;
	width: 100%;
	padding: 15px 20px;
	background: linear-gradient(to bottom, rgba(0, 0, 0, 0) 0, rgba(0, 0, 0, 0.7) 100%);
}

.wgs-team-popup__name {
	font-size: 24px;
	line-height: 34px;
}

.wgs-team-popup__body {
	padding: 15px 20px;
}

.wgs-team-popup__links {
	padding-bottom: 10px;
}

.wgs-team-popup-wrap button.mfp-close {
	background: none !important;
	box-shadow: none !important;
}
