/* --- Autocomplete control --- */

/* Container for the input and the list */
.autocomplete-container {
    position: relative;
    display: inline-block;
    width: 100%;
}

/* The floating list */
.autocomplete-items {
    position: absolute;
    border: 1px solid #d4d4d4;
    border-bottom: none;
    border-top: none;
    z-index: 99;
    top: 100%; /* Position right below the input */
    left: 0;
    right: 0;
    max-height: 200px; /* Scroll if too many results */
    overflow-y: auto;
    background-color: #fff;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

.autocomplete-items div {
    padding: 10px;
    cursor: pointer;
    background-color: #fff;
    border-bottom: 1px solid #d4d4d4;
}

/* Hover effect */
.autocomplete-items div:hover {
    background-color: #e9e9e9;
}

/* Highlight matching letters (optional styling) */
.autocomplete-items strong {
    color: #007bff;
}

/* --- Autocomplete control end --- */

/* --- Multiselect control --- */
.multiselect {
  position: relative;
  width: 100%;
  font-family: system-ui, sans-serif;
}

.input-wrapper {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  cursor: text;
}

.tag {
  background: var(--color-bg-btn-secondary);
  color: var(--color-text-btn-secondary);
  padding: 4px 8px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 1rem;
  font-weight: 500;
}

.tag button.close {
  border: none;
  background: none;
  color: var(--color-text-btn-secondary);
  cursor: pointer;
  font-size: 14px;
  line-height: 1;
}

.dropdown {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: #fff;
  border: 1px solid #ccc;
  border-radius: 6px;
  margin-top: 4px;
  max-height: 200px;
  overflow-y: auto;
  list-style: none;
  padding: 0;
  display: none;
  z-index: 100;
}

.dropdown li {
  padding: 8px;
  cursor: pointer;
}

.dropdown li:hover {
  background: #f3f4f6;
}

/* --- Multiselect control end --- */