/* General */
body {
    margin: 0;
    font-family: 'Poppins', sans-serif;
    overflow-x: hidden;
}

/* Project Container */
.project-container {
    display: flex;
    flex-direction: column; /* Mobile-first */
    height: 100vh;
}


/* Accordion Container */
.accordion-container {
    display: flex;
    width: 100%;
    flex-direction: row;
}

/* Accordion */
.accordion {
    display: flex;
    height: 100vh;
    overflow: hidden;
    transition: all 0.3s ease;
}

.accordion.open .accordion-header {
    /* background: linear-gradient(90deg, #6a11cb, #2575fc); */
    width: auto;
}

.accordion-header {
    writing-mode: vertical-lr;
    transform: rotate(180deg);
    padding: 12px 6px;
    font-weight: bold;
    text-align: center;
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 6px 12px;
    background-color: #fff;
    block-size: 75% content-box;
    transition: all 0.3s ease;

}

.accordion.open {
    flex: 1;
}

#volet-1 .accordion-header{
    background-color: #25325F;
    color: #fff;    
}

#volet-2 .accordion-header{
    background-color: #ADECD7;
    color: #fff;
}

#volet-3 .accordion-header{
    background-color: #F0D68B;
    color: #fff;
}

#volet-4 .accordion-header{
    background-color: #FB94BA;
    color: #fff;
}

.accordion-content {
    display: none;
    padding: 20px;
    border-top: none;
    animation: fadeIn 0.3s ease;
}

.accordion.open .accordion-content {
    display: flex;
    overflow-y: scroll;
    gap: 32px;
}

/* Project Gallery */
.project-gallery {
    display: flex;
    flex-direction: column;
    padding-top: 96px;
    margin: 32px;
    gap: 32px;
}

@media screen and (min-width: 1600px) {
    .accordion.open .accordion-content {
        flex-wrap: wrap;
        justify-content: space-between;
      }
    
    .project-gallery {
        flex-direction: row;
        flex-wrap: wrap;
        gap: 32px;
        padding: 64px;
        justify-content: flex-start;
      }
    
    .exemple-project {
        width: calc(50% - 16px); /* 2 colonnes avec un petit espace */
        flex-direction: row;
        align-items: flex-start;
      }
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-32px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.exemple-project img {
    width: 100%;
    height: auto;
    max-height: 320px;
    max-width: 320px;
    object-fit: cover;
    border-radius: 12px;
}

/* Cacher la version desktop sur mobile */
@media screen and (max-width: 768px) {
    .projects-desktop {
      display: none !important;
    }
    .projects-mobile {
      display: flex !important;
    }
}
  
/* Cacher la version mobile sur desktop */
@media screen and (min-width: 769px) {
    .projects-mobile {
      display: none !important;
    }
}
  
/* Version mobile visible */
@media screen and (max-width: 768px) {
    .projects-mobile {
      display: flex;
      flex-direction: column;
      margin-top: 116px;
    }
  
    .mobile-category {
      display: flex;
      flex-direction: column;
    }
  
    .category-title {
      font-size: 1.2rem;
      justify-content: center;
      align-items: center;
      align-self: center;
      font-weight: 700;
      color: #25325F;
      cursor: pointer;
      padding: 0.2rem;
      transition: background-color 0.3s ease;
    }

    .project-slider {
      display: none;
      overflow-x: auto;
      gap: 1rem;
      margin-left: 24px;
      scroll-snap-type: x mandatory;
      padding-bottom: 1rem;
      -webkit-overflow-scrolling: touch;
      transition: opacity 0.3s ease;
    }
  
    .project-slider.active {
      display: flex;
      opacity: 1;
      margin-left: 24px;
    }
  
    .project-card {
      flex: 0 0 85%;
      scroll-snap-align: start;
      background: #fff;
      border-radius: 16px;
      box-shadow: 0 4px 10px rgba(0,0,0,0.1);
      padding: 1rem;
      transition: transform 0.3s ease;
    }
  
    .project-card:hover {
      transform: scale(1.02);
    }
  
    .project-card img {
      width: 100%;
      border-radius: 12px;
      object-fit: cover;
    }
  
    .project-card h3 {
      font-size: 1.2rem;
      color: #25325F;
    }
  
    .project-card p {
      font-size: 0.95rem;
      color: #25325F;
    }
  
    .project-card a {
      display: inline-block;
      margin-top: 0.6rem;
      background-color: #25325F;
      color: white;
      padding: 8px 14px;
      border-radius: 24px;
      font-size: 0.9rem;
      text-decoration: none;
      transition: background-color 0.3s ease;
    }
  
    .project-card a:hover {
      background-color: #68e0cf;
      color: #25325F;
    }

    @media screen and (max-width: 768px) {
        .projects-mobile .mobile-category:nth-of-type(1) {
          background-color: #25325F; /* Branding */
        }
      
        .projects-mobile .mobile-category:nth-of-type(2) {
          background-color: #ADECD7; /* UX/UI */
          color: #25325F;
        }
      
        .projects-mobile .mobile-category:nth-of-type(3) {
          background-color: #F0D68B; /* Illustration */
        }
      
        .projects-mobile .mobile-category:nth-of-type(4) {
          background-color: #FB94BA; /* Direction Artistique */
        }
      
        .projects-mobile .mobile-category .category-title {
          color: white;
          font-size: 1.3rem;
          font-weight: bold;
          padding: 0.73rem;
          text-align: center;
        }
      
        .projects-mobile .mobile-category .project-card h3 {
          color: #25325F;
        }
      
        .projects-mobile .mobile-category .project-card p {
          color: #555;
        }
      }
      
  }
  