/* Recherche — design FF.pen, id Pencil b4IuQm gNFrR */
.ff-search {
  display: flex;
  align-items: center;
  gap: var(--ff-space-3);
  box-sizing: border-box;
  width: 100%;
  height: 48px;
  margin: 0;
  padding: 0 var(--ff-space-4);
  border: 2px solid transparent;
  border-radius: var(--ff-radius-control);
  background-color: var(--ff-surface-alt);
  color: var(--ff-text-muted);
  font-family: var(--ff-font-body);
  font-size: var(--ff-font-size-m);
  font-weight: 400;
  line-height: normal;
  transition: background-color 0.14s ease, border-color 0.14s ease;
}

.ff-search__icon {
  flex-shrink: 0;
  width: 20px;
  font-size: 20px;
  line-height: normal;
  color: var(--ff-text-muted);
}

input.ff-search__input {
  -webkit-appearance: none;
  appearance: none;
  flex: 1 1 0;
  min-width: 0;
  height: 100%;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  color: var(--ff-text);
  font-family: var(--ff-font-body);
  font-size: var(--ff-font-size-m);
  font-weight: 400;
  line-height: normal;
}

input.ff-search__input::placeholder {
  color: var(--ff-text-muted);
  opacity: 1;
}

input.ff-search__input::-webkit-search-cancel-button,
input.ff-search__input::-webkit-search-decoration {
  -webkit-appearance: none;
  appearance: none;
  display: none;
}

.ff-search:focus-within,
.ff-search.is-focus {
  border-color: var(--ff-focus);
  background-color: var(--ff-surface);
}

.ff-search.is-filled,
.ff-search:has(input.ff-search__input:not(:placeholder-shown)) {
  background-color: var(--ff-surface);
}

button.ff-search__clear {
  display: none;
  flex-shrink: 0;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  width: 44px;
  height: 44px;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: var(--ff-radius-control);
  background-color: transparent;
  color: var(--ff-text-muted);
  font-family: var(--ff-font-body);
  font-size: 18px;
  line-height: 1;
  cursor: pointer;
}

.ff-search.is-filled button.ff-search__clear,
input.ff-search__input:not(:placeholder-shown) ~ button.ff-search__clear {
  display: inline-flex;
}

button.ff-search__clear:hover,
button.ff-search__clear.is-hover {
  background-color: var(--ff-surface-alt);
}

button.ff-search__clear:active,
button.ff-search__clear.is-active {
  background-color: var(--ff-border);
}

button.ff-search__clear:focus-visible,
button.ff-search__clear.is-focus {
  outline: 2px solid var(--ff-focus);
  outline-offset: 2px;
}

@media (prefers-reduced-motion: reduce) {
  .ff-search {
    transition: none;
  }
}
