/* ===================================
   Styles spécifiques pour les Réalisations
   =================================== */

/* Import des variables globales */
@import url('variables.css');

/* Layout principal */
/* .page-realisations {
    background: #f8f9fa;
} */

/* Section Filtres */
.realisations-filters {
    padding: 30px 20px;
    margin-bottom: 40px;
    position: relative;
}

.filters-wrapper {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    gap: 20px;
    align-items: center;
    flex-wrap: wrap;
}

.filter-group {
    flex: 1;
    min-width: 200px;
}

.filter-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: var(--tertiary-color);
    font-size: 0.9em;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.filter-select {
    width: 100%;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    background: #fff;
    font-size: 1em;
    transition: all 0.3s ease;
    cursor: pointer;
}

.filter-select:hover {
    border-color: var(--primary-color, #D37A39);
}

.filter-select:focus {
    outline: none;
    border-color: var(--primary-color, #D37A39);
    /* box-shadow: 0 0 0 3px var(--primary-light, rgba(211, 122, 57, 0.1)); */
}

.btn-reset {
    padding: 12px 25px;
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 28px;
}

.btn-reset:hover {
    background: var(--primary-hover);
    color: white;
    box-shadow: 0 4px 12px rgba(244, 67, 54, 0.3);
}

/* Grille de réalisations */
.realisations-grid {
    padding: 40px 0 60px;
    min-height: 400px;
}

.grid-container {
    max-width: var(--container-width);
    margin: 0 auto;
    /* padding: 0 20px; */
}

.grid-wrapper {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    min-height: 450px;
}

/* Card de réalisation */
.realisation-card {
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
    position: relative;
    opacity: 1;
    transform: translateY(0);
}

.realisation-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.15);
}

.realisation-card.hidden {
    opacity: 0;
    transform: scale(0.9);
    pointer-events: none;
    position: absolute;
}

/* Carrousel d'images */
.card-carousel {
    position: relative;
    height: 440px;
    overflow: hidden;
}

.carousel-container {
    position: relative;
    width: 100%;
    height: 100%;
}

.carousel-track {
    position: relative;
    width: 100%;
    height: 100%;
}

.carousel-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 0.5s ease;
}

.carousel-slide.active {
    opacity: 1;
}

.carousel-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Navigation du carrousel */
.carousel-prev,
.carousel-next {
    position: absolute !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    background: rgba(255, 255, 255, 0.15) !important;
    border: none !important;
    width: 40px !important;
    height: 40px !important;
    min-width: 40px !important;
    min-height: 40px !important;
    max-width: 40px !important;
    max-height: 40px !important;
    border-radius: 50% !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    cursor: pointer !important;
    transition: all 0.3s ease !important;
    z-index: 2;
    opacity: 1;
    color: white !important;
    padding: 0 !important;
    margin: 0 !important;
    text-align: center !important;
    line-height: 1 !important;
    font-size: 0 !important;
}

.carousel-prev svg,
.carousel-next svg {
    width: 24px !important;
    height: 24px !important;
    display: block !important;
    pointer-events: none !important;
}

.carousel-prev {
    left: 10px;
}

.carousel-next {
    right: 10px;
}

.carousel-prev:hover,
.carousel-next:hover {
    background: rgba(255, 255, 255, 0.25) !important;
    transform: translateY(-50%) scale(1.1);
}

/* Indicateurs du carrousel */
.carousel-indicators {
    position: absolute;
    top: 15px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 6px;
    z-index: 2;
}

.indicator {
    width: 6px !important;
    height: 6px !important;
    min-width: 6px !important;
    min-height: 6px !important;
    max-width: 6px !important;
    max-height: 6px !important;
    border-radius: 50% !important;
    background: rgba(255, 255, 255, 0.5) !important;
    border: none !important;
    cursor: pointer !important;
    transition: all 0.3s ease !important;
    padding: 0 !important;
    margin: 0 !important;
    display: inline-block !important;
}

.indicator.active {
    width: 6px !important;
    height: 6px !important;
    border-radius: 50% !important;
    background: rgba(255, 255, 255, 0.9) !important;
    transform: scale(1.3) !important;
}

/* Bouton plein écran */
.carousel-fullscreen {
    position: absolute !important;
    top: 10px !important;
    right: 10px !important;
    background: rgba(0, 0, 0, 0.7) !important;
    border: none !important;
    width: 36px !important;
    height: 36px !important;
    min-width: 36px !important;
    min-height: 36px !important;
    max-width: 36px !important;
    max-height: 36px !important;
    border-radius: 8px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    cursor: pointer !important;
    transition: all 0.3s ease !important;
    z-index: 3;
    color: white !important;
    opacity: 0;
    padding: 0 !important;
    margin: 0 !important;
    line-height: 1 !important;
    font-size: 0 !important;
}

.carousel-fullscreen svg {
    width: 20px !important;
    height: 20px !important;
    display: block !important;
    pointer-events: none !important;
}

.card-carousel:hover .carousel-fullscreen {
    opacity: 1;
}

.carousel-fullscreen:hover {
    background: rgba(0, 0, 0, 0.85) !important;
    transform: scale(1.1);
}

/* Zone sans image */
.no-image {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

/* Informations avec overlay */
.card-info {
    position: absolute;
    bottom: 0;
    width: 100%;
    height: 50%;
    background: #1E293B;
    background: linear-gradient(0deg,rgba(30, 41, 59, 1) 0%, rgba(30, 41, 59, 1) 21%, rgba(30, 41, 59, 0.86) 45%, rgba(30, 41, 59, 0) 100%);
    border-bottom-left-radius: 12px;
    border-bottom-right-radius: 12px;
}

.info-overlay {
    padding: 16px 18px;
    position: absolute;
    bottom: 0;
    width: 100%;
}

.info-title {
    font-size: 1.15em;
    font-weight: 700;
    color: var(--text-white);
    margin-bottom: 12px;
    line-height: 1.2;
    text-align: center;
}

.info-details {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.info-row {
    display: flex;
    gap: 8px;
    align-items: center;
    justify-content: center;
    flex-direction: row;
    flex-wrap: wrap;
}

.info-item {
    display: flex;
    align-items: center;
    gap: 6px;
    color: var(--text-white);
    font-size: 0.9em;
}

.info-item svg {
    flex-shrink: 0;
    color: var(--text-white);
    width: 14px;
    height: 14px;
    margin-left: 5px;
}
/* second line tags */
.info-row.info-tags {
    gap: 6px;
}

.info-row.info-tags svg{
    color: var(--text-white);
    height: 14px;
    margin-left: 0px;
    display: block;
    margin: 0 auto;
}

.info-item.info-distribution {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
}

.info-tag {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 3px 8px;
    margin: 0.3em 0;
    border-radius: 5px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    font-size: 0.85em;
}

.info-tag svg {
  width: 20px;
  height: 20px;
  margin-right: 0.3em;
  color: var(--primary-color);
}

.info-tag span {
  transform: translateY(2px);
}

.distribution-tag {
    background-color: var(--copyright-color);
}

.power-tag {
    background-color: var(--primary-hover);
}



/* Lightbox */
.lightbox {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.95);
    z-index: 9999;
    animation: fadeIn 0.3s ease;
}

.lightbox.active {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
}

.lightbox-close {
    position: absolute !important;
    top: 20px !important;
    right: 20px !important;
    background: rgba(255, 255, 255, 0.1) !important;
    border: none !important;
    color: white !important;
    cursor: pointer !important;
    z-index: 10000;
    transition: all 0.3s ease !important;
    width: 50px !important;
    height: 50px !important;
    min-width: 50px !important;
    min-height: 50px !important;
    max-width: 50px !important;
    max-height: 50px !important;
    border-radius: 50% !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 0 !important;
    margin: 0 !important;
    line-height: 1 !important;
    font-size: 0 !important;
}

.lightbox-close svg {
    width: 30px !important;
    height: 30px !important;
    display: block !important;
    pointer-events: none !important;
}

.lightbox-close:hover {
    background: rgba(255, 255, 255, 0.2) !important;
    transform: rotate(90deg);
}

.lightbox-content {
    position: relative;
    max-width: 90vw;
    max-height: 85vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

#lightbox-image {
    max-width: 100%;
    max-height: 85vh;
    object-fit: contain;
    border-radius: 4px;
}

.lightbox-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 100vw;
    display: flex;
    justify-content: space-between;
    padding: 0 40px;
    pointer-events: none;
}

.lightbox-prev,
.lightbox-next {
    background: rgba(255, 255, 255, 0.15) !important;
    border: none !important;
    width: 60px !important;
    height: 60px !important;
    min-width: 60px !important;
    min-height: 60px !important;
    max-width: 60px !important;
    max-height: 60px !important;
    border-radius: 50% !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    cursor: pointer !important;
    transition: all 0.3s ease !important;
    color: white !important;
    pointer-events: all;
    padding: 0 !important;
    margin: 0 !important;
    line-height: 1 !important;
    font-size: 0 !important;
}

.lightbox-prev svg,
.lightbox-next svg {
    width: 40px !important;
    height: 40px !important;
    display: block !important;
    pointer-events: none !important;
}

.lightbox-prev:hover,
.lightbox-next:hover {
    background: rgba(255, 255, 255, 0.25) !important;
    transform: scale(1.1);
}

/* Indicateurs lightbox */
.lightbox-indicators {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 8px;
    z-index: 10001;
}

.lightbox-indicators .indicator {
    width: 8px !important;
    height: 8px !important;
    min-width: 8px !important;
    min-height: 8px !important;
    max-width: 8px !important;
    max-height: 8px !important;
    border-radius: 50% !important;
    background: rgba(255, 255, 255, 0.4) !important;
    border: none !important;
    cursor: pointer !important;
    transition: all 0.3s ease !important;
    padding: 0 !important;
    margin: 0 !important;
    display: inline-block !important;
}

.lightbox-indicators .indicator.active {
    width: 8px !important;
    height: 8px !important;
    border-radius: 50% !important;
    background: rgba(255, 255, 255, 0.9) !important;
    transform: scale(1.4) !important;
}

.lightbox-indicators .indicator:hover {
    background: rgba(255, 255, 255, 0.6);
}

/* Message aucune réalisation */
.no-realisations {
    grid-column: 1 / -1;
    text-align: center;
    padding: 80px 20px;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    margin: 40px auto;
    max-width: 800px;
}

.no-realisations p {
    font-size: 1.3em;
    color: #666;
    margin: 0;
    font-weight: 300;
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes slideIn {
    from {
        transform: translateY(20px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

/* .realisation-card {
    animation: slideIn 0.5s ease forwards;
}

.realisation-card:nth-child(1) { animation-delay: 0.1s; }
.realisation-card:nth-child(2) { animation-delay: 0.2s; }
.realisation-card:nth-child(3) { animation-delay: 0.3s; }
.realisation-card:nth-child(4) { animation-delay: 0.4s; }
.realisation-card:nth-child(5) { animation-delay: 0.5s; }
.realisation-card:nth-child(6) { animation-delay: 0.6s; } */

/* Responsive */

/* Tablette : 2 colonnes */
@media (max-width: 1024px) {
    .grid-wrapper {
        grid-template-columns: repeat(2, 1fr);
        gap: 25px;
    }
}

/* Mobile : 1 colonne */
@media (max-width: 768px) {
    .filters-wrapper {
        flex-direction: column;
    }

    .filter-group {
        width: 100%;
    }

    .btn-reset {
        width: 100%;
        margin-top: 15px;
    }

    .grid-wrapper {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .card-carousel {
        height: 440px;
    }
    
    .realisations-filters {
        position: relative;
    }
    
    .info-details {
        grid-template-columns: 1fr;
    }
    
    .info-item.info-power {
        grid-column: 1;
    }
}

@media (max-width: 480px) {
    .realisations-intro {
        padding: 30px 0;
    }
    
    .info-title {
        font-size: 1.1em;
    }
    
    .info-details {
        gap: 8px;
    }
    
    .info-item {
        font-size: 0.9em;
    }
}