/**
 * Cases block — 1:1 mockup.
 *
 * Grid: text | tall product photo | nav
 * All columns vertically centered.
 * Left text max-width forces mockup line breaks.
 */

:root {
	--tf-blue: #3273EB;
	--tf-orange: #EB6049;
	--tf-cases-muted: #B9BDBD;
	--tf-cases-text: #111111;
}

.elementor .tf-cases.e-con.tf-cases,
.elementor-element.tf-cases,
.tf-cases.e-con,
.tf-cases {
	--padding-top: 0 !important;
	--padding-bottom: 0 !important;
	--padding-left: 0 !important;
	--padding-right: 0 !important;
	--flex-direction: row;
	--align-items: center;
	display: grid !important;
	/* More room for title/body; photo+nav sit further right. */
	grid-template-columns: minmax(380px, 40%) minmax(280px, 38%) minmax(160px, 18%);
	align-items: center !important;
	justify-content: stretch !important;
	/* Gap only between copy and photo; photo sits flush to nav. */
	column-gap: 0 !important;
	row-gap: 40px !important;
	background-color: #fff !important;
	width: 100% !important;
	max-width: 100% !important;
	min-height: 0;
	padding: 200px var(--tf-page-x) !important;
	flex-wrap: nowrap !important;
	overflow: visible !important;
}

.tf-cases > .e-con,
.tf-cases-copy,
.tf-cases-media,
.tf-cases-nav {
	--width: 100%;
	width: 100% !important;
	max-width: none !important;
	min-width: 0 !important;
	flex: none !important;
	align-self: center !important;
}

/* ----- Left ----- */
.tf-cases-copy.e-con,
.tf-cases-copy {
	display: flex !important;
	flex-direction: column !important;
	justify-content: center !important;
	align-items: flex-start !important;
	padding: 0 !important;
	margin: 0 clamp(40px, 5vw, 96px) 0 0 !important;
	gap: 0 !important;
	max-width: 580px !important;
}

.tf-cases-title {
	margin: 0 0 28px !important;
	width: 100%;
}

.tf-cases-title .elementor-heading-title {
	color: var(--tf-blue) !important;
	font-family: "Garet", sans-serif !important;
	font-weight: 800 !important;
	font-size: 66px !important;
	line-height: 4.1875rem !important;
	letter-spacing: 0;
	margin: 0 !important;
	text-align: left !important;
}

.tf-cases-text {
	margin: 0 0 48px !important;
	width: 100%;
	max-width: 540px;
}

.tf-cases-text p{
	max-width: 90%;
}

.tf-cases-text .elementor-widget-container,
.tf-cases-text p {
	color: var(--tf-cases-text) !important;
	font-family: "Garet", sans-serif !important;
	font-weight: 400 !important;
	font-size: 24px !important;
	line-height: 165% !important;
	margin: 0 !important;
	text-align: left !important;
}


.tf-cases-cta .elementor-button{
	position:relative; display:inline-block;
	padding:0 .78125rem 0 0;
	background:transparent!important; border:0!important; border-radius:0!important;
	color: #eb6049; !important;
	font-size:.8125rem; font-weight:500; letter-spacing:.15em; line-height:1; text-transform:uppercase;
	transition:all .5s cubic-bezier(.22,.61,.36,1);
}
.tf-cases-cta .elementor-button .elementor-button-icon{ display:none!important; }
.tf-cases-cta .elementor-button .elementor-button-content-wrapper{ display:inline; }
.tf-cases-cta .elementor-button::after,
.tf-cases-cta .elementor-button::before{
	content:""; position:absolute; top:50%;
	width:.75rem; height:1.0625rem; transform:translateY(-50%);
	background:url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIxNS41MjQiIGhlaWdodD0iOS41NTMiPjxwYXRoIGRhdGEtbmFtZT0iUGF0aCAyMDUiIGQ9Im0xMC43NDcgMC0uODQyLjg0MiAzLjMzMiAzLjMzOEgwdjEuMTk0aDEzLjIzN0w5Ljg5OSA4LjcwNmwuODQ4Ljg0OCA0Ljc3Ny00Ljc3N3oiIGZpbGw9IiNlYjYwNDkiLz48L3N2Zz4=") no-repeat 50%/contain;
	transition:all .5s cubic-bezier(.22,.61,.36,1); pointer-events:none;
}
.tf-cases-cta .elementor-button::after{ left:100%; opacity:1; }
.tf-cases-cta .elementor-button::before{ left:-10%; opacity:0; }
.tf-cases-cta .elementor-button:hover{ padding-left:1.5625rem; }
.tf-cases-cta .elementor-button:hover::after{ left:110%; opacity:0; }
.tf-cases-cta .elementor-button:hover::before{ left:0; opacity:1; }

/* ----- Center photo ----- */
.tf-cases-media.e-con,
.tf-cases-media {
	--width: 100% !important;
	position: relative !important;
	display: flex !important;
	justify-content: flex-end !important;
	align-items: center !important;
	padding: 0 !important;
	margin: 0 !important;
	min-height: 0;
	overflow: visible !important;
}

.tf-cases-media .tf-cases-photo {
	position: absolute !important;
	inset: 0;
	display: flex !important;
	align-items: center;
	justify-content: center;
	opacity: 0;
	visibility: hidden;
	pointer-events: none;
	transition: opacity 0.35s ease;
	margin: 0 !important;
	width: 100% !important;
	height: 100% !important;
}

.tf-cases-media .tf-cases-photo.is-active {
	position: relative !important;
	inset: auto;
	opacity: 1;
	visibility: visible;
	pointer-events: auto;
	width: auto !important;
	height: auto !important;
}

.tf-cases-media .tf-cases-photo .elementor-widget-container {
	display: flex;
	align-items: center;
	justify-content: center;
	width: auto;
	max-width: none;
	line-height: 0;
}

/*
 * Size by height — max-width:100% kept the photo stuck to a narrow column,
 * so raising max-height only grew empty padding around it.
 */
.tf-cases-media img {
	display: block !important;
	width: auto !important;
	height: clamp(527px, 40.8vw, 697px) !important;
	max-width: none !important;
	max-height: none !important;
	object-fit: contain !important;
	margin: 0 !important;
}

/* ----- Right nav ----- */
.tf-cases-nav.e-con,
.tf-cases-nav {
	display: flex !important;
	justify-content: flex-start !important;
	align-items: center !important;
	padding: 0 !important;
	margin: 0 !important;
}

.tf-cases-nav-list {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	flex-direction: column;
	gap: 10px;
}

.tf-cases-nav-list button {
	appearance: none;
	background: transparent !important;
	background-color: transparent !important;
	border: 0 !important;
	box-shadow: none !important;
	outline: none !important;
	padding: 0;
	margin: 0;
	cursor: pointer;
	text-align: left;
	font-family: "Garet", sans-serif;
	font-weight: 400;
	font-size: 24px;
	line-height: 40px;
	color: var(--tf-cases-muted) !important;
	transition: color 0.2s ease;
	-webkit-tap-highlight-color: transparent;
}

.tf-cases-nav-list button:hover,
.tf-cases-nav-list button:focus,
.tf-cases-nav-list button:focus-visible,
.tf-cases-nav-list button:active {
	color: var(--tf-blue) !important;
	background: transparent !important;
	background-color: transparent !important;
	box-shadow: none !important;
}

.tf-cases-nav-list button.is-active,
.tf-cases-nav-list button.is-active:hover,
.tf-cases-nav-list button.is-active:focus,
.tf-cases-nav-list button.is-active:focus-visible,
.tf-cases-nav-list button.is-active:active {
	color: var(--tf-blue) !important;
	background: transparent !important;
	background-color: transparent !important;
	box-shadow: none !important;
	outline: none !important;
}

@media (max-width: 1440px) {
	.tf-cases-title .elementor-heading-title {
		font-size: 50px !important;
	}

	.tf-cases-text .elementor-widget-container,
	.tf-cases-text p {
		font-size: 20px !important;
		line-height: 26px !important;
	}

	.tf-cases-nav-list button {
		font-size: 20px;
		line-height: 34px;
	}
}

@media (max-width: 1200px) {
	.tf-cases {
		grid-template-columns: minmax(300px, 38%) minmax(260px, 40%) minmax(140px, 18%);
		column-gap: 0 !important;
		min-height: 0;
	}

	.tf-cases-copy {
		margin-right: 36px !important;
	}

	.tf-cases-title .elementor-heading-title {
		font-size: clamp(40px, 4.2vw, 50px) !important;
	}

	.tf-cases-text .elementor-widget-container,
	.tf-cases-text p {
		font-size: clamp(18px, 1.8vw, 20px) !important;
		line-height: 1.35 !important;
	}

	.tf-cases-media img {
		height: clamp(408px, 44.2vw, 578px) !important;
	}

	.tf-cases-nav-list button {
		font-size: 20px;
		line-height: 34px;
	}
	.tf-cases-text p{
		max-width: 100%;
	}
}

@media (max-width: 1024px) {
	.elementor .tf-cases.e-con.tf-cases,
	.elementor-element.tf-cases,
	.tf-cases.e-con,
	.tf-cases {
		--flex-direction: column;
		--flex-wrap-mobile: nowrap;
		--display: flex;
		display: flex !important;
		flex-direction: column !important;
		flex-wrap: nowrap !important;
		align-items: stretch !important;
		justify-content: flex-start !important;
		min-height: 0;
		padding: 56px var(--tf-page-x) 64px !important;
		gap: 0 !important;
		row-gap: 0 !important;
		column-gap: 0 !important;
		grid-template-columns: none !important;
	}

	.tf-cases > .e-con,
	.tf-cases > .e-con.e-child,
	.tf-cases-copy,
	.tf-cases-media,
	.tf-cases-nav,
	.tf-cases-copy.e-con,
	.tf-cases-media.e-con,
	.tf-cases-nav.e-con {
		--width: 100% !important;
		width: 100% !important;
		max-width: 100% !important;
		min-width: 0 !important;
		flex: 0 0 auto !important;
		align-self: stretch !important;
	}

	/* Stack: copy → photo → switches */
	.tf-cases-copy.e-con,
	.tf-cases-copy {
		order: 1 !important;
		max-width: none !important;
		margin: 0 0 40px !important;
		padding: 0 !important;
	}

	.tf-cases-title {
		margin: 0 0 20px !important;
	}

	.tf-cases-title .elementor-heading-title {
		font-size: 30px !important;
		font-weight: 800 !important;
		line-height: 1.15 !important;
		letter-spacing: -0.02em;
	}

	.tf-cases-text {
		margin: 0 0 24px !important;
		max-width: none;
	}

	.tf-cases-text .elementor-widget-container,
	.tf-cases-text p {
		font-size: 18px !important;
		line-height: 1.45 !important;
	}

	.tf-cases-cta .elementor-button,
	.tf-cases-cta a.elementor-button {
		font-size: 13px !important;
		font-weight: 500 !important;
	}

	.tf-cases-media.e-con,
	.tf-cases-media {
		order: 2 !important;
		justify-content: center !important;
		align-items: center !important;
		min-height: 0;
		margin: 0 0 48px !important;
		padding: 0 !important;
	}

	.tf-cases-media .tf-cases-photo.is-active {
		width: 100% !important;
		justify-content: center;
	}

	.tf-cases-media .tf-cases-photo .elementor-widget-container {
		width: 100%;
		justify-content: center;
	}

	.tf-cases-media img {
		width: auto !important;
		height: auto !important;
		max-width: min(100%, 320px) !important;
		max-height: 360px !important;
		margin: 0 auto !important;
	}

	.tf-cases-nav.e-con,
	.tf-cases-nav {
		order: 3 !important;
		justify-content: stretch !important;
		width: 100% !important;
		margin: 0 !important;
		padding: 0 !important;
	}

	.tf-cases-nav-widget,
	.tf-cases-nav .elementor-widget-container {
		width: 100% !important;
	}

	/* 2-column switches grid */
	.tf-cases-nav-list {
		display: grid !important;
		grid-template-columns: 1fr 1fr;
		column-gap: clamp(24px, 8vw, 48px);
		row-gap: 10px;
		width: 100%;
		flex-direction: unset;
		flex-wrap: unset;
		gap: unset;
	}

	.tf-cases-nav-list button {
		font-size: 14px !important;
		line-height: 1.35 !important;
		font-weight: 400 !important;
		padding: 4px 0 !important;
		white-space: normal;
		max-width: 100%;
		text-align: left;
		min-height: 44px;
	}

	.tf-cases-nav-list button.is-active {
		font-weight: 400 !important;
	}
}

@media (max-width: 767px) {
	.tf-cases.e-con,
	.tf-cases {
		padding: 48px var(--tf-page-x) 56px !important;
	}

	.tf-cases-copy {
		margin-bottom: 36px !important;
	}

	.tf-cases-title .elementor-heading-title {
		font-size: 28px !important;
	}

	.tf-cases-media {
		margin-bottom: 40px !important;
	}

	.tf-cases-media img {
		max-width: min(100%, 280px) !important;
		max-height: 320px !important;
	}
}

@media (max-width: 400px) {
	.tf-cases-nav-list {
		grid-template-columns: 1fr 1fr;
		column-gap: 12px;
		row-gap: 8px;
		width: 100%;
		max-width: 100%;
	}

	.tf-cases-nav-list button {
		font-size: 16px !important;
		min-height: 40px;
		overflow-wrap: anywhere;
		max-width: 100%;
	}


	.tf-cases-cta .elementor-button,
	.tf-cases-cta a.elementor-button {
		display: flex !important;
		width: 100% !important;
		max-width: 100% !important;
		white-space: normal !important;
		box-sizing: border-box !important;
	}

	.tf-cases-title .elementor-heading-title {
		font-size: 30px !important;
	}

	.tf-cases-text .elementor-widget-container,
	.tf-cases-text p {
		font-size: 16px !important;
	}
}
