/* ==========================================================================
   Advanced Maps Widgets - Frontend Styles
   ========================================================================== */

/* Map Widget
   ========================================================================== */

.amw-map-widget {
    width: 100%;
}

.amw-map-container {
    width: 100%;
    height: 400px;
    min-height: 200px;
    overflow: hidden;
    background: #f0f0f0;
    position: relative;
}

/* Fix Leaflet z-index issues in Elementor */
.amw-map-container .leaflet-pane,
.amw-map-container .leaflet-top,
.amw-map-container .leaflet-bottom {
    z-index: 1 !important;
}

.amw-map-container .leaflet-control {
    z-index: 2 !important;
}

/* Leaflet Custom Marker
   ========================================================================== */

.amw-leaflet-marker {
    background: transparent !important;
    border: none !important;
}

.amw-marker-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.3));
    transition: transform 0.15s ease;
}

.amw-marker-icon i,
.amw-marker-icon svg {
    display: block;
}

/* Make sure icon inherits color */
.amw-marker-icon i {
    color: inherit !important;
}

.amw-marker-icon svg {
    fill: currentColor !important;
}

/* Popup Styles
   ========================================================================== */

.amw-popup {
    min-width: 150px;
    max-width: 300px;
}

.amw-popup-title {
    font-weight: 600;
    font-size: 14px;
    margin-bottom: 5px;
    color: #333;
}

.amw-popup-desc {
    font-size: 13px;
    color: #666;
    margin-bottom: 5px;
}

.amw-popup-address {
    font-size: 12px;
    color: #999;
    font-style: italic;
}

/* Leaflet popup overrides for Elementor styling */
.leaflet-popup-content .amw-popup-title {
    font-weight: 600;
}

.leaflet-popup-content .amw-popup-desc {
    margin-bottom: 5px;
}

.leaflet-popup-content .amw-popup-address {
    font-style: italic;
    opacity: 0.8;
}

/* List Widget
   ========================================================================== */

.amw-list-widget {
    width: 100%;
}

.amw-list-container {
    gap: 15px;
}

.amw-list-empty {
    padding: 20px;
    text-align: center;
    color: #999;
    font-style: italic;
}

/* List Item
   ========================================================================== */

.amw-list-item {
    cursor: pointer;
    transition: all 0.2s ease;
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 15px;
}

.amw-list-item:hover {
    border-color: #ccc;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.amw-list-item.is-active {
    border-color: #2196f3;
    background-color: #e3f2fd;
}

.amw-item-title {
    font-weight: 600;
    font-size: 15px;
    margin-bottom: 5px;
    color: #333;
}

.amw-item-desc {
    font-size: 13px;
    color: #666;
    line-height: 1.4;
}

/* Responsive
   ========================================================================== */

@media (max-width: 767px) {
    .amw-list-container {
        grid-template-columns: 1fr !important;
    }
}
