/* Base styles */
body {
    font-family: Arial, sans-serif;
    margin: 0;
    padding: 0;
    height: 100vh;
    overflow: hidden;
    color: white;
}


#welcome {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background-color: rgba(0, 0, 0, 0.486); /* semi-transparent black */
    padding: 30px 40px;
    border-radius: 12px;
    text-align: center;
    z-index: 9999;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.4);
  }
  
  #welcome h2 {
    color: white;
    margin-bottom: 20px;
  }
  
/* Button styles */
button {
    background-color: #3b2fe3;
    color: white;
    border: none;
    padding: 15px 30px;
    font-size: 18px;
    cursor: pointer;
    border-radius: 5px;
    margin-top: 20px;
    transition: background-color 0.3s ease;
}

button:hover {
    background-color: #2a21c0;
}

/* Map container */
#map-container {
    width: 100%;
    height: 100%;
    position: absolute;
    top: 0;
    left: 0;
    z-index: 1;
    /* display: none; */
}

/* Map itself */
#map {
    height: 100vh;
    width: 100%;
}

/* Toggle dropdown for variable switching */
#toggle-panel {
  position: absolute;
  top: 25px;
  right: 25px;
  z-index: 999;
  background-color: rgba(247, 233, 144, 0.796); 
  /* background-color: rgba(255, 243, 205, 0.95); soft yellow, matches info box */
  padding: 12px 16px;
  border-radius: 10px;
  font-size: 14px;
  box-shadow: 0px 3px 10px rgba(0, 0, 0, 0.2);
  border: 1px solid #f4a300; /* Optional: border to match warm palette */
  transition: background-color 0.3s ease;
}

#toggle-panel label {
  margin-right: 10px;
  font-weight: bold;
  color: #333;
}


#toggle-panel select {
  padding: 6px 10px;
  font-size: 14px;
  border-radius: 6px;
  border: 1px solid #ccc;
  background-color: #fffbe6;         /* soft yellow */
  color: #333;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.15);
  cursor: pointer;
  transition: background-color 0.2s ease, box-shadow 0.2s ease;
}

#toggle-panel select:hover {
  background-color: #fff3c4;         /* a little deeper yellow on hover */
  box-shadow: 0 3px 6px rgba(0, 0, 0, 0.2);
}

#toggle-panel select:focus {
  outline: none;
  border-color: #f4a300;
  background-color: #fff9d6;
  box-shadow: 0 0 0 3px rgba(255, 215, 100, 0.3);
}


@media (max-width: 480px) {
    button {
        padding: 10px 20px;
        font-size: 14px;
    }

    #welcome h2 {
        font-size: 20px;
    }

    #toggle-panel {
        top: 10px;
        right: 10px;
    }
}
/* Spinner styling */
#spinner {
    position: absolute;
    top: 15px;
    left: 15px;
    z-index: 9999;
    background: rgba(255, 255, 255, 0.85);
    padding: 8px 12px;
    border-radius: 6px;
    font-weight: bold;
    color: #333;
    box-shadow: 0 0 5px rgba(0, 0, 0, 0.2);
}

/* Legend box styling */
.info.legend {
    background: rgba(255, 255, 255, 0.85);
    padding: 8px 10px;
    font: 14px/16px Arial, sans-serif;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.15);
    border-radius: 6px;
    line-height: 1.5em;
    color: #333;
    z-index: 999;
}
.info.legend i {
    width: 18px;
    height: 18px;
    float: left;
    margin-right: 8px;
    opacity: 0.8;
}

#info-fixed {
  position: relative;   /* keep the close button positioned inside */
}

#info-fixed #info-close {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 24px;
  height: 24px;
  border: none;
  border-radius: 4px;   /* small rounding (set 0 for sharp square) */
  background: #f53b3b;
  color: #fff;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  line-height: 24px;   /* centers the X vertically */
  text-align: center;  /* centers the X horizontally */
  padding: 0;
}

#info-fixed #info-close:hover {
  background: #f09292;
}

.fade-out {
    animation: fadeOut 0.5s ease forwards;
  }
  
  @keyframes fadeOut {
    to {
      opacity: 0;
      visibility: hidden;
    }
  }
  
/* overlay styles */
#overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(227, 225, 183, 0.23); /* Semi-transparent black */
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.5s ease;
}
.overlay-content {
  background-color: rgba(232, 224, 164, 0.903);
  padding: 20px 20px;
  border-radius: 12px;
  text-align: center;
  color: #333;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.287);
  font-family: 'Segoe UI', 'Roboto', sans-serif;
  line-height: 1.6;
  max-width: 500px;
  margin: 0 auto;
}

.overlay-content h2 {
  margin-bottom: 20px;
  font-size: 28px;
  font-weight: 700;
}

.overlay-content p {
  font-size: 17px;
  margin-bottom: 10px;
  padding: 0 10px;
}

.overlay-content a {
  text-decoration: underline;
  font-weight: 500;
}


/* .overlay-content {
    background-color: rgba(232, 224, 164, 0.903);
    padding: 30px 40px;
    border-radius: 12px;
    text-align: center;
    color: #333;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.287);
} */

/* .overlay-content h2 {
    margin-bottom: 10px;
}

.overlay-content p {
    margin-bottom: 20px;
} */

.overlay-content button {
    background-color: #f53b3b;
    color: rgb(12, 0, 0);
    border: none;
    padding: 10px 20px;
    font-size: 16px;
    margin: 5px;
    cursor: pointer;
    border-radius: 6px;
    transition: background-color 0.3s ease;
}

.overlay-content button:hover {
    background-color: #fbd3ab;
}

/* Fade-out class */
.fade-out {
    opacity: 0;
    pointer-events: none;
}

#info-fixed {
  position: absolute;
  top: 150px;
  left: 25px;
  width: 300px;
  background-color: rgba(247, 233, 144, 0.472); /* warm orange-yellow */
  padding: 20px 22px;
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
  z-index: 999;
  color: #333;
  font-size: 15px;
  line-height: 1.6;
  border: 1px solid #fbf306; /* subtle border to match theme */
}

#info-fixed h3 {
  margin-top: 0;
  font-size: 18px;
  font-weight: bold;
}

#info-fixed a {
  color: #3b2fe3;
  text-decoration: underline;
}
