css3

Hide a div When Clicked outside of the div

I try to create a custom drop-down. I want to make it works as default drop-down like hide all the option when i clicked outside of the div. As far as i try to make it, i can hide all option when i clicked outside of the div (inside the document). But when i clicked on Browser URL or Title…
Read more

css and html height and width?

When I zoom in or out my element is moving and I’ve tried every code I know but it’s still the same, so I’ve posted my html and css code and I hope you can help me. I have this problem with every element I put in my page <!DOCTYPE html> //html code <html> <head> // head tag <title></title> <link…
Read more

CSS Centering is by top left of inner element

I’m trying to center an inner element using CSS, and for some reason the inner element is centering based on the top left corner, rather than its center: http://codepen.io/anon/pen/WvxeEo HTML: <div class=”topic”> <span class=”title-box”>hello!</span> </div> CSS: .topic { background-color: #84BACE; border: 1px solid #e8e8e8; width:500px; height:500px; position: relative; } .title-box { background-color: #000; color: #fff; font-size: 60px; position: absolute; top:…
Read more

What is the most perfect border radius, 4px or 5px?

In CSS, when setting a border radius in pixels it calculates a radius for us. For example I can set 4px or 5px. What is the perfect border radius of these two? With perfect I mean where it matches the screen pixels the best. There are pixel perfect fonts and pixel perfect icons. What are the pixel perfect border radius?…
Read more

2 different background colours?

How can I have 2 different background colors, like below: http://i.imgur.com/Vz351e5.png The grid I’m working with is 970px wide. I want a sidebar that’s 220 pixels wide (on the left, behind the red) and the main content at 750px (on the right, behind the blue). How can I do this? Source: css3

How to set fixed width of td within a fixed table layout

I have been unsuccessful trying to set a width of the first td/th cell within a table using table layout fixed https://jsfiddle.net/4m5vf9zb/101/ #standings { display: table; table-layout: fixed; width: 100%; margin: 0 auto; } #division00,#division01 { display: table-cell; vertical-align: middle; } .standingslogo { display: block; max-width: 100%; margin:0 auto; } th.ficonname{ width: 400px; } Source: css3

How to reverse order of cols in responsive Bootstrap 3?

DEMO: http://jsfiddle.net/su0ae5v9/ HTML: <div class=”container”> <div class=”row”> <div class=”col-sm-6 text-center”> image </div> <div class=”col-sm-6 text-center”> desctiption </div> </div> <div class=”row”> <div class=”col-sm-6 text-center reverse”> desctiption </div> <div class=”col-sm-6 text-center reverse”> image </div> </div> <div class=”row”> <div class=”col-sm-6 text-center”> image </div> <div class=”col-sm-6 text-center”> desctiption </div> </div> <div class=”row”> <div class=”col-sm-6 text-center reverse”> desctiption </div> <div class=”col-sm-6 text-center reverse”> image </div>…
Read more

CSS3 animate margins

Trying to animate in CSS3 margins. Which this site seems to say you can, but it’s not working for me. Here is a jsFiddle: http://jsfiddle.net/ybh0thp9/3/ (Click on a section to see animation toggle). Here is my CSS: .section{ display: block; animation: fadeIn .5s ease, margin-top .5s ease, margin-bottom .5s ease; } .section.open { margin: 20px 0; } I actually have…
Read more