posting area not expanding - css

I'm coding an area which is intended for posting on a forum, and therefore should expand with the content as it grows longer. I coded it with a min-height, and thought it would move with the rest as it expanded. Unfortunately, the posting area itself expands, but the areas/footers beneath it don't move down. They stay firmly in place.
I've searched all over, and saw mentions of floats and clearfixes, so I'm not sure if that's what I need to do. I attempted some clearfix methods, but they either malfunctioned or simply didn't work at all. I also tried adding 'overflow:hidden' to all of the sections with floats, but that did nothing. I'm also unfamiliar with coding with flexboxes right now, so that isn't a suitable solution for me at this time.
I think having some new sets of eyes on this would be very helpful. Please help me see where I'm going wrong.
Unfortunately, I don't have a codepen link for this one because I changed it significantly from its original model when I put it on my site. I can link to a thread where it's showing the issue though: https://lovedive.jcink.net/index.php?showtopic=5&st=0&#entry20
Here's the full code and css. It's long so hopefully that's not a pain.
.posting {
width: 1100px;
min-height: 1380px;
background-color: #f7f7f7;
border-radius: 15px 15px 10px 10px;
border: 1px solid #eee;
position: relative;
z-index: 0;
margin-bottom: 20px;
}
.proftop {
width: 1100px;
height: 150px;
padding: 0px;
background-image: linear-gradient( to bottom right, rgba(202, 186, 202, 0.2), rgba(123, 83, 123, 0.7));
/****CHANGE FOR GROUP****/
border-radius: 15px 15px 0px 0px;
overflow: hidden;
}
.proftopname {
width: 800px;
padding: 15px;
font-family: abril fatface;
font-size: 45px;
text-align: center;
color: #ffffff;
text-transform: lowercase;
text-shadow: 1px -1px 0px rgba(0, 0, 0, 0.2), -1px 1px 0px rgba(0, 0, 0, 0.2), 1px 1px 0px rgba(0, 0, 0, 0.2), -1px -1px 0px rgba(0, 0, 0, 0.2);
letter-spacing: 2px;
position: absolute;
left: 0px;
top: 30px;
}
.proftopname a {
color: #ffffff;
}
.proftoppic {
position: absolute;
top: 0px;
right: 0px;
}
.proftoppic img {
object-fit: cover;
object-position: center;
height: 150px;
width: 250px;
border-radius: 100px 20px 0px 100px;
}
/*** CHARACTER INFO BENEATH TOP BAR ***/
.picandlinks {
height: 10px;
width: 10px;
display: inline-block;
position: absolute;
left: 0px;
}
.profroundpic {
height: 100px;
width: 100px;
background-color: #f7f7f7;
padding: 15px;
border: 1px solid rgba(123, 83, 123, 0.5);
/****CHANGE FOR GROUP****/
border-radius: 100px;
margin: 40px;
display: inline-block;
position: absolute;
top: -20px;
left: 0px;
z-index: 10;
}
.profroundpic img {
object-fit: cover;
object-position: center;
height: 100px;
width: 100px;
border-radius: 100px;
}
.topicsposts {
width: 80px;
height: 100px;
padding: 10px 10px 0px;
margin: 1px;
background-color: transparent;
display: inline-block;
position: absolute;
left: 140px;
top: 32px;
z-index: 11;
}
.topicsposts g {
height: 15px;
width: 15px;
padding: 8px 10px 10px 10px;
border-radius: 100px;
background-color: rgba(202, 186, 202, 1);
/****CHANGE FOR GROUP****/
font-size: 15px;
color: #fff;
position: absolute;
display: inline-block;
left: 35px;
top: -10px;
}
.topicsposts h {
height: 15px;
width: 15px;
padding: 8px 10px 10px 10px;
border-radius: 100px;
background-color: rgba(202, 186, 202, 1);
/****CHANGE FOR GROUP****/
font-size: 15px;
color: #fff;
position: relative;
display: inline-block;
left: 35px;
top: 25px;
}
.topicsposts j {
height: 15px;
width: 15px;
padding: 8px 10px 10px 10px;
border-radius: 100px;
background-color: rgba(202, 186, 202, 1);
/****CHANGE FOR GROUP****/
font-size: 15px;
color: #fff;
position: relative;
display: inline-block;
top: 68px;
left: -15px;
}
.topicsposts g:hover {
background-color: rgba(163, 135, 163, 1);
/****CHANGE FOR GROUP****/
transition: ease-in 0.3s;
cursor: crosshair;
}
.topicsposts h:hover {
background-color: rgba(163, 135, 163, 1);
/****CHANGE FOR GROUP****/
transition: ease-in 0.3s;
cursor: crosshair;
}
.topicsposts j:hover {
background-color: rgba(163, 135, 163, 1);
/****CHANGE FOR GROUP****/
transition: ease-in 0.3s;
cursor: crosshair;
}
.topicsposts a {
font-size: 15px;
color: #fff;
text-decoration: none;
}
.hiddenbubbleone {
height: 170px;
width: 200px;
border-radius: 150px;
background-color: #f7f7f7;
position: absolute;
z-index: 9;
top: 150px;
left: 10px;
}
.charinfo {
width: 870px;
height: 100px;
border-radius: 2px;
background-color: #eee;
padding: 20px;
margin: 15px;
position: absolute;
right: 0px;
font-family: poppins;
display: block;
}
.charinfo f {
font-size: 25px;
height: 25px;
color: rgba(247, 247, 247, 1);
letter-spacing: 1px;
padding: 5px 20px 0px 20px;
margin-top: 30px;
font-family: staatliches;
letter-spacing: 4px;
display: block;
text-shadow: 1px -1px 0px rgba(125, 131, 137, 0.5), -1px 1px 0px rgba(125, 131, 137, 0.5), 1px 1px 0px rgba(125, 131, 137, 0.5), -1px -1px 0px rgba(125, 131, 137, 0.5);
}
.charinfo k {
padding: 5px 15px;
margin: 5px;
border-radius: 5px;
height: 10px;
font-size: 10px;
color: #888888;
text-transform: uppercase;
letter-spacing: 2px;
text-shadow: 1px -1px 0px rgba(255, 255, 255, 0.2), -1px 1px 0px rgba(255, 255, 255, 0.2), 1px 1px 0px rgba(255, 255, 255, 0.2), -1px -1px 0px rgba(255, 255, 255, 0.2);
}
/******** POSTING AREA *********/
.postarea {
min-height: 600px;
width: 720px;
padding: 30px;
font-family: poppins;
font-size: 12px;
color: #888;
letter-spacing: 1px;
text-align: left;
background-color: rgba(255, 255, 255, 0.6);
border-top: 40px solid #eee;
border-left: 1px solid #eee;
border-bottom: 1px solid #eee;
border-right: 1px solid #eee;
border-radius: 5px;
position: absolute;
display: inline-block;
top: 320px;
left: 20px;
}
.postdatetime {
width: 300px;
font-family: montserrat;
font-size: 10px;
letter-spacing: 2px;
text-align: left;
text-transform: uppercase;
color: #666;
position: absolute;
top: 335px;
left: 40px;
z-index: 10;
}
.postdatetime a {
text-decoration: none;
color: rgba(123, 83, 123, 1);
/****CHANGE FOR GROUP****/
cursor: crosshair;
}
.posteditbuttons {
width: 250px;
font-family: montserrat;
font-size: 10px;
letter-spacing: 1px;
text-align: right;
text-transform: uppercase;
color: #666;
position: absolute;
top: 335px;
right: 320px;
z-index: 10;
}
.posteditbuttons a {
text-decoration: none;
color: rgba(123, 83, 123, 1);
/****CHANGE FOR GROUP****/
cursor: crosshair;
margin-left: 10px;
display: inline-block;
}
/******** MINI PROFILE ********/
.miniholder {
height: 400px;
width: 230px;
padding: 25px 15px;
border-radius: 5px;
border: 1px solid #eee;
background-image: linear-gradient( to bottom, rgba(202, 186, 202, 0.4), rgba(123, 83, 123, 0.3));
/****CHANGE FOR GROUP****/
position: absolute;
display: inline-block;
top: 320px;
right: 20px;
}
.miniarea {
height: 400px;
width: 230px;
background-color: #fff;
}
/*****BOTTOM INFO******/
.bottomcontainer {
width: 1100px;
height: 550px;
border-radius: 0px 0px 10px 10px;
background-image: linear-gradient( rgba(255, 255, 255, 0.2), rgba(202, 186, 202, 0.5));
/****CHANGE FOR GROUP****/
position: absolute;
z-index: 0;
bottom: 0px;
}
/******** SHIP STATUS *******/
.shipinfo {
width: 450px;
height: 180px;
padding: 10px;
border-radius: 15px 2px 2px 15px;
border: 1px solid #ddd;
background-color: rgba(255, 255, 255, 0.7);
position: relative;
top: 205px;
display: inline-block;
}
.shipinfo1 {
height: 160px;
background-color: #fff;
border: 1px dashed #eee;
padding: 10px;
border-radius: 15px 2px 2px 15px;
}
.shipstatus {
width: 220px;
height: 100px;
position: absolute;
top: 50px;
border-top: 1px solid #eee;
border-bottom: 1px solid #eee;
}
.shipstatus d {
display: block;
height: 20px;
margin-top: 25px;
font-family: poppins;
text-transform: uppercase;
font-size: 12px;
letter-spacing: 1px;
color: #aaa;
}
.shipstatus a {
display: block;
height: 20px;
margin-top: 5px;
font-family: staatliches;
font-size: 20px;
letter-spacing: 1px;
color: rgba(123, 83, 123, 0.6);
/****CHANGE FOR GROUP****/
text-decoration: none;
cursor: crosshair;
}
.partnergif {
width: 180px;
height: 120px;
background-color: #fff;
position: absolute;
display: inline-block;
right: 40px;
top: 35px;
z-index: 1;
}
.partnergif img {
object-fit: cover;
object-position: center;
width: 180px;
height: 120px;
border: 5px solid #fff;
border-radius: 2px;
box-shadow: 1px 1px 0px #ddd, -1px -1px 0px #ddd;
}
.shipgrad {
height: 160px;
width: 50px;
background-image: linear-gradient( rgba(202, 186, 202, 0.2), rgba(123, 83, 123, 0.3));
/****CHANGE FOR GROUP****/
position: absolute;
right: 20px;
top: 20px;
z-index: 0;
}
/****** TRIGGERS ******/
.triggersinfo {
width: 450px;
height: 180px;
padding: 10px;
border-radius: 2px 15px 15px 2px;
border: 1px solid #ddd;
background-color: rgba(255, 255, 255, 0.7);
position: relative;
top: 205px;
display: inline-block;
}
.triggersinfo1 {
height: 160px;
background-color: #fff;
border: 1px dashed #eee;
padding: 10px;
border-radius: 2px 15px 15px 2px;
}
.triggersgrad {
height: 160px;
width: 50px;
background-image: linear-gradient( rgba(202, 186, 202, 0.2), rgba(123, 83, 123, 0.3));
/****CHANGE FOR GROUP****/
position: absolute;
}
.triggersicon {
height: 30px;
width: 30px;
padding: 12px 15px 16px 15px;
border-radius: 2px;
background-color: #fff;
border: 1px solid #eee;
color: #aaa;
font-size: 30px;
position: absolute;
top: 70px;
left: 35px;
}
.trigiconpulse {
height: 30px;
width: 30px;
border-radius: 50px;
position: absolute;
top: 15px;
background-color: transparent;
box-shadow: 0 0 0 0 rgba(0, 0, 0, 1);
transform: scale(1);
animation: pulse 2s infinite;
}
#keyframes pulse {
0% {
transform: scale(0.95);
box-shadow: 0 0 0 0 rgba(0, 0, 0, 0.7);
}
70% {
transform: scale(1);
box-shadow: 0 0 0 10px rgba(0, 0, 0, 0);
}
100% {
transform: scale(0.95);
box-shadow: 0 0 0 0 rgba(0, 0, 0, 0);
}
}
.triggersheader {
width: 300px;
height: 30px;
padding-bottom: 30px;
font-size: 30px;
font-family: staatliches;
text-transform: uppercase;
color: #aaa;
letter-spacing: 2px;
position: absolute;
left: 130px;
border-bottom: 1px dashed #ddd;
}
.triggersheader w {
font-family: montserrat;
font-size: 10px;
letter-spacing: 1px;
display: block;
border-top: 1px dashed #ddd;
padding: 5px;
}
.triggersheader ion-icon {
position: relative;
top: 2px;
font-size: 11px;
}
.triggersbox {
height: 70px;
width: 300px;
padding: 10px 15px;
background-color: #f7f7f7;
overflow: auto;
font-family: poppins;
color: #aaa;
font-size: 11px;
text-align: justify;
position: absolute;
top: 90px;
left: 115px;
}
/*** OTHER LINKS ***/
.otherlinks {
height: 90px;
width: 1030px;
padding: 10px 20px 20px 20px;
background-color: rgba(255, 255, 255, 0.6);
border-radius: 15px;
border: 1px solid #ddd;
display: block;
position: relative;
top: 210px;
}
.otherlinksleft {
height: 60px;
width: 400px;
padding-top: 20px;
display: inline-block;
float: left;
overflow: hidden;
}
.otherlinks g {
height: 20px;
width: 20px;
padding: 15px 20px;
border-radius: 8px;
background-color: rgba(202, 186, 202, 0.4);
/***CHANGE TO GROUP COLOR***/
margin: 5px;
box-shadow: 1px -1px 0px rgba(255, 255, 255, 1), -1px 1px 0px rgba(255, 255, 255, 1), 1px 1px 0px rgba(255, 255, 255, 1), -1px -1px 0px rgba(255, 255, 255, 1);
display: inline-block;
}
.otherlinks g:hover {
background-image: linear-gradient( rgba(222, 212, 222, 0.2), rgba(163, 135, 163, 0.3));
/***CHANGE TO GROUP COLOR***/
}
.otherlinks a {
font-size: 20px;
color: #fff;
text-decoration: none;
text-shadow: 1px -1px 0px rgba(163, 135, 163, 0.5), -1px 1px 0px rgba(163, 135, 163, 0.5), 1px 1px 0px rgba(163, 135, 163, 0.5), -1px -1px 0px rgba(163, 135, 163, 0.5);
}
.otherlinksright {
height: 100px;
width: 620px;
display: inline-block;
border-left: 1px dashed #eee;
font-family: montserrat;
float: right;
}
.aliasinfoleft {
height: 100px;
width: 160px;
display: inline-block;
float: left;
margin-right: 10px;
}
.aliasinfoleft k {
display: block;
width: 150px;
height: 10px;
background-color: #fafafa;
padding: 8px 20px 15px 5px;
}
.aliasinfoleft l {
width: 50px;
font-size: 15px;
border-right: 1px dashed #bbb;
color: rgba(163, 135, 163, 1);
/***CHANGE TO GROUP COLOR***/
float: left;
}
.aliasinfoleft m {
font-size: 10px;
text-transform: lowercase;
float: right;
color: #aaa;
letter-spacing: 1px;
padding-top: 2px;
}
.aliasinfomid {
height: 100px;
width: 200px;
display: inline-block;
float: left;
margin-left: 10px;
font-family: montserrat;
font-size: 11px;
}
.aliasinfomid k {
display: block;
width: 175px;
height: 25px;
background-color: #fafafa;
padding: 8px 20px 15px 5px;
}
.aliasinfomid l {
width: 70px;
font-size: 25px;
border-right: 1px dashed #bbb;
color: rgba(163, 135, 163, 1);
/***GROUP COLOR***/
padding-top: 3px;
float: left;
}
.aliasinfomid m {
font-size: 12px;
text-transform: lowercase;
float: right;
color: #aaa;
letter-spacing: 1px;
padding-top: 7px;
overflow: hidden;
}
.aliasname {
height: 60px;
width: 200px;
padding: 25px 15px 15px 15px;
font-size: 11px;
letter-spacing: 2px;
display: inline-block;
float: right;
color: #aaa;
}
.aliasname n {
display: block;
font-size: 22px;
letter-spacing: 1px;
font-family: poppins;
font-weight: bold;
}
<div id="g-<!-- |g_id| -->">
<center>
<div class="posting">
<a name='entry<!-- |pid| -->'></a>
<div class="proftop">
<div class="proftopname">
<!-- |name| -->
</div>
<div class="fakebar1"></div>
<div class="fakebar2"></div>
<div class="proftoppic">
<img src="<!-- |field_24| -->">
</div>
</div>
<div class="picandlinks">
<div class="profroundpic"><img src="<!-- |field_25| -->"></div>
<div class="topicsposts">
<a href="/index.php?act=Search&CODE=getalluser&mid=<!-- |poster_id| -->&type=topics">
<g>
<ion-icon name="folder-open"></ion-icon>
</g>
</a>
<a href="/index.php?act=Search&CODE=getalluser&mid=<!-- |poster_id| -->&type=posts">
<h>
<ion-icon name="bookmarks"></ion-icon>
</h>
</a>
<a href="/index.php?act=Msg&CODE=04&MID=<!-- |poster_id| -->">
<j>
<ion-icon name="mail"></ion-icon>
</j>
</a>
</div>
</div>
<div class="hiddenbubbleone"></div>
<div class="charinfo">
<f>
<!-- |field_3| -->
</f>
<k>
<!-- |field_8| -->
</k>
<k>
<!-- |field_2| -->
</k>
<k>
<!-- |field_4| -->
</k>
<k>
<!-- |field_5| -->/
<!-- |field_6| -->
</k>
<k>
<!-- |field_7| -->
</k>
</div>
<div class="postdatetime">
<a href="<!-- |permalink| -->">
<ion-icon name="arrow-redo"></ion-icon>
</a>
<!-- |post_date| -->
</div>
<div class="posteditbuttons">
<!-- |mod_checkbox| -->
<!-- |edit_button| -->
<!-- |quote_button| -->
<!-- |delete_button| -->
<!-- |report_link| -->
</div>
<div class="postarea">
<!-- |post| -->
</div>
<div class="miniholder">
<div class="miniarea">
<!-- |mini_profile| -->
</div>
</div>
<div class="bottomcontainer">
<div class="shipinfo">
<div class="shipinfo1">
<div class="shipstatus">
<d>
<!-- |field_9| -->
</d>
<a href="<!-- |field_11| -->">
<!-- |field_10| -->
</a>
</div>
<div class="partnergif"><img src="<!-- |field_23| -->"></div>
<div class="shipgrad"></div>
</div>
</div>
<div class="triggersinfo">
<div class="triggersinfo1">
<div class="triggersgrad"></div>
<div class="triggersicon">
<ion-icon name="alert-circle"></ion-icon>
<div class="trigiconpulse"></div>
</div>
<div class="triggersheader">triggers
<w>please tag
<ion-icon name="warning-sharp"></ion-icon>
</w>
</div>
<div class="triggersbox">
<!-- |field_22| -->
</div>
</div>
</div>
<div class="otherlinks">
<div class="otherlinksleft">
<g>
<a href="DIRECTORY">
<ion-icon name="id-card"></ion-icon>
</a>
</g>
<g>
<a href="<!-- |field_12| -->" alt="character dev">
<ion-icon name="color-palette"></ion-icon>
</a>
</g>
<g>
<a href="<!-- |field_13| -->" alt="ship dev">
<ion-icon name="heart-half"></ion-icon>
</a>
</g>
<g>
<a href="<!-- |field_14| -->" alt="instagram">
<ion-icon name="logo-instagram"></ion-icon>
</a>
</g>
<g>
<a href="<!-- |field_15| -->" alt="request">
<ion-icon name="pricetags"></ion-icon>
</a>
</g>
</div>
<div class="otherlinksright">
<div class="aliasinfoleft">
<k>
<l>
<ion-icon name="fitness"></ion-icon>
</l>
<m>
<!-- |field_16| -->
</m>
</k>
<k style="border-bottom: 1px dashed #DDD; border-top: 1px dashed #DDD;">
<l>
<ion-icon name="shirt"></ion-icon>
</l>
<m>
<!-- |field_17| -->
</m>
</k>
<k>
<l>
<ion-icon name="earth"></ion-icon>
</l>
<m>
<!-- |field_18| -->
</m>
</k>
</div>
<div class="aliasinfomid">
<k>
<l>
<ion-icon name="eye-off"></ion-icon>
</l>
<m>
<!-- |field_19| -->
</m>
</k>
<k style="margin-top: 5px;">
<l>
<ion-icon name="flash"></ion-icon>
</l>
<m>
<!-- |field_20| -->
</m>
</k>
</div>
<div class="aliasname">written by
<n>
<!-- |field_21| -->
</n>
</div>
</div>
</div>
<div style="clear: both;"></div>
</div>
</div>
</center>
</div>

Seeing your code, I will guess you do not understand much of what the code is doing.
Here there is a minimal version of something I would imagine is what you are looking for.
When you use float, the element stops taking space by itself and start to float inside its parent, so in your case, you shouldn't use it.
// Get all comments with class 'comment'
const comment = document.querySelectorAll('.comment');
// Iterate the comments in order to make it multiple
comment.forEach( function(element) {
// Add click to every element
element.addEventListener('click',function() {
// Remove class to make it full size
this.classList.remove('short_comment');
//Get the button of that block and make it dissapear
var button_read_more = this.querySelectorAll('.read_more');
button_read_more[0].remove();
});
});
footer {
width: 100%;
background: green;
}
footer div {
padding: 50px;
}
/* No floating */
.short_comment .content {
max-height: 25px;
background: yellow;
overflow: hidden;
}
<div class="comment short_comment">
<p class="content">
Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum
</p>
<button class="read_more">read all</button>
</div>
<footer>
<div>This is the footer</div>
</footer>

Related

How can I fix this grid in css?

I'm trying to do a simple grid for my website. I could almost successfully do what I wanted.
I would like to fix the "Projects" that is the title of this grid, I would like to have it not in the same size as the other parts of the grid.
This is the result that I have:
I would like to have something like this:
HTML:
<div class="project-container">
<div className="title">
<h1>PROJECTS</h1>
</div>
<div className="project-one item">
<h2>Face Recognition</h2>
<button className="button button1">VIEW PROJECT</button>
</div>
<div className="project-two item">
<h2>Face Recognition</h2>
<button className="button button1">VIEW PROJECT</button>
</div>
<div className="project-three item">
<h2>Face Recognition</h2>
<button className="button button1">VIEW PROJECT</button>
</div>
</div>
CSS:
.project-container {
width: 80%;
height: 80vh;
margin: auto;
display: grid;
border: 1px solid pink;
// grid-gap: 4em;
grid-template-columns: repeat(3, 1fr);
grid-template-areas:
"t t t"
"p1 p2 p3";
}
.item {
// width: 100%;
// height: 100%;
// transition: all 0.2s ease-in-out;
text-align: center;
color: white;
border: 1px solid pink;
}
.title {
grid-area: t;
text-align: center;
border: 1px solid pink;
// height: 10vh;
}
use grid-template-rows
.project-container {
width: 80%;
height: 80vh;
margin: auto;
display: grid;
border: 1px solid pink;
// grid-gap: 4em;
grid-template-columns: repeat(3, 1fr);
grid-template-rows: 100px auto;
grid-template-areas:
"t t t"
"p1 p2 p3";
}
Dude I would recommend using css flexbox. See I have made a code that might help you & it's fully responsive. If you want to create a heavy masonry layout you can go for css grid.
.project_container {
padding: 20px;
margin-bottom: 2em;
position: relative;
max-width: 900px;
margin-left: auto;
margin-right: auto;
background-color: #f7f7f7;
border-radius: 7px;
box-sizing: border-box;
font: normal 16px/1.9em sans-serif;
}
.wrap {
color: #292929;
font-size: 18px;
line-height: 1.8em;
border: 0;
vertical-align: baseline;
margin: 0;
background-color: #f7f7f7;
border-radius: 3px;
padding: 20px;
display: flex;
flex-wrap: wrap;
justify-content: space-between;
}
.title {
background-color: #a2cbfa;
border: 1px solid #4390e1;
text-align: center;
font-size: 18px;
color: black;
-webkit-text-fill-color: #a2cbfa;
-webkit-text-stroke-width: 1px;
-webkit-text-stroke-color: black;
vertical-align: center;
box-sizing: border-box;
box-shadow: 0 2px 2px rgba(0, 90, 250, 0.05), 0 4px 4px rgba(0, 90, 250, 0.05),
0 8px 8px rgba(0, 90, 250, 0.05), 0 16px 16px rgba(0, 90, 250, 0.05);
height: 100%;
margin-bottom: 2%;
width: 100%;
}
.item {
color: #292929;
font-size: 18px;
line-height: 1.8em;
vertical-align: baseline;
border-radius: 3px;
background-color: #a2cbfa;
-webkit-text-fill-color: #a2cbfa;
-webkit-text-stroke-width: 1px;
-webkit-text-stroke-color: black;
border: 1px solid #4390e1;
box-sizing: border-box;
box-shadow: 0 2px 2px rgba(0, 90, 250, 0.05), 0 4px 4px rgba(0, 90, 250, 0.05),
0 8px 8px rgba(0, 90, 250, 0.05), 0 16px 16px rgba(0, 90, 250, 0.05);
height: 250px;
margin-bottom: 2%;
text-align: center;
margin-right: 2%;
flex-grow: 1;
}
.project-three {
margin-right: 0px;
}
button {
outline: none;
border: none;
border-radius: 3px;
padding: 5px 10px;
font-weight: light;
-webkit-text-fill-color: #292929;
color: #292929;
-webkit-text-stroke-width: 0px;
-webkit-text-stroke-color: none;
font-size: 12px;
letter-spacing: 1px;
}
<div class="project_container">
<div class="wrap">
<div class="title">
<h1>PROJECTS</h1>
</div>
<div class="project-one item">
<h2>Face Recog</h2>
<button class="button button1">VIEW</button>
</div>
<div class="project-two item">
<h2>Face Recog</h2>
<button class="button button1">VIEW</button>
</div>
<div class="project-three item">
<h2>Face Recog</h2>
<button class="button button1">VIEW</button>
</div>
</div>
</div>
HAPPY CODING
Regards Sameer

css overflow hidden can't cover all element?

.powder-box {
width: 51px;
height: 51px;
border-radius: 50%;
border: 2px solid #A5B2B5;
box-shadow: 0 1px 2px 0px #A5B2B5;
overflow: hidden;
position: relative;
}
.powder-inner {
width: 45px;
height: 45px;
border: 2px solid white;
border-radius: 50%;
box-shadow: 0 4px 10px 0 #656565;
background-color: #00c690;
overflow: hidden;
margin: 1px;
}
.powder-wave {
background-color: white;
height: 70px;
}
<div class="powder-box">
<div class="powder-inner">
<div class="powder-wave" style="margin-top: -54px"></div>
</div>
</div>
.powder-inner overflow hidden ,there have a border in there . it can't cover all .
how can i cover all ? there is border there ?
Update .powder-inner class using border-top-left-radius: 0%; & border-top-right-radius: 0%; then remove top green curve.
See output is browser zoom it and see green curve.
.powder-inner {
width: 45px;
height: 45px;
border: 2px solid white;
border-radius: 49%;
box-shadow: 0 4px 10px 0 #656565;
background-color: #00c690;
overflow: hidden;
margin: 1px;
z-index: 2000;
border-top-left-radius: 0%;
border-top-right-radius: 0%;
}
.powder-box {
width: 51px;
height: 51px;
border-radius: 50%;
border: 2px solid #A5B2B5;
box-shadow: 0 1px 2px 0px #A5B2B5;
overflow: hidden;
position: relative;
}
.powder-inner {
width: 45px;
height: 45px;
border: 2px solid white;
border-radius: 49%;
box-shadow: 0 4px 10px 0 #656565;
background-color: #00c690;
overflow: hidden;
margin: 1px;
z-index: 2000;
border-top-left-radius: 0%;
border-top-right-radius: 0%;
}
.powder-wave {
background-color: white;
height: 70px;
}
<div class="powder-box">
<div class="powder-inner">
<div class="powder-wave" style="margin-top: -54px"></div>
</div>
</div>
.powder-box {
width: 51px;
height: 51px;
border-radius: 50%;
border: 2px solid #A5B2B5;
box-shadow: 0 1px 2px 0px #A5B2B5;
overflow: hidden !important;
position: relative;
}
.powder-inner {
width: 45px;
height: 45px;
border: 2px solid white;
border-radius: 50%;
box-shadow: 0 4px 10px 0 #656565;
background-color: #00c690;
overflow:hidden !important;
margin: 1px;
}
.powder-wave {
background-color: white;
height: 70px;
}
<div class="powder-box">
<div class="powder-inner">
<div class="powder-wave" style=""></div>
</div>
</div>

Header moves on windows resize

When ever I re-size the window the header moves leaving a space on the right side. (Refer to image ). If I shrink the window horizontally even more the gap increases. I have only been able to fix this problem by making the position for header to fixed but then the text overlaps. I want the header to move with the vertical scroll. Any help on here where I am going wrong is highly appreciated.
*{
padding:0;
margin:0 auto;
font-family: 'Museo Slab 300';
}
html{
background: url("Images/backlines.png") no-repeat center center fixed;
}
.company-header {
background-image: -webkit-gradient(linear, 0% 0%, 0% 100%,color-stop(0, rgb(226, 226, 226)),color-stop(0, rgb(254, 254, 254)),color-stop(0.1, rgb(254, 254, 254)),color-stop(1, rgb(219, 219, 219)),color-stop(1, rgb(209, 209, 209)));
height: 140px;
box-shadow: 0px 2px;
position: absolute;
width: 100%;
top: 0px;
}
.company-footer{
position: fixed;
right: 0;
bottom: 0;
left: 0;
padding: 1rem;
background-color: #efefef;
text-align: left;
z-index:-1;
box-shadow: 0px -4px rgba(0, 173, 239, 1);
}
img#logo-image {
position: absolute;
left: 270px;
}
div#setting-dropdown {
position: relative;
float: right;
right: 250px;
top: 58px;
}
div#setting-dropdown-content {
display: none;
background: rgba(0, 173, 239, 1);
width: 196px;
margin-left: -70px;
padding: 4px 5px 5px 7px;
}
div#setting-dropdown-content a {
color: white;
text-decoration: none;
font-size: 16px;
font-family: 'Museo Slab 300';
display: inline-block;
}
div#setting-dropdown i {
display: inline-block;
padding: 5px;
padding-right: 7px;
text-align: center;
border-radius: 10px 10px 0 0;
padding-bottom: 10px;
color: rgba(0, 173, 239, 1);
}
div#setting-dropdown:hover i {
background-color: rgba(0, 173, 239, 1);
color:white;
}
#setting-dropdown:hover #setting-dropdown-content {
display:block;
}
p#setting-dropdown {
font-size: 20px;
font-weight: bold;
}
button#company-logout {
background: rgba(255, 255, 255, 1);
border: none;
border-radius: 40px 40px 40px 40px;
width: 135px;
height: 40px;
font-size: 19px;
font-weight: 900;
font-family: 'Museo Slab 700';
float: right;
top: 54px;
right: -40px;
position: relative;
}
div#log-in {
position: relative;
top: 200px;
}
div#welcome-text {
margin-left: 276px;
font-family: 'Museo Slab 300';
font-size: 22px;
}
div#loginHeader {
margin-top: 60px;
margin-left: 276px;
}
div#dropdown-main-content {
position: relative;
top: 230px;
left: 276px;
display: inline-flex;
}
.dropdown {
position: relative;
width: 11em;
top: 60px;
right: 260px;
}
.dropbtn {
color: white;
width: 100%;
height: 3.2em;
font-size: 16px;
border: none;
text-align: start;
font-weight: 900;
background: rgba(0, 173, 239, 1);
border-radius: 50px 50px 50px 50px;
-moz-border-radius: 0px;
z-index: 2;
text-indent: 23px;
}
.dropdown-content {
display: none;
z-index: -1;
background-color: #f9f9f9;
box-shadow: 0px 8px 16px 0px rgba(0,0,0,0.2);
margin-top: -64px;
width: 176px;
}
.dropdown a {
background:url("Images/sidearrow.png") no-repeat 7px;
}
.dropdown-content a {
color: black;
padding: .75em;
text-decoration: none;
display: block;
border: 1px solid #000;
border-top: none;
text-indent: 12px;
width: 150px;
}
.dropdown:hover .dropdown-content {
display: block;
}
.dropdown:hover .dropbtn {
background-color: #3e8e41;
}
.dropdown-content a:hover {
background:url("Images/sidewhite.png") no-repeat 3px;
background-color: rgb(255,131,0);
color:white;
font-weight:900;
}
.dropdown-content a:first-child {
padding-top: 35px;
background: url("Images/sidearrow.png") no-repeat 7px 36px;
}
.dropdown-content a:first-child:hover {
background: url("Images/sidewhite.png") no-repeat 3px 36px;
color:white;
background-color: rgb(255,131,0);
font-weight:900;
}
img#sphere {
position: relative;
width: 35px;
height: 34px ;
left: 133px;
bottom: 42px;
}
img#sphere-arrow {
position: relative;
bottom: 44px;
left: 99px;
}
div#login-form {
margin-top: 100px;
margin-left: 276px;
}
.page-label {
font-size: 19px;
}
button#loginSubmit {
margin-top: 75px;
background: rgba(0, 173, 239, 1);
border-radius: 0px;
-moz-border-radius: 0px;
border-radius: 40px 40px 40px 40px;
width: 185px;
height: 60px;
font-size: 20px;
font-family: sans-serif;
color: white;
font-weight: 900;
border: none;
position: absolute;
margin-left: 278px;
}
div#login-landingpage{
margin-left: 276px;
margin-top: 90px;
}
select.security-questions {
width: 450px;
height: 40px;
font-weight: bold;
}
.security-question-labels {
font-size: 21px;
font-family: 'Museo Slab 300';
}
<!DOCTYPE html>
<html>
<head>
<title>Averios</title>
<link rel="stylesheet" type="text/css" href="test.css">
<link rel="stylesheet" href="http://code.ionicframework.com/ionicons/2.0.1/css/ionicons.min.css" />
<meta charset="utf-8">
</head>
<body>
<div class="company-header">
<img id="averios-logo-image" src="Images/averioslogo.png" width="176" height="129">
<div id="setting-dropdown">
<!-- SETTING DROPDOWN WILL GO HERE -->
<p id="setting-dropdown"> SETTINGS <i class="ion-chevron-down"></i></p>
<div id="setting-dropdown-content">
Change Password
Change Security Settings
</div>
</div>
<button id="company-logout"> LOGOUT </button>
</div>
<div id="log-in">
<div id="loginHeader">
<h1>Portal</h1>
</div>
<br>
<br>
<div id="welcome-text">
<p> Welcome name </p>
<p> Your last login was time on date </p>
<br>
<p> Please select an application below to begin </p>
</div>
</div>
<div id="dropdown-main-content">
<img id="pulse-image" src="C:\Users\user\Desktop\Final-Designs\Images\pulse.png" width="320" height="50" alt=""/>
<div id="dropdown-one">
<div class="dropdown">
<button class="dropbtn">SELECT</button>
<img id="sphere" src="C:\Users\user\Desktop\Final-Designs\Images\sphere.png" alt=""/>
<img id="sphere-arrow" src="C:\Users\user\Desktop\Final-Designs\Images\arrow.png" alt=""/>
<div class="dropdown-content">
option0
option1
</div>
</div>
</div>
<!-- SENTINAL -->
<img id="sentinal-image" src="C:\Users\user\Desktop\Final-Designs\Images\sentinal.png" width="380" height="50" alt=""/>
<div id="dropdown-second">
<div class="dropdown">
<button class="dropbtn">SELECT</button>
<img id="sphere" src="C:\Users\user\Desktop\Final-Designs\Images\sphere.png" alt=""/>
<img id="sphere-arrow" src="C:\Users\user\Desktop\Final-Designs\Images\arrow.png" alt=""/>
<!--<div class="sphere-two">
<div id="arrow-two">
<img src="C:\Users\user\Desktop\Images\arrow.png" width="29" height="27" alt=""/>
</div>
</div>-->
<div class="dropdown-content">
option0
option1
</div>
</div>
</div>
</div>
<div class="company-footer">
<div id="footer-text">
© 2016 Company, All Rights Reserved.
</div>
</div>
</body>
</html>
Problem is
div#dropdown-main-content {
position: relative;
top: 230px;
left: 276px;
display: inline-flex; }
try to remove display to inline and left to 0 like this
div#dropdown-main-content {
position: relative;
top: 230px;
display: inline; }
also remove fixed widths from images and divs, try to use max-width.
update
*{
padding:0;
margin:0 auto;
font-family: 'Museo Slab 300';
}
html{
background: url("Images/backlines.png") no-repeat center center fixed;
}
.averios-header {
background-image: -webkit-gradient(linear, 0% 0%, 0% 100%,color-stop(0, rgb(226, 226, 226)),color-stop(0, rgb(254, 254, 254)),color-stop(0.1, rgb(254, 254, 254)),color-stop(1, rgb(219, 219, 219)),color-stop(1, rgb(209, 209, 209)));
height: 140px;
box-shadow: 0px 2px;
position: absolute;
width: 100%;
top: 0px;
}
.averios-footer{
position: fixed;
right: 0;
bottom: 0;
left: 0;
padding: 1rem;
background-color: #efefef;
text-align: left;
z-index:-1;
box-shadow: 0px -4px rgba(0, 173, 239, 1);
}
img#averios-logo-image {
position: absolute;
left: 270px;
}
div#setting-dropdown {
position: relative;
float: right;
right: 250px;
top: 58px;
}
div#setting-dropdown-content {
display: none;
background: rgba(0, 173, 239, 1);
width: 196px;
margin-left: -70px;
padding: 4px 5px 5px 7px;
}
div#setting-dropdown-content a {
color: white;
text-decoration: none;
font-size: 16px;
font-family: 'Museo Slab 300';
display: inline-block;
}
div#setting-dropdown i {
display: inline-block;
padding: 5px;
padding-right: 7px;
text-align: center;
border-radius: 10px 10px 0 0;
padding-bottom: 10px;
color: rgba(0, 173, 239, 1);
}
div#setting-dropdown:hover i {
background-color: rgba(0, 173, 239, 1);
color:white;
}
#setting-dropdown:hover #setting-dropdown-content {
display:block;
}
p#setting-dropdown {
font-size: 20px;
font-weight: bold;
}
button#averios-logout {
background: rgba(255, 255, 255, 1);
border: none;
border-radius: 40px 40px 40px 40px;
width: 135px;
height: 40px;
font-size: 19px;
font-weight: 900;
font-family: 'Museo Slab 700';
float: right;
top: 54px;
right: -40px;
position: relative;
}
div#log-in {
position: relative;
top: 200px;
}
div#welcome-text {
margin-left: 276px;
font-family: 'Museo Slab 300';
font-size: 22px;
}
div#loginHeader {
margin-top: 60px;
margin-left: 276px;
}
div#dropdown-main-content {
position: relative;
top: 230px;
display: inline-block;
text-align: center;
width: 100%;
}
.dropdown {
position: relative;
width: 11em;
top: 60px;
}
.dropbtn {
color: white;
width: 100%;
height: 3.2em;
font-size: 16px;
border: none;
text-align: start;
font-weight: 900;
background: rgba(0, 173, 239, 1);
border-radius: 50px 50px 50px 50px;
-moz-border-radius: 0px;
z-index: 2;
text-indent: 23px;
}
.dropdown-content {
display: none;
z-index: -1;
background-color: #f9f9f9;
box-shadow: 0px 8px 16px 0px rgba(0,0,0,0.2);
margin-top: -64px;
width: 176px;
}
.dropdown a {
background:url("Images/sidearrow.png") no-repeat 7px;
}
.dropdown-content a {
color: black;
padding: .75em;
text-decoration: none;
display: block;
border: 1px solid #000;
border-top: none;
text-indent: 12px;
width: 150px;
}
.dropdown:hover .dropdown-content {
display: block;
}
.dropdown:hover .dropbtn {
background-color: #3e8e41;
}
.dropdown-content a:hover {
background:url("Images/sidewhite.png") no-repeat 3px;
background-color: rgb(255,131,0);
color:white;
font-weight:900;
}
.dropdown-content a:first-child {
padding-top: 35px;
background: url("Images/sidearrow.png") no-repeat 7px 36px;
}
.dropdown-content a:first-child:hover {
background: url("Images/sidewhite.png") no-repeat 3px 36px;
color:white;
background-color: rgb(255,131,0);
font-weight:900;
}
img#sphere {
position: relative;
width: 35px;
height: 34px ;
left: 133px;
bottom: 42px;
}
img#sphere-arrow {
position: relative;
bottom: 44px;
left: 99px;
}
div#login-form {
margin-top: 100px;
margin-left: 276px;
}
.page-label {
font-size: 19px;
}
input[type="text"] {
background: #EDEDEE;
background : rgba(237, 237, 238, 1);
border-style : Solid;
border-color : #4B4E53;
border-color : rgba(75, 78, 83, 1);
border-width : 1px;
width: 370px;
height: 35px;
font-size: 26px;
}
input[type="password"] {
background: #EDEDEE;
background : rgba(237, 237, 238, 1);
border-style : Solid;
border-color : #4B4E53;
border-color : rgba(75, 78, 83, 1);
border-width : 1px;
width: 370px;
height: 35px;
font-size: 26px;
}
button#loginSubmit {
margin-top: 75px;
background: rgba(0, 173, 239, 1);
border-radius: 0px;
-moz-border-radius: 0px;
border-radius: 40px 40px 40px 40px;
width: 185px;
height: 60px;
font-size: 20px;
font-family: sans-serif;
color: white;
font-weight: 900;
border: none;
position: absolute;
margin-left: 278px;
}
div#login-landingpage{
margin-left: 276px;
margin-top: 90px;
}
select.security-questions {
width: 450px;
height: 40px;
font-weight: bold;
}
.security-question-labels {
font-size: 21px;
font-family: 'Museo Slab 300';
}
button#saveSubmit {
margin-top: 55px;
background: rgba(0, 173, 239, 1);
border-radius: 0px;
-moz-border-radius: 0px;
border-radius: 40px 40px 40px 40px;
width: 170px;
height: 55px;
font-size: 20px;
font-family: sans-serif;
color: white;
font-weight: 900;
border: none;
position: absolute;
margin-left: 278px;
}
button#cancelSubmit {
margin-top: 55px;
background: rgb(75,79,84);
border-radius: 0px;
-moz-border-radius: 0px;
border-radius: 40px 40px 40px 40px;
width: 170px;
height: 55px;
font-size: 20px;
font-family: sans-serif;
color: white;
font-weight: 900;
border: none;
position: absolute;
margin-left: 478px;
}
div#security-form {
margin-top: 60px;
margin-left: 276px;
}
/* TEST */
div#dropdown-col-2 {
display:inline-block;
}
div#dropdown-second {
position: absolute;
left: 1040px;
top: -10px;
}
//HTML
<div class="averios-header">
<img id="averios-logo-image" src="http://lorempixel.com/176/129/"></img>
</a>
<div id="setting-dropdown">
<!-- SETTING DROPDOWN WILL GO HERE -->
<p id="setting-dropdown"> SETTINGS <i class="ion-chevron-down"></i></p>
<div id="setting-dropdown-content">
Change Password
Change Security Settings
</div>
</div>
<button id="averios-logout"> LOGOUT </button>
</div>
<div id="log-in">
<div id="loginHeader">
<h1> Portal</h1>
</div>
<br>
<br>
<div id="welcome-text">
<p> Welcome name </p>
<p> Your last login was time on date </p>
<br>
<p> Please select an application below to begin </p>
</div>
</div>
<div id="dropdown-main-content">
<div id="dropdown-col-2">
<img id="averios-pulse-image" src="http://lorempixel.com/362/46/" alt="" />
<div class="dropdown">
<button class="dropbtn">SELECT</button>
<div class="dropdown-content">
Option1
</div>
</div>
</div>
<!-- SENTINAL -->
<div id="dropdown-col-2">
<img id="averios-sentinal-image" src="http://lorempixel.com/362/46/" alt="" />
<div class="dropdown">
<button class="dropbtn">SELECT</button>
<div class="dropdown-content">
Option1
</div>
</div>
</div>
</div>
<div class="averios-footer">
<div id="footer-text">
© 2016, All Rights Reserved.
</div>
</div>

How to add 2 bordered triangle over a div tag

I have a div tag and I added one triangle on the div box. How do I add a second triangle?
I want to have 2 triangles, one for best and one for worst that will work on most browsers.
JSFiddle
.arrow_box {
top: 40px;
position: relative;
background: #ffffff;
border: 1px solid #719ECE;
width: 200px;
height: 22px;
border-radius: 3px;
-webkit-filter: drop-shadow(0 1px 10px rgba(113, 158, 206, 0.8));
-moz-box-shadow: 0 1px 10px rgba(113, 158, 206, 0.8);
filter: drop-shadow(0 1px 10px rgba(113, 158, 206, 0.8));
}
.arrow_box:after,
.arrow_box:before {
bottom: 100%;
border: solid transparent;
content: " ";
height: 0;
width: 0;
position: absolute;
pointer-events: none;
}
.arrow_box:after {
border-color: rgba(255, 255, 255, 0);
border-bottom-color: #ffffff;
border-width: 19px;
left: 70%;
margin-left: -19px;
}
.arrow_box:before {
border-color: rgba(113, 158, 206, 0);
border-bottom-color: #719ECE;
border-width: 20px;
left: 70%;
margin-left: -20px;
}
<div id="nicebox" class="arrow_box">
<span class="pull-left">Best </span>
<span class="pull-right">Worst</span>
</div>
Here is the updated Demo
.arrow_box {
top:40px;
position: relative;
background: #ffffff;
border: 1px solid #719ECE;
width: 200px;
height: 22px;
border-radius: 3px;
-webkit-filter: drop-shadow(0 1px 10px rgba(113,158,206,0.8));
-moz-box-shadow: 0 1px 10px rgba(113,158,206,0.8);
filter: drop-shadow(0 1px 10px rgba(113,158,206,0.8));
}
.arrow_box:after,
.arrow_box:before {
bottom: 100%;
border: solid transparent;
content: " ";
height: 0;
width: 0;
position: absolute;
pointer-events: none;
}
.arrow_box:after {
border-color: rgba(255, 255, 255, 0);
border-bottom-color: #719ECE;
border-width: 19px;
right: 0%;
/* margin-left: -10px; */
}
.arrow_box:before {
border-color: rgba(113, 158, 206, 0);
border-bottom-color: #719ECE;
border-width: 20px;
left: 10%;
margin-left: -20px;
}
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css" crossorigin="anonymous">
<div id="nicebox" class="arrow_box">
<span class="pull-left"><i class="fa fa-long-arrow-up" aria-hidden="true"></i>Best </span>
<span class="pull-right">Worst</span>
</div>

Setting a shadow on a border-radius div

I have a div with the style as so:
.oval {
width: 100%;
height: 30%;
border-radius: 250px;
font-weight: bold;
line-height: 2em;
font-size: 1em;
color: #fff;
text-align: center;
}
And also a background color.
I want to add a shadow to this circle.
Is that possible?
I'm seeing conflicting information, with people saying that's inside the image, so you can't apply any styles to it, and other people suggesting that a style like that exists or there is a way to do it.
You can use the box-shadow property:
.oval {
width: 100%;
height: 30%;
border-radius: 250px;
font-weight: bold;
line-height: 2em;
font-size: 1em;
text-align: center;
box-shadow:0 0 2px 2px #999;
}
<div class="oval">text</div>
I think you are looking for box shadow:
-webkit-box-shadow: 0px 0px 30px 0px rgba(0, 0, 255, 0.67);
-moz-box-shadow: 0px 0px 30px 0px rgba(0, 0, 255, 0.67);
box-shadow: 0px 0px 30px 0px rgba(0, 0, 255, 0.67);
This link explains it: http://www.w3schools.com/cssref/css3_pr_box-shadow.aspAnd this link lets you experiment with it: http://www.cssmatic.com/box-shadow
Use box-shadow property:
.oval {
width: 150px;
height: 150px;
border-radius: 150px;
font-weight: bold;
font-size: 1em;
color: #fff;
text-align: center;
display: block;
background-color: red;
box-shadow: 3px 3px 3px #aaa;
}
<div class="oval"></div>
Box Shadow!
https://developer.mozilla.org/en-US/docs/Web/CSS/box-shadow
.circle {
width: 150px;
height: 150px;
background-color: yellow;
border-radius: 50%;
box-shadow: 5px 5px 5px #BC7046;
position: absolute;
top: 10px;
left: 10px;
}
.circle2{
box-shadow: -6px -6px 6px #BCAE46;
}
#square {
border-radius: 5px;
width: 170px;
height: 170px;
background-color: #D0DA72;
position: relative;
}
<div id=square>
<div class=circle></div>
<div class='circle circle2'></div>
</div>

Resources