/* Grille équipe JMS — styles alignés sur la page Elementor 4999 */

/* Conteneur Elementor page équipe : 1 colonne (grille 5 col = .jms-membres-grid) */
.elementor-4999 .elementor-element.elementor-element-2fa39ef,
.elementor-element.team-grid.team-box {
	--e-con-grid-template-columns: repeat(1, 1fr) !important;
	--e-con-grid-template-rows: auto !important;
	grid-template-columns: repeat(1, 1fr) !important;
}

.jms-membres-wrap {
	width: 100%;
}

.jms-membres-wrap .team-member,
.jms-membres-wrap .jms-membre-card {
	display: block;
	width: 100%;
}

/* Grille membres — !important pour primer sur l’ancien CSS Additional CSS (.team-grid) */
.jms-membres-wrap .jms-membres-grid {
	display: grid !important;
	grid-template-columns: repeat(5, 1fr) !important;
	gap: 20px;
	grid-auto-rows: 1fr;
}

.jms-membres-grid > .team-member,
.jms-membres-grid > .jms-membre-card {
	box-shadow: 0 0 10px 0 rgba(0, 0, 0, 0.5);
	background: #fff;
}

.jms-membres-grid > .team-member .profile-card,
.jms-membres-grid > .jms-membre-card .profile-card {
	box-shadow: none !important;
	height: 100%;
}

.jms-membres-grid .ekit-wid-con,
.jms-membres-grid .profile-square-v {
	height: 100%;
}

.jms-membres-grid .profile-card .ekit-team-popup .ekit-team-img {
	height: auto !important;
	width: 100%;
}

.jms-membres-grid .profile-card .ekit-team-popup .ekit-team-img img {
	width: 100%;
	height: auto;
}

.jms-membres-grid .profile-card {
	padding: 20px 20px 40px;
}

.jms-membres-grid .profile-header {
	margin-bottom: 20px;
	width: 100%;
}

.jms-membres-grid .profile-body .profile-title {
	font-size: 22px;
	font-weight: 400;
	margin: 0;
}

.jms-membres-grid a.ekit-team-popup.jms-open-modal,
.jms-membres-grid .profile-body .profile-title a.ekit-team-popup.jms-open-modal {
	color: #000 !important;
	text-decoration: none;
}

.jms-membres-grid a.ekit-team-popup.jms-open-modal:hover,
.jms-membres-grid a.ekit-team-popup.jms-open-modal:focus,
.jms-membres-grid .profile-body .profile-title a.ekit-team-popup.jms-open-modal:hover,
.jms-membres-grid .profile-body .profile-title a.ekit-team-popup.jms-open-modal:focus {
	color: #000 !important;
}

.jms-membres-grid .profile-body .profile-designation {
	color: rgba(0, 0, 0, 0.5);
	font-size: 13px;
	margin-bottom: 15px;
}

.jms-membres-grid .profile-content {
	font-size: 14px;
	color: #000;
}

.jms-membres-grid .profile-content p {
	margin: 0 0 0.35em;
}

.jms-membres-grid .profile-content a {
	color: #000;
	text-decoration: none;
}

/* Filtres */
#team-filters {
	margin-bottom: 20px;
}

.filter-group {
	margin: 10px 0;
}

#team-filters button {
	background: #fff;
	border: 2px solid #ccc;
	color: #333;
	padding: 8px 18px;
	margin: 5px;
	font-size: 14px;
	border-radius: 4px;
	cursor: pointer;
	transition: 0.3s;
	text-transform: uppercase;
}

#team-filters button.active {
	background: #f58220;
	border-color: #f58220;
	color: #fff;
}

#team-filters button:hover {
	background: #f58220;
	border-color: #f58220;
	color: #fff;
}

/* Modal */
.jms-membres-modal-overlay {
	position: fixed;
	inset: 0;
	background: rgba(0, 0, 0, 0.65);
	z-index: 99998;
}

.jms-membres-modal {
	position: fixed;
	inset: 0;
	z-index: 99999;
	overflow-x: hidden;
	overflow-y: auto;
	padding: 60px 15px;
	-webkit-overflow-scrolling: touch;
}

.jms-membres-modal[hidden],
.jms-membres-modal-overlay[hidden] {
	display: none !important;
}

.jms-membres-modal .modal-dialog {
	display: flex;
	align-items: center;
	width: 100%;
	max-width: 920px;
	min-height: calc(100% - 120px);
	margin: 0 auto;
}

.jms-membres-modal .modal-content {
	position: relative;
	width: 100%;
	background: #fff;
	box-shadow: 0 28px 40px 0 rgba(0, 0, 0, 0.1);
}

body.admin-bar .jms-membres-modal {
	top: 32px;
	padding-top: 40px;
}

@media screen and (max-width: 782px) {
	body.admin-bar .jms-membres-modal {
		top: 46px;
	}
}

.jms-membres-modal .modal-body {
	padding: 60px 40px;
	display: flex;
	flex-wrap: wrap;
}

.jms-membres-modal-close {
	position: absolute;
	top: 10px;
	right: 10px;
	width: 40px;
	height: 40px;
	padding: 0;
	color: #fff;
	background-color: #f58220;
	border: 0;
	border-radius: 0;
	font-size: 18px;
	line-height: 1;
	cursor: pointer;
	z-index: 2;
	display: flex;
	align-items: center;
	justify-content: center;
}

.jms-membres-modal-close svg {
	width: 16px;
	height: 16px;
}

.jms-membres-modal .ekit-team-modal-img {
	width: 100%;
	margin-bottom: 30px;
}

.jms-membres-modal .ekit-team-modal-img > img {
	display: block;
	width: 100%;
	box-shadow: 0 28px 40px 0 rgba(0, 0, 0, 0.1);
}

.jms-membres-modal .ekit-team-modal-info {
	width: 100%;
}

.jms-membres-modal .ekit-team-modal-title {
	margin-top: 0;
	margin-bottom: 8px;
	color: #000;
	font-size: 22px;
	font-weight: 600;
}

.jms-membres-modal .ekit-team-modal-position {
	margin-bottom: 35px;
	color: rgba(0, 0, 0, 0.5);
	font-size: 13px;
}

.jms-membres-modal .ekit-team-modal-content {
	margin-bottom: 22px;
	font-size: 15px;
	line-height: 1.6;
	color: #333;
}

.jms-membres-modal .ekit-team-modal-list {
	margin: 0 0 25px;
	padding: 0;
	list-style: none;
	color: #656565;
	font-size: 15px;
}

.jms-membres-modal .ekit-team-modal-list > li {
	padding: 19px 0;
	border-top: 1px solid rgba(0, 0, 0, 0.05);
}

.jms-membres-modal .ekit-team-modal-list > li:last-child {
	border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.jms-membres-modal .ekit-team-modal-list strong {
	font-weight: 600;
	padding-right: 18px;
}

.jms-membres-modal .ekit-team-modal-list a {
	color: inherit;
	text-decoration: none;
}

@media screen and (min-width: 481px) {
	.jms-membres-modal .ekit-team-modal-img {
		flex: 0 0 33.333333%;
		max-width: 33.333333%;
		margin-bottom: 0;
	}

	.jms-membres-modal .ekit-team-modal-info.has-img {
		flex: 0 0 66.666667%;
		max-width: 66.666667%;
		padding-left: 30px;
	}
}

@media screen and (min-width: 992px) {
	.jms-membres-modal .ekit-team-modal-info.has-img {
		padding-left: 50px;
	}
}

@media (max-width: 1200px) {
	.jms-membres-wrap .jms-membres-grid {
		grid-template-columns: repeat(3, 1fr) !important;
	}
}

@media (max-width: 1024px) {
	.jms-membres-wrap .jms-membres-grid {
		grid-template-columns: repeat(2, 1fr) !important;
	}
}

@media (max-width: 767px) {
	.jms-membres-wrap .jms-membres-grid {
		grid-template-columns: repeat(1, 1fr) !important;
		padding: 0 50px;
	}

	.jms-membres-modal .modal-body {
		display: block;
		padding: 60px 25px 40px;
	}
}

body.jms-modal-open {
	overflow: hidden;
}
