/**
 * Entête Divi : logo | menu centré | auth à droite.
 */
.cst-header-auth-on #main-header .et_menu_container {
	display: flex !important;
	align-items: center !important;
	justify-content: space-between;
	gap: 1rem;
	width: 100%;
	min-height: 0;
}

.cst-header-auth-on #main-header .logo_container {
	float: none !important;
	position: relative !important;
	flex: 0 0 auto;
	width: auto !important;
	max-width: 28%;
	height: auto !important;
	z-index: 2;
	display: flex !important;
	align-items: center;
}

.cst-header-auth-on #main-header #et-top-navigation {
	float: none !important;
	flex: 1 1 auto;
	display: flex !important;
	flex-wrap: nowrap !important;
	align-items: center !important;
	justify-content: flex-end;
	/* Annule le décalage vertical Divi (padding-top + padding-bottom des liens). */
	padding-top: 0 !important;
	padding-bottom: 0 !important;
	height: auto !important;
	width: auto !important;
	max-width: none !important;
}

.cst-header-auth-on #main-header #top-menu-nav {
	flex: 1 1 auto;
	display: flex;
	align-items: center;
	justify-content: center;
	min-width: 0;
	height: auto !important;
}

.cst-header-auth-on #main-header #top-menu {
	float: none !important;
	display: flex !important;
	flex-wrap: wrap;
	justify-content: center;
	align-items: center;
	gap: 0.15rem 0.25rem;
	height: auto !important;
	margin: 0 !important;
}

/*
 * Ne pas mettre les li en display:flex : ça casse le positionnement
 * absolu des sous-menus Divi (ils remontent dans l’entête).
 */
.cst-header-auth-on #main-header #top-menu > li {
	position: relative;
	height: auto !important;
	line-height: inherit;
}

.cst-header-auth-on #main-header #top-menu > li > a {
	height: auto !important;
	line-height: 1.25 !important;
	padding-top: 0.45rem !important;
	padding-bottom: 0.45rem !important;
}

/* Sous-menus toujours sous l’item, pas au-dessus / dans l’entête. */
.cst-header-auth-on #main-header #top-menu > li > ul {
	top: 100% !important;
	bottom: auto !important;
	margin-top: 0 !important;
}

/* Masquer la flèche icône Divi (ETmodules) sur les items parents. */
.cst-header-auth-on #main-header #top-menu > .menu-item-has-children > a:first-child:after {
	display: none !important;
	content: none !important;
}

/* Couleurs menu = chatsanstoit01 (Astra) */
.cst-header-auth-on {
	--cst-nav-color: #490d0d;
	--cst-nav-hover: #f77d26;
	--cst-nav-active: #f9f6fe;
	--cst-nav-active-bg: #7b0a0a;
}

.cst-header-auth-on #main-header #top-menu a,
.cst-header-auth-on #main-header .et_mobile_menu a {
	color: var(--cst-nav-color) !important;
}

.cst-header-auth-on #main-header #top-menu > li > a:hover,
.cst-header-auth-on #main-header #top-menu > li > a:focus,
.cst-header-auth-on #main-header #top-menu > li.et-hover > a,
.cst-header-auth-on #main-header .et_mobile_menu a:hover,
.cst-header-auth-on #main-header .et_mobile_menu a:focus {
	color: var(--cst-nav-hover) !important;
	opacity: 1 !important;
}

.cst-header-auth-on #main-header #top-menu > li.current-menu-item > a,
.cst-header-auth-on #main-header #top-menu > li.current_page_item > a,
.cst-header-auth-on #main-header #top-menu > li.current-menu-ancestor > a,
.cst-header-auth-on #main-header .et_mobile_menu .current-menu-item > a,
.cst-header-auth-on #main-header .et_mobile_menu .current_page_item > a {
	/* Texte actif bordeaux (pas de fond : hauteur menu Divi trop grande). */
	color: var(--cst-nav-active-bg) !important;
	font-weight: 600;
}

.cst-header-auth-on #main-header #top-menu li li a:hover,
.cst-header-auth-on #main-header #top-menu li li a:focus {
	color: var(--cst-nav-hover) !important;
	background-color: transparent !important;
}

.cst-header-auth-on #main-header .nav li ul,
.cst-header-auth-on #main-header .et_mobile_menu {
	border-color: var(--cst-nav-hover) !important;
}

.cst-header-auth-on #main-header .mobile_menu_bar:before,
.cst-header-auth-on #main-header .mobile_menu_bar:after {
	color: var(--cst-nav-color) !important;
}

.cst-header-auth-on #main-header #et_top_search {
	display: none !important;
}

/* Bouton « Faire un don » — même look qu’Astra header-button1 */
.cst-header-auth-on #main-header .cst-header-donate {
	flex: 0 0 auto;
	display: flex;
	align-items: center;
	margin-left: 0.75rem;
}

.cst-header-auth-on #main-header .cst-header-donate__btn {
	display: inline-block;
	padding: 10px 20px;
	border: none;
	border-radius: 40px;
	background-color: #ff6e34;
	color: #fff !important;
	font-size: 16px;
	font-weight: 500;
	line-height: 1.2;
	text-decoration: none !important;
	box-shadow: 2px 2px 10px rgba(0, 0, 0, 0.85);
	transition: background-color 0.15s ease, transform 0.15s ease, box-shadow 0.15s ease;
	white-space: nowrap;
}

.cst-header-auth-on #main-header .cst-header-donate__btn:hover,
.cst-header-auth-on #main-header .cst-header-donate__btn:focus {
	background-color: #e85f2a;
	color: #fff !important;
	outline: none;
	box-shadow: 2px 2px 12px rgba(0, 0, 0, 0.9);
}

.cst-header-auth-on #main-header .cst-header-auth {
	flex: 0 0 auto;
	display: flex;
	align-items: center;
	margin-left: 0.5rem;
}

.cst-header-auth-on #main-header .cst-header-auth__link {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 40px;
	height: 40px;
	color: var(--cst-nav-color);
	border-radius: 50%;
	text-decoration: none;
	transition: background-color 0.15s ease, color 0.15s ease;
}

.cst-header-auth-on #main-header .cst-header-auth__link:hover,
.cst-header-auth-on #main-header .cst-header-auth__link:focus {
	background-color: rgba(123, 10, 10, 0.08);
	color: var(--cst-nav-hover);
	outline: none;
}

.cst-header-auth-on #main-header .cst-header-auth__link svg {
	display: block;
}

/* Mobile : menu burger Divi à droite, auth à côté */
@media (max-width: 980px) {
	.cst-header-auth-on #main-header #top-menu-nav {
		display: none;
	}

	.cst-header-auth-on #main-header #et-top-navigation {
		justify-content: flex-end;
	}

	.cst-header-auth-on #main-header .cst-header-donate {
		margin-left: 0.35rem;
	}

	.cst-header-auth-on #main-header .cst-header-donate__btn {
		padding: 8px 14px;
		font-size: 14px;
	}

	.cst-header-auth-on #main-header .cst-header-auth {
		margin-left: 0.35rem;
		margin-right: 0.25rem;
	}
}
