/* Styles pour la pagination des réalisations */
.realisations-pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 15px;
    margin: 50px 0;
    padding: 20px;
}

.pagination-btn {
    background: linear-gradient(135deg, #00E0FF 0%, #0099CC 100%);
    color: white;
    border: none;
    padding: 12px 20px;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
}

.pagination-btn:hover:not(:disabled) {
    background: linear-gradient(135deg, #0099CC 0%, #007399 100%);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 224, 255, 0.3);
}

.pagination-btn:disabled {
    background: #666;
    cursor: not-allowed;
    opacity: 0.5;
}

.pagination-numbers {
    display: flex;
    gap: 8px;
}

.pagination-number {
    background: rgba(255, 255, 255, 0.1);
    color: white;
    border: 2px solid transparent;
    padding: 10px 15px;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.3s ease;
    min-width: 45px;
}

.pagination-number:hover {
    background: rgba(0, 224, 255, 0.2);
    border-color: #00E0FF;
}

.pagination-number.active {
    background: linear-gradient(135deg, #00E0FF 0%, #0099CC 100%);
    border-color: #00E0FF;
    box-shadow: 0 3px 10px rgba(0, 224, 255, 0.4);
}

/* Amélioration des filtres */
.realisations-filters {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 12px;
    margin: 40px 0;
    padding: 0 20px;
}

.filter-btn {
    background: rgba(255, 255, 255, 0.1);
    color: white;
    border: 2px solid transparent;
    padding: 12px 24px;
    border-radius: 25px;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.filter-btn:hover {
    background: rgba(0, 224, 255, 0.2);
    border-color: #00E0FF;
    transform: translateY(-2px);
}

.filter-btn.is-active {
    background: linear-gradient(135deg, #00E0FF 0%, #0099CC 100%);
    border-color: #00E0FF;
    box-shadow: 0 5px 15px rgba(0, 224, 255, 0.4);
}

/* Animation pour les cartes de projet */
.project-card {
    transition: all 0.3s ease;
    opacity: 1;
    transform: scale(1);
}

.project-card[style*="display: none"] {
    opacity: 0;
    transform: scale(0.8);
}

/* S'assurer que les cartes visibles restent visibles */
.project-card[style*="display: block"] {
    opacity: 1 !important;
    transform: scale(1) !important;
    visibility: visible !important;
    display: block !important;
}

/* Éliminer les transitions qui peuvent causer des clignotements */
.project-card {
    transition: none !important;
}

/* Message quand aucune réalisation */
.no-realisations {
    text-align: center;
    padding: 60px 20px;
    color: rgba(255, 255, 255, 0.7);
}

.no-realisations p {
    font-size: 1.2em;
    margin: 0;
}

/* Responsive */
@media (max-width: 768px) {
    .realisations-pagination {
        flex-direction: column;
        gap: 20px;
    }
    
    .pagination-numbers {
        order: -1;
    }
    
    .pagination-btn {
        width: 100%;
        justify-content: center;
        max-width: 200px;
    }
    
    .realisations-filters {
        gap: 8px;
    }
    
    .filter-btn {
        padding: 10px 16px;
        font-size: 0.9em;
    }
}

@media (max-width: 480px) {
    .pagination-numbers {
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .pagination-number {
        padding: 8px 12px;
        min-width: 40px;
    }
}

/* Animation d'entrée pour les nouvelles cartes */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.project-card {
    animation: fadeInUp 0.6s ease forwards;
}

/* Amélioration du slider avant/après */
.before-after-slider {
    position: relative;
    overflow: hidden;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    height: 300px; /* Hauteur fixe pour éviter les problèmes */
}

.slider-image-before,
.slider-image-after {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.slider-image-before img,
.slider-image-after img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block !important;
    opacity: 1 !important;
    visibility: visible !important;
}

.slider-image-before {
    z-index: 2;
    clip-path: inset(0 50% 0 0);
    display: block !important;
    opacity: 1 !important;
    visibility: visible !important;
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    height: 100% !important;
}

.slider-image-after {
    z-index: 1;
    clip-path: inset(0 0 0 50%);
    display: block !important;
    opacity: 1 !important;
    visibility: visible !important;
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    height: 100% !important;
}

.slider-handle {
    position: absolute;
    top: 0;
    left: 50%;
    width: 4px;
    height: 100%;
    z-index: 10;
    cursor: ew-resize;
    transform: translateX(-50%);
}

.slider-handle::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #00E0FF 0%, #0099CC 100%);
    box-shadow: 0 0 10px rgba(0, 224, 255, 0.5);
}

.handle-circle {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, #00E0FF 0%, #0099CC 100%);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    box-shadow: 0 4px 15px rgba(0, 224, 255, 0.4);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.handle-circle:hover {
    transform: translate(-50%, -50%) scale(1.1);
    box-shadow: 0 6px 20px rgba(0, 224, 255, 0.6);
}

.handle-arrows {
    display: flex;
    align-items: center;
    gap: 2px;
}

.arrow-left,
.arrow-right {
    width: 0;
    height: 0;
    border-style: solid;
}

.arrow-left {
    border-width: 4px 6px 4px 0;
    border-color: transparent white transparent transparent;
}

.arrow-right {
    border-width: 4px 0 4px 6px;
    border-color: transparent transparent transparent white;
}