/* Zenesis v2 — Services page: "Four Core Services" overview (section class zn-svo; banner and consultation band come
   from service.css). Content, colours and typography stay in Elementor / Site Settings.
     .zn-svo__accent   vertical gold line beside the heading (draws down on enter)
     .zn-svo__grid     the services, two per row (one on tablet / mobile)
     .zn-svo__card     one service: .zn-svo__media (photo, number) + .zn-svo__body (title, intro line, three focus
                       areas, Explore Service)
     .zn-svo-rv        fades up on enter, staggered (services-page.js) */

.zn-svo .zn-svo__dot { color: var(--e-global-color-primary); }

/* ════════ Card ════════ */
.zn-svo .zn-svo__card {
	position: relative; overflow: hidden; isolation: isolate;
	border: 1px solid var(--e-global-color-zn_line, #E8E6E3);
	transition: border-color .5s ease, box-shadow .6s ease, translate .6s var(--zn-ease-out, ease);
}
.zn-svo .zn-svo__card::before { /* gold rule drawn along the top */
	content: ""; position: absolute; z-index: 2; left: 0; top: 0; width: 100%; height: 3px;
	background: var(--e-global-color-primary);
	transform: scaleX(0); transform-origin: 0 50%; transition: transform .7s var(--zn-ease-out, ease);
}

/* photo fills its column; the number sits on it */
.zn-svo .zn-svo__media { position: relative; overflow: hidden; min-height: 100%; background: var(--e-global-color-secondary, #231F20); }
.zn-svo .zn-svo__photo.elementor-widget { position: absolute; inset: 0; margin: 0; }
.zn-svo .zn-svo__photo .elementor-widget-container, .zn-svo .zn-svo__photo a { display: block; height: 100%; }
.zn-svo .zn-svo__photo img {
	display: block; width: 100%; height: 100%; max-width: none; object-fit: cover; border-radius: 0;
	transition: scale 1.4s var(--zn-ease-out, ease);
}
.zn-svo .zn-svo__media::after { /* soft shade so the number reads */
	content: ""; position: absolute; inset: 0; pointer-events: none;
	background: linear-gradient(180deg, rgb(35 31 32 / .55) 0, rgb(35 31 32 / 0) 38%);
}
.zn-svo .zn-svo__num.elementor-widget { position: absolute; z-index: 1; left: 22px; top: 20px; margin: 0; pointer-events: none; }
.zn-svo .zn-svo__num .elementor-heading-title { display: inline-flex; align-items: center; gap: 10px; }
.zn-svo .zn-svo__num .elementor-heading-title::after { content: ""; width: 22px; height: 1px; background: currentColor; transition: width .6s var(--zn-ease-out, ease); }

/* text: the column takes the room beside the photo (Elementor gives inner containers a 100% width) */
.zn-svo .zn-svo__body.e-con { --width: auto; flex: 1 1 0%; min-width: 0; }
.zn-svo .zn-svo__title .elementor-heading-title { text-wrap: balance; }
.zn-svo .zn-svo__title a { color: inherit; transition: color .35s ease; }
.zn-svo .zn-svo__desc p { margin: 0; }
.zn-svo .zn-svo__area { padding: 11px 0; border-top: 1px solid var(--e-global-color-zn_line, #E8E6E3); }
.zn-svo .zn-svo__area:last-child { border-bottom: 1px solid var(--e-global-color-zn_line, #E8E6E3); }
.zn-svo .zn-svo__icon.elementor-widget { margin: 0; }
.zn-svo .zn-svo__icon img { display: block; transition: translate .5s var(--zn-ease-out, ease); }
.zn-svo .zn-svo__area-title .elementor-heading-title { line-height: 1.35; }
.zn-svo .zn-svo__body > .zn-svo__link { padding-top: 24px; margin-top: auto !important; } /* at the foot when a neighbour is taller */

/* ════════ Hover / focus ════════ */
@media (hover: hover) {
	.zn-svo .zn-svo__card:hover {
		translate: 0 -4px;
		border-color: color-mix(in srgb, var(--e-global-color-primary) 45%, var(--e-global-color-zn_line, #E8E6E3));
		box-shadow: 0 26px 50px -30px rgb(15 19 43 / .35);
	}
	.zn-svo .zn-svo__card:hover::before { transform: scaleX(1); }
	.zn-svo .zn-svo__card:hover .zn-svo__photo img { scale: 1.06; }
	.zn-svo .zn-svo__card:hover .zn-svo__num .elementor-heading-title::after { width: 36px; }
	.zn-svo .zn-svo__card:hover .zn-svo__title a { color: var(--e-global-color-primary); }
	.zn-svo .zn-svo__card:hover .zn-svo__area .zn-svo__icon img { translate: 3px 0; }
}
.zn-svo .zn-svo__card:focus-within { border-color: color-mix(in srgb, var(--e-global-color-primary) 45%, var(--e-global-color-zn_line, #E8E6E3)); }
.zn-svo .zn-svo__card:focus-within::before { transform: scaleX(1); }

/* ════════ Reveal ════════ */
.zn-svo.is-armed .zn-svo-rv { opacity: 0; translate: 0 28px; }
.zn-svo.is-armed .zn-svo-rv.is-in {
	opacity: 1; translate: 0 0;
	transition: opacity .9s ease var(--zn-d, 0s), translate 1.1s var(--zn-ease-out, ease) var(--zn-d, 0s),
		border-color .5s ease, box-shadow .6s ease;
}
.zn-svo.is-armed .zn-svo__card.zn-svo-rv.is-in:hover { translate: 0 -4px; transition-delay: 0s; }
.zn-svo.is-armed .zn-svo__accent { scale: 1 0; transform-origin: 50% 0; }
.zn-svo.is-armed .zn-svo__accent.is-in { scale: 1 1; transition: scale 1.2s var(--zn-ease-out, ease) .1s; }

/* ════════ Tablet / mobile ════════ */
@media (max-width: 1024px) {
	.zn-svo .zn-svo__num.elementor-widget { left: 18px; top: 16px; }
}
@media (max-width: 767px) {
	.zn-svo .zn-svo__media { min-height: 0; aspect-ratio: 16 / 9; }
	.zn-svo .zn-svo__body > .zn-svo__link { padding-top: 20px; }
}

@media (prefers-reduced-motion: reduce) {
	.zn-svo *, .zn-svo *::before, .zn-svo *::after { transition-duration: .01s !important; transition-delay: 0s !important; }
	.zn-svo .zn-svo__card:hover { translate: none; }
	.zn-svo .zn-svo__card:hover .zn-svo__photo img { scale: 1; }
}
