/**
 * VM Meet Your Teacher Block
 *
 * @package club-garrigue
 * @since 1.0.0
 */

/* ─── Block wrapper ─────────────────────────────────────────────── */

.vm-teacher-block {
	container-type: inline-size;
	display: flex;
	flex-direction: column;
	align-items: center;
	
	padding: clamp(40px, 9vw, 100px) 30px;

	
	width: 100vw !important;
	overflow: hidden !important;
	position: relative;
	max-width: unset !important;
	margin-left: calc(50% - 50vw) !important;
	margin-top: 0 !important;
}

.vm-teacher-block.has-white-background-color:after{
	content: '';
	background: #fff;
	height: 100%;
	width: 100vw;
	margin-left: calc(50% - 50vw);
	position: absolute;
	left: 0;
	top: 0;
	z-index: -1;
}

@media (max-width: 599px) {
	.vm-teacher-block{
		padding-bottom: 60px !important;
	}
}

/* Gutenberg block text color: descendants use explicit palette colors by default;
   when the block has a text color, inherit so the editor choice applies. */
.vm-teacher-block.has-text-color .vm-teacher-eyebrow,
.vm-teacher-block.has-text-color .vm-teacher-title,
.vm-teacher-block.has-text-color .vm-teacher-title em,
.vm-teacher-block.has-text-color .vm-teacher-name,
.vm-teacher-block.has-text-color .vm-teacher-subtitle,
.vm-teacher-block.has-text-color .vm-teacher-text,
.vm-teacher-block.has-text-color .vm-teacher-stat-number,
.vm-teacher-block.has-text-color .vm-teacher-stat-label,
.vm-teacher-block.has-text-color .vm-teacher-social-link {
	color: inherit;
}

.vm-teacher-block.has-text-color .vm-teacher-read-more {
	color: inherit;
}

.vm-teacher-block.has-text-color .vm-teacher-read-more:hover,
.vm-teacher-block.has-text-color .vm-teacher-read-more:focus-visible {
	color: inherit;
	opacity: 0.85;
}

/* ─── Centred header (eyebrow + title) ───────────────────────────── */

.vm-teacher-header {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 0.5rem;
	text-align: center;
	max-width: 640px;
	margin-bottom: 36px;
}

.vm-teacher-eyebrow {
	font-family: var(--font-sans);
	font-size: 11px;
	font-weight: 600;
	text-transform: uppercase;
	color: var(--wp--preset--color--stone);
	margin: 0;

    letter-spacing: 3.5px;
    line-height: 1;
    margin-bottom: 12px;
}

.vm-teacher-title {
	font-family: var(--font-serif);
	font-size: var(--wp--preset--font-size--huge) !important;
	line-height: 1.2;
	color: var(--ink);
	margin: 0;
}

.vm-teacher-title em {
	font-style: italic;
	color: var(--wp--preset--color--accent);
}

/* ─── Two-column body ────────────────────────────────────────────── */

.vm-teacher-body {
	display: grid;
	grid-template-columns: 1fr 1fr;
	align-items: flex-start;
	width: 100%;
	max-width: var(--max-width);
	gap: 64px;
}

/* ─── Image ──────────────────────────────────────────────────────── */

.vm-teacher-media {
	overflow: hidden;
	border-radius: 4px;
}

.vm-teacher-img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
	height: 480px;
}

/* ─── Content column ─────────────────────────────────────────────── */

.vm-teacher-content {
	display: flex;
	flex-direction: column;
	padding: 30px 0;
	padding-right: 0;
	padding-top: 0;
}

@media (max-width: 760px) {
	.vm-teacher-content{
		padding: 0;
	}
}

@media (max-width: 599px) {
	.vm-teacher-content{
		gap: 0;
	}

	.vm-teacher-content h3,
	.vm-teacher-content .vm-teacher-subtitle{
		margin-bottom: 15px;
	}
}

/* ─── Teacher name ───────────────────────────────────────────────── */

.vm-teacher-name {
	font-family: var(--font-serif);
    font-weight: 500;
    margin-bottom: 24px;
	line-height: 1.2;
	color: var(--wp--preset--color--accent);
}

@media (max-width: 599px) {
	.vm-teacher-name{
		font-size: 31px;
	}
}

/* ─── Subtitle ───────────────────────────────────────────────────── */

.vm-teacher-subtitle {
	text-transform: uppercase;

	color: var(--stone);
    font-size: 16px;
    line-height: 1.3;
    margin-bottom: 0px;
    font-weight: 300;
	letter-spacing: 1px;
}

/* ─── Body text ──────────────────────────────────────────────────── */

.vm-teacher-text {
	font-family: var(--font-sans);
	line-height: 1.7;
	color: var(--wp--preset--color--stone);
	font-size: clamp(0.875rem, 0.875rem + ((1vw - 0.2rem) * 0.344), 1.15rem);
    line-height: 1.88;
    margin-bottom: 20px;
    font-weight: 300;

	color: var(--wp--preset--color--stone);
    font-size: 15px;
    line-height: 1.88;
    margin-bottom: 18px;
    font-weight: 300;
}

.vm-teacher-text > *:first-child { margin-top: 0; }
.vm-teacher-text > *:last-child  { margin-bottom: 0; }

.vm-teacher-text-wrap {
	width: 100%;
}

.vm-teacher-text-clip {
	position: relative;
	overflow: hidden;
}

/* Off-flow measurement for collapse height (JS toggles class briefly). */
.vm-teacher-text--excerpt.vm-teacher-text--measure {
	visibility: hidden;
	position: absolute;
	left: 0;
	top: 0;
	width: 100%;
	height: auto;
	margin: 0;
	pointer-events: none;
	z-index: 0;
}

.vm-teacher-text-wrap .vm-teacher-text--full[hidden] {
	display: none;
}

.vm-teacher-read-more:disabled {
	cursor: wait;
	opacity: 0.7;
}

.vm-teacher-read-more {
	display: inline-flex;
	align-items: center;
	margin-top: 0.5rem;
	padding: 0;
	border: none;
	background: none;
	font-family: var(--font-sans);
	font-size: 15px;
	font-weight: 500;
	line-height: 1.4;
	color: var(--wp--preset--color--accent);
	cursor: pointer;
	text-decoration: underline;
	transition: color 0.2s ease;
}

.vm-teacher-read-more:hover {
	color: var(--ink);
	text-decoration: underline;
}

.vm-teacher-read-more:focus-visible {
	outline: 2px solid var(--wp--preset--color--accent);
	outline-offset: 3px;
}

/* ─── Stats row ──────────────────────────────────────────────────── */

.vm-teacher-stats {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	gap: var(--wp--preset--spacing--large);
}

.vm-teacher-stat {
	display: flex;
	flex-direction: column;
	gap: 0.25rem;
}

.vm-teacher-stat-number {
	font-family: var(--font-serif);
	color: var(--wp--preset--color--accent);

	font-size: 38px;
    font-weight: 600;
    line-height: 1;
}

.vm-teacher-stat-label {
	font-family: var(--font-sans);
	font-size: 10px;
	font-weight: 500;
	letter-spacing: 2px;
	text-transform: uppercase;
	color: var(--wp--preset--color--stone);
}

/* ─── Social links (repeater under stats) ─────────────────────────── */

.vm-teacher-socials {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 0.75rem 1.25rem;
	margin-top: 16px;
}

.vm-teacher-social-link {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	color: var(--wp--preset--color--stone);
	text-decoration: none;
	transition: all 0.3s ease;
}

.vm-teacher-social-link:hover {
	text-decoration: unset;
	transform: scale(1.1);
}

.vm-teacher-social-link:focus-visible {
	outline: 2px solid var(--wp--preset--color--accent);
	outline-offset: 3px;
}

/* Theme sans-serif on <a> can override Dashicons’ icon font — force the dashicons stack. */
.vm-teacher-social-link .vm-teacher-social-icon--dashicon.dashicons,
.vm-teacher-social-link .dashicons {
	font-family: dashicons !important;
	font-style: normal;
	font-weight: normal;
	font-variant: normal;
	text-transform: none;
	-webkit-font-smoothing: antialiased;
	-moz-osx-font-smoothing: grayscale;
	speak: never;
}

.vm-teacher-social-icon--dashicon {
	font-size: 24px;
	width: 1.25em;
	height: 1.25em;
	width: 24px;
	height: 24px;
	line-height: 1;
}

.vm-teacher-social-icon--img {
	display: block;
	width: 24px;
	height: 24px;
	object-fit: contain;
}

/* ─── Editor placeholder ─────────────────────────────────────────── */

.vm-teacher-placeholder {
	padding: 1rem;
	background: #f9f9f9;
	border: 1px dashed #ccc;
	color: #888;
	font-style: italic;
	border-radius: 4px;
}

/* ─── Responsive ─────────────────────────────────────────────────── */

@container (max-width: 936px) {
	.vm-teacher-body {
		grid-template-columns: 1fr;
		gap: 30px;
	}

	.vm-teacher-stats {
		flex-wrap: wrap;
		gap: var(--wp--preset--spacing--medium);
	}

	.vm-teacher-content{
		padding: 0;
	}
}
