/******************************

TABLE OF CONTENTS :

- DIVI COMMUNITY
- MENU
- HEADER
- FOOTER
- HOME HEADER
- POST CONTENT
- POST
- FORMINATOR
- MEDIA QUERIES

******************************/





/******************************

DIVI COMMUNITY

******************************/

/* 
** CENTRER DU CONTENU VERTICALEMENT 
** Voir tuto : https://www.divi-community.fr/snippets-divi/centrer-du-contenu-verticalement
*/

.dc-centrer-verticalement {
	display: flex;
	flex-direction: column;
	justify-content: center;
  	display: -webkit-box;
	display: -webkit-flex;
	display: -moz-box;
	display: -ms-flexbox;
	-webkit-box-orient: vertical;
	-webkit-box-direction: normal;
	-webkit-flex-direction: column;
	 -moz-box-orient: vertical;
	 -moz-box-direction: normal;
	  -ms-flex-direction: column;
	-webkit-box-pack: center;
	-webkit-justify-content: center;
	-moz-box-pack: center;
	-ms-flex-pack: center;
}


/*
** INVERSER LE SENS DES COLONNES SUR MOBILE
** Voir tuto : https://www.divi-community.fr/snippets-divi/inverser-ordre-des-colonnes-sur-mobile
*/

@media only screen and (max-width : 980px) {
	.dc-inverser-colonnes--section .dc-inverser-colonnes--ligne {
		display: -webkit-flex;
		display: -ms-flex;
		display: flex;
		-webkit-flex-direction: column-reverse;
		-ms-flex-direction: column-reverse;
		flex-direction: column-reverse;
	}
}


/*
** MENU MOBILE : en pleine largeur et le hamburger devient une croix pour fermer
*/

/* .et_mobile_menu {
	margin-left: -30px;
	padding: 5%;
	width: calc( 100% + 60px);
} */

.mobile_nav.opened .mobile_menu_bar:before {
	content: "\4d";
}


/* 
** AUGMENTER LA LARGEUR CHAMP RÉSULTAT CAPTCHA 
** Parfois, suivant la taille du texte, certains chiffres du résultat sont masqués
*/
.et_pb_contact_right p input {
	max-width: 50px;
}


/*
** METTRE EXPOSANTS ET INDICES À LA BONNE TAILLE
** Généralement, ils sont bien trop gros…
*/
sup, sub {
    font-size: 70%;
}





/******************************

ROOT

******************************/

:root {
    --black: #162430;
    --blue: #79cfe2;
}





/******************************

MENU

******************************/

/* MENU ITEM */

.menu-item a {
    background-color: transparent !important;
    padding-top: 10px !important;
    padding-bottom: 10px !important;
    padding-left: 0 !important;
    position: relative;
}

.menu-item a::before {
    background-color: var(--black);
    bottom: 0;
    border-radius: 3px;
    content: '';
    height: 2px;
    left: 0;
    position: absolute;
    transition: transform .3s;
    transform: scaleX(0);
    transform-origin: 0 50%;
    width: 100%;
}

.current-menu-parent > a::before,
.current-menu-item a::before,
.menu-item a:hover::before {
    transform: scaleX(1);
}


/* MENU ITEM HAS CHILDREN */

.menu-item-has-children > a::before {
    width: calc(100% - 20px);
}


/* SUB MENU */

.sub-menu {
    box-shadow: 0 0 10px rgba(0,0,0,0.16) !important;
    padding: 10px !important;
}


/* SUB MENU ITEM */

/* .sub-menu .menu-item a {
    display: inline-block;
    padding: 0;
    width: auto;
} */

/* .menu-item a:hover {
    background-color: transparent !important;
} */




/******************************

HEADER

******************************/

.et-l--header .et-menu > .menu-item {
    padding-bottom: 30px !important;
    padding-top: 30px !important;
}

.et-l--header .sub-menu {
    width: 100% !important;
}

.et-l--header .sub-menu .menu-item {
    padding: 0;
}

.et-l--header .sub-menu .menu-item a {
    box-shadow: 0 0 10px rgba(0,0,0,0.16);
    padding: 10px !important;
    width: 100%;
}


/* WPML */

.wpml-ls {
    border: 0;
    padding: 0;
}

.wpml-ls > ul {
    margin: 0 -5px !important;
    padding: 0;
}

.wpml-ls-link {
    border: 1px solid #000;
    border-radius: 50%;
    overflow: hidden;
    padding: 0 !important;
    position: relative;
    transition: outline-width .05s;
}

.wpml-ls-flag {
    height: 28px;
    object-fit: cover;
    width: 30px;
}


/* MOBILE */

.header-mobile .et_pb_column {
    align-items: center;
    display: flex;
}

.header-mobile__row .et_pb_column,
.header-mobile__row .et_pb_menu,
.header-mobile__row .et_pb_menu_inner_container {
    position: static;
}

.header-mobile .sub-menu .menu-item + .menu-item {
    margin-top: 10px;
}

.header-mobile .sub-menu .menu-item a {
    min-height: 100px;
}

.header-mobile .et_mobile_menu {
  height: calc(100vh - 100%);
  overflow-y: scroll;
}

.header-mobile__wpml {
    flex-shrink: 0;
}

.header-mobile .wpml-ls > ul {
    background-color: #fff;
    border-radius: 10px;
    box-shadow: 0 0 10px rgba(0,0,0,0.16);
    display: flex;
    flex-direction: column;
    left: 0;
    position: absolute;
    top: 0;
    width: 100%;
}

.header-mobile .wpml-ls-item {
    order: 2;
}

.header-mobile .wpml-ls-current-language {
    order: 1;
    padding: 10px !important;
    pointer-events: none;
}

.header-mobile .wpml-ls-item:not(.wpml-ls-current-language) {
    height: 0;
    overflow: hidden;
}

.header-mobile .wpml-ls.is-open .wpml-ls-item:not(.wpml-ls-current-language) {
    border-top: 1px solid var(--black);
    height: auto;
    padding: 10px !important;
} 


/* DESKTOP */

.header-desktop .menu-item-has-children {
    position: static !important;
}

.header-desktop .sub-menu {
    column-gap: 20px;
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    padding: 50px !important;
}

.header-desktop .sub-menu .menu-item a {
    min-height: 200px;
}


/* .header-desktop .wpml-ls-link {
    outline: 1px solid #000;
}  */





/******************************

FOOTER

******************************/

.et-l--footer .et-menu {
    flex-direction: column;
}

.et-l--footer .et_mobile_nav_menu {
    display: none;
}

.et-l--footer .et_pb_menu__menu {
    display: block;
}

.footer__bottom .et_pb_column {
    display: flex;
    flex-direction: initial;
}





/******************************

HOME HEADER

******************************/

.home-header__text-true {
    opacity: 0;
    transition: opacity .3s;
}

.home-header__toggle-btn {
    appearance: none;
    background: none;
    border: none;
    border: 12px solid #fff;
    border-radius: 100px;
    box-sizing: content-box;
    cursor: pointer;
    font-size: 0;
    height: 60px;
    padding: 0;
    position: relative;
    transition: opacity .3s;
    width: 110px;
}

.home-header__toggle-btn::before,
.home-header__toggle-btn::after {
    background: #fff center no-repeat;
    border-radius: 50%;
    content: '';
    height: 50px;
    left: 5px;
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    transition: transform .3s, opacity .3s;
    width: 50px;
}

.home-header__toggle-btn::before {
    background-image: url('/wp-content/themes/lesapprimeurs/images/dots.svg');
    background-size: 60%;
}

.home-header__toggle-btn::after {
    background-image: url('/wp-content/themes/lesapprimeurs/images/tick.svg');
    background-size: 50%;
    opacity: 0;
}

.home-header__toggle-btn:hover {
    opacity: .8;
}

.home-header__character {
    transition: transform .5s cubic-bezier(1.00,0.00,0.00,1.00);
}

.home-header__character-reactions {
    transition: transform .7s cubic-bezier(.47,1.64,.41,.8);
}


/* IS CLEAR */

.home-header.is-clear .home-header__text-true {
    opacity: 1;
}

.home-header.is-clear .home-header__toggle-btn::before,
.home-header.is-clear .home-header__toggle-btn::after {
    transform: translate(100%, -50%);
}

.home-header.is-clear .home-header__toggle-btn::before {
    opacity: 0;
}

.home-header.is-clear .home-header__toggle-btn::after {
    opacity: 1;
}

.home-header.is-clear .home-header__character {
    transform: rotate(-180deg);
}

.home-header.is-clear .home-header__character-reactions {
    transform: rotate(-180deg);
}





/******************************

WP GRID BUILDER

******************************/

.wpgb-card-layer-link {
    pointer-events: initial !important;
}

.wpgb-card-media-overlay::after {
    background: url('/wp-content/themes/lesapprimeurs/images/trame_black.png') right bottom/contain no-repeat;
    bottom: 0;
    content: '';
    height: 80%;
    position: absolute;
    right: 0;
    /* transition: transform .3s;
    transform-origin: 100% 100%; */
    width: 80%;
}

/* .wpgb-card:hover .wpgb-card-media-overlay::after {
    transform: scale(.8);
} */

.wpgb-card-media-thumbnail div {
    transition: transform .3s !important;
}

.wpgb-card:hover .wpgb-card-media-thumbnail div {
    transform: scale(1.2);
}

.wpgb-card-body {
    display: flex;
    flex-direction: column;
}

.wpgb-block-3 {
    margin-top: auto;
}





/******************************

POST CONTENT

******************************/

.et_pb_post_content * {
    padding-bottom: 0;
}

.et_pb_post_content > *:first-child {
    margin-top: 0;
}

.et_pb_post_content > *:last-child {
    margin-bottom: 0;
}

.et_pb_post_content h2,
.et_pb_post_content h3,
.et_pb_post_content h4 {
    margin-top: 1.3em;
    margin-bottom: .3em;
}

.et_pb_post_content p {
    margin-top: 1em;
}

.et_pb_post_content a {
    text-underline-offset: 3px;
    text-decoration-thickness: 1.5px !important;
}

.et_pb_post_content ul {
    margin-top: 1em;
    padding-bottom: 0;
}

.et_pb_post_content blockquote {
    border: none;
    margin-top: 1.6em;
    margin-bottom: 1.6em;
    padding-left: 0;
    position: relative;
}

.et_pb_post_content cite {
    font-size: 1.25rem;
    line-height: 1.5;
    margin-top: 1.5em;
    padding-right: 270px;
}

/* .et_pb_post_content .wp-block-columns {
    margin-top: 2.5em;
    margin-bottom: 2.5em;
}

.et_pb_post_content .wp-block-columns figure {
    margin: 0;
} */

.et_pb_post_content > figure {
    margin: 2.5em -50px;
    text-align: center;
}

.et_pb_post_content figcaption {
    margin-bottom: 0;
    text-align: left;
}

.et_pb_post_content figcaption a {
    font-size: .8rem;
}

.et_pb_post_content sup {
    margin-top: 2.5em;
    margin-bottom: 2.5em;
}





/******************************

POST

******************************/

.post__image .et_pb_column::before {
    background-color: var(--blue);
    content: '';
    height: 100%;
    left: 0;
    mix-blend-mode: multiply;
    position: absolute;
    top: 0;
    width: 100%;
    z-index: 1;
}

.post__image .et_pb_column::after {
    background: url('/wp-content/themes/lesapprimeurs/images/trame_black.png') right bottom/contain no-repeat;
    bottom: 0;
    content: '';
    height: 80%;
    position: absolute;
    right: 0;
    width: 80%;
    z-index: 2;
}

.post__body p:first-child {
    font-size: 1.5rem;
}





/******************************

FIRST PARAGRAPH

******************************/

.first-paragraph-bigger p:first-child {
    font-size: 1.5rem;
    line-height: 1.5;
}





/******************************

FORMINATOR

******************************/

.forminator-button {
    border-radius: 50px !important;
    border: 2px solid var(--black) !important;
    box-shadow: none !important;
    padding: 12px 24px !important;
}

.forminator-checkbox__wrapper p {
    margin-top: 0;
}





/******************************

MEDIA QUERIES

******************************/

@media (min-width: 981px) {

    /******************************
    MENU
    ******************************/

    .menu-item a {
        padding-top: 0 !important;
        padding-bottom: 0 !important;
    }

    
    /******************************
    HEADER
    ******************************/

    /* WPML */

    .wpml-ls-item {
        margin: 0 5px !important;
    }

    .wpml-ls-flag {
        height: 40px;
        width: 40px;
    }

    
    /******************************
    FOOTER
    ******************************/
    
    .footer__bottom .et_pb_column:nth-child(3) {
        flex-direction: column-reverse;
    }

}
