.password-div {
    position: relative;
    display: inline-block; /* или block, в зависимости от макета */
    width: 100%; /* растягиваем на всю доступную ширину */
}

.password-div input {
    padding-right: 40px; /* Оставляем место для иконки */
    width: 100%; /* input занимает всю ширину контейнера */
    box-sizing: border-box; /* чтобы padding не увеличивал ширину */
}

.password-control {
    position: absolute;
    top: 50%;
    right: 12px; /* Отступ от правого края */
    transform: translateY(-50%);
    display: flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    text-decoration: none;
    color: #666;
    cursor: pointer;
    z-index: 2; /* Чтобы иконка была поверх input */
    background: url(/assets/img/eye.svg) center/contain no-repeat;
}

.password-control:hover {
    color: #333;
}

.password-control.view {
    background: url(/assets/img/eye-slash.svg) center/contain no-repeat;
}