/* Compass GIS redesign */
:root {
    --map-green: #2F9460;
    --map-green-dark: #227348;
    --map-text: #262626;
    --map-muted: #737373;
    --map-border: rgba(38, 38, 38, 0.08);
    --map-panel: rgba(255, 255, 255, 0.36);
    --map-mobile-panel: rgba(245, 245, 245, 0.24);
    --map-shadow: 0 18px 52px rgba(15, 23, 42, 0.18);
    --z-map-controls: 1500;
    --z-map-popovers: 1600;
    --z-map-modal-overlay: 2190;
    --z-map-modal: 2200;
}

* {
    box-sizing: border-box;
}

html,
body {
    width: 100%;
    height: 100%;
    overflow: hidden;
}

body {
    margin: 0;
    background: #E5E7EB;
}

#map {
    width: 100%;
    height: 100dvh;
    min-height: 100vh;
    position: relative;
    z-index: 1;
}

#map [class*="ymaps-2"][class*="-map"] {
    font-family: 'Inter', 'Roboto', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

#map [class*="ymaps-2"][class*="-map-copyrights-promo"],
#map [class*="ymaps-2"][class*="-gotoymaps"],
#map [class*="ymaps-2"][class*="-gototech"] {
    display: none !important;
    visibility: hidden !important;
    pointer-events: none !important;
}

.map-interface {
    position: fixed;
    inset: 0;
    z-index: var(--z-map-popovers);
    pointer-events: none;
}

.map-header {
    position: absolute;
    top: 16px;
    left: 16px;
    right: 16px;
    height: 64px;
    min-height: 64px;
    padding: 12px 0;
    border-radius: 32px;
    background: transparent;
    box-shadow: none;
    display: flex;
    align-items: center;
    gap: 0;
    pointer-events: auto;
    isolation: isolate;
    overflow: visible;
}

.map-header::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -1;
    border-radius: inherit;
    background: var(--map-panel);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
}

.map-brand {
    width: 210px;
    min-width: 210px;
    flex: 0 0 210px;
    height: 32px;
    display: flex;
    align-items: center;
    padding: 0 0 0 16px;
    color: #1F2937;
    font: 700 12px/1.05 'Inter', 'Roboto', sans-serif;
}

.map-brand-logo {
    width: 98.764px;
    height: 32px;
    object-fit: contain;
}

.map-header .search-container {
    position: relative;
    top: auto;
    left: auto;
    transform: none;
    z-index: 2;
    flex: 0 0 400px;
    width: 400px;
    min-height: 40px;
    height: 40px;
    border-radius: 22px;
    background: transparent;
    box-shadow: none;
    display: block;
}

.map-header .search-input-container {
    position: relative;
    display: flex;
    align-items: center;
    height: 40px;
    padding: 0 48px 0 16px;
    border: 0;
    border-radius: 22px;
    background: #FFFFFF;
    box-shadow: 0 1px 1px rgba(0, 0, 0, 0.05);
}

.map-header .search-icon {
    position: absolute;
    top: 50%;
    right: 16px;
    transform: translateY(-50%);
    width: 18px;
    height: 18px;
    margin: 0;
    padding: 0;
    opacity: 0.88;
    object-fit: contain;
    pointer-events: none;
}

.map-header .search-input {
    flex: 1;
    height: 100%;
    min-width: 0;
    border: 0;
    outline: 0;
    background: transparent;
    font: 400 14px/20px 'Inter', 'Roboto', sans-serif;
    color: var(--map-text);
}

.map-header .search-input::placeholder {
    color: var(--map-muted);
}

.map-header .search-clear {
    position: absolute;
    top: 50%;
    right: 36px;
    transform: translateY(-50%);
    width: 32px;
    height: 32px;
    border: 0;
    border-radius: 999px;
    background: transparent;
    color: #525252;
    cursor: pointer;
    display: none;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    line-height: 1;
}

.map-header .search-clear:hover {
    background: #F5F5F5;
}

.map-header .search-results {
    display: none;
    position: absolute;
    z-index: 20;
    top: 48px;
    left: 0;
    width: 400px;
    max-height: min(560px, calc(100vh - 132px));
    padding: 10px;
    overflow-y: auto;
    border: 1px solid rgba(255, 255, 255, 0.76);
    border-radius: 22px;
    background: var(--map-panel);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
    box-shadow: var(--map-shadow);
}

.map-header .search-results.is-history {
    padding: 16px 4px;
    border: 0;
    border-radius: 12px;
    background: var(--map-panel);
    box-shadow: 0 10px 40px 10px rgba(0, 0, 0, 0.08);
}

.map-header .search-results.is-results {
    position: fixed;
    top: 92px;
    left: 16px;
    width: 400px;
    height: min(792px, calc(100dvh - 108px));
    max-height: calc(100dvh - 108px);
    padding: 0;
    border: 0;
    border-radius: 22px;
    background: rgba(255, 255, 255, 0.70);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    box-shadow: 0 1px 0.5px rgba(0, 0, 0, 0.05);
    overflow: hidden;
}

.search-results-heading {
    display: flex;
    width: 100%;
    align-items: center;
    justify-content: space-between;
    padding: 24px 24px 0;
}

.search-results-title {
    color: var(--map-text);
    font: 600 20px/1 'Inter', 'Roboto', sans-serif;
    letter-spacing: 0;
}

.search-results-close {
    width: 40px;
    height: 40px;
    margin-right: -14px;
    border: 0;
    border-radius: 22px;
    background: transparent;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.search-results-close:hover {
    background: rgba(245, 245, 245, 0.82);
}

.search-results-close img {
    display: block;
    width: 20px;
    height: 20px;
}

.search-results-list {
    position: relative;
    width: 100%;
    max-height: calc(100% - 64px);
    padding: 16px 24px 24px;
    overflow-x: hidden;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.search-results-list::-webkit-scrollbar {
    width: 4px;
}

.search-results-list::-webkit-scrollbar:horizontal {
    height: 0;
}

.search-results-list::-webkit-scrollbar-track {
    background: transparent;
}

.search-results-list::-webkit-scrollbar-thumb {
    border-radius: 999px;
    background: #E5E5E5;
}

.search-history-list {
    width: 100%;
}

.search-history-item {
    display: flex;
    min-height: 42px;
    width: 100%;
    align-items: center;
    border-radius: 6px;
    transition: background-color 0.2s;
}

.search-history-item:hover,
.search-history-item:focus-within {
    background: #F5F5F5;
}

.search-history-query,
.search-history-remove {
    border: 0;
    background: transparent;
    color: var(--map-text);
    cursor: pointer;
    display: flex;
    align-items: center;
}

.search-history-query {
    flex: 1 1 auto;
    min-width: 0;
    gap: 12px;
    padding: 8px 12px;
    font: 400 16px/1.6 'Inter', 'Roboto', sans-serif;
    text-align: left;
}

.search-history-query span {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.search-history-icon,
.search-history-remove img {
    display: block;
    width: 20px;
    height: 20px;
    flex: 0 0 auto;
}

.search-history-remove {
    width: 36px;
    height: 36px;
    justify-content: center;
    margin-right: 6px;
    border-radius: 4px;
    opacity: 0;
    transition: background-color 0.2s, opacity 0.2s;
}

.search-history-item:hover .search-history-remove,
.search-history-item:focus-within .search-history-remove {
    opacity: 1;
}

.search-history-remove:hover {
    background: #E5E5E5;
}

.search-result-item {
    display: flex;
    width: 352px;
    min-height: 126px;
    align-items: center;
    gap: 16px;
    padding: 16px;
    border-radius: 12px;
    background: #FFFFFF;
    cursor: pointer;
    transition: background-color 0.2s;
}

.search-result-item + .search-result-item {
    margin-top: 0;
}

.search-result-item:hover {
    background: #F2FBF7;
}

.result-info {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;
    gap: 6px;
}

.result-name {
    margin: 0;
    width: 154px;
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    color: var(--map-text);
    font: 600 16px/24px 'Inter', 'Roboto', sans-serif;
    letter-spacing: 0;
}

.search-result-item:hover .result-name {
    color: var(--map-green);
}

.result-details {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 2px;
}

.result-location,
.result-meta,
.result-rating {
    color: var(--map-muted);
    font: 400 14px/20px 'Inter', 'Roboto', sans-serif;
    letter-spacing: 0;
}

.result-location {
    width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.result-rating {
    width: 100%;
    color: var(--map-muted);
    display: flex;
    align-items: center;
    gap: 4px;
}

.result-rating-star {
    width: 16px;
    height: 16px;
    flex: 0 0 auto;
}

.result-icon,
.result-thumb {
    width: 94px;
    height: 94px;
    margin-left: auto;
    border-radius: 12px;
    object-fit: cover;
    opacity: 1;
    background: #F5F5F5;
}

.result-thumb-placeholder {
    width: 94px;
    height: 94px;
    margin-left: auto;
    border-radius: 12px;
    background: #F5F5F5;
    color: #A3A3A3;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    flex: 0 0 auto;
}

.result-thumb-placeholder img {
    width: 20px;
    height: 20px;
    object-fit: contain;
}

.search-message {
    color: var(--map-muted);
    font: 400 14px/20px 'Inter', 'Roboto', sans-serif;
}

.map-header .categories {
    position: static;
    bottom: auto;
    left: auto;
    transform: none;
    z-index: auto;
    flex: 1 1 auto;
    width: auto;
    min-width: 0;
    margin-left: 32px;
    margin-right: 32px;
    gap: 8px;
    padding: 0;
    display: flex;
    align-items: center;
    overflow-x: auto;
    scrollbar-width: none;
    scroll-behavior: smooth;
    mask-image: none;
    -webkit-mask-image: none;
}

.map-header .categories::-webkit-scrollbar {
    display: none;
}

.map-header .category-btn {
    width: auto;
    min-width: max-content;
    height: 32px;
    padding: 6px 12px;
    border: 1px solid #E5E5E5;
    border-radius: 999px;
    background: #FFFFFF;
    color: var(--map-text);
    cursor: pointer;
    white-space: nowrap;
    box-shadow: 0 1px 1px rgba(0, 0, 0, 0.05);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font: 500 12px/16px 'Inter', 'Roboto', sans-serif;
    transition: background-color 0.2s, transform 0.2s;
}

.map-header .category-btn:hover {
    transform: none;
    background: #F7F7F7;
}

.map-header .category-btn.active {
    background: var(--map-green);
    color: #FFFFFF;
    border-color: var(--map-green);
}

.map-header .category-icon {
    width: 16px;
    height: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.map-header .category-icon img,
.map-more-btn img,
.logo-btn img,
.zoom-btn img,
.admin-btn img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.map-header .category-btn > span:not(.category-icon) {
    flex: 0 1 auto;
}

.map-header-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    flex: 0 0 auto;
    margin-left: auto;
    margin-right: 16px;
}

.map-profile-btn,
.map-more-btn {
    height: 40px;
    border: 0;
    border-radius: 999px;
    background: var(--map-green);
    color: #FFFFFF;
    cursor: pointer;
    text-decoration: none;
    box-shadow: 0 8px 20px rgba(47, 148, 96, 0.2);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font: 700 14px/20px 'Inter', 'Roboto', sans-serif;
}

.map-profile-btn {
    padding: 0 18px;
}

.map-more-btn {
    width: 40px;
    display: none;
    background: rgba(255, 255, 255, 0.96);
    color: var(--map-text);
    box-shadow: 0 2px 9px rgba(15, 23, 42, 0.07);
}

.map-profile-btn:hover,
.map-more-btn:hover {
    transform: translateY(-1px);
}

.map-controls {
    position: fixed;
    top: 50%;
    right: 16px;
    bottom: auto;
    left: auto;
    z-index: var(--z-map-controls);
    width: 40px;
    height: 192px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 16px;
    pointer-events: auto;
    transform: translateY(-50%);
    visibility: visible;
}

.map-control-btn,
.logo-btn {
    width: 40px;
    height: 40px;
    border: 0;
    border-radius: 999px;
    background: #FFFFFF;
    color: var(--map-text);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.16);
    font-size: 18px;
}

.map-control-btn:hover,
.logo-btn:hover {
    transform: translateY(-1px);
}

.map-satellite-btn.is-active,
.map-satellite-btn[aria-pressed="true"] {
    background: var(--map-green);
}

.map-satellite-btn.is-active img,
.map-satellite-btn[aria-pressed="true"] img {
    filter: brightness(0) invert(1);
}

.zoom-controls {
    display: flex;
    flex-direction: column;
    gap: 0;
    width: 40px;
    height: 80px;
    border-radius: 999px;
    overflow: hidden;
    background: #FFFFFF;
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.16);
}

.zoom-btn {
    width: 40px;
    height: 40px;
    border: 0;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
    color: var(--map-text);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font: 400 22px/1 'Inter', 'Roboto', sans-serif;
}

.zoom-btn + .zoom-btn {
    border-top: 1px solid #E5E5E5;
}

.zoom-btn:hover {
    transform: none;
    background: #F5F5F5;
}

.map-control-btn img,
.logo-btn img,
.zoom-btn img,
.admin-btn img {
    width: 20px;
    height: 20px;
}

.admin-btn {
    position: fixed;
    top: auto;
    right: 16px;
    bottom: 20px;
    width: 40px;
    height: 40px;
    border: 0;
    border-radius: 999px;
    background: #FFFFFF;
    color: var(--map-text);
    cursor: pointer;
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.16);
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    transition: transform 0.2s, box-shadow 0.2s;
    z-index: var(--z-map-controls);
}

.admin-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 10px 28px rgba(15, 23, 42, 0.18);
}

.occupancy-low {
    background-color: #EFF2C9 !important;
    border: 1px solid #D6E264 !important;
}

.occupancy-medium {
    background-color: #FFE9B2 !important;
    border: 1px solid #FFC943 !important;
}

.occupancy-high {
    background-color: #FFD4D4 !important;
    border: 1px solid #EA454C !important;
}

.geolocation-dialog-overlay {
    position: fixed;
    inset: 0;
    z-index: var(--z-map-modal-overlay);
    padding: 16px;
    background: rgba(17, 24, 39, 0.38);
    display: flex;
    align-items: center;
    justify-content: center;
}

.geolocation-dialog-overlay[hidden] {
    display: none;
}

.geolocation-dialog {
    position: relative;
    width: min(360px, calc(100vw - 32px));
    max-width: min(360px, calc(100vw - 32px));
    padding: 24px 20px 20px;
    border-radius: 24px;
    background: #FFFFFF;
    box-shadow: 0 18px 48px rgba(15, 23, 42, 0.24);
}

.geolocation-dialog-close {
    position: absolute;
    top: 8px;
    right: 8px;
    width: 32px;
    height: 32px;
    border: 0;
    border-radius: 999px;
    background: transparent;
    color: var(--map-muted);
    cursor: pointer;
    font-size: 24px;
    line-height: 32px;
}

.geolocation-dialog-close:hover {
    background: #F5F5F5;
    color: var(--map-text);
}

.geolocation-dialog-title {
    margin: 0 36px 8px 0;
    color: var(--map-text);
    font: 700 18px/1.3 'Inter', 'Roboto', sans-serif;
}

.geolocation-status {
    color: #4B5563;
    font: 500 14px/1.45 'Inter', 'Roboto', sans-serif;
}

.custom-popup {
    width: 360px;
    border-radius: 20px;
    padding: 8px;
    gap: 10px;
    background: #FFFFFF;
    display: flex;
    box-shadow: 0 18px 48px rgba(15, 23, 42, 0.2);
}

.popup-image {
    width: 128px;
    height: 112px;
    border-radius: 16px;
    object-fit: cover;
    flex-shrink: 0;
}

.popup-content {
    flex: 1;
    min-width: 0;
    padding: 2px 0;
    display: flex;
    flex-direction: column;
    position: relative;
}

.popup-rating {
    position: absolute;
    top: 0;
    right: 0;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 4px;
}

.popup-rating .stars {
    display: flex;
    align-items: center;
    gap: 2px;
}

.popup-rating .stars img {
    width: 16px;
    height: 16px;
    object-fit: contain;
}

.like-button {
    padding: 4px;
    border: 0;
    background: transparent;
    cursor: pointer;
}

.like-icon {
    width: 20px;
    height: 20px;
    object-fit: contain;
}

.popup-title {
    max-width: 160px;
    color: var(--map-text);
    font: 700 18px/21px 'Inter', 'Roboto', sans-serif;
}

.popup-full-name,
.popup-coordinates-label,
.popup-coordinates,
.popup-distance {
    color: #525252;
    font: 500 13px/18px 'Inter', 'Roboto', sans-serif;
}

.popup-coordinates-label {
    margin-top: 6px;
}

.popup-distance {
    display: flex;
    align-items: center;
    gap: 6px;
}

.popup-distance img {
    width: 18px;
    height: 18px;
    object-fit: contain;
}

.popup-layer,
.popup-category {
    color: var(--map-green);
}

.popup-button {
    border: 0;
    border-radius: 999px;
    padding: 7px 16px;
    background: var(--map-green);
    color: #FFFFFF;
    cursor: pointer;
    font: 700 13px/18px 'Inter', 'Roboto', sans-serif;
}

.map-load-error {
    position: absolute;
    inset: 0;
    padding: 24px;
    background: #F5F5F5;
    color: var(--map-text);
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    font: 600 15px/22px 'Inter', 'Roboto', sans-serif;
}

.modal-overlay {
    display: none;
    position: fixed;
    inset: 0;
    z-index: var(--z-map-modal-overlay);
    background: transparent;
    backdrop-filter: none;
    pointer-events: none;
}

.modal-overlay.is-open {
    display: block;
}

.modal {
    display: flex;
    flex-direction: column;
    visibility: hidden;
    pointer-events: none;
    position: fixed;
    top: 92px;
    left: 16px;
    right: auto;
    opacity: 0;
    transform: translateX(calc(-100% - 24px));
    width: 400px;
    height: auto;
    max-width: calc(100vw - 32px);
    max-height: calc(100dvh - 108px);
    padding: 0;
    overflow-x: hidden;
    overflow-y: auto;
    border-radius: 22px;
    background: rgba(255, 255, 255, 0.70);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    box-shadow: 0 1px 0.5px rgba(0, 0, 0, 0.05);
    font-family: 'Inter', 'Roboto', sans-serif;
    z-index: var(--z-map-modal);
    transition:
        transform 380ms cubic-bezier(0.22, 1, 0.36, 1),
        opacity 220ms ease,
        visibility 0s linear 380ms;
    will-change: transform;
}

.modal.is-open {
    visibility: visible;
    pointer-events: auto;
    opacity: 1;
    transform: translateX(0);
    transition:
        transform 380ms cubic-bezier(0.22, 1, 0.36, 1),
        opacity 220ms ease,
        visibility 0s;
}

@keyframes desktop-map-panel-in {
    from {
        opacity: 0;
        transform: translateX(calc(-100% - 24px));
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@media (min-width: 981px) {
    .map-header .search-results.is-history {
        border: 0;
        background: #FFFFFF;
        backdrop-filter: none;
        -webkit-backdrop-filter: none;
        box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
    }

    .map-header .search-results.is-results,
    .modal {
        background: var(--map-panel);
    }

    .map-header .search-results.is-results {
        animation: desktop-map-panel-in 340ms cubic-bezier(0.22, 1, 0.36, 1) both;
        will-change: transform;
    }
}

.modal-header {
    position: relative;
    width: 100%;
    height: 240px;
    min-height: 240px;
    flex: 0 0 240px;
    overflow: hidden;
    margin: 0;
    border-radius: 22px 22px 0 0;
}

.modal-header img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: opacity 0.3s ease;
}

.modal-body {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    gap: 24px;
    width: 100%;
    margin-top: -24px;
    margin-bottom: -24px;
    padding: 24px;
    border-radius: 22px;
    background: #FFFFFF;
}

.modal-title {
    position: relative;
    margin: 0;
    padding: 0;
}

.modal-title-category {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
}

.modal-title-name {
    color: var(--map-text);
    font: 600 20px/1.25 'Inter', 'Roboto', sans-serif;
    letter-spacing: 0;
}

.modal-place-category {
    margin-top: 2px;
    color: var(--map-muted);
    font: 400 14px/20px 'Inter', 'Roboto', sans-serif;
    letter-spacing: 0;
}

.modal-rating-row {
    display: flex;
    align-items: center;
    gap: 4px;
    width: 100%;
    padding-top: 12px;
    color: var(--map-muted);
    font: 400 14px/20px 'Inter', 'Roboto', sans-serif;
    letter-spacing: 0;
}

.modal-rating-row img {
    width: 16px;
    height: 16px;
    flex: 0 0 16px;
    object-fit: contain;
}

.modal-info-container {
    margin: 0;
    padding: 24px 0 0;
    border-top: 1px solid #E5E7EB;
    border-radius: 0;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.modal-section-title {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
}

.modal-info-row {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin: 0;
    padding: 0;
    width: 100%;
    border: 0;
    border-radius: 0;
    background: transparent !important;
}

.modal-rating-row[hidden],
.modal-info-row[hidden] {
    display: none !important;
}

.modal-info-icon {
    width: 20px;
    height: 20px;
    margin-top: 2px;
    color: var(--map-green);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
    font-size: 20px;
    line-height: 1;
}

.modal-info-icon img,
.modal-like-btn img,
.modal-inline-chevron {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.modal-info-text {
    flex: 1;
    min-width: 0;
    color: var(--map-text);
    font: 400 16px/24px 'Inter', 'Roboto', sans-serif;
    letter-spacing: 0;
}

.modal-info-main {
    display: flex;
    align-items: center;
    gap: 8px;
    width: 100%;
    min-width: 0;
    color: var(--map-text);
    font: 400 16px/24px 'Inter', 'Roboto', sans-serif;
    letter-spacing: 0;
}

.modal-info-sub {
    width: 100%;
    margin-top: 2px;
    color: var(--map-muted);
    font: 400 14px/20px 'Inter', 'Roboto', sans-serif;
    letter-spacing: 0;
}

.modal-open-status {
    color: #15803D;
}

.modal-inline-chevron {
    width: 20px;
    height: 20px;
    flex: 0 0 20px;
}

.modal-info-text#modal-description,
#modal-description {
    display: -webkit-box;
    -webkit-box-orient: vertical;
    overflow: hidden;
    color: var(--map-text);
    -webkit-line-clamp: 3;
}

.modal-review-link {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    flex: 0 0 auto;
    width: 100%;
    margin: 0;
    padding: 40px 24px 16px;
    border: 0;
    border-radius: 0 0 22px 22px;
    background: transparent;
    color: var(--map-text);
    cursor: default;
    font: 400 14px/20px 'Inter', 'Roboto', sans-serif;
    letter-spacing: 0;
    text-align: left;
}

.modal-review-link img {
    width: 20px;
    height: 20px;
    flex: 0 0 20px;
}

.modal-like-btn,
.modal-close {
    position: absolute;
    top: 24px;
    z-index: 4;
    width: 32px;
    height: 32px;
    border: 0;
    border-radius: 16px;
    background: #FFFFFF;
    color: #262626;
    cursor: pointer;
    box-shadow: none;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-close {
    left: 24px;
}

.modal.is-close-action .modal-close {
    right: 24px;
    left: auto;
}

.modal-like-btn {
    display: none;
    right: 24px;
}

.modal-close img,
.modal-like-btn img {
    width: 20px;
    height: 20px;
    object-fit: contain;
}

.modal-like-btn.active img {
    filter: brightness(0) saturate(100%) invert(80%) sepia(29%) saturate(1115%) hue-rotate(27deg) brightness(86%) contrast(87%);
}

.modal-photo-nav,
.modal-photo-counter {
    display: none !important;
}

.geolocation-dialog {
    border-radius: 24px;
}

@media (max-width: 980px) {
    .map-header {
        top: auto;
        left: 0;
        right: 0;
        bottom: -28px;
        height: 146px;
        min-height: 146px;
        padding: 24px 22px 58px;
        border-radius: 56px;
        display: grid;
        grid-template-columns: minmax(0, 1fr) 40px;
        grid-template-rows: 40px 32px;
        column-gap: 12px;
        row-gap: 12px;
        align-items: start;
        overflow: visible;
        transition:
            bottom 360ms cubic-bezier(0.22, 1, 0.36, 1),
            height 360ms cubic-bezier(0.22, 1, 0.36, 1),
            min-height 360ms cubic-bezier(0.22, 1, 0.36, 1),
            max-height 360ms cubic-bezier(0.22, 1, 0.36, 1),
            padding 360ms cubic-bezier(0.22, 1, 0.36, 1),
            border-radius 360ms cubic-bezier(0.22, 1, 0.36, 1);
    }

    .geolocation-dialog-overlay {
        padding: 20px 32px;
    }

    .geolocation-dialog {
        width: min(300px, calc(100vw - 64px));
        max-width: min(300px, calc(100vw - 64px));
        padding: 24px 18px 20px;
    }

    .map-header::before {
        content: "";
        position: absolute;
        inset: 0 6px -80px;
        z-index: -1;
        border-radius: 56px 56px 0 0;
        background: var(--map-mobile-panel);
        box-shadow: 0 8px 40px rgba(0, 0, 0, 0.12);
        backdrop-filter: blur(18px);
        -webkit-backdrop-filter: blur(18px);
        transition:
            inset 360ms cubic-bezier(0.22, 1, 0.36, 1),
            border-radius 360ms cubic-bezier(0.22, 1, 0.36, 1),
            background-color 240ms ease,
            box-shadow 240ms ease;
    }

    .map-header::after {
        content: "";
        position: absolute;
        top: 5px;
        left: 50%;
        width: 36px;
        height: 5px;
        border-radius: 999px;
        background: #CCCCCC;
        transform: translateX(-50%);
    }

    .map-brand {
        display: none;
    }

    .map-header .search-container {
        grid-column: 1;
        grid-row: 1;
        flex: none;
        width: 100%;
        height: 40px;
        min-height: 40px;
        min-width: 0;
    }

    .map-header--guest .search-container {
        grid-column: 1 / -1;
    }

    .map-header .search-input-container {
        height: 40px;
        padding: 0 44px 0 16px;
        border-radius: 22px;
        box-shadow: 0 1px 1px rgba(0, 0, 0, 0.05);
    }

    .map-header .search-icon {
        right: 10px;
        width: 20px;
        height: 20px;
    }

    .map-header .search-clear {
        right: 36px;
        width: 32px;
        height: 32px;
    }

    .map-header-actions {
        grid-column: 2;
        grid-row: 1;
        width: 40px;
        height: 40px;
        margin: 0;
    }

    .map-header--guest .map-header-actions {
        display: none;
    }

    .map-profile-btn {
        display: none;
    }

    .map-more-btn {
        display: inline-flex;
        width: 40px;
        height: 40px;
        padding: 0;
        border: 1px solid #E5E5E5;
        background: #FFFFFF;
        box-shadow: 0 1px 1px rgba(0, 0, 0, 0.05);
    }

    .map-more-btn img {
        width: 20px;
        height: 20px;
    }

    .map-header .categories {
        grid-column: 1 / -1;
        grid-row: 2;
        flex: none;
        width: 100%;
        margin: 0;
        gap: 8px;
        padding: 0;
        overflow-x: auto;
        overflow-y: hidden;
    }

    .map-header .category-btn {
        height: 32px;
        padding: 8px 12px;
        gap: 4px;
        box-shadow: 0 1px 0.5px rgba(0, 0, 0, 0.05);
    }

    .map-header .category-btn > span:not(.category-icon) {
        padding: 0 4px;
    }

    .map-header .search-results {
        position: fixed;
        top: auto;
        left: 22px;
        right: 22px;
        bottom: 142px;
        width: auto;
        max-height: min(56vh, 430px);
        padding: 12px;
        border-radius: 22px;
    }

    .map-header .search-results.is-history {
        padding: 12px 4px;
        border-radius: 20px;
    }

    .map-header.is-search-history-open {
        bottom: 0;
        height: 50dvh;
        min-height: 50dvh;
        max-height: 50dvh;
        padding: 20px 16px 24px;
        border-radius: 38px 38px 0 0;
        grid-template-rows: 40px minmax(0, 1fr);
        row-gap: 16px;
    }

    .map-header.is-search-history-open::before {
        inset: 0;
        border-radius: 38px 38px 0 0;
        background: #FFFFFF;
        box-shadow: 0 15px 37.5px rgba(0, 0, 0, 0.18);
        backdrop-filter: none;
        -webkit-backdrop-filter: none;
    }

    .map-header.is-search-history-open .search-container {
        grid-column: 1 / -1;
        grid-row: 1 / -1;
        width: 100%;
        height: 100%;
        display: flex;
        flex-direction: column;
        gap: 16px;
        overflow: hidden;
    }

    .map-header.is-search-history-open .search-input-container {
        flex: 0 0 40px;
        width: calc(100% - 52px);
        background: #F5F5F5;
    }

    .map-header.is-search-history-open .map-header-actions {
        position: absolute;
        top: 0;
        right: 16px;
        z-index: 3;
    }

    .map-header.is-search-history-open .categories {
        display: none;
    }

    .map-header.is-search-history-open .search-results.is-history {
        position: static;
        display: block;
        flex: 1 1 auto;
        width: 100%;
        min-height: 0;
        max-height: none;
        padding: 0;
        border: 0;
        border-radius: 0;
        background: transparent;
        box-shadow: none;
        backdrop-filter: none;
        -webkit-backdrop-filter: none;
        overflow-y: auto;
    }

    .map-header.is-search-history-open .search-history-list {
        display: flex;
        width: 100%;
        flex-direction: column;
    }

    .map-header.is-search-history-open .search-history-item {
        min-height: 42px;
        border-radius: 6px;
    }

    .map-header.is-search-history-open .search-history-query {
        min-height: 42px;
        padding: 8px 12px;
    }

    .map-header.is-search-history-open .search-history-remove {
        display: none;
    }

    .map-header.is-search-results-open {
        bottom: 0;
        height: 50dvh;
        min-height: 50dvh;
        max-height: 50dvh;
        padding: 20px 16px 0;
        border-radius: 38px 38px 0 0;
        grid-template-rows: 40px minmax(0, 1fr);
        row-gap: 0;
    }

    .map-header.is-search-results-open::before {
        inset: 0;
        border-radius: 38px 38px 0 0;
        background: #FFFFFF;
        box-shadow: 0 15px 37.5px rgba(0, 0, 0, 0.18);
        backdrop-filter: none;
        -webkit-backdrop-filter: none;
    }

    .map-header.is-search-results-open .search-container {
        grid-column: 1 / -1;
        grid-row: 1 / -1;
        width: 100%;
        height: 100%;
        min-height: 0;
        display: flex;
        flex-direction: column;
        gap: 12px;
        overflow: visible;
    }

    .map-header.is-search-results-open .search-input-container {
        flex: 0 0 40px;
        width: calc(100% - 52px);
        background: #F5F5F5;
    }

    .map-header.is-search-results-open .map-header-actions {
        position: absolute;
        top: 0;
        right: 16px;
        z-index: 3;
    }

    .map-header--guest.is-search-history-open .map-header-actions,
    .map-header--guest.is-search-results-open .map-header-actions {
        display: flex;
    }

    .map-header.is-search-results-open .categories {
        display: none;
    }

    .map-header .search-results.is-results {
        top: 88px;
        left: 14px;
        right: 14px;
        bottom: auto;
        width: auto;
        height: min(70dvh, calc(100dvh - 220px));
        max-height: calc(100dvh - 220px);
        border-radius: 22px;
    }

    .map-header.is-search-results-open .search-results.is-results {
        position: static;
        display: block;
        flex: 1 1 auto;
        width: 100vw;
        min-height: 0;
        max-height: none;
        height: auto;
        margin: 0 calc(50% - 50vw);
        padding: 0;
        border: 0;
        border-radius: 0;
        background: transparent;
        box-shadow: none;
        backdrop-filter: none;
        -webkit-backdrop-filter: none;
        overflow: hidden;
    }

    .map-header.is-search-results-open .search-results-heading {
        display: none;
    }

    .search-results-heading {
        padding: 20px 18px 0;
    }

    .search-results-list {
        padding: 14px 18px 20px;
    }

    .map-header.is-search-results-open .search-results-list {
        height: 100%;
        max-height: none;
        padding: 0;
        gap: 0;
        overflow-y: auto;
        scrollbar-width: none;
    }

    .map-header.is-search-results-open .search-results-list::-webkit-scrollbar {
        width: 0;
        height: 0;
    }

    .search-history-remove {
        opacity: 1;
    }

    .map-header .search-results:not(.is-results) .search-result-item {
        min-height: 94px;
        padding: 12px 0;
        border-radius: 0;
        background: #FFFFFF;
        border-bottom: 1px solid #E5E5E5;
    }

    .map-header .search-results:not(.is-results) .search-result-item + .search-result-item {
        margin-top: 0;
    }

    .map-header .search-results.is-results .search-result-item {
        width: 100%;
        min-height: 118px;
        padding: 14px;
        border-radius: 12px;
        border-bottom: 0;
    }

    .map-header.is-search-results-open .search-results.is-results .search-result-item {
        width: 100%;
        min-height: 126px;
        padding: 16px 22px;
        border-radius: 0;
        border-bottom: 1px solid #E5E5E5;
        background: #FFFFFF;
        gap: 16px;
    }

    .map-header.is-search-results-open .search-results.is-results .search-result-item:hover {
        background: #F2FBF7;
    }

    .map-header.is-search-results-open .search-results.is-results .result-info {
        min-height: 94px;
    }

    .map-header .search-results.is-results .result-name {
        width: min(154px, 100%);
    }

    .map-header .search-results.is-results .result-thumb,
    .map-header .search-results.is-results .result-thumb-placeholder {
        width: 84px;
        height: 84px;
    }

    .map-header.is-search-results-open .search-results.is-results .result-thumb,
    .map-header.is-search-results-open .search-results.is-results .result-thumb-placeholder {
        width: 94px;
        height: 94px;
    }

    .result-thumb,
    .result-thumb-placeholder,
    .result-icon {
        width: 76px;
        height: 76px;
        margin-right: 4px;
    }

    .map-controls {
        top: 50%;
        right: 16px;
        bottom: auto;
        transform: translateY(-50%);
    }

    .admin-btn {
        bottom: 150px;
    }

    .modal {
        display: flex;
        visibility: hidden;
        pointer-events: none;
        top: auto;
        left: 0;
        right: 0;
        bottom: 0;
        width: 100%;
        height: 66.6667dvh;
        min-height: 66.6667dvh;
        max-width: none;
        max-height: 66.6667dvh;
        overflow-y: auto;
        border-radius: 38px 38px 0 0;
        background: #FFFFFF;
        box-shadow: 0 15px 75px rgba(0, 0, 0, 0.18);
        backdrop-filter: none;
        -webkit-backdrop-filter: none;
        opacity: 0;
        transform: translateY(100%);
        transition:
            transform 380ms cubic-bezier(0.22, 1, 0.36, 1),
            opacity 220ms ease,
            visibility 0s linear 380ms,
            height 360ms cubic-bezier(0.22, 1, 0.36, 1),
            min-height 360ms cubic-bezier(0.22, 1, 0.36, 1),
            max-height 360ms cubic-bezier(0.22, 1, 0.36, 1),
            border-radius 360ms cubic-bezier(0.22, 1, 0.36, 1);
        will-change: transform;
    }

    .modal.is-open {
        visibility: visible;
        pointer-events: auto;
        opacity: 1;
        transform: translateY(0);
        transition:
            transform 380ms cubic-bezier(0.22, 1, 0.36, 1),
            opacity 220ms ease,
            visibility 0s,
            height 360ms cubic-bezier(0.22, 1, 0.36, 1),
            min-height 360ms cubic-bezier(0.22, 1, 0.36, 1),
            max-height 360ms cubic-bezier(0.22, 1, 0.36, 1),
            border-radius 360ms cubic-bezier(0.22, 1, 0.36, 1);
    }

    .modal.is-expanded {
        height: 100dvh;
        min-height: 100dvh;
        max-height: 100dvh;
        border-radius: 0;
    }

    .modal.is-expanded .modal-header,
    .modal.is-expanded .modal-review-link {
        border-radius: 0;
    }

    .modal.is-review-pinned .modal-review-link {
        position: sticky;
        bottom: 0;
        margin-top: auto;
    }

    .modal::before {
        content: "";
        position: absolute;
        top: 5px;
        left: 50%;
        z-index: 5;
        width: 36px;
        height: 5px;
        border-radius: 999px;
        background: #FFFFFF;
        transform: translateX(-50%);
    }

    .modal-header {
        height: 240px;
        min-height: 240px;
        flex-basis: 240px;
        border-radius: 38px 38px 0 0;
    }

    .modal-body {
        flex: 0 0 auto;
        gap: 24px;
        margin-top: -40px;
        margin-bottom: -24px;
        padding: 24px;
        border-radius: 0;
        background: #FFFFFF;
    }

    .modal-title-name {
        font: 600 20px/24px 'Inter', 'Roboto', sans-serif;
    }

    .modal-review-link {
        position: static;
        bottom: auto;
        z-index: 3;
        flex: 0 0 auto;
        width: 100%;
        margin: auto 0 0;
        padding: 40px 24px 16px;
        border-top: 0;
        border-radius: 0 0 38px 38px;
        background: #FFFFFF;
    }

    .modal-info-row.occupancy.occupancy-low,
    .modal-info-row.occupancy.occupancy-medium,
    .modal-info-row.occupancy.occupancy-high {
        border: 0 !important;
    }

}

@media (prefers-reduced-motion: reduce) {
    .map-header,
    .map-header::before,
    .modal,
    .modal.is-open {
        transition-duration: 0.01ms;
    }

    .map-header .search-results.is-results {
        animation-duration: 0.01ms;
    }
}
