/* Base */
body {
  font-family: Arial, sans-serif;
  margin: 20px;
  background: #f8f9fa;
  color: #333;
}

h1 {
  color: #0056b3;
  margin-bottom: 8px;
}

/* Primary button style (kept for other buttons) */
button {
  padding: 10px 15px;
  margin-top: 10px;
  background: #0056b3;
  color: white;
  border: none;
  border-radius: 5px;
  cursor: pointer;
}

button:hover {
  background: #003f7f;
}

/* Dashboard layout: side-by-side columns */
.dashboard-container {
  display: flex;
  gap: 1rem;
  margin-top: 16px;
  align-items: flex-start; /* align columns at top */
}

/* Left column: map + guide button */
.map-column {
  flex: 1;                      /* takes left half (or proportionally) */
  display: flex;
  flex-direction: column;
  align-items: stretch;         /* map fills column width */
  min-width: 300px;
}

/* Map area */
#map {
  width: 100%;
  height: 400px;
  border: 1px solid #ccc;
  border-radius: 6px;
  background: #eaeaea;
}

/* Guide container centered under the map */
#guide-container {
  width: 100%;
  margin-top: 12px;
  text-align: center;          /* centers the button horizontally */
}

/* Style for the guide button */
#guideBtn {
  padding: 12px 22px;
  font-size: 1rem;
  background: #28a745;
  border: none;
  border-radius: 6px;
  color: white;
  cursor: pointer;
}

#guideBtn:hover {
  background: #218838;
}

/* Right column: info / list / table */
.info-box {
  flex: 1;
  padding: 1rem;
  border: 1px solid #ccc;
  border-radius: 6px;
  background: #fff;
  max-height: 400px;
  overflow-y: auto;
  min-width: 260px;
}

/* Shelter table (aligned name | distance) */
.shelter-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 0.5rem;
  font-size: 0.95rem;
}

.shelter-table th, .shelter-table td {
  border: 1px solid #e0e0e0;
  padding: 8px 10px;
  text-align: left;
}

.shelter-table th {
  background: #f1f1f1;
  color: #0056b3;
  font-weight: 600;
}

.shelter-table td:last-child {
  text-align: right;  /* distance aligned to right */
}

/* highlight nearest row */
.shelter-table tr.nearest {
  background: #d4edda; /* light green */
}

/* Responsive: stack columns on small screens */
@media (max-width: 768px) {
  .dashboard-container {
    flex-direction: column;
  }

  #map, .info-box {
    height: auto;
    max-height: none;
  }
}
