/* Styles pour la visite virtuelle */
.virtual-tour-card {
    position: relative;
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--box-shadow);
    background: linear-gradient(rgba(0, 0, 0, 0.7), rgba(6, 52, 150, 0.815)), 
                url('../image/others-img/heroImh.jpg') center/cover;
    height: 400px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition);
}
.virtual-tour-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
}

.tour-content {
    text-align: center;
    color: white;
    padding: 20px;
    z-index: 2;
    max-width: 600px;
}

.tour-content h3 {
    font-size: 2rem;
    margin-bottom: 15px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
}

.tour-content p {
    font-size: 1.2rem;
    margin-bottom: 30px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
}

.tour-play-btn {
    background-color: var(--primary-color);
    color: white;
    border: none;
    padding: 15px 30px;
    border-radius: 50px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 10px;
}

.tour-play-btn:hover {
    background-color: #333;
    transform: scale(1.05);
}

.tour-play-btn i {
    font-size: 1.2rem;
}

/* Modal pour la visite virtuelle */
#virtualTourModal .modal-content {
    padding: 0;
    background: #000;
}

.virtual-tour-container {
    width: 100%;
    height: 100%;
    min-height: 500px;
}

/* Augmenter la hauteur de la section gallery */
.gallery {
    padding: 120px 20px;
}

/* Modal Styles - Légendes en bas de l'image */
.modal {
    display: none;
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.9);
    align-items: center;
    justify-content: center;
}

/* Quand le modal est actif */
.modal[style*="flex"] {
    display: flex !important;
}

.modal-content {
    position: relative;
    width: 90%;
    max-width: 1200px;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.modal-carousel {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    max-height: calc(90vh - 100px); /* Laisser de la place pour la légende */
}

.modal-image {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    transition: opacity 0.3s ease;
}

.modal-close {
    position: absolute;
    top: 20px;
    right: 20px;
    color: white;
    font-size: 2.5rem;
    cursor: pointer;
    background: none;
    border: none;
    z-index: 10001;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: background-color 0.3s ease;
}

.modal-close:hover {
    background-color: rgba(255, 255, 255, 0.2);
}

.modal-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background-color: rgba(0, 0, 0, 0.5);
    color: white;
    border: none;
    font-size: 2rem;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10001;
}

.modal-nav:hover {
    background-color: rgba(0, 0, 0, 0.8);
    transform: translateY(-50%) scale(1.1);
}

.modal-prev {
    left: 20px;
}

.modal-next {
    right: 20px;
}
/* Conteneur principal  */
.modal-content {
    display: flex;
    flex-direction: column;
    align-items: center; /* Centre tous les éléments horizontalement */
    justify-content: center;
    position: relative;
}

/* Légende positionnée en bas de l'image - maintenant parfaitement centrée */
.modal-caption {
    position: relative; 
    margin: 20px auto 0 auto; 
    color: white;
    text-align: center;
    font-size: 1.1rem;
    padding: 15px 25px;
    background: rgba(0, 0, 0, 0.8);
    border-radius: 25px;
    max-width: 80%;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    align-self: center;
}

.modal-caption-container {
    display: flex;
    justify-content: center;
    width: 100%;
    margin-top: 20px;
}

/* Responsive */
@media (max-width: 768px) {
    .modal-carousel {
        max-height: calc(90vh - 120px); /* Plus d'espace pour la légende sur mobile */
    }
    
    .modal-nav {
        width: 50px;
        height: 50px;
        font-size: 1.5rem;
    }
    
    .modal-prev {
        left: 10px;
    }
    
    .modal-next {
        right: 10px;
    }
    
    .modal-close {
        top: 10px;
        right: 10px;
        font-size: 2rem;
    }
    
    .modal-caption {
        margin: 15px auto 0 auto;
        font-size: 1rem;
        padding: 12px 20px;
        max-width: 90%;
    }
}

@media (max-width: 480px) {
    .modal-carousel {
        max-height: calc(90vh - 140px);
    }
    
    .modal-caption {
        margin: 10px auto 0 auto;
        font-size: 0.9rem;
        padding: 10px 15px;
        max-width: 95%;
    }
}