/* Staging comparison. Keep the map visible while the answer and list scroll. */
body .ihr-map-explorer.snowshoe-split {
    --split-top: var(--ihr-header-height, 66px);
    height: calc(100svh - var(--split-top));
    min-height: 440px;
    scroll-margin-top: var(--split-top) !important;
    padding: 10px 24px 8px !important;
    display: flex;
    flex-direction: column;
    box-sizing: border-box;
}
body.admin-bar [data-snowshoe-review] .snowshoe-split {
    --split-top: calc(var(--ihr-header-height, 66px) + 32px);
}
.snowshoe-split .ihr-map-explorer__heading {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    width: min(1180px, 100%);
    margin: 0 auto 8px !important;
    text-align: left;
}
.snowshoe-split .ihr-map-explorer__heading p { display: none; }
.snowshoe-split .ihr-map-explorer__heading h2 {
    font-size: clamp(23px, 2.4vw, 34px) !important;
    margin: 0 !important;
}
.snowshoe-split .ihr-map-explorer__heading a {
    color: #f4e2b5;
    font-size: 13px;
    padding: 6px 0;
}
body .ihr-map-explorer.snowshoe-split .ihr-map-explorer__layout {
    flex: 1;
    min-height: 0 !important;
    align-items: stretch !important;
    grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr) !important;
    gap: 12px !important;
    padding: 8px !important;
}
.snowshoe-split .ihr-map-column { display: flex; flex-direction: column; min-height: 0; }
body .ihr-map-explorer.snowshoe-split #ihr-interactive-map.ihr-interactive-map {
    flex: 1;
    aspect-ratio: auto;
    min-height: 0 !important;
    height: auto !important;
}
body .ihr-map-explorer.snowshoe-split .ihr-map-explorer__panel { height: 100% !important; min-height: 0; }
.snowshoe-split .snowshoe-split-response {
    position: relative;
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    overscroll-behavior-y: contain;
}
body .ihr-map-explorer.snowshoe-split .cp-ask {
    flex: none;
    width: auto;
    margin: 0 !important;
    padding: 10px 14px !important;
    color: #fff;
    background: #304e6b;
    clip-path: none;
}
.snowshoe-split .cp-ask::before, .snowshoe-split .cp-ask::after,
.snowshoe-split .cp-ask-intro { display: none !important; }
body .ihr-map-explorer.snowshoe-split .cp-ask > .cp-wrap {
    display: block !important;
    padding: 0 !important;
}
.snowshoe-split .cp-ask-brand { margin-bottom: 6px !important; }
.snowshoe-split .cp-ask-brand img { max-height: 25px; width: auto; }
.snowshoe-split #cp-ask-form { margin: 0 !important; }
.snowshoe-split .cp-chips { gap: 5px !important; }
.snowshoe-split .cp-chips button { font-size: 12px !important; padding: 5px 8px !important; }
.snowshoe-split .cp-demo-note { margin: 6px 0 0 !important; }
body .ihr-map-explorer.snowshoe-split #cp-results {
    margin: 0;
    padding: 12px 16px;
    border-bottom: 1px solid #d2cec3;
}
body .ihr-map-explorer.snowshoe-split #cp-results h3 { font-size: 19px; margin: 0 0 5px; }
.snowshoe-split #cp-results p { margin: 0; }
.snowshoe-split .snowshoe-detail-actions { margin-top: 5px; }
body .ihr-map-explorer.snowshoe-split .snowshoe-relevant-details { margin: 0; padding: 14px 16px; }
body .ihr-map-explorer.snowshoe-split .ihr-map-place-detail { max-height: none; }
.snowshoe-split .ihr-map-explorer__note {
    flex: none;
    width: min(1180px, 100%);
    max-width: none;
    margin: 6px auto 0 !important;
    font-size: 11px;
}

.snowshoe-split .ihr-map-explorer__heading { max-width: none; }
body .ihr-map-explorer.snowshoe-split .cp-ask > .cp-wrap { width: 100%; margin: 0; }
body .ihr-map-explorer.snowshoe-split .cp-ask-brand { min-height: 0; }


/* Layer the selected place over only the lower part of the map. */
body .ihr-map-explorer.snowshoe-split .ihr-map-column {
    display: grid;
    grid-template-rows: minmax(0, 1fr) auto;
}
body .ihr-map-explorer.snowshoe-split #ihr-interactive-map.ihr-interactive-map {
    grid-area: 1 / 1;
    height: 100% !important;
}
.snowshoe-split .ihr-map-column > .diana-map-instruction {
    grid-area: 2 / 1;
}
.snowshoe-map-card {
    grid-area: 1 / 1;
    position: relative;
    z-index: 3;
    align-self: end;
    justify-self: center;
    width: min(420px, calc(100% - 24px));
    max-height: 49%;
    margin-bottom: 28px;
    overflow: auto;
    overscroll-behavior: contain;
    background: #f9f2e6;
    color: #304e6b;
    border-top: 4px solid #304e6b;
    box-shadow: 0 3px 16px #18283755;
    box-sizing: border-box;
}
body .snowshoe-split .snowshoe-map-card .ihr-map-place-detail {
    padding: 10px 42px 12px 14px !important;
    overflow: visible;
}
.snowshoe-map-card #map-place-title {
    font-size: 18px;
    line-height: 1.25;
    text-transform: none;
}
.snowshoe-map-card .ihr-map-place-detail p { margin: 5px 0; }
.snowshoe-map-card .ihr-map-place-detail__links { margin-top: 8px; }
.snowshoe-map-card-close {
    position: sticky;
    top: 0;
    float: right;
    z-index: 1;
    width: 44px;
    height: 44px;
    border: 0;
    background: #f9f2e6;
    color: #304e6b;
    font: 26px/1 sans-serif;
    cursor: pointer;
}

.snowshoe-split .snowshoe-map-card[hidden] { display: none !important; }
body .ihr-map-explorer.snowshoe-split .ihr-map-list-column {
    display: flex;
    flex-direction: column;
    height: 100%;
    min-height: 0;
    background: #f9f2e6;
    overflow: hidden;
}
body .ihr-map-explorer.snowshoe-split.ihr-split-service > .cp-wrap {
    display: flex !important;
    flex-direction: column;
    flex: 1;
    min-height: 0;
}
body .ihr-map-explorer.snowshoe-split #ihr-interactive-map {
    grid-area: 1 / 1;
    height: 100% !important;
    min-height: 0 !important;
    aspect-ratio: auto !important;
}
body .snowshoe-split #ihr-place-list { max-height: none; overflow: visible; }
body .snowshoe-split .ihr-ask-scope { margin: 5px 0; gap: 8px; }
body .snowshoe-split .ihr-ask-scope :is(select,input) { min-height: 32px; padding: 3px 6px; }
body .snowshoe-split .cp-ask { max-height: 60%; overflow-y: auto; }
body .snowshoe-split #ihr-map-status { grid-area: 1 / 1; align-self: start; justify-self: start; z-index: 2; pointer-events: none; margin: 4px; }
body .snowshoe-split .snowshoe-map-card #ihr-map-detail { padding: 10px 42px 12px 14px; }
body .snowshoe-split .snowshoe-split-response > :is(#ihr-map-summary,#ihr-access-notes,.ihr-map-actions) { margin: 8px 12px; }
body .snowshoe-split .cp-wrap > .ihr-map-explorer__note { margin-top: 6px !important; font-size: 11px !important; }
body .ihr-map-pin[aria-pressed="true"]::before {
    background: #fff !important;
    box-shadow: 0 0 0 4px #a63f2d, 0 0 0 6px #fff !important;
}

.snowshoe-split .snowshoe-split-response > details {
    padding: 12px 16px;
    color: #304e6b;
    border-bottom: 1px solid #d2cec3;
}
.snowshoe-split .snowshoe-split-response > details summary { cursor: pointer; font-weight: 700; }

/* One scroll owner for the complete desktop Ask column, including long answers.
   split.js restores the natural stacked layout below 960px or 540px height. */
body .ihr-map-explorer.snowshoe-split :is(.ihr-map-explorer__panel, .ihr-map-list-column) {
    overflow-y: auto !important;
    overflow-x: hidden !important;
    overscroll-behavior-y: contain;
    scrollbar-gutter: stable;
}
body .ihr-map-explorer.snowshoe-split :is(.ihr-map-explorer__panel, .ihr-map-list-column) > * {
    flex-shrink: 0;
}
body .ihr-map-explorer.snowshoe-split .snowshoe-split-response {
    flex: 0 0 auto !important;
    min-height: auto;
    overflow: visible !important;
}
body .ihr-map-explorer.snowshoe-split .cp-ask {
    max-height: none !important;
    overflow: visible !important;
}
body .ihr-map-explorer.snowshoe-split :is(.ihr-map-place-list, #ihr-place-list) {
    flex: none;
    max-height: none !important;
    overflow: visible !important;
}

/* Small screens and short windows use page scrolling, not clipped nested lists. */
@media (max-width: 959px), (max-height: 539px) {
    body .ihr-map-explorer :is(.ihr-map-explorer__panel, .ihr-map-list-column) {
        height: auto !important;
        max-height: none !important;
        overflow: visible !important;
    }
    body .ihr-map-explorer :is(.ihr-map-place-list, #ihr-place-list) {
        height: auto !important;
        max-height: none !important;
        overflow: visible !important;
    }
}
body.admin-bar .ihr-map-explorer.snowshoe-split {
    --split-top: calc(var(--ihr-header-height, 66px) + 32px);
}
