html,
body {
  height: 100%;
  margin: 0;
}
#map {
  height: 100%;
  position: relative;
}

.topbar {
  position: absolute;
  top: 8px;
  right: 12px;
  display: flex;
  gap: 10px;
  z-index: 1000;
  pointer-events: none;
}
.topbar button,
.profile-wrap {
  pointer-events: auto;
}
.home-btn,
.profile-btn {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 2px solid #1c3144;
  background: #fff;
  color: #1c3144;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  padding: 0;
}
.home-btn:hover,
.profile-btn:hover {
  background: #eef3ff;
}

.profile-wrap {
  position: relative;
}
.profile-menu {
  position: absolute;
  right: 0;
  top: 48px;
  background: #fff;
  min-width: 150px;
  border: 1px solid #ccc;
  border-radius: 6px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.25);
  display: none;
  flex-direction: column;
  z-index: 1100;
}
.profile-menu a {
  padding: 9px 14px;
  color: #1c3144;
  text-decoration: none;
}
.profile-menu a:hover {
  background: #eef3ff;
}

.side-panel {
  position: absolute;
  top: 16px;
  left: 16px;
  z-index: 800;
  background: rgba(255, 255, 255, 0.95);
  padding: 16px 20px;
  border-radius: 8px;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.3);
  width: 330px;
  font-size: 1rem;
}

.flatpickr-calendar {
  width: 100% !important;
}
.hint {
  margin-top: 8px;
  font-size: 0.85rem;
  color: #555;
}

#spotPanel {
  position: absolute;
  top: 16px;
  left: 16px;
  z-index: 850;
  background: #fff;
  width: 330px;
  max-height: calc(100% - 32px);
  overflow: auto;
  border-radius: 8px;
  box-shadow: 0 1px 6px rgba(0, 0, 0, 0.45);
  display: none;
}
#spotPanel img {
  width: 100%;
  border-radius: 4px;
  margin-bottom: 8px;
}
#spotPanel h3 {
  margin: 4px 0;
}
#spotPanel ul {
  padding-left: 16px;
  margin: 8px 0;
}
.close-btn {
  background: none;
  border: none;
  color: #1c3144;
  font-size: 1rem;
  cursor: pointer;
  margin: -4px -4px 8px -4px;
}

.flash {
  list-style: none;
  margin: 0;
  padding: 6px 12px;
  position: absolute;
  bottom: 12px;
  left: 12px;
  z-index: 900;
}
.flash li {
  margin-bottom: 4px;
}
.flash .error {
  color: #b70000;
}
.flash .success {
  color: #0a781e;
}
.flash .info {
  color: #0051b7;
}
