I can not horizontally cen a div with flexbox. I have a half query for mobile screens
@media only screen and ( max-width: 479px )
{
.filadisco1
{
display: flex;
width:280px;
justify-content:center;
flex-direction:column;
align-content: center;
padding:0;
}
}
son of .filadisco1 (is out of the mediaquery)
.discox
{
width: 250px;
height: 420px;
margin-top: 34px;
background-color: #212f31;
}
I'm seeing many tutorials but it's not clear where to put:
justify-content:center;
flex-direction:column;
align-content: center;
If in the container or in the children, the template I use is purchased and I do not know if there is any code that is interfering with centering .discox
html:
<div id="content-area">
<div class="container clearfix">
<div id="main-area">
<h1 class="tituloseccion alineacionh1h2">Discografía</h1>
<div class="filadisco1">
<div class="discox">
<a class="ablanco" href="la-desvirtualizacion-de-las-ideas/"><img class="imgdiscosx" src="<?php bloginfo('template_url'); ?>/images/jamondisco5.jpg"</></a>
<p class="parrafodisco">La Desvirtualización de las ideas(2015)</p>
<p class="parrafodescrip"> La idea sigue siendo la misma. Rock cannábico y kalimochero. La grabación [...]</p>
</div><!-- discox->
</div><!-- filadisco1->
</div> <!-- #main-area -->
</div> <!-- .container -->
</div> <!-- #content-area -->
I can not center .discox