/* Services row: built from native Elementor containers, headings and images.
   Class hooks: sk-svc (section), sk-svc__pin > sk-svc__stage > sk-svc__track, sk-svc__card.
   By default the row scrolls sideways by hand; assets/js/services.js pins it and
   moves it with the page scroll on wide screens (adds .is-pinned). */

.sk-svc {
	--sk-svc-gap: clamp(16px, 2.4vw, 40px);
	/* Four cards fill the viewport at any desktop width; phones keep a 240px minimum and swipe. */
	--sk-card-w: max(240px, calc((100vw - 2 * var(--sk-gutter) - 3 * var(--sk-svc-gap)) / 4));
}

/* .e-con raises specificity above Elementor's own container padding and widget margins. */
.sk-svc.e-con {
	padding-block: clamp(64px, 8vw, 128px) clamp(24px, 4vw, 64px);
}

.sk-svc .sk-svc__head.e-con {
	align-items: center;
	margin: 0 auto clamp(28px, 4vw, 64px);
	padding-inline: var(--sk-gutter);
	text-align: center;
}

.sk-svc .sk-svc__title .elementor-heading-title {
	max-width: 15em;
	margin: 0 auto;
	color: var(--sk-ink);
	font-family: var(--sk-font-serif);
	font-size: clamp(32px, 3.3vw, 64px);
	font-weight: 400;
	line-height: 1.1;
	text-wrap: balance;
}

/* ---------- Row (hand-scrolled by default) ---------- */

.sk-svc .sk-svc__stage {
	display: block;
	width: 100%;
	padding: 0;
	overflow-x: auto;
	scroll-snap-type: x proximity;
	scrollbar-width: none;
}

.sk-svc .sk-svc__stage::-webkit-scrollbar {
	display: none;
}

.sk-svc .sk-svc__track {
	display: flex;
	flex-direction: row;
	flex-wrap: nowrap;
	align-items: flex-start;
	flex: none;
	gap: var(--sk-svc-gap);
	width: max-content;
	min-width: 100%;
	padding: 0 var(--sk-gutter);
}

.sk-svc .sk-svc__card {
	display: flex;
	flex: none;
	flex-direction: column;
	align-items: center;
	gap: 0;
	width: var(--sk-card-w);
	padding: 8px 8px clamp(20px, 2vw, 32px);
	border: 1px solid var(--sk-line);
	border-radius: 999px 999px clamp(24px, 2.4vw, 40px) clamp(24px, 2.4vw, 40px);
	background: rgba(251, 251, 250, 0.55);
	scroll-snap-align: start;
}

.sk-svc .sk-svc__card .sk-svc__img {
	width: 100%;
	margin: 0;
	overflow: hidden;
	border-radius: 999px 999px 16px 16px;
}

.sk-svc .sk-svc__img img {
	display: block;
	width: 100%;
	height: auto;
	aspect-ratio: 3 / 4;
	object-fit: cover;
	transition: transform 0.8s var(--sk-ease);
}

.sk-svc .sk-svc__card:hover .sk-svc__img img {
	transform: scale(1.05);
}

.sk-svc .sk-svc__card .sk-svc__tag {
	margin: clamp(16px, 1.6vw, 28px) 0 6px;
	color: var(--sk-muted);
	font-family: var(--sk-font-sans);
	font-size: clamp(12px, 0.85vw, 15px);
	font-weight: 400;
	letter-spacing: 0.04em;
	text-align: center;
}

.sk-svc .sk-svc__card .sk-svc__name {
	margin: 0;
	color: var(--sk-ink);
	font-family: var(--sk-font-serif);
	font-size: clamp(20px, 1.7vw, 32px);
	font-weight: 400;
	line-height: 1.2;
	text-align: center;
	text-wrap: balance;
}

/* ---------- Pinned: the page scroll moves the row ---------- */

.sk-svc .sk-svc__pin {
	display: block;
	padding: 0;
}

.sk-svc .sk-svc__pin.is-pinned .sk-svc__stage {
	position: sticky;
	top: calc(var(--sk-header-h) + var(--sk-admin-bar));
	display: flex;
	flex-direction: row;
	align-items: center;
	height: calc(100svh - var(--sk-header-h) - var(--sk-admin-bar));
	overflow: hidden;
	scroll-snap-type: none;
}

.sk-svc .sk-svc__pin.is-pinned .sk-svc__track {
	will-change: transform;
}

@media (prefers-reduced-motion: reduce) {
	.sk-svc .sk-svc__img img {
		transition: none;
	}
}

/* The whole card is one link (the title's), so the card is a large click target. */
.sk-svc .sk-svc__card {
	position: relative;
}

.sk-svc .sk-svc__name a::after {
	content: "";
	position: absolute;
	inset: 0;
	border-radius: inherit;
}

.sk-svc .sk-svc__name a {
	color: inherit;
}

/* Optional short description under the name. */
.sk-svc .sk-svc__card .sk-svc__text {
	display: -webkit-box;
	-webkit-box-orient: vertical;
	-webkit-line-clamp: 3;
	margin: 8px 8px 0;
	overflow: hidden;
	color: var(--sk-muted);
	font-family: var(--sk-font-sans);
	font-size: clamp(13px, 0.95vw, 16px);
	line-height: 1.45;
	text-align: center;
	text-wrap: balance;
}

/* Hover: the card lifts, the photo zooms and an "Explore" pill slides up over the photo.
   Pointer devices only; the pill adds no height, so the pinned row never shifts. */
@media (hover: hover) {
	.sk-svc .sk-svc__card {
		transition: translate 0.5s var(--sk-ease), box-shadow 0.5s var(--sk-ease), border-color 0.5s var(--sk-ease);
	}

	.sk-svc .sk-svc__card:hover {
		translate: 0 -8px;
		border-color: var(--sk-accent);
		box-shadow: 0 24px 48px -28px rgba(29, 32, 35, 0.45);
	}

	.sk-svc .sk-svc__card .sk-svc__img {
		position: relative;
	}

	.sk-svc .sk-svc__card .sk-svc__img::after {
		content: "Explore \2192";
		position: absolute;
		bottom: 14px;
		left: 50%;
		padding: 8px 18px;
		border-radius: 999px;
		background: rgba(251, 251, 250, 0.88);
		-webkit-backdrop-filter: blur(6px);
		backdrop-filter: blur(6px);
		color: var(--sk-ink);
		font-family: var(--sk-font-sans);
		font-size: 13px;
		font-weight: 500;
		letter-spacing: 0.02em;
		white-space: nowrap;
		opacity: 0;
		translate: -50% 12px;
		transition: opacity 0.4s var(--sk-ease), translate 0.5s var(--sk-ease);
		pointer-events: none;
	}

	.sk-svc .sk-svc__card:hover .sk-svc__img::after {
		opacity: 1;
		translate: -50% 0;
	}
}

/* Gold on hover, taken from the logo (#c9bda8 light, #857a68 mid, #6f6454 deep). */
@media (hover: hover) {
	.sk-svc .sk-svc__card:hover {
		border-color: transparent;
		background:
			linear-gradient(#fafafa, #fafafa) padding-box,
			linear-gradient(135deg, #d4c8b3 0%, #857a68 50%, #6f6454 100%) border-box;
		box-shadow: 0 26px 50px -26px rgba(133, 122, 104, 0.65), 0 0 0 1px rgba(201, 189, 168, 0.35);
	}

	.sk-svc .sk-svc__card:hover .sk-svc__tag {
		color: var(--sk-accent);
	}

	.sk-svc .sk-svc__card .sk-svc__name a {
		background: linear-gradient(90deg, #c9bda8, #857a68) 50% 100% / 0 2px no-repeat;
		padding-bottom: 4px;
		transition: color 0.4s var(--sk-ease), background-size 0.5s var(--sk-ease);
	}

	.sk-svc .sk-svc__card:hover .sk-svc__name a {
		background-size: 60% 2px;
		color: #5f5546;
	}

	/* The "Explore" pill turns gold. */
	.sk-svc .sk-svc__card:hover .sk-svc__img::after {
		background: linear-gradient(135deg, #d9cfbd, #a89a82);
		box-shadow: 0 10px 22px -10px rgba(111, 100, 84, 0.8);
		color: #181b1e;
	}

	/* A soft gold light sweeps across the photo. */
	.sk-svc .sk-svc__card .sk-svc__img::before {
		content: "";
		position: absolute;
		inset: 0;
		z-index: 1;
		background: linear-gradient(105deg, transparent 38%, rgba(217, 207, 189, 0.38) 50%, transparent 62%);
		translate: -120% 0;
		pointer-events: none;
	}

	.sk-svc .sk-svc__card:hover .sk-svc__img::before {
		translate: 120% 0;
		transition: translate 0.9s var(--sk-ease);
	}
}

@media (hover: hover) and (prefers-reduced-motion: reduce) {
	.sk-svc .sk-svc__card:hover .sk-svc__img::before {
		display: none;
	}
}

/* ---------- Static variant: "Related treatments" on inner pages ----------
   Same arch cards as the Home row, but never pinned: five cards sit in ONE row on desktop
   and the row swipes sideways on narrower screens. Add the class sk-svc--static to the widget. */
.sk-svc.sk-svc--static {
	--sk-svc-gap: clamp(12px, 1.4vw, 24px);
	--sk-card-w: max(180px, calc((100% - 4 * var(--sk-svc-gap)) / 5));
}

.sk-svc--static .sk-svc__stage {
	margin-block: -14px;
	padding-block: 14px 22px;
}

.sk-svc--static .sk-svc__track {
	width: 100%;
	padding-inline: 0;
}

.sk-svc--static .sk-svc__card .sk-svc__name {
	font-size: clamp(13px, 1.12vw, 21px);
	white-space: nowrap;
}

.sk-svc--static .sk-svc__card .sk-svc__tag {
	font-size: clamp(11px, 0.8vw, 14px);
}

.sk-svc--static .sk-svc__track {
	align-items: stretch;
}

.elementor .sk-dm .sk-svc--static .sk-svc__card .sk-svc__name a:not(.elementor-button) {
	color: inherit;
	text-decoration: none;
}

/* Below desktop the row swipes: wider cards so the longest name ("Hyperpigmentation Treatment") fits one line. */
@media (max-width: 1199px) {
	.sk-svc.sk-svc--static {
		--sk-card-w: 236px;
	}

	.sk-svc--static .sk-svc__card .sk-svc__name {
		font-size: 15.5px;
	}

	.sk-svc--static .sk-svc__track {
		width: max-content;
	}
}
