/*HERO*/

.designexpert {
  text-align: center;
  padding-bottom: 152px;
  padding-top: 200px;
  padding-left: 5%;
  padding-right: 5%;
}

@media only screen and (max-width: 760px) {
  .designexpert {
    padding-bottom: 108px;
    padding-top: 152px;
  }
}


/*PORTFOLIO*/

/* FILTERS */
        .filters {
            margin-bottom: 24px;
            text-align: center;
            justify-content: center;
            overflow-x: auto;
            white-space: nowrap;
        }

        .tab-scroll {
            display: inline-block;
            justify-content: center;
            align-items: center;
            /*margin: 32px;*/
            padding: 24px;
            background-color: transparent;
            border-radius: 50px;
            margin-bottom: 24px;
        }

        .filter-button {
            background-color: transparent;
            outline: none;
            cursor: pointer;
            padding: 8px 16px;
            transition: 0.3s;
            color: #0E100F;
            font-family: 'Montserrat', sans-serif;
            font-size: 16px;
            font-weight: normal;
            text-align: center;
            margin: 4px;
            opacity: 0.5;
            border : none
        }

        .filter-button.active,
        .filter-button:hover {
   color: #0E100F;
      opacity: 1;
        }

             .filter-button:before{
           content:"[ "
        }
                     .filter-button:after{
           content:" ]"
        }

        /* PORTFOLIO GRID */
        .portfolio {
            display: grid;
            grid-template-columns: repeat(2, 1fr);
            gap: 40px;
            max-width: 1400px;
            margin: 0 auto;
            padding: 0 20px 104px;
        }

        @media screen and (max-width: 980px) {
            .portfolio {
                grid-template-columns: 1fr;
                gap: 30px;
            }
        }

        /* PROJECT CARD AVEC HOVER */
        .project {
            position: relative;
            overflow: hidden;
            cursor: pointer;
            box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
            background: #000;
            display: none; /* Caché par défaut, filtres géreront l'affichage */
        }

        .project.show {
            display: block;
        }

        .project-images {
            position: relative;
            width: 100%;
            overflow: hidden;
        }

        .project-image {
            width: 100%;
            height: 100%;
            object-fit: cover;
            transition: opacity 0.5s ease, transform 0.5s ease;
            display: block;
        }

        .project-image.main {
            position: relative;
            z-index: 1;
        }

        .project-image.hover {
            position: absolute;
            top: 0;
            left: 0;
            z-index: 0;
            opacity: 0;
            transform: scale(1.05);
        }

        .project:hover .project-image.main {
            opacity: 0;
            transform: scale(1.05);
        }

        .project:hover .project-image.hover {
            opacity: 1;
            transform: scale(1);
        }

        /* OVERLAY */
        .project-overlay {
            position: absolute;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            background: linear-gradient(to bottom, rgba(0,0,0,0) 0%, rgba(0,0,0,0.1) 100%);
            z-index: 2;
            display: flex;
            align-items: flex-start;
            padding: 40px;
            pointer-events: none;
            border:0px;
        }

        .client-name {
    font-size: 14px;
    color: white;
    /* text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5); */
    transition: opacity 0.3sease, transform 0.3s ease;
    opacity: 1;
    background-color: #0E100F;
    padding: 8px 8px 8px 8px;
}

.client-name:before {
  content :"["
}

.client-name:after {
  content :"]"
}


        .project-description {
            font-size: 16px;
            color: #F2EFE8;
            text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
            line-height: 1.5;
            max-width: 80%;
            opacity: 0;
            transform: translateY(-10px);
            transition: opacity 0.3s ease, transform 0.3s ease;
            position: absolute;
            top: 0;
        }

        .project:hover .client-name {
            opacity: 0;
            transform: translateY(10px);
        }

        .project:hover .project-description {
            opacity: 1;
            transform: translateY(0);
        }

        /* BOUTON EN SAVOIR PLUS */
        .project-button {
            position: absolute;
            bottom: 40px;
            left: 40px;
            z-index: 3;
            pointer-events: auto;
        }



        /* POPUP */
        .popup {
            display: none;
            position: fixed;
            left: 0;
            top: 0;
            width: 100%;
            height: 100%;
            background-color: rgba(0, 0, 0, 0.5);
            justify-content: center;
            align-items: center;
            z-index: 9999;
        }

        .popup:target {
            display: flex;
        }

        .popup-content {
            background-color: #F2EFE8;
            padding: 24px;
            border-radius: 5px;
            position: relative;
            width: 95%; /* Augmenté */
            max-height: 90vh; /* Hauteur maximale */
            overflow-y: auto; /* Active le scroll vertical */
            text-align: center;
            display: flex;
            /*flex-wrap: wrap;*/
            gap: 20px;
        }

        /* Pour que le scroll fonctionne bien sur tous les navigateurs */
        .popup {
            overflow-y: auto; /* Permet aussi le scroll sur le popup lui-même */
            padding: 20px; /* Un peu d'espace autour */
        }

        .close {
            position: absolute;
            top: 10px;
            right: 10px;
            font-size: 30px;
            text-decoration: none;
            color: black;
            cursor: pointer;
            z-index: 1;
        }

        .colomn1projet {
            flex: 1 1 50%;
            padding: 8px;
            order: 1; /* Ordre par défaut : colonne 1 en premier */

        }

        .colomn2projet {
            flex: 2 1 40%;
            padding: 8px;
            order: 2; /* Ordre par défaut : colonne 2 en deuxième */

        }

        .h4portfolio {
            color: #0E100F;
            text-align: left;
            font-family: 'Montserrat', sans-serif;
            font-size: 30px;
            font-weight: normal;
            text-transform: uppercase;
        }

        .outilsprojets {
            font-family: 'Montserrat', sans-serif;
            font-size: 20px;
            text-align: left;
            padding-bottom: 0px;
            margin-bottom: 32px;
            word-wrap: break-word;
            white-space: normal;
            color: #0E100F;
        }

        .outilsborder {
            font-size: 16px;
        }
        
        .outilsborder:before {
          content :"["
        }

        .outilsborder:after {
          content :"]"
        }
        .textprojet {
            font-family: 'Montserrat';
            font-size: 18px;
            text-align: left;
            width: 100%;
            margin-top: 8px;
            font-weight: 300;
            padding-bottom: 24px;
            color: #0E100F;
        }

        @media screen and (max-width: 865px) {
            .popup-content {
            flex-direction: column;
            width: 95%; /* Plus large sur mobile */
            max-height: 95vh; /* Un peu moins haut sur mobile */
            }
            
            .colomn2projet,
            .colomn1projet {
            flex: none !important; /* Force l'annulation du flex */
            width: 100% !important; /* Force la largeur totale */
            min-width: 100% !important;
            max-width: 100% !important; /* Au cas où */

            }
            
            .h4portfolio {
                font-size: 20px;
            }
            /* INVERSION : Texte avant images sur mobile */
            .colomn2projet {
                order: 1; /* Le texte passe en premier */
            }
            
            .colomn1projet {
                order: 2; /* Les images passent en deuxième */
            }
        }

        @media screen and (max-width: 768px) {
            .project-overlay {
                padding: 25px;
            }
            
            .project-button {
                bottom: 25px;
                left: 25px;
            }
        }

        
.boutonportfolio {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 0px 0px 0px 16px;
  background: #0E100F;
  border-radius: 50px;
  text-decoration: none;
  font-family: 'Montserrat', sans-serif;
  font-size: 18px;
  color: #F2EFE8;
  cursor: pointer;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  margin-top:0px;
}
.boutonportfolio > span:first-child {
  position: relative;
  z-index: 2;
  transition: all 0.4s ease;
}

.boutonportfolio > span:first-child::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: -2px;
  width: 0;
  height: 2px;
  background: #F2EFE8;
  transition: width 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.boutonportfolio .icon-circle {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  background: #0E100F;
  border-radius: 50%;
  flex-shrink: 0;
  z-index: 2;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.boutonportfolio img {
  width: 16px;
  height: 16px;
  object-fit: contain;
  transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Effet hover */
.boutonportfolio:hover {
  border-color: transparent;
  background: transparent;
  color: #F2EFE8; /* ← Texte en noir au hover */

}

.boutonportfolio:hover > span:first-child::after {
  width: 100%;
}

.boutonportfolio:hover .icon-circle {
  background: #0E100F;
  transform: translate(5px, -5px);
}

.boutonportfolio:hover img {
  transform: none;
}
/* Effet click */
.boutonportfolio:active {
  transform: scale(0.98);
}

@media screen and (max-width: 700px) {
  .boutonportfolio {
    font-size:16px;
  }
}