/* ═══════════════════════════════════════════════════════════
   LEAFLET MAP — Archive + Single Project
   ═══════════════════════════════════════════════════════════ */

/* Archive map */
.lic-archive-map {
    width: 100%;
    height: 420px;
    border-radius: 12px;
    margin-bottom: 32px;
    overflow: hidden;
    z-index: 1;
    border: 1px solid var(--lic-border, #d4dee8);
}

/* Single project map */
.lic-map-single {
    width: 100%;
    height: 280px;
    border-radius: 12px;
    margin-top: 0;
    overflow: hidden;
    border: 1px solid var(--lic-border, #d4dee8);
}

/* Custom marker icon */
.lic-map-marker {
    background: none !important;
    border: none !important;
}
.lic-map-marker svg {
    filter: drop-shadow(0 2px 4px rgba(0,0,0,.25));
    cursor: pointer;
}

/* Cluster markers */
.lic-cluster-marker {
    background: none !important;
    border: none !important;
}
.lic-cluster-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--lic-deep, #0c1e3c);
    color: #fff;
    font-family: var(--lic-sans, 'Outfit', system-ui, sans-serif);
    font-size: 14px;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 8px rgba(12,30,60,.3);
    border: 3px solid var(--lic-sand, #c9a96e);
    cursor: pointer;
    transition: transform .15s;
}
.lic-cluster-icon:hover {
    transform: scale(1.1);
}

/* Popup wrapper — override Leaflet defaults */
.lic-map-popup-wrap .leaflet-popup-content-wrapper {
    border-radius: 10px;
    padding: 0;
    box-shadow: 0 4px 16px rgba(12,30,60,.12);
    overflow: hidden;
}
.lic-map-popup-wrap .leaflet-popup-content {
    margin: 0;
    min-width: 220px;
}
.lic-map-popup-wrap .leaflet-popup-tip {
    box-shadow: 0 2px 8px rgba(12,30,60,.08);
}

/* Popup card layout */
.lic-map-popup {
    display: flex;
    gap: 12px;
    padding: 12px;
    cursor: pointer;
    max-width: 320px;
}
.lic-map-popup__thumb {
    width: 80px;
    height: 64px;
    object-fit: cover;
    border-radius: 6px;
    flex-shrink: 0;
}
.lic-map-popup__body {
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-width: 0;
}
.lic-map-popup__title {
    font-family: var(--lic-sans, 'Outfit', system-ui, sans-serif);
    font-weight: 600;
    font-size: 14px;
    color: var(--lic-deep, #0c1e3c);
    margin: 0 0 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.lic-map-popup__price {
    font-size: 13px;
    color: var(--lic-ocean, #2b5c8a);
    font-weight: 500;
    margin: 0 0 2px;
}
.lic-map-popup__location {
    font-size: 12px;
    color: var(--lic-text-muted, #8fa3b8);
    margin: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Responsive */
@media (max-width: 768px) {
    .lic-archive-map { height: 300px; border-radius: 8px; }
    .lic-map-single { height: 220px; }
    .lic-map-popup { gap: 8px; padding: 10px; }
    .lic-map-popup__thumb { width: 64px; height: 52px; }
}

/* ═══════════════════════════════════════════════════════════
   Location map + nearby points sidebar
   (used by single-project, broker-project, pulse)
   ═══════════════════════════════════════════════════════════ */
.lic-location__mapwrap {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
    align-items: stretch;
}
.lic-location__mapwrap--with-points {
    grid-template-columns: minmax(0, 1fr) minmax(240px, 300px);
}
.lic-location__mapwrap .lic-map-single { height: 360px; }
/* When the nearby sidebar grows taller than the map's default height,
   let the map stretch to match so the row looks balanced. */
.lic-location__mapwrap--with-points .lic-map-single {
    height: 100%;
    min-height: 360px;
}

.lic-location__points {
    padding: 18px 20px;
    background: var(--lic-cloud, #eef3f7);
    border: 1px solid var(--lic-border, #d4dee8);
    border-radius: 12px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    align-self: stretch;
}
.lic-location__points-label {
    font-size: 11px;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    color: var(--lic-ocean, #2b5c8a);
    font-weight: 600;
    margin-bottom: 4px;
}
.lic-location__points-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
    overflow-y: auto;
}
.lic-location__point {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    background: #fff;
    border: 1px solid var(--lic-border, #d4dee8);
    border-radius: 10px;
    font-size: 13px;
    line-height: 1.3;
}
.lic-location__point-icon {
    flex-shrink: 0;
    color: var(--lic-sand, #c9a96e);
    stroke: currentColor;
}
.lic-location__point-name {
    flex: 1;
    font-weight: 500;
    color: var(--lic-deep, #0c1e3c);
}
.lic-location__point-distance {
    font-size: 12px;
    color: var(--lic-text-soft, #5a7088);
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
}

/* Pulse variant: dark glass-like background to match the pulse aesthetic */
.lic-location__points--pulse {
    background: rgba(12, 30, 60, 0.78);
    border-color: rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(14px);
    margin-top: 20px;
}
.lic-location__points--pulse .lic-location__points-label {
    color: rgba(255, 255, 255, 0.7);
}
.lic-location__points--pulse .lic-location__point {
    background: rgba(255, 255, 255, 0.06);
    border-color: rgba(255, 255, 255, 0.12);
    color: #fff;
}
.lic-location__points--pulse .lic-location__point-name { color: #fff; }
.lic-location__points--pulse .lic-location__point-distance { color: rgba(255, 255, 255, 0.6); }

@media (max-width: 900px) {
    .lic-location__mapwrap--with-points { grid-template-columns: 1fr; }
    .lic-location__mapwrap .lic-map-single { height: 280px; }
    .lic-location__points-list { max-height: 320px; }
}
