/*
 * iDrive.pk first-screen booking CTA, help-trigger placement, condensed header
 * and install-sheet guard. Release idrive-cta-wording-20261016 (owner request
 * 16 Oct 2026). Loaded last by mu-plugins/idrive-cta-wording-20261016.php.
 */

/* 1. Mobile/tablet header booking button. The desktop .header-book is hidden
   at <=1050px (app.css), so phones had no booking control in the header. */
.site-header .header-book-mobile { display: none; }
@media (max-width: 1050px) {
	.site-header .site-header__actions { gap: 8px; }
	.site-header .header-book-mobile {
		display: inline-flex;
		align-items: center;
		justify-content: center;
		flex: 0 0 auto;
		min-height: 44px;
		padding: 0 16px;
		border: 1px solid #0f3d2e;
		border-radius: 999px;
		background: #0f3d2e;
		color: #fff;
		font-size: .875rem;
		font-weight: 700;
		line-height: 1.1;
		white-space: nowrap;
		text-decoration: none;
		box-shadow: 0 6px 16px rgba(15, 61, 46, .18);
	}
	.site-header .header-book-mobile:hover { background: #145b43; border-color: #145b43; color: #fff; }
	.site-header .header-book-mobile:focus-visible { outline: 3px solid #f4bd4a; outline-offset: 2px; }
}
@media (max-width: 430px) {
	.site-header .container.site-header__inner { gap: 8px !important; padding-inline: 12px !important; }
	/* corridor-v1.css hangs the flag 9px outside the lockup (absolute, right:-9px). */
	.site-header .site-header__inner > .brand { flex: 0 1 auto !important; min-width: 0 !important; width: auto !important; margin-inline-end: 12px !important; }
	.site-header .site-header__inner > .site-header__actions { gap: 6px !important; flex: 0 0 auto !important; margin-inline-start: auto; }
	.site-header .site-header__actions .header-book-mobile { padding: 0 12px !important; font-size: .8125rem !important; }
	/* The 9px tagline is the widest line of the lockup; on phones it sat under
	   the booking button. The emblem and name carry the brand at this size. */
	.site-header .site-header__inner > .brand .brand-copy small { display: none !important; }
}
@media (max-width: 359px) {
	.site-header .site-header__inner > .brand .brand-emblem { width: 2rem !important; height: 2rem !important; }
	.site-header .site-header__inner > .brand .brand-name { font-size: 21px !important; }
	.site-header .site-header__inner > .brand .brand-domain { font-size: 12px !important; }
	.site-header .site-header__inner > .brand .brand-flag { display: none !important; }
	.site-header .site-header__inner > .brand { margin-inline-end: 4px !important; }
	.site-header .site-header__actions .header-book-mobile { padding: 0 9px !important; font-size: .75rem !important; }
}

/* 2. Condensed header after scrolling (desktop 134px -> about 70px, phone
   78px -> about 62px). margin-block-end (set by first-screen.js to the height
   difference) keeps the page flow unchanged, so nothing below moves. */
.site-header { transition: box-shadow .2s ease; }
.site-header.is-condensed { box-shadow: 0 6px 22px rgba(8, 32, 26, .10); margin-block-end: var(--idrive-cta-header-delta, 0px); }
@media (min-width: 1051px) {
	.site-header.is-condensed .desktop-nav,
	.site-header.is-condensed .header-app-center { display: none !important; }
	.site-header.is-condensed .site-header__inner { min-height: 0 !important; padding-block: 4px !important; row-gap: 0 !important; }
	.site-header.is-condensed .brand .brand-emblem { width: 2.5rem !important; height: 2.5rem !important; }
}
@media (max-width: 1050px) {
	.site-header.is-condensed .site-header__inner { min-height: 3.875rem !important; }
	.site-header.is-condensed .brand .brand-emblem { width: 2.2rem !important; height: 2.2rem !important; }
}
@media (prefers-reduced-motion: reduce) { .site-header { transition: none; } }

/* 3. Field help "?" sits inline straight after its label (en, ur, ar). The
   visible disc stays 28px; a transparent ::before gives a 44px tap area. */
.booking-shell__field:has(> .idrive-contextual-help) {
	flex-direction: row !important;
	flex-wrap: wrap !important;
	align-items: center !important;
	justify-content: flex-start !important;
	column-gap: 4px;
}
.booking-shell__field:has(> .idrive-contextual-help) > label,
.booking-shell__field:has(> .idrive-contextual-help) > .booking-shell__caption {
	flex: 0 1 auto !important;
	width: auto !important;
	max-width: calc(100% - 52px);
	padding-inline-end: 0 !important;
}
.booking-shell__field:has(> .idrive-contextual-help) > :not(label):not(.booking-shell__caption):not(.idrive-contextual-help) {
	flex: 1 0 100% !important;
	max-width: 100%;
}
.booking-shell .booking-shell__field > .idrive-contextual-help,
#idrive-journey-composer .booking-shell__field > .idrive-contextual-help {
	position: relative !important;
	inset: auto !important;
	z-index: 4;
	display: inline-flex;
	flex: 0 0 auto;
	margin: -6px 0 !important;
	width: auto;
}
.booking-shell .booking-shell__field > .idrive-contextual-help .idrive-contextual-help__trigger,
#idrive-journey-composer .booking-shell__field > .idrive-contextual-help .idrive-contextual-help__trigger {
	position: relative;
	width: 28px !important;
	height: 28px !important;
	min-width: 28px !important;
	min-height: 28px !important;
	padding: 0 !important;
}
.booking-shell__field > .idrive-contextual-help .idrive-contextual-help__trigger::before {
	content: "";
	position: absolute;
	inset: -8px;
	border-radius: 50%;
}

/* 4. The passive "Install iDrive.pk" sheet is a phone prompt. Never show it on
   desktop widths or on the 404 page, where it covered the search. */
@media (min-width: 821px) {
	.appx-sheet.appx-sheet--passive { display: none !important; }
}
.error404 .appx-sheet.appx-sheet--passive { display: none !important; }

/* 5. Booking note with its own button (guides). */
.results-boundary.idrive-book-note { display: grid; gap: .5rem; justify-items: start; }
.results-boundary.idrive-book-note .button { margin-block-start: .25rem; }
/* The inherited span colour (#cbdad3) was made for a dark panel; on this white
   card it measured about 1.4:1. #3d5249 on #fff is about 8.6:1. */
.results-boundary.idrive-book-note > span { color: #3d5249 !important; }
