/* The year bar: the maps' and the distances pages' ▶, two year handles on one track, and the year shown.
   static/globe/src/controls.js places the handles and moves them on a press. */
#year-label {
  font-variant-numeric: tabular-nums;
  font-weight: 600;
  min-width: 3.5em;
}
/* two handles on one track: the solid one is the year shown, the hollow one the year it is compared with */
#range {
  position: relative;
  flex: 1;
  min-width: 160px;
  height: 24px;
  cursor: pointer;
  touch-action: none; /* a press on the bar moves a handle (controls.js) rather than scrolling */
}
#range::before {
  content: "";
  position: absolute;
  left: 8px;
  right: 8px;
  top: 11px;
  height: 2px;
  background: var(--muted);
  opacity: 0.45;
}
#range-fill {
  position: absolute;
  top: 10px;
  height: 4px;
  border-radius: 2px;
  background: var(--accent);
  opacity: 0.55;
}
#range input {
  position: absolute;
  left: 0;
  top: 0;
  width: 100%;
  height: 24px;
  margin: 0;
  background: transparent;
  pointer-events: none;
  -webkit-appearance: none;
  appearance: none;
}
#range input::-webkit-slider-runnable-track {
  background: transparent;
  height: 24px;
}
#range input::-moz-range-track {
  background: transparent;
  height: 24px;
}
#range input::-webkit-slider-thumb {
  -webkit-appearance: none;
  pointer-events: auto;
  width: 16px;
  height: 16px;
  margin-top: 4px;
  border-radius: 50%;
  background: var(--accent);
  border: 2px solid var(--accent);
  cursor: pointer;
}
#range input::-moz-range-thumb {
  pointer-events: auto;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--accent);
  border: 2px solid var(--accent);
  cursor: pointer;
}
/* these two need the extra id to outweigh the rules above, or the hollow handle comes out filled */
#range #year-from::-webkit-slider-thumb {
  background: var(--bg);
}
#range #year-from::-moz-range-thumb {
  background: var(--bg);
}
/* the distances pages' bar, under the chart (the maps lay theirs out in their own controls) */
.year-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 8px 0 4px;
  max-width: 1100px;
}
.year-bar button {
  font: inherit;
  color: var(--fg);
  background: transparent;
  border: 1px solid var(--muted);
  border-radius: 3px;
  padding: 3px 10px;
  cursor: pointer;
}
.year-bar button:hover {
  border-color: var(--accent);
}
