/* [atual] assets/css/colorbar_styles.css */
/* Theme variables */
:root[data-mantine-color-scheme='light'] {
  --legend-bg: rgba(255, 255, 255, 0.88);
  --legend-border: #1a1a1a;
  --legend-text: #111;
  --legend-shadow: rgba(0, 0, 0, 0.18);
}
:root[data-mantine-color-scheme='dark'] {
  --legend-bg: rgba(0, 0, 0, 0.55);
  --legend-border: #444;
  --legend-text: #eee;
  --legend-shadow: rgba(0, 0, 0, 0.55);
}

.legend-box {
  background: var(--legend-bg);
  color: var(--legend-text);
  border: 1px solid var(--legend-border);
  border-radius: 10px;
  box-shadow: 0 6px 16px var(--legend-shadow);
  padding: 10px 12px;
  min-width: 160px;
  backdrop-filter: blur(6px);
}

.legend-title {
  font-weight: 700;
  font-size: 12px;
  margin-bottom: 8px;
  letter-spacing: .25px;
}

.legend-wrap {
  position: relative;
  display: flex;
  align-items: stretch;
}

.legend-ramp {
  width: 18px;             /* espessura da barra */
  height: 220px;           /* altura padrão (ajustada no inline se preciso) */
  border: 1px solid var(--legend-border);
  border-radius: 4px;
}

.legend-ticks {
  position: relative;
  margin-left: 12px;        /* espaço para labels ao lado da barra */
  width: max-content;
}

.legend-tick {
  position: absolute;
  transform: translateY(-50%);
  font-size: 11px;
  line-height: 1.1;
  white-space: nowrap;
}

.legend-tick::before {
  content: "";
  position: absolute;
  left: -10px;
  top: 50%;
  width: 8px;
  height: 1px;
  background: var(--legend-border);
}

/* Contêiner no canto superior direito (como os controles do Leaflet) */
.legend-topright {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 1000;
}
