/* Pomeroy Shift Compare — before/after hero
   Colors come in as CSS variables from the widget's Style tab. */

.pmsc {
	--pmsc-pos: 50%;
	--pmsc-max: 1200px;
	--pmsc-radius: 24px;
	--pmsc-btn-radius: 6px;
	--pmsc-eyebrow: #5A6778;
	--pmsc-headline: #0A1B33;
	--pmsc-highlight: #0077C7;
	--pmsc-line: #FFFFFF;
	--pmsc-knob: #FFFFFF;
	--pmsc-knob-icon: #0A1B33;
	--pmsc-slider: #0098FF;
	--pmsc-slider-label: #3E4B5E;
	--pmsc-pill-bg: rgba(11, 27, 51, 0.06);
	--pmsc-pill-text: #0A1B33;
	--pmsc-pill-bg-hover: rgba(11, 27, 51, 0.12);
	--pmsc-cta-bg: #0098FF;
	--pmsc-cta-text: #0A1B33;
	--pmsc-cta-bg-hover: #0A1B33;
	--pmsc-cta-text-hover: #FFFFFF;

	display: flex;
	flex-direction: column;
	align-items: center;
	width: 100%;
}

.pmsc *,
.pmsc *::before,
.pmsc *::after {
	box-sizing: border-box;
}

/* Intro ------------------------------------------------------------- */

.pmsc__intro {
	width: 100%;
	max-width: var(--pmsc-max);
	margin-bottom: 36px;
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 18px;
	text-align: center;
}

.pmsc .pmsc__eyebrow {
	font-weight: 700;
	font-size: 13px;
	line-height: 1.4;
	letter-spacing: 1.5px;
	text-transform: uppercase;
	color: var(--pmsc-eyebrow);
}

.pmsc .pmsc__headline {
	margin: 0;
	max-width: 980px;
	font-size: clamp(32px, 2.6vw + 16px, 52px);
	line-height: 1.06;
	font-weight: 700;
	letter-spacing: -0.02em;
	color: var(--pmsc-headline);
}

.pmsc .pmsc__highlight {
	color: var(--pmsc-highlight);
}

/* Stage: both views share one grid cell, so the box is as tall as the
   taller view and templates of any height work. ----------------------- */

.pmsc__stage {
	position: relative;
	width: 100%;
	max-width: var(--pmsc-max);
	min-height: 440px;
	display: grid;
	grid-template: 1fr / 1fr;
	border-radius: var(--pmsc-radius);
	overflow: hidden;
	isolation: isolate;
}

.pmsc__view {
	grid-area: 1 / 1;
	min-width: 0;
	display: flex;
	background: var(--v-bg);
	color: var(--v-text);
}

.pmsc__view--after {
	--v-bg: #0A1B33;
	--v-text: #EAF0F8;
	--v-title: #FFFFFF;
	--v-accent: #2BD19A;
	--v-muted: #9FB1C9;
	--v-item_bg: rgba(255, 255, 255, 0.05);
	z-index: 0;
}

.pmsc__view--before {
	--v-bg: #1E1C21;
	--v-text: #F1E9E7;
	--v-title: #FFFFFF;
	--v-accent: #F28B7B;
	--v-muted: #B9A9A6;
	--v-item_bg: rgba(255, 255, 255, 0.05);
	z-index: 1;
	clip-path: inset(0 calc(100% - var(--pmsc-pos)) 0 0);
}

.pmsc__view--default {
	padding: 36px 44px;
}

.pmsc__view--template {
	padding: 0;
	background: transparent;
}

.pmsc__template,
.pmsc__template > .elementor {
	width: 100%;
	height: 100%;
}

.pmsc__template > .elementor > .e-con,
.pmsc__template > .elementor > .elementor-section {
	min-height: 100%;
}

.pmsc__notice {
	margin: auto;
	padding: 24px;
	font-size: 14px;
	color: #F5B84B;
	text-align: center;
}

/* Built-in layout ---------------------------------------------------- */

.pmsc__layout {
	width: 100%;
	display: flex;
	gap: 40px;
}

.pmsc__main {
	flex: 0 1 540px;
	min-width: 0;
	display: flex;
	flex-direction: column;
	gap: 14px;
}

.pmsc .pmsc__badge {
	align-self: flex-start;
	padding: 6px 12px;
	border-radius: var(--pmsc-btn-radius);
	background: rgba(255, 255, 255, 0.08);
	background: color-mix(in srgb, var(--v-accent) 15%, transparent);
	color: var(--v-accent);
	font-weight: 700;
	font-size: 12px;
	line-height: 1.3;
	letter-spacing: 1px;
}

.pmsc .pmsc__title {
	margin: 0;
	font-size: 28px;
	line-height: 1.2;
	font-weight: 700;
	color: var(--v-title);
}

.pmsc .pmsc__list {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	flex-direction: column;
	gap: 10px;
}

.pmsc .pmsc__item {
	margin: 0;
	display: flex;
	gap: 12px;
	align-items: center;
	padding: 12px 14px;
	border-radius: 12px;
	background: var(--v-item_bg);
	font-size: 15px;
	line-height: 1.4;
	color: var(--v-text);
}

.pmsc__tag {
	flex: none;
	min-width: 20px;
	font-weight: 700;
	font-size: 12px;
	color: var(--v-accent);
}

.pmsc__check {
	flex: none;
	color: var(--v-accent);
}

.pmsc__chart {
	flex: 1 1 auto;
	min-width: 0;
	display: flex;
	flex-direction: column;
	justify-content: flex-end;
	gap: 12px;
}

.pmsc__chart-label {
	font-weight: 700;
	font-size: 12px;
	letter-spacing: 1px;
	text-transform: uppercase;
	color: var(--v-muted);
}

.pmsc__chart-svg {
	display: block;
	width: 100%;
	height: 220px;
}

.pmsc__chart-grid {
	stroke: currentColor;
	stroke-opacity: 0.12;
	stroke-width: 1;
}

.pmsc__chart-line {
	stroke: var(--v-accent);
	stroke-width: 3;
	stroke-linejoin: round;
	stroke-linecap: round;
}

.pmsc__chart-fill {
	fill: var(--v-accent);
	fill-opacity: 0.1;
}

.pmsc .pmsc__chart-img {
	display: block;
	width: 100%;
	height: auto;
	max-height: 260px;
	object-fit: contain;
	object-position: left bottom;
}

/* Full-height image: covers the right side of the view, edge to edge. -- */

.pmsc__view {
	position: relative;
	--pmsc-media-w: 50%;
}

.pmsc__media {
	position: absolute;
	top: 0;
	right: var(--pmsc-media-r, 0);
	bottom: 0;
	left: var(--pmsc-media-l, auto);
	width: var(--pmsc-media-w);
	overflow: hidden;
}

.pmsc .pmsc__media img {
	display: block;
	width: 100%;
	height: 100%;
	max-width: none;
	margin: 0;
	border-radius: 0;
	object-fit: cover;
	object-position: center center;
}

.pmsc__layout--media .pmsc__main {
	flex: 0 1 auto;
	width: calc(100% - var(--pmsc-media-w));
	margin-left: var(--pmsc-main-ml, 0px);
	padding-left: var(--pmsc-main-pl, 0px);
	padding-right: var(--pmsc-main-pr, 40px);
	justify-content: center;
}

/* Divider + handle --------------------------------------------------- */

/* The line sits exactly on the split; the handle stays fully inside the box. */
.pmsc__stage::after {
	content: "";
	position: absolute;
	top: 0;
	bottom: 0;
	left: var(--pmsc-pos);
	z-index: 2;
	width: 2px;
	margin-left: -1px;
	background: var(--pmsc-line);
	pointer-events: none;
}

.pmsc__handle {
	position: absolute;
	top: 0;
	bottom: 0;
	left: clamp(22px, var(--pmsc-pos), calc(100% - 22px));
	z-index: 2;
	width: 44px;
	transform: translateX(-50%);
	display: flex;
	align-items: center;
	justify-content: center;
	cursor: ew-resize;
	touch-action: pan-y;
	outline: none;
	-webkit-user-select: none;
	user-select: none;
}

.pmsc__knob {
	position: relative;
	width: 44px;
	height: 44px;
	border-radius: 50%;
	background: var(--pmsc-knob);
	color: var(--pmsc-knob-icon);
	display: flex;
	align-items: center;
	justify-content: center;
	box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3);
	transition: transform 0.15s ease;
}

.pmsc__handle:hover .pmsc__knob,
.pmsc.is-dragging .pmsc__knob {
	transform: scale(1.06);
}

.pmsc__handle:focus-visible .pmsc__knob {
	outline: 3px solid var(--pmsc-slider);
	outline-offset: 3px;
}

.pmsc.is-dragging,
.pmsc.is-dragging * {
	cursor: ew-resize;
}

/* Slider bar --------------------------------------------------------- */

.pmsc__control {
	width: 100%;
	max-width: var(--pmsc-max);
	margin-top: 16px;
	display: flex;
	align-items: center;
	gap: 20px;
}

.pmsc .pmsc__control label {
	margin: 0;
	font-size: 14px;
	font-weight: 600;
	white-space: nowrap;
	color: var(--pmsc-slider-label);
}

.pmsc .pmsc__range {
	flex: 1 1 auto;
	width: 100%;
	height: 44px;
	margin: 0;
	padding: 0;
	border: 0;
	background: transparent;
	accent-color: var(--pmsc-slider);
	cursor: ew-resize;
}

.pmsc .pmsc__range:focus-visible {
	outline: 3px solid var(--pmsc-slider);
	outline-offset: 2px;
}

/* Links + button ----------------------------------------------------- */

.pmsc__footer {
	width: 100%;
	max-width: var(--pmsc-max);
	margin-top: 28px;
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
}

.pmsc__links {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
}

.pmsc a.pmsc__pill,
.pmsc a.pmsc__cta {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: 44px;
	padding: 0 18px;
	border-radius: var(--pmsc-btn-radius);
	font-size: 15px;
	font-weight: 600;
	line-height: 1.2;
	text-decoration: none;
	transition: background-color 0.15s ease, color 0.15s ease;
}

.pmsc a.pmsc__pill {
	background: var(--pmsc-pill-bg);
	color: var(--pmsc-pill-text);
}

.pmsc a.pmsc__pill:hover,
.pmsc a.pmsc__pill:focus-visible {
	background: var(--pmsc-pill-bg-hover);
	color: var(--pmsc-pill-text);
}

.pmsc a.pmsc__cta {
	min-height: 52px;
	padding: 0 28px;
	font-size: 16px;
	background: var(--pmsc-cta-bg);
	color: var(--pmsc-cta-text);
}

.pmsc a.pmsc__cta:hover,
.pmsc a.pmsc__cta:focus-visible {
	background: var(--pmsc-cta-bg-hover);
	color: var(--pmsc-cta-text-hover);
}

.pmsc a.pmsc__pill:focus-visible,
.pmsc a.pmsc__cta:focus-visible {
	outline: 3px solid var(--pmsc-slider);
	outline-offset: 2px;
}

/* Tablet ------------------------------------------------------------- */

@media (max-width: 1024px) {
	.pmsc__layout {
		gap: 28px;
	}

	.pmsc__chart-svg {
		height: 180px;
	}
}

/* Mobile ------------------------------------------------------------- */

@media (max-width: 767px) {
	.pmsc__intro {
		margin-bottom: 24px;
		gap: 12px;
	}

	.pmsc__stage {
		min-height: 0;
	}

	.pmsc__view--default {
		padding: 24px 20px;
	}

	.pmsc__layout {
		flex-direction: column;
		gap: 20px;
	}

	.pmsc__main {
		flex-basis: auto;
	}

	.pmsc .pmsc__title {
		font-size: 22px;
	}

	.pmsc .pmsc__item {
		font-size: 14px;
	}

	.pmsc__chart-svg {
		height: 120px;
	}

	/* Image stacks above or below the list (Image order setting), full bleed to the box edges. */
	.pmsc__view--default:has(.pmsc__media) {
		flex-direction: var(--pmsc-stack, column-reverse);
	}

	.pmsc__media {
		position: relative;
		width: auto;
		height: 220px;
		left: auto;
		right: auto;
		margin: var(--pmsc-media-m, 24px -20px -24px);
	}

	.pmsc__layout--media .pmsc__main {
		width: 100%;
		margin-left: 0;
		padding-left: 0;
		padding-right: 0;
	}

	.pmsc__control {
		gap: 12px;
	}

	.pmsc__footer {
		flex-direction: column;
		align-items: stretch;
	}

	.pmsc__links {
		justify-content: center;
	}
}

@media (prefers-reduced-motion: reduce) {
	.pmsc__knob,
	.pmsc a.pmsc__pill,
	.pmsc a.pmsc__cta {
		transition: none;
	}
}
