/**
 * Mueen footer — layout for the extended contacts row.
 *
 * The parent theme lays .ft-contacts out as a flex row with hard-coded
 * widths (email 40%, call 20%, social auto) which only holds three blocks.
 * With WhatsApp / Location / Working Hours added we switch to a grid.
 * Scoped to .ft-contacts--mueen so the parent's 3-block layout is untouched.
 */

#site-footer .ft-contacts.ft-contacts--mueen {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	column-gap: 40px;
	row-gap: 40px;
	align-items: start;
}

/* Neutralise the parent's fixed column widths inside the grid. */
#site-footer .ft-contacts.ft-contacts--mueen .ft-contact-block {
	width: 100%;
	min-width: 0;
	margin-left: 0;
}

/* Let long values wrap instead of overflowing their column. */
#site-footer .ft-contacts.ft-contacts--mueen .ft-value {
	overflow-wrap: anywhere;
	word-break: break-word;
}

/* Working hours and location read better on a single line each. */
#site-footer .ft-contacts.ft-contacts--mueen .hours-part .ft-value,
#site-footer .ft-contacts.ft-contacts--mueen .location-part .ft-value {
	text-wrap: balance;
}

/* Social icons sit slightly lower than text values — pull them into line. */
#site-footer .ft-contacts.ft-contacts--mueen .social-part .jkd-social-list {
	--jkd-icon-size: 22px;
	flex-wrap: wrap;
}

/* Inline brand SVGs (TikTok / WhatsApp) must match Iconoir's optical size. */
#site-footer .jkd-social-list .mueen-brand-icon {
	color: var(--jkd-heading);
	display: inline-flex;
	height: var(--jkd-icon-size);
	width: var(--jkd-icon-size);
}

#site-footer .jkd-social-list .mueen-brand-icon svg {
	height: 100%;
	width: 100%;
}

@media (max-width: 992px) {
	#site-footer .ft-contacts.ft-contacts--mueen {
		grid-template-columns: repeat(2, minmax(0, 1fr));
		column-gap: 30px;
		row-gap: 30px;
	}
}

@media (max-width: 576px) {
	#site-footer .ft-contacts.ft-contacts--mueen {
		column-gap: 20px;
		row-gap: 24px;
	}

	/* Address and hours need the full width at this size. */
	#site-footer .ft-contacts.ft-contacts--mueen .location-part,
	#site-footer .ft-contacts.ft-contacts--mueen .hours-part,
	#site-footer .ft-contacts.ft-contacts--mueen .social-part {
		grid-column: 1 / -1;
	}
}

/* ── Centred copyright ────────────────────────────────────
   The parent pushes .ft-copy to the far edge with margin-left:auto
   (main.css) / margin-right:auto (main.rtl.css). `margin-inline: auto`
   overrides both at once, and :only-child keeps the rule from
   hijacking the layout if footer menus are added later.
   Parent specificity is (1,1,0); this is (1,3,0), so it wins. */

#site-footer .ft-bottom .ft-copy:only-child {
	margin-inline: auto;
	text-align: center;
}

/* ── RTL ──────────────────────────────────────────────────
   The Arabic build mirrors the layout; the grid handles direction
   automatically, but the parent's absolutely-positioned plus marker
   is pinned to the left edge. */
[dir="rtl"] #site-footer .ft-contacts .plus-icon {
	left: auto;
	right: 0;
}
