
:root {
	--ccma-navbar-green: #6A855A;
	--ccma-navbar-cream: #F7F1E1;
}

/*******************  CCMA MEGA MENU OVERLAY  *********************************/

.ccma-navigation-overlay {
	min-height: 100vh;
	width: 100%;
	box-sizing: border-box;
	overflow-y: auto;
	z-index: 9999;
}

.ccma-navigation-overlay__top {
	width: 100%;
	box-sizing: border-box;
}

/** Icones NavBar Mega Menu **/

.ccma-navigation-overlay__top a.ccma-simple-svg-link:hover svg rect,
.ccma-navigation-overlay__top a.ccma-simple-svg-link:hover svg path,
.ccma-navigation-overlay__top button   {
	transition: all .2s ease;
}

.ccma-navigation-overlay__top a.ccma-simple-svg-link:hover svg rect   {
	fill: var(--wp--preset--color--vert-800);
}

.ccma-navigation-overlay__top a.ccma-simple-svg-link:hover svg path,
.ccma-navigation-overlay__top button:hover svg line  {
	fill: var(--wp--preset--color--beige);
}

.ccma-navigation-overlay__top button:hover {
	background-color: var(--wp--preset--color--vert-800)
}


/** Colonnes Mega Menu **/

.ccma-mega-menu-columns {
	box-sizing: border-box;
	width: 100%;
	padding: var(--wp--preset--spacing--50) var(--wp--preset--spacing--60);
	gap: var(--wp--preset--spacing--50);
}

.ccma-mega-menu-columns h2:hover a {
	text-decoration: none;
}

.ccma-mega-menu-columns .wp-block-page-list {
	margin: 0;
	padding-left: 0;
	list-style: none;
}

.ccma-mega-menu-columns .wp-block-page-list .wp-block-pages-list__item {
	padding-bottom: 0.2em;
	transition: all 0.2s ease-out;
}

.ccma-mega-menu-columns .wp-block-page-list .wp-block-pages-list__item:hover {
	color: var(--wp--preset--color--vert-900);
	padding-left: 1.25em;
	font-weight: 400 !important;
}

@media (max-width: 900px) {
	.ccma-mega-menu-columns {
		flex-direction: column;
		padding-right: var(--wp--preset--spacing--40);
		padding-left: var(--wp--preset--spacing--40);
	}

	.ccma-mega-menu-columns > .wp-block-column {
		flex-basis: 100% !important;
		width: 100%;
	}

	.ccma-mega-menu-column-large .wp-block-columns {
		flex-direction: column;
		gap: 0;
	}

	.ccma-mega-menu-column-large .wp-block-column {
		flex-basis: 100% !important;
		width: 100%;
	}
}

/* =========================
   Navigation overlay / mega-menu
========================= */

/* Le conteneur natif de la superposition doit passer au-dessus de toute la page */
.wp-block-navigation__responsive-container.is-menu-open {
	position: fixed !important;
	inset: 0 !important;
	z-index: 999999 !important;

	background-color: var(--wp--preset--color--beige) !important;
}

/* Le dialogue interne reste au-dessus du fond */
.wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__responsive-dialog {
	position: relative;
	z-index: 999;
}

/* Le contenu du mega-menu reste au-dessus de son propre fond */
.wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__responsive-container-content {
	position: relative;
	z-index: 3;
}

/* Bouton de fermeture au-dessus de tout le contenu du menu */
.wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__responsive-container-close {
	position: relative;
	z-index: 4;
}

/*********   CCMA MEGA MENU NAVIGATION BAR **********/

.ccma-navbar {
	width: 100%;
	box-sizing: border-box;
}

.ccma-mega-header__inner {
	width: 100%;
	box-sizing: border-box;
	padding-right: var(--wp--preset--spacing--60);
	padding-left: var(--wp--preset--spacing--60);
}

.ccma-mega-header__branding img {
	display: block;
	max-height: 90px;
	width: auto;
}

.ccma-mega-header__tools {
	gap: var(--wp--preset--spacing--30);
}

/* Bouton d'ouverture natif du bloc Navigation */
.ccma-mega-menu-navigation .wp-block-navigation__responsive-container-open {
	position: relative;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 69px;
	height: 45px;
	padding: 0;
	border: 0;
	border-radius: 15px;
	background: #D2DCCC;
	color: #6A855A;
	cursor: pointer;
}

/* On masque l'icône hamburger native */
.ccma-mega-menu-navigation .wp-block-navigation__responsive-container-open svg {
	display: none;
}

/* On recrée tes 3 lignes */
.ccma-mega-menu-navigation .wp-block-navigation__responsive-container-open::before {
	content: "";
	display: block;
	width: 34px;
	height: 20px;
	background:
		linear-gradient(#6A855A, #6A855A) 0 0 / 34px 2px no-repeat,
		linear-gradient(#6A855A, #6A855A) 0 9px / 34px 2px no-repeat,
		linear-gradient(#6A855A, #6A855A) 0 18px / 34px 2px no-repeat;
}

/* Évite que le conteneur responsive natif parasite ton affichage */


@media (max-width: 900px) {
	.ccma-mega-header__inner {
		padding-right: var(--wp--preset--spacing--40);
		padding-left: var(--wp--preset--spacing--40);
	}

	.ccma-mega-header__tools {
		gap: var(--wp--preset--spacing--20);
	}

	.ccma-mega-header__tools .wp-block-search {
		max-width: 220px;
	}
}

/**** CCMA MEGA MENU NAVIGATION BAR - CLOSE ****/

.ccma-overlay-close,
.ccma-overlay-close button,
.ccma-overlay-close .wp-block-navigation-overlay-close {
	position: relative;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 45px;
	height: 45px;
	padding: 0;
	margin: 0;
	border: 0;
	background: transparent;
	color: transparent;
	font-size: 0;
	line-height: 0;
	cursor: pointer;
}

.ccma-overlay-close::before,
.ccma-overlay-close button::before,
.ccma-overlay-close .wp-block-navigation-overlay-close::before {
	content: "";
	display: block;
	width: 45px;
	height: 45px;
	background-repeat: no-repeat;
	background-position: center;
	background-size: contain;
	background-image: url("data:image/svg+xml,%3Csvg width='45' height='45' viewBox='0 0 45 45' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Crect width='44.0417' height='45' rx='15' fill='%23D2DCCC'/%3E%3Cline y1='-1' x2='34' y2='-1' transform='matrix(-0.707107 -0.707107 -0.707107 0.707107 34.0417 35.0416)' stroke='%236A855A' stroke-width='2'/%3E%3Cline y1='-1' x2='34' y2='-1' transform='matrix(0.707107 -0.707107 -0.707107 -0.707107 10 34)' stroke='%236A855A' stroke-width='2'/%3E%3C/svg%3E");
}

.ccma-overlay-close svg {
	display: none;
}

.ccma-mega-menu-navigation {
	position: relative;
	z-index: 10;
}


.ccma-mega-menu-overlay {
	top: calc(var(--ccma-header-height, 0px) + var(--ccma-adminbar-offset, 0px)) !important;
}

.ccma-mega-menu-overlay {
	top: var(--ccma-header-height, 0px);
}

/* mega menu overlay */

section.ccma-mega-menu {
	position: fixed;
	inset: 0;
	z-index: 9999;
	top: 0;
	left: 0;
	width: 100%;
	margin-top: 0 !important;
	opacity: 0;
	visibility: hidden;
	pointer-events: none;
	transition:
		opacity 0.25s ease,
		transform 0.25s ease,
		visibility 0s linear 0.25s;
	background-color: var(--wp--preset--color--vert) !important;
}


.ccma-mega-menu.is-open {
	display: block;
}


.ccma-mega-menu-content {
	min-height: 100dvh;
	height: 100dvh;
	display: flex;
	flex-direction: column;
	overflow-y: auto;
	box-sizing: border-box;
	z-index: 9999;
}

.ccma-mega-menu-content h2 a{
	font-family: var(--wp--preset--font-family--sagace);
	font-weight: 400;
	font-style: Medium;
	font-size: 18px;
	line-height: 23px;
	letter-spacing: 0px;
	vertical-align: middle;

}
.ccma-mega-menu-content h3 a{
	font-family: var(--wp--preset--font-family--sagace);
	font-weight: 400;
	font-style: Medium;
	font-size: 14px;
	line-height: 18px;
	letter-spacing: 0px;
	vertical-align: middle;

}

.ccma-mega-menu-content h2 + ul, .ccma-mega-menu-content h3 + ul {
	font-family: Sagace;
	font-style: Regular;
	font-weight: 400;
	font-size: 12px;
	line-height: 15px;
	letter-spacing: 0px;
	vertical-align: middle;

}

.ccma-mega-menu-content h2 {
	font-family: var(--wp--preset--font-family--sagace);
	text-decoration: underline;
    text-decoration-color: currentcolor;
    text-decoration-thickness: auto;
	text-decoration-color: currentcolor;
	text-decoration-thickness: auto;
	text-decoration-thickness: 35%;
	-webkit-text-decoration-color: var(--wp-preset--color--vert-800, #3A4932);
	-webkit-text-decoration-color: var(--wp-preset--color--vert-800, #3A4932);
	text-decoration-color: var(--wp-preset--color--vert-800, #3A4932);
	text-underline-offset: -11%;
	-webkit-text-decoration-skip-ink: none;
	text-decoration-skip-ink: none;
	padding-bottom: 1em;
}

.ccma-mega-menu-content h3 {
	padding-bottom: 0.4em;
}

.ccma-mega-menu-columns {
	flex: 1 1 auto;
	align-content: start;
}

section.ccma-mega-menu.is-open {
	opacity: 1;
	visibility: visible;
	pointer-events: auto;
	transform: translateY(0);
	transition:
		opacity 0.25s ease,
		transform 0.25s ease,
		visibility 0s linear 0s;
}

.ccma-mega-menu-block {
	display: none;
}

.ccma-mega-menu-columns {
	padding-top: 1.2rem;
	margin-block-start: 0 !important;
}

.ccma-mega-menu {
	position: fixed;
	inset: 0;
	z-index: 9999;
	background: rgba(0, 0, 0, 0.12);
	margin-block-start: 0 !important;
}

.ccma-mega-menu__inner {
	position: relative;
	min-height: 100vh;
	background: #6a855a;
	overflow-y: auto;
}

.ccma-mega-menu-toggle {
	background: transparent;
	border: 0;
	padding: 0;
	cursor: pointer;
	height: 45px !important;
}

.ccma-mega-menu-toggle__svg {
	display: block;
	width: 69px !important;
	height: auto;
}

.ccma-mega-menu-close {
	background: transparent;
	border: 0;
	font-size: 2rem;
	cursor: pointer;
}

body.ccma-mega-menu-open {
	overflow: hidden;
}

@media only screen and (min-device-width : 980px) {
	.ccma-mega-menu .wp-block-group-is-layout-grid {
		grid-template-columns: repeat(3, minmax(0, 1fr));
	}
	.ccma-query-children-of-current-page.grand-childs ul {
		grid-template-columns: repeat(5, minmax(0, 1fr));
	}
}

@media only screen and (max-device-width : 980px) {
	.ccma-mega-menu .wp-block-group-is-layout-grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}
	.ccma-query-children-of-current-page.grand-childs ul {
		grid-template-columns: repeat(3, minmax(0, 1fr));
	}
}

@media only screen and (max-device-width : 480px) {
	.ccma-mega-menu .wp-block-group-is-layout-grid {
		grid-template-columns: repeat(1, minmax(0, 1fr));
	}
	.ccma-query-children-of-current-page.grand-childs ul {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}
}

.ccma-page-list-parent {
	margin-bottom: 15px;
}

.ccma-page-list-parent-title {
	margin: 0;
}

.ccma-page-list-parent-title a {
	font-family: var(--wp--preset--font-family--sagace) !important;
	color: var(--wp--preset--color--beige) !important;
	font-size: var(--wp--preset--font-size--small) !important;
	font-weight: 800 !important;
	line-height: 1em;
	text-decoration: none;
}

.ccma-page-list-parent-title a:hover {
	text-decoration: underline solid inherit 2px !important;
	color: var(--wp--preset--color--beige) !important;
}

.wp-block-pages-list__item.has-child {
	font-weight: 500 !important;
	font-size: var(--wp--preset--font-size--small) !important;
	padding-bottom: 21px !important;
}

a.wp-block-pages-list__item__link {
	/*font-size: inherit;
	font-weight: inherit;
	font-family: inherit;*/
	color: inherit;
	text-decoration: none;
}

ul.wp-block-page-list, ul.wp-block-navigation__submenu-container {
	list-style: none;
	padding-left: 0;
}

.ccma-mega-menu h4 a {
  display: inline;
  background-image: linear-gradient(var(--wp--preset--color--vert-900), var(--wp--preset--color--vert-900));
  background-repeat: no-repeat;
  background-position: 0 80%;
  background-size: 100% 0.3em;
}

.ccma-mega-menu h4 a:hover {
  text-decoration: none !important;
  background-image: linear-gradient(var(--wp--preset--color--vert-900), var(--wp--preset--color--vert-900));
}

.ccma-mega-menu a {
	text-decoration: none !important;
}

.ccma-mega-menu a:hover {
	text-decoration: underline !important;
}



.ccma-mega-menu  h4 a {
  display: inline;
  background-image: linear-gradient(var(--wp--preset--color--vert-900), var(--wp--preset--color--vert-900));
  background-repeat: no-repeat;
  background-position: 0 88%;
  background-size: 100% 0.35em;
  text-decoration: none !important;
}

.ccma-mega-menu h4 a:hover {
  text-decoration: none !important;

}

.ccma-mega-menu a {
	text-decoration: none !important;
}

.ccma-mega-menu a:hover {
	text-decoration: underline !important;
}


/******************  CCMA MEGA-MENU CLOSE BUTTON  *********************************/

/* =========================
   Mega-menu close toggle
========================= */

.ccma-mega-menu-close-toggle {
	display: inline-flex;
	align-items: center;
	justify-content: center;

	width: 45px;
	height: 45px;

	padding: 0;
	margin: 0;

	border: 0;
	border-radius: 15px;

	
	background-color: #d2dccc;
	color: var(--wp--preset--color--vert);

	cursor: pointer;
}

.ccma-mega-menu-close-toggle__icon {
	display: grid;
	place-items: center;

	width: 45px;
	height: 45px;

	line-height: 0;
	color: inherit;
}

.ccma-mega-menu-close-toggle__icon svg {
	display: block;
	width: 26px;
	height: 26px;
	color: currentColor;
	stroke: var(--wp--preset--color--vert);
	stroke-width: 2px;
}

.ccma-mega-menu-close-toggle__icon:hover svg {
	stroke: var(--wp--preset--color--beige);
}

/*.ccma-mega-menu-close-toggle:hover,
.ccma-mega-menu-close-toggle:focus-visible {
	background-color: #d2dccc;
	color: var(--wp--preset--color--vert);
}*/

.ccma-mega-menu-close-toggle:focus-visible {
	outline: 2px solid currentColor;
	outline-offset: 3px;
}


/*********** CCMA MEGA MENU NAVBAR SEARCH BLOCK OVERRIDE  *********************************/

header nav .ccma-mega-menu-content .wp-block-search__button-inside .wp-block-search__inside-wrapper {
	border: 0;
	border-radius: 15px !important;
	height: 45px !important;
	background-color: var(--wp--preset--color--beige) !important;
}

header nav .ccma-mega-menu-content .wp-block-search__input {
	font-weight: 400;
	/*padding-bottom: 0.5em;*/
}

header nav .ccma-mega-menu-content .wp-block-search__button-inside .wp-block-search__inside-wrapper button {
	border: 0;
	background: var(--wp--preset--color--beige) !important;
	color: var(--wp--preset--color--vert) !important;
}

header nav .ccma-mega-menu-content .wp-block-search__button-inside.wp-block-search__icon-button.wp-block-search {
  width: 34.653vw;
}


.ccma-mega-menu-content .ccma-mega-menu-columns ul li a {
	font-size: inherit;
	font-weight: inherit;
	font-family: inherit;
	color: inherit;
	text-decoration: none;
    text-decoration-thickness: auto;
}

.ccma-mega-menu-smartphone h2 {
	text-decoration-thickness: 60%;
	text-underline-offset: -15%;
}

.ccma-mega-menu-smartphone .wp-block-pages-list__item {
	margin-top: 0;
	margin-bottom: 0;
	padding-top: 0;
	padding-bottom: 0;
	font-style: normal;
	font-weight: 300;
	font-family: var(--wp--preset--font-family--sagace) !important;
	font-size: var(--wp--preset--font-size--body-small) !important;
	line-height: 1.25em;
	letter-spacing: 0px;
	padding-bottom: .25em !important;
}