/************************************************

Общие для всех страниц CSS-определения

************************************************/


/* COMMON */
body {
    margin: 0;
    padding: 0;
}


/*** TITLE ***/
div#page-title {
    position: fixed;
    left: 0;
    top: 0;
    right: 0;
    background: url(img/title-x.png) repeat-x;
    margin: 0;
    padding: 0;
    z-index: 2;
}
#page-title table {
    width:100%;/*для совместимости со старыми браузерами*/
    width:100vw;/*так не дергается из-за скроллбара*/
    z-index:2;
    border: 0;
    border-spacing: 0;
    background: url(img/title.png) no-repeat;
    user-select: none;
    margin: 0;
    padding: 0;
    height: 76px;
}
#page-title td {
    position: relative;
    text-align: center;
}

#page-title-logo {
    white-space: nowrap;
    vertical-align: middle;
    background: url(img/logo.png) no-repeat 10px 50%;
    padding: 0;
    width: 150px;
}
#page-title-logo a {
    display: block;
}
#page-title-logo #product {
    width: 130px;
    height: 52px;
}
#page-title-logo #version {
    font-size: 10pt;
    position: relative;
    text-align: left;
    color: #fff;
    text-decoration: none;
    margin-left: 4em;
}
#page-title-logo #version:hover {
    text-decoration: underline;
}
#page-title h1, #page-title h2 {
    margin: 0;
    padding: 0;
    font-weight: bold;
    color: #fff;
    text-align: center;
    text-shadow:2px 2px 3px rgba(0,0,0,0.5);
    white-space: nowrap;
}
#page-title h1 {
    font-size: 14pt;
}
#page-title h2 {
    font-size: 11pt;
}

#page-title td.no-login {
    width: 10%;
}

#page-title td.help {
    width: 1%;
    vertical-align: top;
}
#page-title td.help a {
    display: block;
    width: 21px;
    height: 21px;
    background: url(img/help.png) no-repeat 0 0;
    margin-top: 6px;
    margin-right: 5px;
}
#page-title td.help a:hover {
    background-image: url(img/help-a.png);
}

#page-title td.login {
    font-size: 10pt;
    width: 100px;
    background: url(img/key.png) no-repeat 0 0;
    padding-left: 17px;
    text-align: left;
}
#page-title td.login div {
    height: 2em;
    line-height: 100%;
    padding: 3px 6px;
    color: #fff;
}
#page-title td.login a {
    padding: 3px 6px;
    color: #ddd;
    text-decoration: none;
    font-weight: bold;
}
#page-title td.login a:hover {
    color: #000;
    background: #e80;
}


/*** PANEL ***/
body.form {
    background-color: #dad4cc; /*#dad8cc;*/
}

#page-panel {
    position: fixed;
    left: 0;
    top: 76px;
    height: 100%;
    margin: 0;
    z-index: 2;
    color: #000;
    background-color: #dad4cc;
    border-right: solid 1px #b7b5a6;
    user-select: none;
}

#page-panel div {
    padding: 1ex 2.5ex 0 1.4ex;
}
#page-panel form {
    padding: 0;
    margin: 0;
}

#page-panel dl {
    font: inherit;
    font-size: 100%;
    margin: 0;
    user-select: none;
}
#page-panel dd {
    position: relative;
    margin-left: 0;
    margin-bottom: 0.5em;
}

#page-panel select,
#page-panel input[type=text],
#page-panel input[type=password],
#page-panel input[type="datetime-local"],
#page-panel input[type="date"],
#page-panel textarea,
#page-panel dt.warning {
    width: 27ex;
    padding: 0.2ex;
    box-sizing: border-box;
    -moz-box-sizing: border-box;
    border: 1px solid #767676;
}

#page-panel dt.warning {
    padding: 0.5ex;
    border: none;
    margin-bottom: 0.5em;
}

#page-panel select,
#page-panel input[type=text],
#page-panel input[type=password] {
    height: 1.8em;
}

#page-panel input[type=text],
#page-panel input[type=password],
#page-panel textarea {
    padding-left: 0.3ex;
}

#page-panel input[type=submit] {
    font-size: 110%;
    padding: 5px 20px;
    margin: 0 6px 0 20px;
    float: right;
}

#page-panel textarea {
    resize: none;
}

#page-panel select.changed,
#page-panel input.changed,
#page-panel textarea.changed {
    background-color: #ffc;
}

#page-panel select:disabled {
    color: #000;
}

#page-panel input:disabled {
    color: #000;
    background-color: #fff;
}

#page-panel dd button {
    margin-top: 0.5em;
}

#page-panel button {
    padding: 0.7ex 1ex;
    width: 100%;
}

#page-panel .H {
    display: none;
}

dt.separator {
    height: 1em;
    background-image: url(img/h-sprt.png);
    background-position: 0% 30%;
    background-repeat: repeat-x;
    margin: 0 -16px;
}

#page-panel a.link {
    display: block;
    margin: 0.3em 0;
    color: #03d;
}

#page-panel dt.comment {
    padding: 0.2ex;
    width: 12em;
}

#page-panel .error {
/*    background-color: #fcc;
    color: #000;*/
    color: #c00;
}

#page-panel select.error option {
    color: #000;
}

#page-panel dd.value {
    margin-left: 1em;
}
#page-panel dd.value span {
    font-weight: bold;
    color: #333;
}
#page-panel dd.value.red span {
    color: #d00;
}



/*** PAGE-MENU ***/
#page-title-menu {
    white-space: nowrap;
    padding: 6px 0 4px 0;
    line-height: 100%;
    font-size: 9pt;/*100%;*/
}

#page-title-menu a {
    color: #ddd;
    text-decoration: none;
    font-size: 9pt;/*100%;*/
    font-weight: bold;
    padding: 0.4em 0.5em;
    text-align: left;
}
#page-title-menu a small {
    font-weight: normal;
    font-size: 7pt;
}

#page-title-menu a.sel {
    color: #e80;
}
#page-title-menu a:hover {
    color: #000;
    background: #e80;
}
#page-title-menu div {
    position: absolute;
    z-index: 3;
    display: none;
    padding: 3px;
    background-color: #232F3B;
    border: solid 1px #4A5764;
    box-shadow:3px 3px 4px rgba(0,0,0,0.5);
}
#page-title-menu div.sel {
    display: block;
}
#page-title-menu div > a {
    display: block;
}
#page-title-menu div hr {
    border: 0;
    height: 2px;
    background: url(img/hr.png) repeat-x;
    margin: 0.5ex;
}

/*** CONTENT ***/
#page-content {
    position: absolute;
    margin: 0;
    padding: 0;
    left: 0;
    right: 0;
}

#page-wrapper {
    padding: 1em 1em 4em 1em;
}

.dialog-box{
    display: none;
}

.page-form {
    background: #F1F0E8;
}

div.error-box {
    position: absolute;
    width: 20em;
    margin: 0;
    padding: 0;
    box-shadow: 3px 3px 4px rgba(0,0,0,0.5);
    background-color: #FF6B6B;
    border: 2px solid #FF4F4F;
    border-radius: 9px;
    font-size: 90%;
    font-weight: bold;
    color: #000;
    z-index:1000;
}
div.error-box p {
    margin: 0;
    padding: 1ex;
}


/* TABLE-HEAD */
.page-table-heads {
    position: fixed;
    margin: 0;
    padding: 0;
    top: 0;
    left: 0;
    z-index: 1;
}

body > .page-table-heads {
    top: 76px;
    left: 159px;
}

.page-table-heads table {
    /*width: 100%;*/
    table-layout: fixed;
    background: #E0E0E0;
    border-spacing: 0;
}

.page-table-heads th {
    color: #444;
    text-shadow: 1px 1px 1px #fff;
    border-top: #fff solid 1px;
    border-left: #fff solid 1px;
    border-right: #ccc solid 1px;
    border-bottom: #ccc solid 1px;
    padding: 0.5em 0;
    text-align: center;
    white-space: nowrap;
    overflow: hidden;
    border-spacing: 0;
    user-select: none;
    cursor: default;
}

.page-table-heads th.sort.asc, .page-table-heads th.sort.desc {
    background: #EFEFEF;
    background-repeat: no-repeat;
}

.page-table-heads th.sort.asc {
    background-image: url(img/sort-asc.png);
    background-position: right bottom;
}

.page-table-heads th.sort.desc {
    background-image: url(img/sort-desc.png);
    background-position: right top;
}

/* TABLE-LIST */
table.list {
    /*width: 100%;*/
    border-spacing: 0;
    table-layout: fixed;
    background: #fff;
    border-collapse: collapse;
}

table.list thead, .page-table-heads th.H, table.list th.H, table.list td.H {
    display: none;
}

table.list tr {
    height: 1.8em;
}

table.list td {
    padding: 0.35em 0.4em;
    border-spacing: 0;
    white-space: nowrap;
    overflow: hidden;
}

table.list td.C {
    padding: 0.35em 0;
}

table.list.editing td {
    cursor: pointer;
}

table.list tr:focus {
    /*outline: none !important;*/
    outline: none;
}

table.list.edited tr:focus td {
    background-color: highlight;
}

table.list.edited tr:focus td {
    color: highlighttext;
}

table.list.viewed tbody td {
    border-bottom: #ddd solid 1px;
}

table.list.viewed tr.selected td {
    background-color: highlight !important;
}

table.list.viewed tr.selected td, table.list.viewed tr.selected td * {
    color: highlighttext !important;
}

table.list td.edit input {
    padding: 0 0.1em;
    width: auto;
}

div.clearance {
    text-align: center;
    padding: 2em 0 3em 0;
    color: #888;
}

/*************** Progress-bar сохранения ***************/
#progressor {
    padding: 1em;
    display: none;
}
#progressor div {
    width: 24em;
    box-sizing: border-box;
    -moz-box-sizing: border-box;
}
#progressor .outerbar {
    position: relative;
    height: 0.3em;
    margin: 1em auto;
    background: #eee;
    background: rgba(255, 255, 255, 0.5);
}
#progressor .innerbar {
    position: absolute;
    top: 0px;
    left: 0px;
    height: 100%;
    width: 0%;
    background: #06a;
    background: rgba(0, 0, 0, 0.5);
}
#progressor .msg {
    margin: 1em auto;
    height: 4em;
    overflow: hidden;
}

/*@media screen {
    body.journal {
        overflow-y: scroll;
    }
}*/


/************************************************
PRINT PRINT PRINT PRINT PRINT PRINT PRINT PRINT
        скрываем непечатные элементы
************************************************/
@media print {

    html {
        height: auto;
    }

    body {
        height: auto;
        overflow: auto;
        position: relative;
        font-size: 8pt;
    }

    div.ui-dialog, form, select, button {
        display: none;
    }

    /*** TITLE ***/
    div#page-title {
        position: static;
        background: none;
        padding: 0 0 2em 0;
    }
    #page-title table {
        background: none;
        height: auto;
    }
    #page-title-tr1 {
        display: none;
    }
    #page-title tr.no-print {
        display: none;
    }
    #page-title h1, #page-title h2 {
        color: #555;
        text-shadow: none;
    }

    #page-panel {
        display: none;
    }

    #page-content {
        position: relative;
        top: 0 !important;
        left: 0 !important;
        overflow: hidden !important;
    }

    #page-wrapper {
        padding: 0;
    }

    /* TABLE-HEAD */
    .page-table-heads {
        display: none;
    }

    table.list thead {
        display: table-header-group;
    }
    table.list thead th {
        border-bottom: #DDD solid 1px;
        text-align: left;
    }


    /* TABLE-BODY */
    table.list.viewed tr.selected td, table.list.viewed tr.selected td * {
        color: #000 !important;
    }
    table.list.viewed tr.selected td {
        background: none;
    }

    div.clearance {
        display: none;
    }

}
