1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100
| * {
margin: 0; padding: 0; border: 0;
}
/* ------------------------------- */
/* MENU */
#navMain {
max-width: 150px;
position: relative;
width: 100%;
margin: 0 auto;
font-family: Verdana, Arial;
}
#navMain ul, #navMain li, #navMain a {
position: relative;
padding: 0;
margin: 0;
border: 0;
text-decoration: none;
}
#navMain ul li {
display: block;
}
#navMain ul li a {
display: block;
color: #FFFFFF;
padding: 10px 10px;
position: relative;
text-shadow: 2px 1px 1px #000000; /* Ombrage */
}
/* --------------- */
/* MENU : niveau 1 */
#navMain > ul > li > a {
background: #FF8727;
box-shadow: 0 1px 0 #FF9D4F inset, 0 -1px 0 #DD6403 inset;
}
/* --------------- */
/* MENU : niveau 1 ACTIF - Sous-Menu ouvert par defaut */
#navMain > ul > li.active > a { background: #20638f; }
/* --------------- */
/* MENU : niveau 2 et suivants */
#navMain ul ul > li > a {
padding-left: 20px; /* Ecarts gauches sous-menus */
font-size: 75%;
}
#navMain ul ul > li {
background: #333;
box-shadow: 0 1px 0 #444 inset, 0 -1px 0 #222 inset;
}
#navMain ul ul ul > li {
background: #444;
}
/* --------------- */
/* hover */
#navMain > ul > li:hover > a {
background: #DD6403;
}
#navMain ul li:hover {
background: #DD6403;
box-shadow: 0 1px 0 #FF9D4F inset, 0 -1px 0 #DD6403 inset;
}
/* --------------- */
/* avec sous-menu */
#navMain li.hasSub > ul {
display:none; /* on masque */
}
/* ------------------------------- */
/* fleche, avec rotation */
#navMain .hasSub:after {
position: absolute;
content: '\25BC';
display: block;
font-size: 0.7em;
color: #fff;
top: 14px;
right: 10px;
cursor: pointer;
-o-transition: -o-transform 0.5s;
-ms-transform: rotate(0deg);
-moz-transform: rotate(0deg);
-moz-transition: -moz-transform 0.5s;
-webkit-transform: rotate(0deg);
-webkit-transition: -webkit-transform 0.5s;
transform: rotate(0deg);
transition: transform 0.5s;
}
#navMain .hasSub.open:after {
-o-transition: -o-transform 0.5s;
-ms-transform: rotate(180deg);
-moz-transform: rotate(180deg);
-moz-transition: -moz-transform 0.5s;
-webkit-transform: rotate(180deg);
-webkit-transition: -webkit-transform 0.5s;
transform: rotate(180deg);
transition: transform 0.5s;
}
/* ------------------------------- */
/* SPECIAL : class active - menu actif */
#navMain > ul > li.active > a { background: #DD6403; } |