/**
 * Styles CSS pour la carte Elementor
 */

/* Styles de base pour le conteneur de carte */
.yannjarno-map-wrapper {
    position: relative;
    margin-bottom: 20px;
}

/* Styles pour le conteneur de carte */
.yannjarno-map-container {
    display: flex;
    position: relative;
    min-height: 400px;
    border: 1px solid #ddd;
    border-radius: 4px;
    overflow: hidden;
}

/* Styles pour la carte elle-même */
.yannjarno-map {
    min-height: 500px;
    width: 70%;
    z-index: 1;
}

/* Styles pour la liste des posts */
.yannjarno-post-list {
    width: 30%;
    overflow-y: auto;
    height: 500px;
    border-right: 1px solid #ddd;
    padding: 10px;
    background-color: #ffffff;
}

/* Styles pour les éléments de la liste */
.yannjarno-post-list .post-item {
    margin-bottom: 15px;
    padding-bottom: 15px;
    border-bottom: 1px solid #eee;
}

.yannjarno-post-list .post-item:last-child {
    border-bottom: none;
}

.yannjarno-post-list .post-item h3 {
    font-size: 16px;
    margin: 5px 0;
    color: #333;
}

.yannjarno-post-list .post-item a {
    text-decoration: none;
    color: inherit;
}

.yannjarno-post-list .post-item a:hover {
    color: #ff6600;
}

.yannjarno-post-list .post-item img {
    width: 100%;
    height: 120px;
    object-fit: cover;
    border-radius: 4px;
}

/* Styles pour les formulaires de filtres */
.yannjarno-map-filters {
    margin-bottom: 15px;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
}

.yannjarno-filter-select {
    padding: 8px 12px;
    border-radius: 4px;
    border: 1px solid #ddd;
    min-width: 200px;
}

.radio-button {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
}

/* Style personnalisé pour les boutons radio */
.radio-button div {
    position: relative;
    display: flex;
    align-items: center;
}

.radio-button input[type="radio"] {
    margin-right: 5px;
}

/* Style pour le loader */
.yannjarno-map-loader {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(255, 255, 255, 0.7);
    z-index: 999;
    display: flex;
    justify-content: center;
    align-items: center;
}

/* Animation du loader */
.yannjarno-map-loader .lds-roller {
    display: inline-block;
    position: relative;
    width: 80px;
    height: 80px;
}

.yannjarno-map-loader .lds-roller div {
    animation: lds-roller 1.2s cubic-bezier(0.5, 0, 0.5, 1) infinite;
    transform-origin: 40px 40px;
}

.yannjarno-map-loader .lds-roller div:after {
    content: " ";
    display: block;
    position: absolute;
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #333;
    margin: -4px 0 0 -4px;
}

.yannjarno-map-loader .lds-roller div:nth-child(1) {
    animation-delay: -0.036s;
}

.yannjarno-map-loader .lds-roller div:nth-child(1):after {
    top: 63px;
    left: 63px;
}

.yannjarno-map-loader .lds-roller div:nth-child(2) {
    animation-delay: -0.072s;
}

.yannjarno-map-loader .lds-roller div:nth-child(2):after {
    top: 68px;
    left: 56px;
}

.yannjarno-map-loader .lds-roller div:nth-child(3) {
    animation-delay: -0.108s;
}

.yannjarno-map-loader .lds-roller div:nth-child(3):after {
    top: 71px;
    left: 48px;
}

.yannjarno-map-loader .lds-roller div:nth-child(4) {
    animation-delay: -0.144s;
}

.yannjarno-map-loader .lds-roller div:nth-child(4):after {
    top: 72px;
    left: 40px;
}

.yannjarno-map-loader .lds-roller div:nth-child(5) {
    animation-delay: -0.18s;
}

.yannjarno-map-loader .lds-roller div:nth-child(5):after {
    top: 71px;
    left: 32px;
}

.yannjarno-map-loader .lds-roller div:nth-child(6) {
    animation-delay: -0.216s;
}

.yannjarno-map-loader .lds-roller div:nth-child(6):after {
    top: 68px;
    left: 24px;
}

.yannjarno-map-loader .lds-roller div:nth-child(7) {
    animation-delay: -0.252s;
}

.yannjarno-map-loader .lds-roller div:nth-child(7):after {
    top: 63px;
    left: 17px;
}

.yannjarno-map-loader .lds-roller div:nth-child(8) {
    animation-delay: -0.288s;
}

.yannjarno-map-loader .lds-roller div:nth-child(8):after {
    top: 56px;
    left: 12px;
}

@keyframes lds-roller {
    0% {
        transform: rotate(0deg);
    }
    100% {
        transform: rotate(360deg);
    }
}

/* Styles pour les popups Leaflet */
.leaflet-popup-content {
    min-width: 200px;
}

.leaflet-popup-content h3 {
    font-size: 16px;
    margin: 5px 0;
    color: #333;
}

.leaflet-popup-content p {
    margin: 5px 0;
    font-size: 14px;
}

.leaflet-popup-content img {
    width: 100%;
    height: 150px;
    object-fit: cover;
    border-radius: 4px 4px 0 0;
    margin-bottom: 10px;
}

/* Styles responsifs */
@media (max-width: 768px) {
    .yannjarno-map-container {
        flex-direction: column;
    }
    
    .yannjarno-map,
    .yannjarno-post-list {
        width: 100%;
        height: 400px;
    }
    
    .yannjarno-post-list {
        height: 300px;
        border-right: none;
        border-top: 1px solid #ddd;
    }
    
    .yannjarno-map-filters {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .yannjarno-filter-select {
        width: 100%;
    }
    
    .radio-button {
        margin-top: 10px;
        width: 100%;
        justify-content: space-between;
    }
}

/* Style spécial pour les marqueurs personnalisés */
.custom-icon {
    background: transparent !important;
    border: none !important;
}

.custom-icon.red-marker {
    z-index: 1000 !important;
}