/* ============================================================
   map.css (Map 2.1)
   Clean map layout, mobile selected-card polish, solid Leaflet popups.
   ============================================================ */

:root {
    --bottom-nav-h: 56px;
    --map2-panel-w: 380px;
    --map2-topbar-max-w: 980px;
    --map2-sheet-peek: 82px;
}

.map2 {
    position: relative;
    width: 100%;
    height: calc(100vh - var(--navbar-height));
    overflow: hidden;
}

.map2-map,
.map2-leaflet {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
}

/* Top controls */
.map2-topbar {
    position: absolute;
    top: 10px;
    left: 10px;
    right: 10px;
    z-index: 600;
    display: flex;
    flex-direction: column;
    gap: 10px;
    pointer-events: none;
}

.map2-searchbar,
.map2-chips,
.map2-filter-row {
    pointer-events: auto;
}

.map2-topbar::after {
    content: "›";
    position: absolute;
    right: 4px;
    top: 62px;
    z-index: 2;
    width: 28px;
    height: 76px;
    display: grid;
    place-items: center;
    border-radius: 999px;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,.92) 45%, rgba(255,255,255,.98));
    color: var(--sheep-green);
    font-size: 2rem;
    font-weight: 900;
    line-height: 1;
    pointer-events: none;
    animation: map2-scroll-nudge 1.45s ease-in-out infinite;
}

@keyframes map2-scroll-nudge {
    0%, 100% {
        transform: translateX(0);
        opacity: .72;
    }

    50% {
        transform: translateX(4px);
        opacity: 1;
    }
}

.map2-searchbar {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    border-radius: 999px;
    background: rgba(255,255,255,.94);
    border: 1px solid rgba(15,23,42,.10);
    backdrop-filter: blur(12px);
    box-shadow: 0 10px 28px rgba(15,23,42,.10);
}

.map2-search-icon,
.map2-clear,
.map2-theme,
.map2-locate,
.map2-search-locate {
    color: var(--sheep-gray);
    text-decoration: none;
}

.map2-search-input {
    border: 0 !important;
    box-shadow: none !important;
    background: transparent !important;
    padding: 0 !important;
}

.map2-search-locate {
    flex: 0 0 auto;
    width: 34px;
    height: 34px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    border-radius: 999px;
}

.map2-floating-locate {
    position: absolute;
    right: 14px;
    bottom: 18px;
    z-index: 640;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    min-width: 44px;
    height: 44px;
    padding: 0 14px;
    border: 1px solid rgba(15,23,42,.12);
    border-radius: 999px;
    background: rgba(255,255,255,.96);
    color: var(--sheep-green);
    font-weight: 900;
    line-height: 1;
    backdrop-filter: blur(12px);
    box-shadow: 0 12px 28px rgba(15,23,42,.16);
}

    .map2-floating-locate i {
        font-size: 1.08rem;
    }

    .map2-floating-locate:hover,
    .map2-floating-locate:focus {
        border-color: rgba(44,119,68,.35);
        background: #fff;
        color: var(--sheep-green);
    }

/* Horizontal filter rows */
.map2-chips,
.map2-filter-row {
    display: flex;
    flex-wrap: nowrap;
    overflow-x: auto;
    overflow-y: hidden;
    scrollbar-width: thin;
    scrollbar-color: rgba(44,119,68,.46) transparent;
    scroll-behavior: smooth;
    overscroll-behavior-inline: contain;
    -webkit-overflow-scrolling: touch;
    cursor: ew-resize;
}

.map2-chips {
    gap: 9px;
    padding: 2px 2px 9px;
}

.map2-filter-row {
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 0 2px 9px;
}

    .map2-chips::-webkit-scrollbar,
    .map2-filter-row::-webkit-scrollbar {
        height: 7px;
    }

    .map2-chips::-webkit-scrollbar-track,
    .map2-filter-row::-webkit-scrollbar-track {
        background: transparent;
    }

    .map2-chips::-webkit-scrollbar-thumb,
    .map2-filter-row::-webkit-scrollbar-thumb {
        background: rgba(44,119,68,.42);
        border-radius: 999px;
    }

        .map2-chips::-webkit-scrollbar-thumb:hover,
        .map2-filter-row::-webkit-scrollbar-thumb:hover {
            background: rgba(44,119,68,.70);
        }

.map2-chip,
.map2-distance-chip {
    display: inline-flex;
    align-items: center;
    white-space: nowrap;
    border-radius: 999px;
    background: rgba(255,255,255,.96);
    border: 1px solid rgba(15,23,42,.10);
    color: #1f2937;
    box-shadow: 0 8px 22px rgba(15,23,42,.08);
    backdrop-filter: blur(12px);
    transition: transform 140ms ease, box-shadow 140ms ease, border-color 140ms ease, background-color 140ms ease, color 140ms ease;
}

.map2-chip {
    gap: 8px;
    min-height: 58px;
    padding: 9px 14px;
    font-size: .9rem;
    font-weight: 750;
}

    .map2-chip i {
        color: var(--sheep-green);
        font-size: 1.12rem;
    }

.map2-chip-icon {
    width: 40px !important;
    height: 40px !important;
    max-width: 40px !important;
    max-height: 40px !important;
    flex: 0 0 40px !important;
    object-fit: contain !important;
    border-radius: 12px;
    background: rgba(255,255,255,.88);
    padding: 2px;
}

.map2-chip:hover,
.map2-distance-chip:hover {
    transform: translateY(-1px);
    border-color: rgba(44,119,68,.35);
    box-shadow: 0 12px 26px rgba(15,23,42,.13);
}

.map2-chip.active {
    background: linear-gradient(135deg, var(--sheep-green), #174828);
    border-color: rgba(44,119,68,.85);
    color: #fff;
    box-shadow: 0 12px 30px rgba(44,119,68,.28);
}

    .map2-chip.active i {
        color: #fff;
    }

    .map2-chip.active .map2-chip-icon {
        background: rgba(255,255,255,.96);
    }

.map2-distance-chip {
    gap: 7px;
    padding: 8px 12px;
    font-size: .84rem;
    font-weight: 850;
}

    .map2-distance-chip i {
        color: var(--sheep-green);
    }

    .map2-distance-chip.active {
        background: rgba(44,119,68,.14);
        border-color: rgba(44,119,68,.42);
        color: var(--sheep-green);
    }

/* Selected supplier / deliverer overlay */
.map2-selected {
    position: absolute;
    left: 10px;
    right: 10px;
    bottom: 92px;
    z-index: 650;
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 10px;
    padding: 12px;
    border-radius: 20px;
    background: rgba(255,255,255,.98);
    border: 1px solid rgba(15,23,42,.12);
    backdrop-filter: blur(14px);
    box-shadow: 0 20px 46px rgba(15,23,42,.20);
}

.map2-selected-deliverer {
    border-color: rgba(242,140,56,.25);
}

.map2-selected-main {
    display: grid;
    grid-template-columns: 48px minmax(0, 1fr);
    gap: 10px;
    align-items: center;
    min-width: 0;
}

.map2-selected-icon {
    width: 48px !important;
    height: 48px !important;
    max-width: 48px !important;
    max-height: 48px !important;
    object-fit: contain !important;
    border-radius: 14px;
    background: rgba(44,119,68,.10);
    padding: 3px;
    box-shadow: 0 8px 18px rgba(15,23,42,.10);
}

.map2-selected-copy,
.map2-selected-left {
    min-width: 0;
    overflow: hidden;
}

.map2-selected-left {
    font-weight: 800;
    line-height: 1.15;
    font-size: .98rem;
}

.map2-selected-eyebrow {
    display: flex;
    align-items: center;
    gap: 5px;
    min-width: 0;
    margin-bottom: 3px;
    color: var(--sheep-green);
    font-size: .76rem;
    font-weight: 900;
    line-height: 1.1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.map2-selected-dot {
    color: #94a3b8;
}

.map2-selected-verified {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    flex: 0 0 auto;
    margin-left: 3px;
    padding: 3px 6px;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--sheep-green), #174828);
    color: #fff;
    font-size: .68rem;
    font-weight: 900;
}

.map2-selected-test,
.map2-row-test-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    flex: 0 0 auto;
    padding: 3px 7px;
    border-radius: 999px;
    background: rgba(242,140,56,.16);
    color: #9a4f0f;
    border: 1px solid rgba(242,140,56,.30);
    font-size: .68rem;
    font-weight: 950;
    line-height: 1;
}

.map2-row-test-badge {
    margin-left: 7px;
    vertical-align: middle;
}

.map2-selected-title {
    min-width: 0;
    color: #142033;
    font-size: 1rem;
    font-weight: 950;
    line-height: 1.12;
    letter-spacing: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.map2-selected-sub {
    display: flex;
    align-items: flex-start;
    gap: 6px;
    min-width: 0;
    margin-top: 5px;
    color: #64748b;
    font-size: .8rem;
    line-height: 1.25;
}

    .map2-selected-sub i {
        color: var(--sheep-green);
        flex: 0 0 auto;
        margin-top: 1px;
    }

    .map2-selected-sub span {
        min-width: 0;
        display: -webkit-box;
        -webkit-line-clamp: 2;
        -webkit-box-orient: vertical;
        overflow: hidden;
    }

.map2-selected-category {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    max-width: 100%;
    margin-top: 8px;
    padding: 5px 8px;
    border-radius: 999px;
    background: rgba(44,119,68,.08);
    color: var(--sheep-green);
    font-size: .8rem;
    font-weight: 850;
}

    .map2-selected-category img {
        width: 24px !important;
        height: 24px !important;
        max-width: 24px !important;
        max-height: 24px !important;
        object-fit: contain !important;
        border-radius: 8px;
        flex: 0 0 auto;
    }

.map2-selected-actions {
    display: grid;
    grid-template-columns: 42px minmax(0, 1fr) 42px;
    gap: 8px;
    width: 100%;
    padding: 0;
}

    .map2-selected-actions .map2-action {
        min-height: 42px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        gap: 7px;
        padding: .55rem .75rem;
        border-radius: 999px;
        font-weight: 900;
        line-height: 1;
    }

    .map2-selected-actions .map2-center,
    .map2-selected-actions .map2-close {
        width: 42px;
        padding: 0;
    }

    .map2-selected-actions .map2-open-menu {
        width: 100%;
        min-width: 0;
    }

.map2-openmenu-text {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.map2-test-banner {
    position: absolute;
    right: 12px;
    bottom: 94px;
    z-index: 660;
    display: flex;
    align-items: center;
    gap: 10px;
    max-width: min(360px, calc(100vw - 24px));
    padding: 11px 13px;
    border-radius: 18px;
    background: rgba(255,255,255,.96);
    border: 1px solid rgba(242,140,56,.28);
    color: #334155;
    box-shadow: 0 18px 40px rgba(15,23,42,.16);
    backdrop-filter: blur(12px);
}

.map2-test-banner strong,
.map2-test-banner span {
    display: block;
}

.map2-test-banner strong {
    color: #9a4f0f;
    font-size: .82rem;
    font-weight: 950;
    line-height: 1.1;
}

.map2-test-banner span:not(.map2-test-pulse) {
    color: #64748b;
    font-size: .76rem;
    font-weight: 700;
    line-height: 1.2;
}

.map2-test-pulse,
.popup-test-dot,
.sheep-simulation-marker-pulse {
    flex: 0 0 auto;
    width: 10px;
    height: 10px;
    border-radius: 999px;
    background: #f28c38;
    box-shadow: 0 0 0 6px rgba(242,140,56,.18);
}

/* Desktop side panel */
.map2-panel {
    position: absolute;
    top: var(--navbar-height);
    bottom: 0;
    left: 0;
    z-index: 700;
    width: var(--map2-panel-w);
    display: flex;
    flex-direction: column;
    background: rgba(255,255,255,.96);
    border-right: 1px solid rgba(15,23,42,.08);
    backdrop-filter: blur(10px);
}

.map2-panel-header {
    padding: 14px 16px;
    border-bottom: 1px solid rgba(15,23,42,.08);
}

.map2-panel-body {
    overflow: auto;
    padding: 8px;
}

.map2-panel-sort {
    max-width: 170px;
}

/* Supplier result rows */
.map2-row {
    display: flex;
    align-items: center;
    gap: 12px;
    min-height: 72px;
    margin: 8px 0;
    padding: 12px;
    border-radius: var(--radius);
    border: 1px solid rgba(15,23,42,.08);
    background: rgba(255,255,255,.92);
    box-shadow: 0 8px 22px rgba(15,23,42,.05);
    cursor: pointer;
}

    .map2-row.selected {
        border-color: rgba(44,119,68,.55);
        background: rgba(44,119,68,.10);
        box-shadow: 0 12px 30px rgba(44,119,68,.16);
    }

.map2-row-main {
    min-width: 0;
    flex: 1 1 auto;
    display: grid;
    grid-template-rows: auto 46px auto;
    align-content: center;
    gap: 7px;
    overflow: hidden;
}

.map2-row-title {
    color: #18212f;
    font-weight: 800;
}

.map2-row-heading {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 0;
    min-width: 0;
}

    .map2-row-heading .map2-row-title {
        min-width: 0;
        flex: 1 1 auto;
    }

.map2-row-sub,
.map2-row-desc {
    color: var(--sheep-gray);
    font-size: .9rem;
}

.map2-row-desc {
    margin-top: 4px;
}

.map2-row-right {
    margin-left: auto;
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
}

.map2-row-rich {
    align-items: stretch;
    gap: 12px;
    min-height: 108px;
    padding: 8px 10px;
}

.map2-row-photo {
    position: relative;
    width: 104px !important;
    height: auto !important;
    min-height: 92px;
    max-width: 104px !important;
    max-height: none !important;
    flex: 0 0 104px !important;
    align-self: stretch;
    display: grid;
    place-items: center;
    overflow: hidden;
    border-radius: 14px;
    background: rgba(44,119,68,.10);
}

    .map2-row-business-photo,
    .map2-row-photo > img:not(.map2-row-business-photo):not(.map2-row-category-icon) {
        position: absolute;
        inset: 0;
        width: 100% !important;
        height: 100% !important;
        max-width: 100% !important;
        max-height: 100% !important;
        object-fit: cover !important;
        z-index: 2;
    }

.map2-row-photo-fallback {
    position: absolute;
    inset: 0;
    z-index: 1;
    display: grid;
    place-items: center;
    color: var(--sheep-green);
    font-size: 1.35rem;
}

    .map2-row-category-icon,
    .map2-row-photo-fallback img {
        width: 52px !important;
        height: 52px !important;
        max-width: 52px !important;
        max-height: 52px !important;
        object-fit: contain !important;
        border-radius: 14px;
    }

.map2-row-photo.image-failed .map2-row-business-photo,
.map2-row-photo.image-failed > img:not(.map2-row-category-icon) {
    display: none !important;
}

.map2-row-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px;
    margin-top: 4px;
}

.map2-row-category,
.map2-menu-pill {
    display: inline-flex;
    align-items: center;
    border-radius: 999px;
    background: rgba(44,119,68,.08);
    border: 1px solid rgba(44,119,68,.10);
}

.map2-row-category {
    gap: 5px;
    max-width: 100%;
    padding: 3px 7px 3px 4px;
    color: var(--sheep-green);
    font-size: .76rem;
    font-weight: 800;
}

    .map2-row-category img {
        width: 20px !important;
        height: 20px !important;
        max-width: 20px !important;
        max-height: 20px !important;
        object-fit: contain !important;
        border-radius: 7px;
    }

.map2-row-distance {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    color: #64748b;
    font-size: .76rem;
    font-weight: 800;
}

.map2-menu-preview {
    display: flex;
    flex-wrap: nowrap;
    align-items: center;
    gap: 6px;
    width: 100%;
    min-width: 0;
    height: 50px;
    overflow-x: auto;
    overflow-y: hidden;
    overscroll-behavior-x: contain;
    -webkit-overflow-scrolling: touch;
    scroll-snap-type: x proximity;
    scrollbar-width: thin;
    scrollbar-color: rgba(44,119,68,.32) transparent;
    cursor: grab;
}

    .map2-menu-preview:active {
        cursor: grabbing;
    }

    .map2-menu-preview::-webkit-scrollbar {
        height: 5px;
    }

    .map2-menu-preview::-webkit-scrollbar-track {
        background: transparent;
    }

    .map2-menu-preview::-webkit-scrollbar-thumb {
        background: rgba(44,119,68,.35);
        border-radius: 999px;
    }

        .map2-menu-preview::-webkit-scrollbar-thumb:hover {
            background: rgba(44,119,68,.60);
        }

.map2-menu-pill {
    justify-content: center;
    flex: 0 0 42px;
    width: 42px;
    height: 42px;
    min-width: 42px;
    max-width: 42px;
    padding: 0;
    color: var(--bs-body-color);
    font-size: .78rem;
    line-height: 1;
    overflow: hidden;
    border-radius: 9px;
    scroll-snap-align: start;
}

    .map2-menu-pill img {
        display: block;
        width: 42px !important;
        height: 42px !important;
        max-width: 42px !important;
        max-height: 42px !important;
        flex: 0 0 42px;
        border-radius: 9px;
        object-fit: cover !important;
    }

.map2-food-tags {
    display: flex;
    flex-wrap: nowrap;
    gap: 6px;
    width: 100%;
    overflow-x: auto;
    overflow-y: hidden;
    scrollbar-width: thin;
    scrollbar-color: rgba(44,119,68,.32) transparent;
    -webkit-overflow-scrolling: touch;
}

.map2-food-tags::-webkit-scrollbar {
    height: 5px;
}

.map2-food-tags::-webkit-scrollbar-track {
    background: transparent;
}

.map2-food-tags::-webkit-scrollbar-thumb {
    background: rgba(44,119,68,.35);
    border-radius: 999px;
}

.map2-menu-preview::-webkit-scrollbar {
    display: none;
}

.map2-food-tag {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    padding: 4px 10px;
    border-radius: 999px;
    border: 1px solid rgba(15,23,42,.10);
    background: rgba(255,255,255,.92);
    color: #142033;
    font-size: .78rem;
    font-weight: 850;
    line-height: 1;
    white-space: nowrap;
}

/* Bottom sheet */
.map2-sheet {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 800;
    background: rgba(255,255,255,.96);
    border-top: 1px solid rgba(15,23,42,.08);
    border-top-left-radius: 18px;
    border-top-right-radius: 18px;
    backdrop-filter: blur(10px);
    transition: transform 220ms ease;
    padding-bottom: env(safe-area-inset-bottom);
}

    .map2-sheet.peek {
        transform: translateY(calc(100% - 84px));
    }

    .map2-sheet.half {
        transform: translateY(calc(100% - 52vh));
    }

    .map2-sheet.full {
        transform: translateY(calc(100% - 86vh));
    }

.map2-sheet-handlebar {
    padding: 10px 0 0;
}

.map2-sheet-handle {
    width: 44px;
    height: 5px;
    margin: 0 auto;
    border-radius: 99px;
    background: rgba(0,0,0,.18);
}

.map2-sheet-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 14px;
}

.map2-sheet-sort-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 0 14px 10px;
}

    .map2-sheet-sort-row .map2-locate {
        flex: 0 0 auto;
        display: inline-flex;
        align-items: center;
        gap: 6px;
        padding: 0;
        font-weight: 800;
    }

    .map2-sheet-sort-row .map2-panel-sort {
        flex: 0 1 170px;
    }

.map2-sheet-title {
    font-weight: 700;
}

.map2-sheet-body {
    max-height: 86vh;
    overflow: auto;
    padding: 0 12px 12px;
    -webkit-overflow-scrolling: touch;
}

.map2-sheet-list {
    padding-bottom: 90px;
}

/* Launch announcement */
.map2-launch-map-card,
.map2-launch-panel-card,
.map2-launch-sheet-card {
    border: 1px solid rgba(242,140,56,.26);
    background: radial-gradient(circle at top left, rgba(255,211,125,.36), transparent 42%), linear-gradient(135deg, rgba(255,255,255,.98), rgba(255,250,237,.96));
    box-shadow: 0 16px 38px rgba(15,23,42,.14);
    color: #1f2937;
}

.map2-launch-map-card {
    position: absolute;
    top: 14px;
    right: 14px;
    z-index: 590;
    max-width: min(330px, calc(100% - 28px));
    padding: 13px 15px;
    border-radius: 22px;
    backdrop-filter: blur(14px);
    pointer-events: auto;
}

.map2-launch-panel-card,
.map2-launch-sheet-card {
    display: flex;
    gap: 12px;
    margin: 8px 0 10px;
    padding: 14px;
    border-radius: 20px;
    backdrop-filter: blur(12px);
}

.map2-launch-sheet-card {
    margin: 0 0 12px;
}

.map2-launch-map-kicker,
.map2-launch-card-kicker {
    color: var(--sheep-orange);
    font-weight: 950;
    text-transform: uppercase;
    letter-spacing: .07em;
}

.map2-launch-map-kicker {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    font-size: .78rem;
}

.map2-launch-card-kicker {
    font-size: .72rem;
}

.map2-launch-map-title,
.map2-launch-card-title {
    margin-top: 2px;
    font-weight: 950;
    line-height: 1.12;
    letter-spacing: 0;
}

.map2-launch-map-title {
    font-size: 1rem;
}

.map2-launch-card-title {
    font-size: 1rem;
}

.map2-launch-map-body,
.map2-launch-card-body {
    color: #64748b;
    line-height: 1.35;
}

.map2-launch-map-body {
    margin-top: 3px;
    font-size: .84rem;
}

.map2-launch-card-body {
    margin-top: 6px;
    font-size: .88rem;
}

.map2-launch-card-icon {
    width: 42px;
    height: 42px;
    flex: 0 0 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 16px;
    background: linear-gradient(135deg, var(--sheep-orange), #ffd37d);
    color: #2b1604;
    box-shadow: 0 10px 22px rgba(242,140,56,.28);
}

    .map2-launch-card-icon i {
        font-size: 1.15rem;
    }

.map2-launch-card-copy {
    min-width: 0;
}

.map2-launch-card-note {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-top: 10px;
    padding: 6px 9px;
    border-radius: 999px;
    background: rgba(44,119,68,.10);
    color: var(--sheep-green);
    font-size: .78rem;
    font-weight: 900;
}

/* Leaflet controls, markers, popups */
.map2 .leaflet-control-zoom {
    border: 0;
    border-radius: 14px;
    overflow: hidden;
    box-shadow: 0 10px 24px rgba(15,23,42,.16);
}

    .map2 .leaflet-control-zoom a {
        width: 38px;
        height: 38px;
        line-height: 38px;
        border-radius: 0 !important;
        font-size: 1.25rem;
    }

.leaflet-sheep-div-icon {
    background: transparent !important;
    border: 0 !important;
    overflow: visible !important;
}

.sheep-marker-image-wrap {
    display: grid;
    place-items: center;
    overflow: visible;
    filter: drop-shadow(0 8px 13px rgba(15,23,42,.32));
}

.sheep-marker-img {
    display: block !important;
    user-select: none;
    -webkit-user-drag: none;
}

.leaflet-marker-icon.leaflet-sheep-div-icon,
.leaflet-marker-icon.leaflet-sheep-div-icon img,
.leaflet-marker-icon.leaflet-sheep-div-icon .sheep-marker-img {
    box-sizing: border-box;
}

.leaflet-marker-icon.leaflet-sheep-div-icon .sheep-supplier-marker-img {
    width: 48px !important;
    height: 48px !important;
    max-width: 48px !important;
    max-height: 48px !important;
}

.leaflet-marker-icon.leaflet-sheep-div-icon .sheep-deliverer-marker-img {
    width: 48px !important;
    height: 64px !important;
    max-width: 48px !important;
    max-height: 64px !important;
}

.leaflet-marker-icon.leaflet-sheep-div-icon .sheep-client-marker-img {
    width: 42px !important;
    height: 42px !important;
    max-width: 42px !important;
    max-height: 42px !important;
}

.sheep-you-are-here-popup {
    min-width: 180px;
    padding: 14px;
}

.sheep-you-are-here-title {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0 0 8px;
    color: var(--sheep-green);
    font-size: .98rem;
    font-weight: 950;
}

.sheep-you-are-here-body {
    margin: 0;
    color: #64748b;
    font-size: .82rem;
    line-height: 1.35;
}

.sheep-supplier-marker-wrap {
    border-radius: 15px;
    background: rgba(255,255,255,.92);
}

.sheep-supplier-marker-img {
    border-radius: 14px;
}

.sheep-deliverer-marker-wrap {
    filter: drop-shadow(0 9px 14px rgba(15,23,42,.34));
}

.sheep-deliverer-marker-img {
    border-radius: 0;
}

.sheep-popup-container .leaflet-popup-content-wrapper {
    background: #fff !important;
    border-radius: 22px !important;
    overflow: hidden;
    border: 1px solid rgba(15,23,42,.12);
    box-shadow: 0 22px 55px rgba(15,23,42,.26);
    padding: 0;
}

.sheep-popup-container .leaflet-popup-content {
    margin: 0 !important;
}

.sheep-popup-container .leaflet-popup-tip {
    background: #fff !important;
    border: 1px solid rgba(15,23,42,.10);
    box-shadow: 0 8px 18px rgba(15,23,42,.12);
}

.sheep-popup-container .leaflet-popup-close-button {
    top: 8px !important;
    right: 8px !important;
    z-index: 5;
    width: 30px !important;
    height: 30px !important;
    display: grid !important;
    place-items: center !important;
    padding: 0 !important;
    border-radius: 999px !important;
    background: rgba(255,255,255,.96) !important;
    border: 1px solid rgba(15,23,42,.14) !important;
    color: #334155 !important;
    font-size: 1.1rem !important;
    line-height: 1 !important;
    text-decoration: none !important;
    box-shadow: 0 8px 20px rgba(15,23,42,.14);
}

    .sheep-popup-container .leaflet-popup-close-button:hover {
        background: #fff !important;
        color: var(--sheep-green) !important;
    }

.sheep-popup {
    min-width: 275px;
    overflow: hidden;
    border-radius: 22px;
    background: #fff;
    color: #1f2937;
    font-family: system-ui, sans-serif;
    text-align: left;
    padding: 12px;
}

.popup-image {
    width: calc(100% + 24px) !important;
    height: 128px !important;
    max-width: calc(100% + 24px) !important;
    max-height: 128px !important;
    object-fit: cover !important;
    display: block;
    margin: -12px -12px 0;
}

.popup-category,
.popup-address {
    display: flex;
    background: rgba(44,119,68,.07);
    text-align: left;
}

.popup-category {
    align-items: center;
    justify-content: flex-start;
    gap: 8px;
    margin: .75rem 0 0;
    padding: .55rem .65rem;
    border-radius: 14px;
    color: var(--sheep-green);
    font-size: .82rem;
    font-weight: 900;
}

    .popup-category img {
        width: 32px !important;
        height: 32px !important;
        max-width: 32px !important;
        max-height: 32px !important;
        flex: 0 0 32px;
        object-fit: contain !important;
        border-radius: 10px;
    }

.popup-title {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    flex-wrap: wrap;
    gap: 8px;
    margin: 0;
    padding: .75rem 2.6rem .1rem 0;
    color: var(--sheep-green);
    font-size: 1.08rem;
    font-weight: 900;
    line-height: 1.15;
    letter-spacing: 0;
    text-align: left;
}

.popup-title.is-test {
    color: #9a4f0f;
}

.verified-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 5px 8px;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--sheep-green), #174828);
    color: #fff;
    font-size: .72rem;
    font-weight: 800;
    line-height: 1;
}

.popup-desc {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin: .25rem 0 .65rem;
    color: #64748b;
    font-size: .86rem;
    line-height: 1.35;
    text-align: left;
}

.popup-address {
    align-items: flex-start;
    gap: 8px;
    margin: 0 0 .75rem;
    padding: .7rem .8rem;
    border-radius: 14px;
    color: #475569;
    font-size: .84rem;
    line-height: 1.25;
}

    .popup-address i {
        flex: 0 0 auto;
        margin-top: 1px;
        color: var(--sheep-green);
    }

    .popup-address span {
        min-width: 0;
        overflow-wrap: anywhere;
        text-align: left;
    }

.popup-test-banner {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: .85rem 0 0;
    padding: .55rem .65rem;
    border-radius: 14px;
    background: rgba(242,140,56,.14);
    border: 1px solid rgba(242,140,56,.26);
    color: #9a4f0f;
    font-size: .8rem;
    font-weight: 950;
    line-height: 1;
    text-align: left;
}

.popup-btn-test {
    background: linear-gradient(135deg, #f28c38, #b85d13);
    box-shadow: 0 10px 24px rgba(242,140,56,.24);
}

.sheep-simulation-supplier-wrap,
.sheep-test-deliverer-marker-wrap {
    position: relative;
    display: grid;
    place-items: center;
    width: 54px;
    height: 54px;
    max-width: 54px;
    max-height: 54px;
    border-radius: 18px;
    background: rgba(255,255,255,.96);
    border: 2px solid rgba(242,140,56,.88);
    box-shadow: 0 14px 28px rgba(15,23,42,.18);
}

.sheep-simulation-deliverer-wrap,
.sheep-test-deliverer-marker-wrap {
    position: relative;
    display: grid;
    place-items: center;
    width: 54px;
    height: 68px;
    max-width: 54px;
    max-height: 68px;
    background: transparent;
    border: 0;
    box-shadow: none;
}

.sheep-simulation-deliverer-wrap::before {
    content: "";
    position: absolute;
    left: 50%;
    top: 50%;
    z-index: -1;
    width: 52px;
    height: 52px;
    border-radius: 999px;
    transform: translate(-50%, -46%);
    border: 3px solid rgba(25,135,84,.95);
    background: rgba(25,135,84,.18);
    box-shadow: 0 10px 24px rgba(15,23,42,.22);
}

.sheep-simulation-deliverer-wrap-pending::before {
    border-color: rgba(255,193,7,.98);
    background: rgba(255,193,7,.22);
}

.sheep-simulation-deliverer-wrap-active::before {
    border-color: rgba(13,110,253,.98);
    background: rgba(13,110,253,.2);
}

.sheep-simulation-deliverer-wrap-pickup::before {
    border-color: rgba(242,140,56,.98);
    background: rgba(242,140,56,.22);
}

.sheep-simulation-deliverer-wrap-delivery::before {
    border-color: rgba(13,110,253,.98);
    background: rgba(13,110,253,.2);
}

.sheep-simulation-deliverer-wrap-problem::before {
    border-color: rgba(220,53,69,.98);
    background: rgba(220,53,69,.18);
}

.sheep-simulation-status-banner {
    justify-content: center;
    font-weight: 900;
}

.sheep-simulation-status-available {
    background: rgba(25,135,84,.12);
    color: #146c43;
}

.sheep-simulation-status-pending {
    background: rgba(255,193,7,.22);
    color: #8a5a00;
}

.sheep-simulation-status-active {
    background: rgba(13,110,253,.14);
    color: #084298;
}

.sheep-simulation-status-pickup {
    background: rgba(242,140,56,.18);
    color: #9a4f0f;
}

.sheep-simulation-status-delivery {
    background: rgba(13,110,253,.14);
    color: #084298;
}

.sheep-simulation-status-problem {
    background: rgba(220,53,69,.14);
    color: #842029;
}

.sheep-simulation-client-wrap {
    position: relative;
    display: grid;
    place-items: center;
    width: 52px;
    height: 58px;
    max-width: 52px;
    max-height: 58px;
    border-radius: 18px;
    background: rgba(255,255,255,.96);
    border: 3px solid rgba(255,193,7,.98);
    box-shadow: 0 14px 28px rgba(15,23,42,.2);
}

.sheep-simulation-client-wrap-assigned {
    border-color: rgba(13,110,253,.98);
    background: rgba(232,241,255,.98);
}

.sheep-simulation-client-wrap-in_transit {
    border-color: rgba(25,135,84,.98);
    background: rgba(231,247,239,.98);
}

.sheep-simulation-client-wrap-problem {
    border-color: rgba(220,53,69,.98);
    background: rgba(255,235,238,.98);
}

.sheep-simulation-client-status-waiting {
    background: rgba(255,193,7,.22);
    color: #8a5a00;
}

.sheep-simulation-client-status-assigned {
    background: rgba(13,110,253,.14);
    color: #084298;
}

.sheep-simulation-client-status-in_transit {
    background: rgba(25,135,84,.12);
    color: #146c43;
}

.sheep-simulation-client-status-problem {
    background: rgba(220,53,69,.14);
    color: #842029;
}

.sheep-test-marker-label {
    position: absolute;
    left: 50%;
    top: -4px;
    z-index: 2;
    transform: translateX(-50%);
    padding: 2px 6px;
    border-radius: 999px;
    background: rgba(242,140,56,.96);
    color: #fff;
    font-size: 8px;
    font-weight: 950;
    line-height: 1;
    box-shadow: 0 3px 8px rgba(15,23,42,.18);
}

.sheep-simulation-marker-pulse {
    position: absolute;
    top: -4px;
    right: -4px;
    animation: sheep-sim-pulse 1.35s ease-in-out infinite;
}

@keyframes sheep-sim-pulse {
    0%, 100% {
        transform: scale(.9);
        opacity: .72;
    }

    50% {
        transform: scale(1.12);
        opacity: 1;
    }
}

.popup-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: calc(100% - 1.7rem);
    margin: 0 auto .85rem;
    padding: .72rem 1.2rem;
    border: 0;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--sheep-green), #174828);
    color: #fff !important;
    font-weight: 850;
    text-align: center;
    text-decoration: none;
    box-shadow: 0 10px 24px rgba(44,119,68,.24);
    transition: transform .18s ease, box-shadow .18s ease, filter .18s ease;
}

    .popup-btn:hover,
    .popup-btn:focus {
        color: #fff !important;
        transform: translateY(-1px);
        filter: brightness(1.05);
        box-shadow: 0 14px 30px rgba(44,119,68,.32);
    }

.sheep-popup a:not(.popup-btn) {
    color: var(--sheep-green);
    text-decoration: underline;
}

    .sheep-popup a:not(.popup-btn):hover {
        color: var(--sheep-orange);
    }

/* Dark theme */
[data-theme="dark"] .map2-topbar::after,
body[data-theme="dark"] .map2-topbar::after {
    background: linear-gradient(90deg, transparent, rgba(15,23,42,.80) 45%, rgba(15,23,42,.94));
    color: var(--sheep-green-light);
}

[data-theme="dark"] .map2-searchbar,
[data-theme="dark"] .map2-chip,
[data-theme="dark"] .map2-distance-chip,
[data-theme="dark"] .map2-floating-locate,
body[data-theme="dark"] .map2-searchbar,
body[data-theme="dark"] .map2-chip,
body[data-theme="dark"] .map2-distance-chip,
body[data-theme="dark"] .map2-floating-locate {
    background: rgba(15,23,42,.88);
    border-color: rgba(255,255,255,.10);
    color: #e2e8f0;
    box-shadow: 0 10px 26px rgba(0,0,0,.32);
}

    [data-theme="dark"] .map2-chip i,
    [data-theme="dark"] .map2-distance-chip i,
    body[data-theme="dark"] .map2-chip i,
    body[data-theme="dark"] .map2-distance-chip i {
        color: var(--sheep-green-light);
    }

    [data-theme="dark"] .map2-chip:hover,
    body[data-theme="dark"] .map2-chip:hover {
        border-color: rgba(114,205,139,.35);
        background: rgba(30,41,59,.96);
    }

    [data-theme="dark"] .map2-chip.active,
    body[data-theme="dark"] .map2-chip.active {
        background: linear-gradient(135deg, #2c7744, #72cd8b);
        border-color: rgba(114,205,139,.7);
        color: #07140b;
    }

        [data-theme="dark"] .map2-chip.active i,
        body[data-theme="dark"] .map2-chip.active i {
            color: #07140b;
        }

    [data-theme="dark"] .map2-distance-chip.active,
    body[data-theme="dark"] .map2-distance-chip.active {
        background: rgba(114,205,139,.14);
        border-color: rgba(114,205,139,.35);
        color: var(--sheep-green-light);
    }

[data-theme="dark"] .map2-selected,
body[data-theme="dark"] .map2-selected {
    background: rgba(15,23,42,.94);
    border-color: rgba(255,255,255,.12);
    color: #e2e8f0;
    box-shadow: 0 20px 46px rgba(0,0,0,.42);
}

[data-theme="dark"] .map2-selected-title,
[data-theme="dark"] .map2-row-title,
body[data-theme="dark"] .map2-selected-title,
body[data-theme="dark"] .map2-row-title {
    color: #e2e8f0;
}

[data-theme="dark"] .map2-selected-sub,
[data-theme="dark"] .map2-row-sub,
[data-theme="dark"] .map2-row-desc,
[data-theme="dark"] .map2-row-distance,
body[data-theme="dark"] .map2-selected-sub,
body[data-theme="dark"] .map2-row-sub,
body[data-theme="dark"] .map2-row-desc,
body[data-theme="dark"] .map2-row-distance {
    color: #94a3b8;
}

[data-theme="dark"] .map2-selected-eyebrow,
body[data-theme="dark"] .map2-selected-eyebrow {
    color: var(--sheep-green-light);
}

[data-theme="dark"] .map2-selected-icon,
[data-theme="dark"] .map2-selected-category,
[data-theme="dark"] .map2-row-category,
[data-theme="dark"] .map2-menu-pill,
body[data-theme="dark"] .map2-selected-icon,
body[data-theme="dark"] .map2-selected-category,
body[data-theme="dark"] .map2-row-category,
body[data-theme="dark"] .map2-menu-pill {
    background: rgba(114,205,139,.10);
    border-color: rgba(114,205,139,.16);
    color: var(--sheep-green-light);
}

[data-theme="dark"] .map2-panel,
[data-theme="dark"] .map2-sheet,
body[data-theme="dark"] .map2-panel,
body[data-theme="dark"] .map2-sheet {
    background: rgba(15,23,42,.90);
    border-color: rgba(255,255,255,.10);
    color: #e2e8f0;
}

[data-theme="dark"] .map2-panel-header,
body[data-theme="dark"] .map2-panel-header {
    border-color: rgba(255,255,255,.10);
}

[data-theme="dark"] .map2-row,
body[data-theme="dark"] .map2-row {
    background: rgba(15,23,42,.65);
    border-color: rgba(255,255,255,.10);
    box-shadow: 0 10px 26px rgba(0,0,0,.20);
}

    [data-theme="dark"] .map2-row.selected,
    body[data-theme="dark"] .map2-row.selected {
        border-color: rgba(114,205,139,.50);
        background: rgba(114,205,139,.10);
        box-shadow: 0 12px 30px rgba(114,205,139,.12);
    }

[data-theme="dark"] .map2-sheet-handle,
body[data-theme="dark"] .map2-sheet-handle {
    background: rgba(255,255,255,.22);
}

[data-theme="dark"] .map2-launch-map-card,
[data-theme="dark"] .map2-launch-panel-card,
[data-theme="dark"] .map2-launch-sheet-card,
body[data-theme="dark"] .map2-launch-map-card,
body[data-theme="dark"] .map2-launch-panel-card,
body[data-theme="dark"] .map2-launch-sheet-card {
    border-color: rgba(255,211,125,.26);
    background: radial-gradient(circle at top left, rgba(255,211,125,.18), transparent 42%), linear-gradient(135deg, rgba(30,41,59,.94), rgba(15,23,42,.92));
    color: #e2e8f0;
    box-shadow: 0 18px 42px rgba(0,0,0,.34);
}

[data-theme="dark"] .map2-launch-map-body,
[data-theme="dark"] .map2-launch-card-body,
body[data-theme="dark"] .map2-launch-map-body,
body[data-theme="dark"] .map2-launch-card-body {
    color: #cbd5e1;
}

[data-theme="dark"] .map2-launch-card-note,
body[data-theme="dark"] .map2-launch-card-note {
    background: rgba(114,205,139,.12);
    color: var(--sheep-green-light);
}

[data-theme="dark"] .map2 .leaflet-control-zoom a,
body[data-theme="dark"] .map2 .leaflet-control-zoom a {
    background: #1e293b;
    color: #e2e8f0;
}

[data-theme="dark"] .sheep-popup-container .leaflet-popup-content-wrapper,
body[data-theme="dark"] .sheep-popup-container .leaflet-popup-content-wrapper {
    background: #111827 !important;
    border-color: rgba(255,255,255,.12) !important;
    box-shadow: 0 24px 60px rgba(0,0,0,.45);
}

[data-theme="dark"] .sheep-popup-container .leaflet-popup-tip,
body[data-theme="dark"] .sheep-popup-container .leaflet-popup-tip {
    background: #111827 !important;
    border-color: rgba(255,255,255,.10) !important;
}

[data-theme="dark"] .sheep-popup-container .leaflet-popup-close-button,
body[data-theme="dark"] .sheep-popup-container .leaflet-popup-close-button {
    background: rgba(15,23,42,.96) !important;
    border-color: rgba(255,255,255,.14) !important;
    color: #e2e8f0 !important;
}

[data-theme="dark"] .sheep-popup,
body[data-theme="dark"] .sheep-popup {
    background: #111827;
    color: #e2e8f0;
}

[data-theme="dark"] .popup-title,
[data-theme="dark"] .popup-category,
body[data-theme="dark"] .popup-title,
body[data-theme="dark"] .popup-category {
    color: var(--sheep-green-light);
}

[data-theme="dark"] .popup-category,
[data-theme="dark"] .popup-address,
body[data-theme="dark"] .popup-category,
body[data-theme="dark"] .popup-address {
    background: rgba(114,205,139,.10);
}

[data-theme="dark"] .verified-badge,
[data-theme="dark"] .popup-btn,
body[data-theme="dark"] .verified-badge,
body[data-theme="dark"] .popup-btn {
    background: linear-gradient(135deg, #2c7744, #72cd8b);
    color: #07140b !important;
}

[data-theme="dark"] .popup-desc,
body[data-theme="dark"] .popup-desc {
    color: #94a3b8;
}

[data-theme="dark"] .popup-address,
body[data-theme="dark"] .popup-address {
    color: #cbd5e1;
}

[data-theme="dark"] .map2-test-banner,
body[data-theme="dark"] .map2-test-banner,
[data-theme="dark"] .popup-test-banner,
body[data-theme="dark"] .popup-test-banner {
    background: rgba(30,41,59,.94);
    border-color: rgba(242,140,56,.34);
    color: #fed7aa;
}

[data-theme="dark"] .map2-test-banner strong,
body[data-theme="dark"] .map2-test-banner strong,
[data-theme="dark"] .popup-title.is-test,
body[data-theme="dark"] .popup-title.is-test {
    color: #fdba74;
}

[data-theme="dark"] .map2-test-banner span:not(.map2-test-pulse),
body[data-theme="dark"] .map2-test-banner span:not(.map2-test-pulse) {
    color: #cbd5e1;
}

    [data-theme="dark"] .popup-address i,
    body[data-theme="dark"] .popup-address i {
        color: var(--sheep-green-light);
    }

/* Mobile layout */
@media (max-width: 991.98px) {
    .map2 {
        position: fixed;
        top: var(--navbar-height);
        left: 0;
        right: 0;
        bottom: calc(var(--bottom-nav-h) + env(safe-area-inset-bottom));
        height: auto;
        --top-ui-h: 150px;
        --sheet-peek: var(--map2-sheet-peek);
        --sheet-full: calc(100vh - var(--navbar-height) - var(--bottom-nav-h) - env(safe-area-inset-bottom) - var(--top-ui-h) - 16px);
    }

    .map2-chips,
    .map2-filter-row {
        scrollbar-width: none;
        cursor: grab;
    }

        .map2-chips::-webkit-scrollbar,
        .map2-filter-row::-webkit-scrollbar {
            display: none;
        }

    .map2-sheet {
        position: fixed;
        left: 0;
        right: 0;
        bottom: calc(var(--bottom-nav-h) + env(safe-area-inset-bottom));
        height: var(--sheet-full);
        display: flex;
        flex-direction: column;
        transform: translateY(calc(100% - var(--sheet-peek)));
    }

        .map2-sheet.peek {
            transform: translateY(calc(100% - var(--sheet-peek)));
        }

        .map2-sheet.half {
            transform: translateY(calc(100% - min(52vh, var(--sheet-full))));
        }

        .map2-sheet.full {
            transform: translateY(0);
        }

    .map2-sheet-body {
        flex: 1 1 auto;
        min-height: 0;
    }

    .map2-selected {
        bottom: calc(var(--sheet-peek) + 10px);
    }

    .map2-floating-locate {
        right: 10px;
        bottom: calc(var(--sheet-peek) + 12px);
        width: 44px;
        padding: 0;
    }

    .map2 .leaflet-control-attribution {
        display: none;
    }

    .map2 .leaflet-top.leaflet-left {
        visibility: visible;
        top: 178px;
        left: auto;
        right: 10px;
        z-index: 520;
    }

    .map2-launch-map-card {
        top: auto;
        right: 10px;
        left: 10px;
        bottom: calc(var(--sheet-peek) + 72px);
        max-width: none;
        padding: 11px 13px;
        border-radius: 18px;
    }

    .map2-test-banner {
        right: 10px;
        left: 10px;
        bottom: calc(var(--sheet-peek) + 12px);
        max-width: none;
        padding: 10px 12px;
    }

    .map2-launch-map-title {
        font-size: .94rem;
    }

    .map2-launch-map-body {
        display: none;
    }
}

@media (max-width: 575.98px) {
    .map2-topbar {
        top: 8px;
        left: 8px;
        right: 8px;
        gap: 7px;
    }

    .map2-searchbar {
        padding: 9px 11px;
    }

    .map2-chips {
        gap: 6px;
        padding: 2px 2px 5px;
    }

    .map2-chip {
        width: 52px;
        min-width: 52px;
        height: 52px;
        min-height: 52px;
        justify-content: center;
        gap: 0;
        padding: 6px;
        border-radius: 18px;
        font-size: .84rem;
        box-shadow: 0 7px 18px rgba(15,23,42,.10);
    }

        .map2-chip span {
            display: none;
        }

        .map2-chip.active {
            width: auto;
            min-width: 52px;
            max-width: 160px;
            gap: 7px;
            padding-left: 8px;
            padding-right: 12px;
        }

            .map2-chip.active span {
                display: inline;
                max-width: 96px;
                overflow: hidden;
                text-overflow: ellipsis;
                white-space: nowrap;
                font-size: .78rem;
            }

    .map2-chip-icon {
        width: 38px !important;
        height: 38px !important;
        max-width: 38px !important;
        max-height: 38px !important;
        flex: 0 0 38px !important;
        border-radius: 12px;
    }

    .map2-chip i {
        font-size: 1.35rem;
    }

    .map2-filter-row {
        justify-content: center;
        padding-bottom: 5px;
    }

    .map2-distance-chip {
        padding: 7px 10px;
        font-size: .78rem;
    }

    .map2 .leaflet-top.leaflet-left {
        top: 166px;
        right: 8px;
    }

    .map2-selected {
        left: 8px;
        right: 8px;
        bottom: calc(var(--sheet-peek) + 8px);
        padding: 10px;
        border-radius: 18px;
    }

    .map2-sheet-sort-row {
        padding-right: 12px;
        padding-left: 12px;
    }

        .map2-sheet-sort-row .map2-panel-sort {
            max-width: 150px;
        }

    .map2-selected-main {
        grid-template-columns: 44px minmax(0, 1fr);
        gap: 9px;
    }

    .map2-selected-icon {
        width: 44px !important;
        height: 44px !important;
        max-width: 44px !important;
        max-height: 44px !important;
        border-radius: 13px;
    }

    .map2-selected-title {
        font-size: .96rem;
    }

    .map2-selected-sub {
        font-size: .76rem;
    }

    .map2-selected-eyebrow {
        font-size: .72rem;
    }

    .map2-selected-verified {
        padding: 3px 6px;
        font-size: .64rem;
    }

    .map2-selected-actions {
        grid-template-columns: 40px minmax(0, 1fr) 40px;
        gap: 7px;
    }

        .map2-selected-actions .map2-action {
            min-height: 40px;
        }

        .map2-selected-actions .map2-center,
        .map2-selected-actions .map2-close {
            width: 40px;
        }

    .map2-row-rich {
        gap: 10px;
        min-height: 98px;
        padding: 8px 10px;
    }

    .map2-row-photo {
        width: 82px !important;
        height: auto !important;
        min-height: 88px;
        max-width: 82px !important;
        max-height: none !important;
        flex-basis: 82px !important;
        align-self: stretch;
        border-radius: 14px;
    }

    .map2-row-category-icon,
    .map2-row-photo-fallback img {
        width: 46px !important;
        height: 46px !important;
        max-width: 46px !important;
        max-height: 46px !important;
        border-radius: 12px;
    }

    .map2-row-title {
        font-size: .95rem;
    }

    .map2-row-sub {
        font-size: .82rem;
    }

    .map2-menu-preview {
        gap: 5px;
        height: 42px;
    }

    .map2-menu-pill {
        flex-basis: 38px;
        width: 38px;
        height: 38px;
        min-width: 38px;
        max-width: 38px;
        padding: 0;
        font-size: .72rem;
        border-radius: 9px;
    }

        .map2-menu-pill img {
            width: 38px !important;
            height: 38px !important;
            max-width: 38px !important;
            max-height: 38px !important;
            flex-basis: 38px;
            border-radius: 9px;
        }

    .map2-food-tag {
        padding: 4px 9px;
        font-size: .72rem;
    }

    .map2-launch-panel-card,
    .map2-launch-sheet-card {
        gap: 10px;
        padding: 12px;
        border-radius: 17px;
    }

    .map2-launch-card-icon {
        width: 38px;
        height: 38px;
        flex-basis: 38px;
        border-radius: 14px;
    }

    .map2-launch-card-title {
        font-size: .94rem;
    }

    .map2-launch-card-body {
        font-size: .8rem;
    }

    .map2-launch-card-note {
        font-size: .72rem;
    }

    .sheep-popup {
        min-width: 230px;
        max-width: 286px;
    }

    .sheep-popup-container .leaflet-popup-content-wrapper {
        max-width: 286px;
        border-radius: 20px !important;
    }

    .sheep-popup-container .leaflet-popup-close-button {
        top: 7px !important;
        right: 7px !important;
        width: 29px !important;
        height: 29px !important;
    }

    .popup-image {
        height: 92px !important;
        max-height: 92px !important;
    }

    .popup-category {
        margin: .65rem .8rem 0;
        padding: .48rem .58rem;
        border-radius: 12px;
        font-size: .76rem;
    }

        .popup-category img {
            width: 30px !important;
            height: 30px !important;
            max-width: 30px !important;
            max-height: 30px !important;
            flex-basis: 30px;
            border-radius: 9px;
        }

    .popup-title {
        padding: .7rem 2.8rem .1rem .8rem;
        font-size: .98rem;
    }

    .verified-badge {
        padding: 4px 7px;
        font-size: .66rem;
    }

    .popup-desc {
        margin: .25rem .8rem .6rem;
        font-size: .78rem;
        line-height: 1.25;
    }

    .popup-address {
        margin: 0 .8rem .75rem;
        padding: .58rem .65rem;
        border-radius: 12px;
        font-size: .76rem;
    }

    .popup-btn {
        width: calc(100% - 1.6rem);
        margin-bottom: .8rem;
        padding: .6rem 1rem;
        font-size: .84rem;
    }
}

/* Desktop layout */
@media (min-width: 576px) {
    .map2-selected-actions {
        grid-template-columns: auto minmax(150px, 260px) auto;
        justify-content: end;
        align-items: center;
    }

        .map2-selected-actions .map2-center {
            width: auto;
            min-width: 104px;
            padding-left: .9rem;
            padding-right: .9rem;
        }

        .map2-selected-actions .map2-open-menu {
            max-width: 260px;
        }

        .map2-selected-actions .map2-close {
            width: 42px;
        }
}

@media (min-width: 992px) {
    .map2 {
        display: flex;
        height: calc(100vh - var(--navbar-height));
    }

    .map2-panel {
        position: relative;
        top: auto;
        bottom: auto;
        left: auto;
        z-index: 9999 !important;
        width: var(--map2-panel-w);
        flex: 0 0 var(--map2-panel-w);
        pointer-events: auto;
    }

    .map2-resizer {
        position: relative;
        z-index: 9999;
        width: 10px;
        cursor: col-resize;
        background: transparent;
    }

        .map2-resizer::before {
            content: "";
            position: absolute;
            top: 10px;
            bottom: 10px;
            left: 50%;
            width: 2px;
            transform: translateX(-50%);
            border-radius: 99px;
            background: rgba(0,0,0,.18);
        }

        .map2-resizer:hover::before {
            background: rgba(44,119,68,.60);
        }

    .map2-map,
    .map2-leaflet,
    .map2 .leaflet-container {
        position: relative;
        inset: auto;
        flex: 1 1 auto;
        min-width: 0;
        z-index: 1;
    }

        .map2-map * {
            pointer-events: auto;
        }

    .map2-topbar {
        z-index: 2000;
        left: 10px;
        right: 10px;
    }

    .map2-sheet {
        display: none !important;
    }

    .map2-selected {
        bottom: 16px;
    }

    .map2-panel-body {
        overflow-x: hidden;
    }

    .map2 .leaflet-top.leaflet-left {
        top: 130px;
        left: 0;
        right: auto;
    }

    .map2-launch-map-card {
        top: 166px;
        right: 18px;
    }
}

@media (hover: hover) and (pointer: fine) {
    .map2-row {
        transition: transform 140ms ease, box-shadow 140ms ease, border-color 140ms ease, background-color 140ms ease;
    }

        .map2-row:hover {
            transform: translateY(-1px);
            border-color: rgba(44,119,68,.35);
            background: rgba(44,119,68,.06);
            box-shadow: 0 10px 24px rgba(15,23,42,.11);
        }

        .map2-row:active {
            transform: translateY(0);
            box-shadow: none;
        }

    [data-theme="dark"] .map2-row:hover,
    body[data-theme="dark"] .map2-row:hover {
        border-color: rgba(114,205,139,.35);
        background: rgba(114,205,139,.08);
        box-shadow: 0 12px 28px rgba(0,0,0,.30);
    }
}

.map2-launch-map-card {
    display: none !important;
}


/* SheepMe glow-up patch additions */
.sheep-popup,
.sheep-popup * {
    box-sizing: border-box;
}

.popup-desc,
.popup-category span,
.popup-title,
.popup-address span {
    max-width: 100%;
    min-width: 0;
    overflow-wrap: anywhere;
    word-break: break-word;
}

@media (max-width: 991.98px) {
    .map2-filter-row,
    .map2-chips {
        display: flex !important;
    }

    .map2-test-banner {
        top: calc(env(safe-area-inset-top) + 82px);
        right: 10px;
        bottom: auto;
        left: auto;
        max-width: min(300px, calc(100vw - 20px));
        padding: 8px 10px;
        border-radius: 999px;
        z-index: 640;
    }

    .map2-test-banner span:not(.map2-test-pulse) {
        display: none;
    }

    .map2-sheet-list {
        padding-bottom: 12px;
    }

    .map2-row {
        min-height: 58px;
        padding: 8px 10px;
        gap: 9px;
    }

    .map2-row-sub,
    .map2-row-desc {
        display: none !important;
    }

    .map2-menu-preview {
        margin-top: 4px;
    }

    .map2-menu-pill {
        flex-basis: 38px;
        width: 38px;
        height: 38px;
        min-width: 38px;
        max-width: 38px;
        padding: 0;
        font-size: .72rem;
        border-radius: 9px;
    }

        .map2-menu-pill img {
            width: 38px !important;
            height: 38px !important;
            max-width: 38px !important;
            max-height: 38px !important;
            flex-basis: 38px;
            border-radius: 9px;
        }
}

/* Bottom sheet production snap/tap polish */
.map2-sheet-handlebar,
.map2-sheet-header {
    touch-action: none;
    user-select: none;
    -webkit-user-select: none;
}

.map2-sheet-body {
    touch-action: pan-y;
    overscroll-behavior-y: contain;
    -webkit-overflow-scrolling: touch;
}

.map2-sheet.is-dragging {
    user-select: none;
    -webkit-user-select: none;
}

.map2-sheet-toggle {
    width: 38px;
    height: 38px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    border-radius: 12px;
    border: 2px solid rgba(44,119,68,.82);
    background: rgba(44,119,68,.10);
    color: var(--sheep-green);
    box-shadow: 0 8px 18px rgba(44,119,68,.16);
}

.map2-sheet-toggle:hover,
.map2-sheet-toggle:focus,
.map2-sheet-toggle:active {
    border-color: rgba(44,119,68,1);
    background: rgba(44,119,68,.18);
    color: var(--sheep-green);
}

.map2-sheet-toggle i {
    font-size: 1.08rem;
    font-weight: 900;
    line-height: 1;
}

[data-theme="dark"] .map2-sheet-toggle,
body[data-theme="dark"] .map2-sheet-toggle {
    border-color: rgba(114,205,139,.82);
    background: rgba(114,205,139,.12);
    color: var(--sheep-green-light);
    box-shadow: 0 8px 18px rgba(0,0,0,.28);
}

[data-theme="dark"] .map2-sheet-toggle:hover,
[data-theme="dark"] .map2-sheet-toggle:focus,
[data-theme="dark"] .map2-sheet-toggle:active,
body[data-theme="dark"] .map2-sheet-toggle:hover,
body[data-theme="dark"] .map2-sheet-toggle:focus,
body[data-theme="dark"] .map2-sheet-toggle:active {
    border-color: rgba(114,205,139,1);
    background: rgba(114,205,139,.18);
    color: var(--sheep-green-light);
}
