I am trying to create 3 columns that have 5px gaps between.
I got the looks right but not one next to each other.
<!doctype html>
<html>
<head>
<meta charset="utf-8">
<title>index</title>
<link href="style.css" rel="stylesheet" type="text/css">
</head>
<style>
* {
box-sizing:content-box;
}
#header{text-align: right;
font-weight:bold;
background-color: red}
.row:{
display: ;
clear: both;}
.header{
text-align: center}
.left-col{
background-color: #808080;
col
column-gap: 10px;
width: 33.33%;
left: 0%;
right: auto;
}
.center-col{
background-color:#909090;
column-gap: 10px;
width: 33.33%;
float:none
}
.right-col{
background-color: #909090;
column-gap: 10px;
width: 33.33%;
float:right;
}
<body>
<div class="header">
<h1>Our Menu</h1>
</div>
<div class="row">
<div class="left-col">
<div id="header">Chicken</div>
<p>Suculent chicken thighs. They been marinaded in youghurt with corriander and dried chilly flakes for 12 hours, to make juicy we bursting them wist cpecial house flavouring over the grill using bouqet garnet. One of our house specialites!Enjoy</p>
</div>
<div class="center-col">
<div id="header" >Beef</div>
<p>Sticky beef with with smokey coca cola bbq sauce. We slow roasting topside beef in clay oven for 6 hours. Sauce contain coca cola and fruit juices, for the peppery taste we use blend of 4 different peppers. If you like it mild hot dishes try this one!</p>
</div>
<div class="right-col">
<div id="header">Sushi</div>
<p>Ceviche. Like honest Peruvian cooking ceviche fruits and loads of citrus to cook fish in. Combination of avocado, mango and red onions with thinly sliced jalapeno will make you excited about this fragrant fresh dish please make sure you try it as your starter!</p>
</div>
</body>
</html>
Try this, change the color and text according to your need. Please complete your Responsive Web Design curriculum it will help you in this.
<div class="container">
<div id="one">
<div class="title">Title</div>
<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.</p>
</div>
<div id="two">
<div class="title">Title</div>
<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.</p>
</div>
<div id="three">
<div class="title">Title</div>
<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.</p>
</div>
</div>
.container {
display: flex;
justify-content: space-between;
height: 200px;
}
#one {
display: flex;
flex-direction: column;
width: 33%;
height: 100%;
background-color: red;
}
.title {
display: flex;
align-self: flex-end;
width: 30%;
justify-content: center;
background-color: grey;
}
#two {
display: flex;
flex-direction: column;
width: 33%;
height: 100%;
background-color: blue;
}
#three {
display: flex;
flex-direction: column;
width: 33%;
height: 100%;
background-color: yellow;
}