.ibosim-lj-map-wrap {
    --lj-map-text: #1f2933;
    --lj-map-muted: #66717c;
    --lj-map-border: #dfe3e6;
    --lj-map-soft: #f6f7f7;
    width: 100%;
    margin: 22px 0;
    color: var(--lj-map-text);
    font: inherit;
}

.ibosim-lj-map-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px 28px;
    flex-wrap: wrap;
    padding: 14px 16px;
    background: #fff;
    border: 1px solid var(--lj-map-border);
    border-bottom: 0;
    border-radius: 10px 10px 0 0;
}

.ibosim-lj-map-filter-title {
    font-weight: 700;
    font-size: .96rem;
    white-space: nowrap;
}

.ibosim-lj-map-toolbar-right {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 10px;
    flex: 1;
    min-width: 0;
}

.ibosim-lj-map-filters {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 9px;
}

.ibosim-lj-map-filter {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 38px;
    padding: 7px 10px;
    margin: 0;
    border: 1px solid var(--lj-map-border);
    border-radius: 999px;
    background: #fff;
    cursor: pointer;
    font-size: .9rem;
    line-height: 1;
    user-select: none;
    transition: background .16s ease, border-color .16s ease, opacity .16s ease;
}

.ibosim-lj-map-filter:hover {
    background: var(--lj-map-soft);
    border-color: #c8cfd4;
}

.ibosim-lj-map-filter input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.ibosim-lj-map-filter:has(input:not(:checked)) {
    opacity: .48;
}

.ibosim-lj-map-filter small {
    display: inline-grid;
    place-items: center;
    min-width: 20px;
    height: 20px;
    padding: 0 5px;
    border-radius: 999px;
    background: var(--lj-map-soft);
    color: var(--lj-map-muted);
    font-size: .73rem;
    font-weight: 700;
}

.ibosim-lj-map-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--marker-color);
    box-shadow: 0 0 0 3px color-mix(in srgb, var(--marker-color) 16%, transparent);
}

.ibosim-lj-map-fullscreen {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 38px;
    padding: 7px 12px;
    border: 1px solid #c8cfd4;
    border-radius: 8px;
    background: #30383e;
    color: #fff;
    font: inherit;
    font-size: .88rem;
    font-weight: 700;
    line-height: 1;
    cursor: pointer;
    white-space: nowrap;
    transition: background .16s ease, transform .16s ease;
}

.ibosim-lj-map-fullscreen:hover {
    background: #1f262b;
}

.ibosim-lj-map-fullscreen:active {
    transform: translateY(1px);
}

.ibosim-lj-map-fullscreen-icon {
    position: relative;
    width: 14px;
    height: 14px;
    display: inline-block;
    background:
        linear-gradient(currentColor,currentColor) left top/6px 2px no-repeat,
        linear-gradient(currentColor,currentColor) left top/2px 6px no-repeat,
        linear-gradient(currentColor,currentColor) right top/6px 2px no-repeat,
        linear-gradient(currentColor,currentColor) right top/2px 6px no-repeat,
        linear-gradient(currentColor,currentColor) left bottom/6px 2px no-repeat,
        linear-gradient(currentColor,currentColor) left bottom/2px 6px no-repeat,
        linear-gradient(currentColor,currentColor) right bottom/6px 2px no-repeat,
        linear-gradient(currentColor,currentColor) right bottom/2px 6px no-repeat;
}

.ibosim-lj-map-canvas {
    width: 100%;
    min-height: 520px;
    border: 1px solid var(--lj-map-border);
    border-radius: 0 0 10px 10px;
    overflow: hidden;
    background: #e9edef;
    z-index: 1;
}

.ibosim-lj-map-empty {
    margin-top: 10px;
    padding: 11px 14px;
    border-radius: 7px;
    background: #f8f8f8;
    color: var(--lj-map-muted);
    font-size: .9rem;
}

.ibosim-lj-div-icon {
    background: transparent !important;
    border: 0 !important;
}

.ibosim-lj-marker {
    position: relative;
    display: block;
    width: 28px;
    height: 28px;
    border-radius: 50% 50% 50% 0;
    transform: rotate(-45deg);
    background: var(--marker-color);
    border: 3px solid #fff;
    box-shadow: 0 3px 10px rgba(17, 24, 39, .27);
}

.ibosim-lj-marker > span {
    position: absolute;
    inset: 7px;
    border-radius: 50%;
    background: #fff;
    opacity: .96;
}

.ibosim-lj-map-wrap .leaflet-popup-content-wrapper {
    padding: 0;
    overflow: hidden;
    border-radius: 10px;
    box-shadow: 0 10px 35px rgba(17, 24, 39, .2);
}

.ibosim-lj-map-wrap .leaflet-popup-content {
    margin: 0;
    width: 290px !important;
}

.ibosim-lj-popup-card { background: #fff; }

.ibosim-lj-popup-image {
    display: block;
    height: 145px;
    overflow: hidden;
    background: #eef1f2;
}

.ibosim-lj-popup-image img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.ibosim-lj-popup-body { padding: 15px 16px 16px; }

.ibosim-lj-popup-type {
    margin-bottom: 5px;
    color: #687078;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.ibosim-lj-popup-body h3 {
    margin: 0 0 6px;
    padding: 0;
    color: #1f2933;
    font-size: 17px;
    line-height: 1.25;
    font-weight: 750;
}

.ibosim-lj-popup-address,
.ibosim-lj-popup-meta {
    color: #5f6972;
    font-size: 13px;
    line-height: 1.45;
}

.ibosim-lj-popup-meta {
    margin-top: 5px;
    color: #303940;
    font-weight: 650;
}

.ibosim-lj-popup-button {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    margin-top: 12px;
    color: #222b31 !important;
    text-decoration: none !important;
    font-size: 13px;
    font-weight: 750;
}

.ibosim-lj-popup-button:hover { text-decoration: underline !important; }

/* Native browser fullscreen: filters + map fill the screen. */
.ibosim-lj-map-wrap:fullscreen,
.ibosim-lj-map-wrap:-webkit-full-screen {
    display: flex;
    flex-direction: column;
    width: 100vw;
    height: 100vh;
    margin: 0;
    padding: 0;
    background: #fff;
}

.ibosim-lj-map-wrap:fullscreen .ibosim-lj-map-toolbar,
.ibosim-lj-map-wrap:-webkit-full-screen .ibosim-lj-map-toolbar {
    flex: 0 0 auto;
    border-radius: 0;
    border-left: 0;
    border-right: 0;
    border-top: 0;
}

.ibosim-lj-map-wrap:fullscreen .ibosim-lj-map-canvas,
.ibosim-lj-map-wrap:-webkit-full-screen .ibosim-lj-map-canvas {
    flex: 1 1 auto;
    height: auto !important;
    min-height: 0;
    border: 0;
    border-radius: 0;
}

/* Fallback when Fullscreen API is unavailable/refused. */
.ibosim-lj-map-wrap.ibosim-lj-map-faux-fullscreen {
    position: fixed;
    inset: 0;
    z-index: 999999;
    display: flex;
    flex-direction: column;
    width: 100vw;
    height: 100vh;
    margin: 0;
    background: #fff;
}

.ibosim-lj-map-wrap.ibosim-lj-map-faux-fullscreen .ibosim-lj-map-toolbar {
    flex: 0 0 auto;
    border-radius: 0;
    border: 0;
    border-bottom: 1px solid var(--lj-map-border);
}

.ibosim-lj-map-wrap.ibosim-lj-map-faux-fullscreen .ibosim-lj-map-canvas {
    flex: 1 1 auto;
    height: auto !important;
    min-height: 0;
    border: 0;
    border-radius: 0;
}

body.ibosim-lj-map-no-scroll { overflow: hidden !important; }

@media (max-width: 900px) {
    .ibosim-lj-map-toolbar {
        align-items: flex-start;
    }

    .ibosim-lj-map-toolbar-right {
        width: 100%;
        justify-content: space-between;
        align-items: flex-start;
    }

    .ibosim-lj-map-filters {
        justify-content: flex-start;
    }
}

@media (max-width: 700px) {
    .ibosim-lj-map-toolbar { padding: 13px; }

    .ibosim-lj-map-toolbar-right {
        display: grid;
        grid-template-columns: 1fr auto;
        gap: 10px;
    }

    .ibosim-lj-map-filters {
        width: 100%;
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .ibosim-lj-map-filter {
        justify-content: flex-start;
        border-radius: 7px;
    }

    .ibosim-lj-map-filter small { margin-left: auto; }

    .ibosim-lj-map-fullscreen-text { display: none; }

    .ibosim-lj-map-fullscreen {
        width: 40px;
        padding: 0;
    }

    .ibosim-lj-map-canvas { min-height: 560px; }
}

@media (max-width: 480px) {
    .ibosim-lj-map-toolbar-right { grid-template-columns: 1fr; }

    .ibosim-lj-map-fullscreen {
        position: absolute;
        right: 13px;
        top: 12px;
    }

    .ibosim-lj-map-filter-title { padding-right: 48px; }
}
