/* Common menu definition.
   Adapted from http://www.red-team-design.com/wp-content/uploads/2011/11/css3-animated-dropdown-menu-demo.html */

.menu, .menu ul {
  padding: 0;
  list-style: none;
}

.menu:before,
.menu:after {
  content: "";
  display: table;
}

.menu:after {
  clear: both;
}

.menu {
  zoom:1;
}

.menu a:link,.menu a:hover,.menu a:active,.menu a:visited
{color:black;}

.menu div a:link,.menu div a:hover,.menu div a:active,.menu div a:visited
{color:#444;}

.menu li {
  float: left;
  position: relative;
  border-radius: 10px;
  font-variant:small-caps;
}
.menu div {
  font-variant:normal;
}
.menu div:hover,
.menu li:hover
{
  background-color:#ffb100;
  background-image: -moz-linear-gradient(#ffc400,  #ffb100);
  background-image: -webkit-gradient(linear, left top, left bottom, from(#ffc400), to(#ffb100));
  background-image: -webkit-linear-gradient(#ffc400, #ffb100);
  background-image: -o-linear-gradient(#ffc400, #ffb100);
  background-image: -ms-linear-gradient(#ffc400, #ffb100);
  background-image: linear-gradient(#ffc400, #ffb100);
}

.menu a {
  float: left;
  padding: 6px 3px;
  color: #333;
  text-decoration: none;
  text-shadow: 0 1px 0 #CCC;
  margin:0; width:100%; height:100%;
}

/* changes text colour on hover
.menu li:hover > a {color: #fafafa;}
*html .menu li a:hover { / * IE6 only * / color: #fafafa;}
*/


.menu li:hover > ul,
.menu li.sfHover > ul {
  opacity: 1;
  visibility: visible;
}

.menu ul {
  opacity: 0;
  visibility: hidden;
  position: absolute;
  z-index: 5;
  -moz-box-shadow: 0 -1px rgba(255,255,255,.3);
  -webkit-box-shadow: 0 -1px 0 rgba(255,255,255,.3);
  box-shadow: 0 -1px 0 rgba(255,255,255,.3);
  -moz-border-radius: 10px;
  -webkit-border-radius: 10px;
  border-radius: 10px;
}

.menu ul,
.menu ul div {
  background: #f9f9f9;
  background-image: -webkit-gradient(linear, left top, right top, from(#fff), to(#ddd));
  background: -webkit-linear-gradient(left, #fff, #ddd);
  background: -o-linear-gradient(right, #fff, #ddd);
  background: -moz-linear-gradient(right, #fff, #ddd);
  background: -ms-linear-gradient(right, #fff, #ddd);
  background: linear-gradient(to right, #fff, #ddd);
}

.menu ul div {
  font-size: 0.8em;
  padding: 0 7px;
}

.menu ul div:before {
  content:"";
  display:block;
  margin: 0px 5px;
  border-top: 1px solid #999;
}


.menu ul ul {
  top: 0;
  margin: 0 0 0 20px;
  _margin: 0; /*IE6 only*/
  -moz-box-shadow: -1px 0 0 rgba(255,255,255,.3);
  -webkit-box-shadow: -1px 0 0 rgba(255,255,255,.3);
  box-shadow: -1px 0 0 rgba(255,255,255,.3);
}

.menu ul li {
  float: none;
  display: block;
  border: 1px solid black;
  border-bottom: 0;
  border-radius: 0px;
  _line-height: 0; /*IE6 only*/
  -moz-box-shadow: 0 1px 0 #AAA, 0 2px 0 #FFF;
  -webkit-box-shadow: 0 1px 0 #AAA, 0 2px 0 #FFF;
  box-shadow: 0 1px 0 #AAA, 0 2px 0 #FFF;
}

.menu ul li:first-child {
  border-top-right-radius: 10px;
  border-top-left-radius: 10px;
}

.menu ul li:last-child {
  -moz-box-shadow: none;
  -webkit-box-shadow: none;
  box-shadow: none;
  border-bottom: 1px solid black;
  border-bottom-right-radius: 10px;
  border-bottom-left-radius: 10px;
}

.menu ul a {
  padding: 10px;
  min-width: 180px;
  _height: 10px; /*IE6 only*/
  display: block;
  white-space: nowrap;
  float: none;
}

.menu ul li:first-child > a {
-moz-border-radius: 3px 3px 0 0;
-webkit-border-radius: 3px 3px 0 0;
border-radius: 3px 3px 0 0;
}

.menu ul li:first-child > a:after {
content: '';
position: absolute;
left: 40px;
top: -6px;
}

.menu ul li:first-child a:hover:after {
border-bottom-color: #04acec;
}

.menu ul ul li:first-child a:hover:after {
border-right-color: #0299d3;
border-bottom-color: transparent;
}

.menu ul li:last-child > a {
-moz-border-radius: 0 0 3px 3px;
-webkit-border-radius: 0 0 3px 3px;
border-radius: 0 0 3px 3px;
}

/* iPad */
.no-transition {
  -webkit-transition: none;
  -moz-transition: none;
  -ms-transition: none;
  -o-transition: none;
  transition: none;
  opacity: 1;
  visibility: visible;
  display: none;
}

.menu li:hover > .no-transition {
  display: block;
}
