/* GPM Humanitarian Footprint – mirrors the reference design. Scoped to .gpm-fp so theme styles don't leak in. */
.gpm-fp {
	--gpm-navy: #0c213e;
	--gpm-red: #df303e;
	--gpm-muted: #5d6b7d;
	--gpm-pale: #f1f5f9;
	--gpm-line: #dfe5ed;
	--gpm-font: Arial, Helvetica, sans-serif;
	background: var(--gpm-pale);
	color: var(--gpm-navy);
	font-family: var(--gpm-font);
	font-size: 16px;
	line-height: 1.65;
	-webkit-font-smoothing: antialiased;
}
.gpm-fp--transparent { background: transparent; }
.gpm-fp *, .gpm-fp *::before, .gpm-fp *::after { box-sizing: border-box; }

/* Reset common theme overrides */
.gpm-fp h2, .gpm-fp h3, .gpm-fp h4, .gpm-fp p, .gpm-fp strong, .gpm-fp span, .gpm-fp small, .gpm-fp summary {
	font-family: inherit; color: inherit; text-transform: none;
}
.gpm-fp button {
	font: inherit; line-height: inherit; color: inherit; cursor: pointer; margin: 0;
	text-transform: none; letter-spacing: normal; text-shadow: none; box-shadow: none;
	min-height: 0; width: auto; height: auto; font-weight: 400; text-decoration: none;
	-webkit-appearance: none; appearance: none;
}
.gpm-fp button[hidden] { display: none !important; }
.gpm-fp a { color: inherit; text-decoration: none; box-shadow: none; }
.gpm-fp a:focus-visible, .gpm-fp button:focus-visible, .gpm-fp summary:focus-visible {
	outline: 3px solid #eaaa22; outline-offset: 5px;
}

.gpm-fp-wrap { padding: 76px 6%; max-width: 1500px; margin: auto; }

.gpm-fp-eyebrow {
	font-size: 13px; letter-spacing: 2px; font-weight: 700; text-transform: uppercase !important;
	color: var(--gpm-red) !important; margin: 0 0 18px; line-height: 1.65;
}

.gpm-fp-head { display: flex; justify-content: space-between; align-items: end; gap: 24px; margin-bottom: 30px; }
.gpm-fp .gpm-fp-title {
	font-size: clamp(30px, 3vw, 44px); line-height: 1.15; letter-spacing: -1px; margin: 0 0 20px; font-weight: 700; padding: 0;
}
.gpm-fp-explore { white-space: nowrap; }
.gpm-fp-explore:hover { color: var(--gpm-red); }

/* Stats */
.gpm-fp-stats {
	display: grid; grid-template-columns: repeat(3, 1fr);
	background: #fff; border: 1px solid var(--gpm-line); margin-bottom: 18px;
}
.gpm-fp-stats article { padding: 28px; border-right: 1px solid var(--gpm-line); margin: 0; }
.gpm-fp-stats article:last-child { border-right: 0; }
.gpm-fp-stats strong {
	font-size: clamp(26px, 3vw, 40px); line-height: 1.2; display: block; margin-bottom: 14px; letter-spacing: -1px; font-weight: 700;
}
.gpm-fp-stats span, .gpm-fp-stats small { display: block; }
.gpm-fp-stats span { font-size: 16px; font-weight: 700; }
.gpm-fp-stats small { font-size: 14px; color: var(--gpm-muted); margin-top: 7px; }
.gpm-fp-context { font-size: 14px; color: var(--gpm-muted) !important; max-width: 1000px; margin: 18px 0 36px; }

/* Layout */
.gpm-fp-layout {
	display: grid; grid-template-columns: minmax(0, 2.7fr) minmax(240px, 1fr); gap: 25px; align-items: start;
}

/* Region tabs */
.gpm-fp-tabs { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 18px; }
.gpm-fp .gpm-fp-tabs button {
	border: 1px solid #cdd6e2; background: #fff; color: #000; padding: 8px 18px; border-radius: 30px; font-size: 14px;
}
.gpm-fp .gpm-fp-tabs button.selected { background: var(--gpm-navy); border-color: #cdd6e2; color: #fff; }

/* Map */
.gpm-fp-map {
	position: relative; aspect-ratio: 1000 / 430; background: #102b4a; border-radius: 4px; overflow: hidden;
}
.gpm-fp-map img { width: 100%; height: 100%; display: block; max-width: none; margin: 0; border: 0; box-shadow: none; }
.gpm-fp .gpm-fp-pin {
	position: absolute; transform: translate(-50%, -50%); width: 12px; height: 12px; min-height: 0; padding: 0;
	background: #ff5262; border: 2px solid #fff; border-radius: 50%;
	box-shadow: 0 0 0 4px rgba(223, 48, 62, .14); z-index: 1;
}
.gpm-fp .gpm-fp-pin:hover, .gpm-fp .gpm-fp-pin:focus-visible, .gpm-fp .gpm-fp-pin.chosen {
	background: #ffc74b; z-index: 3; box-shadow: 0 0 0 6px rgba(255, 199, 75, .267);
}

.gpm-fp-caption { font-size: 13px; color: var(--gpm-muted) !important; margin: 12px 0 18px; }

/* Location buttons */
.gpm-fp-buttons { display: flex; flex-wrap: wrap; gap: 8px; }
.gpm-fp .gpm-fp-buttons button {
	font-size: 14px; padding: 7px 12px; border: 1px solid #d2dce8; background: #fff; color: #000; border-radius: 3px;
}
.gpm-fp .gpm-fp-buttons button.selected { background: var(--gpm-navy); color: #fff; border-color: var(--gpm-navy); }

/* Detail panel */
.gpm-fp-detail { background: #fff; border-top: 4px solid var(--gpm-red); padding: 26px; min-height: 370px; }
.gpm-fp-detail > p:not(.gpm-fp-eyebrow) { margin: 0 0 20px; }
.gpm-fp .gpm-fp-detail h3 { font-size: 30px; line-height: 1.3; margin: 12px 0; font-weight: 700; letter-spacing: normal; }
.gpm-fp-detail a, .gpm-fp-sources a { color: var(--gpm-red) !important; text-decoration: underline !important; font-size: 14px; }
.gpm-fp-note {
	font-size: 14px; color: var(--gpm-muted); border-left: 3px solid #a9bbd0; padding: 12px 18px;
	background: var(--gpm-pale); margin-top: 25px;
}
.gpm-fp-figures { border-top: 1px solid var(--gpm-line); padding-top: 18px; }
.gpm-fp-figures span, .gpm-fp-figures small { font-size: 13px; color: var(--gpm-muted) !important; display: block; }
.gpm-fp .gpm-fp-figures h4 { margin: 8px 0 20px; line-height: 1.4; font-size: 16px; font-weight: 700; letter-spacing: normal; }
.gpm-fp-figures strong { font-size: 24px; display: block; margin-top: 15px; font-weight: 700; line-height: 1.65; }
.gpm-fp .gpm-fp-figures p { font-size: 14px; margin: 16px 0 20px; }

/* Sources */
.gpm-fp-sources { border-bottom: 1px solid var(--gpm-line); padding: 20px 0; margin-top: 25px; }
.gpm-fp-sources summary { font-weight: 700; cursor: pointer; }
.gpm-fp-sources p { margin: 15px 0 0; color: var(--gpm-muted); }
.gpm-fp-sources-body > a:first-of-type { display: inline-block; margin-top: 15px; }

@media (max-width: 800px) {
	.gpm-fp-wrap { padding: 48px 6%; }
	.gpm-fp-head { align-items: start; flex-direction: column; }
	.gpm-fp-stats { grid-template-columns: 1fr; }
	.gpm-fp-stats article { border-right: 0; border-bottom: 1px solid var(--gpm-line); padding: 22px; }
	.gpm-fp-stats article:last-child { border-bottom: 0; }
	.gpm-fp-layout { grid-template-columns: 1fr; }
	.gpm-fp .gpm-fp-pin { width: 10px; height: 10px; border-width: 1px; }
	.gpm-fp-detail { min-height: 0; }
	.gpm-fp .gpm-fp-buttons button { padding: 8px 10px; }
}

/* Gallery in the Selected-location panel */
.gpm-fp-gallery { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; margin: 22px 0 18px; }
.gpm-fp-gallery[data-count="1"] { grid-template-columns: 1fr; }
.gpm-fp-gallery[data-count="2"], .gpm-fp-gallery[data-count="4"] { grid-template-columns: repeat(2, 1fr); }
.gpm-fp .gpm-fp-thumb {
	position: relative; display: block; padding: 0; border: 0; border-radius: 3px; overflow: hidden;
	aspect-ratio: 1 / 1; background: var(--gpm-pale);
}
.gpm-fp-gallery[data-count="1"] .gpm-fp-thumb { aspect-ratio: 16 / 10; }
.gpm-fp-thumb img {
	width: 100%; height: 100%; object-fit: cover; display: block; margin: 0; max-width: none;
	transition: transform .25s ease;
}
.gpm-fp .gpm-fp-thumb:hover img, .gpm-fp .gpm-fp-thumb:focus-visible img { transform: scale(1.05); }
.gpm-fp .gpm-fp-thumb:focus-visible { outline-offset: 2px; }
.gpm-fp-more {
	position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
	background: rgba(12, 33, 62, .68); color: #fff !important; font-size: 18px; font-weight: 700;
}

/* Lightbox (appended to <body>, outside .gpm-fp) */
html.gpm-fp-lb-open { overflow: hidden; }
.gpm-fp-lb { position: fixed; inset: 0; z-index: 100000; display: flex; align-items: center; justify-content: center; font-family: Arial, Helvetica, sans-serif; }
.gpm-fp-lb[hidden] { display: none; }
.gpm-fp-lb-backdrop { position: absolute; inset: 0; background: rgba(8, 20, 38, .92); }
.gpm-fp-lb-figure { position: relative; margin: 0; max-width: min(1100px, 90vw); text-align: center; }
.gpm-fp-lb-figure img { display: block; max-width: 100%; max-height: 80vh; width: auto; height: auto; margin: 0 auto; border-radius: 3px; }
.gpm-fp-lb-figure figcaption {
	display: flex; justify-content: space-between; gap: 16px; color: #e3e9f1; font-size: 14px; line-height: 1.5;
	padding: 12px 2px 0; text-align: left;
}
.gpm-fp-lb-count { color: #a9bbd0; white-space: nowrap; }
.gpm-fp-lb .gpm-fp-lb-btn {
	position: absolute; z-index: 1; width: 48px; height: 48px; border-radius: 50%; border: 0; padding: 0; margin: 0;
	background: rgba(255, 255, 255, .12); color: #fff; font: 400 30px/48px Arial, sans-serif; cursor: pointer;
	box-shadow: none; text-shadow: none; min-height: 0;
}
.gpm-fp-lb .gpm-fp-lb-btn:hover { background: rgba(255, 255, 255, .24); }
.gpm-fp-lb .gpm-fp-lb-btn:focus-visible { outline: 3px solid #eaaa22; outline-offset: 3px; }
.gpm-fp-lb .gpm-fp-lb-btn[hidden] { display: none; }
.gpm-fp-lb-close { top: 18px; right: 18px; }
.gpm-fp-lb-prev { left: 18px; top: 50%; transform: translateY(-50%); }
.gpm-fp-lb-next { right: 18px; top: 50%; transform: translateY(-50%); }
@media (max-width: 800px) {
	.gpm-fp-lb-figure { max-width: 94vw; }
	.gpm-fp-lb-prev, .gpm-fp-lb-next { top: auto; bottom: 18px; transform: none; }
}
