/* ==========================================================================
   YohDev Leadership Modal — block styles (editor + frontend)
   ========================================================================== */

/* --------------------------------------------------------------------------
   Editor placeholder
   -------------------------------------------------------------------------- */
.yd-leadership-modal-editor-placeholder {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: 0.5rem;
	padding: 2rem;
	border: 2px dashed #c3c4c7;
	border-radius: 4px;
	background: #f6f7f7;
	text-align: center;
}

.yd-editor-icon {
	font-size: 2rem;
	line-height: 1;
}

.yd-editor-label {
	margin: 0;
	font-size: 1rem;
	font-weight: 600;
	color: #1e1e1e;
}

.yd-editor-sublabel {
	margin: 0;
	font-size: 0.875rem;
	color: #757575;
}

/* --------------------------------------------------------------------------
   Leader card grid
   -------------------------------------------------------------------------- */
.yd-leadership-modal-block .yd-leaders-grid {
	display: grid;
	grid-template-columns: repeat( auto-fill, minmax( 220px, 1fr ) );
	gap: 2rem;
}

.yd-leader-card {
	display: flex;
	flex-direction: column;
	align-items: center;
	text-align: center;
	padding: 1.5rem 1rem;
	background: #fff;
	border: 1px solid #e0e0e0;
	border-radius: 6px;
	box-shadow: 0 1px 4px rgba( 0, 0, 0, 0.06 );
}

.yd-leader-photo img {
	width: 120px;
	height: 120px;
	object-fit: cover;
	border-radius: 50%;
	margin-bottom: 1rem;
}

.yd-leader-info {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 0.4rem;
	flex: 1;
}

.yd-leader-name {
	margin: 0;
	font-size: 1.1rem;
	font-weight: 700;
	line-height: 1.3;
}

.yd-leader-role {
	margin: 0;
	font-size: 0.875rem;
	color: #555;
	font-style: italic;
}

.yd-modal-trigger {
	margin-top: auto;
	padding-top: 0.75rem;
	cursor: pointer;
}

/* --------------------------------------------------------------------------
   Modal — native <dialog>
   -------------------------------------------------------------------------- */
dialog.yd-modal {
	margin: auto;
	padding: 0;
	width: 90%;
	max-width: 640px;
	max-height: 90dvh;
	overflow-y: auto;
	border: none;
	border-radius: 12px;
	box-shadow: 0 8px 32px rgba( 0, 0, 0, 0.2 );
}

dialog.yd-modal::backdrop {
	background: rgba( 0, 0, 0, 0.55 );
}

.yd-modal-close {
	position: absolute;
	top: 0.875rem;
	right: 0.875rem;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 2.25rem;
	height: 2.25rem;
	padding: 0;
	font-size: 1.25rem;
	line-height: 1;
	background: #fff;
	border: 1px solid #d0d5dd;
	border-radius: 6px;
	cursor: pointer;
	color: #555;
	transition: background 0.15s, border-color 0.15s;
}

.yd-modal-close:hover,
.yd-modal-close:focus {
	background: #f5f5f5;
	border-color: #999;
	outline: 2px solid #1e1e1e;
	outline-offset: 2px;
}

/* --------------------------------------------------------------------------
   Modal content layout
   -------------------------------------------------------------------------- */
.yd-modal-content {
	display: flex;
	flex-direction: column;
	gap: 1.25rem;
	padding: 2rem;
}

@media ( min-width: 480px ) {
	.yd-modal-content {
		flex-direction: row;
		align-items: flex-start;
	}

	.yd-modal-photo {
		flex-shrink: 0;
	}
}

.yd-modal-photo img {
	width: 120px;
	height: 120px;
	object-fit: cover;
	border-radius: 50%;
}

.yd-modal-body {
	display: flex;
	flex-direction: column;
	gap: 0.75rem;
	flex: 1;
	min-width: 0;
}

.yd-modal-name {
	margin: 0;
	font-size: 1.4rem;
	font-weight: 700;
	line-height: 1.2;
	padding-right: 2rem; /* clear close button */
}

.yd-modal-role {
	margin: 0;
	font-size: 0.9rem;
	font-style: italic;
	color: #555;
}

.yd-modal-bio {
	font-size: 0.95rem;
	line-height: 1.6;
}

.yd-modal-bio p:first-child {
	margin-top: 0;
}

.yd-modal-bio p:last-child {
	margin-bottom: 0;
}

.yd-modal-quote {
	margin: 0;
	padding: 0.875rem 1.25rem;
	font-style: italic;
	font-size: 0.95rem;
	color: #444;
	background: #f5f5f5;
	border-radius: 8px;
}

.yd-modal-quote::before {
	content: '\201C';
}

.yd-modal-quote::after {
	content: '\201D';
}

.yd-modal-contact {
	border-top: 1px solid #e0e0e0;
	padding-top: 0.75rem;
	display: flex;
	flex-direction: column;
	gap: 0.5rem;
}

.yd-modal-contact-heading {
	margin: 0 0 0.25rem;
	font-size: 0.85rem;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: 0.05em;
	color: #555;
}

.yd-modal-contact-item {
	display: flex;
	align-items: center;
	gap: 0.75rem;
	padding: 0.75rem 1rem;
	border: 1px solid #e0e0e0;
	border-radius: 8px;
	font-size: 0.9rem;
	color: inherit;
	text-decoration: none;
	transition: background 0.15s, border-color 0.15s;
}

.yd-modal-contact-item:hover,
.yd-modal-contact-item:focus {
	background: #f5f5f5;
	border-color: #bbb;
}

.yd-modal-contact-icon {
	flex-shrink: 0;
	color: #555;
}

/* --------------------------------------------------------------------------
   Body scroll lock — triggered by the open dialog attribute
   -------------------------------------------------------------------------- */
body:has( dialog.yd-modal[open] ) {
	overflow: hidden;
}
