.prosearch {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
}

.prosearch__form {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
}

.prosearch__input {
  width: 0;
  max-width: 0;
  opacity: 0;
  overflow: hidden;
  transition: width 0.3s ease, max-width 0.3s ease, opacity 0.25s ease, padding 0.3s ease;
}

.prosearch__input input {
  width: 100%;
  padding: 0.15rem 0.35rem;
  border: none;
  border-bottom: 1px solid currentColor;
  background: transparent;
  font-size: 0.85rem;
  line-height: 1.3;
  color: inherit;
}

.prosearch__input input:focus {
  outline: none;
  border-color: currentColor;
}

.prosearch.is-open .prosearch__input {
  width: 150px;
  max-width: 150px;
  opacity: 1;
}

.prosearch__button {
  display: inline-flex;
}

.prosearch__toggle {
  padding: 0.35rem;
  border: 1px solid currentColor;
  background: transparent;
  border-radius: 999px;
  color: inherit;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease;
}

.prosearch__toggle:hover,
.prosearch__toggle:focus-visible {
  background: var(--wp--preset--color--foreground, #000);
  color: var(--wp--preset--color--background, #fff);
}

.prosearch__toggle svg {
  width: 1rem;
  height: 1rem;
  stroke: currentColor;
}
