/* --- BARRE D'ADMIN ------------------------------------------------------------------------------------------------------------------- */

/* Masque certains boutons de la barre d'admin */
#wp-admin-bar-site-editor,
#wp-admin-bar-customize,
#wp-admin-bar-comments,
#wp-admin-bar-new-post,
#wp-admin-bar-new-media,
#wp-admin-bar-appearance,
#wp-admin-bar-search{
	display: none !important;
}

/* définit une variable globale contenant la hauteur de la barre d'admin (facilite l'adaptation de certains blocks : header, menu, content, ...) */
body{
	--admin-bar-height: 0px;
}
body.admin-bar{
	--admin-bar-height: 32px;
}
@media (max-width: 782px) {

	body.admin-bar{
		--admin-bar-height: 46px;
	}

}

/* Maintient la barre d'admin en position fixed au format mobile */
@media (max-width: 600px) {

    #wpadminbar{
        position: fixed !important;
    }

}


/* --- SUPPRESSION DES MARGES PAR DÉFAUT ENTRE LES ÉLÉMENTS DE PREMIER NIVEAU ---------------------------------------------------------- */

/* WordPress ajoute 24px entre les éléments de premier niveau mais il est préférable de les gérer au niveau des éléments eux-mêmes (footer notamment). */
:where(.wp-site-blocks) > *{
    margin-block-start: 0 !important;
}