.nav {

margin-top: -15px;
	
position: relative;
    width: 190px;
    box-shadow:0 2px 2px rgba(0,0,0, .5);
    -moz-box-shadow:0 2px 2px rgba(0,0,0, .5);
    -webkit-box-shadow:0 2px 2px rgba(0,0,0, .5);
	background:#435982;
}


/* Top Level Menu */
.nav ul {
	z-index:100;
    font-size: 16px;
    font-weight:bold;
    color: transparent;
    text-decoration:none;
    display:block;
    padding:0px 0px;
	background:#435982;
    box-shadow:0 2px 2px rgba(0,0,0, .5);
    -moz-box-shadow:0 2px 2px rgba(0,0,0, .5);
    -webkit-box-shadow:0 2px 2px rgba(0,0,0, .5);
}

/* Top level list items */
.nav ul li {
    position: relative;
}

/* Top level menu items link style */
.nav ul li a, .nav ul li span {
    display: block;
    position: relative;
    /* background of menu items (default state) */
    background: #435982;
    color: white;
    padding: 14px 10px;
    color: #435982;
    text-decoration: none;
}


.nav ul li a:link, .nav ul li a:visited {
    color: white;
}

/* Top level menu items link style on hover and when active */
.nav ul li:hover > a {
	 background:#df691a;
    color:white;

	box-shadow:0 1px 1px rgba(0,0,0, .7); /*немного css3*/
    -moz-box-shadow:0 1px 1px rgba(0,0,0, .7);
    -webkit-box-shadow:0 1px 1px rgba(0,0,0, .7);
}

/* Sub ULs style */
.nav ul li ul {
    position: absolute;
    left: -5000px;
		top: 0;
    opacity: 0;
    width: 190px;
    visibility: hidden;
    box-shadow: 2px 2px 5px gray;
    -webkit-transition: opacity .3s, visibility 0s .3s, left 0s .3s;
    transition: opacity .3s, visibility 0s .3s, left 0s .3s;
}

/* First Sub Levels UL style on hover */
.nav ul li:hover > ul {
    visibility: visible;
    left: 100%;
    opacity: 1;
    -webkit-transition: opacity .5s;
    transition: opacity .5s;
}

/* Sub level Menu list items (alters style from Top level List Items) */
.nav ul li ul li {
    display: list-item;
    float: none;
}

/* 2nd and beyond Sub Levels vertical offset after 1st level sub menu */
.nav ul li ul li ul {
    top: 0;
    left: 100%;
}

/* Sub Levels link style on hover and when active */
.nav ul ul li:hover > a {
	background:#df691a;
    color:white;
	
	box-shadow:0 1px 1px rgba(0,0,0, .7); /*немного css3*/
    -moz-box-shadow:0 1px 1px rgba(0,0,0, .7);
    -webkit-box-shadow:0 1px 1px rgba(0,0,0, .7);
}

/* Sub Levels UL style on hover */
.nav ul ul li:hover > ul {
    left: 100%;
}

/* Sub level menu links style */
.nav ul li ul li a {
	font: bold 16px Cambria, "Hoefler Text", "Liberation Serif", Times, "Times New Roman", serif, sans-serif;
	font-size:16px;
    font-weight:bold;
    
    padding: 10px;
    margin: 0;
    background:#435982;
    border-right: none;
    border-top-width: 0;
}

/* LIs with a sub UL style */
.nav ul li > a {
    /* add padding to accomodate arrow inside LIs */
    padding-right: 25px;
}

/* LIs with NO sub UL style */
.nav ul li > a:only-child {
    /* undo padding for non submenu LIs */
    padding-right: 10px;
}

/* LIs with a sub UL pseudo class */
.nav ul li > a:after {
    /* add arrow inside LIs */
    content: "";
    position: absolute;
    height: 0;
    width: 0;
    border: 5px solid transparent;
    border-left-color: #FFFFFF;
    top: 40%;
    right: 8px;
}

/* LIs with NO sub UL pseudo class */
.nav ul li > a:only-child:after {
    /* undo arrow for non submenu LIs */
    display: none;
}


/* ####### responsive layout CSS ####### */

@media (max-width: 923px) {
    /* FIRST breaking point
			Last top menu items' sub ULs should drop to the left (instead of right)
			Change 1 to a different number to exclude/include more top menu items based on menu and max-width setting above
		*/

		.nav ul li:nth-last-of-type(-n+1) ul li:hover > ul {
        left: -100%;
    }
}

@media (max-width: 500px) {
    /* SECOND breaking point 
			For mobile and screen browser windows
			Get Sub ULs to expand entire width of document and drop down
			Changes menu reveal type from "visibility" to "display" to overcome bug. See comments below
		*/
    .nav{
        width: 100%;
    }
    
    .nav ul li > a:after {
        /* add arrow inside LIs */
        content: "";
        position: absolute;
        height: 0;
        width: 0;
        border: 5px solid transparent;
        border-left-color: transparent;
        border-top-color: #fff;
        top: 40%;
        right: 8px;
    }

	.nav ul li {
        position: static;
    }

    .nav ul li ul {
        width: 100%;
        border-top: 2px solid rgba(0,0,0,.6);
		/* change menu reveal type from "visibility" to "display". Former seems to cause browser to jump to top of page sometimes when menu header is tapped on */
		display: none;
    }
h
    .nav ul li:hover > ul {
		display: block;
        left: 0 !important;
        top: auto;
        box-shadow: 0 0 12px gray;
    }


}
/* Пункт "Главная" (значок) */
.home-icon {display: inline-block; }
.home-icon a {background: url(/sm.aspx?guid=1463) center no-repeat; display: inline-block; min-width: 32px; padding: 0 0.8em; text-indent: -9999px; }
.home-icon a:hover, .home-icon-active a {background: url(/sm.aspx?guid=1563) center no-repeat;}