
/* Main map */

#map {
    width: 100%;
    height: 68vh;
    min-height: 480px;
    background: #f1f5f9;
    z-index: 1;
}

/* Map polygons */

.leaflet-interactive {
    cursor: pointer;
}

/* Teardrop parcel/count markers */

.count-pin {
    width: 36px;
    height: 36px;

    background: #059669;
    border: 3px solid white;

    border-radius: 50% 50% 50% 0;

    transform: rotate(-45deg);

    display: flex;
    align-items: center;
    justify-content: center;

    box-shadow: 0 3px 10px rgba(0,0,0,0.25);
}

.count-pin span {
    transform: rotate(45deg);

    color: white;
    font-size: 12px;
    font-weight: 800;
}

/* Special parcel marker */

.parcel-pin {
    width: 42px;
    height: 42px;

    background: #047857;
    border: 3px solid white;

    border-radius: 50% 50% 50% 0;

    transform: rotate(-45deg);

    display: flex;
    align-items: center;
    justify-content: center;

    box-shadow: 0 4px 14px rgba(0,0,0,0.3);
}

.parcel-pin span {
    transform: rotate(45deg);

    color: white;
    font-size: 10px;
    font-weight: 800;
}

/* Panorama viewer */
#panoramaPanel {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    z-index: 30;
}

#panoramaViewer {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;   
}
#panoramaViewer .pnlm-container {
    width: 100% !important;
    height: 100% !important;
}
/* Mobile adjustments */

@media (max-width: 640px) {

    #map {
        height: 65vh;
        min-height: 420px;
    }

}

/* =========================================
   ENEO360 MAP - FULL BLEED STAGE
========================================= */

/* Map screen becomes the positioning parent */
[data-screen-panel="map"] {
    position: absolute;
    inset: 0;
    overflow: hidden;
    background: #e8e8e8;
}

/* The map fills the complete screen */
[data-screen-panel="map"] #map {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    min-height: 0;
    z-index: 1;
}

/* Floating top controls */
.map-floating-controls {
    position: absolute;
    top: 14px;
    left: 14px;
    right: 14px;
    z-index: 1000;

    display: flex;
    align-items: center;
    justify-content: space-between;

    pointer-events: none;
}

/* Back button */
.map-back-button {
    width: 42px;
    height: 42px;

    display: flex;
    align-items: center;
    justify-content: center;

    border: 0;
    border-radius: 50%;

    background: rgba(35, 35, 35, 0.72);
    color: #ffffff;

    font-size: 25px;
    font-weight: 500;

    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);

    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.12);

    cursor: pointer;

    pointer-events: auto;
    transition: background 0.2s ease, transform 0.2s ease;
}

.map-back-button:hover {
    background: rgba(20, 20, 20, 0.9);
}

.map-back-button:active {
    transform: scale(0.94);
}

.map-back-button[hidden] {
    display: none !important;
}

/* Kenya pill */
.map-floating-controls .country-pill {
    margin-left: auto;

    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;

    padding: 10px 14px;

    border-radius: 999px;

    background: rgba(35, 35, 35, 0.72);
    color: #ffffff;

    font-size: 12px;
    font-weight: 700;

    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);

    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.12);

    pointer-events: auto;
}

.country-pill-icon {
    font-size: 11px;
    opacity: 0.85;
}

/* =========================================
   MAP LOCATION INFORMATION
========================================= */

.map-location-overlay {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;

    z-index: 900;

    padding:
        65px 18px
        22px;

    color: #ffffff;

    background: linear-gradient(
        to bottom,
        transparent 0%,
        rgba(0, 0, 0, 0.08) 15%,
        rgba(0, 0, 0, 0.55) 70%,
        rgba(0, 0, 0, 0.75) 100%
    );

    pointer-events: none;
}

.map-location-content {
    max-width: 100%;
}

.map-location-overlay h2 {
    margin: 0 0 6px;

    font-size: 17px;
    font-weight: 800;
    line-height: 1.35;

    text-shadow: 0 2px 6px rgba(0, 0, 0, 0.65);
}

.map-location-overlay p {
    margin: 0;

    font-size: 11px;
    line-height: 1.6;

    color: rgba(255, 255, 255, 0.88);

    text-shadow: 0 1px 4px rgba(0, 0, 0, 0.7);
}

/* Keep Leaflet controls beneath our floating overlays */
[data-screen-panel="map"] .leaflet-top {
    top: 65px;
}

[data-screen-panel="map"] .leaflet-left {
    left: 10px;
}

[data-screen-panel="map"] .leaflet-control-zoom {
    border: 0 !important;
    border-radius: 9px !important;
    overflow: hidden;

    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.16);
}

/* Mobile adjustments */
@media (max-width: 767px) {

    .map-floating-controls {
        top: 12px;
        left: 12px;
        right: 12px;
    }

    .map-back-button {
        width: 40px;
        height: 40px;
    }

    .map-floating-controls .country-pill {
        padding: 9px 12px;
        font-size: 11px;
    }

    .map-location-overlay {
        padding: 60px 15px 18px;
    }

    .map-location-overlay h2 {
        font-size: 16px;
    }

    .map-location-overlay p {
        font-size: 10px;
    }

    [data-screen-panel="map"] .leaflet-top {
        top: 62px;
    }

}
