/* ============================================================
   ASEDG – Custom theme
   ============================================================ */

/* ----------------------------------------------------------
   1. VARIABLES & BASE
   ---------------------------------------------------------- */
:root {
    --red: #e2654d;
    --yellow: #f6b409;

    --primary-accent: #9f1a0b;
    --secondary-accent: #d79c06;
}

/* @font-face {
  font-family: 'Circular Air Pro';
  src: url('../assets/fonts/Circular Air Pro-Light.otf') format('opentype');
  font-weight: 300;
  font-style: normal;
  font-display: swap;
} */

body {
    margin: 0;
    font-family: Arial;
    padding-top: 120px;
}

body,
p {
}

h2 {
    position: relative;
    font-size: 30px;
    margin-bottom: 20px;
}

h3 {}

h4 {}

h5 {}


#footer {}

.arrows {
    text-align: right;
}

button.arrow {
    border-radius: 50%;
    height: 40px;
    width: 40px;
    border: 2px solid #ddd;
    background: #fff;
    line-height: 0;
    cursor: pointer;
    font-size: 16px;
    font-weight: bold;

    &:hover {
        background: #ddd;
    }

    &:active {
        background: #aaa;
        border-color: #aaa;
        color: #fff;
    }
}

.read-more {
    cursor: pointer;
    transition: 0.2s;
    color: inherit;
    text-decoration: none;

    &.small:hover {
        color: var(--red);
    }

    &::after {
        content: attr(data-icon);
        white-space: pre;
        margin-left: 0px;
        transition: 0.5s;
    }

    &:hover {

        &::after {
            margin-left: 20px;
        }
    }
}

.center {
    text-align: center;
}

section {
    margin-bottom: 40px;
}

.columns {
    display: flex;
    gap: 80px;
    justify-content: space-around;
    margin: 60px 0;
    &.tiny{
        p{
            flex:1;
        }
    }
}

.column {
    display: flex;
    flex-direction: column;
    align-items: center;
    flex: 1;
    i {
        border-radius: 50%;
        height: 160px;
        width: 160px;
    }

    h3 {
        font-size: 22px;
        margin-bottom: 10px;
    }

    p {
        text-align: center;
        line-height: 24px;
        max-width: 70%;
        margin: 0 0 20px;
        /* flex: 1; */
    }

    ul {
        flex: 1;
        margin: 0 0 40px;
        list-style: none;
        max-width: 60%;
        min-width: 50%;

        li {
            position: relative;

            &::before {
                content: ">";
                font-weight: bold;
                position: absolute;
                top: 5px;
                left: -20px;
                color: var(--yellow);
            }

            a {
                color: #888;
            }
        }
    }
    
    a {
        color:#000;
        text-decoration: none;
        line-height: 28px;
    }
    
    .wrap {
        position: relative;
    }

    .read-more {
        font-weight: bold;
    }
}

.imgbox {
    padding: 40px 0;

    .wrap {
        display: flex;
        gap: 40px;
    }

    .content {
        flex: 1.5;

        h3 {
            font-size: 34px;
            margin: 20px 0 20px;
        }

        p {
            line-height: 24px;
            font-size: 16px;
            margin-bottom: 20px;
        }
    }

    picture {
        flex: 2;
        background: var(--red);
        border-radius: 20px;
        overflow: hidden;
    }
}

.bullets {
    display: flex;
    gap: 40px;
    margin: 40px 0 0;
    padding: 0;
    list-style: none;

    .bullet {
        display: flex;
        gap: 20px;
        align-items: center;

        i {
            display: flex;
            height: 80px;
            width: 80px;
            border-radius: 50%;
            background: var(--red);
            flex: 0 0 80px;
            align-items:center;
            justify-content:center;
            svg{
                width:60%;
                height:60%;
                color:#fff;
            }
        }

        .content {
            flex: 1;

            h3 {
                margin: 0 0 10px;
            }

            p {
                margin: 0;
                color: #888;
            }

            flex: 1;
        }
    }
}
.titledeco {
    position: absolute;
    height: 2px;
    background: var(--red);
    width: 40px;
    bottom: -5px;
    left: 0;
    
    &::after{
        content:"";
        position:absolute;
        bottom:-10px;
        height:10px;
        width:2px;
        background:var(--red);
        left:19px;
    }

    &.center{
        left: 50%;
        transform:translateX(-50%);
    }

    &.yellow{
        background: var(--yellow);
        &::after{
        background:var(--yellow);
        }
    }
}
.rel{
    position:relative;
}
/* ----------------------------------------------------------
   3. HEADER / NAV
   ---------------------------------------------------------- */
#header {
    height: 120px !important;
    padding: 10px 40px;
    box-sizing: border-box;
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    background: #fff;
    z-index: 10;
    
    
    
    
    
    
    
    
    
    



    .container {
        display: flex;
        align-items: center;
        flex-direction: row;
        padding: 0;
        height: 100%;
        border-bottom: 2px solid grey;
        justify-content: space-between;
    }
}

#header .navbar-section {
    height: calc(4rem + 30px) !important;
}

#header .logo img,
#header .logo svg {
    height: 56px !important;
}

#header li a:hover {
    color: var(--red);
}

.container {
    max-width: 1300px;
    margin: auto;
    padding: 0 80px;

    &.small {
        max-width: 1100px;
    }
}

.navbar-brand {
    margin: 10px 0;
    height: 60%;

    img {
        height: 100%;
    }
}

.navbar {
    flex: 1;
}

#menu {
    list-style: none;
    display: flex;
    justify-content: end;
    align-items: center;
}

.submenu {
    display: none;
    position: absolute;
    list-style: none;
    padding: 0;
    left: 0;
    top: 100%;
    min-width: 200px;

    li {
        padding: 6px 10px;
        background: #fff;
        border-bottom: 2px solid var(--yellow);

        a {
            display: block;
        }

    }
}

#menu li {
    position: relative;




    &.dropdown {

        &:hover {
            .submenu {
                display: block;
            }

            >a {
                color: var(--red);
            }
        }

        &.red>a {
            color: var(--red);

            &:hover {
                color: var(--yellow);
            }
        }

        >a::after {
            content: "⯆";
            line-height: 0;
            font-size: 14px;
            margin-left: 6px;
        }
    }

    a {
        text-decoration: none;
        color: #000;
        font-weight: 600;
        cursor: pointer;
    }
}

#menu>li {
    padding: 10px;


    &:nth-child(n+2) {
        margin-left: 20px;
    }
}


/* ----------------------------------------------------------
   4. BOUTONS
   ---------------------------------------------------------- */
.button,
a.button {
    display: inline-block;
    padding: 14px 20px;
    box-sizing: border-box;
    border-radius: 30px;
    text-decoration: none !important;
    cursor: pointer;
    transition: 0.2s;
    background: var(--red);
    color: #fff !important;
    letter-spacing: 1.2px;
    font-weight: normal !important;

    &.secondary {
        background: var(--yellow);
    }

    &.go {
        padding: 0;
        width: 40px;
        height: 40px;
        border-radius: 50%;
        display: flex;
        align-items: center;
        justify-content: center;

        &:hover {
            width: 50px;
            height: 50px;
            margin-top: -5px;
            margin-bottom: -5px;
        }
    }
}

.button:hover,
a.button:hover {
    background: #000;
    color: #fff !important;
    outline: none;
}

.button:active,
a.button:active {
    transform: translateY(0);
}

.buttons {

    &.centered {
        justify-content: center;
    }
}

/* ----------------------------------------------------------
   5. SECTION HERO
   ---------------------------------------------------------- */


#hero {
    height: 500px;
    overflow: hidden;
    
    
    
    
    
    




    >.wrap {
        padding: 40px 0;
        position: relative;
        height: 100%;
    }
}

#hero-text-container {
    h1 {
        font-size: 46px;
        width: 50%;
        min-width: 700px;
    }

    p {
        font-size: 18px;
        font-weight: bold;
        line-height: 28px;
        width: 35%;
        min-width: 550px;
    }

    position:relative;
    z-index: 1;
}


@keyframes disc{
    0%{
        transform:translate(0,0px);
    }
    50%{
        transform:translate(0,-20px);
    }
    100%{
        transform:translate(0,0px);
    }
}

#hero-bg-container {
    position: absolute;
    inset: 0;
    overflow: hidden;


    .wrap {
        position: relative;
        height: 100%;
        width: 100%;
    }

    .disc {

        border-radius: 50%;
        position: absolute;
        transform-origin:center;

        &.red {
            background: var(--red);
            height: 600px;
            width: 600px;
            bottom: -200px;
            right: 100px;
            animation: disc 6s ease infinite;
        }

        &.yellow {
            background: var(--yellow);
            height: 400px;
            width: 400px;
            bottom: -150px;
            right: -50px;
            animation: disc 4s 1s ease infinite;
        }

    }
}

/* ----------------------------------------------------------
   5. SECTION STATS
   ---------------------------------------------------------- */

#stats {
    padding: 80px;
    
    

    .wrap {
        display: flex;
        justify-content: space-around;
        list-style: none;
        margin: 0;
        padding: 0;

        .item {
            display: flex;

            .icon {
                display: block;
                height: 100px;
                width: 100px;
                svg{
                    height:100%;
                    width:100%;
                }
            }

            .text {
                strong {
                    display: block;
                    font-size: 60px;
                    filter: blur(0px);
                    transition:0.3s;
                    &.incrementing{
                        filter:blur(2px);
                    }
                    &.done{
                        filter:blur(0px);
                    }
                }

                small {
                    font-size: 14px;
                    color: #888;
                }

                margin-left: 20px;
            }
        }
    }
}


/* ----------------------------------------------------------
   5. SECTION ACTUALITES
   ---------------------------------------------------------- */
#news, .bloc-posts {

    .siema {
        overflow: hidden;
    }

    .posts {
        display: flex;
        gap: 20px;
        margin-top: 20px;

        .single {
            flex: 1 60%;

            .newscard {
                height: 100%;
            }
        }

        .duo {
            flex: 1 40%;
            display: flex;
            flex-direction: column;
            gap: 20px;
        }

        /* Groupe incomplet : 1 ou 2 articles, chacun sur une demi-largeur
           (un article seul ne s'étire donc pas sur toute la ligne). */
        &.all-single .single {
            flex: 0 1 calc(50% - 10px);
        }
    }
}

picture img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.newscard {
    border-radius: 20px;
    display: flex;

    picture {
        display: block;
        height: 100%;
        min-height: 160px;
        width: 50%;
        background: var(--red);
        flex: 1 50%;
        border-radius: 20px;
        overflow: hidden;
    }

    >div {
        flex: 1 50%;
        padding: 20px;
        width: 50%;
        box-sizing: border-box;
        display: flex;
        flex-direction: column;
    }

    &.small {
        picture {
            flex: 1 30%;
        }

        >div {
            padding: 20px;
        }

        .card-title {
            font-size: 16px;
            font-weight: bold;
            margin: 10px 0;
            flex: 1;
        }
    }

    time {
        color: var(--red);
        font-weight: bolder;
    }

    .card-title {
        font-size: 28px;
        font-weight: bold;
        margin: 10px 0;

        a {
            color: inherit;
            text-decoration: none;

            &:hover {
                color: var(--red);
            }
        }
    }

    p {
        line-height: 24px;
        flex: 1;
    }
}



.red {
    color: var(--red);
}

.yellow {
    color: var(--yellow);
}

.yellow-bg {
    background: var(--yellow);
}

.grey {
    background: #f5f1eb;
    /* background: lightgrey; */
}


#engage-partners {
    h2 {
        font-size: 24px;
    position: relative;
    }

    >.wrap {
        display: flex;
        gap: 40px;

        >section {
            flex: 1;
            /* Siema donne au carrousel une largeur en pixels : sans min-width,
               le min-content de la colonne suit cette largeur et la colonne
               s'élargit sans fin. */
            min-width: 0;
        }
    }
}

#partners {
    .siema {
        overflow: hidden;
    }

    .partner-slide {
        display: flex;
        align-items: center;
        justify-content: center;
        padding: 20px;
        box-sizing: border-box;

        a {
            display: flex;
        }

        img {
            max-width: 100%;
            max-height: 60px;
            width: auto;
            height: auto;
            filter: grayscale(1);
            opacity: 0.7;
            transition: 0.2s;
        }

        a:hover img {
            filter: grayscale(0);
            opacity: 1;
        }

        span {
            font-weight: 600;
            color: #888;
        }
    }
}



footer{
    .wrap{
    border-top: 2px solid #ddd;
    padding: 0;
    margin: auto;
        > .columns{
           margin: 20px 0;
           gap: 40px;
           .column{
               flex:1;
               align-items: start;
               justify-content: flex-start;

               h4{
                   margin:0 0 10px;
               }
               ul{
                   margin:0;
                   padding-left: 20px;
                   max-width: unset;
                   min-width: unset;
                   width: 100%;

                   li::before{
                       color:#000;
                   }
               }
               >a{
                   text-decoration: none;
                   color: #000;
                   font-weight: bold;
                   line-height: 28px;
                   &:hover{
                       text-decoration:underline;
                   }
               }
           }
        }
    }
    .navbar-brand {
    height: auto;
    max-width: 200px;
    
    img {
            width: 100%;
            height: auto;
        }
    }

    padding: 10px 40px;
    .footer-meta{
        text-align:center;
        color:#888;
        font-size:14px;
        margin-top:40px;
        a{
            color:#888;
            text-decoration:none;
        }
    }
}


#prestations, #branches, .prestations-list {

.icon {
    display:flex;
    align-items:center;
    justify-content:center;
    svg{
        height:60%;
    width:60%;
    color:#fff;
    }
}
}
#branches{
    .icon svg{
        color:#000;
    }
}


/* ----------------------------------------------------------
   6. PAGES INTÉRIEURES
   ---------------------------------------------------------- */
.page-hero {
    padding: 60px 0 40px;

    h1 {
        display: inline-block;
        font-size: 40px;
        margin: 0;
    }

    .intro {
        max-width: 720px;
        margin-top: 24px;

        p {
            font-size: 18px;
            line-height: 28px;
            color: #555;
            margin: 0;
        }
    }
}

.page-content {
    line-height: 28px;

    h2 {
        margin-top: 40px;
    }

    h2:first-child {
        margin-top: 0;
    }

    ul, ol {
        line-height: 28px;
    }

    a {
        color: var(--red);
    }
}

.prestations-list {
    margin-bottom: 40px;

    .column p {
        color: #888;
    }
}

.page-buttons {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
    margin-top: 40px;
}

/* Blocs modulaires */
.bloc {
    padding: 40px 0;

    &.grey {
        background: #f5f1eb;
    }
}

.bloc-columns {
    .columns {
        flex-wrap: wrap;
        margin: 40px 0 0;
    }

    .column {
        flex: 1 1 200px;
    }
}

.bloc.imgbox {
    picture {
        min-height: 240px;
    }

    &.img-left .wrap {
        flex-direction: row-reverse;
    }
}


/* ----------------------------------------------------------
   7. ACTUALITÉS (liste + article)
   ---------------------------------------------------------- */
.chip {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    border-radius: 30px;
    border: 2px solid #ddd;
    background: #fff;
    color: #000;
    text-decoration: none;
    font-weight: 600;
    font-size: 15px;
    line-height: 1.2;
    transition: 0.2s;

    .count {
        color: #888;
        font-weight: normal;
        font-size: 13px;
    }

    &:hover {
        border-color: var(--red);
        color: var(--red);
    }

    &.active {
        background: var(--red);
        border-color: var(--red);
        color: #fff;

        .count {
            color: #fff;
        }
    }

    &.small {
        padding: 4px 12px;
        font-size: 13px;
        font-weight: normal;
    }
}

.blog-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 40px 0 30px;
}

.blog-active-filter {
    color: #888;
    margin: 0 0 30px;

    a {
        color: var(--red);
    }
}

.blog-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
    margin-bottom: 40px;

    .newscard {
        height: 100%;
    }
}

.post-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 16px;
    margin: 20px 0 0;

    time {
        color: var(--red);
        font-weight: bolder;
    }
}

.post-tags {
    display: inline-flex;
    flex-wrap: wrap;
    gap: 8px;
}

.post {
    .post-image {
        display: block;
        border-radius: 20px;
        overflow: hidden;
        max-height: 420px;
        margin-bottom: 30px;
    }
}

.back-link {
    margin-top: 40px;

    a {
        font-weight: bold;
    }
}



/* ----------------------------------------------------------
   3bis. MENU MOBILE
   ---------------------------------------------------------- */
.mobile-menu {
    display: none;
}

.mobile-container {
    display: none;
}

body.no-scroll, body.no-scroll>div, body.no-scroll footer {
    overflow: hidden;
    /* height: 100vh; */
}

@media (max-width: 980px) {

    #menu {
        display: none;
    }

    .mobile-menu {
        display: flex;
        align-items: center;
        gap: 20px;
    }

    .mobile-quick-menu {
        list-style: none;
        margin: 0;
        padding: 0;

        li.dropdown {
            position: relative;

            >a {
                font-weight: 600;
                cursor: pointer;

                &::after {
                    content: "⯆";
                    display: inline-block;
                    line-height: 0;
                    font-size: 12px;
                    margin-left: 6px;
                    transition: 0.2s;
                }
            }

            &.open>a::after {
                transform: rotate(180deg);
            }

            .submenu {
                left: auto;
                right: 0;
                li{
                    line-height: 28px;
                    font-size:20px;
                    
                    
                    
                    a{
                        text-decoration:none;
                        color:#000;
                        font-weight: bold;
                    }
                }
            }
        }
    }

    .mobile-menu .dropdown.open>.submenu,
    .mobile-container .dropdown.open>.submenu {
        display: block;
    }

    .button_container {
        cursor: pointer;
        width: 26px;
        height: 18px;
        position: relative;
        flex: 0 0 auto;

        span {
            display: block;
            position: absolute;
            left: 0;
            width: 100%;
            height: 3px;
            border-radius: 3px;
            background: #000;
            transition: 0.3s;

            &.top {
                top: 0;
            }

            &.middle {
                top: 50%;
                margin-top: -1.5px;
            }

            &.bottom {
                bottom: 0;
            }
        }

        &.open {

            span.top {
                top: 50%;
                margin-top: -1.5px;
                transform: rotate(45deg);
            }

            span.middle {
                opacity: 0;
            }

            span.bottom {
                bottom: 50%;
                margin-bottom: -1.5px;
                transform: rotate(-45deg);
            }
        }
    }

    /* Hamburger – opens the main menu, fullscreen, below the header */
    .mobile-container {
        display: flex;
        align-items: center;
        justify-content: center;
        position: fixed;
        top: 120px;
        left: 0;
        height: calc(100vh - 120px);
        width: 100vw;
        z-index: 8;
        background: #fff;
        opacity: 0;
        visibility: hidden;
        transition: 0.3s;
        
        &.open {
            opacity: 1;
            visibility: visible;
        }

        .mobile-nav-list {
            list-style: none;
            margin: 0;
            padding: 0;
            text-align: center;

            >li {
                margin-bottom: 20px;
            }

            a {
                display: inline-block;
                text-decoration: none;
                color: #000;
                font-size: 26px;
                font-weight: 600;

                &:hover {
                    color: var(--red);
                }
            }

            .dropdown>a {
                cursor: pointer;

                &::after {
                    content: "⯆";
                    display: inline-block;
                    font-size: 16px;
                    margin-left: 8px;
                    transition: 0.2s;
                }
            }

            .dropdown.open>a::after {
                transform: rotate(180deg);
            }

            .submenu {
                display: none;
                position: static;
                list-style: none;
                margin: 14px 0 0;
                padding: 0;
                min-width: 0;

                li {
                    margin-bottom: 10px;
                }

                a {
                    font-size: 18px;
                    font-weight: 500;
                }
            }
        }
    }
    #header {
        padding: 10px;
    }
    
    .navbar-brand {
        max-width: 160px;
        img{
            height:auto;
            width:100%;
        }
    }
#news, .bloc-posts {
    & .posts {
        flex-direction: column;
    }

    & .posts.all-single .single {
        flex: 1 1 auto;
    }
}

.blog-grid {
    grid-template-columns: 1fr;
}

.newscard {
    picture {
        height:auto;
    }
    &.small {
        picture {
            flex: 1 20%;
            min-width:160px;
        }
    }
}

.container {
    padding: 0 40px;
}

#stats {
    padding: 40px;
    .wrap{
        flex-direction: column;
        display: inline-block;
        /* align-items:center; */
        position: relative;
        left: 50%;
        transform: translateX(-50%);
        .item:nth-child(n+2){
            margin-top:40px;
        }
        .item:nth-child(2){
            /* flex-direction:row-reverse; */
        }
    }
}


#hero-text-container {
    h1 {
        font-size: 26px;
        min-width: auto;
        width: auto;
    }

    p {
        font-size: 18px;
        font-weight: bold;
        line-height: 28px;
        width: 80%;
        min-width: unset;
    }

    position:relative;
    z-index: 1;
}

#hero-bg-container {

    .wrap {
        transform:scale(0.7);
        transform-origin:bottom;
    }
}

.columns {
    flex-wrap: wrap;
}

footer{
    .wrap > .columns {
        flex-direction:column;
        align-items:center;
    }
}

.imgbox {

    .wrap {
        flex-direction:column-reverse;
        gap: 20px;
    }

    picture {
        flex: 2;
        border-radius: 20px;
        min-height: 300px;
        width:100%;
    }
}

#engage-partners {
    
    >.wrap {
        display: flex;
        flex-direction:column;
    }
}
    
}


@media (max-width: 1200px) {
    
    .navbar-brand {
        height: 50%;
    }
    
    #menu>li {
        &:nth-child(n+2) {
            margin-left: 0;
        }
        a{
            font-size: 14px;
        }
    }
    #stats {
        padding: 80px 40px;
        .wrap {
            gap: 80px;
        }
    }

    .newscard {
        .card-title {
            font-size: 22px;
        }
    }
    .bullets {
        flex-direction: column;
    }
}


@media (max-width: 560px) {

    .newscard {
        &:not(.small){
            flex-direction: column;
            >div,picture{
                width:100%;
            }
        }
        picture {
            height:auto;
        }
        &.small {
        picture {
                flex: 1 10% !important;
        min-width:120px;
            }
        }
    }

    footer .columns .columns{
        width:auto !important;
        gap: 20px !important;
        flex-direction: column;
        
        ul{
            width:auto !important;
        } 
    }
    
}