@import "Shared";

#layout_PageHeading {
    #Device_Show_Status {
        /*position: absolute;
        right: 20px;
        top: 6px;*/
        margin-left: 20px;
        display: inline-block;
        height: 50px;
        font-family: @FontFamilyHeading;
        font-weight: @FontWeightHeading;
        font-stretch: @FontStretchHeading;
        font-size: 0.7em;
        text-transform: uppercase;

        span.icon {
            margin-right: 6px;
        }
    }
}

#Device_Show {
    #Device_Show_Subjects {
        table-layout: fixed;

        & > tbody > tr > td {
            padding-top: 0;
            height: 100%;

            & > div /* Extra DIV added for FireFox TD relative position incompatibility */ {
                position: relative;

                div.status {
                    margin-top: 2px;
                    padding-top: 2px;
                    border-top: 1px dashed #ddd;
                }

                input.discreet {
                    margin-left: -2px;
                }
            }
        }

            & > tbody > tr > td:not(:last-child) {
                border-right: 1px dashed #aaa;
            }

        #Device_Show_Details {

            table.verticalHeadings {
                & > tbody > tr > td:first-child {
                    width: 104px;
                    font-weight: bold;
                }
            }

            #Device_Show_Details_Asset_Name {
                font-weight: bold;
            }

            #Device_Show_Details_Asset_Enrolled_Trusted {
                display: inline-block;
                height: 16px;
                padding-left: 16px;
                background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAACWUlEQVQ4y6XRXWiSURgHcJsXa4WNNuuyiy6CoAupixERoXXhmljuxaJiFrVA1i72cVFCOSMt8rNt2YfGO5g5Z1NstWW+c4ZBq4QpqMkEbZDSCObAMprjdf90sIjxsgUdODd/zvmd5zwPCwDrf/aGB7q6utgmk8ngdruzVqt10eVyTWu1Wuk/AXK5vMpoNPpjsRgGbU8/9fbdH/J4PAuRSARKpfLKhoBYLG595nTCaDSZVjPp6TPbHQ5H0mAwfBeJRHXrAp0dna9JcqCguX2H/Xd+S625aLFYQBDE8XWBd+8/TI6Njc+vzcfGX4nLX4FOp5OuC0wGAlS53NzaPPAm2Gi32+H3+5tYJEl+pigKoVAIPp+PnpqaosPhMF1uHB2Px2mv14vya6VgMKhhHGN3d/dSMplENptFIpHA3NwcCoUCSqUSKqvScZVKBbPZHGQEFApFMZ1OI5PJIBqNrkD5fB40Ta8AlcrUajVsNpufEbh+42YxHEkh+/UbUqlZpGd/lAH8WTMzMzDd64d7NMAMDOobi/OpHqh6rqK9jcCvBQncQzK0Xm5DPn0BJ4lz6GgVIkedYAaamxqK0dEDePl4FziczehTsZGLs7BnNwdiwRac4lejvp6La83VzABv/8FF/qG9oD/WQS/fhNptHEw8rEJiuAo7ubXACAtH9m0Fu2YHxQzweEuEVIYnaiFmvQ04f1aItksi5KaP4ZFGjDB5GG/7j4LL5YYYgZYW2c/yiJbv6h/A0EvC4RjGiOsFnK4J+KgABmyjsDufL0skki8CgYCoXOLz+TWrwG+kXMkgQ6yv+QAAAABJRU5ErkJggg==) /*Images/Actions/unlocked.png*/;
                background-repeat: no-repeat;
            }

            #Device_Show_GenerateDocument_Container {
                padding-top: 4px;

                #Device_Show_GenerateDocument {
                    padding: 0;
                }
            }
        }

        #Device_Show_Policies {
            table.verticalHeadings {
                & > tbody > tr > td:first-child {
                    width: 120px;
                    font-weight: bold;
                }
            }
        }

        #Device_Show_Aspects {
            #Device_Show_Aspects_Model_Image {
                display: block;
                width: 256px;
                height: 256px;
                margin: 0 auto;
            }
        }

        #Device_Show_Subjects_Actions {
            & > td {
                padding-top: 4px;
            }
        }
    }
}

#DeviceDetailTabs {
    margin-top: 10px;
    /*jQuery Tab Extensions*/
    border-radius: 0;
    background-image: none;
    background-color: @white;
    border: none;
    padding: 0;

    #DeviceDetailTabItems {
        border-radius: 0;
        border-top: 1px solid #ddd;
        border-right: 1px solid #ddd;
        border-left: 1px solid #ddd;
        border-bottom: none;
        padding: 2px 0 0 4px;
        background-image: none;
        background-color: #eee;
        display: table;

        & > li {
            top: 0;
            border-radius: 0;
            margin: 0 5px 0 0;
            padding: 0;
            line-height: normal;
            margin-right: 4px;

            & > a {
                padding: 5px 8px;
            }
        }
    }

    div.ui-tabs-panel {
        border-radius: 0;
        padding: 4px;
        border-right: 1px solid #ddd;
        border-bottom: 1px solid #ddd;
        border-left: 1px solid #ddd;
        border-top: none;
        background-color: #eee;
    }
}

#Device_Show_Policies_Profile_Actions_Update_Dialog, #Device_Show_Policies_Batch_Actions_Update_Dialog {
    ul {
        li {
            background-color: @white;
            padding: 2px 0;

            &:nth-child(odd) {
                background-color: @TableDataRowBackgroundColor;
            }

            &.selected {
                background-color: @TableDataDarkBorderColour;
                font-weight: bold;
            }
        }
    }
}

#DeviceDetailTab-JobsContainer {
    div.jobTable {
        margin: -1px;
        border: 1px solid #ddd;
    }

    .dataTables_wrapper {
        .dataTables_filter {
            margin-top: -24px;
            -moz-opacity: 1;
            opacity: 1;
        }

        .dataTables_length {
            margin-top: -24px;
            -moz-opacity: 1;
            opacity: 1;
        }

        .dataTables_showStatusClosed {
            right: 220px;
            margin-top: -24px;
        }
    }
}

#DeviceDetailTab-DetailsContainer {
    & > table {
        .tableData();

        & > tbody > tr {
            & > th {
                width: 150px;
            }

            & > th, & > td {
                padding: 10px 6px;
            }
        }
    }
}


#deviceShowResources {
    #Attachments {
        padding: 0;
        border: 1px solid @SubtleBorderColour;
        background-color: @white;

        div.attachmentOutput {
            height: 115px;
            overflow: auto;
            font-size: 0.95em;

            & > a {
                display: block;
                float: left;
                height: 48px;
                width: 221px;
                padding: 2px;
                margin: 2px;
                font-size: 0.9em;
                border: 1px solid @white;
                color: @black;
                text-decoration: none;

                span.comments, span.author, span.timestamp {
                    display: block;
                    float: left;
                    width: 168px;
                    overflow: hidden;
                    height: 16px;
                }

                span.author {
                    color: #888;
                    width: 150px;
                }

                span.timestamp {
                    color: #888;
                    font-style: italic;
                }

                span.icon {
                    display: block;
                    float: left;
                    height: 48px;
                    width: 48px;
                    margin-right: 2px;

                    img {
                        height: 48px;
                        width: 48px;
                    }
                }

                &:hover {
                    background-color: @SubtleColour;
                    border: 1px solid @SubtleBorderColour;

                    span.remove {
                        opacity: .5;
                    }
                }

                span.remove {
                    font-size: 1.4em;
                    color: @StatusRemove;
                    margin-left: 6px;
                    cursor: pointer;
                    opacity: 0;

                    &:hover {
                        opacity: 1;
                    }
                }
            }
        }

        div.attachmentInput {
            border-top: 1px solid @SubtleBorderColour;
            height: 40px;
            background-color: @white;
            padding: 3px;

            span.action {
                color: @HeaderBackgroundColour;
                display: block;
                margin: 0 4px 0 0;
                font-size: 1.5em;
                cursor: pointer;
                float: right;
                border: 1px solid @white;
                padding: .5em;

                &:hover {
                    color: @HyperLinkColour;
                    background-color: @SubtleColour;
                    border: 1px solid @SubtleBorderColour;
                }
            }
        }
    }
}

#Devices_Export {
    .Devices_Export_Type_Target {
        margin-top: 10px;
        display: none;
    }

    #Devices_Export_Fields {
        #Devices_Export_Fields_Defaults {
            font-size: .75em;
        }

        th {
            font-size: 1.05em;

            span {
                margin-top: 4px;
                font-size: .8em;
            }
        }
    }
}

#Devices_Export_Download_Dialog {
    padding-top: 20px;
    text-align: center;

    h4 {
        margin-bottom: 30px;
    }

    a {
        margin-bottom: 20px;
    }
}

#Devices_Export_Exporting {
    padding-top: 50px;
    text-align: center;

    i {
        margin-right: 10px;
        color: @StatusInformation;
    }
}

#Devices_Import {
    #ImportFile {
        width: 96%;
        margin-bottom: 8px;
    }

    #Devices_Import_Documentation {
        width: 700px;
        margin: 20px auto;

        & > table > tbody th:first-child {
            width: 220px;
        }
    }
}

#Devices_Import_Completed_Dialog {
    padding: 50px 0;
    text-align: center;

    h3 {
        margin-bottom: 16px;
    }

    i {
        margin-right: 10px;
        color: @StatusSuccess;
    }
}

#Devices_Import_Loading_Dialog {
    padding-top: 50px;
    text-align: center;

    i {
        margin-right: 10px;
        color: @StatusInformation;
    }
}

#Devices_Import_Headers {

    #Devices_Import_Headers_TableContainer {
        margin: 18px 0;
        overflow-x: auto;
        border: 1px solid #ccc;

        table {
            & > thead {
                white-space: nowrap;

                ul.importHeaderType {
                    & > li > a > span:not(.ui-menu-icon) {
                        padding-right: 16px;
                    }

                    ul {
                        z-index: 1000;
                    }
                }

                td.headerIgnoreColumn {
                    background-color: @StatusAlert;
                }

                td:not(.headerIgnoreColumn) {
                    background-color: @StatusInformation;
                }
            }

            & > tbody {
                td.headerDeviceSerialNumber {
                    border-top-color: lighten(@StatusInformation, 50%);
                    border-bottom-color: lighten(@StatusInformation, 50%);
                    background-color: lighten(@StatusInformation, 54%);
                }

                td.headerIgnoreColumn {
                    max-width: 150px;
                    white-space: nowrap;
                    overflow: hidden;
                    -ms-text-overflow: ellipsis;
                    -o-text-overflow: ellipsis;
                    text-overflow: ellipsis;
                    color: @SubtleBorderColour;
                }
            }
        }
    }
}

#Devices_Import_Parsing_Dialog {
    padding-top: 50px;
    text-align: center;

    i {
        margin-right: 10px;
        color: @StatusInformation;
    }
}

// Icons used within Devices_Import_Review
@import "FontAwesome\variables.less";

#Devices_Import_Review {

    #Devices_Import_Review_Navigation {
        margin-top: 15px;
        text-align: right;

        ul {
            display: inline-block;
            padding: 0px;
            border: 1px solid #bbb;

            li {
                display: inline-block;
                padding: 3px 10px;
                margin: 0;

                &.actionDetached {
                    background-color: lighten(@StatusError, 45%);
                }

                &.actionModified {
                    background-color: lighten(@StatusInformation, 54%);
                }

                &.actionAdded {
                    background-color: lighten(@StatusSuccess, 53%);
                }

                &.actionUnchanged {
                    background-color: @TableDataRowBackgroundColor;
                }
            }
        }
    }

    #Devices_Import_Review_TableContainer {
        margin: 18px 0;
        overflow-x: auto;
        border: 1px solid #ccc;

        table {
            & > thead {
                white-space: nowrap;

                tr:nth-child(2) th {
                    padding-top: 0;
                    font-weight: normal;
                    font-size: 0.9em;
                }
            }

            & > tbody {

                td.action {
                    text-align: center;
                }

                tr.actionDetached {
                    td.action {
                        i:before {
                            color: @StatusError;
                            content: @fa-var-exclamation;
                        }
                    }

                    td {
                        background-color: lighten(@StatusError, 50%);
                    }
                }

                tr.actionUnchanged {
                    td.action {
                        i:before {
                            content: @fa-var-minus;
                        }
                    }

                    td {
                        background-color: @TableDataRowBackgroundColor;
                    }

                        td:nth-child(n+3) {
                            color: @SubtleBorderColour;
                        }
                }

                tr.actionModified {
                    td.action {
                        i:before {
                            color: @StatusInformation;
                            content: @fa-var-pencil;
                        }
                    }

                    td {
                        background-color: lighten(@StatusInformation, 58%);
                    }
                }

                tr.actionAdded {
                    td.action {
                        i:before {
                            color: @StatusSuccess;
                            content: @fa-var-plus;
                        }
                    }

                    td {
                        background-color: lighten(@StatusSuccess, 53%);
                    }
                }

                tr:not(.actionUnchanged) {
                    td.actionUnchanged:nth-child(n+3):not(.headerDeviceSerialNumber) {
                        color: @SubtleBorderColour;
                    }
                }

                td.actionError {
                    color: @StatusError;
                    background-color: lighten(@StatusError, 52%);

                    span.errorMessage {
                        display: none;
                    }
                }

                td.actionModified {
                    background-color: lighten(@StatusInformation, 54%) !important;
                }

                td.headerDeviceSerialNumber, td.headerDeviceDecommissionedDate, td.headerDeviceDecommissionedReason,
                td.headerModelId, td.headerBatchId, td.headerProfileId,
                td.headerAssignedUserId {
                    white-space: nowrap;
                }

                span.smallMessage {
                    color: inherit;
                }
            }
        }
    }
}
