/* Map Container */
.mimovemap-container {
  position: relative;
  height: 100%;
  width: 100%;
  overflow: hidden;
}

/* Marker Styles */
.custom-marker {
    cursor: pointer;
    width: fit-content;
    height: auto;
    z-index: 1;
}

.custom-marker[role="button"] {
    z-index: 2;
}

.custom-marker[role="img"] {
    z-index: 1;
}

.custom-marker.hover,
.custom-marker:focus,
.custom-marker.active {
    z-index: 3 !important;
}

.custom-marker .marker-pin {
    border: 2px solid #FFFFFF;
    border-radius: 20px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
    position: relative;
    width: fit-content;
    height: auto;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    z-index: inherit;
}

.custom-marker .marker-dot {
    width: 16px;
    height: 16px;
    background: #002F5C;
    border-radius: 50%;
    border: 1px solid white;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
    transition: all 0.2s ease;
    z-index: inherit;
}

.custom-marker .marker-price {
    background: #002F5C;
    border-radius: 12px;
    padding: 2px 6px;
    font-size: 13px;
    font-weight: bold;
    color: #FFFFFF;
    white-space: nowrap;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
    overflow: hidden;
    text-overflow: ellipsis;
    z-index: inherit;
}

/* Hover States */
.custom-marker:hover .marker-pin {
    background: #FF5252;
    transform: scale(1.1);
}

.custom-marker:hover .marker-dot {
    transform: scale(1.3);
    background: #FF5252;
}

.custom-marker.hover .marker-pin,
.custom-marker.active .marker-pin {
    background: #FF5252;
    transform: scale(1.1);
}

.custom-marker.hover .marker-dot,
.custom-marker.active .marker-dot {
    transform: scale(1.3);
    background: #FF5252;
}

/* Popup Styles */
.property-popup {
    width: 100%;
    max-width: 320px !important;
    padding: 0 !important;
    border-radius: 10px !important;
    overflow: hidden;
    background: transparent !important;
    box-shadow: none !important;
    position: absolute !important;
    top: 16px !important;
    right: 16px !important;
    left: auto !important;
    transform: none !important;
    z-index: 99;
}

.property-popup .mapboxgl-popup-content {
    padding: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
}

.property-popup .mapboxgl-popup-close-button {
    font-size: 20px;
    color: #333333;
    padding: 8px;
    background: rgba(255, 255, 255, 0.8);
    border-radius: 50%;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    top: 8px;
    right: 8px;
    z-index: 100;
}

.mapboxgl-popup-tip {
    display: none !important;
}

/* Loading State */
.custom-marker.loading .marker-pin,
.custom-marker.loading .marker-dot {
    animation: pulse 1.5s infinite;
}

.custom-marker.error .marker-pin,
.custom-marker.error .marker-dot {
    background: #FF0000;
}

@keyframes pulse {
    0% {
        opacity: 0.6;
        transform: scale(1);
    }
    50% {
        opacity: 1;
        transform: scale(1.1);
    }
    100% {
        opacity: 0.6;
        transform: scale(1);
    }
}

/* Mobile Styles */
@media (width < 64rem) {
    .property-popup {
        max-width: 320px !important;
        top: auto !important;
        right: auto !important;
        left: calc(50% - 162px) !important;
        bottom: 0 !important;
    }

    .custom-marker .marker-pin {
        transform: none !important;
    }

    .custom-marker .marker-dot {
        transform: none !important;
    }
}

/* Map Controls */
.mapboxgl-ctrl-top-right {
    top: 10px;
    right: 10px;
}

.mapboxgl-ctrl-bottom-right {
    bottom: 10px;
    right: 10px;
}