/* =========================================================================
   Anchor v2 — Team card design with hover effect + modal popup
   Modern wellness brand pattern. Photo-first, name reveal on hover, full
   bio in an elegant overlay modal on click.
   ========================================================================= */


/* ============================================================
   TEAM SECTION HEADER (refined)
   ============================================================ */

.team-section {
	background: #fff;
	padding-block: clamp(56px, 7vw, 90px);
}

.team-section--dark {
	background: var(--brand-primary);
	color: #fff;
}

.team-section--dark .team-section__head h2 { color: #fff; }
.team-section--dark .team-section__head h2 em { color: var(--brand-secondary); }
.team-section--dark .team-section__head-right p { color: rgba(255, 255, 255, 0.82); }


/* ============================================================
   TEAM CARD — photo with hover-reveal name + click for modal
   ============================================================ */

.tcards {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 16px;
}

@media (max-width: 860px) { .tcards { grid-template-columns: repeat(2, 1fr); gap: 12px; } }
@media (max-width: 480px) { .tcards { grid-template-columns: 1fr; } }

/* The 6-up dense grid for homepage */
.tcards--six { grid-template-columns: repeat(6, 1fr); }
@media (max-width: 1080px) { .tcards--six { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 700px)  { .tcards--six { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 380px)  { .tcards--six { grid-template-columns: 1fr; } }

.tcard {
	position: relative;
	aspect-ratio: 3 / 4;
	overflow: hidden;
	cursor: pointer;
	display: block;
	color: #fff;
	background: var(--brand-primary);
	isolation: isolate;
	border: 0;
	padding: 0;
	width: 100%;
	font-family: inherit;
	text-align: left;
}

.tcard__img {
	position: absolute;
	inset: 0;
	width: 100%; height: 100%;
	object-fit: cover;
	transition: transform 900ms var(--ease), filter 600ms var(--ease);
	filter: saturate(0.85) brightness(0.96);
	z-index: 1;
}

.tcard:hover .tcard__img {
	transform: scale(1.08);
	filter: saturate(1.02) brightness(1);
}

/* Bottom gradient — always present */
.tcard::after {
	content: "";
	position: absolute; inset: 0;
	background: linear-gradient(180deg, rgba(0,0,0,0) 35%, rgba(66, 27, 73, 0.92) 100%);
	z-index: 2;
	transition: opacity 500ms var(--ease);
}

/* Hover overlay — full-card brand wash with bottom reveal */
.tcard__overlay {
	position: absolute;
	inset: 0;
	background: linear-gradient(180deg, rgba(66, 27, 73, 0.30) 0%, rgba(66, 27, 73, 0.85) 100%);
	opacity: 0;
	transition: opacity 500ms var(--ease);
	z-index: 3;
	pointer-events: none;
}

.tcard:hover .tcard__overlay { opacity: 1; }

/* Default name plate at bottom */
.tcard__plate {
	position: absolute;
	left: 16px; right: 16px;
	bottom: 16px;
	z-index: 4;
	transition: transform 500ms var(--ease);
}

.tcard__line {
	display: block;
	width: 24px;
	height: 1px;
	background: var(--brand-secondary);
	margin-bottom: 12px;
	transition: width 500ms var(--ease);
}

.tcard:hover .tcard__line { width: 60px; }

.tcard__name {
	font-family: var(--font-display);
	font-size: clamp(15px, 1.6vw, 19px);
	font-weight: 500;
	color: #fff;
	margin: 0;
	letter-spacing: -0.005em;
	line-height: 1.2;
}

.tcard__role {
	font-size: 10px;
	font-weight: 500;
	letter-spacing: 0.22em;
	text-transform: uppercase;
	color: rgba(255, 255, 255, 0.78);
	margin: 4px 0 0;
}

/* Hidden "Read profile" cue revealed on hover */
.tcard__cue {
	position: absolute;
	left: 16px;
	bottom: 16px;
	z-index: 4;
	font-size: 11px;
	font-weight: 500;
	letter-spacing: 0.22em;
	text-transform: uppercase;
	color: var(--brand-secondary);
	display: inline-flex;
	align-items: center;
	gap: 8px;
	opacity: 0;
	transform: translateY(8px);
	transition: opacity 400ms var(--ease) 100ms, transform 400ms var(--ease) 100ms;
}

.tcard__cue::after {
	content: "+";
	display: inline-block;
	width: 20px; height: 20px;
	border-radius: 50%;
	border: 1px solid var(--brand-secondary);
	display: inline-flex;
	align-items: center;
	justify-content: center;
	font-size: 14px;
	line-height: 1;
}

.tcard:hover .tcard__cue { opacity: 1; transform: translateY(0); }
.tcard:hover .tcard__plate { transform: translateY(-32px); }


/* ============================================================
   MODAL — beautiful popup with bio
   ============================================================ */

.tmodal {
	position: fixed;
	inset: 0;
	z-index: var(--z-modal);
	display: flex;
	align-items: center;
	justify-content: center;
	background: rgba(15, 8, 22, 0.78);
	backdrop-filter: blur(8px);
	-webkit-backdrop-filter: blur(8px);
	padding: var(--gutter);
	opacity: 0;
	visibility: hidden;
	transition: opacity 320ms var(--ease), visibility 0s linear 320ms;
}

.tmodal.is-open {
	opacity: 1;
	visibility: visible;
	transition: opacity 320ms var(--ease), visibility 0s linear 0s;
}

.tmodal__dialog {
	position: relative;
	width: 100%;
	max-width: 980px;
	max-height: calc(100vh - 40px);
	background: #fff;
	overflow: hidden;
	display: grid;
	grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr);
	transform: translateY(20px) scale(0.98);
	transition: transform 380ms var(--ease);
}

.tmodal.is-open .tmodal__dialog {
	transform: translateY(0) scale(1);
}

@media (max-width: 760px) {
	.tmodal__dialog { grid-template-columns: 1fr; max-height: calc(100vh - 24px); overflow-y: auto; }
}

.tmodal__close {
	position: absolute;
	top: 14px; right: 14px;
	z-index: 5;
	width: 36px; height: 36px;
	background: rgba(255, 255, 255, 0.9);
	border: 1px solid rgba(0, 0, 0, 0.08);
	color: var(--brand-primary);
	cursor: pointer;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	transition: background-color 200ms var(--ease), color 200ms var(--ease);
}

.tmodal__close:hover {
	background: var(--brand-primary);
	color: #fff;
}

.tmodal__close svg { width: 16px; height: 16px; }

.tmodal__photo {
	position: relative;
	overflow: hidden;
	background: var(--brand-primary);
	min-height: 320px;
}

.tmodal__photo img {
	width: 100%; height: 100%; object-fit: cover;
	display: block;
}

.tmodal__photo::after {
	content: "";
	position: absolute; inset: 0;
	background: linear-gradient(180deg, transparent 60%, rgba(66, 27, 73, 0.45) 100%);
	pointer-events: none;
}

.tmodal__photo-badge {
	position: absolute;
	left: 18px; bottom: 18px;
	z-index: 2;
	font-family: var(--font-script);
	color: #fff;
	font-size: 22px;
	line-height: 1;
}

.tmodal__body {
	padding: clamp(28px, 4vw, 48px);
	overflow-y: auto;
	max-height: calc(100vh - 40px);
}

@media (max-width: 760px) {
	.tmodal__body { max-height: none; padding: 28px; }
}

.tmodal__eyebrow {
	display: inline-flex;
	align-items: center;
	gap: 12px;
	font-size: 11px;
	font-weight: 600;
	letter-spacing: 0.28em;
	text-transform: uppercase;
	color: var(--brand-secondary);
	margin-bottom: 14px;
}

.tmodal__eyebrow::before {
	content: "";
	width: 28px;
	height: 1px;
	background: var(--brand-secondary);
}

.tmodal__name {
	font-family: var(--font-display);
	font-size: clamp(26px, 3vw, 36px);
	font-weight: 500;
	color: var(--brand-primary);
	margin: 0 0 4px;
	line-height: 1.1;
	letter-spacing: -0.01em;
}

.tmodal__role {
	font-size: 12px;
	font-weight: 500;
	color: var(--brand-text);
	letter-spacing: 0.22em;
	text-transform: uppercase;
	margin: 0 0 22px;
	padding-bottom: 22px;
	border-bottom: 1px solid var(--line-soft);
}

.tmodal__bio {
	font-size: 15px;
	line-height: 1.75;
	color: var(--brand-text);
	font-weight: 300;
	margin: 0 0 1em;
}

.tmodal__tags {
	display: flex;
	flex-wrap: wrap;
	gap: 6px;
	margin-top: 18px;
	margin-bottom: 24px;
}

.tmodal__tag {
	font-size: 11px;
	font-weight: 500;
	color: var(--brand-primary);
	background: rgba(66, 27, 73, 0.06);
	padding: 5px 10px;
	letter-spacing: 0.04em;
}

.tmodal__cta {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	font-size: 12px;
	font-weight: 500;
	color: #fff;
	background: var(--brand-secondary);
	padding: 12px 22px;
	letter-spacing: 0.16em;
	text-transform: uppercase;
	transition: background-color 200ms var(--ease);
}

.tmodal__cta:hover { background: var(--brand-primary); }


/* Prevent body scroll when modal open */
body.modal-open { overflow: hidden; }
