/**
 * Inner pages: page hero, product catalogue, machinery, callouts, prose.
 * Tokens come from style.css.
 */

/* =========================================================================
   PAGE HERO
   ========================================================================= */

.kf-page-hero {
	position: relative;
	display: flex;
	align-items: center;
	min-height: clamp(300px, 40vh, 420px);
	background: var(--kf-black);
	overflow: hidden;
}

.kf-page-hero__media { position: absolute; inset: 0; }

.kf-page-hero__media img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

.kf-page-hero__media::after {
	content: "";
	position: absolute;
	inset: 0;
	background: linear-gradient(
		100deg,
		rgba(0, 0, 0, 0.92) 0%,
		rgba(0, 0, 0, 0.74) 42%,
		rgba(0, 0, 0, 0.34) 78%,
		rgba(0, 0, 0, 0.5) 100%
	);
}

.kf-page-hero__inner {
	position: relative;
	z-index: 1;
	color: #fff;
	padding-block: 48px;
	width: 100%;
}

.kf-crumbs {
	display: flex;
	align-items: center;
	gap: 9px;
	font-size: 12.5px;
	letter-spacing: 0.06em;
	text-transform: uppercase;
	margin-bottom: 16px;
	color: rgba(255, 255, 255, 0.65);
}

.kf-crumbs a { color: var(--kf-gold); text-decoration: none; }
.kf-crumbs a:hover { text-decoration: underline; }
.kf-crumbs__sep { color: rgba(255, 255, 255, 0.4); }

.kf-page-hero__eyebrow {
	color: var(--kf-gold);
	font-size: 13px;
	font-weight: 700;
	letter-spacing: 0.14em;
	text-transform: uppercase;
	margin: 0 0 8px;
}

.kf-page-hero__title {
	font-size: clamp(30px, 4.6vw, 52px);
	font-weight: 800;
	line-height: 1.08;
	text-transform: uppercase;
	margin: 0 0 14px;
	color: #fff;
	max-width: 20ch;
}

.kf-page-hero__text {
	font-size: clamp(14px, 1.5vw, 16px);
	line-height: 1.7;
	max-width: 46ch;
	margin: 0 0 24px;
	color: rgba(255, 255, 255, 0.86);
}

/* =========================================================================
   FILTER BAR
   ========================================================================= */

.kf-filter {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	margin-bottom: 34px;
}

.kf-filter__btn {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	padding: 11px 18px;
	background: transparent;
	border: 1px solid var(--kf-border);
	border-radius: var(--kf-radius);
	color: #d6d6d6;
	font-size: 12.5px;
	font-weight: 700;
	letter-spacing: 0.05em;
	text-transform: uppercase;
	cursor: pointer;
	transition: border-color var(--kf-transition), color var(--kf-transition), background var(--kf-transition);
}

.kf-filter__btn .kf-icon { width: 15px; height: 15px; }

.kf-filter__btn:hover { border-color: var(--kf-gold); color: var(--kf-gold); }

.kf-filter__btn.is-active {
	border-color: var(--kf-gold);
	color: var(--kf-gold);
	background: rgba(240, 165, 0, 0.1);
}

/* =========================================================================
   CATALOGUE
   ========================================================================= */

.kf-catalogue__grid {
	display: grid;
	grid-template-columns: repeat(4, 1fr);
	gap: 20px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.kf-cat-card {
	display: flex;
	flex-direction: column;
	background: var(--kf-surface);
	border: 1px solid var(--kf-border);
	border-radius: var(--kf-radius);
	overflow: hidden;
	transition: border-color var(--kf-transition), transform var(--kf-transition);
}

.kf-cat-card:hover { border-color: var(--kf-gold); transform: translateY(-4px); }

.kf-cat-card__media { aspect-ratio: 4 / 3; overflow: hidden; }

.kf-cat-card__media img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
	transition: transform 0.45s ease;
}

.kf-cat-card:hover .kf-cat-card__media img { transform: scale(1.06); }

.kf-cat-card__body { padding: 18px 18px 22px; }

.kf-cat-card__title {
	margin: 0 0 8px;
	color: #fff;
	font-size: 15px;
	font-weight: 700;
	letter-spacing: 0.03em;
	text-transform: uppercase;
	line-height: 1.3;
}

.kf-cat-card__desc {
	margin: 0;
	color: var(--kf-text-muted-dark);
	font-size: 13.5px;
	line-height: 1.6;
}

.kf-catalogue__empty {
	text-align: center;
	color: var(--kf-text-muted-dark);
	padding: 40px 0;
	margin: 0;
}

/* =========================================================================
   MACHINERY PAGE
   ========================================================================= */

.kf-machinery__grid--page { grid-template-columns: repeat(5, 1fr); }

/* =========================================================================
   CALLOUT
   ========================================================================= */

.kf-callout {
	display: flex;
	align-items: center;
	gap: 22px;
	margin-top: 46px;
	padding: 26px 28px;
	background: var(--kf-surface);
	border: 1px solid var(--kf-border);
	border-radius: var(--kf-radius);
	flex-wrap: wrap;
}

.kf-callout--spaced { margin-top: 54px; }

.kf-callout__icon {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 52px;
	height: 52px;
	flex: none;
	border-radius: 50%;
	border: 1px solid var(--kf-gold);
	color: var(--kf-gold);
}

.kf-callout__icon .kf-icon { width: 24px; height: 24px; }

.kf-callout__body { flex: 1 1 320px; }

.kf-callout__title {
	margin: 0 0 5px;
	color: #fff;
	font-size: 17px;
	font-weight: 700;
	letter-spacing: 0.03em;
	text-transform: uppercase;
}

.kf-callout__text { margin: 0; font-size: 14px; color: var(--kf-text-muted-dark); }
.kf-callout__cta { flex: none; }

/* =========================================================================
   SELLING POINTS
   ========================================================================= */

.kf-usps { background: #0a0a0a; border-top: 1px solid var(--kf-border); }

.kf-usps__grid {
	display: grid;
	grid-template-columns: repeat(4, 1fr);
	gap: 30px;
	padding-block: 46px;
}

.kf-usp { display: flex; gap: 15px; align-items: flex-start; }

.kf-usp__icon {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 46px;
	height: 46px;
	flex: none;
	border-radius: 50%;
	border: 1px solid rgba(240, 165, 0, 0.45);
	color: var(--kf-gold);
}

.kf-usp__icon .kf-icon { width: 21px; height: 21px; }

.kf-usp__title {
	margin: 0 0 6px;
	color: #fff;
	font-size: 13.5px;
	font-weight: 700;
	letter-spacing: 0.05em;
	text-transform: uppercase;
}

.kf-usp__text {
	margin: 0;
	color: var(--kf-text-muted-dark);
	font-size: 13px;
	line-height: 1.6;
}

/* =========================================================================
   PAGE BODY (client-authored content)
   ========================================================================= */

.kf-prose { max-width: 860px; color: var(--kf-text-on-light); }

.kf-prose h1,
.kf-prose h2,
.kf-prose h3 {
	color: var(--kf-text-on-light);
	font-weight: 800;
	text-transform: uppercase;
	letter-spacing: 0.01em;
	margin: 1.6em 0 0.6em;
}

.kf-prose h2 { font-size: 26px; }
.kf-prose h3 { font-size: 20px; }

.kf-prose p { line-height: 1.8; color: var(--kf-text-muted-light); margin: 0 0 1.2em; }
.kf-prose a { color: var(--kf-gold-deep); }

.kf-prose img { height: auto; border-radius: var(--kf-radius); }

.kf-prose figcaption {
	font-size: 13px;
	color: var(--kf-text-muted-light);
	text-align: center;
	margin-top: 8px;
}

/* =========================================================================
   RESPONSIVE
   ========================================================================= */

@media (max-width: 1100px) {
	.kf-catalogue__grid { grid-template-columns: repeat(3, 1fr); }
	.kf-machinery__grid--page { grid-template-columns: repeat(4, 1fr); }
	.kf-usps__grid { grid-template-columns: repeat(2, 1fr); gap: 26px; }
}

@media (max-width: 800px) {
	.kf-catalogue__grid { grid-template-columns: repeat(2, 1fr); }
	.kf-machinery__grid--page { grid-template-columns: repeat(3, 1fr); }
	.kf-callout { flex-direction: column; align-items: flex-start; }
	.kf-callout__cta { width: 100%; justify-content: center; }
}

@media (max-width: 560px) {
	.kf-machinery__grid--page { grid-template-columns: repeat(2, 1fr); }
	.kf-usps__grid { grid-template-columns: 1fr; }
	.kf-filter__btn { flex: 1 1 auto; justify-content: center; }
}

@media (prefers-reduced-motion: reduce) {
	.kf-cat-card,
	.kf-cat-card__media img,
	.kf-filter__btn { transition: none; }

	.kf-cat-card:hover { transform: none; }
	.kf-cat-card:hover .kf-cat-card__media img { transform: none; }
}

/* =========================================================================
   TEAM PAGE
   ========================================================================= */

.kf-leader__grid {
	display: grid;
	grid-template-columns: 0.85fr 1.15fr;
	gap: 48px;
	align-items: center;
}

.kf-leader__media {
	border-radius: var(--kf-radius);
	overflow: hidden;
	background: var(--kf-black);
}

.kf-leader__media img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
	aspect-ratio: 3 / 4;
}

.kf-leader__name {
	font-size: clamp(26px, 3.2vw, 38px);
	font-weight: 800;
	line-height: 1.15;
	margin: 0 0 18px;
	color: var(--kf-text-on-light);
}

/* Short amber rule under the name, as in the mockup. */
.kf-leader__name::after {
	content: "";
	display: block;
	width: 54px;
	height: 3px;
	background: var(--kf-gold);
	margin-top: 16px;
	border-radius: 2px;
}

.kf-leader__text {
	font-size: 15px;
	line-height: 1.8;
	color: var(--kf-text-muted-light);
	margin: 0 0 26px;
	max-width: 52ch;
}

/* Featured leader gets labelled links; the grid below uses icon-only. */
.kf-leader__links {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.kf-leader__link {
	display: inline-flex;
	align-items: center;
	gap: 9px;
	padding: 10px 16px;
	border: 1px solid #dcdcdc;
	border-radius: var(--kf-radius);
	color: var(--kf-text-on-light);
	font-size: 13px;
	font-weight: 600;
	text-decoration: none;
	transition: background var(--kf-transition), color var(--kf-transition),
		border-color var(--kf-transition), transform var(--kf-transition);
}

.kf-leader__link .kf-icon { width: 17px; height: 17px; }
.kf-leader__link:hover { transform: translateY(-2px); border-color: transparent; color: #fff; }
.kf-leader__link.kf-member__link--mail:hover { background: var(--kf-gold); color: #101010; }

.kf-team-page__grid {
	display: grid;
	grid-template-columns: repeat(4, 1fr);
	gap: 22px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.kf-person {
	background: var(--kf-surface);
	border: 1px solid var(--kf-border);
	border-radius: var(--kf-radius);
	overflow: hidden;
	transition: border-color var(--kf-transition), transform var(--kf-transition);
}

.kf-person:hover { border-color: var(--kf-gold); transform: translateY(-4px); }

.kf-person__media { aspect-ratio: 1 / 1; overflow: hidden; }

.kf-person__media img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	object-position: center top;
	display: block;
}

.kf-person__body { padding: 18px 18px 22px; }

.kf-person__name {
	margin: 0;
	color: #fff;
	font-size: 15px;
	font-weight: 700;
	letter-spacing: 0.03em;
	text-transform: uppercase;
	line-height: 1.3;
}

.kf-person__role {
	margin: 7px 0 0;
	color: var(--kf-gold);
	font-size: 13px;
	line-height: 1.45;
}

.kf-person__note {
	margin: 9px 0 0;
	color: #8a8a8a;
	font-size: 11.5px;
	line-height: 1.5;
	font-style: italic;
}

/* =========================================================================
   ABOUT PAGE
   ========================================================================= */

.kf-story__grid {
	display: grid;
	grid-template-columns: 1.05fr 0.95fr;
	gap: 52px;
	align-items: center;
}

.kf-story__text p {
	font-size: 15px;
	line-height: 1.85;
	color: var(--kf-text-muted-light);
	margin: 0 0 18px;
	max-width: 56ch;
}

.kf-story__actions { margin-top: 26px; }

.kf-story__media {
	border-radius: var(--kf-radius);
	overflow: hidden;
}

.kf-story__media img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
	aspect-ratio: 4 / 3;
}

/* The stats band also appears on the homepage; on inner pages it needs its
   own top border since it does not follow a hero there. */
.kf-stats--page { border-top: 0; }

.kf-values__grid {
	display: grid;
	grid-template-columns: repeat(4, 1fr);
	gap: 22px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.kf-value {
	background: var(--kf-surface);
	border: 1px solid var(--kf-border);
	border-radius: var(--kf-radius);
	padding: 28px 24px;
	text-align: center;
	transition: border-color var(--kf-transition), transform var(--kf-transition);
}

.kf-value:hover { border-color: var(--kf-gold); transform: translateY(-4px); }

.kf-value__icon {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 54px;
	height: 54px;
	margin: 0 auto 16px;
	border-radius: 50%;
	border: 1px solid rgba(240, 165, 0, 0.45);
	color: var(--kf-gold);
}

.kf-value__icon .kf-icon { width: 24px; height: 24px; }

.kf-value__title {
	margin: 0 0 9px;
	color: #fff;
	font-size: 14px;
	font-weight: 700;
	letter-spacing: 0.04em;
	text-transform: uppercase;
	line-height: 1.35;
}

.kf-value__text {
	margin: 0;
	color: var(--kf-text-muted-dark);
	font-size: 13px;
	line-height: 1.65;
}

/* =========================================================================
   RESPONSIVE
   ========================================================================= */

@media (max-width: 1000px) {
	.kf-team-page__grid { grid-template-columns: repeat(2, 1fr); }
	.kf-values__grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 860px) {
	.kf-leader__grid,
	.kf-story__grid { grid-template-columns: 1fr; gap: 32px; }

	.kf-leader__media img { aspect-ratio: 4 / 3; }
}

@media (max-width: 560px) {
	.kf-team-page__grid { grid-template-columns: 1fr; }
	.kf-values__grid { grid-template-columns: 1fr; }
	.kf-leader__link { flex: 1 1 auto; justify-content: center; }
}

@media (prefers-reduced-motion: reduce) {
	.kf-person,
	.kf-value,
	.kf-leader__link { transition: none; }

	.kf-person:hover,
	.kf-value:hover,
	.kf-leader__link:hover { transform: none; }
}

/* =========================================================================
   CONTACT PAGE
   ========================================================================= */

.kf-contact__grid {
	display: grid;
	grid-template-columns: 0.85fr 1.15fr;
	gap: 32px;
	align-items: start;
}

.kf-contact__panel {
	background: var(--kf-surface);
	border: 1px solid var(--kf-border);
	border-radius: var(--kf-radius);
	padding: 30px 28px;
}

.kf-contact__list { margin: 0; padding: 0; list-style: none; }

.kf-contact__item {
	display: flex;
	gap: 16px;
	padding-block: 18px;
	border-bottom: 1px solid rgba(255, 255, 255, 0.07);
}

.kf-contact__item:first-child { padding-top: 0; }
.kf-contact__item:last-child { border-bottom: 0; padding-bottom: 0; }

.kf-contact__icon {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 42px;
	height: 42px;
	flex: none;
	border-radius: 50%;
	border: 1px solid rgba(240, 165, 0, 0.4);
	color: var(--kf-gold);
}

.kf-contact__icon .kf-icon { width: 19px; height: 19px; }

.kf-contact__label {
	margin: 0 0 5px;
	color: var(--kf-gold);
	font-size: 11.5px;
	font-weight: 700;
	letter-spacing: 0.13em;
	text-transform: uppercase;
}

.kf-contact__value {
	margin: 0;
	color: #fff;
	font-size: 14.5px;
	line-height: 1.65;
}

.kf-contact__value a { color: inherit; text-decoration: none; }
.kf-contact__value a:hover { color: var(--kf-gold); }

.kf-contact__sub {
	margin: 4px 0 0;
	color: var(--kf-text-muted-dark);
	font-size: 13px;
}

.kf-contact__directions { width: 100%; justify-content: center; margin-top: 26px; }

.kf-contact__map {
	border-radius: var(--kf-radius);
	overflow: hidden;
	border: 1px solid var(--kf-border);
	background: var(--kf-surface);
	min-height: 460px;
	display: flex;
}

.kf-contact__map iframe {
	width: 100%;
	height: 100%;
	min-height: 460px;
	border: 0;
	display: block;
}

/* =========================================================================
   GALLERY
   ========================================================================= */

.kf-gallery__grid {
	display: grid;
	grid-template-columns: repeat(4, 1fr);
	gap: 14px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.kf-gallery__item { border-radius: var(--kf-radius); overflow: hidden; }

.kf-gallery__btn {
	display: block;
	width: 100%;
	padding: 0;
	border: 0;
	background: var(--kf-surface);
	cursor: pointer;
	aspect-ratio: 4 / 3;
	overflow: hidden;
}

.kf-gallery__btn img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
	transition: transform 0.45s ease, opacity var(--kf-transition);
}

.kf-gallery__btn:hover img { transform: scale(1.07); opacity: 0.88; }

/* =========================================================================
   LIGHTBOX
   ========================================================================= */

/* [hidden] must beat display:flex below, or the lightbox sits open over the
   grid permanently and the close button cannot dismiss it. */
.kf-lightbox[hidden] { display: none; }

.kf-lightbox {
	position: fixed;
	inset: 0;
	z-index: 900;
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 12px;
	padding: 5vh 5vw;
	background: rgba(0, 0, 0, 0.93);
}

.kf-lightbox__img {
	max-width: 100%;
	max-height: 90vh;
	object-fit: contain;
	display: block;
	border-radius: var(--kf-radius);
}

.kf-lightbox__close,
.kf-lightbox__nav {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	border: 1px solid rgba(255, 255, 255, 0.25);
	background: rgba(0, 0, 0, 0.5);
	color: #fff;
	cursor: pointer;
	border-radius: 50%;
	transition: background var(--kf-transition), border-color var(--kf-transition);
}

.kf-lightbox__close:hover,
.kf-lightbox__nav:hover { background: var(--kf-gold); color: #101010; border-color: var(--kf-gold); }

.kf-lightbox__close {
	position: absolute;
	top: 18px;
	inset-inline-end: 18px;
	width: 44px;
	height: 44px;
}

.kf-lightbox__nav {
	width: 48px;
	height: 48px;
	flex: none;
	font-size: 30px;
	line-height: 1;
}

/* Locking the body prevents the page scrolling behind the overlay. */
.kf-lightbox-open { overflow: hidden; }

/* =========================================================================
   RTL
   The site publishes English and Central Kurdish (ckb), which is RTL. Layout
   uses logical properties throughout, so only genuinely directional things
   need mirroring here.
   ========================================================================= */

[dir="rtl"] .kf-lightbox__nav--prev { order: 3; }
[dir="rtl"] .kf-lightbox__nav--next { order: 1; }
[dir="rtl"] .kf-lightbox__img { order: 2; }

/* The chevron and arrow glyphs are drawn pointing right. */
[dir="rtl"] .kf-lightbox__nav span[aria-hidden] { display: inline-block; transform: scaleX(-1); }
[dir="rtl"] .kf-crumbs__sep { transform: scaleX(-1); }

/* The hero scrim is a directional gradient: flip it so the dark end stays
   behind the text when the text moves to the right. */
[dir="rtl"] .kf-hero__media::after,
[dir="rtl"] .kf-page-hero__media::after { transform: scaleX(-1); }

[dir="rtl"] .kf-about__point::before { inset-inline-start: 0; }

/* =========================================================================
   RESPONSIVE
   ========================================================================= */

@media (max-width: 1000px) {
	.kf-contact__grid { grid-template-columns: 1fr; }
	.kf-contact__map { min-height: 380px; }
	.kf-contact__map iframe { min-height: 380px; }
	.kf-gallery__grid { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 600px) {
	.kf-gallery__grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
	.kf-contact__panel { padding: 22px 18px; }

	.kf-lightbox { padding: 3vh 3vw; gap: 6px; }
	.kf-lightbox__nav { width: 38px; height: 38px; font-size: 24px; }
}

@media (prefers-reduced-motion: reduce) {
	.kf-gallery__btn img,
	.kf-lightbox__close,
	.kf-lightbox__nav { transition: none; }

	.kf-gallery__btn:hover img { transform: none; }
}
