/* Gallery Section */
.gallery {
  background: rgba(255, 255, 255, 0.02);
}

.nettoyage-title {
  color: #fff;
  font-size: 2.2rem;
  font-weight: 800;
  letter-spacing: 2px;
  display: inline-block;
  margin-bottom: 10px;
}

.gallery-filters {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 15px;
  margin-bottom: 50px;
}

.filter-btn {
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: white;
  padding: 12px 25px;
  border-radius: 25px;
  cursor: pointer;
  transition: all 0.3s ease;
  font-weight: 500;
  font-size: 0.95rem;
}

.filter-btn:hover {
  background: rgba(255, 255, 255, 0.2);
  transform: translateY(-2px);
}

.filter-btn.active {
  background: linear-gradient(135deg, var(--primary-blue), var(--light-blue));
  border-color: var(--light-blue);
  box-shadow: 0 4px 15px rgba(30, 58, 138, 0.3);
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
  gap: 30px;
}

.gallery-item {
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 20px;
  overflow: hidden;
  position: relative;
  transition: all 0.3s ease;
}

.gallery-item:hover {
  transform: translateY(-5px);
  box-shadow: 0 15px 35px rgba(30, 58, 138, 0.3);
  border-color: rgba(192, 192, 192, 0.3);
}

.image-container {
  position: relative;
  overflow: hidden;
}

.image-slider {
  position: relative;
  width: 100%;
  height: 250px;
  overflow: hidden;
  border-radius: 20px 20px 0 0;
}

.gallery-image {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: filter 0.5s;
}

.gallery-image.after {
  transition: none;
  box-shadow: 0 0 30px 0 rgba(59,130,246,0.25);
  clip-path: inset(0 0 0 0);
  z-index: 2;
}

/* Barre de séparation slider */
.slider-separator {
  position: absolute;
  top: 0;
  width: 4px;
  height: 100%;
  background: linear-gradient(180deg, #3B82F6 0%, #1E3A8A 100%);
  box-shadow: 0 0 12px 2px #3B82F6;
  border-radius: 2px;
  transition: none;
  z-index: 3;
}

.slider-bar {
  position: absolute;
  bottom: 10px;
  left: 50%;
  transform: translateX(-50%);
  width: 80%;
  height: 6px;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 10px;
  outline: none;
  cursor: pointer;
  z-index: 4;
}

.slider-bar::-webkit-slider-thumb {
  appearance: none;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--light-blue), var(--primary-blue));
  cursor: pointer;
  box-shadow: 0 2px 10px rgba(59, 130, 246, 0.5);
  transition: all 0.3s ease;
}

.slider-bar::-webkit-slider-thumb:hover {
  transform: scale(1.2);
  box-shadow: 0 4px 20px rgba(59, 130, 246, 0.7);
}

.slider-bar::-moz-range-thumb {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--light-blue), var(--primary-blue));
  cursor: pointer;
  border: none;
  box-shadow: 0 2px 10px rgba(59, 130, 246, 0.5);
}

/* Étiquettes Avant/Après */
.image-label {
  position: absolute;
  top: 15px;
  padding: 8px 22px;
  border-radius: 18px;
  font-weight: 800;
  font-size: 1.1rem;
  text-transform: uppercase;
  letter-spacing: 2px;
  backdrop-filter: blur(10px);
  border: 2px solid #fff;
  transition: all 0.3s cubic-bezier(.77,0,.18,1);
  z-index: 2;
}

.pro-label {
  box-shadow: 0 8px 32px rgba(30,58,138,0.18);
  border: 2px solid #3B82F6;
  background: linear-gradient(90deg, #1E3A8A 0%, #3B82F6 100%);
  color: #fff;
}

.before-label {
  left: 15px;
}

.after-label {
  right: 15px;
}

.gallery-item:hover .image-label {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
}

.image-controls {
  position: absolute;
  bottom: 15px;
  right: 15px;
  display: flex;
  gap: 10px;
}

.zoom-btn {
  background: var(--silver);
  color: var(--primary-blue);
  border: none;
  width: 35px;
  height: 35px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  transition: all 0.3s ease;
}

.zoom-btn:hover {
  background: white;
  transform: scale(1.1);
}

.gallery-info {
  padding: 25px;
}

.gallery-title {
  font-size: 1.3rem;
  font-weight: 600;
  color: white;
  margin-bottom: 10px;
}

.gallery-description {
  color: rgba(255, 255, 255, 0.8);
  line-height: 1.5;
  font-size: 0.95rem;
}

.no-results {
  text-align: center;
  padding: 60px 20px;
  color: rgba(255, 255, 255, 0.6);
  font-size: 1.1rem;
}

/* Modal Styles */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.9);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2000;
  padding: 20px;
  backdrop-filter: blur(5px);
}

.modal-content {
  background: rgba(30, 58, 138, 0.95);
  backdrop-filter: blur(20px);
  border-radius: 20px;
  padding: 30px;
  max-width: 900px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  position: relative;
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.close-btn {
  position: absolute;
  top: 15px;
  right: 20px;
  background: none;
  border: none;
  color: white;
  font-size: 2rem;
  cursor: pointer;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: all 0.3s ease;
}

.close-btn:hover {
  background: rgba(255, 255, 255, 0.1);
}

.modal-images {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-bottom: 30px;
}

.modal-image-container {
  position: relative;
  border-radius: 15px;
  overflow: hidden;
}

.modal-image-container img {
  width: 100%;
  height: 300px;
  object-fit: cover;
}

.modal-image-label {
  position: absolute;
  top: 15px;
  left: 15px;
  background: rgba(30, 58, 138, 0.9);
  color: white;
  padding: 8px 15px;
  border-radius: 20px;
  font-weight: 600;
  font-size: 14px;
}

.modal-info {
  text-align: center;
}

.modal-info h3 {
  font-size: 1.5rem;
  color: white;
  margin-bottom: 15px;
}

.modal-info p {
  color: rgba(255, 255, 255, 0.8);
  line-height: 1.6;
  font-size: 1.1rem;
}

/* Responsive Gallery */
@media (max-width: 768px) {
  .gallery-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }
  
  .gallery-filters {
    gap: 10px;
  }
  
  .filter-btn {
    padding: 10px 20px;
    font-size: 14px;
  }
  
  .modal-images {
    grid-template-columns: 1fr;
  }
  
  .modal-image-container img {
    height: 250px;
  }
  
  .modal-content {
    padding: 20px;
  }
  
  .nettoyage-title {
    font-size: 1.8rem;
    padding: 10px 24px;
  }
}

@media (max-width: 480px) {
  .gallery-grid {
    grid-template-columns: 1fr;
  }
  
  .image-slider {
    height: 200px;
  }
  
  .gallery-info {
    padding: 20px;
  }
  
  .gallery-title {
    font-size: 1.1rem;
  }
  
  .modal-image-container img {
    height: 200px;
  }
  
  .nettoyage-title {
    font-size: 1.5rem;
    padding: 8px 20px;
  }
  
  .image-label {
    padding: 6px 16px;
    font-size: 0.9rem;
  }
}

.image-slider {
    user-select: none;
    -webkit-user-select: none;
    -ms-user-select: none;
    -moz-user-select: none;
}

.image-slider img {
    pointer-events: none;
    user-drag: none;
    -webkit-user-drag: none;
}
