/**
 * Header & footer natifs Licence-4.
 * Sticky en CSS pur (remplace Sticky Header OceanWP + Q2W3 Fixed Widget).
 * Palette : #30698C (bleu), #FF8D62 (orange), #ECF9FF (bleu clair), #183546.
 */

:root {
	--l4-blue: #30698C;
	--l4-blue-dark: #224A62;
	--l4-ink: #183546;
	--l4-orange: #FF8D62;
	--l4-sky: #ECF9FF;
	--l4-font: "Poppins", "Lato", system-ui, -apple-system, sans-serif;
}

/* ---------- Bandeau promo ----------
   Même style que la landing SEA : fond bleu foncé + badge orange, sur tout
   le site. */
.l4-topbar {
	background: var(--l4-blue);
	color: #fff;
	font-family: var(--l4-font);
}
.l4-topbar-inner {
	max-width: 1251px;
	margin: 0 auto;
	padding: 4px 20px;
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
	min-height: 42px;
}
.l4-topbar-right {
	display: flex;
	align-items: center;
	gap: 14px;
	flex-shrink: 0;
}
/* Ni badge avis ni promo — le cas d'une page anglaise dont les champs
   « … (EN) » du bandeau sont vides : le bloc téléphone/langues se retrouve
   seul, et space-between le collerait à gauche. */
.l4-topbar-right:only-child { margin-left: auto; }
.l4-topbar-phone {
	display: inline-flex;
	align-items: center;
	gap: 5px;
	color: #fff;
	font-weight: 700;
	font-size: 13px;
	text-decoration: none;
	white-space: nowrap;
}
.l4-topbar-phone:hover { color: var(--l4-sky); }
.l4-icon-phone { flex-shrink: 0; }
.l4-topbar-promo {
	margin: 0;
	text-align: center;
	font-size: 13px;
	font-weight: 400;
	line-height: 1.4;
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: center;
	column-gap: 10px;
	row-gap: 3px;
}
.l4-promo-badge {
	font-weight: 700;
	font-size: 11px;
	letter-spacing: .06em;
	text-transform: uppercase;
	background: #F2703F;
	color: #fff;
	padding: 4px 8px;
	border-radius: 3px;
	white-space: nowrap;
}
/* Séparateur « · » entre les deux infos promo, comme sur la landing */
.l4-promo-l1 + .l4-promo-l2::before { content: "· "; }
.l4-topbar-langs {
	display: flex;
	align-items: center;
	gap: 8px;
}
.l4-topbar-langs img {
	display: block;
	width: 28px;
	height: 28px;
	border-radius: 50%;
	transition: transform .15s;
}
.l4-topbar-langs a:hover img { transform: scale(1.12); }

/* Badge avis clients (API publique Avis Garantis, voir inc/avis-garantis.php) */
.l4-trust-badge {
	display: flex;
	flex-direction: column;
	gap: 1px;
	font-family: var(--l4-font);
	white-space: nowrap;
	flex-shrink: 0;
}
.l4-trust-main {
	display: flex;
	align-items: center;
	gap: 6px;
}
.l4-trust-stars {
	color: var(--l4-orange);
	font-size: 13px;
	letter-spacing: 1px;
	line-height: 1;
}
.l4-trust-text {
	font-size: 13px;
	color: #fff;
	line-height: 1.3;
}
.l4-trust-text strong { font-weight: 700; }
.l4-trust-link {
	font-size: 10.5px;
	color: var(--l4-sky);
	text-decoration: underline;
	text-underline-offset: 2px;
	line-height: 1.2;
}
.l4-trust-link:hover { color: #fff; }

/* ---------- Barre de navigation (sticky) ----------
   Seule la navbar est sticky, pas le bandeau promo : un élément sticky ne
   colle que dans les limites de son parent, donc le wrapper #l4-header est
   retiré du rendu (display: contents) pour que la navbar se positionne par
   rapport à la page entière pendant que le bandeau défile normalement. */
#l4-header { display: contents; }
/* Un CSS personnalisé Elementor (section .elementor-element-b375c1d de la
   page d'accueil, post-25.css) pose body{overflow:hidden}, ce qui désactive
   position:sticky dans toute la page. On neutralise : « clip » bloque le
   débordement horizontal (le but recherché à l'origine) SANS faire du body
   un conteneur de défilement — le sticky refonctionne. Vérifié sur staging. */
body { overflow-x: clip !important; overflow-y: visible !important; }
.l4-navbar {
	background: #fff;
	box-shadow: 0 1px 6px rgba(24, 53, 70, .12);
	position: sticky;
	top: 0;
	z-index: 999;
}
/* Compatibilité barre d'admin WP */
body.admin-bar .l4-navbar { top: 32px; }
@media (max-width: 782px) {
	body.admin-bar .l4-navbar { top: 46px; }
}
.l4-navbar-inner {
	max-width: 1299px;
	margin: 0 auto;
	padding: 0 20px;
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 24px;
	min-height: 72px;
}
.l4-logo { display: flex; align-items: center; flex-shrink: 0; }
.l4-logo img { height: 52px; width: auto; display: block; }

/* Menu desktop */
.l4-nav { font-family: var(--l4-font); }
.l4-menu,
.l4-menu ul {
	list-style: none;
	margin: 0;
	padding: 0;
}
.l4-menu { display: flex; align-items: center; gap: 4px; }
.l4-menu > li { position: relative; }
.l4-menu a {
	display: block;
	padding: 24px 14px;
	color: var(--l4-ink);
	font-size: 16px;
	text-decoration: none;
	line-height: 1.3;
	font-weight: 400;
  	text-transform: uppercase;
}
.l4-menu > li > a:hover,
.l4-menu > li.current-menu-item > a,
.l4-menu > li.current-menu-ancestor > a { color: var(--l4-blue); }

/* Flèche des items à sous-menu */
.l4-menu > li.menu-item-has-children > a::after {
	content: "";
	display: inline-block;
	margin-left: 7px;
	width: 7px;
	height: 7px;
	border-right: 2px solid currentColor;
	border-bottom: 2px solid currentColor;
	transform: rotate(45deg) translateY(-3px);
}

/* Sous-menus desktop */
.l4-menu li ul {
	position: absolute;
	top: 100%;
	left: 0;
	min-width: 300px;
	background: #fff;
	border-radius: 0 0 8px 8px;
	box-shadow: 0 10px 28px rgba(24, 53, 70, .18);
	opacity: 0;
	visibility: hidden;
	transform: translateY(8px);
	transition: opacity .18s, transform .18s;
	padding: 6px 0;
	z-index: 1000;
}
.l4-menu li:hover > ul,
.l4-menu li:focus-within > ul {
	opacity: 1;
	visibility: visible;
	transform: translateY(0);
}
.l4-menu li ul a {
	padding: 10px 18px;
	font-weight: 500;
	font-size: 15px;
}
.l4-menu li ul a:hover {
	background: var(--l4-sky);
	color: var(--l4-blue);
}

/* Téléphone dans le menu (visible en mobile uniquement) */
.l4-nav-phone { display: none; }

/* Bouton d'appel + burger, groupés à droite de la navbar (mobile uniquement) */
.l4-navbar-actions {
	display: flex;
	align-items: center;
	gap: 8px;
}
.l4-navbar-call {
	display: none;
	align-items: center;
	justify-content: center;
	width: 40px;
	height: 40px;
	border-radius: 50%;
	background: var(--l4-blue);
	color: #fff;
	text-decoration: none;
	flex-shrink: 0;
}
.l4-navbar-call:hover { background: var(--l4-blue-dark); }

/* Burger : mêmes dimensions/fond que le bouton d'appel, barres blanches
   (avant : barres bleues sur fond clair, peu lisible sur certains écrans). */
.l4-burger {
	display: none;
	align-items: center;
	justify-content: center;
	flex-direction: column;
	gap: 5px;
	width: 40px;
	height: 40px;
	background: var(--l4-blue);
	border: 0;
	border-radius: 50%;
	padding: 0;
	cursor: pointer;
	flex-shrink: 0;
}
.l4-burger:hover { background: var(--l4-blue-dark); }
.l4-burger span {
	display: block;
	width: 18px;
	height: 2px;
	background: #fff;
	border-radius: 2px;
	transition: transform .22s, opacity .22s;
}
.l4-burger[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.l4-burger[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.l4-burger[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- Tablette / petit desktop : menu resserré ---------- */
@media (min-width: 1025px) and (max-width: 1260px) {
	.l4-menu a { padding: 24px 9px; font-size: 14.5px; }
	.l4-navbar-inner { gap: 14px; }
	.l4-logo img { height: 44px; }
}

/* ---------- Mobile ---------- */
@media (max-width: 1024px) {
	.l4-topbar-inner {
		flex-wrap: wrap;
		justify-content: center;
		gap: 4px 12px;
		padding: 7px 12px;
	}
	.l4-topbar-phone { display: none; } /* repris dans le menu mobile */
	.l4-topbar-promo { font-size: 12.5px; }
	.l4-topbar-langs img { width: 24px; height: 24px; }

	.l4-navbar-inner { min-height: 60px; }
	.l4-logo img { height: 42px; }
	.l4-navbar-call { display: flex; }
	.l4-burger { display: flex; }

	.l4-nav {
		display: none;
		position: absolute;
		top: 100%;
		left: 0;
		right: 0;
		background: #fff;
		box-shadow: 0 14px 24px rgba(24, 53, 70, .18);
		max-height: calc(100vh - 60px);
		overflow-y: auto;
		-webkit-overflow-scrolling: touch;
	}
	.l4-navbar { position: sticky; }
	.l4-nav.is-open { display: block; }
	.l4-menu { display: block; padding: 6px 0; }
	.l4-menu a { padding: 13px 20px; }
	.l4-menu > li.menu-item-has-children > a::after {
		float: right;
		margin-top: 6px;
		transition: transform .2s;
	}
	.l4-menu > li.menu-item-has-children.is-open > a::after {
		transform: rotate(225deg) translateY(-3px);
	}
	.l4-menu li ul {
		position: static;
		opacity: 1;
		visibility: visible;
		transform: none;
		box-shadow: none;
		background: var(--l4-sky);
		display: none;
		border-radius: 0;
	}
	.l4-menu li.is-open > ul { display: block; }
	.l4-menu li ul a { padding-left: 34px; }

	.l4-nav-phone {
		display: flex;
		align-items: center;
		justify-content: center;
		gap: 6px;
		margin: 8px 20px 16px;
		background: var(--l4-blue);
		color: #fff;
		font-weight: 600;
		padding: 12px;
		border-radius: 6px;
		text-decoration: none;
		font-family: var(--l4-font);
	}
}

/* Très petits écrans : promo sur une seule ligne utile */
@media (max-width: 480px) {
	.l4-promo-l2 { display: none; }
	.l4-topbar-promo { font-size: 13px; }
}

/* Le menu mobile ouvert bloque le défilement de la page derrière
   (!important : doit repasser devant le body{overflow-y:visible !important}
   posé plus haut pour réparer le sticky). */
html.l4-menu-open,
html.l4-menu-open body { overflow: hidden !important; }

/* Accessibilité : focus clavier visible */
.l4-menu a:focus-visible,
.l4-logo:focus-visible,
.l4-topbar-langs a:focus-visible,
.l4-nav-phone:focus-visible {
	outline: 2px solid var(--l4-orange);
	outline-offset: 2px;
	border-radius: 3px;
}
.l4-navbar-call:focus-visible,
.l4-burger:focus-visible {
	outline: 2px solid var(--l4-orange);
	outline-offset: 2px;
	border-radius: 50%;
}

/* Respect de prefers-reduced-motion */
@media (prefers-reduced-motion: reduce) {
	.l4-menu li ul,
	.l4-burger span,
	.l4-topbar-langs img { transition: none; }
}

/* ---------- Bandeau "page-header" OceanWP (titre + fil d'Ariane) ----------
   OceanWP ajoute ce bandeau (titre + breadcrumb) sur certaines pages. On
   masque le titre, on centre le fil d'Ariane et on retire le fond gris +
   les grandes marges. !important sur le fond/padding car le CSS additionnel
   du Customizer (chargé en tout dernier) peut sinon reprendre le dessus. */
.page-header:not(.background-image-page-header) {
	background-color: transparent !important;
	border-bottom: 0 !important;
	padding: 10px 0 !important;
}

.page-header-title,
.page-subheading {
	display: none !important;
}

.page-header .site-breadcrumbs {
	position: static;
	top: auto;
	left: auto;
	right: auto;
	max-width: 100%;
	height: auto;
	line-height: 1.6;
	margin: 0;
	text-align: center;
	white-space: normal;
	overflow: visible;
}

/* ---------- Footer ----------
   Fond : même bleu que le footer du site actuel en production (#30698C,
   vérifié sur www.licence-4.com — couleur calculée de la section Elementor). */
#l4-footer {
	background: var(--l4-blue);
	color: #e3eef5;
	font-family: var(--l4-font);
	margin-top: 0;
}
.l4-footer-inner {
	max-width: 1251px;
	margin: 0 auto;
	padding: 48px 20px 32px;
	display: grid;
	grid-template-columns: 1fr 1fr 1fr;
	gap: 40px;
}
.l4-footer-col h2 {
	color: #fff !important;
	font-size: 17px;
	font-weight: 700;
	margin: 0 0 14px;
	padding-bottom: 8px;
}
/* Interlignes resserrés (1.45 au lieu de 1.7 sur les paragraphes, 1.35 au lieu
   de 1.55 sur les liens, 6 px d'écart entre deux liens au lieu de 8) : les
   colonnes du footer sont des listes de liens courts, l'aération d'un corps de
   texte y étirait le bloc sur une hauteur d'écran inutile.
   L'écart entre deux <li> reste au-dessus de l'interligne : plusieurs libellés
   passent sur deux lignes (« Formation Hygiène Alimentaire HACCP ») et il faut
   voir où un lien s'arrête. */
.l4-footer-col p {
	font-size: 14.5px;
	line-height: 1.45;
	margin: 0 0 12px;
}
.l4-footer-col ul {
	list-style: none;
	margin: 0;
	padding: 0;
}
.l4-footer-col li.l4-margin { margin-bottom: 10px; }
.l4-footer-col a {
	color: #e3eef5;
	font-size: 14.5px;
	text-decoration: none;
	line-height: 1.35;
}
.l4-footer-col a:hover { color: var(--l4-orange); }

/* Mise en avant d'un lien de menu, repris du footer actuel où « Club
   Licence-4.com » ressort en gras blanc, détaché de la liste au-dessus.
   Utilisation : Apparence > Menus, ouvrir l'élément de menu et coller
   « l4-menu-fort » dans le champ « Classes CSS » — champ à activer dans
   Options de l'écran s'il n'apparaît pas. S'applique à n'importe quel élément
   des quatre menus du footer, pas seulement au Club. */
.l4-footer-col li.l4-menu-fort {
	margin-top: 14px;
	margin-bottom: 10px;
}
.l4-footer-col li.l4-menu-fort > a {
	color: #fff;
	font-weight: 700;
}
.l4-footer-col li.l4-menu-fort > a:hover { color: var(--l4-orange); }
.l4-menu-item-icon { height: 16px; width: auto; vertical-align: middle; margin-right: 6px; }
/* Logo : hauteur imposée en CSS — l'attribut height du <img> est neutralisé
   par le `img { height: auto }` d'OceanWP, ce qui affichait le fichier à sa
   taille réelle (logo énorme et pixellisé à l'agrandissement). */
.l4-footer-contact > a img {
	height: 46px;
	width: auto;
	margin-bottom: 14px;
}
.l4-footer-certifs img {
	background: #fff;
	border-radius: 6px;
	padding: 8px;
	margin: 10px 0 14px;
}
.l4-footer-small { font-size: 12.5px; opacity: .8; }
.l4-footer-bottom {
	border-top: 1px solid rgba(255, 255, 255, .12);
	text-align: center;
	padding: 16px 20px;
}
.l4-footer-bottom p {
	margin: 0;
	font-size: 13px;
	opacity: .75;
}
@media (max-width: 1024px) {
	.l4-footer-inner { grid-template-columns: 1fr 1fr; gap: 36px 32px; }
}
@media (max-width: 640px) {
	.l4-footer-inner { grid-template-columns: 1fr; gap: 32px; padding: 36px 20px 24px; }
}
