#header { /* DIV */
    display: flex; /* a header egy flexbox része, de maga is egy flexbox */
    flex-shrink: 0;
    position: relative; /* a lenyíló menük pozíciója miatt kell */
    margin: 0;
    padding: 0;
    z-index: 100;
    height: 44px; /* 40H + 4border-width */
    font-size: 12px;
    font-family: 'Verdana';
    white-space: nowrap;
}

/* minden menüpont */
#header a {
    color: inherit;
    text-decoration: none;
    border: none;
    display: inline-block;
    outline: none;
}

/* --- LOGO <DIV> --------------------------------------------------------- */

#header #hlogo {
    font-family: "Candara","Trebuchet MS", "Franklin Gothic", sans-serif;
    font-weight: bold;
    font-size: 20px;
    text-shadow: 2px 2px rgba(0,0,0,0.4);
    line-height: 40px;
    padding: 0 14px 0 10px;
    border-right: 1px solid #555;
    background: #8E8E8E;
}


/* --- MENÜ --------------------------------------------------------------- */

/* a főmenük és almenük fő <UL>-je */
#header ul {
    display: block;
    margin: 0;
    padding: 0;
    list-style-type: none;
}

/* --- FŐMENÜ --- */

/* a fő menüpontok containerei */
#header > ul > li {
    display: inline-block;
    margin: 0;
    padding: 0;
}

/* a fő menüpontok */
#header > ul > li > a {
    display: flex;
    align-items: center; /* align vertical */
    margin: 0;
    padding: 0px 20px;
    height: 40px;
    cursor: pointer;
}

/* a fő menüpontok thumbnailjei */
#header > ul > li > a > span:first-child {
    margin-right: 5px;
    height: 24px;
    width: 24px;
    background-size: cover;
    background-position: center center;
    background-repeat: no-repeat;
}

/* a fő menüpontok szövege */
#header > ul > li > a > span+span {
    max-width: 150px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* --- ALMENÜK --- */

/* az almenük containere */
#header > ul > li div {
    display: none;
    position: absolute;
    padding-top: 4px; /* = #header border-bottom-width */
    z-index: 99;
    box-shadow: rgba(0, 0, 0, 0.172549) 0px 6px 12px 0px;
    line-height: 40px;
}
/* almenük látszanak, ha a főmenüpont hoover állapotban van */
#header > ul > li:hover div {
    display: block;
}

/* almenük <UL> */
#header > ul ul {
    position: relative;
    left: -1px; /* főmenüpont border-left miatt */
    min-width: 220px;
}

/* az almenük pontjai */
#header > ul ul li a {
    display: block;
    padding: 0px 15px;
}

#header > ul ul li.selected a::before {
    content: '► ';
}

/* --- FILLER <DIV> --------------------------------------------------------- */

#filler {
    flex-grow: 1;
}

/* --- USER  ---------------------------------------------------------------- */

#header > ul.usermenu > li > a {
    padding: 0 10px;
    border: none !important;
}

/* thumbnail */
#header > ul.usermenu > li > a > span:first-child {
    border-radius: 5px;
    height: 32px;
    width: 32px;
}

#header > ul.usermenu div {
    right: 0;
}

#header > ul.usermenu ul {
    min-width: 0;
    left: 0;
}


/* --- TÉMASZÍNEK ----------------------------------------------------------- */

#header {
    color: white;
    background: #777;
    border-bottom: 4px solid #555;
}

/* ha kiválaszott ő, vagy a gyermeke */
#header > ul > li.selected > a {
    background: #51A351;
}

#header > ul > li > a {
    border-right: 1px solid #555;
}
#header > ul > li:first-child > a {
    border-left: 1px solid #555;
}

/* a fő menüpontok hoover állapotban */
#header > ul > li:hover > a, /* a fő menüpontok hoover állapotban */
#header > ul ul a:hover { /* az almenük pontjai hoover állapotban */
    background-color: #51A351;
    color: white;
}

/* almenük */
#header > ul ul {
    color: #333;
    background: white;
    border-bottom: 1px solid #BFBFBF;
    border-left: 1px solid #BFBFBF;
    border-right: 1px solid #BFBFBF;
}

#header > ul ul > li.selected {
    color: green;
    background: #DBEBD5;
    /*color: white;
    background: #51A351;*/

}

/* --- TOOLBAR -------------------------------------------------------------- */

#toolbar {
    position: relative;
    flex-shrink: 0;
    height: 41px;
    padding: 0;
    z-index: 80;
    box-shadow: 0px 4px 7px rgba(0,0,0,0.25);
    background: #F9F9F9;
    font-size: 12px;
    font-family: Verdana, sans-serif;
    line-height: 40px;
    vertical-align: top;

    -webkit-touch-callout: none;
    -webkit-user-select: none;
    -khtml-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
}

#toolbar > * {
    display: inline-block; /* rés van köztük a sortörés miatt (float esetén nincs) */
    margin: 0;
    padding: 0 10px;
    border-right: 1px solid #DDD;
    border-radius: 10px;
}

#toolbar > *.noborder {
    border: none;
    padding-right: 0;
}

#toolbar .tbutton {
    padding: 5px 13px;
}