/* ─────────────────────────────────────────────────────────────────────────────
 * Top bar (widget ElementsKit « Page List » avec la classe .top-bar-menu)
 * Sur mobile, on remplace l'empilement vertical par défaut par un burger qui
 * ouvre un panneau plein écran (comme la barre de menu principale).
 * ────────────────────────────────────────────────────────────────────────── */

/* Verrou du scroll pendant que le panneau plein écran est ouvert (posé par top-bar.js) */
body.top-bar-open-lock {
	overflow: hidden;
}

/* Bouton burger : masqué sur desktop, injecté par top-bar.js */
.top-bar-menu .top-bar-burger {
	display: none;
	width: 40px;
	height: 40px;
	padding: 0;
	margin: 0;
	background: transparent;
	border: 0;
	cursor: pointer;
	align-items: center;
	justify-content: center;
	flex-direction: column;
	gap: 5px;
}

/* Neutralise la règle globale button:hover/:focus de reset.css (fond #c36) */
.top-bar-menu .top-bar-burger:hover,
.top-bar-menu .top-bar-burger:focus,
.top-bar-menu .top-bar-burger:active {
	background: transparent;
	color: inherit;
	outline: none;
	box-shadow: none;
}

.top-bar-menu .top-bar-burger span {
	display: block;
	width: 22px;
	height: 2px;
	background: #ffffff;
	transition: transform 0.2s ease, opacity 0.2s ease;
}

/* Animation du burger en croix quand le menu est ouvert */
.top-bar-menu.top-bar-menu--open .top-bar-burger span:nth-child(1) {
	transform: translateY(7px) rotate(45deg);
}
.top-bar-menu.top-bar-menu--open .top-bar-burger span:nth-child(2) {
	opacity: 0;
}
.top-bar-menu.top-bar-menu--open .top-bar-burger span:nth-child(3) {
	transform: translateY(-7px) rotate(-45deg);
}

/* ─── Responsive : passage en burger (≤ 780px) ──────────────────────────────── */
@media (max-width: 780px) {

	.top-bar-menu .top-bar-burger {
		display: inline-flex;
	}

	/* Le burger reste aligné à droite dans la barre */
	.top-bar-menu .ekit-wid-con {
		display: flex;
		justify-content: flex-end;
	}

	/* La liste des pages devient un panneau plein écran masqué par défaut.
	 * --top-bar-top (hauteur du bandeau header) est posé par top-bar.js à
	 * l'ouverture. .top-bar-menu__list est ajoutée par top-bar.js sur le conteneur
	 * réel des liens (indépendant des classes internes d'ElementsKit). */
	.top-bar-menu .top-bar-menu__list {
		display: none !important;
		position: fixed;
		top: var(--top-bar-top, 0px);
		left: 0;
		right: 0;
		bottom: 0;
		z-index: 1000;
		margin: 0;
		padding: 24px 20px;
		background: rgba(30, 30, 30, 0.7);
		backdrop-filter: blur(20px);
		-webkit-backdrop-filter: blur(20px);
		flex-direction: column;
		overflow-y: auto;
	}

	.top-bar-menu.top-bar-menu--open .top-bar-menu__list {
		display: flex !important;
	}

	/* Chaque entrée sur toute la largeur du panneau */
	.top-bar-menu .top-bar-menu__list .elementor-icon-list-item {
		width: 100%;
		margin: 0;
	}

	.top-bar-menu .top-bar-menu__list .elementor-icon-list-item a {
		display: flex;
		width: 100%;
		padding: 10px 20px;
	}

	/* Bouton « Aperam Corporate Website » déplacé dans le panneau (sous les pages).
	 * .top-bar-menu__corpo est ajoutée par top-bar.js sur le widget bouton. */
	.top-bar-menu .top-bar-menu__list .top-bar-menu__corpo {
		width: 100%;
		margin-top: 6px;
		padding: 12px 20px;
	}

	.top-bar-menu .top-bar-menu__list .top-bar-menu__corpo .elementor-button {
		justify-content: center;
	}
}
