inexplicable space gap in page - html

I need help with an invisible/inexplicable space gap in my webpage, in the screen screenshots below you can see the space (the red area):
I need that they behavior just like the other row below "LMP" and "LMB"
In Safari the space gap is not present, but in chrome and firefox this space appears, ain honestly I don't kow what to do, i detected that the container class with a width:80% desapears the gap, but then the page becomes too thin.
Here is a
JSfiddle
IF anyone has the same problem, above the titles I have a header, in this I missed a /div so the next row was complete crazy...thanks to all for helping me, i really apreciate the help

You need to make <div class="row">
before any col-md/col-lg/col-sm Because Bootstrap keep 15px Padding for this.
Update jsfiddle solution:
Update solution in codepen Link
And Update Snipper
/***** 3.- NEWS AND CONTENT *******/
.news-section {
background-color: #F1EFEF;
height: 1500px;
}
.black-title {
margin-top: 50px;
height: 60px;
width:112%;
margin-left: -15px;
background-color: #4A90E2;
text-align: center;
line-height: 60px;
}
.black-title > h3 {
vertical-align: middle;
}
.white-title {
margin-top: 50px;
height: 60px;
margin-left: -15px;
background-color: #3F444A;
color: #fff;
text-align: center;
line-height: 60px;
}
.white-title > h3 {
vertical-align: middle;
}
.title-section-2 {
margin-top:0px;
height: 100%;
}
.news-content {
margin-top: 25px;
display: block;
}
.news-content img {
margin:auto;
background-color: #F1EFEF;
}
.news-link {
text-align: right;
margin: 10px;
}
.news-link a {
color: #E7BF3A;
text-decoration: none;
}
.spot-horizontal {
height: 90px;
margin-top: 10px;
background-color: #BD10E0;
}
.logos-horizontal {
height: 50px;
background-color: #3F444A;
}
<link href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css" rel="stylesheet"/>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"></script>
<section>
<div class="container">
<div class="row">
<div class="news-section">
<div class="col-md-6 col-sm-6">
<div class="row">
<h3 class=" black-title">Lo más nuevo</h3>
<div class="news-content">
<img class="img-responsive" src="http://placehold.it/500x400" alt="" >
</div>
</div>
</div>
<div class="col-md-6 col-sm-6">
<div class="row">
<h3 class="white-title">Videos más nuevos</h3>
<div class="news-content">
<img class="img-responsive" src="http://placehold.it/500x400" alt="" >
</div>
</div>
</div>
<div class="col-md-12 spot-horizontal">
<div class="row">
<h3 class="title-black">PUBLICIDAD</h3>
</div>
</div>
<div class="col-md-6 col-sm-6">
<div class="row">
<h3 class=" black-title title-section-2">LMB</h3>
<div class="news-content">
<h4>Titulo de noticia</h4>
<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Aenean molestie aliquet tristique. Proin aliquam neque quis est sagittis, tempus sagittis tortor mattis. Praesent nec gravida.</p>
<h4>Titulo de noticia</h4>
<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Aenean molestie aliquet tristique. Proin aliquam neque quis est sagittis, tempus sagittis tortor mattis. Praesent nec gravida.</p>
<div class="news-link">
Más Noticias
</div>
</div>
</div>
</div>
<div class="col-md-6 col-sm-6">
<div class="row">
<h3 class="white-title title-section-2">LMP</h3>
<div class="news-content">
<h4>Titulo de noticia</h4>
<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Aenean molestie aliquet tristique. Proin aliquam neque quis est sagittis, tempus sagittis tortor mattis. Praesent nec gravida.</p>
<h4>Titulo de noticia</h4>
<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Aenean molestie aliquet tristique. Proin aliquam neque quis est sagittis, tempus sagittis tortor mattis. Praesent nec gravida.</p>
<div class="news-link">
Más Noticias
</div>
</div>
</div>
</div>
<div class="col-md-12 logos-horizontal">
<div class="row">
<h3 class="white-title title-section-2">LOGOS</h3>
</div>
</div>
</div>
</div>
</div>
</section>

Both divs have to be inline-block and have the same parent.
Here's a fiddle: https://jsfiddle.net/fbrh1464/6

Related

How to align items with different heights?

I'm not sure how better to describe it, so:
I have a grid for 12 columns. (2 identical icons and 2 texts with different heights) per 6 columns. Is there any way to align icons by center and texts by the same height? I'm able to align icons but texts are always on different heights.
.benefits .benefits_item {
display: flex;
justify-content: center;
align-items: center;
margin-top: 35px;
min-height: 150px;
}
.benefits .benefits_item .benefits_round {
display: flex;
justify-content: center;
align-items: center;
margin-right: 25px;
width: 116px;
height: 116px;
background: #1EACC7;
border-radius: 50%;
}
.benefits .benefits_item .benefits_descr {
width: 370px;
font-family: 'Roboto';
font-style: normal;
font-weight: 300;
font-size: 15px;
color: #202020;
}
.benefits .benefits_item .benefits_descr span {
font-family: 'Roboto';
font-style: normal;
font-weight: 400;
font-size: 17px;
line-height: 25px;
color: #1EACC7;
<div class="row">
<div class="col-md-6">
<div class="benefits_item">
<div class="benefits_round"><img src="" alt="1" class="benefits_icon"></div>
<div class="benefits_descr"><span>Lorem ipsum dolor sit ame</span><br>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec arcu ligula, lacinia vel fermentum elementum</div>
</div>
</div>
<div class="col-md-6">
<div class="benefits_item">
<div class="benefits_round"><img src="" alt="2" class="benefits_icon"></div>
<div class="benefits_descr"><span>Lorem ipsum</span><br>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec arcu ligula, lacinia vel fermentum elementum, malesuada vel ante. Donec ut odio augue. Integer a aliquet quam. Aenean ut enim ullamcorper, feugiat neque ac,
pretium augue.</div>
</div>
</div>
</div>
You can add align-items-center to <div class="row"> -- Bootstrap's rows use display: flex so you can use other flex utility classes on the row
:root {
--color: #1EACC7;
--iconSize: 6rem;
}
.benefits_round {
height: var( --iconSize );
max-width: var( --iconSize ); min-width: var( --iconSize );
background-color: var( --color );
}
.benefits_descr span { color: var( --color ) }
<link href="https://cdn.jsdelivr.net/npm/bootstrap#5.1.3/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-1BmE4kWBq78iYhFldvKuhfTAU6auU8tT94WrHftjDbrCEXSU1oBoqyl2QvZ6jIW3" crossorigin="anonymous">
<div class="container-md">
<div class="row align-items-center">
<div class="col-sm-6">
<div class="d-flex justify-content-center align-items-center">
<div class="benefits_round rounded-circle me-4 d-flex justify-content-center align-items-center">
<img src="" alt="1">
</div>
<div class="benefits_descr fw-light">
<span class="fs-5">Lorem ipsum dolor sit ame</span>
<br>
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec arcu ligula, lacinia vel fermentum elementum
</div>
</div>
</div>
<div class="col-sm-6">
<div class="d-flex justify-content-center align-items-center">
<div class="benefits_round rounded-circle me-4 d-flex justify-content-center align-items-center">
<img src="" alt="2">
</div>
<div class="benefits_descr fw-light">
<span class="fs-5">Lorem ipsum</span>
<br>
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec arcu ligula, lacinia vel fermentum elementum, malesuada vel ante. Donec ut odio augue. Integer a aliquet quam. Aenean ut enim ullamcorper, feugiat neque ac, pretium augue.
</div>
</div>
</div>
</div>
</div>

Header overlay over Hero

I am working on a website. I am a little rusty when it comes to CSS. I am trying to get the same effect as this page https://prp.fm/. I want the header to be over the hero section with a transparent background. The header does not need to be sticky, but I am unable to get the header to overlay over the header.
I tried adding background-attachment:fixed in the .hero-section CSS, but it would just fix the image to the page and not scroll with the page. That I do NOT want. I want the hero section to be behind the header and scroll with the page.
.main {
padding-top: 0 !important;
}
.header-section {
background: #212121;
padding: 0 33px;
padding-bottom: 50px;
border-bottom: 1px solid #fff;
position: relative:
}
.hero-section {
height: 962px;
background-image: url(../img/chart-bg.jpg);
background-repeat: no-repeat;
background-size: cover;
background-position: top center;
padding-top: 0px;
z-index: 100;
}
<header class="header-section" id="header">
<div class="header-warp">
<!-- Site Logo -->
<a href="home.html" class="site-logo">
<img src="img/logo.png" alt="">
</a>
<!-- responsive -->
<div class="nav-switch">
<i class="fa fa-bars"></i>
</div>
</div>
</header>
<div class="main">
<section class="hero-section">
</section>
<div id="inner">
<section class="some-section">
<div class="container">
<div class="section-title text-center">
<h2>Tile</h2>
</div>
<div class="row about-box">
<div class="col-lg-6">
<img src="img/pic1.jpg" alt="">
</div>
<div class="col-lg-6">
<div class="ab-content">
<h4>A short History</h4>
<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nam eu tincidunt ligula. Fusce dictum ullamcorper purus, at elementum sem sollicitudin non. Sed id tristique lacus. Fusce pellentesque dignissim arcu, id hendrerit urna feugiat vitae.
Pellentesque viverra aliquet arcu, vel aliquet est commodo quis. Nam tempus, nisl eu maximus viverra, magna quam porta nibh.</p>
</div>
</div>
</div>
</div>
</section>
</div>
Just reduce an opacity on the header and increase the font-weight of the contents which are in the header like the following
.main {
padding-top: 0 !important;
}
.header-section {
background: #212121;
padding: 0 33px;
padding-bottom: 50px;
border-bottom: 1px solid #fff;
opacity: .3; /* added */
position: relative:
}
.hero-section {
height: 962px;
background-image: url(../img/chart-bg.jpg);
background-repeat: no-repeat;
background-size: cover;
background-position: top center;
padding-top: 0px;
z-index: 100;
}
<link rel="stylesheet" type="text/css" href="https://stackpath.bootstrapcdn.com/bootstrap/4.5.2/css/bootstrap.min.css">
<header class="header-section" id="header">
<div class="header-warp">
<!-- Site Logo -->
<a href="home.html" class="site-logo">
<img src="img/logo.png" alt="">
</a>
<!-- responsive -->
<div class="nav-switch">
<i class="fa fa-bars"></i>
</div>
</div>
</header>
<div class="main">
<section class="hero-section">
</section>
<div id="inner">
<section class="some-section">
<div class="container">
<div class="section-title text-center">
<h2>Tile</h2>
</div>
<div class="row about-box">
<div class="col-lg-6">
<img src="img/pic1.jpg" alt="">
</div>
<div class="col-lg-6">
<div class="ab-content">
<h4>A short History</h4>
<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nam eu tincidunt ligula. Fusce dictum ullamcorper purus, at elementum sem sollicitudin non. Sed id tristique lacus. Fusce pellentesque dignissim arcu, id hendrerit urna feugiat vitae.
Pellentesque viverra aliquet arcu, vel aliquet est commodo quis. Nam tempus, nisl eu maximus viverra, magna quam porta nibh.</p>
</div>
</div>
</div>
</div>
</section>
</div>

How to get colums side by side on large screens and under each other on smaller screens in bootstrap 4?

I have two columns within a row, but they're not side by side. They are within another div column that is within another row, but that shouldn't matter, should it? Columns should always be side by side unless coded otherwise. How can I make sure the columns are next to each other in larger screens and underneath each other on smaller screens? I tried the order-* tag, but that didn't work. I'm only a beginner, so apologies is this is easy to fix, but I can't figure it out myself.
It looks like this now, the text should be next to the picture on the right side:
enter image description here
This is the code:
.recept-bereiding {
color: #9a084d;
margin-left: 0px;
margin-right: 50px;
}
.recept-bereiding p {
font-size: 0.85rem !important;
}
.steps {
padding-left: 0px;
list-style-type: none;
color: #9a084d;
font-size: 0.9em;
counter-reset: step-counter calc(var(--start) - 1);
}
.steps img {
padding-bottom: 5px;
}
.steps ol {
counter-reset: step-counter;
}
.steps li {
counter-increment: step-counter;
counter-reset: none;
}
.steps li::before {
content: counter(step-counter);
background-color: #7dc623;
margin-right: 5px;
padding: 4px 8px;
font-size: 0.9em;
font-weight: bold;
color: #ffffff;
border-radius: 100%;
}
<div class="container ">
<div class="row d-flex justify-content-center">
<div class="col-md-8 recept-bereiding">
<h3>Omschrijving</h3>
<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed finibus odio id augue ornare scelerisque. Quisque porta tempor velit, in viverra urna euismod in. Nulla nec efficitur turpis. Quisque at.</p>
<h3>Bereidingswijze</h3>
<row>
<div class="col-md-3 p-0 steps">
<img src="https://i.imgur.com/SJAUllt.jpg" alt=""/>
</div>
<div class="col-md-9 p-0">
<ol style="counter-reset: step-counter 0" start="1" class="steps">
<li>Vestibulum rhoncus egestas lectus quis vulputate. Vestibulum rutrum, ipsum vel vestibulum suscipit, sem lorem malesuada ex, a.</li>
</ol>
</div>
</row>
</div>
<div class="col-md-3 receptside">
</div>
</div>
</div>
well,
Columns should always be side by side unless coded otherwise
isn't always true and it depends on the viewport dimensions.
I would code it like this :
<div class="container">
<div class="row">
<div class="col-md-4 recept-bereiding">
<h3>Omschrijving</h3>
<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed finibus odio id augue ornare scelerisque. Quisque porta tempor velit, in viverra urna euismod in. Nulla nec efficitur turpis. Quisque at.</p>
<h3>Bereidingswijze</h3>
</div>
<div class="col-md-4 p-0 steps">
<img src="https://i.imgur.com/SJAUllt.jpg" alt="" class="img-fluid"/>
</div>
<div class="col-md-4 p-0">
<ol style="counter-reset: step-counter 0" start="1" class="steps">
<li>Vestibulum rhoncus egestas lectus quis vulputate. Vestibulum rutrum, ipsum vel vestibulum suscipit, sem lorem malesuada ex, a.</li>
</ol>
</div>
<div class="col-md-4 receptside">
</div>
</div>
</div>
</div>
consider the following points:
Do not use row tag in your html. row is a bootstrap class and must be treated as
<div class="row">
ending tags do not need classes as in:
</div class="row">
use bootstrap responsive numbers accordingly.
<div class="col-md-4"
means it will occupy 4 parts of the 12 available space given to its div on a medium sized screen
Can change <row> to <div class="row">. When in fullscreen, the column will show side by side.
.recept-bereiding {
color: #9a084d;
margin-left: 0px;
margin-right: 50px;
}
.recept-bereiding p {
font-size: 0.85rem !important;
}
.steps {
padding-left: 0px;
list-style-type: none;
color: #9a084d;
font-size: 0.9em;
counter-reset: step-counter calc(var(--start) - 1);
}
.steps img {
padding-bottom: 5px;
}
.steps ol {
counter-reset: step-counter;
}
.steps li {
counter-increment: step-counter;
counter-reset: none;
}
.steps li::before {
content: counter(step-counter);
background-color: #7dc623;
margin-right: 5px;
padding: 4px 8px;
font-size: 0.9em;
font-weight: bold;
color: #ffffff;
border-radius: 100%;
}
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/4.4.1/css/bootstrap.min.css">
<div class="container ">
<div class="row d-flex justify-content-center">
<div class="col-md-8 recept-bereiding">
<h3>Omschrijving</h3>
<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed finibus odio id augue ornare scelerisque. Quisque porta tempor velit, in viverra urna euismod in. Nulla nec efficitur turpis. Quisque at.</p>
<h3>Bereidingswijze</h3>
<div class="row">
<div class="col-md-3 p-0 steps">
<img src="https://i.imgur.com/SJAUllt.jpg" alt=""/>
</div>
<div class="col-md-9 p-0">
<ol style="counter-reset: step-counter 0" start="1" class="steps">
<li>Vestibulum rhoncus egestas lectus quis vulputate. Vestibulum rutrum, ipsum vel vestibulum suscipit, sem lorem malesuada ex, a.</li>
</ol>
</div>
</div>
</div>
<div class="col-md-3 receptside">
</div>
</div>
</div>

Aligning multiple boxes on CSS

I'm struggling to align a group of boxes in the center of my webpage when displayed on a computer screen. I'm floating the boxes left but then it's assymetrical with more space on the right. It's currently looking like this:
! https://imgur.com/a/wq0yv6S
I tried a few different alignment properties to the "boxes" and "box" classes but they didn't accomplish anything.
HTML of the section + first box and CSS:
#boxes {
margin-top: 20px;
}
#boxes .box {
float: left;
width: 20%;
padding: 10px;
text-align: center;
align-self: center;
justify-content: space-around;
}
#boxes .box img {
width: 200px;
}
<section id="boxes">
<div class="container">
<div class="box">
<img src="./img/foto0.jpg">
<h2>Pessoa Fisica</h2>
<p>Cuidamos da sua declaracao de imposto de renda</p>
</div>
I'd like to have those boxes positioned symmetrically.
You can use display: grid;
.grid {
display: grid;
grid-template-columns: repeat(4, 1fr);
grid-gap: 1em;
}
.grid-item {
background: #F7F7F7;
padding: 1em;
text-align: center;
}
<div class="grid">
<div class="grid-item">1</div>
<div class="grid-item">2</div>
<div class="grid-item">3</div>
<div class="grid-item">4</div>
</div>
You could use flexbox,
it's very easy to start with,
you need to implement this CSS code to the parent container which you need its children to be aligned in someway
.container{
display: flex;
justify-content: center;
align-items: center;
}
<section id="boxes">
<div class="container">
<div class="box">
<img src="./img/foto0.jpg">
<h2>Pessoa Fisica</h2>
<p>Cuidamos da sua declaracao de imposto de renda</p>
</div>
What you're trying to achieve is not too hard with flexbox. See the following demo for an example. If you have any questions please ask :).
Note: The .site div is not needed but added for reference.
.container {
width: 100%;
padding-right: 15px;
padding-left: 15px;
margin-right: auto;
margin-left: auto;
max-width: 960px;
}
.row {
display: flex;
align-items: center;
flex-wrap: wrap;
margin-right: -15px;
margin-left: -15px;
}
.box {
position: relative;
flex-basis: 0;
flex-grow: 1;
max-width: 100%;
padding-right: 15px;
padding-left: 15px;
}
.site {
border: 1px solid red;
}
img {
max-width: 100%;
height: auto;
}
<div class="site">
<div class="container">
<div class="row">
<div class="box">
<img src="https://dummyimage.com/300x200/f9f9f9/aaa" alt="">
<h2>Title #1</h2>
<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Morbi dui purus, porta sit amet elit ut, pretium dapibus ante. Suspendisse non pharetra odio. Mauris ac placerat libero.</p>
</div>
<div class="box">
<img src="https://dummyimage.com/300x200/f9f9f9/aaa" alt="">
<h2>Title #1</h2>
<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Morbi dui purus, porta sit amet elit ut, pretium dapibus ante. Suspendisse non pharetra odio. Mauris ac placerat libero.</p>
</div>
<div class="box">
<img src="https://dummyimage.com/300x200/f9f9f9/aaa" alt="">
<h2>Title #1</h2>
<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Morbi dui purus, porta sit amet elit ut, pretium dapibus ante. Suspendisse non pharetra odio. Mauris ac placerat libero.</p>
</div>
<div class="box">
<img src="https://dummyimage.com/300x200/f9f9f9/aaa" alt="">
<h2>Title #1</h2>
<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Morbi dui purus, porta sit amet elit ut, pretium dapibus ante. Suspendisse non pharetra odio. Mauris ac placerat libero.</p>
</div>
</div>
</div>
</div>

Making the size of text-box the same as image

I'm trying to fix 2 issues:
The images on the left (sideImage) won't vertically align with the text box when I scale the window down horizontally. I've tried using margin-top auto and margin-bottom auto but that doesn't seem to work to well.
The top div would disappear on top when I scale down the window vertically. (I have no idea why that happened)
I'm using Bootstrap btw, so pls do keep that in mind.
/*-- CSS --*/
* {
background-color: rgba(0, 0, 0, 0.1);
}
html,
body {
height: 100%;
}
body {
display: flex;
align-items: center;
}
.page2Box {
float: left;
display: inline-block;
clear: both;
}
.sideImage {
margin-top: auto !important;
margin-bottom: auto !important;
}
.mainImage {
float: right;
margin-top: auto !important;
margin-bottom: auto !important;
}
p {
height: 180px !important;
overflow: hidden;
}
<!DOCTYPE html>
<html>
<head>
<title>Page2_Bootstrap</title>
<link rel="stylesheet" type="text/css" href="style.css">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css">
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.2.0/jquery.min.js"></script>
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min.js"></script>
</head>
<body>
<div class="container-fluid bigBox col-md-8">
<div class="container page2Box col-md-12" id="box1">
<h2 class="col-md-5">Main Goal</h2>
<p class="col-md-8">Lorem ipsum dolor sit amet, consectetur adipiscing elit. Mauris ultrices urna in dui laoreet rhoncus. Vestibulum posuere mollis velit. Morbi elementum placerat erat.</p>
</div>
<div class="container page2Box col-md-4" <div class="container page2Box col-md-12" id="box2">
<img class="image-responsive sideImage col-md-4" src="placeholder.png">
<h2 class="col-md-5">Who We Are</h2>
<p class="col-md-8">Lorem ipsum dolor sit amet, consectetur adipiscing elit. Mauris ultrices urna in dui laoreet rhoncus. Vestibulum posuere mollis velit. Morbi elementum placerat erat.</p>
</div>
<div class="container page2Box col-md-12" id="box3">
<img class="image-responsive sideImage col-md-4" src="placeholder.png">
<h2 class="col-md-5">What We Do</h2>
<p class="col-md-8">Lorem ipsum dolor sit amet, consectetur adipiscing elit. Mauris ultrices urna in dui laoreet rhoncus. Vestibulum posuere mollis velit. Morbi elementum placerat erat.</p>
</div>
</div>
<image class="image-responsive col-md-4 mainImage" src="placeholder.png">
</body>
</html>
This is how it looks like.
Here are the problems.
I would suggest using the flex-box option while nesting the image and text in separate divs. I.E.
HTML:
<div class="container">
<div class="row equal">
<div class="col-md-6 col-sm-6">
<div class="box">
<img class="image-responsive" src="http://via.placeholder.com/350x150" />
</div>
</div>
<div class="col-md-6 col-sm-6">
<div class="box">
<h2>Main Goal</h2>
<p>In iaculis elit id odio malesuada, vitae euismod dui viverra. Maecenas pulvinar quis magna in dapibus. Ut eget elit eget nibh eleifend ultricies a a orci. Aliquam tristique nulla eu sapien posuere egestas. </p>
</div>
</div>
</div>
</div>
CSS:
.row {
display: -webkit-box;
display: -webkit-flex;
display: -ms-flexbox;
display: flex;
flex-wrap: wrap;
}
.row > [class*='col-'] {
display: flex;
flex-direction: column;
border: 1px solid #333;
}
JSFiddle: https://jsfiddle.net/Jabideau/rkzafmrb/