/**
 * Frontend styles for Enfrute Speakers Modal.
 */

/* Trigger link styling */
.enfrute-speaker-trigger {
	cursor: pointer;
	text-decoration: none;
	border-bottom: 2px dashed #4CAF50; /* Primary Green color */
	color: #4CAF50;
	font-family: inherit;
	font-size: inherit;
	font-weight: inherit;
	transition: all 0.25s ease;
	display: inline-block;
}

.enfrute-speaker-trigger:hover {
	color: #2e7d32;
	border-bottom-color: #2e7d32;
	background-color: rgba(76, 175, 80, 0.05);
	border-bottom-style: solid;
}

/* Modal Overlay base */
.enfrute-speaker-modal {
	position: fixed;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	z-index: 999999; /* Stays above header and admin bars */
	display: flex;
	align-items: center;
	justify-content: center;
	opacity: 0;
	visibility: hidden;
	transition: opacity 0.3s ease, visibility 0.3s ease;
}

/* Modal Active State */
.enfrute-speaker-modal.is-active {
	opacity: 1;
	visibility: visible;
}

/* Dark backdrop with blur */
.enfrute-speaker-modal-overlay {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	background: rgba(18, 22, 19, 0.65); /* Rich dark tint */
	backdrop-filter: blur(8px);
	-webkit-backdrop-filter: blur(8px);
}

/* Modal Content Card */
.enfrute-speaker-modal-container {
	position: relative;
	background: #ffffff;
	width: 90%;
	max-width: 680px;
	max-height: 85vh;
	border-radius: 16px;
	box-shadow: 0 20px 50px rgba(0, 0, 0, 0.25);
	z-index: 10;
	overflow-y: auto;
	transform: translateY(30px);
	transition: transform 0.3s cubic-bezier(0.25, 1, 0.5, 1);
	border: 1px solid rgba(255, 255, 255, 0.8);
	font-family: 'Montserrat', sans-serif;
}

/* Prevent body scrolling when modal is open */
body.enfrute-modal-open {
	overflow: hidden;
}

.enfrute-speaker-modal.is-active .enfrute-speaker-modal-container {
	transform: translateY(0);
}

/* Modern close button */
.enfrute-speaker-modal-close {
	position: absolute;
	top: 15px;
	right: 15px;
	background: #f2f3f5;
	border: none;
	width: 32px;
	height: 32px;
	border-radius: 50%;
	font-size: 22px;
	line-height: 1;
	cursor: pointer;
	color: #5c6370;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: all 0.2s ease;
	z-index: 12;
	padding: 0;
}

.enfrute-speaker-modal-close:hover {
	background: #e4e6eb;
	color: #1b1f23;
	transform: rotate(90deg);
}

/* Flex Grid Layout */
.enfrute-speaker-modal-content {
	display: flex;
	flex-direction: row;
	gap: 28px;
	padding: 32px;
}

/* Photo Wrapper */
.enfrute-speaker-modal-photo {
	flex-shrink: 0;
	width: 170px;
	height: 170px;
	border-radius: 12px;
	overflow: hidden;
	box-shadow: 0 6px 16px rgba(0, 0, 0, 0.12);
	border: 3px solid #ffffff;
	background: #f5f6f8;
}

.enfrute-speaker-modal-photo img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

/* Details and Text content */
.enfrute-speaker-modal-details {
	flex-grow: 1;
	display: flex;
	flex-direction: column;
	justify-content: center;
}

/* Speaker Name heading */
.enfrute-speaker-modal-name {
	font-family: 'Montserrat', sans-serif;
	font-size: 22px;
	font-weight: 700;
	color: #1c1e21;
	margin: 0 0 12px 0;
	line-height: 1.25;
}

/* Bio description text */
.enfrute-speaker-modal-bio {
	font-family: 'Montserrat', sans-serif;
	font-size: 14.5px;
	line-height: 1.6;
	color: #4f5660;
}

.enfrute-speaker-modal-bio p {
	margin: 0 0 12px 0;
}

.enfrute-speaker-modal-bio p:last-child {
	margin: 0;
}

/* Responsive adjustment for tablets/mobile */
@media (max-width: 640px) {
	.enfrute-speaker-modal-content {
		flex-direction: column;
		align-items: center;
		text-align: center;
		padding: 24px;
		gap: 20px;
	}

	.enfrute-speaker-modal-photo {
		width: 130px;
		height: 130px;
		margin-top: 15px; /* Leave space for close button */
	}

	.enfrute-speaker-modal-name {
		font-size: 19px;
		margin-bottom: 8px;
	}

	.enfrute-speaker-modal-bio {
		font-size: 13.5px;
	}
}
