.fund-map-layout {
    display: flex;
    height: 62vh;
    width: 100%;
}

#fund-map {
    flex: 1;
    border-radius: 1.5rem;
    border: 1px solid #e8e8e8;
}

.fund-sidebar {
    width: 360px;
    border-left: 1px solid #e5e5e5;
    background: #fff;
    overflow-y: auto;
}

.fund-sidebar-empty {
    padding: 30px;
    color: #777;
}

.fund-card {
    padding: 24px;
}

.fund-card__title {
    font-size: 22px;
    font-weight: 700;
    margin-bottom: 12px;
}

.fund-card__row {
    margin-bottom: 10px;
    line-height: 1.5;
}

.fund-card__label {
    font-weight: 700;
}

.fund-card__link {
    display: inline-block;
    margin-top: 20px;
    background: #2563eb;
    color: #fff;
    padding: 10px 16px;
    border-radius: 8px;
    text-decoration: none;
}

.fund-marker-wrapper {
    cursor: pointer;
}

.fund-marker {
    position: relative;
    width: var(--marker-size, 12px);
    height: var(--marker-size, 12px);
    border-radius: 50%;
    background: var(--primary-darker, #1874c1);
    border: 2px solid #fff;
    box-shadow: 0 2px 8px rgba(0,0,0,.25);

    transition:
        background-color .2s ease,
        box-shadow .2s ease;
}

.fund-marker-wrapper .fund-marker:hover {
    transform: scale(1.4);
}

.fund-marker--new {
    background: #10b981;
}

.fund-marker--new::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: rgba(16,185,129,.25);
    transform: translate(-50%, -50%);
    animation: marker-ping 1.5s infinite;
    pointer-events: none;
}

@keyframes marker-ping {
    0% {
        transform: translate(-50%, -50%) scale(.5);
        opacity: 1;
    }

    100% {
        transform: translate(-50%, -50%) scale(1.8);
        opacity: 0;
    }
}

.maplibregl-marker {
    cursor: pointer;
}

.map-legend {
    position: absolute;
    bottom: 38px;
    left: 16px;
    z-index: 10;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.map-legend__card {
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(8px);
    border-radius: 12px;
    padding: 12px 16px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
}

.map-legend__content {
    display: flex;
    align-items: center;
    gap: 16px;
    font-size: 12px;
}

.map-legend__count, .map-legend__count span {
    color: #737373;
    font-weight: 600;
    font-size: .75rem;
}

.map-legend__divider {
    width: 1px;
    height: 16px;
    background: #e5e5e5;
}

.map-legend__item {
    display: flex;
    align-items: center;
    gap: 6px;
}

.map-legend__label {
    color: #737373;
    font-size: .75rem;
}

.map-legend__new-marker {
    position: relative;
    width: 10px;
    height: 10px;
}

.map-legend__new-marker .fund-marker {
    position: absolute;
    inset: 0;
}

.map-legend__new-marker .fund-marker--new {
    position: absolute;
    inset: 0;
}

.pill {
    display: inline-block;
    padding: 4px 8px;
    margin-right: 8px;
    margin-bottom: 5px;
    font-size: 12px;
    border-radius: 100px;
    text-align: center;
}

.pill--gray-blank {
    border: none;
    background: var(--secondary-lighter, #f5f5f5);
    padding: 6px 16px;
    font-weight: 600;
    line-height: 1.2;
    color: var(--secondary-darkest, #000);
}

.map-sidebar {
    height: 100%;
    width: 360px;
    overflow-y: auto;
    margin-left: 10px;

    background: #fff;
    border: 1px solid #e8e8e8;
    border-radius: 1rem;

    box-shadow: 0 8px 24px rgba(24,116,193,.06);
}

.map-sidebar__header {
    padding: 12px 16px 16px;
}

.map-sidebar__section {
    padding: 16px;
}

.map-sidebar__divider {
    height: 1px;
    background: #e5e5e5;
}

.map-sidebar__section-title {
    margin-bottom: 8px;

    color: #a3a3a3;
    font-size: 10px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .08em;
}

.map-sidebar__type {
    margin-bottom: 12px;

    color: #404040;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
}

.map-sidebar__logo {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    object-fit: contain;
}

.map-sidebar__name {
    font-size: 16px;
    font-weight: 700;
}

.map-sidebar__location {
    margin-top: 2px;

    color: #737373;
    font-size: 11px;
}

.map-sidebar__row {
    display: flex;
    gap: 8px;

    margin-bottom: 8px;
}

.map-sidebar__label {
    width: 80px;
    flex-shrink: 0;

    color: #737373;
    font-size: 13px;
}

.map-sidebar__value {
    flex: 1;

    color: #171717;
    font-size: 13px;
    font-weight: 500;
}

.map-sidebar__tags {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
}

.map-sidebar__tag {
    display: inline-flex;

    padding: 2px 6px;

    background: #f5f5f5;
    border-radius: 4px;

    color: #404040;
    font-size: 11px;
    font-weight: 600;
}

.map-sidebar__investor {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    color: inherit;
}

.map-sidebar__investor:hover .map-sidebar__name {
    text-decoration: underline;
}

.map-sidebar__logo {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    object-fit: contain;
    background: #fff;
    flex-shrink: 0;
    box-shadow: 0 1px 3px rgba(0,0,0,.08);
}

.map-sidebar__logo-placeholder {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    font-weight: 700;
    background: #fff;
    color: #3b82f6;
    flex-shrink: 0;
    box-shadow: 0 1px 3px rgba(0,0,0,.08);
}

.map-sidebar__investor-info {
    min-width: 0;
}

.map-sidebar__name {
    font-size: 16px;
    font-weight: 700;
    color: #171717;
    line-height: 1.2;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.map-sidebar__location {
    margin-top: 2px;
    font-size: 11px;
    color: #737373;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

#toggle-dot-size:checked ~ .custom-control-label::before {
    border-color: rgb(24, 116, 193);
    background-color: rgb(24, 116, 193);
}

.map-sidebar__empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    padding: 32px;
    text-align: center;
}

.map-sidebar__empty-icon {
    width: 64px;
    height: 64px;
    border-radius: 16px;
    background: #f5f5f5;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 16px;
}

.map-sidebar__empty-icon svg {
    width: 32px;
    height: 32px;
    color: #d4d4d4;
}

.map-sidebar__empty-title {
    margin: 0 0 4px;
    font-size: 14px;
    font-weight: 600;
    color: #171717;
}

.map-sidebar__empty-text {
    margin: 0;
    font-size: 12px;
    color: #a3a3a3;
    line-height: 1.4;
}

.fund-popup {
    min-width: 220px;
    padding: 12px;
}

.fund-popup__header {
    display: flex;
    align-items: center;
    gap: 10px;
}

.fund-popup__logo {
    width: 36px;
    height: 36px;
    border-radius: 8px;
    object-fit: contain;
    background: #fff;
}

.fund-popup__logo-placeholder {
    width: 36px;
    height: 36px;
    border-radius: 8px;
    background: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    box-shadow: 0 1px 3px rgba(0,0,0,.08);
}

.fund-popup__name {
    font-size: 14px;
    font-weight: 700;
    color: #171717;
}

.fund-popup__type, .fund-popup__size {
    font-size: 12px;
    color: #737373;
    margin-top: 2px;
}

.maplibregl-popup-content {
    border-radius: 12px;
    padding: 0 !important;
    box-shadow: 0 8px 24px rgba(24,116,193,.12);
}

.maplibregl-popup-close-button {
    display: none;
}

.maplibregl-popup-tip {
    border-top-color: white !important;
}

.mid-dot {
    color: #737373;
    margin-top: 2px;
}

.map-search-subtitle {
    font-size: 11px;
    font-weight: 600;
    color: #a3a3a3;
}

.investors__top-search {
    max-width: none; !important;
}

@media (max-width: 992px) {
    .map-search-subtitle {
        text-align: center;
        margin-top: 5px;
    }

    .custom-switch {
        margin-left: 17px;
    }
}
