I want to align a div to the right side of an other div using margin-left: auto; but for some reason this does nothing. If the div is not contained by another div, this approach works flawlessly.
This is an example of the problem:
<!DOCTYPE html>
<html>
<body>
<style>
#inner {
margin-left: auto;
}
</style>
<div id="outer">
<div id="inner">
Text
</div>
</div>
</body>
</html>