@import './dv-constants.scss';
@import 'primeflex/primeflex.scss';

// library global style
html,
body { 
    position:relative;
    height:100vh;
    margin: 0;
    padding: 0;
    overflow: hidden;
    font-size: 12px;
    font-family: 'NanumGothic';
}

#mainTitle {
    margin: 0px;
    height: 34px;

    &> div {
        // justify-content: space-evenly;
        padding: 0px;
        justify-content: flex-start;
        align-items: center;
    
        &:first-child {
            padding-left: 14px;
        }
    
        &:last-child {
            padding-right: 0px;
        }
    }
    div {
        a {
            // display: flex;
            align-items: center;
            height: fit-content;

            strong { font-size: 20px; }
            h5 { margin: 0px 10px 0px 0px; }
        }
    }

    .btn-setting {
        border: none;
        background: transparent;
        padding: 0px;
        line-height: 33px;
    }

    .dv-title-logout {
        font-size: 10pt;
        color: white;
        margin: 0px;
        line-height: 33px;
        a {
            display: inline;
        }
    }
}

.ngBody {
    // padding: 20px;
    position: fixed;
    left: 0;
    right: 0;
    top: 130px;
    bottom: 22.2px;
    overflow: auto;
}

.dv-view-main,
.dv-dashboard {
    padding: 0px 20px;
}

footer {
    z-index: 999;
    padding: 0px 30px;
    width: 100%;
    position: fixed;
    bottom: 0;
    left: 0;

    .row {
        margin-left: -30px;
        margin-right: -30px;
        margin-top: 0px;

        div {
            padding: 3px 5px;
        }
    }
}

.dv-menubar {
    padding: 0px 5px;
    height: 38px;
    margin-bottom: -2px;

    &.p-menubar {
        .p-menubar-root-list > .p-menuitem {
            font-size: 10pt;
            &> .p-menuitem-link {
                // margin-top: 5px;
                margin-top: 6px;
                padding: 0.6rem;
                border-radius: 6px 6px 0px 0px;

                .p-submenu-icon {
                    display: none;
                }
            }
        }
        .p-submenu-list {
            width: max-content;
        }
    }
}

.flex-left {
    @include styleclass('align-items-center justify-content-start');
}

.flex-center {
    @include styleclass('align-items-center justify-content-center');
}

.flex-right {
    @include styleclass('align-items-center justify-content-end');
}

.text-center {
    text-align: center;
}

.text-end {
    text-align: right;
}

.col-centered {
    float: none;
    margin: 0px auto;
}

.text-success,
.text-success .bg-input-row {
    color: var(--green-700) !important;
}

.text-danger,
.text-danger .bg-input-row {
    color: var(--red-700) !important;
}

.text-gray,
.text-gray .bg-input-row {
    color: #BDBDBD !important;
}

.text-info,
.text-info .bg-input-row {
    color: #17a2b8 !important;
}

.text-warning,
.text-warning .bg-input-row {
    color: var(--orange-500) !important;
}

a { cursor: pointer; }

.page-search {
    position: relative;
    margin: 0;
    border-bottom: 1px solid #e3e3e3;
}

.table tr td {
    font-size: 9pt;

    &.input-font-size-11 {
        font-size: 11pt;
        input {
            font-size: 11pt;
            padding: 0.5px;
        }
        div {
            font-size: 11pt;
        }
    }
}

.input-group-menu {
    display: flex;
    justify-content: center;

    .dv-menu-search-input {
        height: 28px;
        min-height: 28px;
        max-width: 250px;
        font-size: 10pt;
    }
    .p-button {
        width: auto;
        display: flex;
        justify-content: space-around;
    }
    .p-button-label { display: none; }
    .p-autocomplete-panel .p-autocomplete-items .p-autocomplete-item {
        padding: 4px;
    }

    .center-item {
        border-radius: 0px;
    }

    .left-item {
        border-right: none;
        border-top-right-radius: 0px !important;
        border-bottom-right-radius: 0px !important;
    }

    .right-item {
        border-left: none;
        border-top-left-radius: 0px !important;
        border-bottom-left-radius: 0px !important;
    }
}

input[type="number"]::-webkit-outer-spin-button,
input[type="number"]::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

// dynamic search - ngbTypeahead
ngb-typeahead-window.dropdown-menu {
    top: 2px !important;
    max-height: 300px !important;
    overflow-y: auto;
    z-index: 2000;
    padding: 5px 0 5px 0;
    border: 1px solid rgba(0,0,0,.15);
    border-radius: 0.25rem;
    .dropdown-item {
        text-align: left;
        min-width:350px;
        width: 100%;
        height: inherit;
        display: block;
        border: none;
        padding: 0;
        background: none;

        div {
            cursor: pointer;
            min-height: 40px;
            padding: 15px 20px;
        }
    }
}

/* Scrollbar */

/* width */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

/* Track */
::-webkit-scrollbar-track {
    box-shadow: inset 0 0 5px #ECEFF1;
    border-radius: 2px;
}

/* Handle */
::-webkit-scrollbar-thumb {
    background: #B0BEC5;
    border-radius: 2px;
}

/* Handle on hover */
::-webkit-scrollbar-thumb:hover {
    background: #78909C;
}

.border-right-none {
    border-right: 0px !important;
}
.border-left-none {
    border-left: 0px !important;
}

// clock start
.clockSvg {
    stroke: #000;
    font-family: "HelveticaNeue-Light", "Helvetica Neue Light", "Helvetica Neue", Helvetica, Arial, "Lucida Grande", sans-serif;
}

#rim {
    fill: none;
    stroke: #999;
    stroke-width: 3px;
}

.second-hand {
    stroke-width: 3;
    stroke: #FF0000;
    stroke-linecap: round;
}

.minute-hand {
    stroke-width: 6;
    stroke: #1565C0;
    stroke-linecap: round;
}

.hour-hand {
    stroke-width: 9;
    stroke-linecap: round;
}

.hands-cover {
    stroke-width: 3;
    fill: #fff;
}

.second-tick {
    stroke-width: 1;
    fill: #000;
}

.hour-tick {
    stroke-width: 5;
    /*same as the miute hand*/
}

.second-label {
    font-size: 12px;
    color: gray;
    stroke: #B0BEC5;
}

.hour-label {
    font-size: 20px;
    stroke: #B0BEC5;
}
// clock end

.card-body {
    flex: 1 1 auto;
    padding: 1rem 1rem;
}

// page-head/search/body start
.page-head {
    // padding-bottom: 10px;
    position:relative;
    padding:5px 0px;
    margin:0;
    border-bottom:1px solid #e3e3e3;

    .p-breadcrumb {
        padding: 0px;
        border: none;
        font-size: 12px;
        display: flex;
        align-content: flex-end;
        justify-content: flex-end;
        height: 100%;
        align-items: flex-end;
        background: transparent;

        ul {
            margin-bottom: 2px;
            li .p-menuitem-link {
                pointer-events: none;
            }
        }
    }

    .dv-comment-card {
        border-radius: 10px;
    
        .p-card-body {
            padding: 10px;
        }
    
        .p-card-content {
            padding: 0px;
    
            .help-comment {
                margin-top: 0px;
                font-size: 14px;
            }
    
            div > p {
                margin-bottom: 0px;
                font-size: 12px;
            }
        }
    }
}
[class*='page-search'] {
    position:relative; 
    padding:10px 0px;
    margin:0;

    &> div {
        padding: 0px 10px;
    }

    input {
        cursor: auto;
    }
}
.page-search {
    border-bottom:1px solid #e3e3e3;
}
.page-search1 {
    margin-bottom:-7px;
}
.page-search2 {
    margin-top:-7px;
    border-bottom:1px solid #e3e3e3;
}
.page-body {
    position:relative; 
    padding-top:5px;
    padding-bottom:5px;
    overflow: auto;
}
// page-head/search/body end

// placeholder start
::-webkit-input-placeholder {
    /* Chrome/Opera/Safari */
    color: #B0BEC5;
}
.form-control::-webkit-input-placeholder {
    /* Chrome/Opera/Safari */
    color: #B0BEC5;
}
::-moz-placeholder {
    /* Firefox 19+ */
    color: #B0BEC5;
}
.form-control::-moz-placeholder {
    /* Firefox 19+ */
    color: #B0BEC5;
}
:-ms-input-placeholder {
    /* IE 10+ */
    color: #B0BEC5;
}
.form-control:-ms-input-placeholder {
    /* IE 10+ */
    color: #B0BEC5;
}

.form-control:-moz-placeholder {
    /* Firefox 18- */
    color: #B0BEC5;
}
:-moz-placeholder {
    /* Firefox 18- */
    color: #B0BEC5;
}
.form-control::placeholder {
    color: #B0BEC5;
    opacity: 1; /* Firefox */
}
::placeholder {
    color: #B0BEC5;
    opacity: 1; /* Firefox */
}
.form-control:-ms-input-placeholder { /* Internet Explorer 10-11 */
   color: #B0BEC5;
}
:-ms-input-placeholder { /* Internet Explorer 10-11 */
    color: #B0BEC5;
 }

::-ms-input-placeholder { /* Microsoft Edge */
   color: #B0BEC5;
}
// placeholder end

.input-btn-height-30 {
    input, button, select {
        height: 30px !important;
        width: auto !important;
        font-size: 10pt !important;
    } 
}

#tableDiv,
#rankedItemDiv {
    .table {
        width: 100%;
        overflow: auto;
        table-layout: fixed;

        tr {
            td {
                text-overflow: ellipsis;
                overflow: hidden;
                white-space: nowrap;
            }

            td, th {
                height:26px;
            }
        }
    }
}

// input validation color start
.dv-input-necessary-success,
td.dv-necessary-success input,
div.dv-necessary-success input {
    border-color: #3ea875 !important;
    &:focus {
        border-color: #3ea875 !important;
        box-shadow: 0 0 5px rgba(62, 168, 117, 0.6);
    }
}
.dv-input-necessary-fail,
td.dv-necessary-fail input,
div.dv-necessary-fail input {
    border-color: $failColor !important;
    &:focus {
        border-color: $failColor !important;
        box-shadow: 0 0 5px rgba(239, 209, 59, 0.6);
    }
}
// input validation color end

[hidden] {
    display: none !important;
}

.dv-input-title {
    text-align: right;
    line-height: 31px;

    label {
        margin: 0;
        font-size: 9pt;
        font-weight: bold;
    }
}

input.form-control {
    font-size: 10pt;
}
.form-control {
    width: 100%;
}

.my-drop-zone {
    border: 1px solid;
}

.rounded {
    border-radius: 0.25rem!important;
}

.img-fluid {
    max-width: 100%;
    height: auto;
}

.socketDialog {
    position: absolute;
    top: 0;
    left: 0;
    z-index: 99999;
    visibility: hidden;
    border: 1px solid grey;
    border-radius: 3px;
    background-color: #fff;
    margin: 5px 5px 5px 10px;
    opacity: 1;
    width: 360px;
    height: 230px;
    overflow: hidden;
    text-align: left;
    font-size: 10pt;
    font-family: sans-serif;
    color: #000;
}

.card-batch {
    p {
        margin-top: 0;
        margin-bottom: 4px;
        font-size: 10pt;
    }

    .card-body {
        height: 210px;
    }

    .card-footer {
        height: 40px;
        padding-right: 4px;
    }
}

[class*="level-"] {
    font-weight: bolder;
}

.level- {
    &1 {
        span { padding-left: 0px; }
    }
    &2 {
        span { padding-left: 15px; }
    }
    &3 {
        span { padding-left: 30px; }
    }
    &4 {
        span { padding-left: 45px; }
    }
    &5 {
        span { padding-left: 60px; }
    }
}

textarea {
    resize: none;
}

// 관리도 화면 css
.dv-list-group {
    display: flex;
    flex-direction: column;
    padding-left: 0;
    margin-bottom: 0;
    margin-top: 0;
    .dv-list-group-item {
        &.in-box-item {
            &:first-child {
                border-top: 0;
            }
        }
        &:first-child {
            border-top-left-radius: 0.25rem;
            border-top-right-radius: 0.25rem;
        }
        position: relative;
        display: block;
        padding: 0.75rem 1.25rem;
        margin-bottom: -1px;
        background-color: #fff;
        border: 1px solid rgba(0,0,0,.125);
        min-height: 34px;
    }
}

.chartControlLine {
    fill:none;
    stroke: #000000;
    stroke-width: 1;

}
.chartControlLine2 {
    fill:none;
    stroke: #9E9E9E;
    stroke-width: 0.5;

}
.chartLine {
    fill: none;
    stroke: #ffab00;
    stroke-width: 3;
}

/* Style the dots by assigning a fill and stroke */
.chartDot {
    fill: #ffab00;
    stroke: #fff;

}
.chartRedDot {
    fill: #B71C1C;
    stroke: #fff;
}
.selectedDot {
    fill:#1565C0;
    stroke: #fff;
}
.verifyMode_1 {
    fill: #B71C1C;
    stroke: #fff;
    strong {
        color: #B71C1C;
    }
}
.verifyMode_2 {
    fill: #880E4F;
    stroke: #fff;
    strong {
        color: #880E4F;
    }
}
.verifyMode_3 {
    fill: #9C27B0;
    stroke: #fff;
    strong {
        color: #9C27B0;
    }
}
.verifyMode_4 {
    fill: #3F51B5;
    stroke: #fff;
    strong {
        color: #3F51B5;
    }
}
.verifyMode_5 {
    fill: #2196F3;
    stroke: #fff;
    strong {
        color: #2196F3;
    }
}
.verifyMode_6 {
    fill: #004D40;
    stroke: #fff;
    strong {
        color: #004D40;
    }
}
.verifyMode_7 {
    fill: #66BB6A;
    stroke: #fff;
    strong {
        color: #66BB6A;
    }
}
.verifyMode_8 {
    fill: #795548;
    stroke: #fff;
}
.chartCapaGoalLine {
    fill:none;
    stroke: #9C27B0;
    stroke-width: 2.5;
    z-index: 100;
}
.chartCapaStandardLine {
    fill:none;
    stroke: #DD2C00;
    stroke-width: 1.5;
    z-index: 100;

}
polyline{
    opacity: .3;
    stroke: black;
    stroke-width: 2px;
    fill: none;
}
.line {
    fill: none;
    stroke: #DD2C00;
    stroke-width: 2.5px;
    z-index: 100;
}
.line2 {
    fill: none;
    stroke: #212121;
    stroke-width: 1.5px;
    z-index: 100;
}

.barText {
    fill: #205493;
}

.barText2 {
    fill: #1B5E20;
}

.bar2 {
    fill: #673AB7;
}

.bar1 {
    fill: #DD2C00;
}

.bar {
    fill: #0071BC;
    stroke: #FFFFFF;
    stroke-width: 1;
}

.bar:hover {
    fill: #81D4FA;
    stroke: #0091EA;
    stroke-width: 1;
}

.bar1:hover {
    fill: #81D4FA;
    stroke: #0091EA;
    stroke-width: 1;
}

.bar2:hover {
    fill: #81D4FA;
    stroke: #0091EA;
    stroke-width: 1;
}

.table-container {
    &.table-outline {
        border: 1px solid #b8bbbf;
    }
}

.dv-border-top {
    border-top: 1px solid #b8bbbf;
}

.dv-scroll-table {
    overflow-y: hidden;
    height:100%;

    .p-datatable-thead { 
        tr{
            th {
                position: sticky !important;
                top: 0 !important;
                z-index: 1 !important;

                &.p-frozen-column {
                    z-index: 10 !important;
                }
            }
        }
    }

    .p-datatable-wrapper {
        overflow-y: auto;
        height: 100%;
    }
}

/* 텍스트 취소선 긋기 */
.test-line-through {
    text-decoration: line-through;
    text-decoration-thickness: 1.5px;
}

textarea.form-control {
    font-size: 10pt;
}

.side-menu-logout {
    &.p-button.p-button-icon-only {
        padding: 1px 0px;
        color: $white;
        &:hover {
            color: $white;
        }
        span.pi {
            font-size: 16px;
        }
    }
}

#ngHeader{
    position:fixed;
    top:0;
    left:0;
    right:0;
    bottom: 1px;
    z-index:999;
    border-bottom:1px solid #304164;
    height:130px;
    background-color:#FFFFFF;
    // overflow: hidden;
    --webkit-overflow-scrolling: touch;
    --webkit-transform: translateZ(999);
}

.main-status {
    height: 24px;
    &> div {
        line-height: 18px;
    }
}

@media screen and (max-width: $lg) {
    #mainTitle div a strong {
        font-size: 14px;
    }

    .dv-panel-menu {
        .p-panelmenu-header {
            &.mobile-hidden {
                display: none;
            }
        }
        li.mobile-hidden {
            display: none;
        }
    }

    .main-title {
        h5 {
            font-size: 14px;
        }
    }
}

@media screen and (max-width: $sm) {
    .page-search1:not(.two-line-search) {
        border-bottom: 1px solid #e3e3e3;
    }
    .page-search2:not(.two-line-search) {
        margin-top: 0px;
        border-top: 1px solid #e3e3e3;
    }
    .p-contextmenu {
        display: none !important;
    }
}
