:root {
  --red: #ca6868;
  --gray: #a7a7a7;
  --blue: #52a3fc;
  --green: #7abe50;

  font-family: system-ui, -apple-system, BlinkMacSystemFont,
               "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

#map {
    flex: 1;
    height: 100vh;
}

#loading {
    position: fixed;
    top: 0;
    left: 0;
    z-index: 9999;
    display: none;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    background: rgb(255 255 255 / 80%);
}

#loading.active {
    display: flex;
}

.spinner {
    width: 50px;
    height: 50px;
    border: 6px solid #eee;
    border-top: 6px solid #333;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.marker-icon-default {
    color: var(--gray);
}

.marker-icon-customers {
    color: var(--blue);
}

.marker-icon-success {
    color: var(--green);
}

.marker-icon-warning {
    color: var(--red);
}

#container {
  display: flex;
  height: 100vh;
}

#sidebar {
  width: 280px;
  padding: 15px;
  overflow-y: auto;
  background: #f8f9fa;
  border-right: 1px solid #ddd;
}

@media (width <= 600px) {
  #sidebar {
    position: absolute;
    z-index: 1000;
    width: 80%;
    height: 100%;
    transform: translateX(-100%);
    transition: transform 0.3s;
  }

  #sidebar.open {
    transform: translateX(0);
  }
}

#menu-btn {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 1100;
  padding: 8px 12px;
  font-size: 20px;
  cursor: pointer;
  background: white;
  border: 1px solid #ccc;
  border-radius: 6px;
}

/* optional: hide on desktop */
@media (width > 600px) {
  #menu-btn {
    display: none;
  }
}

.btn {
    display: inline-block;
    padding: .2rem .5rem;
    margin-top: 1rem;
}

#legend {
    padding-top: 2.5rem;
}

#legend table tr > td {
    padding: .5rem;
}

#legend table tr > td:first-child {
    padding-right: 1rem;
}
