﻿/*
    Styles CSS menu.
*/

/******************************************************************* 
	The menu is based from the SuperFish menu
	Thanks to http://users.tpg.com.au/j_birch/plugins/superfish/
********************************************************************/


/*  PROPRIÉTÉS DE DÉFAUTS POUR TOUS LES NIVEAUX */
.sf-menu, .sf-menu * {
    list-style: none;
}

    .sf-menu a {
        display: block;
        position: relative;
        color: #404040;
        outline: none;
        text-decoration: none;
    }

    .sf-menu li {
        float: left;
        position: relative;
    }


        .sf-menu li.separator {
            border-bottom: 1px solid #E2E4E6;
        }



/* CONTENEUR PRINCIPAL - PREMIER NIVEAU DE MENU */

.sf-menu {
    font-size: 14px;
    float: left;
    margin: 0;
    padding: 0;
    margin-bottom: 1em;
    line-height: 50px;
}

    .sf-menu li:hover,
    .sf-menu a:hover {
        color: #404040;
    }

    .sf-menu li a:hover {
        background-color: #F7F7F7;
        box-shadow: 0px 2px 4px rgba(176, 176, 176, 0.3);
    }

    /*  CONTENEUR SECONDAIRE - DEUXIÈME NIVEAU DE MENU */
    .sf-menu ul {
        position: absolute;
        top: -999em;
        width: 200px;
        padding: 0px 0px 0px 0px;
        line-height: 14px;
        font-size: 12px;
        background-color: #F7F7F7;
        box-shadow: 0px 2px 4px rgba(176,176,176,0.3);
        border-radius: 6px;
        font-weight: 400;
        font-style: normal;
        border: 1px solid #B0B0B0;
    }

        .sf-menu ul ul {
            border-left: 1px solid #333;
        }

    /*  Positionnement du premier niveau de sous-menu sous le menu principal et aligné à sa gauche */
    .sf-menu li.sfHover ul {
        left: 0px;
        top: 50px;
        z-index: 99;
    }


        .sf-menu li.sfHover ul .merge-menu {
            left: -165px;
            top: 50px;
            z-index: 99;
        }

    /* Gestion de l'espacement des éléments des sous-menus */
    .sf-menu ul li {
        width: 100%;
    }

        .sf-menu ul li a {
            padding: 12px 16px;
        }


/*  Positionnement du deuxième niveau de sous-menu (à compléter) */
ul.sf-menu li li.sfHover li ul {
    top: -999em;
}

ul.sf-menu li.sfHover li ul {
    top: -999em;
}

/*  Décalé vers le haut pour s'aligner avec le sous-menu appelant  */
ul.sf-menu li li.sfHover ul {
    left: 200px;
    top: -6px;
}


/*  Survol de la souris sur les éléments des sous-menus 
    Lors du survol du premier niveau, on s'assure de ne pas affecter le deuxième niveau.
    On applique donc les propriétés que sur l'hyperlien */
.sf-menu ul li:hover > a {
    background-color: #E2E4E6;
}

.sf-menu ul li ul li:hover a {
    background-color: #E2E4E6;
}

/*  Les éléments sélectionnés ont un fond noir 
    On s'assure que l'application n'affecte pas les enfants de cet élément. */
.sf-menu ul li.sfHover > a {
    color: #333;
    font-weight: bold;
}

.sf-menu ul li.sfHover:hover > a {
    background-color: #E2E4E6;
}

.sf-menu ul li:first-child a {
    border-top-right-radius: 6px;
    border-top-left-radius: 6px;
}

.sf-menu ul li:last-child a {
    border-bottom-right-radius: 6px;
    border-bottom-left-radius: 6px;
}

.sf-menu ul li:first-child a:hover {
    border-top-right-radius: 6px;
    border-top-left-radius: 6px;
}

.sf-menu ul li:last-child a:hover {
    border-bottom-right-radius: 6px;
    border-bottom-left-radius: 6px;
}

/*  Petite flèche sur le top des sous-menus */
.sf-menu ul:before {
    position: absolute;
    content: '';
    height: 8px;
    width: 8px;
    background: #F7F7F7;
    right: 15px;
    top: -5px;
    transform: rotate(45deg);
    z-index: -1;
    border: 1px solid #B0B0B0;
    border-style: solid none none solid;
}


/* Gestion des flèches des sous-menus */
.sf-sub-indicator {
    position: absolute;
    display: block;
    background: url('../imgs/CGI/MenuArrows.png') no-repeat 0 -12px;
    right: 8px;
    top: 6px;
    width: 10px;
    height: 12px;
    text-indent: -999em;
    overflow: hidden;
}

.sf-menu ul li:hover > a > .sf-sub-indicator {
    background-position: 0 0;
}

.sf-menu ul li.sfHover > a > .sf-sub-indicator {
    background-position: 0 -12px;
}

.sf-menu ul li.sfHover:hover > a > .sf-sub-indicator {
    background-position: 0 0;
}



.sf-menu a.sf-with-ul {
    padding-right: 2.25em;
    min-width: 1px; /* trigger IE7 hasLayout so spans position accurately */
}



/* MENUS UTILITAIRES SOUS FORMES D'ICONES (A LA DROITE DE LA BANNIÈRE) */


/* Positionnement des menus (aligné à la droite directement sous le menu principal)
    La position de gauche est calculé de la façon suvante :
    -200px (largeur du menu) + 64px (largeur de l'icone parent 2plus le padding et les bordures) 
 */
#OptionMenu ul {
    left: -155px;
    z-index: 99;
}

#OptionMenu li.sfHover ul {
    top: 53px;
}

.sf-menu .icon {
    display: block;
    padding: 0px;
    top: 8px;
    width: 34px;
    height: 34px;
}

    .sf-menu .icon:hover {
        background: #ffffff;
    }

    .sf-menu .icon a:hover {
        background-color: #F7F7F7;
        border: 1px solid #B0B0B0;
        border-radius: 6px;
        box-shadow: 0px 2px 4px rgba(176, 176, 176, 0.3);
    }

.sf-menu li.sfHover .icon a {
    background-color: #F7F7F7;
    border: 1px solid #B0B0B0;
    border-radius: 6px;
    box-shadow: 0px 2px 4px rgba(176, 176, 176, 0.3);
}

/* Affichage des image selon l'état du menu */

.sf-menu a.Profil {
    width: 34px;
    height: 34px;
    background: url(../imgs/CGI/MenuProfile.svg) no-repeat;
    background-position: center;
}

.sf-menu a.Help {
    width: 34px;
    height: 34px;
    background: url(../imgs/CGI/MenuHelp.svg) no-repeat;
    background-position: center;
}

.sf-menu a.Quit {
    width: 34px;
    height: 34px;
    background: url(../imgs/CGI/MenuQuit.svg) no-repeat;
    background-position: center;
}

/* Affichage du toolTip des options du top-menu */
.sf-menu .icon:hover .iconTooltip {
    display: block;
    margin-top: 135%;
    margin-left: -60px;
    line-height: 0px;
    white-space: nowrap;
    padding: 14px;
    height: 31px;
}


.sf-menu .sfHover:hover .iconTooltip {
    display: none;
    visibility: hidden;
    opacity: 0;
}

.sf-menu .icon .iconTooltip::after {
    content: " ";
    position: absolute;
    bottom: 85%;
    height: 7px;
    width: 7px;
    margin-left: -7px;
    border-width: 1px;
    border-style: solid;
    background: #404040;
    transform: rotate(225deg);
    border-color: transparent transparent transparent transparent;
    box-shadow: 1px 1px rgb(176 176 176 / 50%);
}

/* Ajustement de la 'responsivite' du menu des options */
@media (max-width: 560px) {
    .sf-menu ul {
        width: 196px;
    }

    .sf-menu a {
        padding: 0 10px;
    }

    .merge-menu-head {
        padding: 0;
    }
}

/************************* Menu Lateral *************************/
/****** Hamburger Icon ******/
#hamb {
    position: fixed;
    top: 0px;
    left: 0px;
    width: 54px;
    height: 50px;
    border-right: 1px solid;
    border-bottom: 1px solid;
    border-color: #E2E4E6;
    background: #F7F7F7;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
}

    #hamb.sm-active {
        background: #E2E4E6;
        border-color: #B0B0B0;
    }

/****** Icon Menu ******/
#iconMenu {
    position: fixed;
    top: 51px;
    left: 0px;
    width: 55px;
    height: 100%;
    padding-top: 16px;
    border-right: 1px solid;
    border-color: #E2E4E6;
    background: #FFFFFF;
    box-sizing: border-box;
    display: block;
    z-index: 99;
}

.icon {
    position: relative;
    width: 20px;
    height: 20px;
    padding: 8px;
    margin-bottom: 24px;
    margin-left: 9px;
    margin-right: 9px;
    border-radius: 6px;
    cursor: pointer;
}

    .icon:hover {
        background: #E2E4E6;
        box-shadow: 0px 2px 4px rgba(226, 228, 230, 0.3);
    }

    .icon.active {
        padding: 7px;
        border: 1px solid;
    }

.iconImage {
    width: 20px;
    height: 20px;
}

.iconTitle {
    display: none
}

.iconTooltip {
    position: absolute;
    top: 50%;
    left: 100%;
    max-width: none;
    padding: 9px;
    margin-left: 20px;
    font-family: 'Helvetica Neue', Helvetica, 'Source Sans Pro', Arial, sans-serif;
    font-weight: bold;
    font-size: 14px;
    text-align: center;
    color: #fff;
    background-color: #404040;
    transform: translate(0, -50%);
    border-radius: 4px;
    box-shadow: 0 0 6px rgba(0,0,0,0.2);
    box-sizing: border-box;
    display: none;
    visibility: hidden;
    opacity: 0;
    transition: opacity 0.8s;
    white-space: nowrap;
    z-index: 9999;
}

.iconTooltipLeft {
    left: 30px;
}

.iconTooltipQuit {
    left: -52px;
}
 
.icon:hover .iconTooltip {
    display: block;
    visibility: visible;
    opacity: 1;
    z-index: 9999;
}

.icon.active:hover .iconTooltip {
    display: none;
    visibility: hidden;
    opacity: 0;
}

.iconTooltip i {
    position: absolute;
    top: 50%;
    right: 100%;
    margin-top: -10px;
    width: 10px;
    height: 20px;
    overflow: hidden;
}

    .iconTooltip i::after {
        content: '';
        position: absolute;
        width: 12px;
        height: 12px;
        left: 0;
        top: 50%;
        transform: translate(50%,-50%) rotate(-45deg);
        background: #404040;
        box-shadow: 0 0 6px rgba(0,0,0,0.2);
    }

.icon.gear {
    position: fixed;
    bottom: 26px;
    margin-bottom: 0px;
    background: #F7F7F7;
}

.icon.option {
    display: none;
}


/****** Side Menu ******/
.side-menu {
    position: fixed;
    top: 0px;
    left: 55px;
    width: 339px;
    height: 100%;
    border-right: 1px solid;
    border-color: #E2E4E6;
    display: none;
}

    .side-menu.active {
        display: block;
        z-index: 50;
    }

.sm-header {
    position: absolute;
    top: 0px;
    left: 0px;
    width: 339px;
    height: 50px;
    background: #FFFFFF;
    border-bottom: 1px solid;
    border-color: #E2E4E6;
}

.sm-tab {
    position: absolute;
    top: 15px;
    bottom: 15px;
    left: 20px;
    right: 25px;
    height: 20px;
    font-family: 'Helvetica Neue', Helvetica, 'Source Sans Pro', Arial, sans-serif;
    font-style: normal;
    font-weight: bold;
    font-size: 18px;
    line-height: 22px;
    letter-spacing: 0.03em;
}

.sm-tab-backbutton {
    display: none;
}

.sm-body {
    position: absolute;
    top: 51px;
    bottom: 16px;
    left: 0px;
    width: 339px;
    background: #F7F7F7;
}

    .sm-body ul {
        margin: 0px;
        padding: 0px;
        list-style-type: none;
    }

.side-menu.favorite .sm-body {
    bottom: 67px;
}


.sm-items {
    position: absolute;
    top: 16px;
    bottom: 0px;
    width: 100%;
    overflow: auto;
    display: block;
}

.sm-subtab {
    margin-top: 14px;
}

.sm-subtab-title {
    height: 20px;
    padding-left: 20px;
    padding-right: 25px;
    margin-bottom: 12px;
    font-family: 'Helvetica Neue', Helvetica, 'Source Sans Pro', Arial, sans-serif;
    font-style: normal;
    font-weight: bold;
    font-size: 14px;
    line-height: 17px;
    letter-spacing: 0.03em;
    text-transform: uppercase;
    color: #333333;
}

.sm-subtab-item:hover {
    background-color: #E2E4E6;
}

.sm-subtab-item + .sm-subtab-item {
    margin-top: 4px;
}

.sm-subtab-item.active {
    background-color: #E2E4E6;
}


.sm-footer {
    position: absolute;
    bottom: 0px;
    width: 339px;
    height: 16px;
    background: #F7F7F7;
}

.side-menu.favorite .sm-footer {
    width: 294px;
    height: 35px;
    padding-top: 16px;
    padding-bottom: 16px;
    padding-left: 20px;
    padding-right: 25px;
}

#customizeFavorite {
    position: relative;
    width: fit-content;
    height: 17px;
    display: flex;
    align-items: center;
    cursor: pointer;
}

    #customizeFavorite:hover {
        background-color: #F7F7F7;
    }

    #customizeFavorite.active {
        background-color: #F7F7F7;
    }

    #customizeFavorite > img {
        position: relative;
        left: 0px;
        width: 17px;
        height: 17px;
    }

    #customizeFavorite > div {
        position: relative;
        left: 10px;
        height: 16px;
        padding-top: 1px;
        display: inline-block;
        white-space: nowrap;
        font-family: 'Helvetica Neue', Helvetica, 'Source Sans Pro', Arial, sans-serif;
        font-style: normal;
        font-weight: 400;
        font-size: 12px;
        line-height: 16px;
    }


.sm-section {
    height: auto;
    cursor: pointer;
}

    .sm-section:hover {
        background-color: #E2E4E6;
    }

    .sm-section.expanded {
        background: #E2E4E6;
    }

.sm-items > .sm-section {
    margin-top: 4px;
}

.sm-items::-webkit-scrollbar {
    width: 4px;
}

.sm-items::-webkit-scrollbar-track {
    background: #F1F1F1;
    border-radius: 6px;
}

.sm-items::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 6px;
}

    .sm-items::-webkit-scrollbar-thumb:hover {
        background: #555;
    }

.sm-section-header {
    padding-top: 8px;
    padding-bottom: 8px;
    padding-left: 20px;
    padding-right: 25px;
    margin-bottom: 4px;
    display: flex;
    align-items: center;
}

.sm-section-title {
    font-family: 'Helvetica Neue', Helvetica, 'Source Sans Pro', Arial, sans-serif;
    font-style: normal;
    font-weight: 400;
    font-size: 14px;
    line-height: 20px;
    color: #666666;
    display: flex;
    align-items: center;
}

.sm-section:hover .sm-section-title {
    color: #404040;
}

.sm-section.expanded .sm-section-title {
    font-weight: bold;
    color: #404040;
}

.sm-section-arrow {
    position: absolute;
    right: 25px;
    width: 10px;
    height: 10px;
    display: block;
    opacity: 0.5;
}

    .sm-section-arrow.up {
        transform: rotate(180deg);
        opacity: 1;
    }

.sm-section:hover .sm-section-arrow {
    opacity: 1;
}

.sm-section.expanded .sm-section-arrow {
    opacity: 1;
}

.sm-section-body {
    padding-top: 4px;
    padding-bottom: 8px;
    padding-left: 20px;
    padding-right: 25px;
    display: none;
}

.sm-section.expanded .sm-section-body {
    display: flex;
    align-items: stretch;
}

.sm-section-bar {
    width: 1px;
    margin-left: 9px;
    align-self: stretch;
    background: #E2E4E6;
}

.sm-section.expanded .sm-section-bar {
    background: #B0B0B0 !important;
}

.sm-section-item {
    width: 225px;
    min-height: 20px;
    padding-top: 8px;
    padding-bottom: 8px;
    padding-left: 20px;
    margin-right: 20px;
}

    .sm-section-item:hover {
        background: #B0B0B0;
    }

    .sm-section-item.active {
        position: relative;
        left: -1px;
        background: #E2E4E6 !important;
    }


.sm-function {
    padding-top: 8px;
    padding-bottom: 8px;
    display: flex;
    align-items: center;
    cursor: pointer;
}

    .sm-function a {
        width: 100%;
        height: 100%;
        display: flex;
        align-items: center;
        font-family: 'Helvetica Neue', Helvetica, 'Source Sans Pro', Arial, sans-serif;
        font-style: normal;
        font-weight: 400;
        font-size: 14px;
        line-height: 20px;
        color: #666666 !important;
    }

        .sm-function a:link {
            text-decoration: none;
        }

    .sm-function:hover a {
        color: #404040 !important;
    }

    .sm-function.active a {
        font-weight: bold;
    }


.sm-items > .sm-function {
    padding-left: 20px;
    padding-right: 25px;
    margin-top: 4px;
}

    .sm-items > .sm-function.active {
        background-color: #E2E4E6;
    }

    .sm-items > .sm-function:hover {
        background-color: #E2E4E6;
    }

.sm-subtab-item.sm-function {
    padding-left: 20px;
    padding-right: 25px;
}


.sm-subtab + .sm-subtab {
    margin-top: 30px;
}

.sm-items > .sm-section + .sm-section,
.sm-items > .sm-section + .sm-function,
.sm-items > .sm-function + .sm-function,
.sm-items > .sm-function + .sm-section {
    margin-top: 4px !important;
}

.sm-items > .sm-section + .sm-subtab,
.sm-items > .sm-function + .sm-subtab,
.sm-items > .sm-subtab + .sm-function,
.sm-items > .sm-subtab + .sm-section {
    margin-top: 20px !important;
}

/* La classe main-form est définie dans base.css */

/* Responsive */
@media screen and (max-width: 1500px) {

    /****** Side Menu ******/
    .side-menu {
        width: 320px;
    }

    .sm-header {
        width: 320px;
    }

    .sm-tab {
        right: 20px;
        font-size: 14px;
    }

    .sm-body {
        width: 320px;
    }

    .sm-subtab {
        margin-top: 9px;
    }

    .sm-subtab-title {
        font-size: 12px;
    }

    .sm-footer {
        width: 320px;
    }

    .side-menu.favorite .sm-footer {
        width: 280px;
        padding-right: 20px
    }

    .sm-section-header {
        padding-right: 20px;
    }

    .sm-section-title {
        font-size: 12px;
    }

    .sm-section-arrow {
        right: 20px;
    }

    .sm-section-body {
        padding-right: 20px;
    }

    .sm-section-item {
        width: 210px;
    }

    .sm-function a {
        font-size: 12px;
    }

    .sm-items > .sm-function {
        padding-right: 20px;
    }

    .sm-subtab-item.sm-function {
        padding-right: 20px;
    }

    .sm-subtab + .sm-subtab {
        margin-top: 25px;
    }
}

@media screen and (max-width: 768px) {

    /****** Hamburger Icon ******/
    #hamb {
        display: none;
    }

    /****** Icon Menu ******/
    #iconMenu {
        top: 0px;
        width: 321px;
        padding-top: 30px !important;
        padding-bottom: 30px;
        background: #F7F7F7;
        overflow: auto;
        display: none;
    }

        #iconMenu.active {
            display: block;
        }

    .icon {
        width: 280px;
        height: 44px;
        padding-top: 12px;
        padding-bottom: 12px;
        padding-left: 20px;
        margin-bottom: 20px !important;
        margin-left: 20px;
        margin-right: 20px;
        box-sizing: border-box;
        display: flex;
        align-items: center;
        background: #FFFFFF;
    }

        .icon:hover {
            background: #FFFFFF;
        }

        .icon.active {
            padding-top: 11px;
            padding-bottom: 11px;
            padding-left: 20px;
            border: inherit;
            border-color: #E72012;
            background: #EE3124;
            box-shadow: 0px 2px 4px rgba(238, 49, 36, 0.3);
        }

    .iconImage::selection {
        background: initial;
        color: initial;
    }

    .iconTitle {
        padding-left: 10px;
        display: inline-block;
        font-family: 'Helvetica Neue', Helvetica, 'Source Sans Pro', Arial, sans-serif;
        font-style: normal;
        font-weight: 400;
        font-size: 14px;
        line-height: 14px;
        letter-spacing: 0.03em;
    }

        .iconTitle::selection {
            background: initial;
            color: initial;
        }

    .icon.active .iconTitle {
        color: white;
    }

        .icon.active .iconTitle::selection {
            color: white;
        }

    .icon:hover .iconTooltip {
        display: none;
        visibility: hidden;
        opacity: 0;
    }

    #iconMenuSeparator {
        position: relative;
        width: 320px;
        height: 2px;
        margin-bottom: 20px;
        background-color: #E2E4E6;
        display: block;
    }

    .icon.gear {
        position: relative;
        bottom: auto;
        background: #FFFFFF;
    }

    .icon.option {
        position: relative;
        display: flex;
        margin-bottom: 20px !important;
    }

        .icon.option.active {
            border: 1px solid;
            border-color: #B0B0B0;
            background: #F7F7F7;
            box-shadow: 0px 2px 4px rgba(176, 176, 176, 0.3);
        }

            .icon.option.active .iconTitle {
                color: inherit;
            }

                .icon.option.active .iconTitle::selection {
                    color: inherit;
                }

    #icon_help > .iconImage {
        background: url('/Common/imgs/CGI/MenuHelp.svg') no-repeat;
        background-color: #F7F7F7;
    }

    #icon_profile > .iconImage {
        background: url('/Common/imgs/CGI/MenuProfile.svg') no-repeat;
        background-color: #F7F7F7;
    }

    #icon_logout > .iconImage {
        background: url('/Common/imgs/CGI/MenuQuit.svg') no-repeat;
        background-color: #F7F7F7;
    }


    /****** Side Menu ******/
    .side-menu {
        left: 0px;
    }

    .sm-header {
        padding-top: 15px;
        padding-bottom: 15px;
        box-sizing: border-box;
    }

    .sm-tab {
        position: absolute;
        left: 60px;
        right: 60px;
        display: flex;
        justify-content: center;
        align-items: center;
    }

    .sm-tab-backbutton {
        position: absolute;
        top: 18px;
        left: 20px;
        width: 9px;
        height: 14px;
        display: block;
        cursor: pointer;
    }

    .sm-items > .sm-function:hover {
        background-color: initial;
    }
}


@media screen and (max-height: 1000px) {

    #iconMenu {
        padding-top: 16px;
    }

    .icon {
        margin-bottom: 16px;
    }
}

@media screen and (max-height: 720px) {

    #iconMenu {
        padding-top: 12px;
    }

    .icon {
        margin-bottom: 12px;
    }
}

@media screen and (max-height: 620px) {

    #iconMenu {
        padding-top: 8px;
    }

    .icon {
        margin-bottom: 8px;
    }
}


@media screen and (max-height: 620px) and (min-width: 769px) {

    .icon.gear {
        bottom: 8px;
    }
}
