/* =====================================================================
   Chip picker - tap-to-select values from a dictionary.
   Used by the trade form (setup, mindset tags) and the Dashboard's Today
   check-in. One look for both, so a dictionary edit reads identically
   wherever it surfaces.
   ================================================================== */
.chip-picker {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
}

.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 36px;
  padding: 0 var(--space-4);
  border-radius: var(--radius-pill);
  border: 0;
  background: var(--tile);
  /* A resting chip keeps its shape on any surface: the hairline is the edge
     (--tile alone is 1.05:1 on a white modal). */
  box-shadow: inset 0 0 0 1px var(--line);
  color: var(--text-2);
  font-size: var(--fs-caption);
  font-weight: var(--fw-medium);
  cursor: pointer;
  transition: background-color var(--dur-fast) var(--ease-standard),
    border-color var(--dur-fast) var(--ease-standard),
    color var(--dur-fast) var(--ease-standard);
}

:root[data-theme="light"] .chip:not(.is-active) {
  background: var(--tile-2);
}

.chip:hover {
  background: var(--tile-2);
  color: var(--text-1);
}

:root[data-theme="light"] .chip:not(.is-active):hover {
  background: rgba(0, 0, 0, 0.1);
}

/* Selected is filled with the lead colour, never outlined. */
.chip.is-active {
  background: rgba(var(--lead-rgb), 0.18);
  color: var(--lead);
}

.chip.is-active:not(.chip--offlist) {
  box-shadow: none;
}

.chip:focus-visible {
  outline: 2px solid var(--lead);
  outline-offset: 2px;
}

.chip-picker--sm .chip {
  min-height: 32px;
  padding: 0 var(--space-3);
  font-size: var(--fs-caption);
}

/* A value stored on a record that is no longer on its dictionary. Marked,
   never hidden or rewritten - see the dictionary hard rule in CLAUDE.md. */
.chip__offlist-dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--color-text-tertiary);
}

.chip--offlist {
  box-shadow: inset 0 0 0 1px var(--text-3);
}

