how to get circular menu (incl. hover + link functionality) fully responsive? - html

I am trying to get a circular menu (incl. hover + link functionality) to behave fully responsible.
The hovering and linking part basically is working fine.
Without the hovering part, the circular menu behaves responsive.
But with the hovering part included, the menu gets squeezed when display/screen width is adjusted.
I have tried the #media approach, setting different width and height in .ch-grid li for different screen widths, but that is not to be considered as a true solution, is merely a temporary workaround.
ul,
li {
list-style: none;
margin: 0;
padding: 0;
}
#test1 {
display: -webkit-flex;
display: flex;
text-align: center;
justify-content: space-between;
margin-bottom: 30px;
margin-left: 35px;
margin-right: 35px;
}
#test2 {
width: 15%;
text-align: center;
position: relative;
border-radius: 50%;
overflow: hidden;
background-color: #ff0082;
}
ul li img {
position: absolute;
width: 100%;
height: 100%;
top: 0;
left: 0;
object-fit: cover;
}
.ch-grid:after,
.ch-item:before {
content: '';
display: table;
}
.ch-grid:after {
clear: both;
}
.ch-grid li {
width: 220px;
height: 90px;
display: inline-block;
}
.ch-item {
width: 100%;
height: 100%;
border-radius: 50%;
overflow: hidden;
position: relative;
cursor: default;
box-shadow: inset 0 0 0 16px rgba(255, 255, 255, 0.6), 0 1px 2px rgba(0, 0, 0, 0.1);
transition: all 0.4s ease-in-out;
}
.ch-info {
position: absolute;
background: rgba(63, 147, 147, 0.8);
width: inherit;
height: inherit;
border-radius: 50%;
overflow: hidden;
opacity: 0;
transition: all 0.4s ease-in-out;
transform: scale(0);
}
.ch-info p {
color: #fff;
padding: 13px 0px;
font-style: normal;
font-size: 9px;
border-top: 1px solid rgba(255, 255, 255, 0.5);
opacity: 0;
transition: all 1s ease-in-out 0.4s;
}
.ch-info p a {
display: block;
color: rgba(255, 255, 255, 0.7);
font-style: normal;
font-weight: 700;
font-size: 140%;
letter-spacing: 1px;
padding-top: 4px;
font-family: 'Open Sans', Arial, sans-serif;
}
.ch-info p a:hover {
color: rgba(255, 242, 34, 0.8);
}
.ch-item:hover {
box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.1), 0 1px 2px rgba(0, 0, 0, 0.1);
}
.ch-item:hover .ch-info {
transform: scale(1);
opacity: 1;
}
.ch-item:hover .ch-info p {
opacity: 1;
}
<ul id="test1" class="ch-grid">
<li id="test2">
<div class="ch-item">
<img src="https://gespreksmakers.nl/images/1_hansie_hansumus.jpg" />
<div class="ch-info">
<p>Hansie<BR>Hansumus</p>
</div>
</div>
</li>
<li id="test2">
<div class="ch-item">
<img src="https://gespreksmakers.nl/images/1_missie_marble.jpg" />
<div class="ch-info">
<p>Missie<BR>Marble</p>
</div>
</div>
</li>
<li id="test2">
<div class="ch-item">
<img src="https://gespreksmakers.nl/images/1_piotr_linski.jpg" />
<div class="ch-info">
<p>Piotr<BR>Linski</p>
</div>
</div>
</li>
<li id="test2">
<div class="ch-item">
<img src="https://gespreksmakers.nl/images/1_red.jpg" />
<div class="ch-info">
<p>Mister<BR>Red</p>
</div>
</div>
</li>
<li id="test2">
<div class="ch-item">
<img src="https://gespreksmakers.nl/images/1_green.jpg" />
<div class="ch-info">
<p>Miss<BR>Green</p>
</div>
</div>
</li>
<li id="test2">
<div class="ch-item">
<img src="https://gespreksmakers.nl/images/1_blue.jpg" />
<div class="ch-info">
<p>Mister<BR>Blue</p>
</div>
</div>
</li>
</ul>
A fiddle, showing the present CSS- and HTML-code can be found here: https://jsfiddle.net/piotrlinski/b3tL9v4h/8/
Any suggestions how to solve?

The class attribute can be used with multiple HTML elements/tags and
all will take the effect. Where as the id is meant for a single
element/tag and is considered unique. Moreoever the id has a higher
specificity value than the class.
Responsive image:
.img-responsive {
display: block;
max-width: 100%;
height: auto;
}
An unordered list:
<ul class="thumbnails">
<li>Thumbnail 1</li>
<li>Thumbnail 2</li>
<li>...</li>
</ul>
List unstyled in one line with display: flex:
.thumbnails {
display: flex;
list-style: none;
...
}
Structure of a thumbnail
<a href="https://nkbv.nl" class="thumbnail">
<img src = "https://gespreksmakers.nl/images/1_hansie_hansumus.jpg"/>
<div class="overlay">
<p class="text">Mister White</p>
</div>
</a>
where .thumbnail has position: relative and .overlay has position: absolute so that .overlay is in the same area as .thumbnail.
Make font size responsive with vw.
A modified and clear solution
.thumbnails {
display: flex;
list-style: none;
padding: 0 2vw;
}
.thumbnails>li {
flex: 1 0;
margin: 0 5px;
text-align: center;
line-height: 0;
}
.thumbnail,
.thumbnail>img,
.thumbnail>.overlay {
border-radius: 50%;
}
.thumbnail {
position: relative;
display: inline-block;
cursor: pointer;
}
/* Responsive images */
.thumbnail>img {
display: block;
max-width: 100%;
height: auto;
}
.thumbnail>.overlay {
background: rgba(63, 147, 147, 0.8);
opacity: 0.7;
position: absolute;
top: 0;
height: 100%;
width: 100%;
transform: scale(0);
display: flex;
flex-direction: column;
justify-content: center;
text-align: center;
transition: all 0.4s ease-in-out;
}
.thumbnail>.overlay>.text {
color: white;
width: 66.66%;
line-height: 100%;
margin: 0 auto;
padding: 5px 0;
border-bottom: 1px solid;
border-top: 1px solid;
font-size: 1.85vw;
transition: opacity 1s ease-in-out 0.4s;
opacity: 0;
}
.thumbnail:hover>.overlay {
transform: scale(1);
}
.thumbnail:hover>.overlay>.text {
opacity: 1;
}
<ul class="thumbnails">
<li>
<a href="https://nkbv.nl" class="thumbnail">
<img src="https://gespreksmakers.nl/images/1_hansie_hansumus.jpg" />
<div class="overlay">
<p class="text">Mister White</p>
</div>
</a>
</li>
<li>
<a href="https://kakivi.de" class="thumbnail">
<img src="https://gespreksmakers.nl/images/1_missie_marble.jpg" />
<div class="overlay">
<p class="text">Mister White</p>
</div>
</a>
</li>
<li>
<a href="https://telegraaf.nl" class="thumbnail">
<img src="https://gespreksmakers.nl/images/1_piotr_linski.jpg" />
<div class="overlay">
<p class="text">Mister White</p>
</div>
</a>
</li>
<li>
<a href="https://www.tukhut.nl" class="thumbnail">
<img src="https://gespreksmakers.nl/images/1_red.jpg" />
<div class="overlay">
<p class="text">Mister White</p>
</div>
</a>
</li>
<li>
<a href="https://www.alumnei.nl" class="thumbnail">
<img src="https://gespreksmakers.nl/images/1_green.jpg" />
<div class="overlay">
<p class="text">Mister White</p>
</div>
</a>
</li>
<li>
<a href="https://www.astronieuws.nl" class="thumbnail">
<img src="https://gespreksmakers.nl/images/1_blue.jpg" />
<div class="overlay">
<p class="text">Mister White</p>
</div>
</a>
</li>
</ul>

You may check my code below though I have made kind of lots of changes.
Some tips:
IDs must be unique in the HTML document, so you should not use an ID more than once (e.g. #test2).
Also, it is better to use the classes you created to style your document, rather than the IDs (e.g. #test1, #test2 could be replaced by .ch-grid and .ch-grid li, respectively).
<style>
ul,
li {
list-style: none;
margin: 0;
padding: 0;
}
.ch-grid {
display: -webkit-flex;
display: flex;
flex-wrap: wrap;
text-align: center;
}
.ch-grid:after,
.ch-item:before {
content: "";
display: table;
}
.ch-grid:after {
clear: both;
flex: auto;
}
.ch-grid li {
flex: 1;
display: inline-block;
min-width: calc(100% / 6);
max-width: calc(100% / 6);
position: relative;
background-color: #ff0082;
overflow: hidden;
border-radius: 50%;
text-align: center;
}
.ch-grid li img {
width: 100%;
height: 100%;
object-fit: cover;
position: relative;
z-index: 10;
}
.ch-item {
position: relative;
width: 100%;
height: 100%;
border-radius: 50%;
overflow: hidden;
cursor: default;
box-shadow: inset 0 0 0 16px rgba(255, 255, 255, 0.6),
0 1px 2px rgba(0, 0, 0, 0.1);
transition: all 0.3s ease-in-out;
}
.ch-info {
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
display: -webkit-flex;
display: flex;
flex-direction: column;
justify-content: center;
background: rgba(63, 147, 147, 0.8);
border-radius: 50%;
overflow: hidden;
opacity: 0;
transition: all 0.4s ease-in-out;
transform: scale(0);
z-index: 20;
}
.ch-info p {
color: #fff;
padding: 13px 0px;
font-style: normal;
font-size: 9px;
border-top: 1px solid rgba(255, 255, 255, 0.5);
opacity: 0;
transition: all 1s ease-in-out 0.4s;
}
.ch-info p a {
display: block;
color: rgba(255, 255, 255, 0.7);
font-style: normal;
font-weight: 700;
font-size: 140%;
letter-spacing: 1px;
padding-top: 4px;
font-family: "Open Sans", Arial, sans-serif;
}
.ch-info p a:hover {
color: rgba(255, 242, 34, 0.8);
}
.ch-item:hover {
box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.1),
0 1px 2px rgba(0, 0, 0, 0.1);
}
.ch-item:hover .ch-info {
transform: scale(1);
opacity: 1;
}
.ch-item:hover .ch-info p {
opacity: 1;
}
#media (max-width: 767px) {
.ch-grid li {
min-width: calc(100% / 3);
max-width: calc(100% / 3);
}
}
</style>

If you set width over percentage, the list items will not seem as a circle depending the screen width. Because of this situation, you should set fixed width to the list items and set wrap to parent as you can see below:
#test1 {
display: -webkit-flex;
display: flex;
text-align: center;
justify-content: space-between;
flex-wrap: wrap;
margin-bottom: 30px;
margin-left: 35px;
margin-right: 35px;
}
#test2 {
flex-basis: 85px;
text-align: center;
position: relative;
border-radius: 50%;
overflow: hidden;
background-color: #ff0082;
}

Related

Why is there white space on the bottom of the web page

The white space is visible when I select a height over 20px at the last CSS Element. The
class "roadmap-box"
Near the bottom of the HTML Body Element. The top white box is the "roadmap-box" Click here to see the image
Whenever I try to adjust the height, the top white box becomes bigger, but also the white box at the bottom grows in size. I dont know how to fix that.
* {
margin: 0;
padding: 0;
font-family: sans-serif;
}
.banner {
width: 100%;
height: 100vh;
background-image: linear-gradient(rgba(0, 0, 0, 0.65), rgba(0, 0, 0, 0.5)), url(Background/3.jpg);
background-size: cover;
background-position: center;
padding-bottom: 2100px;
}
.navbar {
width: 85%;
margin: auto;
padding: 35px 0;
display: flex;
align-items: center;
justify-content: space-between;
}
.profile-signature {
width: 300px;
object-position: top;
object-fit: contain;
display: flex;
justify-content: center;
align-items: center;
cursor: pointer;
}
.navbar ul li {
list-style: none;
display: inline-block;
margin: 0 20px;
position: relative;
}
.navbar ul li a {
text-decoration: none;
color: #fff;
text-transform: uppercase;
}
.navbar ul li::after {
content: '';
height: 3px;
width: 0;
background: #009688;
position: absolute;
left: 0;
bottom: -10px;
transition: 0.5s;
}
.navbar ul li:hover::after {
width: 100%;
}
.profile-picture {
border-radius: 50%;
width: 150px;
height: 150px;
object-fit: cover;
cursor: pointer;
box-shadow: 16px 16px 32px rgba(255, 255, 255, 0.3), -16px -16px 32px rgba(255, 255, 255, 0.3);
transition: 0.5s;
}
.profile-picture:hover {
width: 275px;
height: 275px;
transform: translateY(-25px);
transition: 0.5s;
}
.content {
width: 100%;
position: absolute;
top: 60;
transform: translateY(25px);
text-align: center;
color: white;
}
.content h1 {
font-size: 70px;
margin-top: 60px;
}
.content p {
margin: 20px auto;
font-weight: 100;
line-height: 25px;
}
button {
width: 200px;
padding: 15px 0;
text-align: center;
margin: 20px 10px;
border-radius: 25px;
font-weight: bold;
border: 2px solid #009688;
background: transparent;
color: white;
cursor: pointer;
position: relative;
overflow: hidden;
}
span {
background: #009688;
height: 100%;
width: 0;
border-radius: 25px;
position: absolute;
left: 0;
bottom: 0;
z-index: -1;
transition: 0.5s;
}
button:hover span {
width: 100%;
}
button:hover {
border: none
}
.text-box {
height: 600px;
border: 3px;
border-style: none;
border-color: rgba(255, 255, 255, 0.3);
transform: translateY(500px);
display: flex;
justify-content: space-around;
}
.images-box1 {
background-color: rgba(68, 218, 185, 0.05);
border-radius: 77px;
width: 375px;
height: 628px;
border: 5px;
border-color: #1f534f;
border-style: solid none;
align-items: center;
cursor: pointer;
z-index: -1;
transition: 0.7s;
}
.images-box1:hover {
background: rgb(152, 152, 152);
background: linear-gradient(3deg, rgba(152, 152, 152, 0) 0%, rgba(255, 255, 255, 0.3113620448179272) 100%);
height: 300px;
margin-top: 20px;
background: #009688;
transition: 0.7s;
}
.text-image {
border-radius: 75px;
width: 375px;
height: 300px;
display: flex;
justify-content: left;
align-items: center;
flex-direction: column;
object-fit: cover;
object-position: middle;
}
.text-title-box1 {
text-align: start;
margin-top: 10px;
text-align: center;
}
p {
padding-top: 20px;
transition: 0.5s;
}
p:hover {
transition: 0.5s;
}
.bottom-parent {
position: relative;
}
.bottom {
display: block;
width: 100%;
position: absolute;
bottom: 0;
height: 45px;
background-color: rgb(21, 105, 87);
}
.text-bottom {
display: flex;
justify-content: center;
text-indent: 20px;
padding-right: 20px;
padding-top: 13px;
color: white;
}
.twitter-hover {
text-decoration: none;
color: white;
}
.twitter-hover:hover {
text-decoration: underline;
color: rgba(255, 255, 255, 0.685);
}
.linkedin-hover {
text-decoration: none;
color: white;
}
.linkedin-hover:hover {
text-decoration: underline;
color: rgba(255, 255, 255, 0.685);
}
.instagram-hover {
text-decoration: none;
color: white;
}
.instagram-hover:hover {
text-decoration: underline;
color: rgba(255, 255, 255, 0.685);
}
.impressum:hover {
cursor: pointer;
text-decoration: underline;
color: rgba(255, 255, 255, 0.685);
}
.roadmap-box {
width: 100%;
height: 50px;
background-color: white;
transform: translateY(-500px);
}
<div class="banner">
<div class="navbar">
<img class="profile-signature" src="Logo/logo-1.png" alt="Profile Logo">
<ul>
<li>HOME</li>
<li>PORTFOLIO</li>
<li>GAMES</li>
<li>SOCIALS</li>
<li>CONTACT</li>
</ul>
</div>
<div class="content">
<a href="https://google.com/" target="_blank">
<img class="profile-picture" src="Logo/logo-2.jpg" alt="Profile Picture">
</a>
<h1>WELCOME TO PARADISE!</h1>
<p>This is a practice website. There's just a bit of text here to fill the lines, blah blah blah.
<br>If you want to know more about me, just have a look around</p>
<div>
<a href="https://google.com/" target="_blank">
<button type="button" href="#middle"><span></span>PORTFOLIO</button>
</a>
<a href="https://twitter.com/" target="_blank">
<button type="button"><span></span>SOCIALS</button>
</a>
</div>
<div class="text-box">
<div class="images-box1">
<img src="designs/1.jpg" class="text-image">
<div>
<h2 class="text-title-box1">Random Design 1</h1>
<p></p>
</div>
</div>
<div class="images-box1">
<img src="designs/2.jpg" class="text-image">
<div>
<h2 class="text-title-box1">Fantasy Shower</h1>
<p>Well, nothing much to explain here. <br> <br> I need some text so have run reading <br> blah blah blah again <br> <br>:)</p>
</div>
</div>
<div class="images-box1">
<img src="designs/3.jpg" class="text-image">
<div>
<h2 class="text-title-box1">Light Bulb Girl</h1>
<p>This image was created 2020. <br> It shows a person beeing stuck inside a lightbulb. Funny right? No deeper <br> intentions, dont look for them, <br> lol</p>
</div>
</div>
<div class="images-box1">
<img src="designs/4.jpg" class="text-image">
<div>
<h2 class="text-title-box1">Random Design 4</h1>
<p>Test</p>
</div>
</div>
</div>
</div>
</div>
<div class="code-image-box">
<div class="code-image">
</div>
</div>
<div class="roadmap-box">
<div class="q1"></div>
<div class="q2"></div>
</div>
<div class="bottom-parent">
<div class="bottom">
<div class="text-bottom">
<a class="twitter-hover" href="https:/twitter.com/" target="_blank">
<div class="twitter">Twitter</div>
</a>
<a class="linkedin-hover" href="https:/linkedin.com/" target="_blank">
<div class="linkedin">LinkedIn</div>
</a>
<a class="instagram-hover" href="https:/instagram.com/" target="_blank">
<div class="instagram">Instagram</div>
</a>
<div class="impressum">Impressum</div>
</a>
</div>
</div>
</div>
The div with class .roadmap-box has been translatedY(-500px) but the browser has still made the space available for it as it's a block-level element. If you hide it then the gap disappears. What's the purpose of it? What are you trying to do with it?
See example below. There's also no need to make .bottom position:absoute as it then gives the div .bottom-parent no height. See modified markup below.
* {
margin: 0;
padding: 0;
font-family: sans-serif;
}
.banner {
width: 100%;
height: 100vh;
background-image: linear-gradient(rgba(0, 0, 0, 0.65), rgba(0, 0, 0, 0.5)), url(Background/3.jpg);
background-size: cover;
background-position: center;
padding-bottom: 2100px;
}
.navbar {
width: 85%;
margin: auto;
padding: 35px 0;
display: flex;
align-items: center;
justify-content: space-between;
}
.profile-signature {
width: 300px;
object-position: top;
object-fit: contain;
display: flex;
justify-content: center;
align-items: center;
cursor: pointer;
}
.navbar ul li {
list-style: none;
display: inline-block;
margin: 0 20px;
position: relative;
}
.navbar ul li a {
text-decoration: none;
color: #fff;
text-transform: uppercase;
}
.navbar ul li::after {
content: '';
height: 3px;
width: 0;
background: #009688;
position: absolute;
left: 0;
bottom: -10px;
transition: 0.5s;
}
.navbar ul li:hover::after {
width: 100%;
}
.profile-picture {
border-radius: 50%;
width: 150px;
height: 150px;
object-fit: cover;
cursor: pointer;
box-shadow: 16px 16px 32px rgba(255, 255, 255, 0.3), -16px -16px 32px rgba(255, 255, 255, 0.3);
transition: 0.5s;
}
.profile-picture:hover {
width: 275px;
height: 275px;
transform: translateY(-25px);
transition: 0.5s;
}
.content {
width: 100%;
position: absolute;
top: 60;
transform: translateY(25px);
text-align: center;
color: white;
}
.content h1 {
font-size: 70px;
margin-top: 60px;
}
.content p {
margin: 20px auto;
font-weight: 100;
line-height: 25px;
}
button {
width: 200px;
padding: 15px 0;
text-align: center;
margin: 20px 10px;
border-radius: 25px;
font-weight: bold;
border: 2px solid #009688;
background: transparent;
color: white;
cursor: pointer;
position: relative;
overflow: hidden;
}
span {
background: #009688;
height: 100%;
width: 0;
border-radius: 25px;
position: absolute;
left: 0;
bottom: 0;
z-index: -1;
transition: 0.5s;
}
button:hover span {
width: 100%;
}
button:hover {
border: none
}
.text-box {
height: 600px;
border: 3px;
border-style: none;
border-color: rgba(255, 255, 255, 0.3);
transform: translateY(500px);
display: flex;
justify-content: space-around;
}
.images-box1 {
background-color: rgba(68, 218, 185, 0.05);
border-radius: 77px;
width: 375px;
height: 628px;
border: 5px;
border-color: #1f534f;
border-style: solid none;
align-items: center;
cursor: pointer;
z-index: -1;
transition: 0.7s;
}
.images-box1:hover {
background: rgb(152, 152, 152);
background: linear-gradient(3deg, rgba(152, 152, 152, 0) 0%, rgba(255, 255, 255, 0.3113620448179272) 100%);
height: 300px;
margin-top: 20px;
background: #009688;
transition: 0.7s;
}
.text-image {
border-radius: 75px;
width: 375px;
height: 300px;
display: flex;
justify-content: left;
align-items: center;
flex-direction: column;
object-fit: cover;
object-position: middle;
}
.text-title-box1 {
text-align: start;
margin-top: 10px;
text-align: center;
}
p {
padding-top: 20px;
transition: 0.5s;
}
p:hover {
transition: 0.5s;
}
.bottom-parent {
position: relative;
}
.bottom {
display: block;
width: 100%;
/* position: absolute; */
bottom: 0;
height: 45px;
background-color: rgb(21, 105, 87);
}
.text-bottom {
display: flex;
justify-content: center;
text-indent: 20px;
padding-right: 20px;
padding-top: 13px;
color: white;
}
.twitter-hover {
text-decoration: none;
color: white;
}
.twitter-hover:hover {
text-decoration: underline;
color: rgba(255, 255, 255, 0.685);
}
.linkedin-hover {
text-decoration: none;
color: white;
}
.linkedin-hover:hover {
text-decoration: underline;
color: rgba(255, 255, 255, 0.685);
}
.instagram-hover {
text-decoration: none;
color: white;
}
.instagram-hover:hover {
text-decoration: underline;
color: rgba(255, 255, 255, 0.685);
}
.impressum:hover {
cursor: pointer;
text-decoration: underline;
color: rgba(255, 255, 255, 0.685);
}
.roadmap-box {
width: 100%;
height: 50px;
background-color: white;
display: none;
/*transform: translateY(-500px);*/
}
<div class="banner">
<div class="navbar">
<img class="profile-signature" src="Logo/logo-1.png" alt="Profile Logo">
<ul>
<li>HOME</li>
<li>PORTFOLIO</li>
<li>GAMES</li>
<li>SOCIALS</li>
<li>CONTACT</li>
</ul>
</div>
<div class="content">
<a href="https://google.com/" target="_blank">
<img class="profile-picture" src="Logo/logo-2.jpg" alt="Profile Picture">
</a>
<h1>WELCOME TO PARADISE!</h1>
<p>This is a practice website. There's just a bit of text here to fill the lines, blah blah blah.
<br>If you want to know more about me, just have a look around
</p>
<div>
<a href="https://google.com/" target="_blank">
<button type="button" href="#middle"><span></span>PORTFOLIO</button>
</a>
<a href="https://twitter.com/" target="_blank">
<button type="button"><span></span>SOCIALS</button>
</a>
</div>
<div class="text-box">
<div class="images-box1">
<img src="designs/1.jpg" class="text-image">
<div>
<h2 class="text-title-box1">Random Design 1</h1>
<p></p>
</div>
</div>
<div class="images-box1">
<img src="designs/2.jpg" class="text-image">
<div>
<h2 class="text-title-box1">Fantasy Shower</h1>
<p>Well, nothing much to explain here. <br> <br> I need some text so have run reading <br> blah blah blah again <br> <br>:)</p>
</div>
</div>
<div class="images-box1">
<img src="designs/3.jpg" class="text-image">
<div>
<h2 class="text-title-box1">Light Bulb Girl</h1>
<p>This image was created 2020. <br> It shows a person beeing stuck inside a lightbulb. Funny right? No deeper <br> intentions, dont look for them, <br> lol</p>
</div>
</div>
<div class="images-box1">
<img src="designs/4.jpg" class="text-image">
<div>
<h2 class="text-title-box1">Random Design 4</h1>
<p>Test</p>
</div>
</div>
</div>
</div>
</div>
<div class="code-image-box">
<div class="code-image">
</div>
</div>
<div class="roadmap-box">
<div class="q1"></div>
<div class="q2"></div>
</div>
<div class="bottom-parent">
<div class="bottom">
<div class="text-bottom">
<a class="twitter-hover" href="https:/twitter.com/" target="_blank">
<div class="twitter">Twitter</div>
</a>
<a class="linkedin-hover" href="https:/linkedin.com/" target="_blank">
<div class="linkedin">LinkedIn</div>
</a>
<a class="instagram-hover" href="https:/instagram.com/" target="_blank">
<div class="instagram">Instagram</div>
</a>
<div class="impressum">Impressum</div>
</a>
</div>
</div>
</div>

Why can't i align the div that contains text next to the div that contains the image

i'm currently working on a webpage for my design class and i have a problem. This is the browser view:
I am kinda new with html and css but i have tried display in-line block, flex... Nothing worked, and i dont know what else i could do
So the problem is that the text "aaaaa" must be next to image. Here is my html code:
.caixa {
word-wrap: break-word;
width: 70%;
box-shadow: 2px 2px 30px rgba(0, 0, 0, 0.2);
margin: 25px;
margin-left: 0px;
border-radius: 10px;
}
.caixa-img {
display: inline-block;
margin: 15px;
width: 15%;
position: relative;
}
.caixa-img img {
margin-right: 120px;
border-radius: 10px;
width: 100%;
height: 100%;
}
.info {
width: 100%;
padding: 10px 20px;
}
.tipo {}
.descripcio {
display: block;
background-color: chartreuse;
}
.tipo a {
color: #222222;
margin: 5px 0px;
font-weight: 700;
letter-spacing: 0.5px;
padding-right: 8px;
}
.tipo span {
color: rgba(26, 26, 26, 0.5);
}
.preu {
color: #333333;
font-weight: 600;
font-size: 1.1rem;
font-family: poppins;
letter-spacing: 0.5px;
}
.overlay {
position: absolute;
left: 50%;
top: 50%;
transform: translate(-50%, -50%);
width: 100%;
height: 100%;
background-color: rgba(226, 197, 88, 0.6);
display: flex;
justify-content: center;
align-items: center;
}
.comprar {
width: 160px;
height: 40px;
display: flex;
justify-content: center;
align-items: center;
background-color: #FFFFFF;
color: #252525;
font-weight: 700;
letter-spacing: 1px;
font-family: calibri;
border-radius: 20px;
box-shadow: 2px 2px 30px rgba(0, 0, 0, 0.2);
}
.comprar:hover {
color: #FFFFFF;
background-color: rgb(248, 171, 55);
transition: all ease 0.3s;
}
.overlay {
visibility: hidden;
}
.caixa-img:hover .overlay {
visibility: visible;
animation: fade 0.5s;
}
#keyframes fade {
0% {
opacity: 0;
}
100% {
opacity: 1;
}
}
<div class="col-12 productes">
<div class="producte1">
<div class="caixa">
<div class="caixa-img">
<img alt="" src="imgExplora/imgCarrousel/herbicida.jpg">
<div class="overlay">
Comprar
</div>
<div class="tipo">
<a href="#">
<h3>HERBICIDA</h3>
</a>
<!--
<div class="rating">
<span>☆</span><span>☆</span><span>☆</span><span>☆</span><span>☆</span>
</div>-->
</div>
55€
</div>
<div class="info">
<span class="descripcio">aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa</span>
</div>
</div>
</div>
</div>
Below an example using flexbox (see .caixa).
.caixa {
width: 70%;
box-shadow: 2px 2px 30px rgba(0, 0, 0, 0.2);
margin: 25px 25px 25px 0;
/* margin-left: 0px; */
border-radius: 10px;
display: flex; /* Added */
}
.caixa-img {
margin: 15px;
width: 30%;
}
.caixa-img img {
border-radius: 10px;
width: 125px; /* For demo */
height: 125px; /* For demo */
}
.info {
width: 100%;
padding: 10px 20px;
}
.tipo {}
.descripcio {
display: block;
background-color: chartreuse;
word-break: break-all; /* Essential to break large words */
}
.tipo a {
color: #222222;
margin: 5px 0px;
font-weight: 700;
letter-spacing: 0.5px;
padding-right: 8px;
}
.tipo span {
color: rgba(26, 26, 26, 0.5);
}
.preu {
color: #333333;
font-weight: 600;
font-size: 1.1rem;
font-family: poppins;
letter-spacing: 0.5px;
}
.overlay {
position: absolute;
left: 50%;
top: 50%;
transform: translate(-50%, -50%);
width: 100%;
height: 100%;
background-color: rgba(226, 197, 88, 0.6);
display: flex;
justify-content: center;
align-items: center;
}
.comprar {
width: 160px;
height: 40px;
display: flex;
justify-content: center;
align-items: center;
background-color: #FFFFFF;
color: #252525;
font-weight: 700;
letter-spacing: 1px;
font-family: calibri;
border-radius: 20px;
box-shadow: 2px 2px 30px rgba(0, 0, 0, 0.2);
}
.comprar:hover {
color: #FFFFFF;
background-color: rgb(248, 171, 55);
transition: all ease 0.3s;
}
.overlay {
visibility: hidden;
}
.caixa-img:hover .overlay {
visibility: visible;
animation: fade 0.5s;
}
#keyframes fade {
0% {
opacity: 0;
}
100% {
opacity: 1;
}
}
<div class="col-12 productes">
<div class="producte1">
<div class="caixa">
<div class="caixa-img">
<img alt="" src="imgExplora/imgCarrousel/herbicida.jpg">
<div class="overlay">
Comprar
</div>
<div class="tipo">
<a href="#">
<h3>HERBICIDA</h3>
</a>
</div>
55€
</div>
<div class="info">
<span class="descripcio">aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa</span>
</div>
</div>
</div>
</div>
if you use boostrap framework
you can use the bootstrap column and row.
<!-- language: lang-html -->
<div class="row">
<div class="col-6 productes">
<div class="producte1">
<div class="caixa">
<div class="caixa-img">
<img alt="" src="imgExplora/imgCarrousel/herbicida.jpg">
<div class="overlay">
Comprar
</div>
</div>
<div class="col-6">
<div class="tipo">
<a href="#">
<h3>HERBICIDA</h3>
</a>
<!--
<div class="rating">
<span>☆</span><span>☆</span><span>☆</span><span>☆</span><span>☆</span>
</div>-->
</div>
55€
</div>
<div class="info">
<span class="descripcio">aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa</span>
</div>
</div>
</div>
</div>
</div>
<!-- end snippet -->
You have too much nested divs that dont need to be there, just making it more complex.
Also, your text is going outside your div borders, this is not a good thing.
You can move your text next to the image by using flex.
You always apply flex on a parent of the element that you want to move around (in this case, div with a picture, and div with a text).
So you are going to apply flex to a div that holds both of those divs (div with image, and div with text).
Here is my solution to this problem on a simple example, it should help you :
https://codepen.io/Juka99/pen/YzGVQyv

Setting modals size to 100%

I have created a modal inside a button-container which utilizes some flex display elements.
The problem occurs when I want to size the .modal-mask to a 100% of width/height to the whole page (body) size which is my goal here, I can't seem to get it to adjust properly without disturbing my button-container elements.
In short, I want the inner div .modal-mask to be sized 100% to the body
Project Fiddle: https://jsfiddle.net/est857q0/
HTML:
<ul id="button-container">
<li>
<a id="html-modal-button" #click="showModal = 'html-modal'">
<img class="htmllogo" src="http://sweettutos.com/wp-content/uploads/2015/12/placeholder.png">
</a>
<htmlmodal v-if="showModal === 'html-modal'" #close="showModal = false"></htmlmodal>
</li>
<li>
<a id="cs-modal-button" #click="showModal = 'cs-modal'">
<img class="csharplogo" src="http://sweettutos.com/wp-content/uploads/2015/12/placeholder.png">
</a>
<csmodal v-if="showModal === 'cs-modal'" #close="showModal = false"></csmodal>
</li>
</ul>
<!-- MODAL SECTION -->
<script type="text/x-template" id="html-modal-template">
<transition name="html-modal">
<div class="modal-mask">
<div class="modal-wrapper">
<div class="modal-container">
<div class="modal-content">
<slot name="body">
<button class="modal-default-button" #click="$emit('close')">HTML CLOSE</button>
</slot>
</div>
</div>
</div>
</div>
</transition>
</script>
<script type="text/x-template" id="cs-modal-template">
<transition name="cs-modal">
<div class="modal-mask">
<div class="modal-wrapper">
<div class="modal-container">
<div class="modal-content">
<slot name="body">
<button class="modal-default-button" #click="$emit('close')">CS CLOSE</button>
</slot>
</div>
</div>
</div>
</div>
</transition>
</script>
CSS:
/*Global*/
html {
margin-right: calc(100% - 100vw);
/*overflow: hidden;*/
}
body {
margin: 0 auto;
background-image: url('../images/wallpaper.jpg');
font-family: 'Josefin Sans', sans-serif;
}
*::selection {
background-color: red;
}
/*Header*/
h1 {
text-transform: uppercase;
width: 100%;
font-size: 9vw;
text-align: center;
margin-top: 4vh;
}
/*Containers*/
#button-container {
padding: 0;
margin: 0;
list-style: none;
display: flex;
-webkit-flex-flow: row wrap;
justify-content: space-around;
margin-top: 40vh;
margin-left: 50vw;
transform: translate(-50%, -70%);
width: 90vw;
height: 45vh;
align-items: baseline;
background: linear-gradient(to right, transparent 0%, #fff 33%, #fff 66%, transparent 100%);
}
#button-container li {
position: relative;
display: inline-block;
cursor: pointer;
}
#button-container .html-text-block,
.cs-text-block {
position: absolute;
bottom: 4px;
width: 100%;
height: 30%;
box-sizing: border-box;
background-color: #fff;
padding-left: 5px;
box-shadow: 0 3px 6px rgba(0, 0, 0, 0.16), 0 3px 6px rgba(0, 0, 0, 0.23);
transition: box-shadow 0.5s cubic-bezier(.25, .8, .25, 1), transform 0.5s cubic-bezier(.25, .8, .25, 1);
}
#button-container .htmllogo,
#button-container .csharplogo {
width: 150px;
}
#button-container {
border: 1px solid #000;
}
img:hover {
transform: scale(1.1);
}
/* THE MODAL CSS SECTION */
/*Main Modal container*/
.modal-mask {
position: fixed;
z-index: 9998;
top: 0;
left: 0;
width: 100%;
height: 100%;
background-color: rgba(0, 0, 0, .5);
display: table;
transition: opacity .3s ease;
}
.modal-wrapper {
display: table-cell;
vertical-align: middle;
}
.modal-container {
width: 300px;
margin: 0px auto;
padding: 20px 30px;
background-color: #fff;
border-radius: 2px;
box-shadow: 0 2px 8px rgba(0, 0, 0, .33);
transition: all .3s ease;
font-family: Helvetica, Arial, sans-serif;
}
.modal-content {
margin: 20px 0;
}
I attempted to set the button-container too 100% : https://jsfiddle.net/est857q0/ yet this messes up the flow

divider not showing with onhover effects

I am just attempting a simple fix. For some reason my divider isn't showing up on hover? How can I get it to show up like the other text does? I have another example of how i got the divider to look on other pages...
http://runningfish.net/finestc/about/
Right underneath the header of the page that says "About"
Also, what I am currently working with is runningfish.net/finestc
You can see the live code there right underneath the section that says "Recent Sales".
I am still a fledgling coder so if I am doing something inefficiently or could be doing better that you notice, please point it out! I want to get better at coding. Critique welcome!
Thanks!
.grids {
width: 33.33%;
float: left;
display: inline-block;
position: relative;
}
.grids img {
display: block;
height: 33.33vh;
width: 100%;
}
.grid-image-description {
position: absolute;
top: 0;
bottom: 0;
left: 0;
right: 0;
background: rgba(0, 0, 0, 0.6);
color: #fff;
visibility: hidden;
opacity: 0;
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
transition: opacity .5s, visibility .5s;
}
.grid-image-description h2 {
font-family: playfairdisplay;
font-size: 1.7em;
color: #fff;
}
.grid-image-description p {
font-family: playfairdisplay;
font-size: 1.0em;
color: #fff;
}
.grid-image-description hr {
border-top: 1px;
border-color: #001532;
border-style: solid;
box-shadow: 2px 1px 15px #fff;
margin: 0 0 0 10px;
max-width: 200px;
}
.grids:hover .grid-image-description {
visibility: visible;
opacity: 1;
}
.grids-description {
transition: .5s;
transform: translateY(1em);
}
.grids:hover .grid-image-description {
transform: translateY(0);
}
<a href="#nogo">
<div class="grids">
<img class="grid-image-cover" alt="" src="//runningfish.net/finestc/wp-content/uploads/2018/02/Depositphotos_11636543_original.jpg" />
<div class="grid-image-description">
<h2 class="grids-header">House For Sale</h2>
<hr>
<p class="grids-description">123 mulbury street</br>san diego, ca 92101
</p>
</div>
</div>
</a>
Add a width value to <hr>
.grids {
width: 33.33%;
float: left;
display: inline-block;
position: relative;
}
.grids img {
display: block;
height: 33.33vh;
width: 100%;
}
.grid-image-description {
position: absolute;
top: 0;
bottom: 0;
left: 0;
right: 0;
background: rgba(0, 0, 0, 0.6);
color: #fff;
visibility: hidden;
opacity: 0;
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
transition: opacity .5s, visibility .5s;
}
.grid-image-description h2 {
font-family: playfairdisplay;
font-size: 1.7em;
color: #fff;
}
.grid-image-description p {
font-family: playfairdisplay;
font-size: 1.0em;
color: #fff;
}
.grid-image-description hr {
border-top: 1px;
border-color: #001532;
border-style: solid;
box-shadow: 2px 1px 15px #fff;
margin: 0 0 0 10px;
max-width: 200px;
/* added */
width: 200px;
}
.grids:hover .grid-image-description {
visibility: visible;
opacity: 1;
}
.grids-description {
transition: .5s;
transform: translateY(1em);
}
.grids:hover .grid-image-description {
transform: translateY(0);
}
<a href="#nogo">
<div class="grids">
<img class="grid-image-cover" alt="" src="//runningfish.net/finestc/wp-content/uploads/2018/02/Depositphotos_11636543_original.jpg" />
<div class="grid-image-description">
<h2 class="grids-header">House For Sale</h2>
<hr>
<p class="grids-description">123 mulbury street<br>san diego, ca 92101
</p>
</div>
</div>
</a>

Only some images are not displaying in Firefox

I am having an odd issue with certain images not displaying in Firefox, but displaying in every other browser.
You can see the differences between Chrome and Firefox here
I am using an unordered list to display a row of images that are list items. However, at the beginning of each row, I am placing a normal image in the list that is not tagged as a list item. This works perfectly in Chrome, Edge, IE and Safari but, for some reason, only a few of those images won't display in Firefox. What is confusing is that there is nothing fundamentally different about rows one and two when compared to rows three and four - that I see anyway.
It is also squishing the images in row three and four and I'm not having that issue in other browsers.
The only differences I can see are image URLs. I tried removing the disable divider to see if that made a difference and it did not.
I have created a JS Fiddle to replicate the issue.
What is included below is a greatly reduced version of what you will find using the link.
hr {
opacity: .5;
display: block;
margin-top: 0.5em;
margin-bottom: 0.5em;
margin-left: 80px;
margin-right: 100px;
border-style: inset;
background: #00adbd;
border-top: 0.5px dotted #fff;
}
.disabledbutton {
pointer-events: none;
opacity: 0.4;
}
#outeroutside {
background-image: url("/assets/tile.jpg");
background-color: #a00f14;
width: 1300px;
max-width: 100%;
padding: 10px 10px 10px 10px;
position: relative;
}
#outside {
text-align: center;
background-color: rgba(252, 251, 245, 0.95);
width: 1200px;
max-width: 100%;
padding: 0px 10px 0px 0px;
}
#welcomemain p {
width: 95%;
display: inline-block;
text-align: center;
margin: 15px 5px;
height: auto;
}
#welcomemain img {
padding: 10px;
max-width: 100%;
}
h2 {
color: #2e1f11;
}
#outeroutside a:link {
color: #996515;
text-decoration: none;
font-weight: bold;
font-size: 16px;
}
#outeroutside a:hover {
color: #FFD700;
opacity: 0.9;
}
#outeroutside a:visited {
text-decoration: underline;
color: #996515;
}
#outeroutside a:active {
opacity: 0.5;
}
.row2 a {
color: #C0C0C0 !important;
text-decoration: none;
font-weight: bold;
font-size: 16px;
}
.row2 a:visited {
text-decoration: underline;
color: #999999;
}
.row2 a:active {
opacity: 0.5;
}
#navigation img {
padding: 10px;
max-width: 30%;
}
.youtube {
position: relative;
padding-bottom: 60%; // This is the aspect ratio
height: 0;
overflow: hidden;
}
.youtube iframe {
padding: 10px 10px 10px 30px;
position: absolute;
top: 0;
left: 0;
width: 100% !important;
height: 100% !important;
}
b {
color: #312112;
}
i {
color: #b05830;
}
.font {
font-size: 15px;
}
.ih-item.circle.effect1 .spinner {
width: 270px;
height: 270px;
border: 10px groove #fdec6d;
border-right-color: #739968;
border-bottom-color: #739968;
border-radius: 50%;
-webkit-transition: all 0.8s ease-in-out;
-moz-transition: all 0.8s ease-in-out;
transition: all 0.8s ease-in-out;
}
.ih-item.circle.effect1 .img {
position: absolute;
top: 0px;
bottom: 0px;
left: 0px;
right: 0px;
width: auto;
height: auto;
}
.ih-item.circle.effect1 .img:before {
display: none;
}
.ih-item.circle.effect1.colored .info {
background: #1a4a72;
background: rgba(26, 74, 114, 0.6);
}
.ih-item.circle.effect1 .info {
top: 0px;
bottom: 0px;
left: 0px;
right: 0px;
background: #333333;
background: rgba(0, 0, 0, 0.6);
opacity: 0;
-webkit-transition: all 0.8s ease-in-out;
-moz-transition: all 0.8s ease-in-out;
transition: all 0.8s ease-in-out;
}
.ih-item.circle.effect1 .info h3 {
color: #fff;
text-transform: uppercase;
position: relative;
letter-spacing: 2px;
font-size: 22px;
margin: 0 30px;
padding: 55px 0 0 0;
height: 110px;
text-shadow: 0 0 1px white, 0 1px 2px rgba(0, 0, 0, 0.3);
}
.ih-item.circle.effect1 .info p {
color: #bbb;
padding: 10px 5px;
font-style: italic;
margin: 0 30px;
font-size: 12px;
border-top: 1px solid rgba(255, 255, 255, 0.5);
}
.ih-item.circle.effect1 a:hover .spinner {
-webkit-transform: rotate(180deg);
-moz-transform: rotate(180deg);
-ms-transform: rotate(180deg);
-o-transform: rotate(180deg);
transform: rotate(180deg);
}
.ih-item.circle.effect1 a:hover .info {
opacity: 1;
}
.ih-item {
position: relative;
-webkit-transition: all 0.35s ease-in-out;
-moz-transition: all 0.35s ease-in-out;
transition: all 0.35s ease-in-out;
}
.ih-item,
.ih-item * {
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
box-sizing: border-box;
}
.ih-item a {
color: #333;
}
.ih-item a:hover {
text-decoration: none;
}
.ih-item img {
width: 100%;
height: 100%;
}
.ih-item.circle {
position: relative;
width: 270px;
height: 270px;
border-radius: 50%;
}
.ih-item.circle .img {
position: relative;
width: 260px;
height: 260px;
border-radius: 50%;
}
.ih-item.circle .img:before {
position: absolute;
display: block;
content: '';
width: 100%;
height: 100%;
border-radius: 50%;
box-shadow: inset 0 0 0 16px rgba(255, 255, 255, 0.6), 0 1px 2px rgba(0, 0, 0, 0.3);
-webkit-transition: all 0.35s ease-in-out;
-moz-transition: all 0.35s ease-in-out;
transition: all 0.35s ease-in-out;
}
.ih-item.circle .img img {
border-radius: 50%;
}
.ih-item.circle .info {
position: absolute;
top: 0;
bottom: 0;
left: 0;
right: 0;
text-align: center;
border-radius: 50%;
-webkit-backface-visibility: hidden;
backface-visibility: hidden;
}
.ih-item.circle.effect1 .spinner {
width: 270px;
height: 270px;
border: 10px solid #ecab18;
border-right-color: #1ad280;
border-bottom-color: #1ad280;
border-radius: 50%;
-webkit-transition: all 0.8s ease-in-out;
-moz-transition: all 0.8s ease-in-out;
transition: all 0.8s ease-in-out;
}
.ih-item.circle.effect1 .img {
position: absolute;
top: 0px;
bottom: 0;
left: 0px;
right: 0;
width: auto;
height: auto;
}
.ih-item.circle.effect1 .img:before {
display: none;
}
.ih-item.circle.effect1.colored .info {
background: #1a4a72;
background: rgba(26, 74, 114, 0.6)
}
.ih-item.circle.effect1 .info {
top: 0px;
bottom: 0;
left: 0px;
right: 0;
background: #333;
background: rgba(0, 0, 0, 0.6);
opacity: 0;
-webkit-transition: all 0.8s ease-in-out;
-moz-transition: all 0.8s ease-in-out;
transition: all 0.8s ease-in-out;
}
.ih-item.circle.effect1 .info h3 {
color: #fff;
text-transform: uppercase;
position: relative;
letter-spacing: 2px;
font-size: 20px;
margin: 0 30px;
padding: 55px 0 0 0;
height: 110px;
text-shadow: 0 0 1px #fff, 0 1px 2px rgba(0, 0, 0, 0.3);
}
.ih-item.circle.effect1 .info p {
color: #bbb;
padding: 11px 5px;
font-style: italic;
margin: 0 30px;
font-size: 12px;
border-top: 1px solid rgba(255, 255, 255, 0.5);
}
.ih-item.circle.effect1 a:hover .spinner {
-webkit-transform: rotate(180deg);
-moz-transform: rotate(180deg);
-ms-transform: rotate(180deg);
-o-transform: rotate(180deg);
transform: rotate(180deg);
}
.ih-item.circle.effect1 a:hover .info {
opacity: 1;
}
.row {
margin: 5px 0px 10px 5px;
padding: 10px 3px 30px 3px;
width: 1115px;
max-width: 100%;
display: flex;
flex-wrap: nonwrap;
align-content: center;
overflow-y: hidden;
overflow-x: auto;
background-color: rgba(238, 155, 195, 0.95);
}
.row2 {
margin: 5px 0px 5px 5px;
padding: 10px 3px 15px 3px;
width: 1115px;
max-width: 100%;
display: flex;
flex-wrap: nonwrap;
align-content: center;
overflow-y: hidden;
overflow-x: auto;
background-color: rgba(238, 46, 54, 0.95);
}
.col-sm-6 li {
padding: 10px 20px 10px 20px;
max-width: 33.3%;
}
a.effect-shine:hover {
-webkit-mask-image: linear-gradient(-75deg, rgba(0, 0, 0, .6) 30%, #000 50%, rgba(0, 0, 0, .6) 70%);
-webkit-mask-size: 200%;
animation: shine 2s infinite;
}
#-webkit-keyframes shine {
from {
-webkit-mask-position: 150%;
}
to {
-webkit-mask-position: -50%;
}
<ul id="week1">
<ul class="row">
<img src="http://springfieldleather.com/assets/Scroll_Week1.1.png">
<li class="col-sm-6">
<!-- normal -->
<div class="ih-item circle effect1">
<a href="#">
<div class="spinner"></div>
<div class="img"><img src="http://springfieldleather.com/assets/Week1_Gator_Buckles.jpg" alt="img"></div>
<div class="info">
<div class="info-back">
<h3>$5 Gator Buckle Sets</h3>
<p>Get a selection of 6-piece gator buckle sets for just $5. These opulent adornments are jewel encrusted and waiting to make your belt fancy!</p>
</div>
</div>
</a>
<P> Click here to see all styles! </p>
</li>
<li class="col-sm-6">
<!-- normal -->
<div class="ih-item circle effect1">
<a href="#">
<div class="spinner"></div>
<div class="img"><img src="http://springfieldleather.com/assets/Week1_Liz_CraftPack.jpg" alt="img"></div>
<div class="info">
<div class="info-back">
<h3>Liz's Craft Pack</h3>
<p>Explore the possibilities of leather craft with Liz's craft pack. Bursting at the seams with leather components, this not-so-little pack is only $25!</p>
</div>
</div>
</a>
<P> Get Liz's Craft Pack Here!</p>
</li>
<li class="col-sm-6">
<!-- normal -->
<div class="ih-item circle effect1">
<a href="#">
<div class="spinner"></div>
<div class="img"><img src="http://springfieldleather.com/assets/Week1_Stamping_Tools.jpg" alt="img"></div>
<div class="info">
<div class="info-back">
<h3>25% Off Stamping Tools</h3>
<p>Transform your veg tan with stamping tools! For this month only, get select stamping tools at an even lower price! Nearly 100 tools are included!</p>
</div>
</div>
</a>
<P> Click here to view the selection!</p>
</li>
<li class="col-sm-6">
<!-- normal -->
<div class="ih-item circle effect1">
<a href="#">
<div class="spinner"></div>
<div class="img"><img src="http://springfieldleather.com/assets/Week1_BeltBend_Black.jpg" alt="img"></div>
<div class="info">
<div class="info-back">
<h3>Black Belt Bends</h3>
<p>These Hermann Oak drum dyed belt bends are magnificent and they're on sale! Get them in black or brown. </p>
</div>
</div>
</a>
<P> Get Black Hermann Oak Belt Bend Here!</p>
</li>
<li class="col-sm-6">
<!-- normal -->
<div class="ih-item circle effect1">
<a href="#">
<div class="spinner"></div>
<div class="img"><img src="http://springfieldleather.com/assets/Week1_BeltBend_Brown.jpg" alt="img"></div>
<div class="info">
<div class="info-back">
<h3>Brown Belt Bends</h3>
<p>These Hermann Oak drum dyed belt bends are magnificent and they're on sale! Get them in black or brown.</p>
</div>
</div>
</a>
<P> Get Brown Hermann Oak Belt Bend Here!</p>
</li>
<li class="col-sm-6">
<!-- normal -->
<div class="ih-item circle effect1">
<a href="#">
<div class="spinner"></div>
<div class="img"><img src="http://springfieldleather.com/assets/Week1_VegTan_Split_Bundle.jpg" alt="img"></div>
<div class="info">
<div class="info-back">
<h3>Veg Tan Split Bundle</h3>
<p>Our new splitter has left us swimming in veg tan splits! Get this sweet bundle for just $15!</p>
</div>
</div>
</a>
<P> Get Your Veg Tan Split Bundle Here!</p>
</li>
<li class="col-sm-6">
<!-- normal -->
<div class="ih-item circle effect1">
<a href="#">
<div class="spinner"></div>
<div class="img"><img src="http://springfieldleather.com/assets/Week1_Jr_LegalPad_Templete.jpg" alt="img"></div>
<div class="info">
<div class="info-back">
<h3>Legal Pad Poly Template</h3>
<p>We have finally done it! Poly templates for one of our favorite projects: leather covers! Cover your legal pad in luxury with this template for only $5.</p>
</div>
</div>
</a>
<P> Get Your Legal Pad Template Here!</p>
</li>
</ul>
</ul>
<hr>
Please note: This code has a number of problems in IE due to lack of support for some features, however even IE is displaying the leading image in each row. There are small circles in the li's that appear in the JS Fiddle that do not display on my actual website.
You really need to fix your markup. As pointed out in my comment, you have invalid HTML. Regardless, to correct the display issue in FF, here is a possible solution:
Flexbox is shrinking your img. You can configure it not to. I've added flex-shrink: 0 to .row img
hr {
opacity: .5;
display: block;
margin-top: 0.5em;
margin-bottom: 0.5em;
margin-left: 80px;
margin-right: 100px;
border-style: inset;
background: #00adbd;
border-top: 0.5px dotted #fff;
}
.disabledbutton {
pointer-events: none;
opacity: 0.4;
}
#outeroutside {
background-image: url("/assets/tile.jpg");
background-color: #a00f14;
width: 1300px;
max-width: 100%;
padding: 10px 10px 10px 10px;
position: relative;
}
#outside {
text-align: center;
background-color: rgba(252, 251, 245, 0.95);
width: 1200px;
max-width: 100%;
padding: 0px 10px 0px 0px;
}
#welcomemain p {
width: 95%;
display: inline-block;
text-align: center;
margin: 15px 5px;
height: auto;
}
#welcomemain img {
padding: 10px;
max-width: 100%;
}
h2 {
color: #2e1f11;
}
#outeroutside a:link {
color: #996515;
text-decoration: none;
font-weight: bold;
font-size: 16px;
}
#outeroutside a:hover {
color: #FFD700;
opacity: 0.9;
}
#outeroutside a:visited {
text-decoration: underline;
color: #996515;
}
#outeroutside a:active {
opacity: 0.5;
}
.row2 a {
color: #C0C0C0 !important;
text-decoration: none;
font-weight: bold;
font-size: 16px;
}
.row2 a:visited {
text-decoration: underline;
color: #999999;
}
.row2 a:active {
opacity: 0.5;
}
#navigation img {
padding: 10px;
max-width: 30%;
}
.youtube {
position: relative;
padding-bottom: 60%; // This is the aspect ratio
height: 0;
overflow: hidden;
}
.youtube iframe {
padding: 10px 10px 10px 30px;
position: absolute;
top: 0;
left: 0;
width: 100% !important;
height: 100% !important;
}
b {
color: #312112;
}
i {
color: #b05830;
}
.font {
font-size: 15px;
}
.ih-item.circle.effect1 .spinner {
width: 270px;
height: 270px;
border: 10px groove #fdec6d;
border-right-color: #739968;
border-bottom-color: #739968;
border-radius: 50%;
-webkit-transition: all 0.8s ease-in-out;
-moz-transition: all 0.8s ease-in-out;
transition: all 0.8s ease-in-out;
}
.ih-item.circle.effect1 .img {
position: absolute;
top: 0px;
bottom: 0px;
left: 0px;
right: 0px;
width: auto;
height: auto;
}
.ih-item.circle.effect1 .img:before {
display: none;
}
.ih-item.circle.effect1.colored .info {
background: #1a4a72;
background: rgba(26, 74, 114, 0.6);
}
.ih-item.circle.effect1 .info {
top: 0px;
bottom: 0px;
left: 0px;
right: 0px;
background: #333333;
background: rgba(0, 0, 0, 0.6);
opacity: 0;
-webkit-transition: all 0.8s ease-in-out;
-moz-transition: all 0.8s ease-in-out;
transition: all 0.8s ease-in-out;
}
.ih-item.circle.effect1 .info h3 {
color: #fff;
text-transform: uppercase;
position: relative;
letter-spacing: 2px;
font-size: 22px;
margin: 0 30px;
padding: 55px 0 0 0;
height: 110px;
text-shadow: 0 0 1px white, 0 1px 2px rgba(0, 0, 0, 0.3);
}
.ih-item.circle.effect1 .info p {
color: #bbb;
padding: 10px 5px;
font-style: italic;
margin: 0 30px;
font-size: 12px;
border-top: 1px solid rgba(255, 255, 255, 0.5);
}
.ih-item.circle.effect1 a:hover .spinner {
-webkit-transform: rotate(180deg);
-moz-transform: rotate(180deg);
-ms-transform: rotate(180deg);
-o-transform: rotate(180deg);
transform: rotate(180deg);
}
.ih-item.circle.effect1 a:hover .info {
opacity: 1;
}
.ih-item {
position: relative;
-webkit-transition: all 0.35s ease-in-out;
-moz-transition: all 0.35s ease-in-out;
transition: all 0.35s ease-in-out;
}
.ih-item,
.ih-item * {
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
box-sizing: border-box;
}
.ih-item a {
color: #333;
}
.ih-item a:hover {
text-decoration: none;
}
.ih-item img {
width: 100%;
height: 100%;
}
.ih-item.circle {
position: relative;
width: 270px;
height: 270px;
border-radius: 50%;
}
.ih-item.circle .img {
position: relative;
width: 260px;
height: 260px;
border-radius: 50%;
}
.ih-item.circle .img:before {
position: absolute;
display: block;
content: '';
width: 100%;
height: 100%;
border-radius: 50%;
box-shadow: inset 0 0 0 16px rgba(255, 255, 255, 0.6), 0 1px 2px rgba(0, 0, 0, 0.3);
-webkit-transition: all 0.35s ease-in-out;
-moz-transition: all 0.35s ease-in-out;
transition: all 0.35s ease-in-out;
}
.ih-item.circle .img img {
border-radius: 50%;
}
.ih-item.circle .info {
position: absolute;
top: 0;
bottom: 0;
left: 0;
right: 0;
text-align: center;
border-radius: 50%;
-webkit-backface-visibility: hidden;
backface-visibility: hidden;
}
.ih-item.circle.effect1 .spinner {
width: 270px;
height: 270px;
border: 10px solid #ecab18;
border-right-color: #1ad280;
border-bottom-color: #1ad280;
border-radius: 50%;
-webkit-transition: all 0.8s ease-in-out;
-moz-transition: all 0.8s ease-in-out;
transition: all 0.8s ease-in-out;
}
.ih-item.circle.effect1 .img {
position: absolute;
top: 0px;
bottom: 0;
left: 0px;
right: 0;
width: auto;
height: auto;
}
.ih-item.circle.effect1 .img:before {
display: none;
}
.ih-item.circle.effect1.colored .info {
background: #1a4a72;
background: rgba(26, 74, 114, 0.6)
}
.ih-item.circle.effect1 .info {
top: 0px;
bottom: 0;
left: 0px;
right: 0;
background: #333;
background: rgba(0, 0, 0, 0.6);
opacity: 0;
-webkit-transition: all 0.8s ease-in-out;
-moz-transition: all 0.8s ease-in-out;
transition: all 0.8s ease-in-out;
}
.ih-item.circle.effect1 .info h3 {
color: #fff;
text-transform: uppercase;
position: relative;
letter-spacing: 2px;
font-size: 20px;
margin: 0 30px;
padding: 55px 0 0 0;
height: 110px;
text-shadow: 0 0 1px #fff, 0 1px 2px rgba(0, 0, 0, 0.3);
}
.ih-item.circle.effect1 .info p {
color: #bbb;
padding: 11px 5px;
font-style: italic;
margin: 0 30px;
font-size: 12px;
border-top: 1px solid rgba(255, 255, 255, 0.5);
}
.ih-item.circle.effect1 a:hover .spinner {
-webkit-transform: rotate(180deg);
-moz-transform: rotate(180deg);
-ms-transform: rotate(180deg);
-o-transform: rotate(180deg);
transform: rotate(180deg);
}
.ih-item.circle.effect1 a:hover .info {
opacity: 1;
}
.row {
margin: 5px 0px 10px 5px;
padding: 10px 3px 30px 3px;
width: 1115px;
max-width: 100%;
display: flex;
flex-wrap: nonwrap;
align-content: center;
overflow-y: hidden;
overflow-x: auto;
background-color: rgba(238, 155, 195, 0.95);
}
.row img {
flex-shrink: 0;
}
.row2 {
margin: 5px 0px 5px 5px;
padding: 10px 3px 15px 3px;
width: 1115px;
max-width: 100%;
display: flex;
flex-wrap: nonwrap;
align-content: center;
overflow-y: hidden;
overflow-x: auto;
background-color: rgba(238, 46, 54, 0.95);
}
.col-sm-6 li {
padding: 10px 20px 10px 20px;
max-width: 33.3%;
}
a.effect-shine:hover {
-webkit-mask-image: linear-gradient(-75deg, rgba(0, 0, 0, .6) 30%, #000 50%, rgba(0, 0, 0, .6) 70%);
-webkit-mask-size: 200%;
animation: shine 2s infinite;
}
#-webkit-keyframes shine {
from {
-webkit-mask-position: 150%;
}
to {
-webkit-mask-position: -50%;
}
<ul id="week1">
<ul class="row">
<img src="http://springfieldleather.com/assets/Scroll_Week1.1.png">
<li class="col-sm-6">
<!-- normal -->
<div class="ih-item circle effect1">
<a href="#">
<div class="spinner"></div>
<div class="img"><img src="http://springfieldleather.com/assets/Week1_Gator_Buckles.jpg" alt="img"></div>
<div class="info">
<div class="info-back">
<h3>$5 Gator Buckle Sets</h3>
<p>Get a selection of 6-piece gator buckle sets for just $5. These opulent adornments are jewel encrusted and waiting to make your belt fancy!</p>
</div>
</div>
</a>
<P> Click here to see all styles! </p>
</li>
<li class="col-sm-6">
<!-- normal -->
<div class="ih-item circle effect1">
<a href="#">
<div class="spinner"></div>
<div class="img"><img src="http://springfieldleather.com/assets/Week1_Liz_CraftPack.jpg" alt="img"></div>
<div class="info">
<div class="info-back">
<h3>Liz's Craft Pack</h3>
<p>Explore the possibilities of leather craft with Liz's craft pack. Bursting at the seams with leather components, this not-so-little pack is only $25!</p>
</div>
</div>
</a>
<P> Get Liz's Craft Pack Here!</p>
</li>
<li class="col-sm-6">
<!-- normal -->
<div class="ih-item circle effect1">
<a href="#">
<div class="spinner"></div>
<div class="img"><img src="http://springfieldleather.com/assets/Week1_Stamping_Tools.jpg" alt="img"></div>
<div class="info">
<div class="info-back">
<h3>25% Off Stamping Tools</h3>
<p>Transform your veg tan with stamping tools! For this month only, get select stamping tools at an even lower price! Nearly 100 tools are included!</p>
</div>
</div>
</a>
<P> Click here to view the selection!</p>
</li>
<li class="col-sm-6">
<!-- normal -->
<div class="ih-item circle effect1">
<a href="#">
<div class="spinner"></div>
<div class="img"><img src="http://springfieldleather.com/assets/Week1_BeltBend_Black.jpg" alt="img"></div>
<div class="info">
<div class="info-back">
<h3>Black Belt Bends</h3>
<p>These Hermann Oak drum dyed belt bends are magnificent and they're on sale! Get them in black or brown. </p>
</div>
</div>
</a>
<P> Get Black Hermann Oak Belt Bend Here!</p>
</li>
<li class="col-sm-6">
<!-- normal -->
<div class="ih-item circle effect1">
<a href="#">
<div class="spinner"></div>
<div class="img"><img src="http://springfieldleather.com/assets/Week1_BeltBend_Brown.jpg" alt="img"></div>
<div class="info">
<div class="info-back">
<h3>Brown Belt Bends</h3>
<p>These Hermann Oak drum dyed belt bends are magnificent and they're on sale! Get them in black or brown.</p>
</div>
</div>
</a>
<P> Get Brown Hermann Oak Belt Bend Here!</p>
</li>
<li class="col-sm-6">
<!-- normal -->
<div class="ih-item circle effect1">
<a href="#">
<div class="spinner"></div>
<div class="img"><img src="http://springfieldleather.com/assets/Week1_VegTan_Split_Bundle.jpg" alt="img"></div>
<div class="info">
<div class="info-back">
<h3>Veg Tan Split Bundle</h3>
<p>Our new splitter has left us swimming in veg tan splits! Get this sweet bundle for just $15!</p>
</div>
</div>
</a>
<P> Get Your Veg Tan Split Bundle Here!</p>
</li>
<li class="col-sm-6">
<!-- normal -->
<div class="ih-item circle effect1">
<a href="#">
<div class="spinner"></div>
<div class="img"><img src="http://springfieldleather.com/assets/Week1_Jr_LegalPad_Templete.jpg" alt="img"></div>
<div class="info">
<div class="info-back">
<h3>Legal Pad Poly Template</h3>
<p>We have finally done it! Poly templates for one of our favorite projects: leather covers! Cover your legal pad in luxury with this template for only $5.</p>
</div>
</div>
</a>
<P> Get Your Legal Pad Template Here!</p>
</li>
</ul>
</ul>
<hr>