/**
 * Generic team-member profile (templates/single-membri-del-team.php).
 *
 * Palette comes from the ali-blocks --block-* tokens, so the profile inherits
 * whatever the active theme maps them to. Literal fallbacks keep it readable if
 * the block library is ever absent.
 */

.ali-team-profile {
	--atp-max: 1000px;
	background: #fff;
	font-family: var(--block-font-body, system-ui, sans-serif);
	color: var(--block-text, #2c2c2c);
}

/* ── Hero ───────────────────────────────────────── */
.ali-team-hero {
	text-align: center;
	padding: 72px 24px 48px;
	background: var(--block-bg, #faf9f7);
}

.ali-team-hero__photo {
	width: 190px;
	height: 190px;
	border-radius: 50%;
	object-fit: cover;
	margin: 0 auto 24px;
	display: block;
	box-shadow: 0 6px 28px rgba(0, 0, 0, .1);
}

.ali-team-hero__photo--placeholder {
	display: flex;
	align-items: center;
	justify-content: center;
	background: var(--block-bg-sky, #E8F4F6);
}

.ali-team-hero__photo--placeholder svg {
	width: 64px;
	height: 64px;
	color: var(--block-accent-text, #207180);
	opacity: .4;
}

.ali-team-hero h1 {
	font-family: var(--block-font-heading, Georgia, serif);
	font-weight: var(--block-heading-weight, 400);
	color: var(--block-heading-color, var(--block-dark, #1a2332));
	font-size: clamp(1.9rem, 4vw, 2.6rem);
	margin: 0 0 8px;
	line-height: 1.2;
}

.ali-team-hero__qualifica {
	font-size: 1rem;
	font-weight: 600;
	color: var(--block-accent-text, #207180);
	margin: 0 0 4px;
}

.ali-team-hero__professione {
	font-size: .9rem;
	color: var(--block-text-secondary, #5a5a5a);
	margin: 0;
}

/* ── Section label ──────────────────────────────── */
.ali-team-label {
	font-size: .78rem;
	font-weight: 700;
	letter-spacing: .1em;
	text-transform: uppercase;
	color: var(--block-accent-text, #207180);
	margin-bottom: 12px;
}

/* ── Bio + contatti ─────────────────────────────── */
.ali-team-bio {
	padding: 64px 24px;
}

.ali-team-bio__inner {
	max-width: var(--atp-max);
	margin: 0 auto;
	display: grid;
	grid-template-columns: minmax(0, 1fr) 280px;
	gap: 48px;
	align-items: start;
}

.ali-team-bio__text p {
	font-size: 1rem;
	line-height: 1.85;
	color: var(--block-text-secondary, #5a5a5a);
	margin: 0 0 16px;
}

.ali-team-bio__text p:last-child {
	margin-bottom: 0;
}

.ali-team-contact {
	background: var(--block-bg, #faf9f7);
	border-radius: var(--block-radius, 16px);
	padding: 24px;
	margin-bottom: 20px;
}

.ali-team-contact h2 {
	font-size: .95rem;
	font-weight: 700;
	color: var(--block-heading-color, var(--block-dark, #1a2332));
	margin: 0 0 14px;
}

.ali-team-contact__link {
	display: flex;
	align-items: center;
	gap: 10px;
	font-size: .88rem;
	color: var(--block-accent-text, #207180);
	text-decoration: none;
	padding: 6px 0;
	overflow-wrap: anywhere;
}

.ali-team-contact__link:hover {
	text-decoration: underline;
}

.ali-team-contact__link svg {
	width: 17px;
	height: 17px;
	flex-shrink: 0;
}

.ali-team-back {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	font-size: .85rem;
	font-weight: 600;
	color: var(--block-text-secondary, #5a5a5a);
	text-decoration: none;
}

.ali-team-back:hover {
	color: var(--block-accent-text, #207180);
}

.ali-team-back svg {
	width: 16px;
	height: 16px;
}

/* ── Colleghi ───────────────────────────────────── */
.ali-team-colleghi {
	padding: 56px 24px 80px;
	background: var(--block-bg, #faf9f7);
}

.ali-team-colleghi__inner {
	max-width: var(--atp-max);
	margin: 0 auto;
}

.ali-team-colleghi__header {
	text-align: center;
	margin-bottom: 36px;
}

.ali-team-colleghi__header h2 {
	font-family: var(--block-font-heading, Georgia, serif);
	font-weight: var(--block-heading-weight, 400);
	color: var(--block-heading-color, var(--block-dark, #1a2332));
	font-size: clamp(1.5rem, 3vw, 2rem);
	margin: 0;
}

.ali-team-colleghi__group {
	margin-bottom: 40px;
}

.ali-team-colleghi__group h3 {
	font-size: 1.05rem;
	color: var(--block-accent-text, #207180);
	margin: 0 0 4px;
}

.ali-team-colleghi__desc {
	font-size: .88rem;
	color: var(--block-text-secondary, #5a5a5a);
	margin: 0 0 20px;
}

.ali-team-colleghi__grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
	gap: 28px 20px;
}

.ali-team-collega {
	text-align: center;
	text-decoration: none;
	display: block;
}

.ali-team-collega__photo {
	width: 110px;
	height: 110px;
	border-radius: 50%;
	object-fit: cover;
	margin: 0 auto 12px;
	display: block;
	background: var(--block-bg-sky, #E8F4F6);
	transition: transform .3s cubic-bezier(.22, 1, .36, 1);
}

.ali-team-collega:hover .ali-team-collega__photo {
	transform: scale(1.06);
}

.ali-team-collega__photo--placeholder {
	display: flex;
	align-items: center;
	justify-content: center;
}

.ali-team-collega__photo--placeholder svg {
	width: 40px;
	height: 40px;
	color: var(--block-accent-text, #207180);
	opacity: .4;
}

.ali-team-collega__name {
	display: block;
	font-size: .95rem;
	font-weight: 600;
	color: var(--block-accent-text, #207180);
	line-height: 1.3;
}

.ali-team-collega__role {
	display: block;
	font-size: .8rem;
	color: var(--block-text-secondary, #5a5a5a);
	margin-top: 2px;
	line-height: 1.4;
}

/* ── Responsive ─────────────────────────────────── */
@media (max-width: 860px) {
	.ali-team-bio__inner {
		grid-template-columns: 1fr;
		gap: 32px;
	}
}

@media (max-width: 560px) {
	.ali-team-hero {
		padding: 48px 20px 36px;
	}

	.ali-team-hero__photo {
		width: 150px;
		height: 150px;
	}

	.ali-team-colleghi__grid {
		grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
	}
}
