/* ==========================================================================
   Quality Immigration — About (page 10) & Contact (page 11)
   Extends assets/qi-design.css. Nothing here is used by other pages, with the
   exception of the Fluent Forms skin, which is written so it would behave if
   the form is ever embedded elsewhere.

   1 page canvas · 2 About: hero, timeline, values · 3 Contact: hero, layout,
   contact card · 4 Fluent Forms skin · 5 small screens
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. Page canvas
   Mirrors the .home / .qi-canvas treatment in qi-design.css so these two pages
   are edge-to-edge editorial canvases rather than boxed article pages. Scoped
   by page id so no other page is affected while agents build in parallel.
   -------------------------------------------------------------------------- */

body.qi.page-id-10 #main-container .ct-container,
body.qi.page-id-11 #main-container .ct-container {
	max-width: none;
	padding-left: 0;
	padding-right: 0;
}

body.qi.page-id-10 .entry-content,
body.qi.page-id-11 .entry-content {
	padding: 0;
}

body.qi.page-id-10 .entry-content > *,
body.qi.page-id-11 .entry-content > * {
	max-width: none;
	margin-block: 0;
}

body.qi.page-id-10 article.page,
body.qi.page-id-10 article.post,
body.qi.page-id-11 article.page,
body.qi.page-id-11 article.post {
	padding: 0;
}

/* The hero carries the page title on both pages. */
body.qi.page-id-10 .entry-header,
body.qi.page-id-10 .hero-section,
body.qi.page-id-11 .entry-header,
body.qi.page-id-11 .hero-section {
	display: none;
}

body.qi.page-id-10 .ct-container-full,
body.qi.page-id-11 .ct-container-full {
	padding-top: 0;
	padding-bottom: 0;
}

/* --------------------------------------------------------------------------
   2. About
   -------------------------------------------------------------------------- */

/* 2a. Interior hero — shorter than the front-page hero, same duotone wash. */

body.qi .qi-hero-page.wp-block-cover {
	min-height: min(62vh, 560px);
	padding: clamp(4.5rem, 3rem + 6vw, 7.5rem) var(--qi-gutter);
}

body.qi .qi-hero-page h1 {
	max-width: 15ch;
}

body.qi .qi-hero-page .qi-lead {
	margin-bottom: 0;
}

/* 2b. Journey timeline ----------------------------------------------------- */

.qi-timeline {
	list-style: none;
	margin: 0;
	padding: 0;
	position: relative;
	max-width: 58rem;
}

/* The spine: a hairline the year markers sit on. */
.qi-timeline::before {
	content: "";
	position: absolute;
	left: 0;
	top: .55rem;
	bottom: .55rem;
	width: 1px;
	background: linear-gradient(
		to bottom,
		transparent 0,
		var(--qi-gold-soft) 6%,
		var(--qi-gold-soft) 94%,
		transparent 100%
	);
}

.qi-timeline-item {
	position: relative;
	padding-left: clamp(1.75rem, 1rem + 2.5vw, 3rem);
	padding-bottom: clamp(2.25rem, 1.5rem + 2vw, 3.25rem);
}

.qi-timeline-item:last-child {
	padding-bottom: 0;
}

/* Gold marker on the spine. */
.qi-timeline-item::before {
	content: "";
	position: absolute;
	left: -4.5px;
	top: .5rem;
	width: 10px;
	height: 10px;
	border-radius: 50%;
	background: var(--qi-ivory-deep);
	border: 1.5px solid var(--qi-gold);
}

.qi-timeline-year {
	display: block;
	font-family: var(--qi-font-body);
	font-size: .8125rem;
	font-weight: 600;
	letter-spacing: .12em;
	text-transform: uppercase;
	color: var(--qi-gold-ink);
	margin-bottom: .55rem;
}

body.qi .qi-timeline-body h3 {
	font-size: clamp(1.25rem, 1.1rem + .7vw, 1.5rem);
	margin: 0 0 .5rem;
	text-wrap: pretty;
}

.qi-timeline-body p {
	margin: 0;
	color: var(--qi-ink-muted);
	max-width: 54ch;
}

/* Wide screens: the year sits in its own column beside the entry. */
@media (min-width: 860px) {
	.qi-timeline-item {
		display: grid;
		grid-template-columns: 9.5rem 1fr;
		column-gap: clamp(1.5rem, 1rem + 1.5vw, 2.5rem);
		align-items: start;
	}

	.qi-timeline-year {
		margin-bottom: 0;
		padding-top: .25rem;
		text-align: right;
	}
}

/* 2c. Values row ----------------------------------------------------------- */

.qi-values {
	margin-top: clamp(2.5rem, 1.5rem + 3vw, 4rem);
}

/* --------------------------------------------------------------------------
   3. Contact
   -------------------------------------------------------------------------- */

/* 3a. Slim tint hero ------------------------------------------------------- */

body.qi .qi-hero-slim {
	padding-block: clamp(3.5rem, 2.5rem + 4vw, 6rem);
}

body.qi .qi-hero-slim h1 {
	max-width: 16ch;
	margin: 0 0 1.25rem;
}

body.qi .qi-hero-slim .qi-lead {
	max-width: 48ch;
	margin: 0;
}

/* 3b. Two-column layout ---------------------------------------------------- */

body.qi .qi-contact-split.wp-block-columns {
	gap: clamp(2rem, 1.2rem + 3vw, 4rem);
}

/* Core forces `align-items: normal !important` on column blocks, so the
   columns are aligned individually or the aside stretches and never sticks. */
body.qi .qi-contact-split > .wp-block-column {
	align-self: flex-start;
}

@media (min-width: 900px) {
	body.qi .qi-contact-split.wp-block-columns {
		flex-wrap: nowrap;
	}

	body.qi .qi-contact-split > .qi-contact-form-col {
		flex-basis: 58% !important;
	}

	body.qi .qi-contact-split > .qi-contact-aside-col {
		flex-basis: 42% !important;
		position: sticky;
		top: 7rem;
	}
}

body.qi .qi-formcard > h2 {
	margin: 0 0 .75rem;
	font-size: var(--qi-h3);
}

body.qi .qi-formcard > p {
	max-width: 46ch;
	margin-bottom: 2.25rem;
}

/* 3c. Contact card --------------------------------------------------------- */

body.qi .qi-contact-card {
	gap: 0;
	display: block;
	height: auto;
}

body.qi .qi-contact-card:hover {
	transform: none;
	border-color: transparent;
}

body.qi .qi-contact-card .qi-eyebrow {
	margin-bottom: 1.35rem;
}

.qi-contact-list {
	list-style: none;
	margin: 0;
	padding: 0;
}

.qi-contact-list li {
	padding-block: 1rem;
	border-top: 1px solid rgba(11, 68, 68, .12);
}

.qi-contact-list li:first-child {
	border-top: 0;
	padding-top: 0;
}

.qi-contact-label {
	display: block;
	font-size: .75rem;
	font-weight: 600;
	letter-spacing: .12em;
	text-transform: uppercase;
	color: var(--qi-ink-soft);
	margin-bottom: .3rem;
}

body.qi .qi-contact-value {
	display: inline-block;
	font-family: var(--qi-font-head);
	font-weight: 600;
	font-size: clamp(1.0625rem, 1rem + .35vw, 1.1875rem);
	line-height: 1.35;
	color: var(--qi-teal-800);
	text-decoration: none;
	overflow-wrap: anywhere;
	transition: color .22s var(--qi-ease);
}

body.qi a.qi-contact-value:hover {
	color: var(--qi-teal-600);
	text-decoration: underline;
	text-decoration-color: var(--qi-gold-soft);
}

body.qi .qi-contact-value-plain {
	font-family: var(--qi-font-body);
	font-weight: 500;
	font-size: var(--qi-small);
	line-height: 1.6;
	color: var(--qi-ink-muted);
}

.qi-contact-social-head {
	margin-top: 1.85rem !important;
	padding-top: 1.6rem;
	border-top: 1px solid rgba(11, 68, 68, .12);
	margin-bottom: 1rem !important;
}

.qi-contact-social {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	flex-wrap: wrap;
	gap: .6rem;
}

body.qi .qi-contact-social a {
	display: inline-flex;
	align-items: center;
	font-size: .875rem;
	font-weight: 600;
	letter-spacing: .01em;
	color: var(--qi-teal-800);
	text-decoration: none;
	padding: .5rem 1rem;
	border: 1px solid var(--qi-hairline-strong);
	border-radius: 999px;
	background: rgba(250, 247, 242, .55);
	transition: border-color .22s var(--qi-ease), color .22s var(--qi-ease),
		background-color .22s var(--qi-ease);
}

body.qi .qi-contact-social a:hover {
	border-color: var(--qi-teal-600);
	color: var(--qi-teal-600);
	background: var(--qi-white);
}

body.qi .qi-contact-figure {
	margin: clamp(1.25rem, 1rem + 1vw, 1.75rem) 0 0;
}

body.qi .qi-contact-figure img {
	display: block;
	width: 100%;
	height: auto;
	aspect-ratio: 4 / 3;
	object-fit: cover;
	border-radius: var(--qi-radius-lg);
}

/* --------------------------------------------------------------------------
   4. Fluent Forms skin
   Ivory inputs, hairline borders, teal focus, gold submit. Fluent Forms ships
   its own reset, so most rules need the .ff-el- specificity it uses plus the
   body.qi prefix.
   -------------------------------------------------------------------------- */

body.qi .fluentform .ff-el-group {
	margin-bottom: 1.5rem;
}

body.qi .fluentform .ff-el-input--label label {
	font-family: var(--qi-font-body);
	font-size: .8125rem;
	font-weight: 600;
	letter-spacing: .1em;
	text-transform: uppercase;
	color: var(--qi-ink-soft);
	margin-bottom: .5rem;
	line-height: 1.4;
}

body.qi .fluentform .ff-el-is-required.asterisk-right label:after,
body.qi .fluentform .ff-el-is-required.asterisk-left label:before {
	color: var(--qi-gold);
	font-weight: 600;
}

body.qi .fluentform .ff-el-form-control {
	width: 100%;
	font-family: var(--qi-font-body);
	font-size: 1rem;
	line-height: 1.5;
	color: var(--qi-ink);
	background-color: var(--qi-ivory);
	border: 1px solid var(--qi-hairline-strong);
	border-radius: var(--qi-radius-btn);
	padding: .9rem 1.05rem;
	min-height: 52px;
	box-shadow: none;
	transition: border-color .22s var(--qi-ease), background-color .22s var(--qi-ease),
		box-shadow .22s var(--qi-ease);
}

body.qi .fluentform textarea.ff-el-form-control {
	min-height: 148px;
	resize: vertical;
}

body.qi .fluentform .ff-el-form-control::placeholder {
	color: var(--qi-ink-soft);
	opacity: .78;
}

body.qi .fluentform .ff-el-form-control:hover {
	border-color: rgba(11, 68, 68, .34);
}

body.qi .fluentform .ff-el-form-control:focus,
body.qi .fluentform .ff-el-form-control:focus-visible {
	outline: none;
	background-color: var(--qi-white);
	border-color: var(--qi-teal-600);
	box-shadow: 0 0 0 3px rgba(17, 100, 102, .14);
}

/* Native select arrow, drawn in gold. */
body.qi .fluentform select.ff-el-form-control {
	appearance: none;
	-webkit-appearance: none;
	padding-right: 2.75rem;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none' stroke='%23C6A15B' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m3.5 6 4.5 4.5L12.5 6'/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: right 1.05rem center;
	background-size: 16px 16px;
}

/* Consent checkbox ---------------------------------------------------------- */

body.qi .fluentform .qi-consent {
	background: var(--qi-tint);
	border-radius: var(--qi-radius);
	padding: 1.1rem 1.25rem;
}

body.qi .fluentform .ff-el-form-check {
	margin-bottom: 0;
}

body.qi .fluentform .ff-el-form-check-label {
	display: flex;
	align-items: flex-start;
	gap: .7rem;
	font-size: var(--qi-small);
	line-height: 1.55;
	color: var(--qi-ink-muted);
	cursor: pointer;
}

body.qi .fluentform .ff-el-form-check-label input[type="checkbox"],
body.qi .fluentform .ff-el-form-check input[type="checkbox"],
body.qi .fluentform .ff-el-form-check input[type="radio"] {
	flex: 0 0 auto;
	width: 18px;
	height: 18px;
	margin: .18em 0 0;
	accent-color: var(--qi-teal-600);
	cursor: pointer;
}

body.qi .fluentform .qi-consent .ff-el-input--label {
	display: none;
}

/* Submit button ------------------------------------------------------------- */

body.qi .fluentform .ff-btn-submit,
body.qi .fluentform .ff-btn.ff-btn-submit {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	font-family: var(--qi-font-body);
	font-size: .9375rem;
	font-weight: 600;
	letter-spacing: .01em;
	line-height: 1;
	min-height: 52px;
	padding: 1.05rem 2.1rem;
	border-radius: var(--qi-radius-btn);
	border: 1px solid var(--qi-gold);
	background-color: var(--qi-gold);
	color: #16181A;
	box-shadow: none;
	text-transform: none;
	transition: background-color .25s var(--qi-ease), border-color .25s var(--qi-ease),
		transform .25s var(--qi-ease);
}

body.qi .fluentform .ff-btn-submit:hover,
body.qi .fluentform .ff-btn-submit:focus-visible {
	background-color: #B8914A;
	border-color: #B8914A;
	color: #16181A;
	transform: translateY(-1px);
}

body.qi .fluentform .ff-el-group.ff_submit_btn_wrapper {
	margin-top: 2rem;
	margin-bottom: 0;
}

/* Validation & messages ------------------------------------------------------ */

body.qi .fluentform .ff-el-is-error .ff-el-form-control {
	border-color: #B3453B;
	background-color: #FDF6F4;
}

body.qi .fluentform .error.text-danger,
body.qi .fluentform .ff-el-is-error .error {
	font-size: .8125rem;
	font-weight: 500;
	color: #A63B31;
	margin-top: .45rem;
}

body.qi .ff-message-success,
body.qi .fluentform .ff-message-success {
	background: var(--qi-tint);
	border: 1px solid rgba(17, 100, 102, .22);
	border-left: 3px solid var(--qi-gold);
	border-radius: var(--qi-radius);
	padding: 1.35rem 1.5rem;
	color: var(--qi-teal-800);
	font-size: var(--qi-body);
}

body.qi .ff-errors-in-stack,
body.qi .fluentform .ff-errors-in-stack {
	background: #FDF6F4;
	border: 1px solid rgba(179, 69, 59, .3);
	border-radius: var(--qi-radius);
	padding: 1rem 1.25rem;
	color: #A63B31;
	font-size: var(--qi-small);
	margin-bottom: 1.25rem;
}

body.qi .fluentform .ff-el-help-message {
	font-size: .8125rem;
	color: var(--qi-ink-soft);
	margin-top: .4rem;
}

/* --------------------------------------------------------------------------
   5. Small screens
   -------------------------------------------------------------------------- */

@media (max-width: 899px) {
	body.qi .qi-contact-split > .wp-block-column {
		flex-basis: 100% !important;
	}
}

@media (max-width: 599px) {
	body.qi .fluentform .ff-btn-submit,
	body.qi .fluentform .ff-btn.ff-btn-submit {
		width: 100%;
	}

	.qi-timeline-item {
		padding-left: 1.5rem;
	}
}

/* --------------------------------------------------------------------------
   Mobile pass — about / contact
   These selectors are defined in this file, which is enqueued after
   qi-design.css, so the global mobile band in §10 there cannot reach them at
   equal specificity. The reading floors and touch sizing are repeated here.
   -------------------------------------------------------------------------- */

@media (max-width: 782px), (max-height: 500px) and (pointer: coarse) {
	body.qi .qi-contact-social a {
		font-size: 1rem;
		min-height: 44px;
	}

	body.qi .fluentform .ff-el-input--label label {
		font-size: .875rem;
		letter-spacing: .08em;
	}

	body.qi .fluentform .ff-btn-submit,
	body.qi .fluentform .ff-btn.ff-btn-submit {
		font-size: 1rem;
	}

	body.qi .fluentform .error.text-danger,
	body.qi .fluentform .ff-el-is-error .error,
	body.qi .fluentform .ff-el-help-message {
		font-size: .9375rem;
	}
}

@media (max-width: 782px), (pointer: coarse) {
	/* Fluent Forms renders the consent box as .ff-el-form-check-input, not the
	   bare [type=checkbox] the global rule targets. */
	body.qi .fluentform input.ff-el-form-check-input,
	body.qi .fluentform input.ff-el-form-check-checkbox,
	body.qi .fluentform .ff-el-form-check-label input[type="checkbox"] {
		width: 22px;
		height: 22px;
	}

	body.qi .fluentform .ff-el-form-check-label {
		min-height: 44px;
		align-items: center;
	}

	body.qi a.qi-contact-value {
		padding-block: .7rem;
	}
}

@media (max-width: 560px) {
	/* Submit spans the card on the narrowest band. */
	body.qi .fluentform .ff-btn-submit,
	body.qi .fluentform .ff-btn.ff-btn-submit {
		width: 100%;
	}
}
