.lc-mr {
    --mr-commercial: #16325c;
    --mr-residential: #fe2c57;
    --mr-business: #0e9f9a;
}

.lc-mr-meta {
    color: var(--bs-secondary-color);
}

.lc-mr .breadcrumb-item.active {
    color: var(--bs-body-color);
}

.lc-mr-card {
    overflow: hidden;
}

.lc-mr-toolbar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.6rem 0.9rem;
    padding: 0.7rem 0.9rem;
    border-bottom: 1px solid var(--bs-border-color);
    background: var(--bs-tertiary-bg);
}

.lc-mr-pills .btn {
    border: 1px solid var(--bs-border-color);
    background: var(--bs-body-bg);
    color: var(--bs-body-color);
    font-weight: 600;
}

.lc-mr-pills .btn.active {
    background: var(--lc-navy-soft, #16325c);
    border-color: var(--lc-navy-soft, #16325c);
    color: #fff;
}

.lc-mr-sale {
    margin-left: 0.4rem;
    padding-left: 1rem;
    border-left: 2px solid var(--bs-border-color);
    gap: 0.4rem;
}

.lc-mr-pills.lc-mr-sale .btn {
    border-radius: 2rem !important;
    border-style: dashed;
    border-color: #0b9ad6;
    background: transparent;
    color: #0b9ad6;
}

.lc-mr-pills.lc-mr-sale .btn.active {
    border-style: solid;
    background-color: #0b9ad6 !important;
    border-color: #0b9ad6 !important;
    color: #fff;
}

.lc-mr-mapwrap {
    position: relative;
}

.lc-mr-map {
    height: 76vh;
    min-height: 30rem;
    background: var(--bs-secondary-bg);
}

.lc-mr-overlay {
    position: absolute;
    z-index: 800;
    left: 50%;
    transform: translateX(-50%);
    padding: 0.5rem 0.9rem;
    border-radius: 2rem;
    background: var(--bs-body-bg);
    color: var(--bs-body-color);
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.25);
    font-size: 0.9rem;
}

.lc-mr-loading {
    top: 0.8rem;
}

.lc-mr-empty {
    top: 50%;
    transform: translate(-50%, -50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    border-radius: 1rem;
    padding: 1.2rem 1.6rem;
}

.lc-mr-empty.d-none {
    display: none !important;
}

.lc-mr-corner {
    position: absolute;
    z-index: 800;
    top: 0.8rem;
    right: 0.8rem;
}

.lc-mr-legend {
    position: absolute;
    z-index: 800;
    left: 0.8rem;
    bottom: 1.6rem;
    display: flex;
    gap: 0.8rem;
    padding: 0.35rem 0.7rem;
    border-radius: 2rem;
    background: var(--bs-body-bg);
    color: var(--bs-body-color);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.25);
    font-size: 0.78rem;
}

.lc-dot {
    display: inline-block;
    width: 0.7rem;
    height: 0.7rem;
    border-radius: 50%;
    margin-right: 0.35rem;
}

.lc-dot-commercial { background: var(--mr-commercial); }
.lc-dot-residential { background: var(--mr-residential); }
.lc-dot-business { background: var(--mr-business); }

.lc-mr-note {
    padding: 0.5rem 0.9rem;
    border-top: 1px solid var(--bs-border-color);
    background: var(--bs-warning-bg-subtle);
    color: var(--bs-warning-text-emphasis);
}

.lc-pin {
    position: absolute;
    transform: translate(-50%, -100%);
    white-space: nowrap;
    padding: 0.18rem 0.5rem;
    border-radius: 0.8rem;
    color: #fff;
    font-size: 0.75rem;
    font-weight: 700;
    line-height: 1.2;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.45);
    border: 2px solid #fff;
    transition: transform 0.12s ease;
    cursor: pointer;
}

.lc-pin::after {
    content: "";
    position: absolute;
    left: 50%;
    bottom: -7px;
    width: 8px;
    height: 8px;
    background: inherit;
    border-right: 2px solid #fff;
    border-bottom: 2px solid #fff;
    transform: translateX(-50%) rotate(45deg);
}

.lc-pin-commercial { background: var(--mr-commercial); }
.lc-pin-residential { background: var(--mr-residential); }
.lc-pin-business { background: var(--mr-business); }

.lc-pin-lease {
    border-style: dashed;
}

.lc-pin-active,
.lc-pin:hover {
    transform: translate(-50%, -100%) scale(1.18);
    z-index: 1000 !important;
}

.lc-pin-wrap {
    background: none;
    border: 0;
}

.lc-cluster {
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    color: #fff;
    font-weight: 700;
    background: radial-gradient(circle at 30% 30%, #2a5cb0, #0a1b33);
    border: 3px solid rgba(255, 255, 255, 0.85);
    box-shadow: 0 0 0 6px rgba(22, 50, 92, 0.28), 0 3px 8px rgba(0, 0, 0, 0.4);
}

.lc-cluster-md { width: 46px; height: 46px; }
.lc-cluster-lg { width: 54px; height: 54px; }

.lc-cluster-commercial { background: radial-gradient(circle at 30% 30%, #2a5cb0, #0a1b33); box-shadow: 0 0 0 6px rgba(22, 50, 92, 0.28), 0 3px 8px rgba(0, 0, 0, 0.4); }
.lc-cluster-residential { background: radial-gradient(circle at 30% 30%, #ff6a86, #c41e44); box-shadow: 0 0 0 6px rgba(254, 44, 87, 0.28), 0 3px 8px rgba(0, 0, 0, 0.4); }
.lc-cluster-business { background: radial-gradient(circle at 30% 30%, #2fd1cb, #086b67); box-shadow: 0 0 0 6px rgba(14, 159, 154, 0.28), 0 3px 8px rgba(0, 0, 0, 0.4); }
.lc-cluster-mixed { background: radial-gradient(circle at 30% 30%, #8a8f98, #3d424a); box-shadow: 0 0 0 6px rgba(90, 95, 105, 0.28), 0 3px 8px rgba(0, 0, 0, 0.4); }

.lc-popup {
    width: 14.5rem;
}

.lc-popup-img {
    width: 100%;
    height: 7rem;
    object-fit: cover;
    border-radius: 0.5rem;
    margin-bottom: 0.45rem;
}

.lc-popup-price {
    font-size: 1.05rem;
    font-weight: 700;
}

.lc-popup .lc-popup-title {
    display: block;
    font-weight: 600;
    margin-bottom: 0.15rem;
    white-space: normal;
}

.leaflet-tooltip.lc-pin-tip {
    padding: 0.55rem;
    white-space: normal;
    border: 0;
    border-radius: 0.7rem;
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.3);
}

.leaflet-tooltip.lc-pin-tip::before {
    display: none;
}

.lc-mr-region {
    display: block;
    width: 100%;
    text-align: left;
    padding: 0.45rem 0.6rem;
    margin-bottom: 0.3rem;
    border: 1px solid var(--bs-border-color);
    border-radius: 0.6rem;
    background: var(--bs-body-bg);
    color: var(--bs-body-color);
    transition: border-color 0.15s ease, background 0.15s ease;
}

.lc-mr-region:hover,
.lc-mr-region:focus-visible {
    border-color: var(--lc-red, #fe2c57);
    background: var(--bs-tertiary-bg);
}

.lc-mr-region-count {
    min-width: 2rem;
}

.lc-mr-bar {
    display: flex;
    height: 0.35rem;
    margin: 0.4rem 0 0.3rem;
    border-radius: 0.3rem;
    overflow: hidden;
    background: var(--bs-secondary-bg);
}

.lc-mr-bar span:nth-child(1) { background: var(--mr-commercial); }
.lc-mr-bar span:nth-child(2) { background: var(--mr-residential); }
.lc-mr-bar span:nth-child(3) { background: var(--mr-business); }

.lc-mr-chip {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    padding: 0.1rem 0.5rem;
    border-radius: 1rem;
    background: var(--bs-secondary-bg);
    font-size: 0.75rem;
}

.lc-mr-chip button {
    border: 0;
    background: none;
    padding: 0;
    line-height: 1;
    color: inherit;
}

@media (min-width: 1200px) {
    .lc-mr-main {
        display: flex;
    }

    .lc-mr-card {
        flex: 1 1 auto;
        display: flex;
        flex-direction: column;
    }

    .lc-mr-mapwrap {
        flex: 1 1 auto;
        min-height: 36rem;
    }

    .lc-mr-map {
        position: absolute;
        inset: 0;
        height: auto;
        min-height: 0;
    }
}

@media (max-width: 1199.98px) {
    .lc-mr-map {
        height: 58vh;
    }
}
