/* ==========================================================================
   Team Page — team-page.css
   Loaded only when the "Our Team Page" template is active.
   Relies on CSS custom properties defined in main.css (:root block).
   ========================================================================== */

/* ── Page layout ──────────────────────────────────────────────────────────── */

.team-page-main {
	position: relative;
	padding-top: 80px;
	padding-bottom: 120px;
	overflow: hidden;
}

/* ── Decorative background circles (brand style) ──────────────────────────── */

.team-decor {
	position: absolute;
	inset: 0;
	pointer-events: none;
	z-index: 0;
}

.team-decor__circle {
	position: absolute;
	border-radius: 50%;
	background: transparent;
	border: 1px solid rgba(0, 0, 0, 0.06);
}

/* Top-right cluster */
.team-decor__circle--1 {
	width: 560px;
	height: 560px;
	top: -200px;
	right: -180px;
	background: radial-gradient(circle, rgba(229, 229, 229, 0.35) 0%, transparent 70%);
}

.team-decor__circle--2 {
	width: 360px;
	height: 360px;
	top: -80px;
	right: -60px;
	background: radial-gradient(circle, rgba(229, 229, 229, 0.25) 0%, transparent 70%);
}

/* Bottom-left accent */
.team-decor__circle--3 {
	width: 480px;
	height: 480px;
	bottom: 40px;
	left: -200px;
	background: radial-gradient(circle, rgba(229, 229, 229, 0.30) 0%, transparent 70%);
}

/* ── Hero / header ───────────────────────────────────────────────────────── */

.team-hero {
	position: relative;
	z-index: 1;
	text-align: center;
	margin-bottom: 56px;
}

.team-hero__title {
	font-size: clamp(36px, 5vw, 64px);
	font-weight: 700;
	color: #1A1A1A;
	line-height: 1.1;
	margin-bottom: 16px;
}

.team-hero__subtitle {
	font-size: clamp(16px, 2vw, 20px);
	color: #666;
	font-weight: 400;
	max-width: 540px;
	margin: 0 auto;
}

/* ── Department filter tabs ───────────────────────────────────────────────── */

.team-filter {
	position: relative;
	z-index: 1;
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	justify-content: center;
	margin-bottom: 56px;
}

.team-filter__btn {
	display: inline-flex;
	align-items: center;
	padding: 10px 24px;
	border: 1.5px solid #E8E8E8;
	border-radius: 100px;
	background: #fff;
	color: #1A1A1A;
	font-family: inherit;
	font-size: 14px;
	font-weight: 500;
	cursor: pointer;
	transition: border-color 0.2s ease, background 0.2s ease, color 0.2s ease;
	white-space: nowrap;
}

.team-filter__btn:hover {
	border-color: #F5821F;
	color: #F5821F;
}

.team-filter__btn.is-active {
	background: #F5821F;
	border-color: #F5821F;
	color: #fff;
}

/* ── Team grid ───────────────────────────────────────────────────────────── */

.team-grid {
	position: relative;
	z-index: 1;
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 28px;
}

@media (max-width: 1024px) {
	.team-grid {
		grid-template-columns: repeat(2, 1fr);
	}
}

@media (max-width: 580px) {
	.team-grid {
		grid-template-columns: 1fr;
	}
}

/* ── Team card ───────────────────────────────────────────────────────────── */

.team-card {
	background: #fff;
	border: 1px solid #E8E8E8;
	border-radius: 12px;
	padding: 28px 24px 24px;
	display: flex;
	flex-direction: column;
	gap: 12px;
	transition: box-shadow 0.25s ease, transform 0.25s ease;
}

.team-card:hover {
	box-shadow: 0 8px 32px rgba(0, 0, 0, 0.08);
	transform: translateY(-2px);
}

/* Hidden state used by JS filter */
.team-card[hidden] {
	display: none;
}

/* Enter animation when JS filter shows a card */
@media (prefers-reduced-motion: no-preference) {
	@keyframes team-card-enter {
		from {
			opacity: 0;
			transform: translateY(8px);
			filter: blur(2px);
		}
		to {
			opacity: 1;
			transform: translateY(0);
			filter: blur(0);
		}
	}

	.team-card.is-entering {
		animation: team-card-enter 0.22s cubic-bezier(0.22, 1, 0.36, 1) both;
	}
}

/* ── Photo / initials placeholder ────────────────────────────────────────── */

.team-card__photo-wrap {
	width: 80px;
	height: 80px;
	border-radius: 50%;
	overflow: hidden;
	flex-shrink: 0;
}

.team-card__photo {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

.team-card__initials {
	width: 100%;
	height: 100%;
	background: #F5821F;
	color: #fff;
	font-size: 24px;
	font-weight: 700;
	display: flex;
	align-items: center;
	justify-content: center;
	letter-spacing: 0.02em;
	border-radius: 50%;
	user-select: none;
}

/* ── Badge ───────────────────────────────────────────────────────────────── */

.team-card__badge {
	display: inline-block;
	align-self: flex-start;
	background: #F5821F;
	color: #fff;
	font-size: 11px;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: 0.06em;
	padding: 4px 10px;
	border-radius: 4px;
}

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

.team-card__body {
	display: flex;
	flex-direction: column;
	gap: 6px;
	flex: 1;
}

.team-card__name {
	font-size: 18px;
	font-weight: 600;
	color: #1A1A1A;
	line-height: 1.3;
	margin: 0;
}

.team-card__position {
	font-size: 14px;
	font-weight: 500;
	color: #F5821F;
	margin: 0;
}

.team-card__bio {
	font-size: 14px;
	color: #666;
	line-height: 1.6;
	margin: 4px 0 0;
}

/* ── Social links ─────────────────────────────────────────────────────────── */

.team-card__socials {
	display: flex;
	gap: 12px;
	margin-top: auto;
	padding-top: 4px;
}

.team-card__social-link {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 36px;
	height: 36px;
	border-radius: 8px;
	border: 1px solid #E8E8E8;
	color: #666;
	transition: border-color 0.2s ease, color 0.2s ease, background 0.2s ease;
	flex-shrink: 0;
}

.team-card__social-link:hover {
	border-color: #F5821F;
	color: #F5821F;
	background: #fff8f4;
}

/* ── Empty state ─────────────────────────────────────────────────────────── */

.team-empty {
	text-align: center;
	color: #999;
	font-size: 16px;
	padding: 60px 0;
}

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

@media (max-width: 768px) {
	.team-page-main {
		padding-top: 60px;
		padding-bottom: 80px;
	}

	.team-hero {
		margin-bottom: 40px;
	}

	.team-filter {
		margin-bottom: 40px;
	}

	/* Shrink decorative circles so they don't dominate on small screens */
	.team-decor__circle--1 {
		width: 300px;
		height: 300px;
		top: -120px;
		right: -100px;
	}

	.team-decor__circle--2 {
		width: 180px;
		height: 180px;
		top: -40px;
		right: -30px;
	}

	.team-decor__circle--3 {
		width: 260px;
		height: 260px;
		bottom: 20px;
		left: -100px;
	}
}

@media (max-width: 480px) {
	.team-filter__btn {
		padding: 8px 18px;
		font-size: 13px;
	}

	.team-card {
		padding: 22px 18px 20px;
	}
}

/* ── Reduced motion ─────────────────────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
	*,
	*::before,
	*::after {
		animation-duration: 0.01ms !important;
		animation-iteration-count: 1 !important;
		transition-duration: 0.01ms !important;
	}
}
