/* =====================================================
   Mini Golf Planet - pages de liste
   (archive des établissements, territoires, thématiques, caractéristiques, pages hub)
===================================================== */


/* EN-TÊTE */
section.listing-heading {
	padding-top: 50px;
	padding-bottom: 60px;
}

.listing-heading .heading-text {
	max-width: 860px;
}

.listing-heading h1 {
	display: flex;
	align-items: center;
	gap: 18px;
	margin-bottom: 16px;
	color: var(--color-ivory);
}

.listing-heading .heading-icon {
	display: inline-flex;
	flex: 0 0 auto;
	align-items: center;
	justify-content: center;
	width: 64px;
	height: 64px;
	border-radius: 50%;
	background-color: var(--color-ivory);
}

.listing-heading .heading-icon .fa-icon {
	width: auto;
	height: 30px;
	fill: var(--color-green);
}

.listing-heading .heading-intro,
.listing-heading .heading-intro p {
	font-size: 19px;
	line-height: 1.55em;
	color: var(--color-ivory);
}

.listing-heading .heading-intro p:last-child {
	margin-bottom: 0;
}

.listing-heading .heading-intro a {
	color: var(--color-ivory);
	font-weight: 600;
	text-decoration: underline;
	text-underline-offset: 3px;
}

.listing-heading .heading-intro a:hover,
.listing-heading .heading-intro a:focus-visible {
	color: var(--color-sand);
}

.listing-heading .results-count {
	display: inline-block;
	margin: 22px 0 0;
	padding: 8px 16px;
	border-radius: 30px;
	background-color: var(--color-forest);
	color: var(--color-ivory);
	font-size: 14px;
	font-weight: 600;
}


/* CARTES DE TERMES (pays, régions, villes, thématiques, caractéristiques) */
section.listing-terms {
	padding-top: 60px;
	padding-bottom: 60px;
}

.listing-terms h2 {
	margin-bottom: 24px;
}

.listing-terms .cta-link {
	margin-top: 24px;
}

.listing-terms-heading {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	justify-content: space-between;
	gap: 10px 30px;
	margin-bottom: 24px;
}

.listing-terms-heading h2 {
	margin-bottom: 0;
}

.listing-terms-heading .cta-link {
	margin-top: 0;
}

.results-range {
	font-family: var(--font-body);
	font-size: 0.55em;
	font-weight: 500;
	color: rgba(24, 61, 53, 0.65);
}

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

.term-card {
	display: flex;
	align-items: center;
	gap: 14px;
	height: 100%;
	padding: 16px 18px;
	border-radius: 16px;
	background-color: var(--color-sand);
	color: var(--color-forest);
	transition: background-color 0.3s ease, color 0.3s ease;
}

.bg-ivory .term-card {
	background-color: #fff;
	box-shadow: 0 3px 12px rgba(24, 61, 53, 0.06);
}

.term-card:hover,
.term-card:focus-visible {
	background-color: var(--color-green) !important;
	color: var(--color-ivory);
}

.term-card-icon {
	display: inline-flex;
	flex: 0 0 auto;
	align-items: center;
	justify-content: center;
	width: 44px;
	height: 44px;
	border-radius: 50%;
	background-color: var(--color-ivory);
}

.term-card-icon .fa-icon {
	width: auto;
	height: 20px;
	fill: var(--color-green);
}

.term-card-icon .mgp-icon {
	width: 22px;
	height: 22px;
	color: var(--color-green);
}

.term-card-text {
	display: flex;
	flex-direction: column;
	gap: 2px;
	min-width: 0;
}

.term-card-text strong {
	font-family: var(--font-heading);
	font-size: 17px;
	line-height: 1.25;
}

.term-card-text span {
	font-size: 13px;
	opacity: 0.8;
}


/* Where to play : groupes par pays, cartes de chaîne avec la liste des fiches */
.where-country {
	margin: 34px 0 14px;
	font-size: 22px;
}

.where-country:first-of-type {
	margin-top: 10px;
}

.term-card-list {
	align-items: flex-start;
}

.term-card-list:hover {
	background-color: var(--color-sand) !important;
	color: var(--color-forest);
}

.bg-ivory .term-card-list:hover {
	background-color: #fff !important;
}

.term-card-list strong a {
	color: var(--color-forest);
}

.term-card-list strong a:hover,
.term-card-list strong a:focus-visible {
	color: var(--color-orange);
}

.term-card-text .term-card-locations {
	margin: 8px 0 0;
	padding: 0;
	list-style: none;
}

.term-card-locations li {
	margin: 0 0 4px;
	font-size: 14px;
	line-height: 1.35;
}

.term-card-locations a {
	color: var(--color-orange);
}

.term-card-locations a:hover,
.term-card-locations a:focus-visible {
	color: var(--color-forest);
	text-decoration: underline;
}

/* RÉSULTATS */
section.listing-results {
	padding-top: 60px;
	scroll-margin-top: 100px;
}

.listing-results-heading h2 {
	margin-bottom: 20px;
}

.listing-filters {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 10px;
	margin-bottom: 36px;
	padding: 18px;
	border-radius: 20px;
	background-color: var(--color-ivory);
	box-shadow: 0 3px 12px rgba(24, 61, 53, 0.08);
}

.listing-filters select,
.listing-filters input[type="search"] {
	flex: 1 1 170px;
	min-width: 0;
	height: 46px;
	padding: 0 14px;
	border: 1px solid rgba(24, 61, 53, 0.2);
	border-radius: 12px;
	background-color: #fff;
	color: var(--color-forest);
	font-family: var(--font-body);
	font-size: 15px;
}

.listing-filters .btn {
	height: 46px;
}

.listing-filters-reset {
	font-size: 14px;
	font-weight: 600;
	color: var(--color-orange);
	text-decoration: underline;
}


/* GRILLE ET CARTE D'ÉTABLISSEMENT */
.location-grid {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 24px;
}

.location-card {
	height: 100%;
}

.location-card-link {
	display: flex;
	flex-direction: column;
	height: 100%;
	overflow: hidden;
	border-radius: 20px;
	background-color: var(--color-ivory);
	color: var(--color-forest);
	box-shadow: 0 3px 12px rgba(24, 61, 53, 0.08);
	transition: box-shadow 0.3s ease, transform 0.3s ease;
}

.location-card-link:hover,
.location-card-link:focus-visible {
	color: var(--color-forest);
	transform: translateY(-3px);
	box-shadow: 0 10px 24px rgba(24, 61, 53, 0.16);
}

.location-card-visual {
	position: relative;
	aspect-ratio: 16 / 10;
	overflow: hidden; /* sinon une image haute agrandit la boîte malgré le ratio */
	background-color: var(--color-sand);
}

.location-card-visual > img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.location-card-logo,
.location-card-placeholder {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	height: 100%;
	padding: 24px 40px;
	background-color: #fff;
}

.location-card-placeholder {
	background: linear-gradient(120deg, var(--color-forest) 0%, var(--color-green) 55%, var(--color-blue) 100%);
}

.location-card-logo img,
.location-card-placeholder img {
	width: auto;
	max-width: 100%;
	max-height: 100%;
	object-fit: contain;
}

.location-card-placeholder img {
	max-height: 60%;
}

/* Logo en pastille sur la photo */
.location-card-badge {
	position: absolute;
	left: 14px;
	bottom: 14px;
	display: flex;
	align-items: center;
	justify-content: center;
	height: 80px;
	aspect-ratio: 4 / 3;
	padding: 15px;
	border-radius: 16px;
	background-color: #fff; /* blanc pur : beaucoup de logos sont des JPG sur fond blanc */
	box-shadow: 0 4px 14px rgba(0, 0, 0, 0.25);
}

.location-card-badge img {
	width: auto;
	max-width: 100%;
	max-height: 100%;
	object-fit: contain;
}

.location-card-body {
	display: flex;
	flex: 1 1 auto;
	flex-direction: column;
	gap: 10px;
	padding: 20px 22px 22px;
}

.location-card-area {
	display: flex;
	align-items: center;
	gap: 6px;
	margin: 0;
	font-size: 13px;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: 0.03em;
	color: var(--color-green);
}

.location-card-area .mgp-icon {
	width: 16px;
	height: 16px;
}

.location-card-title {
	margin: 0;
	font-size: 22px;
	line-height: 1.25;
}

.location-card-description {
	display: -webkit-box;
	margin: 0;
	overflow: hidden;
	font-size: 15px;
	line-height: 1.5;
	-webkit-line-clamp: 3;
	-webkit-box-orient: vertical;
}

.location-card-facts {
	display: flex;
	flex-wrap: wrap;
	gap: 6px;
	margin: 4px 0 0;
	padding: 0;
	list-style: none;
}

.location-card-facts li {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 4px 10px;
	border-radius: 20px;
	background-color: var(--color-sand);
	font-size: 13px;
	font-weight: 500;
}

.location-card-facts .mgp-icon {
	width: 14px;
	height: 14px;
	color: var(--color-green);
}

.location-card-facts .fa-icon {
	width: auto;
	height: 12px;
	fill: var(--color-green);
}

.location-card .cta-link {
	margin-top: auto;
	padding-top: 6px;
}

.location-card .cta-link .mgp-icon {
	width: 18px;
	height: 18px;
}


/* PAGINATION ET LISTE VIDE */
.listing-pagination {
	margin-top: 40px;
}

.listing-pagination ul {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: 8px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.listing-pagination .page-numbers {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 44px;
	height: 44px;
	padding: 0 14px;
	border-radius: 22px;
	background-color: var(--color-ivory);
	color: var(--color-forest);
	font-weight: 600;
}

.listing-pagination a.page-numbers:hover,
.listing-pagination a.page-numbers:focus-visible {
	background-color: var(--color-green);
	color: var(--color-ivory);
}

.listing-pagination .page-numbers.current {
	background-color: var(--color-orange);
	color: var(--color-ivory);
}

.listing-empty {
	padding: 40px;
	border-radius: 20px;
	background-color: var(--color-ivory);
	text-align: center;
}

.listing-empty p {
	margin-bottom: 10px;
	font-size: 17px;
}


/* EN-TÊTE : grande icône décorative (thématiques, caractéristiques) */
.listing-heading.has-visual .grid-container {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 50px;
}

.listing-heading .heading-decor {
	flex: 0 0 auto;
}

.listing-heading .heading-brand-logo {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 260px;
	aspect-ratio: 4 / 3;
	padding: 30px;
	border-radius: 20px;
	background-color: #fff; /* logos souvent en JPG sur fond blanc */
	box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
}

.listing-heading .heading-brand-logo img {
	max-width: 100%;
	max-height: 100%;
	width: auto;
	height: auto;
	object-fit: contain;
}

.listing-heading .heading-decor .fa-icon {
	width: auto;
	height: 170px;
	fill: rgba(255, 252, 247, 0.22);
}


/* BARRE D'ANCRES (épinglée sous l'en-tête par js/scripts.js : position sticky impossible
   avec overflow-x: hidden sur body) */
.mgp-submenu {
	z-index: 50;
	box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.mgp-submenu.is-pinned {
	position: fixed;
	top: var(--mgp-header-height, 0px);
	left: 0;
	width: 100%;
}

.mgp-submenu .grid-container {
	display: flex;
	overflow-x: auto;
	padding: 0 30px;
	scrollbar-width: none;
}

.mgp-submenu .grid-container::-webkit-scrollbar {
	display: none;
}

.mgp-submenu a {
	flex: 0 0 auto;
	padding: 16px 22px;
	border-right: 1px solid rgba(255, 252, 247, 0.12);
	color: var(--color-ivory);
	font-size: 13px;
	font-weight: 700;
	letter-spacing: 0.05em;
	text-transform: uppercase;
	transition: background-color 0.25s ease;
}

.mgp-submenu a:hover,
.mgp-submenu a:focus-visible,
.mgp-submenu a.is-active {
	background-color: var(--color-green);
	color: var(--color-ivory);
}

/* Les sections visées s'arrêtent sous l'en-tête + la barre. */
.mgp-submenu ~ section[id] {
	scroll-margin-top: calc(var(--mgp-header-height, 0px) + 56px);
}


/* SECTIONS EXPLICATIVES (What to expect, Who will enjoy) ET FAQ */
.term-explainer p {
	font-size: 17px;
	line-height: 1.65;
}

.term-explainer p:last-child {
	margin-bottom: 0;
}

.explainer-how .explainer-how-intro {
	margin: 34px 0 0;
	font-family: var(--font-body);
	font-size: 15px;
	font-weight: 700;
	letter-spacing: 0.03em;
	text-transform: uppercase;
	color: var(--color-forest);
}

.explainer-how ul,
.explainer-how ol {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
	gap: 20px;
	margin: 20px 0 0;
	padding: 0;
	list-style: none;
}

.explainer-how li {
	padding: 24px;
	border-top: 5px solid var(--color-green);
	border-radius: 20px;
	background-color: var(--color-ivory);
	font-size: 15px;
	line-height: 1.55;
}

.explainer-how li strong {
	display: block;
	margin-bottom: 8px;
	font-family: var(--font-heading);
	font-size: 19px;
	line-height: 1.3;
	color: var(--color-forest);
}

.explainer-proscons {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 40px;
	margin-top: 40px;
}

.explainer-proscons h3 {
	margin-bottom: 20px;
}

.explainer-icon-list {
	display: flex;
	flex-direction: column;
	gap: 20px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.explainer-icon-list li {
	display: flex;
	align-items: flex-start;
	gap: 16px;
}

.explainer-icon {
	display: flex;
	flex: 0 0 52px;
	align-items: center;
	justify-content: center;
	height: 52px;
	border-radius: 50%;
}

.explainer-icon .fa-icon {
	width: auto;
	height: 22px;
}

.explainer-pros .explainer-icon {
	background-color: color-mix(in srgb, var(--color-green) 15%, white);
}

.explainer-pros .explainer-icon .fa-icon {
	fill: var(--color-green);
}

.explainer-cons .explainer-icon {
	background-color: color-mix(in srgb, var(--color-orange) 13%, white);
}

.explainer-cons .explainer-icon .fa-icon {
	fill: var(--color-orange);
}

.explainer-icon-list strong {
	display: block;
	margin-bottom: 4px;
	font-size: 18px;
}

.explainer-icon-list p {
	margin: 0;
	font-size: 15px;
}

/* HUB DES CHAÎNES */
.brand-cards {
	display: grid;
	grid-template-columns: repeat(4, minmax(0, 1fr));
	gap: 18px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.brand-card {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 6px;
	height: 100%;
	padding: 22px;
	border-radius: 20px;
	background-color: #fff;
	color: var(--color-forest);
	text-align: center;
	box-shadow: 0 3px 12px rgba(24, 61, 53, 0.06);
	transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.brand-card:hover,
.brand-card:focus-visible {
	color: var(--color-forest);
	transform: translateY(-3px);
	box-shadow: 0 10px 24px rgba(24, 61, 53, 0.14);
}

.brand-card-logo {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	height: 110px;
	margin-bottom: 8px;
}

.brand-card-logo img {
	max-width: 80%;
	max-height: 100%;
	width: auto;
	height: auto;
	object-fit: contain;
}

.brand-card-logo .mgp-icon {
	width: 48px;
	height: 48px;
	color: var(--color-green);
}

.brand-card strong {
	font-family: var(--font-heading);
	font-size: 18px;
}

.brand-card-countries {
	font-size: 13px;
	font-weight: 600;
	line-height: 1.4;
	color: var(--color-green);
}

.brand-card-count {
	font-size: 13px;
	opacity: 0.75;
}


/* RESPONSIVE */
@media screen and (max-width: 1024px) {
	.term-cards { grid-template-columns: repeat(3, minmax(0, 1fr)); }
	.location-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media screen and (max-width: 768px) {
	.brand-cards { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.term-cards { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.listing-heading .heading-decor { display: none; }
	.explainer-proscons { grid-template-columns: 1fr; gap: 30px; }
}

@media screen and (max-width: 600px) {
	.mgp-map { height: 320px; }
	section.listing-heading { padding-top: 30px; padding-bottom: 40px; }
	.listing-heading h1 { gap: 12px; }
	.listing-heading .heading-icon { width: 48px; height: 48px; }
	.listing-heading .heading-icon .fa-icon { height: 22px; }
	.listing-heading .heading-intro,
	.listing-heading .heading-intro p { font-size: 17px; }
	.term-cards { grid-template-columns: 1fr; }
	.location-grid { grid-template-columns: 1fr; }
	.listing-filters select,
	.listing-filters input[type="search"],
	.listing-filters .btn { flex: 1 1 100%; justify-content: center; }
}

/* Grappes d'épingles (Leaflet.markercluster) aux couleurs du site */
.marker-cluster-small,
.marker-cluster-medium,
.marker-cluster-large {
	background-color: rgba(36, 139, 89, 0.3);
}

.marker-cluster-small div,
.marker-cluster-medium div,
.marker-cluster-large div {
	background-color: #248B59;
	color: #FFFCF7;
	font-weight: 700;
}

/* Cartes de pays : drapeau rectangulaire (4:3) à la place de l'icône */
.term-card-flag {
	width: auto;
	height: auto;
	border-radius: 0;
	background-color: transparent;
}
.term-card-icon.term-card-flag .mgp-flag-rect {
	width: 56px;
	height: 42px;
	border-radius: 10px;
}

/* Mini drapeau à la place de l'épingle */
.location-card-area .mgp-flag-rect,
.term-card-icon .mgp-flag-rect {
	width: 20px;
	height: 15px;
	border-radius: 4px;
}

/* Where to play (thèmes, types, caractéristiques) : un bloc compact par pays */
.where-countries {
	column-count: 3;
	column-gap: 24px;
}

.where-block {
	break-inside: avoid;
	margin-bottom: 24px;
	padding: 20px 22px;
	border-radius: 20px;
	background-color: #fff;
	box-shadow: 0 3px 12px rgba(24, 61, 53, 0.06);
}

.where-block-head {
	display: flex;
	align-items: center;
	gap: 10px;
	margin-bottom: 12px;
	color: var(--color-forest);
	font-size: 18px;
}

.where-block-head .mgp-flag-rect {
	width: 28px;
	height: 21px;
	border-radius: 5px;
}

.where-block-head:hover strong,
.where-block-head:focus-visible strong {
	color: var(--color-orange);
}

.where-count {
	margin-left: auto;
	padding: 2px 10px;
	border-radius: 20px;
	font-size: 13px;
	font-weight: 700;
	background-color: var(--color-sand);
}

.where-regions {
	display: flex;
	flex-direction: column;
	gap: 4px;
	margin: 0;
	padding: 0;
	list-style: none;
	font-size: 15px;
	line-height: 1.5;
}

.where-regions li {
	margin: 0;
}

.where-regions a {
	color: var(--color-forest);
	text-decoration: underline;
	text-decoration-color: rgba(24, 61, 53, 0.25);
	text-underline-offset: 3px;
}

.where-regions a:hover,
.where-regions a:focus-visible {
	color: var(--color-orange);
	text-decoration-color: currentColor;
}

.where-regions span {
	color: #6B7A76;
	font-size: 13px;
}

@media (max-width: 1024px) {
	.where-countries { column-count: 2; }
}

@media (max-width: 768px) {
	.where-countries { column-count: 1; }
}

/* Logo clair (blanc sur transparent) : fond vert foncé */
.location-card-logo.is-light,
.location-card-badge.is-light { background-color: var(--color-forest); }
