.leaflet-popup-content {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

@media screen and (max-width: 600px) {
    .leaflet-popup-content {
        white-space: normal;
    }
}

/* used for the chart */
.chart-popup {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background-color: white;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    border-radius: 8px;
    width: 80vw;
    z-index: 2000;
}

.chart-header {
    background-color: #007bff;
    color: white;
    padding: 10px 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top-left-radius: 8px;
    border-top-right-radius: 8px;
}

.chart-close {
    background: none;
    border: none;
    color: white;
    font-size: 20px;
    cursor: pointer;
}

.chart-body {
    width: 100%;
    max-height: 60vh; 
    overflow: auto;
    padding-bottom: 40px;  /* avoid overlap between x-ticks and slider */
}

/* chart body */
.chart-body canvas {
    display: block;
    width: 100%;
    height: auto;
}

/* chart slider */
.chart-slider-container {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    margin-top: 10px;
}

.overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1999;
}

#chartContainer {
    position: relative;
    width: 80%;
    margin: auto;
}


/* slider */
.range-slider-container {
    width: 100%;
    text-align: center;
    margin-top: 5px auto;
    padding: 0;
}

.range-slider-container #range-slider {
    width: 80%;
    margin: auto;
}

#range-slider {
    margin-top: 15px;
    width: 80%;
    
    height: 30px;
}

#range-slider .noUi-connect {
    background-color: rgba(30, 30, 30, 0.5);
}


.noUi-handle {
    background: #007bff !important;
    border: 1px solid white;
    width: 1px;
    height: 20px;
    border-radius: 0;
    box-shadow: 0 0 px rgba(0, 0, 0, 0.2);
    cursor: pointer;
}

.noUi-connect {
    background: #d3d3d3;
}

.noUi-base {
    background: #f0f0f0;
}

.noUi-tooltip {
    
    font-size: 12px;
    background: #007bff;
    color: white;
    padding: 2px 5px;
    border-radius: 0px;
}


#slider-values {
    text-align: center;
    font-weight: bold;
    margin-top: 10px;
}

/* used to add the frame to be shown when the block is clicked */
path.leaflet-interactive:focus {
    outline: none !important;
    stroke: none !important; 
    filter: none !important;
}

/* adjust chart size when when windows becomes smaller */
@media (max-width: 768px) {
    .chart-popup {
        width: 80vw; /* make it 80% wide */
        max-width: 600px;
    }
}

/* for groundwater bubble */
/* Bubble marker with centered number */
.owrb-bubble {
  /* Let inline style control width/height/background */
}
.owrb-bubble .bubble {
  display:flex; align-items:center; justify-content:center;
  border-radius:50%;
  border:2px solid #2e7d32;  /* outline */
  font-weight:700; line-height:1;
  user-select:none;
}