/* Reset default margins and paddings */
body, html {
    margin: 0;
    padding: 0;
    height: 100%;
    font-family: Arial, sans-serif;
  }
  
  /* Date Range Selection */
  #date-range {
    position: absolute;
    top: 10px;
    left: 10px;
    z-index: 1000; /* Ensure it's above the map */
    background: rgba(255, 255, 255, 0.9);
    padding: 10px;
    border-radius: 8px;
    box-shadow: 0 0 5px rgba(0,0,0,0.3);
  }
  
  #date-range label {
    margin-right: 5px;
  }
  
  #date-range input {
    margin-right: 10px;
  }
  
  #update-map {
    margin-top: 5px;
    padding: 5px 10px;
    border: none;
    background-color: #1f77b4;
    color: white;
    border-radius: 4px;
    cursor: pointer;
  }
  
  #update-map:hover {
    background-color: #155d8b;
  }
  
  /* Map Container */
  #map {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
  }
  
  /* Information Panel */
  #info-panel {
    position: absolute;
    top: 0;
    right: 0;
    width: 350px;
    height: 100%;
    background: white;
    overflow-y: auto;
    z-index: 1000;
    box-shadow: 2px 0 5px rgba(0,0,0,0.3);
    transition: transform 0.3s ease;
  }
  
  #info-panel.hidden {
    transform: translateX(100%);
  }
  
  #info-content {
    padding: 20px;
  }
  
  #info-panel h2 {
    margin-top: 0;
  }
  
  #info-panel select {
    width: 100%;
    padding: 5px;
    margin-bottom: 10px;
  }

  /* Close Button Styling */
#info-panel .close-button {
    position: absolute;
    top: 10px;
    right: 15px;
    background: none;
    border: none;
    font-size: 30px;
    cursor: pointer;
  }
  
  #info-panel .close-button:hover {
    color: #999;
  }
  
  
  /* Chart Styling */
  .chart {
    margin-top: 10px;
  }
  
  .chart svg {
    width: 100%;
    height: 250px;
  }
  
  /* Color Scale Legend */
  .legend {
    position: absolute;
    bottom: 30px;
    left: 10px;
    z-index: 1000;
    background: white;
    padding: 10px;
    border-radius: 8px;
    font-size: 12px;
    line-height: 18px;
    color: #555;
    box-shadow: 0 0 5px rgba(0,0,0,0.3);
  }
  
  .legend i {
    width: 18px;
    height: 18px;
    float: left;
    margin-right: 8px;
    opacity: 0.7;
  }
  
  /* Ensure popups are above other elements */
  .leaflet-popup {
    z-index: 10000;
  }
  
  /* Modal Styling */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    z-index: 2000;
    display: flex;
    justify-content: center;
    align-items: center;
  }
  
  .modal .modal-content {
    background-color: white;
    padding: 20px;
    position: relative;
    width: 80%;
    max-width: 800px;
    max-height: 90%;
    overflow-y: auto;
  }
  
  .modal .close-button {
    position: absolute;
    top: 10px;
    right: 15px;
    background: none;
    border: none;
    font-size: 30px;
    cursor: pointer;
  }
  
  .modal .close-button:hover {
    color: #999;
  }
  
  .modal .chart svg {
    width: 100%;
    height: 500px;
  }
  
  /* Hide modal by default */
  .hidden {
    display: none;
  }
  
  .chart-legend {
    display: flex;
    justify-content: center;
    margin-top: 10px;
  }
  
  .chart-legend div {
    display: flex;
    align-items: center;
    margin-right: 15px;
  }
  
  .chart-legend div span {
    width: 12px;
    height: 12px;
    display: inline-block;
    margin-right: 5px;
  }