/* Shared header uses one row and switches to a menu before its links can collide. */
.header .wrap {
	height: auto;
	min-height: 84px;
	gap: 18px;
	position: relative;
	flex-wrap: nowrap;
}
.header .brand {
	min-width: 0;
	flex: 0 0 auto;
	gap: 10px;
}
.header .brand-name {
	font-size: 19px;
	max-width: none;
	white-space: nowrap;
}
.header .brand img {
	width: 56px;
	height: 60px;
	flex-shrink: 0;
}
.header #main-navigation {
	position: static;
	display: flex;
	flex-direction: row;
	gap: 19px;
	padding: 0;
	box-shadow: none;
	background: none;
	margin-inline: auto;
	align-items: center;
	font-size: 13px;
	white-space: nowrap;
}
.header #main-navigation a {
	padding-block: 12px;
}
.header .language-switch {
	order: initial;
	margin: 0;
	min-height: 42px;
	flex-shrink: 0;
}
.header .header-cta {
	padding: 11px 15px;
	font-size: 13px;
	flex-shrink: 0;
}
.header .menu {
	display: none;
	margin: 0;
	order: initial;
	min-width: 44px;
	min-height: 44px;
	padding: 0;
	flex-shrink: 0;
	line-height: 1;
}

/* Grid children and long bilingual text must be allowed to shrink at every width. */
main,
.wrap,
article,
aside,
figure,
section,
form {
	min-width: 0;
}
.wrap > *,
.form-grid > *,
.official-heading > * {
	min-width: 0;
}
h1,
h2,
h3,
p,
li,
figcaption {
	overflow-wrap: break-word;
}
.breadcrumbs {
	flex-wrap: wrap;
	line-height: 1.6;
}
.btn {
	max-width: 100%;
	white-space: normal;
	text-align: center;
}
#services {
	scroll-margin-top: 100px;
}
.official-page .gallery-pagination {
	position: static;
	inset: auto;
	box-shadow: none;
	background: none;
	padding: 0;
	flex-direction: row;
	width: auto;
	max-width: 100%;
}
.official-page .table-search input {
	max-width: 100%;
}
.official-page .official-detail-aside {
	top: 104px;
}

/* Equal article cards replace the two poster images on the home and blog pages. */
.article-grid {
	grid-template-columns: repeat(2, minmax(0, 1fr));
	align-items: stretch;
}
.article-card {
	display: flex;
	flex-direction: column;
	background: white;
	border: 1px solid var(--line);
	border-radius: 12px;
	overflow: hidden;
	box-shadow: 0 14px 36px #082d540d;
}
.article-photo {
	display: block;
	overflow: hidden;
	background: #e5eef5;
}
.article-grid .article-photo img {
	width: 100%;
	height: 275px;
	object-fit: cover;
	transition: transform 0.4s;
}
.article-card:hover .article-photo img {
	transform: scale(1.035);
}
.article-copy {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	flex: 1;
	padding: 29px;
}
.article-copy h3 {
	font-size: 25px;
	color: var(--navy);
	line-height: 1.4;
	margin: 3px 0 15px;
}
.article-copy p {
	color: var(--muted);
	font-size: 15px;
	margin: 0 0 25px;
}
.article-copy .official-text-link {
	margin-top: auto;
	border-top: 1px solid var(--line);
	padding-top: 17px;
	width: 100%;
	display: flex;
	justify-content: space-between;
	gap: 16px;
	color: #467fb1;
	font-weight: 700;
	font-size: 13px;
}

/* Published projects retain their actual records in a more legible two-column register. */
.project-overview {
	display: grid;
	grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr);
	align-items: center;
	gap: 55px;
	margin-bottom: 60px;
}
.project-overview h2 {
	font-size: clamp(28px, 3vw, 42px);
	line-height: 1.3;
	color: var(--navy);
	margin: 0 0 20px;
}
.project-overview p {
	color: var(--muted);
	margin: 0;
	font-size: 16px;
}
.project-overview > img {
	width: 100%;
	height: 340px;
	object-fit: cover;
	border-radius: 12px;
}
.project-metrics {
	display: flex;
	gap: 35px;
	margin-top: 27px;
}
.project-metrics > div {
	border-inline-start: 3px solid var(--blue);
	padding-inline-start: 17px;
	flex: 1;
}
.project-metrics strong {
	display: block;
	font-size: 36px;
	line-height: 1.25;
	color: var(--navy);
}
.project-metrics span {
	font-size: 12px;
	color: var(--muted);
}
.project-register {
	border: 1px solid var(--line);
	border-radius: 12px;
	overflow: hidden;
	background: white;
	box-shadow: 0 15px 40px #06275a06;
}
.project-register > .official-heading {
	padding: 30px;
	margin: 0;
	border-bottom: 1px solid var(--line);
	align-items: center;
}
.official-page .project-register h2 {
	font-size: 28px;
}
.official-page .project-register .table-scroll {
	border: 0;
	border-radius: 0;
	box-shadow: none;
}
.official-page .project-register-table {
	min-width: 0;
	width: 100%;
	table-layout: fixed;
}
.official-page .project-register-table th:first-child {
	width: 130px;
}
.official-page .project-register-table th:last-child {
	width: auto;
}
.official-page .project-register-table th,
.official-page .project-register-table td {
	text-align: start;
	padding: 17px 30px;
	vertical-align: middle;
}
.official-page .project-register-table th {
	background: var(--navy);
	color: white;
}
.official-page .project-register-table th button {
	color: inherit;
	width: 100%;
	justify-content: space-between;
}
.official-page .project-register-table tbody tr:nth-child(even) {
	background: #f6f9fc;
}
.official-page .project-register-table tbody tr:hover {
	background: #eaf2f8;
}
.project-number {
	display: inline-grid;
	place-items: center;
	min-width: 42px;
	height: 36px;
	font-weight: 700;
	font-size: 13px;
	background: white;
	border: 1px solid var(--line);
	border-radius: 7px;
	color: var(--navy);
}
.scope-badge {
	display: inline-flex;
	align-items: center;
	gap: 12px;
	font-weight: 700;
	font-size: 14px;
	color: var(--navy);
	line-height: 1.6;
}
.scope-dot {
	width: 7px;
	height: 7px;
	border-radius: 50%;
	background: #5e9bc9;
	flex-shrink: 0;
}
.scope-unlisted {
	font-size: 13px;
	color: var(--muted);
}
.project-register > .table-empty {
	padding: 25px;
	margin: 0;
}

/* Tablet navigation opens beneath a stable logo, language switch and touch control. */
@media (max-width: 1199px) {
	.header .wrap {
		min-height: 76px;
		gap: 14px;
	}
	.header .brand-name {
		font-size: 19px;
		max-width: 230px;
	}
	.header .language-switch {
		margin-inline-start: auto;
	}
	.header .header-cta {
		display: none;
	}
	.header .menu {
		display: block;
	}
	.header #main-navigation {
		display: none;
		position: absolute;
		inset-inline: 0;
		top: 100%;
		margin: 0;
		flex-direction: column;
		align-items: stretch;
		gap: 0;
		background: white;
		border: 1px solid var(--line);
		border-radius: 0 0 10px 10px;
		box-shadow: 0 15px 25px #06275a16;
		padding: 10px 18px;
		max-height: calc(100dvh - 90px);
		overflow: auto;
		white-space: normal;
	}
	.header #main-navigation.open {
		display: flex;
	}
	.header #main-navigation a {
		padding: 12px 5px;
		border-bottom: 1px solid #d9e4ed80;
	}
	.header #main-navigation a:last-child {
		border: 0;
	}
}
@media (max-width: 850px) {
	.project-overview {
		gap: 30px;
		grid-template-columns: 1fr;
		margin-bottom: 35px;
	}
	.project-overview > img {
		height: 300px;
	}
	.project-overview > div {
		max-width: 650px;
	}
	.article-grid .article-photo img {
		height: 225px;
	}
	.article-copy {
		padding: 23px;
	}
	.article-copy h3 {
		font-size: 23px;
	}
	.official-page .official-detail-aside {
		position: static;
	}
	.section-head {
		align-items: flex-start;
		flex-wrap: wrap;
	}
	.official-page .contact-form-panel .form-grid input,
	.official-page .contact-form-panel .form-grid select,
	.official-page .contact-form-panel .form-grid textarea {
		font-size: 16px;
	}
}
@media (max-width: 600px) {
	.article-grid {
		grid-template-columns: 1fr;
	}
	.article-grid .article-photo img {
		height: 240px;
	}
	.header .wrap {
		min-height: 72px;
		gap: 10px;
	}
	.header .brand {
		gap: 8px;
	}
	.header .brand-name {
		font-size: 16px;
		max-width: 145px;
		white-space: normal;
	}
	.header .brand-name small {
		font-size: 10px;
		letter-spacing: 0.02em;
	}
	.header .brand img {
		width: 44px;
		height: 50px;
	}
	.header .language-switch {
		padding: 6px 8px;
		font-size: 12px;
	}
	.header .menu {
		font-size: 25px;
		min-width: 40px;
	}
	.project-metrics {
		gap: 20px;
	}
	.project-overview > img {
		height: 240px;
	}
	.project-register > .official-heading {
		padding: 23px;
	}
	.project-register > .official-heading .table-search {
		margin-top: 18px;
	}
	.official-page .project-register-table {
		display: block;
	}
	.official-page .project-register-table thead {
		position: absolute;
		width: 1px;
		height: 1px;
		overflow: hidden;
		clip-path: inset(50%);
	}
	.official-page .project-register-table tbody {
		display: grid;
		gap: 12px;
		padding: 16px;
	}
	.official-page .project-register-table tr {
		display: grid;
		gap: 15px;
		border: 1px solid var(--line);
		padding: 18px;
		border-radius: 8px;
	}
	.official-page .project-register-table td {
		display: flex;
		align-items: flex-start;
		justify-content: space-between;
		gap: 14px;
		width: auto;
		padding: 0;
		border: 0;
	}
	.official-page .project-register-table td:before {
		content: attr(data-label);
		font-size: 12px;
		color: var(--muted);
		flex: 0 0 78px;
	}
	.official-page .project-register-table .scope-badge {
		font-size: 13px;
		justify-content: flex-end;
		text-align: end;
	}
	footer .wrap:not(.footer-links) {
		display: block;
	}
	footer .wrap span + span {
		display: block;
		margin-top: 7px;
	}
	.hero h1 {
		font-size: clamp(30px, 8.6vw, 39px);
	}
}
@media (max-width: 359px) {
	.header .wrap {
		gap: 6px;
	}
	.header .brand-name {
		font-size: 14px;
		max-width: 115px;
	}
	.header .brand img {
		width: 36px;
		height: 44px;
	}
	.header .brand-name small {
		font-size: 9px;
	}
	.header .language-switch {
		font-size: 11px;
		padding: 5px 6px;
	}
	.header .menu {
		min-width: 34px;
	}
	.phone-list a {
		font-size: 16px;
		padding: 12px;
	}
	.phone-list small {
		font-size: 11px;
	}
}
@media (prefers-reduced-motion: reduce) {
	.article-card * {
		transition: none !important;
	}
}

/* Keep the bot field visually hidden without creating an RTL overflow area. */
.contact-form {
	position: relative;
}
.contact-form .honeypot {
	left: auto;
	inset-inline-start: 0;
	top: 0;
	width: 1px;
	height: 1px;
	overflow: hidden;
	clip-path: inset(50%);
	white-space: nowrap;
}

/* Property-first AI concept gallery, with visible provenance labels. */
.official-page .property-concepts {
	grid-template-columns: repeat(2, minmax(0, 1fr));
}
.official-page .property-concepts img {
	height: 300px;
}
.property-concepts figcaption strong,
.property-concepts figcaption small {
	display: block;
}
.property-concepts figcaption small {
	font-size: 11px;
	font-weight: 400;
	margin-top: 4px;
	color: var(--muted);
}
.company-network p {
	color: var(--muted);
	font-size: 15px;
	margin: 0;
}
@media (max-width: 600px) {
	.official-page .property-concepts {
		grid-template-columns: 1fr;
	}
	.official-page .property-concepts img {
		height: 245px;
	}
}

/* Smaller, modern hero heading in both languages. */
html[lang="en"] .hero h1,
html[lang="ar"] .hero h1 {
	font-size: clamp(28px, 3.5vw, 48px);
	font-weight: 600;
	margin-block: 18px 24px;
}

html[lang="en"] .hero h1 {
	font-family: "Inter", Arial, sans-serif;
	line-height: 1.3;
	letter-spacing: -0.025em;
}

html[lang="ar"] .hero h1 {
	font-family: "Tajawal", Tahoma, sans-serif;
	line-height: 1.6;
	letter-spacing: 0;
}

/* Compact heading on mobile devices. */
@media (max-width: 600px) {
	html[lang="en"] .hero h1,
	html[lang="ar"] .hero h1 {
		font-size: 28px;
	}
}
