.locations-popup {
    display: flex;
    flex-direction: column;
}

.locations-popup #globe-container {
    flex: 1 1 auto;
    min-height: 0;
    height: auto !important;
}

.locations-title-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    column-gap: 0.75rem;
    row-gap: 0.4rem;
    margin-bottom: 0.75rem;
    padding-right: 2.25rem;
}

.locations-switch {
    display: inline-flex;
    gap: 0.4rem;
}

.locations-chip {
    background-color: #ffffff;
    border: 1px solid #d1d5db;
    border-radius: 9999px;
    color: #1f2937;
    cursor: pointer;
    font-size: 0.875rem;
    font-weight: 600;
    line-height: 1.25;
    padding: 0.4rem 0.85rem;
    white-space: nowrap;
}

.locations-chip:hover {
    border-color: #3b82f6;
    color: #1d4ed8;
}

.locations-chip:focus-visible {
    outline: 2px solid #93c5fd;
    outline-offset: 2px;
}

.locations-chip[aria-pressed="true"] {
    background-color: #3b82f6;
    border-color: #3b82f6;
    color: #ffffff;
}

.locations-chip:disabled,
.locations-chip:disabled:hover {
    background-color: #f3f4f6;
    border-color: #e5e7eb;
    color: #9ca3af;
    cursor: not-allowed;
}

.locations-chip-count {
    font-weight: 500;
    margin-left: 0.35rem;
    opacity: 0.7;
}

.locations-note {
    color: #374151;
    font-size: 0.9rem;
    line-height: 1.4;
    margin-bottom: 0.6rem;
}

.locations-note[hidden] {
    display: none;
}

.locations-search-note {
    margin-bottom: 0;
}

.locations-map {
    display: flex;
    flex: 1 1 auto;
    flex-direction: column;
    gap: 0.5rem;
    min-height: 0;
}

.locations-map[hidden] {
    display: none;
}

.locations-map-cities {
    display: flex;
    flex: none;
    flex-wrap: nowrap;
    gap: 0.5rem;
    overflow-x: auto;
    padding-bottom: 0.1rem;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
}

.locations-map-cities:empty {
    display: none;
}

.locations-map-cities::-webkit-scrollbar {
    display: none;
}

.locations-map-tools {
    display: flex;
    flex: none;
    flex-wrap: nowrap;
    align-items: center;
    gap: 0.5rem;
}

.locations-map-tools .locations-chip {
    flex: none;
}

.locations-map-tools[hidden] {
    display: none;
}

.locations-map-search-row {
    display: flex;
    flex: 1 1 15rem;
    min-width: 0;
    align-items: center;
    gap: 0.5rem;
}

.locations-map-search-row[hidden] {
    display: none;
}

.locations-map-search-box {
    position: relative;
    flex: 1 1 auto;
    min-width: 0;
}

.locations-map-search {
    display: block;
    width: 100%;
    border: 1px solid #000000;
    border-radius: 0.25rem;
    color: #374151;
    font-size: 16px;
    padding: 0.45rem 0.75rem;
}

.locations-map-search::placeholder {
    font-size: 14px;
}

.locations-map-search:focus {
    outline: none;
    box-shadow: 0 0 0 1px #000000;
}

.locations-map-suggestions {
    position: absolute;
    top: calc(100% + 2px);
    left: 0;
    right: 0;
    z-index: 20;
    max-height: 16rem;
    margin: 0;
    padding: 0;
    overflow-y: auto;
    list-style: none;
    text-align: left;
    background-color: #ffffff;
    border-radius: 0.25rem;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
    -webkit-overflow-scrolling: touch;
}

.locations-map-suggestions[hidden] {
    display: none;
}

.locations-map-suggestion {
    display: flex;
    align-items: center;
    gap: 0.55rem;
    padding: 0.6rem 0.75rem;
    border-top: 1px solid #e6e6e6;
    color: #6b7280;
    cursor: pointer;
    font-size: 13px;
    line-height: 1.3;
}

.locations-map-suggestion:first-child {
    border-top: none;
}

.locations-map-suggestion:hover {
    background-color: #f5f7fa;
}

.locations-map-suggestion[aria-selected="true"] {
    background-color: #ebf2fe;
}

.locations-map-suggestion-icon {
    flex: none;
    width: 12px;
    height: 16px;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 16'%3E%3Cpath fill='%239ca3af' d='M6 0C2.7 0 0 2.6 0 5.9 0 10.3 6 16 6 16s6-5.7 6-10.1C12 2.6 9.3 0 6 0zm0 8.2a2.3 2.3 0 1 1 0-4.6 2.3 2.3 0 0 1 0 4.6z'/%3E%3C/svg%3E") no-repeat center / contain;
}

.locations-map-suggestion-text {
    flex: 1 1 auto;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.locations-map-suggestion-main {
    color: #111827;
    font-size: 14px;
    margin-right: 0.35rem;
}

.locations-map-suggestion-main b {
    font-weight: 700;
}

.locations-chip[hidden] {
    display: none;
}

.locations-map-density {
    position: absolute;
    pointer-events: none;
    opacity: 0.85;
}

.locations-map-notes {
    flex: none;
    color: #374151;
    font-size: 0.875rem;
    line-height: 1.4;
}

.locations-map-notes:empty {
    display: none;
}

.locations-map-notes p + p {
    margin-top: 0.25rem;
}

.locations-map-frame {
    position: relative;
    z-index: 0;
    flex: 1 1 auto;
    min-height: 240px;
    overflow: hidden;
    background-color: #e5e7eb;
    border: 1px solid #e5e7eb;
    border-radius: 0.5rem;
}

.locations-map-canvas {
    position: absolute;
    inset: 0;
}

.locations-map-info {
    max-width: 260px;
    max-height: 260px;
    overflow-y: auto;
    color: #1f2937;
    font-size: 14px;
    line-height: 1.35;
    text-align: left;
}

.locations-map-info-heading {
    font-weight: 700;
    margin-bottom: 0.4rem;
}

.locations-map-info-item + .locations-map-info-item {
    border-top: 1px solid #e5e7eb;
    margin-top: 0.5rem;
    padding-top: 0.5rem;
}

.locations-map-info-name {
    font-size: 15px;
    font-weight: 700;
}

.locations-map-info-address {
    color: #4b5563;
    margin-top: 0.15rem;
}

.locations-map-info-links {
    display: flex;
    gap: 0.9rem;
    margin-top: 0.35rem;
}

.locations-map-info-links a {
    color: #3b82f6;
    font-weight: 600;
    text-decoration: none;
}

.locations-map-info-links a:hover {
    color: #1d4ed8;
}
