.search-difficulty-scale {
  color: var(--search-scale-ink, var(--ink));
}
.search-difficulty-viewport {
  overflow-x: auto;
  scrollbar-color: var(--search-scale-border, var(--blue-dark)) transparent;
}
.search-difficulty-viewport:focus-visible {
  outline: 2px solid var(--search-scale-accent, var(--blue));
  outline-offset: 3px;
}
.search-difficulty-caption {
  color: var(--search-scale-muted, var(--ink-soft));
  font: 0.75rem/1.6 var(--sl-font, "Libre Franklin", sans-serif);
  margin: 1rem 0 0;
}
.how-page .search-difficulty-scale {
  max-width: 980px;
  margin-left: 84px;
}
@media (max-width: 760px) {
  .how-page .search-difficulty-scale {
    margin-left: 0;
  }
}

.rarity-meter {
  display: grid;
  gap: 0;
  width: 760px;
  min-width: 760px;
  padding: 1rem 0.5rem;
}

.rarity-step {
  display: grid;
  grid-template-columns: minmax(100px, 1fr) 118px 190px;
  align-items: center;
  gap: 12px;
}

.rarity-step.has-connector {
  grid-template-rows: 14px 34px;
  row-gap: 0;
}

.rarity-bar {
  position: relative;
  display: grid;
  grid-template-columns: repeat(9, minmax(0, 1fr));
  gap: 3px;
  height: 14px;
}

.rarity-bar > span {
  display: block;
  height: 14px;
  border: 2px solid var(--search-scale-border, var(--blue-dark));
  border-radius: 3px;
  background: var(--search-scale-accent, var(--blue));
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.08);
}

.rarity-reference-slice {
  position: absolute;
  z-index: 2;
  top: 2px;
  bottom: 2px;
  left: 2px;
  display: block;
  min-width: 2px;
  border-radius: 1px;
  background: var(--search-scale-highlight, var(--red));
  box-shadow: 0 0 0 1px rgba(255, 253, 245, 0.75);
}

.rarity-reference-slice::before {
  position: absolute;
  bottom: 100%;
  left: 50%;
  width: 1px;
  height: 4px;
  background: var(--search-scale-highlight, var(--red));
  content: "";
}

.rarity-scale-arrow {
  grid-row: 2;
  grid-column: 1;
  width: 100%;
  height: 34px;
  overflow: visible;
  pointer-events: none;
}

.rarity-scale-arrow path {
  fill: none;
  stroke-linecap: round;
}

.rarity-scale-arrow .rarity-scale-brace {
  stroke: color-mix(
    in srgb,
    var(--search-scale-accent, var(--blue)) 58%,
    var(--search-scale-muted, var(--ink-soft))
  );
  stroke-linejoin: round;
  stroke-width: 1.15;
}

.rarity-scale-arrow .rarity-scale-pointer {
  stroke: color-mix(
    in srgb,
    var(--search-scale-highlight, var(--red)) 82%,
    var(--search-scale-muted, var(--ink-soft))
  );
  stroke-linejoin: round;
  stroke-width: 1.35;
}

.rarity-scale-arrow .rarity-scale-arrow-head {
  fill: none;
  stroke: color-mix(
    in srgb,
    var(--search-scale-highlight, var(--red)) 82%,
    var(--search-scale-muted, var(--ink-soft))
  );
  stroke-linejoin: round;
  stroke-width: 1.35;
}

.rarity-step strong,
.rarity-step small {
  font-family: "DM Mono", monospace;
  font-size: 10px;
}

.rarity-step small {
  display: flex;
  align-items: baseline;
  justify-content: flex-end;
  gap: 9px;
  color: var(--search-scale-muted, var(--ink-soft));
  text-align: right;
}

.rarity-step small b {
  color: var(--search-scale-accent, var(--blue));
  font-size: 9px;
  white-space: nowrap;
}

.rarity-power sup {
  position: relative;
  top: -0.35em;
  margin-left: 1px;
  font-size: 0.68em;
  line-height: 0;
}

.rarity-odds {
  min-width: 91px;
}

.rarity-odds em {
  display: block;
  font-style: normal;
}
