/* ==========================================================================
   RTL overrides (Arabic)
   ========================================================================== */

html[dir="rtl"] body {
	direction: rtl;
	text-align: right;
	font-family: "Cairo", var(--font-body), sans-serif;
}

html[dir="rtl"] .display,
html[dir="rtl"] .hero__title,
html[dir="rtl"] .page-hero__title,
html[dir="rtl"] .sec-title,
html[dir="rtl"] .statement__title,
html[dir="rtl"] .landing-quick__title,
html[dir="rtl"] .landing-cta h2,
html[dir="rtl"] h1,
html[dir="rtl"] h2,
html[dir="rtl"] h3,
html[dir="rtl"] h4 {
	font-family: "Cairo", var(--font-display), sans-serif;
	font-weight: 700;
	text-transform: none;
	letter-spacing: 0;
}

/* Arabic script is taller than Latin: relax the tight display leading and
   scale display sizes down so ascenders, descenders and diacritics never
   collide between lines. */
html[dir="rtl"] .display,
html[dir="rtl"] .hero__title,
html[dir="rtl"] .page-hero__title,
html[dir="rtl"] .sec-title,
html[dir="rtl"] .statement__title,
html[dir="rtl"] .landing-intro__title,
html[dir="rtl"] .landing-quick__title,
html[dir="rtl"] .landing-cta h2,
html[dir="rtl"] .why__title,
html[dir="rtl"] .inquiry__title,
html[dir="rtl"] .footer__cta-title,
html[dir="rtl"] .design-offer__title,
html[dir="rtl"] .systems-row__body h2,
html[dir="rtl"] .entry h2,
html[dir="rtl"] .entry h3,
html[dir="rtl"] .entry h4,
html[dir="rtl"] h1,
html[dir="rtl"] h2,
html[dir="rtl"] h3,
html[dir="rtl"] h4 {
	line-height: 1.32;
}

html[dir="rtl"] .hero__title {
	font-size: clamp(38px, 5.2vw, 74px);
	max-width: 13em;
}

html[dir="rtl"] .page-hero__title {
	font-size: clamp(34px, 5.4vw, 84px);
	max-width: 17em;
}

html[dir="rtl"] .sec-title {
	font-size: clamp(28px, 3.4vw, 50px);
}

html[dir="rtl"] .article-hero .page-hero__title,
html[dir="rtl"] .term-hero .page-hero__title,
html[dir="rtl"] .product-single-hero .page-hero__title {
	font-size: clamp(28px, 3.8vw, 54px);
	line-height: 1.38;
	max-width: 24em;
}

html[dir="rtl"] .footer__cta-title {
	font-size: clamp(32px, 4.2vw, 58px);
}

html[dir="rtl"] .design-offer__title {
	font-size: clamp(30px, 4vw, 56px);
}

html[dir="rtl"] .landing-cta h2 {
	font-size: clamp(28px, 3.6vw, 52px);
}

html[dir="rtl"] .mono {
	letter-spacing: 0;
}

html[dir="rtl"] .topbar__dot {
	margin-right: 0;
	margin-left: 7px;
}

html[dir="rtl"] .topbar__group:last-child {
	margin-left: 0;
}

html[dir="rtl"] .lang-switch__list {
	right: auto;
	left: 0;
}

html[dir="rtl"] .hero__copy {
	padding-right: var(--gutter);
	padding-left: clamp(24px, 4vw, 72px);
}

html[dir="rtl"] .hero__copy::before {
	left: auto;
	right: calc(var(--gutter) - 1px);
}

html[dir="rtl"] .hero__coord {
	right: auto;
	left: 22px;
}

html[dir="rtl"] .stat {
	border-right: 0;
	border-left: 1px solid var(--line);
}

html[dir="rtl"] .stat:first-child {
	border-left: 0;
	border-right: 1px solid var(--line);
}

html[dir="rtl"] .stat:last-child {
	border-left: 0;
}

html[dir="rtl"] .statement__quote {
	border-left: 0;
	border-right: 3px solid var(--orange);
}

html[dir="rtl"] .process__step {
	border-right: 0;
	border-left: 1px solid var(--line);
}

html[dir="rtl"] .process__step:last-child {
	border-left: 0;
}

html[dir="rtl"] .process__step::before {
	left: auto;
	right: clamp(14px, 1.8vw, 24px);
}

html[dir="rtl"] .work-card__body,
html[dir="rtl"] .insight-card__body,
html[dir="rtl"] .product-card__body,
html[dir="rtl"] .project-card__body,
html[dir="rtl"] .cert-card {
	text-align: right;
}

html[dir="rtl"] .landing-system__media span {
	left: auto;
	right: 14px;
}

html[dir="rtl"] .landing-nav__cta {
	margin-left: 0;
	margin-right: auto;
}

html[dir="rtl"] .landing-apps {
	border-left: 0;
	border-right: 1px solid var(--line-strong);
}

html[dir="rtl"] .landing-app {
	border-right: 0;
	border-left: 1px solid var(--line);
}

html[dir="rtl"] .landing-app .mono {
	text-align: right;
}

html[dir="rtl"] .landing-cta__links,
html[dir="rtl"] .landing-cta__deliverables,
html[dir="rtl"] .landing-faq__foot {
	text-align: right;
}

html[dir="rtl"] .inq-dock {
	right: auto;
	left: clamp(14px, 2.2vw, 28px);
}

/* The panel is absolute to the dock: in RTL it must grow from the dock's
   left edge, otherwise it is pushed off-screen and clipped. */
html[dir="rtl"] .inq-dock__panel {
	right: auto;
	left: 0;
	transform-origin: bottom left;
}

html[dir="rtl"] .inq-dock__teaser {
	right: auto;
	left: 0;
}

html[dir="rtl"] .inq-dock__teaser-close {
	border-left: 0;
	border-right: 1px solid var(--line);
}

html[dir="rtl"] .field select {
	padding-right: 0;
	padding-left: 24px;
	background-position: left 2px center;
}

html[dir="rtl"] .link-arrow svg,
html[dir="rtl"] .btn--ghost svg {
	transform: scaleX(-1);
}

html[dir="rtl"] .landing-quick__fields input,
html[dir="rtl"] .field input,
html[dir="rtl"] .field textarea {
	text-align: right;
}

html[dir="rtl"] .landing-scope li {
	padding-left: 0;
	padding-right: 18px;
}

html[dir="rtl"] .landing-scope li::before {
	left: auto;
	right: 0;
}

html[dir="rtl"] .media-caption {
	direction: rtl;
}

html[dir="rtl"] .also a,
html[dir="rtl"] .filter-bar button {
	text-align: right;
}

@media (max-width: 760px) {
	html[dir="rtl"] .hero__copy {
		padding-right: var(--gutter);
		padding-left: var(--gutter);
	}

	html[dir="rtl"] .stat {
		border-left: 0;
		border-right: 0;
	}

	html[dir="rtl"] .stat:nth-child(2n) {
		border-left: 0;
	}

	html[dir="rtl"] .stat:nth-child(2n + 1) {
		border-left: 1px solid var(--line);
	}

	html[dir="rtl"] .process__step {
		border-left: 0;
	}

	html[dir="rtl"] .landing-app {
		border-left: 0;
	}

	html[dir="rtl"] .inq-dock {
		left: 0;
		right: 0;
	}

	html[dir="rtl"] .inq-dock__panel {
		left: 0;
		right: 0;
		width: 100%;
		transform-origin: bottom center;
	}
}
