/* Self-hosted Montserrat (variable font, wght 100–900; the app uses 400 & 500) —
   replaces the third-party Google Fonts CSS request + collapses the font load chain.
   latin + latin-ext only (Czech). font-display:swap → text shows in the fallback font
   immediately, then swaps to Montserrat. Unicode ranges match Google's subsetting. */
@font-face {
    font-family: 'Montserrat';
    font-style: normal;
    font-weight: 400 500;
    font-display: swap;
    src: url('/assets/fonts/montserrat-latin-ext.woff2') format('woff2');
    unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
    font-family: 'Montserrat';
    font-style: normal;
    font-weight: 400 500;
    font-display: swap;
    src: url('/assets/fonts/montserrat-latin.woff2') format('woff2');
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
    --brand-color: #005CA5; /* overridden inline by config.js with config.themeColor (#00b199) */
    --theme-color: var(--brand-color, #005CA5);
    --foreground-text: #4d4d4d;
    --background-color: #f9f9f6;
    --surface: #ffffff;
    --border: #e4e4d8;
    --muted: #b2b2b2;
    --overlay: rgba(0, 0, 0, 0.5);
    --thumbBG: var(--theme-color);
    --scrollbarBG: var(--background-color);
}

html.dark {
    --theme-color: #1dd1a1;
    --foreground-text: #e0e0e0;
    --background-color: #1a1a2e;
    --surface: #16213e;
    --border: #2a2a4a;
    --muted: #8a8aa0;
    --overlay: rgba(0, 0, 0, 0.6);
}

html.colorblind {
    --theme-color: #000000;
    --foreground-text: #000000;
    --background-color: #ffffff;
    --surface: #ffffff;
    --border: #000000;
    --muted: #000000;
    --overlay: rgba(0, 0, 0, 0.6);
}

* {
    margin: 0;
    padding: 0;
    font-family: Montserrat, sans-serif;
}

html, body {
    min-height: 100% !important;
    height: 100%;
    width: 100%;
    overflow: hidden;
}

#unsupported {
    height: 100%;
    width: 100%;
    min-height: 100% !important;
    color: #f9f9f6;
    text-align: center;
    font-size: 24px;
    padding-top: 250px;
}

.hidden {
    visibility: hidden;
}

.metadata-marker {
    display: none;
}

.gis-map-layers {
    overflow-y: auto;
    /* Bottom room so the last layer clears the Google attribution (bottom-left). */
    padding-bottom: 44px;
}

.gis-map-layers {
    scrollbar-width: thin;
    scrollbar-color: var(--thumbBG) var(--scrollbarBG);
}

.gis-map-layers::-webkit-scrollbar {
    width: 6px;
}

.gis-map-layers::-webkit-scrollbar-track {
    background: var(--scrollbarBG);
}

.gis-map-layers::-webkit-scrollbar-thumb {
    background-color: var(--thumbBG);
    border-radius: 6px;
    border: 3px solid var(--scrollbarBG);
}

#map {
    height: 100%;
    width: 100%;
}

/* High-contrast: monochrome base map to match the B&W pins/overlays. Target the
   map's render layer (first child of .gm-style) so the control overlays and the
   point-detail modal (with photos) are NOT grayscaled. */
html.colorblind #map .gm-style > div:first-child { filter: grayscale(1); }

.gis-dropdown__container {
    display: none;
    padding-top: 50px;
    background: var(--background-color);
}

.gis-map-layers--visible,
.gis-map-types--visible,
.gis-search-layer--visible,
.gis-map-measure--visible,
.gis-help--visible {
    display: block !important;
}

.gis-map-layers--visible.gis-search-layer--visible {
    margin-top: 50px;
}

.gis-dropdown__container ul {
    list-style: none inside none;
}

.gis-dropdown__container > ul > li {
    padding-top: 15px;
    padding-bottom: 15px;
    padding-right: 20px;
}

.gis-dropdown__container > ul > li:not(:last-child) {
    border-bottom: solid 1px var(--scrollbarBG);
}

.gis-search-layer {
    padding-top: 0 !important;
    display: none;
}

.gis-search-highlight {
    background-color: #fff176;
    color: inherit;
    padding: 0 1px;
    border-radius: 2px;
}

.loading-box {
    position: fixed !important;
    display: block;
    left: calc(50% - 2.5rem);
    top: calc(50% - 2.5rem);
    width: 80px;
    height: 80px;
    z-index: 1001 !important;
    visibility: hidden;
}

.loading-box div {
    box-sizing: border-box;
    display: block;
    position: absolute;
    width: 64px;
    height: 64px;
    margin: 8px;
    border: 8px solid #fff;
    border-radius: 50%;
    animation: spinner 1.2s cubic-bezier(0.5, 0, 0.5, 1) infinite;
    border-color: var(--theme-color) transparent transparent transparent;
}

.loading-box div:nth-child(1) {
    animation-delay: -0.45s;
}

.loading-box div:nth-child(2) {
    animation-delay: -0.3s;
}

.loading-box div:nth-child(3) {
    animation-delay: -0.15s;
}

@keyframes spinner {
    0% {
        transform: rotate(0deg);
    }
    100% {
        transform: rotate(360deg);
    }
}

.loading-backdrop {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.15);
    backdrop-filter: blur(2px);
    -webkit-backdrop-filter: blur(2px);
    z-index: 10;
    pointer-events: none;
    visibility: hidden;
}

/*
LAYERS DROPDOWN
*/

.gis-dropdown__container--layers label {
    display: flex;
    flex: 1 0 auto;
    align-items: center;
    justify-content: space-around;
    cursor: pointer;
}


.gis-dropdown__container--layers li ul {
    flex-basis: 100%;
}

.gis-dropdown__container--layers li.gis-dropdown__expandable-list {
    padding-left: 0;
}

/*
MAP TYPES DROPDOWN
*/

.gis-dropdown__container--map-types ul li,
.gis-dropdown__container--search ul li,
.gis-dropdown__container--measure ul li {
    padding-left: 19px;
}

.gis-dropdown__container--map-types .gis-dropdown__title {
    position: relative;
    overflow: hidden;
}

.gis-dropdown__container--map-types .gis-dropdown__title input[type="radio"] {
    position: absolute;
    top: -500px;
}

.gis-dropdown__container--map-types .gis-dropdown__title input[type="radio"] + span {
    color: var(--muted);
}

.gis-dropdown__container--map-types .gis-dropdown__title input[type="radio"]:checked + span {
    color: var(--foreground-text);
}

/* show a check on the selected base map (space reserved on both so labels align) */
.gis-dropdown__container--map-types .gis-dropdown__title span::before {
    content: '';
    display: inline-block;
    width: 1.25rem;
    height: 1.25rem;
    margin-right: 10px;
    vertical-align: middle;
    background: no-repeat center / contain;
}
.gis-dropdown__container--map-types .gis-dropdown__title input[type="radio"]:checked + span::before {
    background-image: url('/assets/icons/tick.svg');
}
html.colorblind .gis-dropdown__container--map-types .gis-dropdown__title input[type="radio"]:checked + span::before {
    filter: brightness(0);
}

.gis-dropdown__container--map-types label {
    cursor: pointer;
}

/* Theme-mode radios in the Help overlay ("Zobrazení") — mirror the base-map picker:
   hide the native radio, show a tick on the selected mode (black in high-contrast). */
.gis-help__theme .gis-dropdown__title input[type="radio"] {
    position: absolute;
    top: -500px;
}
.gis-help__theme .gis-dropdown__title input[type="radio"] + span {
    color: var(--muted);
}
.gis-help__theme .gis-dropdown__title input[type="radio"]:checked + span {
    color: var(--foreground-text);
}
.gis-help__theme .gis-dropdown__title span::before {
    content: '';
    display: inline-block;
    width: 1.25rem;
    height: 1.25rem;
    margin-right: 10px;
    vertical-align: middle;
    background: no-repeat center / contain;
}
.gis-help__theme .gis-dropdown__title input[type="radio"]:checked + span::before {
    background-image: url('/assets/icons/tick.svg');
}
html.colorblind .gis-help__theme .gis-dropdown__title input[type="radio"]:checked + span::before {
    filter: brightness(0);
}
.gis-help__theme label {
    cursor: pointer;
}

/*
EXPANDABLE LIST
*/
.gis-dropdown__expandable-list ul {
    display: none;
}

.gis-dropdown__expandable-list label {
    justify-content: unset;
}

.gis-dropdown__expandable-indicator img {
    position: absolute;
    top: 50%;
    transform: translateY(-50%) rotate(90deg);
    transition: transform 250ms;
}

.gis-dropdown__expandable-list--expanded ul {
    display: block;
}

.gis-dropdown__expandable-list--expanded .gis-dropdown__expandable-indicator img {
    transform: translateY(-50%) rotate(180deg);
}

.gis-dropdown__checkbox input[type="checkbox"] {
    position: absolute;
    left: -2000px;
}

.gis-dropdown__checkbox input[type="checkbox"]:checked + span {
    background: transparent url('/assets/icons/tick.svg') no-repeat center;
    display: inline-block;
}

.gis-dropdown__checkbox span {
    display: none;
    position: absolute;
    width: 1.5rem;
    height: 1.5rem;
}

.layer-new {
    display: inline-block;
    height: 14px;
    width: 2px;
    background-color: var(--theme-color);
}

.gis-dropdown__external span {
    position: absolute;
    width: 1.5rem;
    height: 1.5rem;
    background: transparent url('/assets/icons/layer_ext.svg') no-repeat center;
    background-size: 32px 32px;
    margin-left: 1px;
    display: inline-block;
}


.gis-dropdown__checkbox input[type="checkbox"]:indeterminate + span {
    background: transparent url('/assets/icons/dash.svg') no-repeat center;
    display: inline-block;
}


.gis-dropdown__title,
.gis-help__title {
    line-height: 1.5rem;
    color: var(--foreground-text);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    width: 18.75rem;
}

.gis-dropdown__title {
    margin-left: 5px;
}


.gis-dropdown__title-img {
    margin-left: auto;
    width: 1.5rem;
    height: 1.5rem;
    text-align: center;
}

.gis-dropdown__title-img img {
    width: 1.5rem;
    height: 1.5rem;
}

/*
GIS TOGGLE BUTTON
 */

.gis-toggle-button {
    position: absolute;
    top: 7px;
    width: 2.25rem;
    height: 2.25rem;
    text-align: center;
    opacity: 1;
    border: none;
    outline: none;
    cursor: pointer;
}

/*
EXPAND ALL LAYERS
*/

.gis-expand-all-layers__expanded {
    display: none;
}

.gis-expand-all-layers input[type="checkbox"] {
    display: none;
}

.gis-expand-all-layers input[type="checkbox"]:checked ~ .gis-expand-all-layers__collapsed {
    display: none;
}

.gis-expand-all-layers input[type="checkbox"]:checked ~ .gis-expand-all-layers__expanded {
    display: inline-block;
}

.gis-toggle-layers:hover {
    background: transparent url('/assets/icons/vrstvy_hover.svg') 0 0 no-repeat padding-box;
}

.gis-toggle-map-type svg {
    transition: transform 250ms;
    transform: rotate(90deg);
    margin-left: 22px;
    margin-top: -2px;
    vertical-align: text-top;
    pointer-events: none;
}

.gis-toggle-map-type svg path {
    fill: #ffffff;
}

.gis-toggle-map-type--open svg {
    transform: rotate(180deg);
}

.gis-set-center:hover {
    background: transparent url('/assets/icons/center_position_1_hover.svg') 0 0 no-repeat padding-box;
}

.gis-set-minus:hover {
    background: transparent url('/assets/icons/minus_hover.svg') 0 0 no-repeat padding-box;
}

.gis-set-plus:hover {
    background: transparent url('/assets/icons/plus_hover.svg') 0 0 no-repeat padding-box;
}

.gis-toggle-help:hover {
    background: transparent url('/assets/icons/help_hover.svg') 0 0 no-repeat padding-box;
}

.gis-help__title {
    padding: 15px 30px 5px 30px;
    font-weight: 500;
}

.gis-dropdown__container--help > ul {
    padding-bottom: 20px;
    margin-bottom: 10px;
    border-bottom: solid 1px var(--scrollbarBG);
}

.gis-dropdown__container--help > ul > li,
.gis-dropdown__container--help > ul > li:not(:last-child) {
    display: flex;
    align-items: center;
    padding: 7.5px 30px;
    line-height: 1.375rem;
    font-weight: 300;
    color: var(--foreground-text);
    border-bottom: none;
}

.gis-dropdown__container--help > ul > li svg {
    display: inline-block;
    margin-right: 15px;
    color: var(--theme-color); /* #20: help-list icons follow the active theme (fill=currentColor) */
}

/* #20: version / "O aplikaci" links in brand color (was default blue/violet) */
.gis-dropdown__container--help a,
.gis-dropdown__container--help a:link,
.gis-dropdown__container--help a:visited,
.gis-dropdown__container--help a:hover,
.gis-dropdown__container--help a:active { color: var(--theme-color); }

.gis-dropdown__container--search {
    display: block;
}

.gis-help p {
    display: inline-block;
    padding: 15px 30px 20px 30px;
    line-height: 1.375rem;
    font-weight: 300;
    color: var(--foreground-text);
}

/*
MODAL
*/

.gis-linkified {
    display: inline-block;
    color: var(--theme-color);
}

#gis-modal-layer {
    left: 0 !important;
    z-index: 50 !important;
}

#gis-modal-picture-layer {
    left: 0 !important;
    z-index: 70 !important;
}

#gis-modal-sharer-layer, #gis-modal-billboard-layer, #gis-modal-sharer-layer, #gis-modal-point-layer {
    left: 0 !important;
    z-index: 90 !important;
}

.gis-modal__backdrop {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: var(--overlay);
}

.gis-modal__handle {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 11px 12px 11px 20px;
    background: var(--theme-color);
    border-radius: 0 0 6px 6px;
}

.gis-modal__handle em {
    font-weight: 500;
    font-style: normal;
    color: #FFFFFF;
}

.gis-modal__type {
    display: block;
    margin-bottom: 0.7rem;
    font-weight: 500;
    font-style: normal;
    line-height: 1.5rem;
    color: var(--foreground-text);
}

.gis-modal-meta {
    display: flex;
    flex-direction: column;
    margin-bottom: 0.2rem;
    color: var(--foreground-text);
}

.gis-modal--link {
    position: absolute;
    right: 34px;
}

.gis-modal--link img {
    width: 38px;
}

.gis-modal--link-layer {
    position: absolute;
    right: 68px;
}

.gis-modal--link-layer img {
    width: 38px;
}

.gis-modal--link-navigate {
    position: absolute;
    right: 103px;
}

.gis-modal--link-navigate img {
    height: 26px;
    width: 26px;
}

.gis-modal--copy-point {
    position: absolute;
    right: 134px;
}

.gis-modal--copy-point img {
    height: 18px;
    width: 18px;
}

@media (min-width: 480px) {
    /* .gis-modal-meta {
        flex-direction: row;
    }
     */
}

.gis-modal-meta > div:first-child {
    --margin-right: 26px;
}

.gis_modal__link_container {
    width: 95%;
}

.gis_modal__link_container_list {
    width: 90%;
}

.gis_modal__link_container_list ul {
    list-style: none
}

.gis_modal__link_container_list li {
    display: block;
}

.gis-modal__link,
.gis-modal__link:visited,
.gis-modal__link:active,
.gis-modal__link:hover {
    display: inline-block;
    color: var(--theme-color);
}

.gis-modal__button,
.gis-modal__button:visited,
.gis-modal__button:active,
.gis-modal__button:hover {
    display: inline-block;
    background-color: var(--theme-color);
    font-weight: 500;
    font-style: normal;
    color: #FFFFFF;
    padding: 0.5rem 0.8rem 0.5rem 0.8rem;
    margin-left: 35%;
    border-radius: 6px;
    text-decoration: none;
}

@media (min-width: 768px) {
    .gis-modal__link {
        margin-bottom: 0;
    }
}

.gis-modal-picture__backdrop {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: var(--overlay);
}

.gis-modal-picture__content {
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100%;
    max-width: 820px;
    line-height: 1.375rem;
    max-height: 98vh;
    background: var(--background-color);
}

.gis-modal-picture__handle {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 11px 12px 11px 20px;
    background: var(--theme-color);
    border-radius: 0 0 6px 6px;
}

.gis-modal-picture__carret-left, .gis-modal-picture__carret-right {
    display: block;
    border-radius: 6px;
    color: #FFFFFF;
    background: var(--theme-color);
    position: relative;
    text-align: center;
    vertical-align: middle;
    margin-right: -100px;
    opacity: 80%;
    cursor: pointer;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
}

.gis-modal-picture__carret-left:hover, .gis-modal-picture__carret-right:hover {
    opacity: 100%;
}

.gis-modal-picture__carret-left {
    float: left !important;
    margin-left: -1rem;
}

.gis-modal-picture__carret-right {
    float: right !important;
    margin-right: -6rem;
}

.gis-modal-picture__handle em {
    font-weight: 500;
    font-style: normal;
    color: #FFFFFF;
}

.gis-modal-picture__body {
    display: flex;
    padding: 1rem 60px 40px 20px;
}

.gis-modal-picture__icon {
    margin-right: 14px;
}

.gis-modal-picture-meta {
    display: flex;
    flex-direction: column;
    margin-bottom: 10px;
    color: var(--foreground-text);
}

@media (min-width: 480px) {
    .gis-modal-picture-meta {
        flex-direction: row;
    }
}

.gis-modal-picture-meta > div:first-child {
    margin-right: 26px;
}

.gis-modal-picture__desc {
    display: flex;
    flex-direction: column;
    padding: 1rem 0 0 0;
    border-top: 1px solid var(--border);
}

.gis-modal-picture__desc__text {
    order: 0;
    width: 300px;
    word-wrap: normal;
}

.gis-modal-picture__desc__image {
    order: 1;
    margin-top: 10px;
}

@media (min-width: 768px) {
    .gis-modal-picture__desc {
        display: flex;
        flex-direction: row;
    }
}

.gis-modal-picture__desc > div:last-child {
    flex: 1 0 32%;
}

.gis-modal-picture__desc picture {
    margin-left: 10px;
    margin-top: 40px;
    max-width: 100%;
}

.gis-modal-picture__title {
    display: block;
    margin-bottom: 1rem;
    font-style: normal;
    color: var(--foreground-text);

}

.gis-modal-picture__desc p {
    margin-bottom: 24px;
    color: var(--foreground-text);
    white-space: pre-wrap;
}

.gis-modal-picture__link,
.gis-modal-picture__link:visited,
.gis-modal-picture__link:active,
.gis-modal-picture__link:hover {
    display: inline-block;
    color: var(--theme-color);
}

@media (min-width: 768px) {
    .gis-modal-picture__link {
        margin-bottom: 0;
    }
}

.gis-modal-sharer__backdrop, .gis-modal-billboard_backdrop, .gis-modal-point_backdrop {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: var(--overlay);
}

.gis-modal-sharer__content, .gis-modal-billboard__content, .gis-modal-point__content {
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100%;
    max-width: 520px;
    line-height: 1.375rem;
    max-height: 98vh;
    background: var(--background-color);
}

.gis-modal-sharer__handle, .gis-modal-billboard__handle, .gis-modal-point__handle {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 11px 12px 11px 20px;
    background: var(--theme-color);
    border-radius: 0 0 6px 6px;
}

.gis-modal-sharer-text, .gis-modal-billboard-text, .gis-modal-point-text {
    vertical-align: baseline;
    display: inline-block;
    width: fit-content;
    padding-top: 4px;
}

.gis-modal-sharer-link, .gis-modal-billboard-link, .gis-modal-point-link {
    display: inline-block;
    width: 100%;
}

.gis-modal-sharer-link-container {
    display: inline-block;
    position: relative;
    margin-left: 20px;
    width: 90%;
    height: 1.785rem;
    border-radius: 2px;
    border: 1px solid var(--theme-color);
    background-color: var(--surface);
    overflow: hidden;
    cursor: default;
    font-family: 'Montserrat';
    font-size: 1.125rem;
}

.gis-modal-sharer-link-container:focus {
    outline: none !important;
    border-color: var(--theme-color);
    box-shadow: 0 0 10px var(--theme-color);
}

.gis-modal-sharer__handle em, .gis-modal-billboard__handle em, .gis-modal-point__handle em {
    font-weight: 500;
    font-style: normal;
    color: #FFFFFF;
}

.gis-modal-sharer__body {
    display: flex;
    padding: 1.5rem 1.5rem 1.5rem 1.5rem;
}

.gis-modal-billboard__body, .gis-modal-point__body {
    display: flex;
    padding: 1.5rem 0rem 1.5rem 1.5rem;
}

.gis-modal-sharer__icon, .gis-modal-billboard__icon, .gis-modal-point__icon {
    margin-right: 14px;
}

.gis-modal-sharer-meta, .gis-modal-billboard-meta, .gis-modal-point-meta {
    display: flex;
    flex-direction: column;
    margin-bottom: 10px;
    color: var(--foreground-text);
}

@media (min-width: 480px) {
    .gis-modal-sharer-meta, .gis-modal-billboard-meta, .gis-modal-point-meta {
        flex-direction: row;
    }
}

.gis-modal-sharer-meta > div:first-child, .gis-modal-billboard-meta > div:first-child, .gis-modal-point-meta > div:first-child {
    margin-right: 26px;
}

.gis-modal-sharer__desc {
    display: flex;
    flex-direction: column;
    padding: 1rem 0 0 0;
    border-top: 1px solid var(--border);
}

.gis-modal-sharer__desc__text {
    order: 0;
    width: 300px;
    word-wrap: normal;
}

.gis-modal-billboard__desc__text, .gis-modal-point__desc__text {
    order: 0;
    display: block;
    width: 100%;
    word-wrap: normal;
}

.gis-modal-billboard__button {
    order: 1;
    display: block;
    width: 50%;
    text-align: center;
    background-color: var(--theme-color);
    color: white;
    padding-bottom: 0.5rem;
    padding-top: 0.5rem;
    margin: auto;
    cursor: pointer;
    /* reset native <button> chrome so it matches the former <a> styling */
    border: none;
    font: inherit;
    -webkit-appearance: none;
    appearance: none;
}

.gis-modal-billboard__button:hover {
    color: var(--theme-color);
    background-color: var(--surface);
    border: solid 1px var(--theme-color);
}

.gis-modal-sharer__desc__image, .gis-modal-billboard__desc__image, .gis-modal-point__desc__image {
    order: 1;
    margin-top: 10px;
}

@media (min-width: 768px) {
    .gis-modal-sharer__desc, .gis-modal-billboard__desc, .gis-modal-point__desc {
        display: flex;
        flex-direction: row;
    }
}

.gis-modal-sharer__desc > div:last-child, .gis-modal-billboard__desc > div:last-child, .gis-modal-point__desc > div:last-child {
    flex: 1 0 32%;
}

.gis-modal-sharer__desc {
    margin-left: 10px;
    margin-top: 40px;
    max-width: 100%;
}

.gis-modal-billboard__desc, .gis-modal-point__desc {
    margin-left: 10px;
    max-width: 100%;
    display: flex;
    flex-direction: row;
    overflow: auto;
    max-height: 70vh;
    --scrollbarBG: var(--scrollbarBG);
    --thumbBG: var(--theme-color);
    --scrollbar-width: thin;
    --scrollbar-color: var(--thumbBG) var(--scrollbarBG);
}

.gis-modal-billboard__desc::-webkit-scrollbar {
    width: 6px;
}

.gis-modal-billboard__desc::-webkit-scrollbar-track {
    background: var(--scrollbarBG);
}

.gis-modal-billboard__desc::-webkit-scrollbar-thumb {
    background-color: var(--thumbBG);
    border-radius: 3px;
    border: 3px solid var(--scrollbarBG);
}

.gis-modal-sharer__title, .gis-modal-billboard__title, .gis-modal-point__title {
    display: block;
    margin-bottom: 1rem;
    font-style: normal;
    color: var(--foreground-text);

}

.gis-modal-sharer__desc p {
    margin-bottom: 24px;
    color: var(--foreground-text);
    white-space: pre-wrap;
}


.gis-modal-billboard__desc p, .gis-modal-point__desc p {
    margin-bottom: 24px;
    color: var(--foreground-text);
    white-space: pre-wrap;
    margin-right: 1.5rem;
}

.gis-modal-sharer__link,
.gis-modal-sharer__link:visited,
.gis-modal-sharer__link:active,
.gis-modal-sharer__link:hover {
    display: inline-block;
    color: var(--theme-color);
}

@media (min-width: 768px) {
    .gis-modal-sharer__link, .gis-modal-billboard__link, .gis-modal-point__link {
        margin-bottom: 0;
    }
}

@media screen and (min-width: 601px) and (min-height: 601px) {
    .gis-layer {
        position: absolute;
        cursor: pointer;
        top: 0;
        opacity: 1;
        font-size: 1.125rem;
        font-weight: 400;
    }

    .gis-modal {
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        opacity: 1;
        display: none;
        font-size: 1.125rem;
        font-weight: 400;
    }

    .gis-modal-picture__carret-right, .gis-modal-picture__carret-left {
        margin-top: 30vh;
        font-size: 6rem;
        width: 4rem;
        height: 4rem;
        line-height: 3rem;
    }
}

@media screen and (min-width: 601px) and (max-height: 600px) {
    .gis-layer {
        position: absolute;
        cursor: pointer;
        top: 0;
        opacity: 1;
        font-size: 1.125rem;
        font-weight: 400;
    }

    .gis-modal {
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        opacity: 1;
        display: none;
        font-size: 1rem;
        font-weight: 400;
    }

    .gis-modal-picture__carret-right, .gis-modal-picture__carret-left {
        margin-top: 15vh;
        font-size: 3rem;
        width: 2rem;
        height: 2rem;
        line-height: 1.5rem;
    }
}

@media screen and (min-width: 401px) and (max-width: 600px) {
    .gis-layer {
        position: absolute;
        cursor: pointer;
        top: 0;
        opacity: 1;
        font-size: 1rem;
        font-weight: 400;
    }

    .gis-modal {
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        opacity: 1;
        display: none;
        font-size: 1rem;
        font-weight: 400;
    }

    .gis-modal-picture__carret-right, .gis-modal-picture__carret-left {
        margin-top: 15vh;
        font-size: 3rem;
        width: 2rem;
        height: 2rem;
        line-height: 1.5rem;
    }
}

@media screen and (max-width: 400px) {
    .gis-layer {
        position: absolute;
        cursor: pointer;
        top: 0;
        opacity: 1;
        font-size: 0.875rem;
        font-weight: 400;
    }

    .gis-modal {
        position: absolute;
        top: 0;
        left: 0 !important;
        right: 0;
        bottom: 0;
        opacity: 1;
        display: none;
        font-size: 0.875rem;
        font-weight: 400;
    }

    .gis-modal-picture__carret-right, .gis-modal-picture__carret-left {
        margin-top: 15vh;
        font-size: 3rem;
        width: 2rem;
        height: 2rem;
        line-height: 1.5rem;
    }
}

#toast {
    visibility: hidden;
    min-width: 250px;
    margin-left: -125px;
    background-color: var(--theme-color);
    color: #fff;
    text-align: center;
    border-radius: 2px;
    padding: 16px;
    position: fixed !important;
    z-index: 10000 !important;
    left: 50% !important;
    top: unset !important;
    bottom: 30px !important;
}

#toast.show {
    visibility: visible;
    -webkit-animation: fadein 0.5s, fadeout 0.5s 2.5s;
    animation: fadein 0.5s, fadeout 0.5s 2.5s;
}

/* Animations to fade the snackbar in and out */
@-webkit-keyframes fadein {
    from {
        bottom: 0;
        opacity: 0;
    }
    to {
        bottom: 30px;
        opacity: 1;
    }
}

@keyframes fadein {
    from {
        bottom: 0;
        opacity: 0;
    }
    to {
        bottom: 30px;
        opacity: 1;
    }
}

@-webkit-keyframes fadeout {
    from {
        bottom: 30px;
        opacity: 1;
    }
    to {
        bottom: 0;
        opacity: 0;
    }
}

@keyframes fadeout {
    from {
        bottom: 30px;
        opacity: 1;
    }
    to {
        bottom: 0;
        opacity: 0;
    }
}

/* ===== #17 Spotlight fulltext palette (layers + points) =============== */
/* Body-level overlay, NO backdrop dimming — the map stays visible. */
.gis-spotlight {
    position: fixed;
    inset: 0;
    z-index: 60;
    display: none;
    justify-content: center;
    align-items: flex-start;
    pointer-events: none;
}

.gis-spotlight.gis-spotlight--visible {
    display: flex;
}

.gis-spotlight__box {
    pointer-events: auto;
    margin-top: 12vh;
    width: min(560px, 92vw);
    max-height: 72vh;
    display: flex;
    flex-direction: column;
    background: var(--surface);
    border-radius: 14px;
    box-shadow: 0 18px 50px rgba(0, 0, 0, .30), 0 3px 10px rgba(0, 0, 0, .14);
    overflow: hidden;
    animation: gis-spotlight-in .12s ease-out;
}

@keyframes gis-spotlight-in {
    from { opacity: 0; transform: translateY(-8px) scale(.985); }
    to   { opacity: 1; transform: none; }
}

.gis-spotlight__inputrow {
    display: flex;
    align-items: center;
    gap: 11px;
    padding: 14px 18px;
    border-bottom: 1px solid #ececec;
}

.gis-spotlight__search-icon {
    flex: 0 0 20px;
    width: 20px;
    height: 20px;
    background: #9aa3ad;
    -webkit-mask: no-repeat center / contain url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='11' cy='11' r='8'/%3E%3Cpath d='m21 21-4.3-4.3'/%3E%3C/svg%3E");
    mask: no-repeat center / contain url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='11' cy='11' r='8'/%3E%3Cpath d='m21 21-4.3-4.3'/%3E%3C/svg%3E");
}

.gis-spotlight__input {
    flex: 1;
    min-width: 0;
    border: 0;
    outline: 0;
    background: transparent;
    font: inherit;
    font-size: 20px;
    line-height: 1.25;
    color: #222;
}

.gis-spotlight__results {
    list-style: none;
    margin: 0;
    padding: 6px;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
}

.gis-spotlight__row {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 9px 12px;
    border-radius: 9px;
    cursor: pointer;
}

.gis-spotlight__row--active {
    background: #eaf1fb;
}

.gis-spotlight__icon {
    flex: 0 0 26px;
    width: 26px;
    height: 26px;
    object-fit: contain;
}

.gis-spotlight__text {
    min-width: 0;
    flex: 1;
    display: flex;
    flex-direction: column;
    line-height: 1.3;
}

.gis-spotlight__headline {
    font-size: 15px;
    color: #1a1a1a;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.gis-spotlight__sub {
    font-size: 12.5px;
    color: #7a7a7a;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.gis-spotlight__badge {
    display: inline-block;
    font-size: 11px;
    color: #5a6470;
    background: #eef0f3;
    border-radius: 4px;
    padding: 0 5px;
    margin-right: 2px;
}

.gis-spotlight__headline mark,
.gis-spotlight__sub mark {
    background: #ffe39e;
    color: inherit;
    border-radius: 2px;
    padding: 0 1px;
}

.gis-spotlight__hint {
    display: flex;
    gap: 14px;
    padding: 8px 16px;
    border-top: 1px solid #f1f1f1;
    font-size: 11px;
    color: #9aa0a6;
}

.gis-spotlight__empty {
    list-style: none;
    padding: 20px;
    text-align: center;
    color: #9aa0a6;
    font-size: 14px;
}

/* ===== #20 dark / high-contrast per-component overrides ============== */
/* The Spotlight palette uses one-off light-mode colors that don't derive
   from the theme variables, so they must be themed explicitly per mode. */
html.dark .gis-spotlight__inputrow,
html.colorblind .gis-spotlight__inputrow { border-bottom-color: var(--border); }

html.dark .gis-spotlight__input,
html.colorblind .gis-spotlight__input,
html.dark .gis-spotlight__headline,
html.colorblind .gis-spotlight__headline { color: var(--foreground-text); }

html.dark .gis-spotlight__sub,
html.colorblind .gis-spotlight__sub,
html.dark .gis-spotlight__hint,
html.colorblind .gis-spotlight__hint,
html.dark .gis-spotlight__empty,
html.colorblind .gis-spotlight__empty { color: var(--muted); }

html.dark .gis-spotlight__hint,
html.colorblind .gis-spotlight__hint { border-top-color: var(--border); }

html.dark .gis-spotlight__search-icon { background: var(--muted); }
html.colorblind .gis-spotlight__search-icon { background: #000; }

html.dark .gis-spotlight__badge { color: #cfd6e0; background: rgba(255, 255, 255, 0.10); }
html.colorblind .gis-spotlight__badge { color: #000; background: #fff; border: 1px solid #000; }

html.dark .gis-spotlight__row--active { background: rgba(255, 255, 255, 0.08); }
html.colorblind .gis-spotlight__row--active { background: #000; }
html.colorblind .gis-spotlight__row--active .gis-spotlight__headline,
html.colorblind .gis-spotlight__row--active .gis-spotlight__sub { color: #fff; }
/* On the black active row keep the "vrstva" pill black-on-white and the <mark>
   highlight black-on-yellow, so neither's text turns white and vanishes. */
html.colorblind .gis-spotlight__row--active .gis-spotlight__badge { color: #000; background: #fff; border-color: #000; }
html.colorblind .gis-spotlight__row--active mark { color: #000; }

/* spotlight per-result layer icons (teal SVG <img>) -> black; but the active row
   has a black background, so its icon must invert to white instead. */
html.colorblind .gis-spotlight__icon { filter: brightness(0); }
html.colorblind .gis-spotlight__row--active .gis-spotlight__icon { filter: brightness(0) invert(1); }

/* #20 theme toggle button — per-mode icon (light=sun, dark=moon, high-contrast=contrast).
   White-stroke Lucide on the theme-colored side-toolbar bar; data-mode set by ui.js. */
#gis-toggle-theme {
    background: transparent url('/assets/icons/theme-light.svg') 0 0 no-repeat padding-box;
}
#gis-toggle-theme[data-mode="dark"] { background-image: url('/assets/icons/theme-dark.svg'); }
#gis-toggle-theme[data-mode="colorblind"] { background-image: url('/assets/icons/theme-hc.svg'); }

/* #20: the layer-list marks + icons are teal SVG *images* (tick.svg / dash.svg /
   chevron.svg / per-layer /assets/icons/svg/*.svg) — fill can't reach them, so
   recolor to solid black in high-contrast via filter. */
html.colorblind .gis-dropdown__checkbox { border-color: #000; }
html.colorblind .gis-dropdown__checkbox input[type="checkbox"]:checked + span,
html.colorblind .gis-dropdown__checkbox input[type="checkbox"]:indeterminate + span,
html.colorblind .gis-dropdown__external span,
html.colorblind .gis-dropdown__expandable-indicator img,
html.colorblind .gis-dropdown__title-img img,
html.colorblind .gis-modal__icon img,
html.colorblind .gis-modal-point__icon img,
html.colorblind .gis-modal-billboard__icon img,
html.colorblind .gis-modal-sharer__icon img,
html.colorblind .gis-modal-picture__icon img {
    filter: brightness(0);
}

