/*
 * Ekhaa 2026 — the sector layer.
 *
 * Loaded last. Everything here comes from looking at what this sector actually
 * does, not from taste:
 *
 *   ehsan.sa (منصة إحسان)      — the national platform, 5th of 39 government
 *                                 platforms for digital experience maturity.
 *                                 Light base, photo-led cards, repeated
 *                                 high-contrast call to action, impact numbers.
 *   ensan.org.sa (جمعية إنسان) — the closest peer, Saudi orphan care. Light
 *                                 green base, beneficiary photographs framed in
 *                                 ARCHES, an official quotation block with a
 *                                 portrait, assistant in the corner.
 *   sos-childrensvillages.org  — the global benchmark. Its headline is a
 *                                 promise about the child, not a line about
 *                                 the organisation.
 *
 * The earlier dark, typographic treatment read as an agency portfolio. Every
 * reference in this sector is light, warm and led by faces.
 */

/* ==========================================================================
   1. Light base
   Navy stops being the ground and becomes the ink.
   ========================================================================== */

body { background: #fdfbf6; }

/* The hero is now light. The photograph carries the warmth instead of a scrim. */
.ekhaa-hero {
	background: linear-gradient(180deg, #fbf4e6 0%, #fdfbf6 100%);
	color: var(--ink);
	min-height: auto;
	padding-block: clamp(3rem, 7vw, 5.5rem) clamp(3.5rem, 8vw, 6rem);
}

.ekhaa-hero .ekhaa-stage { display: none; }
.ekhaa-hero::before,
.ekhaa-hero::after { display: none; }
.ekhaa-hero .mashrabiya { opacity: .07; }

.ekhaa-hero h1 {
	color: var(--ink);
	text-shadow: none;
	font-size: clamp(2.5rem, 6.4vw, 5rem);
	max-width: 15ch;
}

.ekhaa-hero h1 em {
	-webkit-text-fill-color: var(--clay-deep);
	color: var(--clay-deep);
	background: none;
	animation: none;
}

.ekhaa-hero__lede { color: var(--muted); text-shadow: none; }
.ekhaa-hero .ekhaa-eyebrow { color: var(--clay-deep); }

.ekhaa-hero__inner {
	display: grid;
	gap: clamp(2rem, 5vw, 4rem);
	align-items: center;
}

@media (min-width: 1000px) {
	.ekhaa-hero__inner { grid-template-columns: 1.05fr .95fr; }
}

.ekhaa-scroll { display: none; }

/* ==========================================================================
   2. The arch
   Taken from ensan.org.sa, where every beneficiary photograph sits in one.
   It is the oldest frame in this architecture and it reads instantly as
   "home" rather than "stock photo in a box".
   ========================================================================== */

.arch {
	position: relative;
	overflow: hidden;
	/* A pointed-shouldered arch: round at the top, square at the foot. */
	border-start-start-radius: 50% 32%;
	border-start-end-radius: 50% 32%;
	border-end-start-radius: 18px;
	border-end-end-radius: 18px;
	aspect-ratio: 4 / 5;
	background: var(--cream);
}

.arch img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* A thin gold outline, offset, as a second arch behind the first. */
.arch--framed::before {
	content: "";
	position: absolute;
	inset: -14px -14px 0 -14px;
	border: 2px solid var(--gold);
	border-bottom: 0;
	border-start-start-radius: 50% 32%;
	border-start-end-radius: 50% 32%;
	z-index: -1;
	opacity: .55;
}

.arch-wrap { position: relative; isolation: isolate; padding-top: 14px; }

.arch--sm { aspect-ratio: 3 / 4; }

/* ==========================================================================
   3. One repeated call to action
   Every reference site puts a single high-contrast action everywhere. Ours is
   not "donate" — Ekhaa does not take donations through this site — it is the
   step the page actually offers.
   ========================================================================== */

.ekhaa-btn--cta {
	background-color: var(--btn-cta-bg, var(--clay-deep));
	color: var(--btn-cta-ink, #fff);
	font-size: 1.02rem;
	padding: .9rem 2rem;
}
.ekhaa-btn--cta:hover { background: #6f3326; color: #fff; }

/* A real background, not `transparent`. A see-through button inherits whatever
   is behind it, which makes its label's contrast unknowable — and it was
   landing at 1:1 in high-contrast mode. */
/* Tokens only. High contrast then flows through the variables, which is the
   one mechanism that was demonstrably reaching these elements. */
.ekhaa-btn--quiet {
	background-color: var(--btn-quiet-bg, #fff);
	border-color: var(--btn-quiet-border, var(--sand));
	color: var(--btn-quiet-ink, var(--ink));
}
.ekhaa-btn--quiet:hover { background-color: var(--cream); color: var(--btn-quiet-ink, var(--ink)); }

/* ==========================================================================
   4. The official word
   ensan.org.sa gives a royal quotation a section of its own with a portrait.
   It is how trust is signalled in this sector, and it was buried in four
   small cards before.
   ========================================================================== */

.pledge {
	background: var(--ink);
	color: #e8dcc4;
	position: relative;
	overflow: hidden;
}
.pledge__inner {
	display: grid;
	gap: clamp(1.5rem, 4vw, 3rem);
	align-items: center;
}
@media (min-width: 900px) {
	.pledge__inner { grid-template-columns: .32fr 1fr; }
}
.pledge blockquote {
	margin: 0;
	font-family: var(--wp--preset--font-family--heading);
	font-size: clamp(1.25rem, 2.1vw, 1.75rem);
	line-height: 1.75;
	color: #fff;
}
.pledge blockquote::before {
	content: "”";
	display: block;
	font-size: 3.5rem;
	line-height: .6;
	color: var(--gold);
	margin-bottom: .3rem;
}
.pledge cite {
	display: block;
	margin-top: 1.1rem;
	font-style: normal;
	font-size: .95rem;
	color: var(--gold-soft);
}
.pledge .arch { aspect-ratio: 3 / 4; max-width: 230px; }

/* ==========================================================================
   5. Impact numbers, the way the sector shows them
   ========================================================================== */

.impact {
	display: grid;
	gap: clamp(1rem, 2.5vw, 2rem);
	grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
}
.impact__item {
	padding: 1.4rem 1.2rem;
	background: #fff;
	border: 1px solid var(--line);
	border-radius: var(--radius);
	text-align: center;
}
.impact__num {
	display: block;
	font-family: var(--wp--preset--font-family--heading);
	font-size: clamp(2.4rem, 4.6vw, 3.4rem);
	font-weight: 700;
	line-height: 1;
	color: var(--clay-deep);
}
.impact__label { color: var(--muted); font-size: .95rem; }

/* ==========================================================================
   6. Dark sections become light
   Only the pledge keeps the navy, so it stands alone as the formal moment.
   ========================================================================== */

.ekhaa-section--ink:not(.pledge) {
	background: var(--cream);
	color: var(--ink);
}
.ekhaa-section--ink:not(.pledge) h2,
.ekhaa-section--ink:not(.pledge) h3 { color: var(--ink); }
.ekhaa-section--ink:not(.pledge) p { color: var(--muted); }
.ekhaa-section--ink:not(.pledge) .ekhaa-eyebrow { color: var(--clay-deep); }
.ekhaa-section--ink:not(.pledge) .ekhaa-card {
	background: #fff;
	border-color: var(--line) !important;
}
.ekhaa-section--ink:not(.pledge) .ekhaa-card h3 { color: var(--ink) !important; }
.ekhaa-section--ink:not(.pledge) .ekhaa-card p { color: var(--muted) !important; }
.ekhaa-section--ink:not(.pledge) .stat__num { color: var(--clay-deep); }
.ekhaa-section--ink:not(.pledge) .stat__label { color: var(--muted) !important; }
.ekhaa-section--ink:not(.pledge) .mashrabiya { opacity: .1; }

/* ==========================================================================
   7. Story card — a photograph with words beside it
   ========================================================================== */

.story { display: grid; gap: clamp(1.5rem, 4vw, 3rem); align-items: center; }
@media (min-width: 880px) {
	.story { grid-template-columns: .38fr 1fr; }
	.story--flip { grid-template-columns: 1fr .38fr; }
	.story--flip .story__media { order: 2; }
}
.story blockquote {
	margin: 0;
	font-family: var(--wp--preset--font-family--heading);
	font-size: clamp(1.15rem, 1.9vw, 1.5rem);
	line-height: 1.8;
	color: var(--ink);
}
.story cite { display: block; margin-top: .9rem; font-style: normal; color: var(--muted); font-size: .95rem; }

/* ==========================================================================
   8. Mobile
   ========================================================================== */

@media (max-width: 760px) {
	.ekhaa-hero h1 { font-size: clamp(2.2rem, 10vw, 3rem); max-width: 100%; }
	.arch { aspect-ratio: 1 / 1.1; }
	.pledge .arch { max-width: 170px; margin-inline: auto; }
}

/* ==========================================================================
   9. Brand mark
   The header carried a text wordmark with a diamond because the real asset
   was never wired in. It is their actual bilingual lockup (إخاء / EKHAA).
   ========================================================================== */

.ekhaa-logo { gap: 0; }
.ekhaa-logo::before { display: none; }

.ekhaa-logo img {
	height: 42px;
	width: auto;
	display: block;
}

.is-stuck .ekhaa-logo img { height: 34px; transition: height .35s var(--ease); }

@media (max-width: 760px) {
	.ekhaa-logo img { height: 34px; }
}

/* The footer takes the mark knocked out to cream. */
.ekhaa-footer .ekhaa-logo img {
	height: 46px;
	filter: brightness(0) invert(1) opacity(.92);
}

/* ==========================================================================
   10. Hero composition
   Text and picture were two centred columns of equal weight, which reads as a
   slide rather than a page. The picture now sits lower and carries a card that
   laps over its corner, so the two columns lock together instead of floating.
   ========================================================================== */

@media (min-width: 1000px) {
	.ekhaa-hero__inner { grid-template-columns: 1.08fr .92fr; align-items: start; }
	.ekhaa-hero__inner > div:first-child { padding-top: clamp(1rem, 3vw, 2.5rem); }
	.ekhaa-hero .arch-wrap { margin-block-start: clamp(0rem, 2vw, 1.5rem); }
}

/* A fact lifted out of the page and laid on the image. */
.hero-chip {
	position: absolute;
	inset-inline-start: -18px;
	bottom: 26px;
	z-index: 3;
	background: #fff;
	border: 1px solid var(--line);
	border-radius: 16px;
	padding: .85rem 1.15rem;
	box-shadow: 0 2px 6px rgba(22,40,74,.06), 0 24px 46px -22px rgba(22,40,74,.42);
	display: grid;
	gap: .1rem;
	max-width: 230px;
}
.hero-chip strong {
	font-family: var(--wp--preset--font-family--heading);
	font-size: 1.5rem;
	line-height: 1;
	color: var(--clay-deep);
}
.hero-chip span { font-size: .85rem; color: var(--muted); line-height: 1.5; }

@media (max-width: 999px) {
	.hero-chip { position: static; max-width: none; margin-top: 1rem; box-shadow: var(--shadow); }
}

/* ==========================================================================
   11. Section rhythm
   Every band was a card grid on cream or white, so the page read as one long
   texture. These give the stack a pulse.
   ========================================================================== */

/* A band that runs edge to edge with no card chrome at all. */
.ekhaa-section--plain { background: transparent; }
.ekhaa-section--plain .ekhaa-card {
	background: transparent;
	border: 0;
	box-shadow: none;
	padding-inline: 0;
	border-top: 2px solid var(--sand);
	border-radius: 0;
}
.ekhaa-section--plain .ekhaa-card::before,
.ekhaa-section--plain .ekhaa-card::after { display: none; }
.ekhaa-section--plain .ekhaa-card:hover { transform: none; box-shadow: none; }

/* A heading that sits beside its content instead of above it. */
.split { display: grid; gap: clamp(1.5rem, 4vw, 3.5rem); }
@media (min-width: 900px) {
	.split { grid-template-columns: .34fr 1fr; align-items: start; }
	.split > .ekhaa-head { position: sticky; top: 100px; margin-bottom: 0; }
}

/* ==========================================================================
   Motion-off repair
   cinema.css restores the gold word when motion is switched off, which was
   right on its dark hero. On this light base #dca859 over #fdfbf6 measures
   2.07:1 at 80px/700 — it needs 3:1. sector.css loads after cinema.css, so
   this equal-specificity rule wins without !important.
   ========================================================================== */
:root[data-ekhaa-motion="off"] .ekhaa-hero h1 em {
	background: none;
	-webkit-text-fill-color: var(--clay-deep);
	color: var(--clay-deep);
}

/* ==========================================================================
   Home page: the sections the preview had and the theme did not
   ========================================================================== */

/* The standing figures are words, not numerals, so they must not inherit the
   display size .impact__num uses for counts. */
.impact__num--text {
	font-size: 1.3rem;
	line-height: 1.4;
}

.faq-list {
	max-inline-size: var(--measure);
}

.faq-more {
	margin-block-start: 1.6rem;
	max-inline-size: var(--measure);
}

/* The hero's photograph sits in the same arch as every other image on the
   site. Only the size differs here, because it is the first thing seen. */
.arch--hero {
	margin-inline: auto;
	max-inline-size: 440px;
	width: 100%;
}

@media (max-width: 999px) {
	.arch--hero { max-inline-size: 330px; }
}
