html,
body {
  margin: 0;
  padding: 0;
  height: 100%;
  background: #000;
  color: #eee;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    sans-serif;
}

.map-wrap {
  height: calc(100vh - 50px);
  width: 100%;
  position: relative;
}

#map {
  height: 100%;
  width: 100%;
  background: #262626;
}

/* --- Overlay / panel --- */
.overlay {
  position: absolute;
  inset: 0;
  z-index: 500;
  outline: none;
}

.backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.45);
}

.panel {
  position: absolute;
  top: 0;
  right: 0;
  height: 100%;
  width: min(720px, 92vw);
  background: #111;
  color: #eee;
  box-shadow: -12px 0 30px rgba(0, 0, 0, 0.45);
  z-index: 1;
  display: flex;
  flex-direction: column;
  border-left: 1px solid #222;
}

.panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 16px;
  background: #161616;
  border-bottom: 1px solid #222;
  color: #FFD700;
}

.overlay .close-btn {
  background: transparent;
  border: none;
  font-size: 1.6rem;
  line-height: 1;
  cursor: pointer;
  color: #FFD700;
  padding: 6px;
}

.close-btn:hover {
  background: #2a2a2a;
}

.panel-body {
  overflow-y: auto;
  font-size: 0.95rem;
}

.place-description {
  padding: 16px;
  margin-bottom: 1rem;
  line-height: 1.4;
}

.place-raw dl {
  margin: 0;
}

.place-raw dt {
  font-weight: 600;
  font-size: 0.8rem;
  text-transform: uppercase;
  color: #aaa;
  margin-top: 0.5rem;
}

.place-raw dd {
  margin: 0;
  font-size: 0.9rem;
  color: #ddd;
}

.leaflet-control-attribution {
  background: rgba(0, 0, 0, 0.4);
  color: #ccc;
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 12px;
}

.year-control {
  background: rgba(0, 0, 0, 0.6);
  color: #ffd700;
  padding: 0.5rem 0.75rem;
  border-radius: 0.5rem;
  width: 260px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.35);
  margin-bottom: 150px;
  margin-left: 20px;
}

.year-control .yc-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.35rem;
}

.year-control .yc-btn {
  cursor: pointer;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: #ffd700;
  border-radius: 0.5rem;
  padding: 0.25rem 0.5rem;
  font-size: 1rem;
}

.year-control .yc-display {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas,
    monospace;
  font-size: 1.25rem;
  letter-spacing: 0.5px;
}

.year-control .yc-slider {
  width: 100%;
  accent-color: #ffd700;
}

.year-control .yc-minmax {
  display: flex;
  justify-content: space-between;
  font-size: 0.75rem;
  color: #bbb;
  margin-top: 0.25rem;
}

.volcano-control {
  pointer-events: auto; 
  background: rgba(30, 30, 30, 0.85);

  border-radius: 10px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.35);
  backdrop-filter: blur(6px);
}

.volcano-select {
  font-size: 16px;
  padding: 10px 14px;
  border-radius: 8px;
  border: 1px solid #444;
  background: #202020;
  color: #f0f0f0;
  cursor: pointer;
  outline: none;
  appearance: none;           
  -webkit-appearance: none;
  -moz-appearance: none;
  position: relative;
  width: 220px;
  font-weight: 500;
  margin: 20px;
  box-shadow: inset 0 1px 3px rgba(0,0,0,0.4);
  transition: all 0.15s ease;
}


.volcano-select:hover {
  border-color: #777;
  background: #2a2a2a;
}


.volcano-select:focus {
  border-color: #FFD700;
  box-shadow: 0 0 0 3px rgba(255, 215, 0, 0.4);
}


.volcano-select {
  background-image:
    linear-gradient(45deg, transparent 50%, #ccc 50%),
    linear-gradient(135deg, #ccc 50%, transparent 50%),
    linear-gradient(to right, #444, #444);

  background-position:
    calc(100% - 16px) calc(50% - 4px),
    calc(100% - 12px) calc(50% - 4px),
    calc(100% - 28px) 50%;

  background-size:
    6px 6px,
    6px 6px,
    1px 40%;

  background-repeat: no-repeat;
}

.volcano-info {
  margin-top: 6px;
  font-size: 0.85rem;
  color: #ccc;
  padding-left: 16px;
}

.leaflet-bar.volcano-control {
  transition: opacity 150ms ease;
}

.emission-legend {
  background: rgba(0,0,0,0.66);
  color: #eee;
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid rgba(255,255,255,0.06);
  box-shadow: 0 2px 8px rgba(0,0,0,0.35);
  min-width: 120px;
  z-index: 1200;
}

.leaflet-bottom .emission-legend{
  margin-bottom: 20px;
  margin-right: 20px;
}

.emission-legend .legend-title {
  color: #ffd700;
  font-weight: 700;
  margin-bottom: 6px;
  font-size: 0.9rem;
}

.emission-legend .legend-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 6px 0;
}

.emission-legend .legend-label {
  font-size: 0.85rem;
  color: #eee;
  white-space: nowrap;
}

.topbar {
  height: 48px;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0 16px;
  background: #161616;
  color: #ffd700;
  font-size: 1.1rem;
  box-shadow: 0 1px 0 rgba(255,255,255,0.05);
  z-index: 1500;
}

.topbar-title {
  font-weight: 600;
  letter-spacing: 0.3px;
}

.back-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 10px;
  background: rgba(255,255,255,0.08);
  color: #fff;
  text-decoration: none;
  border-radius: 8px;
  font-size: 0.9rem;
  border: 1px solid rgba(255,255,255,0.15);
  cursor: pointer;
}

.back-btn:hover {
  background: rgba(255,255,255,0.16);
}

.back-btn:active {
  transform: translateY(1px);
}

.leaflet-top,
.leaflet-bottom {
  pointer-events: none;
}

.leaflet-top .leaflet-control,
.leaflet-bottom .leaflet-control {
  pointer-events: auto;
}

/* topbar: push title center-ish and info to far right */
.topbar { display: flex; align-items: center; gap: 12px; }
.topbar-title { flex: 1; text-align: center; }

/* info button */
.info-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 10px;
  border: 1px solid rgba(255,255,255,0.15);
  background: rgba(255,255,255,0.08);
  color: #fff;
  cursor: pointer;
}

.info-btn:hover { background: rgba(255,255,255,0.16); }
.info-btn:active { transform: translateY(1px); }

/* info overlay modal */
.info-overlay {
  position: fixed;
  inset: 0;
  z-index: 3000; 
}

.info-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.55);
}

.info-panel {
  position: absolute;
  top: 70px;
  left: 50%;
  transform: translateX(-50%);
  width: min(720px, 92vw);
  max-height: calc(100vh - 110px);
  background: #111;
  border: 1px solid #222;
  border-radius: 14px;
  box-shadow: 0 20px 50px rgba(0,0,0,0.55);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.info-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 6px 16px;
  background: #161616;
  border-bottom: 1px solid #222;
  color: #ffd700;
}

.info-close {
  background: transparent;
  border: none;
  color: #ffd700;
  font-size: 1.6rem;
  line-height: 1;
  cursor: pointer;
  padding: 6px;
  border-radius: 10px;
}
.info-close:hover { background: #2a2a2a; }

.info-body {
  padding: 16px;
  overflow: auto;
  color: #eee;
  line-height: 1.45;
}