html - Building a Product Box using images w/ CSS -
i designed basic looking box in photoshop use show product information inside of. consists of header, body , button (each separate image) image below.
how can use css/html piece these together? need show header text in top box , bullet points in body area, not sure how build image files.
i know html such, confused how build box, such stacking images , overlaying button in position on body.
<div id="product_box"> <div id="header">title here</div> <div id="body"> <ul> <li>point here</li> <li>point here</li> <li>point here</li> </ul> </div> <div id="button></div> </div>
well have at:
you don't have change html
markup use css
:
here relevant css:
#product_box{ border:2px solid #bbc; border-radius:15px; display:block; width:50%; height:100%; position:relative; box-shadow: 5px 5px 5px rgba(0,0,0,0.5); padding:0px; !important background: #b5bdc8; /* old browsers */ /* gradient */ background: -moz-linear-gradient(top, #b5bdc8 0%, #828c95 36%, #28343b 100%); /* ff3.6+ */ background: -webkit-gradient(linear, left top, left bottom, color-stop(0%,#b5bdc8), color-stop(36%,#828c95), color-stop(100%,#28343b)); /* chrome,safari4+ */ background: -webkit-linear-gradient(top, #b5bdc8 0%,#828c95 36%,#28343b 100%); /* chrome10+,safari5.1+ */ background: -o-linear-gradient(top, #b5bdc8 0%,#828c95 36%,#28343b 100%); /* opera 11.10+ */ background: -ms-linear-gradient(top, #b5bdc8 0%,#828c95 36%,#28343b 100%); /* ie10+ */ background: linear-gradient(to bottom, #b5bdc8 0%,#828c95 36%,#28343b 100%); /* w3c */ filter: progid:dximagetransform.microsoft.gradient( startcolorstr='#b5bdc8', endcolorstr='#28343b',gradienttype=0 ); /* ie6-9 */ } #header{ background:#aaf; width:100%; height:50px; border:0px; border-bottom:1px solid #99b; padding-top:15px; padding-bottom:15px; border-radius:5px; background: #b5bdc8; /* old browsers */ /* gradient */ background: -moz-linear-gradient(top, #b5bdc8 0%, #828c95 36%, #28343b 100%); /* ff3.6+ */ background: -webkit-gradient(linear, left top, left bottom, color-stop(0%,#b5bdc8), color-stop(36%,#828c95), color-stop(100%,#28343b)); /* chrome,safari4+ */ background: -webkit-linear-gradient(top, #b5bdc8 0%,#828c95 36%,#28343b 100%); /* chrome10+,safari5.1+ */ background: -o-linear-gradient(top, #b5bdc8 0%,#828c95 36%,#28343b 100%); /* opera 11.10+ */ background: -ms-linear-gradient(top, #b5bdc8 0%,#828c95 36%,#28343b 100%); /* ie10+ */ background: linear-gradient(to bottom, #b5bdc8 0%,#828c95 36%,#28343b 100%); /* w3c */ filter: progid:dximagetransform.microsoft.gradient( startcolorstr='#b5bdc8', endcolorstr='#28343b',gradienttype=0 ); /* ie6-9 */ } #body{ padding-bottom:15px; } #button{ background:#756; border:1px solid #645; display:block; width:150px; height:50px; border-radius:5px; position:absolute; bottom:-25px; right:33%; color:#fff; box-shadow:5px 5px 5px rgba(0,0,0,0.4); text-align:center; font-weight:bolder; font-size:15px; background: #b5bdc8; /* old browsers */ /* gradient */ background: -moz-linear-gradient(top, #b5bdc8 0%, #828c95 36%, #28343b 100%); /* ff3.6+ */ background: -webkit-gradient(linear, left top, left bottom, color-stop(0%,#b5bdc8), color-stop(36%,#828c95), color-stop(100%,#28343b)); /* chrome,safari4+ */ background: -webkit-linear-gradient(top, #b5bdc8 0%,#828c95 36%,#28343b 100%); /* chrome10+,safari5.1+ */ background: -o-linear-gradient(top, #b5bdc8 0%,#828c95 36%,#28343b 100%); /* opera 11.10+ */ background: -ms-linear-gradient(top, #b5bdc8 0%,#828c95 36%,#28343b 100%); /* ie10+ */ background: linear-gradient(to bottom, #b5bdc8 0%,#828c95 36%,#28343b 100%); /* w3c */ filter: progid:dximagetransform.microsoft.gradient( startcolorstr='#b5bdc8', endcolorstr='#28343b',gradienttype=0 ); /* ie6-9 */ } div{ text-align:center; color:#fff; font-weight:bold; }
and here output of that:
edit
according comment here updated code:
and output:
hope helps.
Comments
Post a Comment