I have a div called .outer
which contained a div called .film
, and the div .film
has some of image divs.
The problem is .outer
div doesn't shrink it as the screen size in Firefox like this picture:
As you can see, the div is shrinking well in Chrome(left side) but not in Firefox(right side).
Are there any ways to shrink the .outer
div in Firefox just like Chrome does?
This is the code:
* {
margin: 0;
padding: 0;
}
section, div {
position: relative;
}
.outer {
margin: 0 auto;
width: 500px;
height: 500px;
display: flex;
flex-flow: row;
justify-content: center;
overflow: hidden;
}
.film {
width: 90%;
margin: 0 .8%;
display: flex;
flex-flow: column;
justify-content: center;
flex-shrink: 0;
padding-bottom: 33.3333%;
background-image: url('https://i.imgur.com/3p6TLYE.jpg');
background-size: cover;
background-position: center center;
overflow: hidden;
}
.film:nth-child(2n-1) {
opacity: .4;
transform: scale();
}
<div class="outer">
<div class="film"></div>
<div class="film"></div>
<div class="film"></div>
</div>