/* ==========================================================================
 * Contact CTA + footer on ONE continuous navy background (2026-11-17)
 *
 * Loaded on the home page and on every page with the global contact band (inc/footer-blend.php),
 * and every rule is scoped to the `ftr-blend` body class that file adds, so no other page's footer
 * changes. The CTA above is the home page's `.gc-quote` (#2226) or the global `.gc-connect` band
 * (assets/contact-cta.css); the `.gc-quote` rules below only ever match on the home page.
 *
 * HOW THE BACKGROUND IS SHARED. The CTA and the footer (`.ftr`, template #2395) are separate
 * elements with no wrapper of their own, so there is no single box to paint.
 *   1. Both get the same deep navy where they meet: the CTA's gradient already ends in #100925, its
 *      faint grid fades out over its lower half, and the footer is flat #100925.
 *   2. The map is the footer's `::after`, absolutely positioned. It covers the footer and reaches
 *      `--fb-reach` up behind the bottom of the CTA, fading in at the top, so there is no seam.
 *   3. Stacking: `.ftr` stops being a stacking context here (`isolation:auto`), so the map layer
 *      (z-index 0) shares the root context with the CTA. The CTA's content and the footer's
 *      content are lifted to z-index 1, so the map paints over the CTA's background but under
 *      its text, buttons and white form panel.
 * The layer is a pseudo-element with only background images: no layout, no pointer events, not
 * in the accessibility tree. The reach applies only while the CTA is the section right above
 * (`:has()`); without it the map stays inside the footer.
 *
 * Elementor's own overlay on the footer container (the dotted map, `::before`) is switched off
 * here only; it still renders on every other page and is still edited in Elementor.
 * ======================================================================== */

/* ---------- tokens ---------- */
body.ftr-blend {
	/* THE content width for the contact CTA and the footer: one value, read by footer.css's --ftr-max
	   below, by home-contact.css (.gc-quote__inner) and by contact-cta.css (.gc-connect__inner). */
	--fb-content: 1400px;
	--fb-deep: #100925;
	--fb-rule: rgb(172 184 222 / 16%);
	--fb-reach: 300px;
	/* Lucide 1.17.0 outlines (ISC), each in a faint rotated tile: web, code, workflow, commerce, growth. */
	--fb-i-web: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='84' height='84' viewBox='0 0 84 84' fill='none'%3E%3Cg transform='rotate(-10 42 42)'%3E%3Crect x='8.5' y='8.5' width='67' height='67' rx='13' fill='%2318354C' fill-opacity='.08' stroke='%2363AFC4' stroke-opacity='.26'/%3E%3Cg transform='translate(26 26) scale(1.3333)' stroke='%2373CAE0' stroke-opacity='.4' stroke-width='.85' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect width='18' height='18' x='3' y='3' rx='2'/%3E%3Cpath d='M3 9h18'/%3E%3Cpath d='M9 21V9'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
	--fb-i-code: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='84' height='84' viewBox='0 0 84 84' fill='none'%3E%3Cg transform='rotate(12 42 42)'%3E%3Crect x='8.5' y='8.5' width='67' height='67' rx='13' fill='%2318354C' fill-opacity='.08' stroke='%2363AFC4' stroke-opacity='.26'/%3E%3Cg transform='translate(26 26) scale(1.3333)' stroke='%2373CAE0' stroke-opacity='.4' stroke-width='.85' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m18 16 4-4-4-4'/%3E%3Cpath d='m6 8-4 4 4 4'/%3E%3Cpath d='m14.5 4-5 16'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
	--fb-i-ai: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='84' height='84' viewBox='0 0 84 84' fill='none'%3E%3Cg transform='rotate(8 42 42)'%3E%3Crect x='8.5' y='8.5' width='67' height='67' rx='13' fill='%2318354C' fill-opacity='.08' stroke='%2363AFC4' stroke-opacity='.26'/%3E%3Cg transform='translate(26 26) scale(1.3333)' stroke='%2373CAE0' stroke-opacity='.4' stroke-width='.85' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect width='8' height='8' x='3' y='3' rx='2'/%3E%3Cpath d='M7 11v4a2 2 0 0 0 2 2h4'/%3E%3Crect width='8' height='8' x='13' y='13' rx='2'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
	--fb-i-commerce: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='84' height='84' viewBox='0 0 84 84' fill='none'%3E%3Cg transform='rotate(-12 42 42)'%3E%3Crect x='8.5' y='8.5' width='67' height='67' rx='13' fill='%2318354C' fill-opacity='.08' stroke='%2363AFC4' stroke-opacity='.26'/%3E%3Cg transform='translate(26 26) scale(1.3333)' stroke='%2373CAE0' stroke-opacity='.4' stroke-width='.85' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M16 10a4 4 0 0 1-8 0'/%3E%3Cpath d='M3.103 6.034h17.794'/%3E%3Cpath d='M3.4 5.467a2 2 0 0 0-.4 1.2V20a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2V6.667a2 2 0 0 0-.4-1.2l-2-2.667A2 2 0 0 0 17 2H7a2 2 0 0 0-1.6.8z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
	--fb-i-growth: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='84' height='84' viewBox='0 0 84 84' fill='none'%3E%3Cg transform='rotate(8 42 42)'%3E%3Crect x='8.5' y='8.5' width='67' height='67' rx='13' fill='%2318354C' fill-opacity='.08' stroke='%2363AFC4' stroke-opacity='.26'/%3E%3Cg transform='translate(26 26) scale(1.3333)' stroke='%2373CAE0' stroke-opacity='.4' stroke-width='.85' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M12 16v5'/%3E%3Cpath d='M16 14v7'/%3E%3Cpath d='M20 10v11'/%3E%3Cpath d='m22 3-8.646 8.646a.5.5 0 0 1-.708 0L9.354 8.354a.5.5 0 0 0-.708 0L2 15'/%3E%3Cpath d='M4 18v3'/%3E%3Cpath d='M8 14v7'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
}

/* ---------- CTA: same navy at the seam, less space before the footer ---------- */
body.ftr-blend .e-con.gc-quote {
	--padding-bottom: 36px;
	/* Elementor's 20px row gap sat between the content and the (empty) Cal.com loader widget. */
	--row-gap: 0px;
	--gap: 0px;
	/* The CTA's own stack (home-contact.css) with one layer added: a fade that takes the faint
	   grid out over the lower half, so the grid never stops at a hard line above the footer. */
	background-image:
		url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='560' height='360' viewBox='0 0 560 360' fill='none'%3E%3Cg stroke='%230AA3D6' stroke-opacity='.22' stroke-width='1'%3E%3Cpath d='M0 120h150l30 30h110'/%3E%3Cpath d='M0 200h90l24-24h96'/%3E%3Cpath d='M380 0v70l-30 30v60'/%3E%3C/g%3E%3Cg fill='%230AA3D6' fill-opacity='.45'%3E%3Ccircle cx='290' cy='150' r='3'/%3E%3Ccircle cx='210' cy='176' r='3'/%3E%3Ccircle cx='350' cy='160' r='3'/%3E%3C/g%3E%3C/svg%3E"),
		linear-gradient(180deg, rgb(16 9 37 / 0%) 45%, var(--fb-deep) 92%),
		linear-gradient(rgb(255 255 255 / 3.2%) 1px, transparent 1px),
		linear-gradient(90deg, rgb(255 255 255 / 3.2%) 1px, transparent 1px),
		linear-gradient(180deg, var(--gq-navy, #170d3d) 0%, var(--fb-deep) 100%);
	background-size: 560px 360px, 100% 100%, 48px 48px, 48px 48px, auto;
	background-position: left -40px top 38%, 0 0, center top, center top, center;
	background-repeat: no-repeat, no-repeat, repeat, repeat, no-repeat;
}
/* Lifted above the footer's map layer (see the header). */
body.ftr-blend .e-con.gc-quote > .e-con,
body.ftr-blend .e-con.gc-quote > .elementor-widget,
body.ftr-blend .e-con.gc-connect > .e-con,
body.ftr-blend .e-con.gc-connect > .elementor-widget {
	position: relative;
	z-index: 1;
}

/* ---------- footer: one surface with the CTA ---------- */
body.ftr-blend .elementor-2395 .elementor-element.ftr.e-con {
	/* The footer's content edge = the CTA's: --fb-content wide, same side padding per tier. */
	--ftr-gutter: 20px;
	--ftr-max: calc(var(--fb-content) + 2 * var(--ftr-gutter));
	/* Muted footer text a step lighter than the base sheet's .72: over the brightest part of the map
	   on a phone the base value measured 4.44:1; .8 keeps every link above 4.5:1. */
	--ftr-muted: rgba(255, 255, 255, .8);
	background: var(--fb-deep);
	isolation: auto;
	overflow: visible;
	overflow-x: clip;
}
body.ftr-blend .elementor-2395 .elementor-element.ftr.e-con::before {
	display: none;
}
body.ftr-blend .elementor-2395 .elementor-element.ftr.e-con::after {
	content: "";
	position: absolute;
	z-index: 0;
	inset: 0;
	pointer-events: none;
	background-image:
		var(--fb-i-ai), var(--fb-i-code), var(--fb-i-commerce), var(--fb-i-growth), var(--fb-i-web),
		/* dark overlay for text contrast; lighter to the right, where the columns are shorter */
		linear-gradient(90deg, rgb(17 11 45 / 42%), rgb(17 11 45 / 28%) 55%, rgb(17 11 45 / 22%)),
		url("footer-markets-map.svg");
	background-repeat: no-repeat;
	/* Icons only where no text can ever be under them, opened countries included: the band
	   below the CTA (workflow, code) and, from 1640px, the side gutters (the other three). */
	background-size: 84px 84px, 84px 84px, 84px 84px, 84px 84px, 84px 84px, 100% 100%, max(112%, 1180px) auto;
	background-position: 47% 3%, 98% 24%, right 1% bottom 110px, left 1.2% bottom 150px, left 0.5% top 46%, 0 0, 42% 58%;
	-webkit-mask-image: linear-gradient(180deg, transparent 0, #000 var(--fb-fade, 30%), #000 calc(100% - 30px), transparent 100%);
	mask-image: linear-gradient(180deg, transparent 0, #000 var(--fb-fade, 30%), #000 calc(100% - 30px), transparent 100%);
}
body.ftr-blend:has(.e-con.gc-quote) .elementor-2395 .elementor-element.ftr.e-con::after,
body.ftr-blend:not(.gc-no-connect):has(.e-con.gc-connect) .elementor-2395 .elementor-element.ftr.e-con::after {
	top: calc(-1 * var(--fb-reach));
}
/* The three gutter tiles need ~100px of side margin beside the 1400px content: from 1640px only. */
@media (max-width: 1639px) {
	body.ftr-blend .elementor-2395 .elementor-element.ftr.e-con::after {
		background-size: 84px 84px, 84px 84px, 0 0, 0 0, 0 0, 100% 100%, max(112%, 1180px) auto;
	}
}
body.ftr-blend .ftr > .e-con.ftr__inner,
body.ftr-blend .ftr > .e-con.ftr-bottom {
	position: relative;
	z-index: 1;
}

/* ---------- four columns in one row (1024px and up) ---------- */
/* A grid, not the base sheet's wrapping flex row: Company + Services are ONE Elementor container
   (a two-track grid of their own), so three tracks here read as four columns. */
body.ftr-blend .ftr > .e-con.ftr__inner {
	display: grid;
	grid-template-columns: minmax(0, .9fr) minmax(0, 1.75fr) minmax(0, 1.45fr);
	align-items: start;
	column-gap: clamp(24px, 2.6vw, 40px);
	row-gap: 40px;
	padding-top: 44px;
	/* The divider between the CTA and the footer navigation: a 1px line across the content
	   width only, drawn as a background so it is not an element. */
	background-image: linear-gradient(var(--fb-rule), var(--fb-rule));
	background-size: calc(100% - 2 * var(--ftr-gutter)) 1px;
	background-position: 50% 0;
	background-repeat: no-repeat;
}
body.ftr-blend .ftr__inner > .e-con.ftr-col {
	width: 100%;
	max-width: none;
	min-width: 0;
}
/* The closing links ("View More", "Explore Solutions") use the CTA's text cyan here: the brand
   cyan measured 4.25:1 where a link crosses the brightest part of the map; #5FD0F1 is 9.7:1 on
   the navy and stays above 4.5:1 over the map. */
body.ftr-blend .ftr .ftr-locgrid__more { color: var(--gq-cyan-text, #5fd0f1); }
body.ftr-blend .ftr .ftr-locgrid__more:hover,
body.ftr-blend .ftr .ftr-locgrid__more:focus-visible { color: #fff; }
body.ftr-blend .ftr__inner > .e-con.ftr-col--services {
	grid-template-columns: minmax(0, .85fr) minmax(0, 1.15fr);
	column-gap: clamp(24px, 2.6vw, 40px);
}

/* 1024–1199: the base sheet's tablet tier lifts links to 16px for a stacked footer. In four
   columns that wraps the email address and the closing links, so this tier keeps the desktop
   15px (14px for the closing links), which is what the rest of the site uses at this width. */
@media (min-width: 1024px) and (max-width: 1199px) {
	body.ftr-blend .ftr .ftr-links__item > a,
	body.ftr-blend .ftr .ftr-locgrid__link,
	body.ftr-blend .ftr .ftr-contact__body { font-size: 15px; }
	body.ftr-blend .ftr .ftr-locgrid__more { font-size: 14px; }
	body.ftr-blend .ftr .ftr-col__title,
	body.ftr-blend .ftr .ftr-locgrid__title { font-size: 19px; }
}

/* ---------- 768–1023: brand across the top, then Company · Services · Markets ---------- */
@media (max-width: 1023px) {
	body.ftr-blend .ftr > .e-con.ftr__inner {
		grid-template-columns: minmax(0, 2fr) minmax(0, 1fr);
		column-gap: 28px;
	}
	body.ftr-blend .ftr__inner > .e-con.ftr-col--brand {
		grid-column: 1 / -1;
		flex-direction: row;
		flex-wrap: wrap;
		align-items: center;
		justify-content: space-between;
		gap: 16px 40px;
	}
	body.ftr-blend .ftr-col--brand .ftr-contact,
	body.ftr-blend .ftr-col--brand .ftr-social {
		margin-top: 0;
	}
	body.ftr-blend .ftr .ftr-locgrid--markets .ftr-locgrid__grid--markets {
		grid-template-columns: minmax(0, 1fr);
		row-gap: 14px;
	}
	body.ftr-blend .elementor-2395 .elementor-element.ftr.e-con::after {
		background-size: 84px 84px, 84px 84px, 0 0, 0 0, 0 0, 100% 100%, 150% auto;
		background-position: 52% 4%, 99% 20%, 0 0, 0 0, 0 0, 0 0, 36% 64%;
	}
}
@media (max-width: 899px) {
	body.ftr-blend .elementor-2395 .elementor-element.ftr.e-con { --ftr-gutter: 18px; }
	body.ftr-blend .e-con.gc-quote { --padding-bottom: 32px; }
}

/* ---------- phones: brand, Company | Services, Markets (Canada | UAE, USA | Worldwide) ---------- */
@media (max-width: 767px) {
	body.ftr-blend { --fb-reach: 200px; }
	body.ftr-blend .elementor-2395 .elementor-element.ftr.e-con { --ftr-gutter: 16px; }
	body.ftr-blend .e-con.gc-quote {
		--padding-bottom: 32px;
		background-position: left -260px top 22%, 0 0, center top, center top, center;
	}
	body.ftr-blend .ftr > .e-con.ftr__inner {
		grid-template-columns: minmax(0, 1fr);
		row-gap: 36px;
		padding-top: 40px;
	}
	body.ftr-blend .ftr__inner > .e-con.ftr-col--brand {
		flex-direction: column;
		align-items: flex-start;
		gap: 0;
		margin-bottom: 0;
	}
	body.ftr-blend .ftr-col--brand .ftr-contact { margin-top: 24px; }
	body.ftr-blend .ftr-col--brand .ftr-social { margin-top: 24px; }
	body.ftr-blend .ftr__inner > .e-con.ftr-col--services {
		display: grid;
		grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
		column-gap: 20px;
	}
	/* The base sheet rules each group as one long mobile list of accordions; here they are open
	   columns (footer.js builds no accordions on this page), so the rules and padding go. */
	body.ftr-blend .ftr .ftr-links--footer-company,
	body.ftr-blend .ftr .ftr-links--service-category,
	body.ftr-blend .ftr .ftr-locgrid {
		padding: 0;
		border: 0;
	}
	body.ftr-blend .ftr .ftr-locgrid--markets .ftr-locgrid__grid--markets {
		grid-template-columns: repeat(2, minmax(0, 1fr));
		column-gap: 16px;
		row-gap: 20px;
	}
	body.ftr-blend .ftr .ftr-bottom__inner { border-top: 1px solid var(--fb-rule); padding-top: 22px; }
	body.ftr-blend .elementor-2395 .elementor-element.ftr.e-con::after {
		--fb-fade: 14%;
		background-size: 0 0, 70px 70px, 0 0, 0 0, 0 0, 100% 100%, 240% auto;
		background-position: 0 0, 104% 30%, 0 0, 0 0, 0 0, 0 0, 30% 52%;
	}
}
@media (max-width: 379px) {
	body.ftr-blend .elementor-2395 .elementor-element.ftr.e-con { --ftr-gutter: 12px; }
	/* "UNITED STATES" holds one line in a 140px cell: a tighter gap, a 22px flag, less tracking. */
	body.ftr-blend .ftr .ftr-locgrid--markets .ftr-locgrid__grid--markets { column-gap: 12px; }
	body.ftr-blend .ftr .ftr-locgrid--markets .ftr-locgrid__flag { width: 22px; height: 22px; }
	body.ftr-blend .ftr .ftr-locgrid--markets .ftr-locgrid__head { gap: 7px; }
	body.ftr-blend .ftr .ftr-locgrid--markets .ftr-locgrid__country-name { letter-spacing: .01em; }
}
